How do I fix "Error using ==> mupadmex Error in MuPAD command: DOUBLE cannot convert the input expression into a double array. If the input expression contains a symbolic variable, use the VPA function instead." ?
8 次查看(过去 30 天)
显示 更早的评论
This is my script and the error I get after I enter the series equation and starting k:
syms k
series_eq = input('Enter equation(k = index): ');
a = input('Enter starting k (integer >= 1): ');
disp(' ')
p = limit(series_eq(k),k,inf,'left')
p = double(p);
fseries_eq = matlabFunction(series_eq);
k = a:(a + 999);
if abs(fseries_eq(k)) >= abs(fseries_eq(k + 1))
if p == 0
disp('The series equation:')
series_eq
disp('Is convergent.')
disp(' ')
else
disp('The series equation:')
series_eq
disp('Is divergent.')
disp(' ')
end
else
if p == 0
disp('The series equation:')
series_eq
disp('May converge or diverge.')
disp(' ')
else
disp('The series equation:')
series_eq
disp('Is divergent.')
end
end
??? Error using ==> mupadmex
Error in MuPAD command: DOUBLE cannot convert the input expression into a
double array.
If the input expression contains a symbolic variable, use the VPA function instead.
Error in ==> sym.sym>sym.double at 936 Xstr = mupadmex('symobj::double', S.s, 0);
Error in ==> sym.sym>privformatscalar at 2678 x = double(x);
Error in ==> sym.sym>privformat at 2663 s = privformatscalar(x);
Error in ==> sym.sym>sym.subsref at 1379 [inds{k},refs{k}] = privformat(inds{k});
Error in ==> altlimit at 5 p = limit(series_eq(k),k,inf,'left')
0 个评论
采纳的回答
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!