Answer format for solve()
Afficher commentaires plus anciens
I don't like the way MuPad inserts an extra parameter in the solution to a problem I gave it:
solve( { v1 + v2*t + v3*t^2 = 0,
v1*-2 + v2*(-2*t+1) + v3*(-2*t^2 + 2*t) = 0,
v1*4 + v2*(4*t-4) + v3*(4*t^2 - 8*t + 2)=12 } )
Answer: {[t = -z/12, v1 = z^2/24, v2 = z, v3 = 6]}
So I have 2 questions here:
- How do you stop mupad from using a parameter, or remove z from the equations and have the solution in t only?
- If you square z in the solution for v1, you lose the negativity, so isn't this answer strictly speaking not correct? (Since v1 = 6*t^2, not -6*t^2 as it should be?)
Réponse acceptée
Plus de réponses (1)
Andrew Newell
le 2 Juin 2011
1. Just specify the variables:
solve(...,{v1,v2,v3})
2. In your solution, if you substitute for all four variables, the equation is zero.
Catégories
En savoir plus sur Evaluation dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!