1
$\begingroup$

I have two functions $F_1(a,b,x)$ and $F_2(a,b,x)$ I expand these functions about the point $x=0$

  Series[F1,{x,0,2}]
  Series[F2,{x,0,2}]

the coefficients are depended on $a$ and $b$ variables. I want to create the system of equations where all coefficients are equal to zero.

$$F_1(a,b,x)=A_0(a,b)+A_1(a,b)x+A_2(a,b)x^2$$ $$F_2(a,b,x)=B_0(a,b)+B_1(a,b)x+B_2(a,b)x^2$$

so the system of the equations is

$A_0(a,b)=0, \ A_1(a,b)=0, \ A_2(a,b)=0, B_0(a,b)=0, \ B_1(a,b)=0, \ B_2(a,b)=0$

I know that CoefficientList[Series[F1,{x,0,2}],{x}] returns coefficients of the expansion, but how can I use them to create equations? And how can I pass them to Solve[] function?

$\endgroup$
3
  • 2
    $\begingroup$ Solve[Thread[coeffs == 0], (* stuff *)]. Your system is currently overdetermined, however. $\endgroup$ – J. M.'s ennui Oct 31 '15 at 9:54
  • $\begingroup$ J.M. thank you very much. I think your comment is the answer to my question. $\endgroup$ – Paramore Oct 31 '15 at 10:11
  • 1
    $\begingroup$ If you think you understand what Thread[] did to solve your problem, I would suggest writing an answer to your own question. $\endgroup$ – J. M.'s ennui Oct 31 '15 at 10:21
2
$\begingroup$

As suggested J.M. above I use Thread[] function which converts list to list of equations, for example Thread[{a,b,c}==0] = {a=0,b=0,c=0}. So I have two lists

coeff1 = CoefficientList[Series[F1,{x,0,2}],{x}]
coeff2 = CoefficientList[Series[F1,{x,0,2}],{x}]

I join them using Join[] function

coeffs = Join[coeff1,coeff2];

and then I solve the system of equations

 Solve[Thread[coeffs == 0], {a,b}]
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.