partial differential for nonlinear equation
1 view (last 30 days)
Show older comments
i want the partial differential of this equation w.r.t X , Y and Z
31.65951=sqrt((20460991.052399-X)^2+(11012393.207537-Y)^2+(13140061.841029-Z)^2)-sqrt((20462649.31-X)^2+(11012196.356-Y)^2+(13137623.266-Z)^2)
0 Comments
Accepted Answer
Mischa Kim
on 1 Mar 2015
Edited: Mischa Kim
on 1 Mar 2015
Use gradient
syms X Y Z
Eq = -31.65951 + sqrt((20460991.052399-X)^2+(11012393.207537-Y)^2+(13140061.841029-Z)^2)-sqrt((20462649.31- X)^2+(11012196.356-Y)^2+(13137623.266-Z)^2);
gradient(Eq)
ans =
(2*X - 5492455463362645/134217728)/(2*((Z - 3527258492164819/268435456)^2 + (X - 5492455463362645/268435456)^2 + (Y - 2956116792316497/268435456)^2)^(1/2)) - (2*X - 5492900598497935/134217728)/(2*((Z - 7053207784329839/536870912)^2 + (X - 5492900598497935/268435456)^2 + (Y - 5912127900768797/536870912)^2)^(1/2))
(2*Y - 2956116792316497/134217728)/(2*((Z - 3527258492164819/268435456)^2 + (X - 5492455463362645/268435456)^2 + (Y - 2956116792316497/268435456)^2)^(1/2)) - (2*Y - 5912127900768797/268435456)/(2*((Z - 7053207784329839/536870912)^2 + (X - 5492900598497935/268435456)^2 + (Y - 5912127900768797/536870912)^2)^(1/2))
(2*Z - 3527258492164819/134217728)/(2*((Z - 3527258492164819/268435456)^2 + (X - 5492455463362645/268435456)^2 + (Y - 2956116792316497/268435456)^2)^(1/2)) - (2*Z - 7053207784329839/268435456)/(2*((Z - 7053207784329839/536870912)^2 + (X - 5492900598497935/268435456)^2 + (Y - 5912127900768797/536870912)^2)^(1/2))
3 Comments
Mischa Kim
on 1 Mar 2015
Ahmed, how are you running these lines of code? Within a script/function?
Can you get it to run in the MATLAB command window?
More Answers (0)
See Also
Categories
Find more on Calculus 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!