MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Coefficient...

  • To: mathgroup at smc.vnet.net
  • Subject: [mg79631] Re: [mg79601] Coefficient...
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Wed, 1 Aug 2007 04:49:13 -0400 (EDT)
  • Reply-to: hanlonr at cox.net

fx = a*x^2 + d*x*y + 2*c*x + b*c*x*z;

CoefficientList[fx, {x, y, z}][[2, 1, 1]]

2 c

Coefficient[fx /. {y -> 0, z -> 0}, x]

2 c


Bob Hanlon

---- Bruno Campanini <BC at gmail.com> wrote: 
> Given fx:=ax^2 + dxy + 2cx + bcxz
> Coefficient[fx,x] gives   dy + 2c + bcz   but I only need 2c.
> 
> Without any If clause, is it possible to get Coefficient not
> to look on terms containing y or z?
> 
> Bruno
> 



  • Next by Date: Mathematica: FindRoot Help!!!
  • Next by thread: Re: Coefficient...