Sponsored links: Algebra eBooks ### The Maxima on-line user's manual

Algebra Calculator

#### Search: #### Listofvars

Function: listofvars (<expr>) Returns a list of the variables in <expr>.

`listconstvars` if `true` causes `listofvars` to include `%e`, `%pi`, `%i`, and any variables declared constant in the list it returns if they appear in <expr>. The default is to omit these.

See also the option variable `listdummyvars` to exclude or include "dummy variables" in the list of variables.

```          (%i1) listofvars (f (x+y) / g^(2+a));
(%o1)                     [g, a, x , y]
1```

```(%o1)                                true
(%i2) ```

### Related Examples

##### listofvars

lst: listofvars(k*x*m...

lst2: [F, k, t, x, m];

is(lst=lst2);

Calculate

##### listofvars-showratvars

listofvars(x^2+2*x+1);

showratvars(x^2+2*x+1);

Calculate

##### listofvars

term: a^6;

listofvars(term);

Calculate

##### listofvars-showratvars

listofvars(x^2+2*x+1);

showratvars(x^2+2*x+1);

Calculate

##### listofvars

eq: x!*(x-y)!/(y-1)!;

listofvars(eq);

Calculate

##### listofvars-showratvars

listofvars(x^2+2*x+1);

showratvars(x^2+2*x+1);

Calculate

##### listofvars-sqrt

listofvars(sqrt(1+sqr...

sqdnst(sqrt(3-2*sqrt(...

Calculate

##### listofvars

listofvars(F=k*x*m/(t...

Calculate

##### listofvars

listofvars(x^2+2*x+1);

Calculate

##### listofvars-sort

lst: sort(listofvars(...

lst2: sort([F, k, t, ...

Calculate 