Can someone run this simple code for me? Matlab isn't converging to a solution on my computer...
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
A = [0 1 0 0; 1 .15 -2 -.05; 0 0 0 1; -1 -.025 -.5 -.075]
t = sym('t')
expm(A*t)
Thanks in advance! Apparently it should work, but I guess finding the state-transition matrix for when A is a 4 x 4 matrix is pretty computationally taxing for Matlab.
0 Commenti
Risposte (1)
Walter Roberson
il 30 Gen 2014
Modificato: Walter Roberson
il 30 Gen 2014
I suggest experimenting with
expm(sym(A,'d') * t)
the sym(,'d') tells MuPAD to treat the numbers as decimals instead of doing the default of converting to rational. My tests suggest that doing the calculation with rationals might be considerably more time consuming.
1 Commento
Walter Roberson
il 30 Gen 2014
Technical compatibility note:
When you use the MATLAB expm() interface to MuPAD, you do want to multiply your input values by "t", as Kelsey shows. Likewise, if you go down into the MuPAD level to find the built-in MuPAD expm, your numeric input should be multiplied by "t" in the manner shown.
If, though, you happen to use Maple, then Maple's MTM:-expm() function should only be passed the numeric values, as it will add the "t" itself.
Vedere anche
Categorie
Scopri di più su Linear Algebra in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!