### The Maxima on-line user's manual

Algebra Calculator

#### Copy

Function: copy (<e>) Return a copy of the Maxima expression <e>. Although <e> can be any Maxima expression, the copy function is the most useful when <e> is either a list or a matrix; consider:

`          (%i1) m : [1,[2,3]]\$`
`          (%i2) mm : m\$`
`          (%i3) mm[2][1] : x\$`
`          (%i4) m;`
`          (%o4)                      [1,[x,3]]`
`          (%i5) mm;`
`          (%o5)                      [1,[x,3]]`
`     Lets try the same experiment, but this time let <mm> be a copy of`
`     <m>`
`          (%i6) m : [1,[2,3]]\$`
`          (%i7) mm : copy(m)\$`
`          (%i8) mm[2][1] : x\$`
`          (%i9) m;`
`          (%o9)                     [1,[2,3]]`
`          (%i10) mm;`
`          (%o10)                    [1,[x,3]]`
`     This time, the assignment to <mm> does not change the value of <m>.`

There are also some inexact matches for `copy`. Try `?? copy` to see them.

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

? copy;

Calculate

m : [1,[2,3]];

mm : m;

mm[2][1] : x;

Calculate

a: "xxx";

b: copy(a);

Calculate

? copy;

Calculate

m : [1,[2,3]];

mm : m;

mm[2][1] : x;

Calculate

a: "xxx";

b: copy(a);

Calculate