## 827 Reputation

11 years, 197 days

## Thank you...signum...

@Preben Alsholm Thank you. That basicially sorted it. Many "signum" appeared. Used simplify(expr,assume=real) and that polished off the answer.

## Create a document default setting like D...

@Samir Khan Maple pushes strongly into the education sectior. Students basically understand scientific notation. It is neat and tidy. It would be good to have a command like Digits to create this output. e.g. ScientificNotation(5) so 123456789101112131415.01245689 is displayed as

1.2345x10^20 formated to to read nicely. Assuming I  have counted out the number of digits correctly)

Could also make it a bit more functional having an optional 2 digit ScientificNotation(5,3) so could be displayed as 123.45x10^18

Could lead to an interesting situation on integer/rational arithmetic. My take would be a 3rd option ScientificNotation(5,3,y) . So for 123456789 =123x10^6  and ScientificNotation(5,3,n) =123456789 (rationals unchanged) probable the default here should be no. ScientificNotation(5,y) ?? would be nice if possible too. This aspect would be really useful, say when producing a Groebner basis. 1000s of digit long numbers thats are necessary for the maths but you are not going to read them. Probably heresy to the mathmeticians!

Copy/paste would be on the real number not just what is displayed.

I'm sure I am not the first to ask for this. Understand that there could be core difficulties but feel it is really a display formatting issue.

## How to do an enhancment request?...

@acer  Well it works and is far less torturous than my fisrt approach of having to animate each component of the body seperately.

How would I put in for a software enhacment to improve the situation?

## Definately improvement needed in rotate ...

@acer Thank you for you helpful insights. I have used your

f:=T->unapply(convert(eval(Q,t=T).Vector(3,[x,y,z]) , list ),  [x,y,z])

There definately room for improvement to transform command to make more like the rotate command.

I created Body2. It is in my worksheet posted at the start.' vv' was just saying that my rotate command as posted worked. I am using it to animate a body tumbling as it rotates about it's mid axis of inertia called the Dzhanibekov effect. A link to the blog on this is posted in a reply to Rouben Rostamain above. Even though it tumbles it's rotational momentum remains constant.

## This might interest you...

@Rouben Rostamian   I am following a blog on the Dzhanibekov effect. It starts here http://arkadiusz-jadczyk.eu/blog/2017/01/04/   . He is now getting into using quaternions.

## Thank you...

@Kitonum That debugged it. I think the whole thing is a work around though. Not a criticism of you. I guess transfom has to look at a huge array of points that have been stored somewhere and operate on them all. Rotate only needed to inprinciple operate on about a dozen points in the body and the internal routines of arrow, point, line etc fill in the rest. There is definatels scopt for an improved rotate command to take matrices. I know matrices can also transform shape.

## Quaternions are great...

@Rouben Rostamian   Well Quaternions definately solve the problem of dismantling an Euler rotation matrix. See it is easy to convert the quaternion to get axis and angle. Have a little bit of familaity with them. Don't fully understand all the details of your worksheet but get the concept.  Nearly fell of my seat when I saw you reply this evening. I am using Eulers euqations of motion applied to a rigid body rotating about it's mid axis of inertia. It tumbles. Will update you soon.

Write that book. You have valuable knowledge.

## Can you post me a short document of what...

@Scot Gould So do you use worksheet or document mode with 1D math input? I like an example if that is ok.

## Fascinating.....

@Rouben Rostamian  I look forward to your corrected worksheet. What the problem with the one you posted. It pasted my body into it and it ran.

## Code works but my original question rela...

@vv Hi. Yes rotate works. The original question was that I have the rotation matrix not the original w1 w2 w3. I just threw in the Euler rotation matrix here as it is easy to produce for this example.

In my reply to you above I tried applying the transform command to the matrix (Rot). That I couldn't get to work. I dont think I did that correctly. I basicially used

f:=t->plottools:-transform((x,y,z)->convert(Rot.Vector(3,[x,y,z]), list)):

f2 := plots:-animate(plots:-display, [('f(t)')(Body2)], t = 0 .. 8*Pi, frames = 100, scaling = constrained)

This either produces an empty animation (10 frames)   or output exceeds 10000000   (100 frames) I tried unevaluation quotes around plots:-display.

## @Kitonum  Tried this.Either it give...

@Kitonum  Tried this.

Either it gives empty plot or for 100 frames `[Length of output exceeds limit of 10000000]`. Tried the usual combinations of delay evaluation quotes. No luck.

f := proc (t) options operator, arrow; transform(proc (x, y, z) options operator, arrow; convert(Rot . Vector(3, [x, y, z]), list) end proc) end proc

f2 := plots:-animate(plots:-display, [('f(t)')(Body2)], t = 0 .. 8*Pi, frames = 100, scaling = constrained)

## Thank you...

@Scot Gould  Thanks for the useful info. Yes I know a lot of pros. use the worksheet format. I home thought so started off on the pretty interface.

## Nice,...

@vv That make it simple. I confused rotate with the Rotate command in Image tools. It uses lefthand rule. Odd but not a shot stopper.

## There must be a bug in "point"...

@acer  Firstly I replyed to this hours ago but it never appeared here. You have masterful insight/experience with Maple. I tested your solutions under the following condition. I replaced, e.g sin(0.25 t) with sin(w t), then defined w later after the display/animate commands. The 'point' produces an error still, 'line' works fine. Worksheet posted, I made before I saw your posts.

I have included the OriginalBody. I wanted to rotate this without having to define the functions inside the plot/display/animate commands. What I have done works but I certainly don't like the level of workaround required.

 (1)

 (2)

 (3)

 (4)

 (1)

 (2)

 (3)

 (4)

## There must be a bug with points....

@acer Very insightful. Points still can cause errors with you solutions if a variable apart from t does not have a numerical value. Line works fine.  I got this working last night using POINTS. My approach is somewhat tedious to program. I would rather be able to apply the rotation matrix to the "OriginalBody" shoun at the start.

 (1)

 (2)

 (3)

 (4)