error in integral equation
1 次查看(过去 30 天)
显示 更早的评论
clc
clear
% t = -(r^3)*sqrt((R)^2-(ro)^2);
% k= sqrt(((R)^6*(r^2-ro^2))-((r)^6*(R^2-ro^2)));
% z = t/k;
R = 65; ro = 17.5;
syms r
func1 = @(r) PI*((-(r^3).*sqrt((R)^2-(ro)^2))/(sqrt(((R)^6.*(r^2-ro^2))-((x)^6*(R^2-ro^2)))))*r.^2;
j = integral(func1, 65,17.5);
Hi all,
I am trying to solve this code in matlab, but i am getting an error as
Error in integral (line 88)
Q = integralCalc(fun,a,b,opstruct);
Error in performance_factor_optimal (line 9)
j = integral(func1, 65,17.5);
any suggestions thanks in advance![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/274531/image.jpeg)
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/274531/image.jpeg)
0 个评论
采纳的回答
Walter Roberson
2020-3-1
Each place that you have r^ change that to r.^
Change / to ./
Change * to .*
Also we need to see the source code for the function x that you are calling without parameters.
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!