Determining particular solution of 3x3 matrix using variation of parameters

5 views (last 30 days)
If I am correct in my process for variation of parameters for a matrix:
I already have my general solution that was solved (with some help...thanks!) via undetermined coefficients.
I then need to take the inverse of that matrix.
Then I multiply the inverse by the non-homogeneous part of the equation. And this is where I get stuck...
I can then take the integral of the resulting matrix for my particular solution...
Is taking this approach flawed in general? Or is there something simple that I am missing when I try to multiply the inverse by the non-hom. part?
Thank you for any insight.
Here is my general solution:
>> null(evs(1)*Id3-A)
ans =
152/21
-57/7
1
>> null(evs(2)*Id3-A)
ans =
0
-1/7
1
>> null(evs(3)*Id3-A)
ans =
0
0
1
And this is where the trouble begins...
>> A = sym([152/21,0,0;-57/7,-1/7,0;0,0,1]);
>> Y=inv(A)
Y =
[ 21/152, 0, 0]
[ -63/8, -7, 0]
[ 0, 0, 1]
>> B = sym([-1575,0,0]);
>> Y*B
??? Error using ==> mupadmex
Error in MuPAD command: dimensions do not match [(Dom::Matrix(Dom::ExpressionField()))::_mult2]
Error in ==> sym.sym>sym.mtimes at 180
X = mupadmex('mllib::mtimes',A.s,B.s);

Accepted Answer

madhan ravi
madhan ravi on 9 Dec 2018
Remove sym()
  4 Comments
spcrooks
spcrooks on 9 Dec 2018
How silly...big difference between [-1575,0,0] and [-1575;0;0] !
Got it. Thanks, again.

Sign in to comment.

More Answers (0)

Products


Release

R2010a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!