Derivative is calculated 2 different ways.
Mostra commenti meno recenti
I used the code syms x ((x^2)+4)^2*(2*x^3-1)^3 diff(ans)
This is an improper result-- but if I use syms x ((x^2)+4)^2*(2*x^3-1)^3 expand(ans) diff(ans)
It works fine.
Even more frustratingly, when I name the function anything, my workaround with "expand" no longer works. I can only do it as expand(ans). Any explanation of why? My whole class is having an issue with this problem and I am the only one who has been able to get MATLAB to get the correct answer-- but I don't know why.
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Code Performance in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!