Having difficulty performing symbolic integral
3 views (last 30 days)
Show older comments
Faraz Vossoughian on 18 Dec 2017
Answered: Walter Roberson on 20 Dec 2017
In my code the part im trying to calculate A0 , A1,A2 and zerolift i get the following error
Error using sym/subsindex (line 836)
Invalid indexing or function definition. Indexing must follow
MATLAB indexing. Function arguments must be symbolic variables,
and function body must be sym expression.
Error in sym/subsref (line 881)
R_tilde = builtin('subsref',L_tilde,Idx);
Error in TEST2 (line 10)
please someone help me.
my code is below
dzdx=(12*xc*(2*xc - 2))/25 + (12*(xc - 1)^2)/25;
Amy on 20 Dec 2017
Faraz, I think you are running into this issue because of the following line:
int = A/pi;
Then you run into an error the next time you try calling the int function because it is " shadowed". Try renaming that variable something else and you should no longer run into the same error.
Walter Roberson on 20 Dec 2017
As I said then, do not use int as a variable name. I suggested replacement code there.
Find more on Common Operations in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!Start Hunting!