aajgeeraert
(Chiel Geeraert)
1
I have this quotiënt split in partial fractions as following :
(s^2 + 3) / ((s - 1)^2 (s + 1)) == A1 / (s - 1) + A2 / (s - 1)^2 + A3 / (s + 1)
Is there an easy way to find the constants ? I tried several things with Solve but without succes.
Thank you very much
timmy2x
(Tim Laska)
2
Have you looked at Apart?
Apart[(s^2 + 3)/((s - 1)^2 (s + 1))] (* 2/(-1+s)^2+(1+s)^(-1) *)
mhelmle
(Michael Helmle)
3
eq1 = (s^2 + 3)/((s - 1)^2 (s + 1)) == A1/(s - 1) + A2/(s - 1)^2 + A3/(s + 1)
sol = SolveAlways[eq1, s][[1]]
(* {A2\[Rule]2,A3\[Rule]1,A1\[Rule]0}*)
Simplify[eq1 /. sol]
aajgeeraert
(Chiel Geeraert)
4
Thank you both very much. I have found a solution myself but with more ‘hassle’ around it then yours.
f[s_] := (s^2 + 3) / ((s - 1)^2 (s + 1)) == A1 / (s - 1) + A2 / (s - 1)^2 + A3 /( s + 1)
Solve[ { f[s] /. s → 0, f[s] /. s → 2, f[s] /. s → 3}, {A1, A2, A3}]
{{A1 → 0, A2 → 2, A3 → 1}}
Greetings,Chiel Geeraert (Netherlands)