       Re: how to simplify an expression

• To: mathgroup at smc.vnet.net
• Subject: [mg90843] Re: how to simplify an expression
• From: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>
• Date: Sat, 26 Jul 2008 04:20:27 -0400 (EDT)
• Organization: The Open University, Milton Keynes, UK
• References: <g6c971\$bqv\$1@smc.vnet.net>

mssivava wrote:

> The following code calculates the elements of matrises (x6). But in the result there are some characters like #1,& vs.
> And I couldn't success to express the result without these characters. Is there anyway to express more clear result? Please help!!!!!!!!!
>
>
>
> A = {{0, -R, 0, 0, 0, 0}, {(-Gamma^2*R^3*k)/Dnn, 0, -1,(R*(1 + Gamma^2))/Dnn, 0, 0}, {0, 1, 0, 0, (R*(1+ Gamma^2))/Dtt, (-R^2*Gamma^2)/Dtt}, {0, 0, 0, 0, -1, R}, {0, 0, 0, 1, 0, 0}, {k*R, 0, 0, 0, 0, 0}}
>
> expmat = MatrixExp[t*A]
> expmat // MatrixForm
> FullSimplify[expmat[[1, 1]]]

The characters ("#!", "&", and the likes) you are referring to are parts
of larger expressions called *Root[]*. Each Root[] object is an exact
concise symbolic representation of a root. See

http://reference.wolfram.com/mathematica/ref/Root.html

If you want to get rid of them, you can use *ToRadicals[]*. See

Note that, arguably, transforming Root[] objects into radicals might not
be such a good idea since the complexity of the resulting matrix
(measured in terms of binary tree size and depth) is dramatically
increased. For instance,

A = {{0, -R, 0, 0, 0, 0}, {(-Gamma^2*R^3*k)/Dnn,
0, -1, (R*(1 + Gamma^2))/Dnn, 0, 0}, {0, 1, 0,
0, (R*(1 + Gamma^2))/Dtt, (-R^2*Gamma^2)/Dtt}, {0, 0, 0, 0, -1,
R}, {0, 0, 0, 1, 0, 0}, {k*R, 0, 0, 0, 0, 0}};

expmat = MatrixExp[t*A];

LeafCount[expmat[[1, 1]]]

(* 7972 *)

(* 74516 *)

LeafCount[expmat]

(* 232132 *)