MathGroup Archive 2010

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

Search the Archive

Re: counting number of variables in an expression

  • To: mathgroup at smc.vnet.net
  • Subject: [mg108636] Re: counting number of variables in an expression
  • From: Bob Hanlon <hanlonr at cox.net>
  • Date: Thu, 25 Mar 2010 06:08:58 -0500 (EST)
  • Reply-to: hanlonr at cox.net

Variables[(x + y)^2 + 3 z^2 - y z + 7]

{x,y,z}

% // Length

3


Bob Hanlon

---- Rob <schabertrobbinger at gmail.com> wrote: 

=============
Is there a straightforward way to count the number of variables in an
expression? If it makes any difference what I'm looking at is the
product of several polynomials in many variables with rational
coefficients.




  • Prev by Date: Re: An open note for all the Mathematica
  • Next by Date: Re: partial derivate of a function of vector variable
  • Previous by thread: counting number of variables in an expression
  • Next by thread: Re: counting number of variables in an expression