# freeIndets

Free indeterminates of an expression

### Use only in the MuPAD Notebook Interface.

This functionality does not run in MATLAB.

## Syntax

```freeIndets(`object`, <All>)
```

## Description

`freeIndets(object)` returns the free indeterminates of `object` as a set.

An identifier occurring in `object` is free if it cannot be replaced by another identifier without changing the mathematical meaning of `object`.

By default, `freeIndets` does not return free identifiers that occur only in the `0`th operand of subexpressions of `object`.

The special identifiers `PI`, `EULER`, `CATALAN` are not free indeterminates. See Example 1.

If `object` is a polynomial, a function environment, a procedure, or a built-in kernel function, then `freeIndets` returns the empty set. See Example 3.

## Examples

### Example 1

Find free identifiers in the following image set. In this set, `PI` is a mathematical constant; therefore, it is not a free identifier. The operand `f` is a `0`th operand. The variable `k` is not a free identifier because you can replace it by any other letter like `m` or `n` without changing the mathematical meaning. Therefore, only `u` is a free identifier:

`e:= Dom::ImageSet(k*f(u)+PI, k, Z_)`

`freeIndets(e)`

To find all identifiers in the same image set, use `indets`:

`indets(e)`

### Example 2

Use the `All` option to return free identifiers including the `0`th operands of subexpressions. For example, compare the sets of free identifiers returned by `freeIndets` with the `All` option and without this option:

```e := Dom::ImageSet(k*f(u)+PI, k, Z_): freeIndets(e, All); freeIndets(e)```

### Example 3

`freeIndets` assumes that polynomials and functions do not have free indeterminates:

```delete x, y: freeIndets(poly(x*y, [x, y])), freeIndets(sin), freeIndets(x -> x^2+1)```

## Parameters

 `object` An arbitrary object

## Options

 `All` Do not exclude free identifiers that occur in the `0`th operand of subexpressions of `object`. With this option, `freeIndets` does not exclude the `0`th operand. If the `0`th operand of a subexpression is an indeterminate, such as `sin`, the `freeIndets` function includes this operand in the result. See Example 2.

`object`

## Algorithms

If `object` is an element of a library domain `T` that has a slot `"freeIndets"`, then MuPAD® calls the slot routine `T::freeIndets` with `object` as an argument. You can use this approach to extend the functionality of `freeIndets` to user-defined domains. If no such slot exists, then `freeIndets` regards all identifiers occurring in elements of that domain as free, with the exception of mathematical constants.