Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

Maybe I am missing something here. Maybe it's just a new feature?

I have just installed Maple 2021 on Mac.

A simple sheet, using simplify-simplify to get units right.

Sometimes Maple doesn't update result when pressing Enter.

Sometimes Maple doesn't give any result when pressing Enter.

First everything ok:

Then I change a to 5 m. Pressing Enter on all three lines gives:

The value of A is not updated.

If I then delete the 'simplify 9 m^2' and presses Enter on the line with A:=a*b, there is no output?

Pressing Enter on blue line, no output.

 

Reviewing the help Physics Examples worksheet Section 1, subsection 5 a transformation between cartesion and spherical coordinates is defined using the command ChangeCoordinates from the Physics[Vectors] package. This command is described briefly as follows in the Updates, Maple 2015, Physics page:

"New command: ChangeCoordinates, to rewrite an algebraic expression, using Cartesian, cylindrical, and spherical coordinates, an expression that involves these coordinates, either a scalar expression, or vectorial one but then not changing the orthonormal basis."

However, when I use the link to the ChangeCoordinates help page, the link simply loops back to the Updates, Maple 2015, Physics page.  Is there a specific help page for the ChangeCoordinates command?

Hi!

I am trying to combine the plot in cobweb-diagram.mw (sorry for the messed up axes, you can adjust it in the 'axes properties') with the plot in modèle_graphes.mw. I've tried these two things : test1.mw and test2.mw, but I can't make it work. 

 

Can someone please help me combine these graphics ? Thank you very much for your time.

hello everyone, i have an idea how to implement adomain decomposition method manually but want to transform the whole method on maple for any kind of non-linear ode.

Respected administration I already posted the same question for the other method, pls do not delete my question

 

help_adomian_decomposition_method.mw

hello I would like to ask how to implement phase singularities using wavelets in maple.

https://pdfs.semanticscholar.org/03cf/d388491c4fc7bc41c5f99a284feb7b2c34f1.pdf

http://mmlab.ie.cuhk.edu.hk/archive/2009/pami09_theory.pdf

restart;
Here is my pde and a procedure that plots the solution.
K1:=proc(g)
uses PDEtools,plots:
local pde, ic,ans;
pde:=-4*x*diff(f(u,x),u,x)+4*diff(f(u,x),u)=x^4*diff(f(u,x),x,x)+x^3*diff(f(u,x),x)+8*x^2*f(u,x)*(1-f(u,x)^2);
ic:={f(u,0) = 1, f(u,1) = 0,f(0,x)=g};
ans:=pdsolve(pde,ic,numeric,compile=true,time=u,range=0..1,'spacestep'=0.005);
ans:-plot(u=3)
end proc:
K1(1+x^2-2*x^3);

It works just fine; I get a plot of f(u,x) for u =3.  (Note that unlike dsolve there is no complaint about the global variable g in the initial conditions.)
Now I want to see a plot of diff(f(u,x) for u=3.
K2:=proc(g)
uses PDEtools,plots:
local pde, ic,ans;
pde:=-4*x*diff(f(u,x),u,x)+4*diff(f(u,x),u)=x^4*diff(f(u,x),x,x)+x^3*diff(f(u,x),x)+8*x^2*f(u,x)*(1-f(u,x)^2);
ic:={f(u,0) = 1, f(u,1) = 0,f(0,x)=g};
ans:=pdsolve(pde,ic,numeric,compile=true,time=u,range=0..1,'spacestep'=0.005);
ans:-plot([diff(f(u,x),x,u),color=cyan],u=3)
end proc:
K2(1+x^2-2*x^3);

That does not work.

I try to introduce a new variable h(u,x) = diff(f(u,x),x) so that I can plot h(u,x).
K3:=proc(g)
uses PDEtools,plots:
local pde, ic,ans;
pde:={h(u,x)=diff(f(u,x),x),
-4*x*diff(h(u,x),u)+4*diff(f(u,x),u)=x^4*diff(h(u,x),x)+x^3*h(u,x)+8*x^2*f(u,x)*(1-f(u,x)^2)};
ic:={f(u,0) = 1,f(u,1) = 0,f(0,x)=g};
ans:=pdsolve(pde,ic,numeric,compile=true,time=u,range=0..1,'spacestep'=0.005);
ans:-plot(h(u,x),u=3)
end proc:

K3(1-x^2);
Error, (in pdsolve/numeric/par_hyp) Incorrect number of initial conditions, expected 2, got 1

I have no idea what Maple is referring to; there are 3 initial conditions, not 1 or 2.

Anybody know what is going on? Any idea how to get what I need?

One more comment. I have never knowingly used a module in all the years I have been using and teaching Maple. I am sure there are good reasons for the construct but I think it would be difficult to teach. For ode's the result of dsolve is a procedure and it is relatively easy to teach because procedures are the bread and butter of using Maple. Why does pdsolve return a module?  I spent a good deal of time figuring out the use of pdsolve and would not like to force my students to do the same. I get them up to speed solving ode's using dsolve and DETools in a one hour lab. I wonder how much time it would take to do pdsolve.

 

It seems that DrawGraph cannot display the weights of more than 45 arcs of a directed graphs (the arcs themselves are keeping to be displayed correctly).

Maybe a version issue?

WeightedGraphs.mw

I am using Maple 2020.2 and it seems that the Linear Algebra package is incompatable with the Vector Calculus package:

Why not a friendly error message?
I want to use the Jacobian and the Hessian. Are there alternatives? MTM package can give a Jacobian, but no Hessian (but MTM is also tricky to use).

Harry

 

I want to compute the Lie derivative of a large expression in maple.
The expression is attached, there are 20 vars in total. But Maple cannot do that (after 7hrs of working!), but this is doable with another math tool which first turns the expression into subexpressions.
However, I want to do this in Maple.
I have already tried to simplify/combine/factor/use the Lie algebra package, none of them helped.
Any suggestion is highly appreciated

 

(6*m__1*(2*x[13]*x[12]*((x[12]*(cos(x[7])^2 - 2)*(x[17] - g__1)*cos(x[8])^2 - 2*x[12]*(x[17] - g__1)*cos(x[7])^2 + x[18]*cos(x[7])*sin(x[7])*sin(x[8]) + x[12]*(x[17] - g__1))*cos(x[6])^2 - 2*cos(x[8])*(x[12]*sin(x[8])*(x[17] - g__1)*sin(x[7]) + x[18]*cos(x[7])/2)*sin(x[6])*cos(x[6]) + x[12]*cos(x[8])^2*(x[17] - g__1))*cos(x[4])^5 + ((-x[12]*x[13]*x[18]*sin(x[4])*(cos(x[7])^2 - 2)*cos(x[8])^2 + (((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])*x[12]*sin(x[8])*cos(x[7])^2 - 3*(x[12]^2*x[18] - (2*x[20])/9)*sin(x[7])*cos(x[7])/2 - 2*((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])*x[12]*sin(x[8]))*cos(x[8]) + 4*(x[18]*cos(x[7])^2/2 + x[12]*sin(x[7])*sin(x[8])*(x[17] - g__1)*cos(x[7]) - x[18]/4)*sin(x[4])*x[13]*x[12])*cos(x[6])^2 + (2*((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])*sin(x[7])*x[12]*sin(x[6])*cos(x[8])^2 - 4*(x[12]*x[13]*sin(x[4])*sin(x[6])*(x[17] - g__1)*cos(x[7]) - x[13]*x[18]*sin(x[4])*sin(x[6])*sin(x[7])*sin(x[8])/2 - x[12]*x[15]*(x[17] - g__1)/24)*x[12]*cos(x[8]) - (3*(x[12]^2*x[18] - (2*x[20])/9)*sin(x[8])*cos(x[7])/2 + ((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])*sin(x[7])*x[12])*sin(x[6]))*cos(x[6]) + x[12]*(-x[13]*x[18]*cos(x[8])^2*sin(x[4]) + ((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])*sin(x[8])*cos(x[8]) + x[12]*sin(x[8])*(x[17] - g__1)*(sin(x[6])*sin(x[7])*x[15] + x[14]*cos(x[7]))/6))*cos(x[4])^4 + ((-5*x[12]^2*x[13]*(cos(x[7])^2 - 2)*(x[17] - g__1)*cos(x[8])^2 - sin(x[4])*(3*(x[12]^2*x[18] - (2*x[20])/9)*sin(x[8])*cos(x[7])^2/2 + ((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])*sin(x[7])*x[12]*cos(x[7]) - 3*(x[12]^2*x[18] - (2*x[20])/9)*sin(x[8]))*cos(x[8]) + 7*(x[12]*(x[17] - g__1)*cos(x[7])^2 - (2*x[18]*cos(x[7])*sin(x[7])*sin(x[8]))/7 - (5*x[12]*(x[17] - g__1))/7)*x[13]*x[12])*cos(x[6])^2 - (3*sin(x[4])*(x[12]^2*x[18] - (2*x[20])/9)*sin(x[7])*cos(x[8])^2 - 10*(x[18]*cos(x[7])/5 + x[12]*sin(x[8])*(x[17] - g__1)*sin(x[7]))*x[13]*x[12]*cos(x[8]) + sin(x[4])*(((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])*x[12]*sin(x[8])*cos(x[7]) - 3*(x[12]^2*x[18] - (2*x[20])/9)*sin(x[7])/2))*sin(x[6])*cos(x[6]) - 5*x[12]^2*x[13]*(x[17] - g__1)*cos(x[8])^2 - (3*sin(x[4])*(x[12]^2*x[18] - (2*x[20])/9)*sin(x[8])*cos(x[8]))/2 + (x[17] - g__1)*(x[15]*cos(x[7])*sin(x[4])*sin(x[6])/6 - x[14]*sin(x[4])*sin(x[7])/6 + x[13])*x[12]^2)*cos(x[4])^3 - (7*x[12]*((-(4*x[13]*x[18]*sin(x[4])*(cos(x[7])^2 - 2)*cos(x[8])^2)/7 + (((x[17] - g__1)*x[12]^2 + ((4*x[17])/7 - (4*g__1)/7)*x[13]^2 - (2*x[19])/7)*sin(x[8])*cos(x[7])^2 - (5*x[12]*x[18]*cos(x[7])*sin(x[7]))/7 - 2*((x[17] - g__1)*x[12]^2 + ((4*x[17])/7 - (4*g__1)/7)*x[13]^2 - (2*x[19])/7)*sin(x[8]))*cos(x[8]) + 10*(x[18]*cos(x[7])^2/5 + x[12]*sin(x[7])*sin(x[8])*(x[17] - g__1)*cos(x[7]) - (2*x[18])/5)*sin(x[4])*x[13]/7)*cos(x[6])^2 + (2*((x[17] - g__1)*x[12]^2 + ((4*x[17])/7 - (4*g__1)/7)*x[13]^2 - (2*x[19])/7)*sin(x[7])*sin(x[6])*cos(x[8])^2 + (-(10*x[12]*x[13]*sin(x[4])*sin(x[6])*(x[17] - g__1)*cos(x[7]))/7 + (8*x[13]*x[18]*sin(x[4])*sin(x[6])*sin(x[7])*sin(x[8]))/7 + x[12]*x[15]*(x[17] - g__1)/21)*cos(x[8]) - ((5*x[12]*x[18]*cos(x[7])*sin(x[8]))/7 + ((x[17] - g__1)*x[12]^2 + ((4*x[17])/7 - (4*g__1)/7)*x[13]^2 - (2*x[19])/7)*sin(x[7]))*sin(x[6]))*cos(x[6]) - (4*x[13]*x[18]*cos(x[8])^2*sin(x[4]))/7 + ((x[17] - g__1)*x[12]^2 + ((4*x[17])/7 - (4*g__1)/7)*x[13]^2 - (2*x[19])/7)*sin(x[8])*cos(x[8]) + x[12]*x[14]*sin(x[8])*(x[17] - g__1)*cos(x[7])/21 + (2*x[13]*x[18]*sin(x[4]))/7 + x[12]*x[15]*sin(x[6])*sin(x[7])*sin(x[8])*(x[17] - g__1)/21)*cos(x[4])^2)/2 + 3*(((4*x[13]*(cos(x[7])^2 - 2)*(x[17] - g__1)*cos(x[8])^2)/3 + sin(x[4])*((2*x[18]*cos(x[7])^2*sin(x[8]))/3 + x[12]*sin(x[7])*(x[17] - g__1)*cos(x[7]) - (4*x[18]*sin(x[8]))/3)*cos(x[8]) - (2*x[13]*(cos(x[7])^2 - 2)*(x[17] - g__1))/3)*cos(x[6])^2 + ((4*x[18]*cos(x[8])^2*sin(x[4])*sin(x[7]))/3 - (8*x[13]*sin(x[7])*sin(x[8])*(x[17] - g__1)*cos(x[8]))/3 + (x[12]*sin(x[8])*(x[17] - g__1)*cos(x[7]) - (2*x[18]*sin(x[7]))/3)*sin(x[4]))*sin(x[6])*cos(x[6]) + (4*x[13]*(x[17] - g__1)*cos(x[8])^2)/3 + (2*x[18]*cos(x[8])*sin(x[4])*sin(x[8]))/3 - (2*x[13]*(x[17] - g__1))/3)*x[12]^2*cos(x[4]) + 2*(x[17] - g__1)*(cos(x[8])*sin(x[8])*(cos(x[7])^2 - 2)*cos(x[6])^2 + 2*(cos(x[8])^2 - 1/2)*sin(x[7])*sin(x[6])*cos(x[6]) + cos(x[8])*sin(x[8]))*x[12]^3)*L*cos(x[5])^6 + (12*m__1*sin(x[5])*((-((x[12]^2*x[18] - x[20]/6)*(cos(x[7])^2 - 2)*cos(x[8])^2)/2 + (x[12]^2*x[18] - x[20]/6)*cos(x[7])^2 + sin(x[7])*((x[17] - g__1)*x[12]^2 + (x[17] - g__1)*x[13]^2 - x[19]/2)*x[12]*sin(x[8])*cos(x[7]) - x[12]^2*x[18]/2 + x[20]/12)*cos(x[6])^2 - (((x[17] - g__1)*x[12]^2 + (x[17] - g__1)*x[13]^2 - x[19]/2)*x[12]*cos(x[7]) - (x[12]^2*x[18] - x[20]/6)*sin(x[7])*sin(x[8]))*cos(x[8])*sin(x[6])*cos(x[6]) - cos(x[8])^2*(x[12]^2*x[18] - x[20]/6)/2)*L*cos(x[4])^5 - 6*m__1*sin(x[5])*((sin(x[4])*(cos(x[7])^2 - 2)*((x[17] - g__1)*x[12]^2 + (x[17] - g__1)*x[13]^2 - x[19]/2)*x[12]*cos(x[8])^2 + 3*x[13]*((2*x[18]*cos(x[7])^2*sin(x[8]))/3 + x[12]*sin(x[7])*(x[17] - g__1)*cos(x[7]) - (4*x[18]*sin(x[8]))/3)*x[12]*cos(x[8]) - 2*sin(x[4])*(((x[17] - g__1)*x[12]^2 + (x[17] - g__1)*x[13]^2 - x[19]/2)*x[12]*cos(x[7])^2 - (x[12]^2*x[18] - x[20]/6)*sin(x[7])*sin(x[8])*cos(x[7]) - (((x[17] - g__1)*x[12]^2 + (x[17] - g__1)*x[13]^2 - x[19]/2)*x[12])/2))*cos(x[6])^2 - 2*(-2*x[12]*x[13]*x[18]*cos(x[8])^2*sin(x[7]) + sin(x[4])*((x[12]^2*x[18] - x[20]/6)*cos(x[7]) + sin(x[7])*((x[17] - g__1)*x[12]^2 + (x[17] - g__1)*x[13]^2 - x[19]/2)*x[12]*sin(x[8]))*cos(x[8]) - 3*(x[12]*sin(x[8])*(x[17] - g__1)*cos(x[7]) - (2*x[18]*sin(x[7]))/3)*x[13]*x[12]/2)*sin(x[6])*cos(x[6]) + cos(x[8])*(sin(x[4])*((x[17] - g__1)*x[12]^2 + (x[17] - g__1)*x[13]^2 - x[19]/2)*cos(x[8]) + 2*x[13]*x[18]*sin(x[8]))*x[12])*L*cos(x[4])^4 + ((15*m__1*sin(x[5])*(cos(x[7])^2 - 2)*(x[12]^2*x[18] - (2*x[20])/15)*L*cos(x[8])^2 - 18*x[12]*((x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*sin(x[8])*cos(x[7])^2 - (2*L*x[13]*x[18]*cos(x[7])*sin(x[4])*sin(x[5])*sin(x[7])*m__1)/3 - 2*(x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*sin(x[8]))*cos(x[8]) - 33*m__1*sin(x[5])*(((7*x[12]^2*x[18])/11 - x[20]/33)*cos(x[7])^2 + ((x[17] - g__1)*x[12]^2 + ((4*x[17])/11 - (4*g__1)/11)*x[13]^2 - (2*x[19])/11)*sin(x[7])*x[12]*sin(x[8])*cos(x[7]) - (5*x[12]^2*x[18])/11 + (2*x[20])/33)*L)*cos(x[6])^2 + 33*(-12*(x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*sin(x[7])*x[12]*cos(x[8])^2/11 + m__1*sin(x[5])*(((x[17] - g__1)*x[12]^2 + ((4*x[17])/11 - (4*g__1)/11)*x[13]^2 - (2*x[19])/11)*x[12]*cos(x[7]) - 10*(x[12]^2*x[18] - (2*x[20])/15)*sin(x[7])*sin(x[8])/11)*L*cos(x[8]) + (6*x[12]*((2*L*x[13]*x[18]*cos(x[7])*sin(x[4])*sin(x[5])*sin(x[8])*m__1)/3 + (x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*sin(x[7])))/11)*sin(x[6])*cos(x[6]) + 15*m__1*sin(x[5])*(x[12]^2*x[18] - (2*x[20])/15)*L*cos(x[8])^2 - 18*(x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*x[12]*sin(x[8])*cos(x[8]) - 3*(x[12]^2*x[18] - x[20]/3)*m__1*sin(x[5])*L)*cos(x[4])^3 + 15*x[12]*((m__1*sin(x[4])*sin(x[5])*(cos(x[7])^2 - 2)*L*((x[17] - g__1)*x[12]^2 + ((4*x[17])/5 - (4*g__1)/5)*x[13]^2 - (2*x[19])/5)*cos(x[8])^2 + ((4*L*x[13]*x[18]*cos(x[7])^2*sin(x[5])*sin(x[8])*m__1)/5 + 2*(x[17] - g__1)*sin(x[7])*(L*x[12]*x[13]*sin(x[5])*m__1 - (2*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/15)*cos(x[7]) - (8*L*x[13]*x[18]*sin(x[5])*sin(x[8])*m__1)/5)*cos(x[8]) - (9*m__1*sin(x[4])*(((x[17] - g__1)*x[12]^2 + ((2*x[17])/9 - (2*g__1)/9)*x[13]^2 - x[19]/9)*cos(x[7])^2 - (5*x[12]*x[18]*cos(x[7])*sin(x[7])*sin(x[8]))/9 + (-(5*x[17])/9 + (5*g__1)/9)*x[12]^2 + (-(4*x[17])/9 + (4*g__1)/9)*x[13]^2 + (2*x[19])/9)*sin(x[5])*L)/5)*cos(x[6])^2 + ((8*L*x[13]*x[18]*cos(x[8])^2*sin(x[5])*sin(x[6])*sin(x[7])*m__1)/5 - 2*(x[12]*x[18]*cos(x[7])/2 + sin(x[7])*((x[17] - g__1)*x[12]^2 + ((4*x[17])/5 - (4*g__1)/5)*x[13]^2 - (2*x[19])/5)*sin(x[8]))*m__1*sin(x[4])*sin(x[5])*L*sin(x[6])*cos(x[8]) + 2*(x[17] - g__1)*(L*x[12]*x[13]*sin(x[5])*m__1 - (2*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/15)*sin(x[8])*sin(x[6])*cos(x[7]) - m__1*(x[12]*x[15]*sin(x[8])*(x[17] - g__1)*sin(x[4]) + 12*x[13]*x[18]*sin(x[6])*sin(x[7]))*sin(x[5])*L/15)*cos(x[6]) + m__1*sin(x[5])*(sin(x[4])*((x[17] - g__1)*x[12]^2 + ((4*x[17])/5 - (4*g__1)/5)*x[13]^2 - (2*x[19])/5)*cos(x[8])^2 + (x[12]*x[14]*sin(x[4])*(x[17] - g__1)*cos(x[7])/15 + x[12]*x[15]*sin(x[6])*sin(x[7])*(x[17] - g__1)*sin(x[4])/15 + (4*x[13]*x[18]*sin(x[8]))/5)*cos(x[8]) - sin(x[4])*((x[17] - g__1)*x[12]^2 + (2*x[17] - 2*g__1)*x[13]^2 - x[19])/5)*L)*cos(x[4])^2 + 18*x[12]*((-(2*L*x[12]*x[18]*sin(x[5])*m__1*(cos(x[7])^2 - 2)*cos(x[8])^2)/3 + 4*(x[17] - g__1)*(cos(x[7])^2 - 2)*sin(x[8])*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/6)*cos(x[8])/3 + m__1*sin(x[5])*x[12]*L*(x[18]*cos(x[7])^2/3 + x[12]*sin(x[7])*sin(x[8])*(x[17] - g__1)*cos(x[7]) - (2*x[18])/3))*cos(x[6])^2 - (-8*(x[17] - g__1)*sin(x[7])*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/6)*cos(x[8])^2/3 + m__1*sin(x[5])*(x[12]*cos(x[7])*(x[17] - g__1) - (4*x[18]*sin(x[7])*sin(x[8]))/3)*x[12]*L*cos(x[8]) + 4*(x[17] - g__1)*sin(x[7])*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/6)/3)*sin(x[6])*cos(x[6]) - (2*L*x[12]*x[18]*cos(x[8])^2*sin(x[5])*m__1)/3 + 4*(x[17] - g__1)*sin(x[8])*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/6)*cos(x[8])/3 + L*x[12]*x[18]*sin(x[5])*m__1/3)*cos(x[4]) - 12*(x[17] - g__1)*m__1*sin(x[4])*sin(x[5])*x[12]^3*L*((cos(x[8])^2 - 1/2)*(cos(x[7])^2 - 2)*cos(x[6])^2 - 2*cos(x[6])*sin(x[7])*cos(x[8])*sin(x[6])*sin(x[8]) + cos(x[8])^2 - 1/2))*cos(x[5])^5 + (-18*m__1*x[13]*L*(((cos(x[7])^2 - 2)*((x[17] - g__1)*x[12]^2 + (x[17]/3 - g__1/3)*x[13]^2 - x[19]/6)*cos(x[8])^2 + ((-2*x[17] + 2*g__1)*x[12]^2 + (-(2*x[17])/3 + (2*g__1)/3)*x[13]^2 + x[19]/3)*cos(x[7])^2 + (4*x[12]*x[18]*cos(x[7])*sin(x[7])*sin(x[8]))/3 + (x[17] - g__1)*x[12]^2 + (x[17]/3 - g__1/3)*x[13]^2 - x[19]/6)*cos(x[6])^2 - 2*((2*x[12]*x[18]*cos(x[7]))/3 + sin(x[7])*sin(x[8])*((x[17] - g__1)*x[12]^2 + (x[17]/3 - g__1/3)*x[13]^2 - x[19]/6))*cos(x[8])*sin(x[6])*cos(x[6]) + cos(x[8])^2*((x[17] - g__1)*x[12]^2 + (x[17]/3 - g__1/3)*x[13]^2 - x[19]/6))*cos(x[4])^5 + ((12*L*sin(x[4])*m__1*x[12]*x[13]*x[18]*(cos(x[7])^2 - 2)*cos(x[8])^2 - 12*m__1*L*(((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*x[12]*sin(x[8])*cos(x[7])^2 - sin(x[7])*(x[12]^2*x[18] + 5/4*x[13]^2*x[18] - 1/6*x[20])*cos(x[7]) - 2*((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*x[12]*sin(x[8]))*cos(x[8]) - 24*L*x[12]*x[13]*x[18]*cos(x[7])^2*sin(x[4])*m__1 - 36*sin(x[7])*(-x[12]*(x[17] - g__1)^2*(m__1 + m__p)*sin(x[5])/9 + m__1*sin(x[4])*x[13]*L*((x[17] - g__1)*x[12]^2 + (x[17]/3 - g__1/3)*x[13]^2 - x[19]/6))*sin(x[8])*cos(x[7]) + 12*L*sin(x[4])*m__1*x[12]*x[13]*x[18])*cos(x[6])^2 + (-24*m__1*((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*sin(x[7])*x[12]*L*sin(x[6])*cos(x[8])^2 + (36*(-x[12]*(x[17] - g__1)^2*(m__1 + m__p)*sin(x[5])/9 + m__1*sin(x[4])*x[13]*L*((x[17] - g__1)*x[12]^2 + (x[17]/3 - g__1/3)*x[13]^2 - x[19]/6))*sin(x[6])*cos(x[7]) - 24*m__1*(x[12]*x[18]*sin(x[4])*sin(x[6])*sin(x[7])*sin(x[8]) - x[13]*x[15]*(x[17] - g__1)/24)*x[13]*L)*cos(x[8]) + 12*m__1*(sin(x[8])*(x[12]^2*x[18] + 5/4*x[13]^2*x[18] - 1/6*x[20])*cos(x[7]) + ((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*sin(x[7])*x[12])*L*sin(x[6]))*cos(x[6]) - 12*m__1*(-x[12]*x[13]*x[18]*cos(x[8])^2*sin(x[4]) + ((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*x[12]*sin(x[8])*cos(x[8]) - x[13]^2*sin(x[8])*(x[17] - g__1)*(sin(x[6])*sin(x[7])*x[15] + x[14]*cos(x[7]))/12)*L)*cos(x[4])^4 + ((63*(cos(x[7])^2 - 2)*(-(2*x[12]*sin(x[4])*(x[17] - g__1)^2*(m__1 + m__p)*sin(x[5]))/63 + m__1*x[13]*L*((x[17] - g__1)*x[12]^2 + ((2*x[17])/7 - (2*g__1)/7)*x[13]^2 - (2*x[19])/21))*cos(x[8])^2 + 12*m__1*sin(x[4])*(sin(x[8])*(x[12]^2*x[18] + 5/4*x[13]^2*x[18] - 1/6*x[20])*cos(x[7])^2 + ((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*sin(x[7])*x[12]*cos(x[7]) - 2*sin(x[8])*(x[12]^2*x[18] + 5/4*x[13]^2*x[18] - 1/6*x[20]))*L*cos(x[8]) + (4*x[12]*sin(x[4])*(x[17] - g__1)^2*(m__1 + m__p)*sin(x[5]) - 63*m__1*((x[17] - g__1)*x[12]^2 - x[19]/21)*x[13]*L)*cos(x[7])^2 + 24*L*x[12]*x[13]*x[18]*cos(x[7])*sin(x[7])*sin(x[8])*m__1 - 2*x[12]*sin(x[4])*(x[17] - g__1)^2*(m__1 + m__p)*sin(x[5]) + 63*m__1*x[13]*L*((x[17] - g__1)*x[12]^2 + ((2*x[17])/7 - (2*g__1)/7)*x[13]^2 - (2*x[19])/21))*cos(x[6])^2 + 12*(2*m__1*sin(x[4])*sin(x[7])*L*(x[12]^2*x[18] + 5/4*x[13]^2*x[18] - 1/6*x[20])*cos(x[8])^2 + (-2*L*x[12]*x[13]*x[18]*cos(x[7])*m__1 - (21*sin(x[7])*(-(2*x[12]*sin(x[4])*(x[17] - g__1)^2*(m__1 + m__p)*sin(x[5]))/63 + m__1*x[13]*L*((x[17] - g__1)*x[12]^2 + ((2*x[17])/7 - (2*g__1)/7)*x[13]^2 - (2*x[19])/21))*sin(x[8]))/2)*cos(x[8]) + m__1*sin(x[4])*(((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*x[12]*sin(x[8])*cos(x[7]) - sin(x[7])*(x[12]^2*x[18] + 5/4*x[13]^2*x[18] - 1/6*x[20]))*L)*sin(x[6])*cos(x[6]) + (-2*x[12]*sin(x[4])*(x[17] - g__1)^2*(m__1 + m__p)*sin(x[5]) + 63*m__1*x[13]*L*((x[17] - g__1)*x[12]^2 + ((2*x[17])/7 - (2*g__1)/7)*x[13]^2 - (2*x[19])/21))*cos(x[8])^2 + 12*m__1*sin(x[4])*L*(x[12]^2*x[18] + 5/4*x[13]^2*x[18] - 1/6*x[20])*sin(x[8])*cos(x[8]) - 27*m__1*x[13]*(-x[13]*x[15]*sin(x[4])*sin(x[6])*(x[17] - g__1)*cos(x[7])/27 + x[13]*x[14]*sin(x[7])*(x[17] - g__1)*sin(x[4])/27 + (x[17] - g__1)*x[12]^2 + ((4*x[17])/9 - (4*g__1)/9)*x[13]^2 - x[19]/9)*L)*cos(x[4])^3 + ((-30*L*sin(x[4])*m__1*x[12]*x[13]*x[18]*(cos(x[7])^2 - 2)*cos(x[8])^2 + 24*m__1*(((x[17] - g__1)*x[12]^2 + ((17*x[17])/8 - (17*g__1)/8)*x[13]^2 - x[19]/4)*x[12]*sin(x[8])*cos(x[7])^2 - (5*sin(x[7])*x[18]*(x[12]^2 - x[13]^2/5)*cos(x[7]))/8 - 2*((x[17] - g__1)*x[12]^2 + ((17*x[17])/8 - (17*g__1)/8)*x[13]^2 - x[19]/4)*x[12]*sin(x[8]))*L*cos(x[8]) + 12*L*x[12]*x[13]*x[18]*cos(x[7])^2*sin(x[4])*m__1 + 45*(x[17] - g__1)*sin(x[7])*(-(4*x[12]*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/45 + L*x[13]*sin(x[4])*m__1*(x[12]^2 - (2*x[13]^2)/15))*sin(x[8])*cos(x[7]) - 30*L*sin(x[4])*m__1*x[12]*x[13]*x[18])*cos(x[6])^2 + (48*m__1*sin(x[7])*((x[17] - g__1)*x[12]^2 + ((17*x[17])/8 - (17*g__1)/8)*x[13]^2 - x[19]/4)*x[12]*L*sin(x[6])*cos(x[8])^2 + (-45*(x[17] - g__1)*(-(4*x[12]*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/45 + L*x[13]*sin(x[4])*m__1*(x[12]^2 - (2*x[13]^2)/15))*sin(x[6])*cos(x[7]) + m__1*(60*x[12]*x[13]*x[18]*sin(x[4])*sin(x[6])*sin(x[7])*sin(x[8]) + x[15]*(x[12] - x[13])*(x[12] + x[13])*(x[17] - g__1))*L)*cos(x[8]) - 24*m__1*((5*x[18]*sin(x[8])*(x[12]^2 - x[13]^2/5)*cos(x[7]))/8 + sin(x[7])*((x[17] - g__1)*x[12]^2 + ((17*x[17])/8 - (17*g__1)/8)*x[13]^2 - x[19]/4)*x[12])*L*sin(x[6]))*cos(x[6]) + 24*m__1*(-(5*x[12]*x[13]*x[18]*cos(x[8])^2*sin(x[4]))/4 + ((x[17] - g__1)*x[12]^2 + ((17*x[17])/8 - (17*g__1)/8)*x[13]^2 - x[19]/4)*x[12]*sin(x[8])*cos(x[8]) + x[14]*sin(x[8])*(x[12] - x[13])*(x[12] + x[13])*(x[17] - g__1)*cos(x[7])/24 + (3*x[12]*x[13]*x[18]*sin(x[4]))/4 + x[15]*sin(x[6])*sin(x[7])*sin(x[8])*(x[12] - x[13])*(x[12] + x[13])*(x[17] - g__1)/24)*L)*cos(x[4])^2 - 18*x[12]*((8*(x[17] - g__1)*(cos(x[7])^2 - 2)*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/12 + L*x[12]*x[13]*m__1)*cos(x[8])^2/3 + m__1*sin(x[4])*((2*x[12]*x[18]*cos(x[7])^2*sin(x[8]))/3 + (x[17] - g__1)*(x[12]^2 - x[13]^2/3)*sin(x[7])*cos(x[7]) - (4*x[12]*x[18]*sin(x[8]))/3)*L*cos(x[8]) - (x[17] - g__1)*((-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/9 + L*x[12]*x[13]*m__1)*cos(x[7])^2 + (2*sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/9 - (8*L*x[12]*x[13]*m__1)/3))*cos(x[6])^2 + ((4*L*x[12]*x[18]*cos(x[8])^2*sin(x[4])*sin(x[7])*m__1)/3 - 16*(x[17] - g__1)*sin(x[7])*sin(x[8])*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/12 + L*x[12]*x[13]*m__1)*cos(x[8])/3 + m__1*sin(x[4])*((x[17] - g__1)*(x[12]^2 - x[13]^2/3)*sin(x[8])*cos(x[7]) - (2*x[12]*x[18]*sin(x[7]))/3)*L)*sin(x[6])*cos(x[6]) + 8*(x[17] - g__1)*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/12 + L*x[12]*x[13]*m__1)*cos(x[8])^2/3 + (2*L*x[12]*x[18]*cos(x[8])*sin(x[4])*sin(x[8])*m__1)/3 - 5*(x[17] - g__1)*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/15 + L*x[12]*x[13]*m__1)/3)*cos(x[4]) - 12*(x[17] - g__1)*m__1*(cos(x[8])*sin(x[8])*(cos(x[7])^2 - 2)*cos(x[6])^2 + 2*(cos(x[8])^2 - 1/2)*sin(x[7])*sin(x[6])*cos(x[6]) + cos(x[8])*sin(x[8]))*x[12]^3*L)*cos(x[5])^4 + (-36*m__1*sin(x[5])*x[13]^2*((-x[18]*(cos(x[7])^2 - 2)*cos(x[8])^2/6 + x[18]*cos(x[7])^2/3 + x[12]*sin(x[7])*sin(x[8])*(x[17] - g__1)*cos(x[7]) - x[18]/6)*cos(x[6])^2 - cos(x[8])*(x[12]*cos(x[7])*(x[17] - g__1) - x[18]*sin(x[7])*sin(x[8])/3)*sin(x[6])*cos(x[6]) - x[18]*cos(x[8])^2/6)*L*cos(x[4])^5 + 36*((((x[17] - g__1)*(cos(x[7])^2 - 2)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/9)*cos(x[8])^2)/2 + m__1*sin(x[5])*((2*x[12]*x[18]*cos(x[7])^2*sin(x[8]))/3 + sin(x[7])*((x[17] - g__1)*x[12]^2 + (x[17]/2 - g__1/2)*x[13]^2 - x[19]/6)*cos(x[7]) - (4*x[12]*x[18]*sin(x[8]))/3)*L*cos(x[8]) - (x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/9)*cos(x[7])^2 + L*x[13]*x[18]*cos(x[7])*sin(x[4])*sin(x[5])*sin(x[7])*sin(x[8])*m__1/3 + ((x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/9))/2)*cos(x[6])^2 + ((4*L*x[12]*x[18]*cos(x[8])^2*sin(x[5])*sin(x[7])*m__1)/3 + (-L*x[13]*x[18]*cos(x[7])*sin(x[4])*sin(x[5])*m__1/3 - (x[17] - g__1)*sin(x[7])*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/9)*sin(x[8]))*cos(x[8]) + m__1*sin(x[5])*L*(sin(x[8])*((x[17] - g__1)*x[12]^2 + (x[17]/2 - g__1/2)*x[13]^2 - x[19]/6)*cos(x[7]) - (2*x[12]*x[18]*sin(x[7]))/3))*sin(x[6])*cos(x[6]) + cos(x[8])*((x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/9)*cos(x[8]) + (4*L*x[12]*x[18]*sin(x[5])*sin(x[8])*m__1)/3)/2)*x[13]*cos(x[4])^4 + ((-6*m__1*sin(x[5])*(cos(x[7])^2 - 2)*L*(x[12]^2*x[18] + 5/2*x[13]^2*x[18] - 1/6*x[20])*cos(x[8])^2 + (36*(m__1*sin(x[4])*x[13]*L*((x[17] - g__1)*x[12]^2 + (x[17]/2 - g__1/2)*x[13]^2 - x[19]/6)*sin(x[5]) - (11*x[12]*(x[17] - g__1)^2*(m__1 + m__p))/36)*sin(x[8])*cos(x[7])^2 - 24*sin(x[7])*x[18]*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/6)*cos(x[7]) - 72*(m__1*sin(x[4])*x[13]*L*((x[17] - g__1)*x[12]^2 + (x[17]/2 - g__1/2)*x[13]^2 - x[19]/6)*sin(x[5]) - (11*x[12]*(x[17] - g__1)^2*(m__1 + m__p))/36)*sin(x[8]))*cos(x[8]) + 3*L*x[13]^2*x[18]*cos(x[7])^2*sin(x[5])*m__1 + 27*(x[17] - g__1)*x[13]*sin(x[7])*(L*x[12]*x[13]*sin(x[5])*m__1 - (4*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/27)*sin(x[8])*cos(x[7]) - 6*m__1*sin(x[5])*L*(x[12]^2*x[18] + 5/2*x[13]^2*x[18] - 1/6*x[20]))*cos(x[6])^2 + (72*(m__1*sin(x[4])*x[13]*L*((x[17] - g__1)*x[12]^2 + (x[17]/2 - g__1/2)*x[13]^2 - x[19]/6)*sin(x[5]) - (11*x[12]*(x[17] - g__1)^2*(m__1 + m__p))/36)*sin(x[7])*sin(x[6])*cos(x[8])^2 + (-27*(x[17] - g__1)*x[13]*(L*x[12]*x[13]*sin(x[5])*m__1 - (4*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/27)*sin(x[6])*cos(x[7]) + 12*m__1*sin(x[7])*L*(x[12]^2*x[18] + 5/2*x[13]^2*x[18] - 1/6*x[20])*sin(x[8])*sin(x[6])*sin(x[5]) + x[15]*(x[17] - g__1)^2*(m__1 + m__p))*cos(x[8]) - 36*((2*x[18]*sin(x[8])*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/6)*cos(x[7]))/3 + (m__1*sin(x[4])*x[13]*L*((x[17] - g__1)*x[12]^2 + (x[17]/2 - g__1/2)*x[13]^2 - x[19]/6)*sin(x[5]) - (11*x[12]*(x[17] - g__1)^2*(m__1 + m__p))/36)*sin(x[7]))*sin(x[6]))*cos(x[6]) - 6*m__1*sin(x[5])*L*(x[12]^2*x[18] + 5/2*x[13]^2*x[18] - 1/6*x[20])*cos(x[8])^2 + 36*(m__1*sin(x[4])*x[13]*L*((x[17] - g__1)*x[12]^2 + (x[17]/2 - g__1/2)*x[13]^2 - x[19]/6)*sin(x[5]) - (11*x[12]*(x[17] - g__1)^2*(m__1 + m__p))/36)*sin(x[8])*cos(x[8]) + x[14]*sin(x[8])*(x[17] - g__1)^2*(m__1 + m__p)*cos(x[7]) + 6*m__1*(x[12]^2*x[18] + 3/2*x[13]^2*x[18] - 1/6*x[20])*L*sin(x[5]) + x[15]*sin(x[6])*sin(x[7])*sin(x[8])*(x[17] - g__1)^2*(m__1 + m__p))*cos(x[4])^3 + ((-6*(cos(x[7])^2 - 2)*(m__1*sin(x[4])*x[12]*((x[17] - g__1)*x[12]^2 + ((15*x[17])/2 - (15*g__1)/2)*x[13]^2 - x[19]/2)*L*sin(x[5]) - (11*x[13]*(x[17] - g__1)^2*(m__1 + m__p))/6)*cos(x[8])^2 + (-24*(L*x[12]*x[13]*sin(x[5])*m__1 - sin(x[4])*(m__1 + m__p)*(x[17] - g__1)/6)*x[18]*sin(x[8])*cos(x[7])^2 - 42*(x[17] - g__1)*(L*x[13]*m__1*(x[12]^2 - x[13]^2/7)*sin(x[5]) - (11*x[12]*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/42)*sin(x[7])*cos(x[7]) + 48*(L*x[12]*x[13]*sin(x[5])*m__1 - sin(x[4])*(m__1 + m__p)*(x[17] - g__1)/6)*x[18]*sin(x[8]))*cos(x[8]) + 9*(x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 + 5*(m__1 + m__p)*(x[17] - g__1)/9)*x[13]*cos(x[7])^2 + 3*L*x[13]^2*x[18]*cos(x[7])*sin(x[4])*sin(x[5])*sin(x[7])*sin(x[8])*m__1 - 6*m__1*sin(x[4])*x[12]*((x[17] - g__1)*x[12]^2 + ((15*x[17])/2 - (15*g__1)/2)*x[13]^2 - x[19]/2)*L*sin(x[5]) + 11*x[13]*(x[17] - g__1)^2*(m__1 + m__p))*cos(x[6])^2 + (-48*(L*x[12]*x[13]*sin(x[5])*m__1 - sin(x[4])*(m__1 + m__p)*(x[17] - g__1)/6)*sin(x[7])*x[18]*sin(x[6])*cos(x[8])^2 + 12*(-L*x[13]^2*x[18]*cos(x[7])*sin(x[4])*sin(x[5])*m__1/4 + sin(x[7])*(m__1*sin(x[4])*x[12]*((x[17] - g__1)*x[12]^2 + ((15*x[17])/2 - (15*g__1)/2)*x[13]^2 - x[19]/2)*L*sin(x[5]) - (11*x[13]*(x[17] - g__1)^2*(m__1 + m__p))/6)*sin(x[8]))*sin(x[6])*cos(x[8]) - 42*(x[17] - g__1)*(L*x[13]*m__1*(x[12]^2 - x[13]^2/7)*sin(x[5]) - (11*x[12]*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/42)*sin(x[8])*sin(x[6])*cos(x[7]) + 24*m__1*(-x[13]*x[15]*sin(x[8])*(x[17] - g__1)*sin(x[4])/24 + x[12]*x[18]*sin(x[6])*sin(x[7]))*x[13]*L*sin(x[5]) - 4*x[18]*sin(x[4])*sin(x[6])*sin(x[7])*(m__1 + m__p)*(x[17] - g__1))*cos(x[6]) + (-6*m__1*sin(x[4])*x[12]*((x[17] - g__1)*x[12]^2 + ((15*x[17])/2 - (15*g__1)/2)*x[13]^2 - x[19]/2)*L*sin(x[5]) + 11*x[13]*(x[17] - g__1)^2*(m__1 + m__p))*cos(x[8])^2 + (L*x[13]^2*x[14]*sin(x[4])*sin(x[5])*m__1*(x[17] - g__1)*cos(x[7]) - 24*m__1*(-x[13]*x[15]*sin(x[6])*sin(x[7])*(x[17] - g__1)*sin(x[4])/24 + x[12]*x[18]*sin(x[8]))*x[13]*L*sin(x[5]) + 4*x[18]*sin(x[4])*sin(x[8])*(m__1 + m__p)*(x[17] - g__1))*cos(x[8]) + x[15]*sin(x[4])*sin(x[6])*(x[17] - g__1)^2*(m__1 + m__p)*cos(x[7]) + 6*m__1*sin(x[4])*((x[17] - g__1)*x[12]^2 + ((9*x[17])/2 - (9*g__1)/2)*x[13]^2 - x[19]/2)*x[12]*L*sin(x[5]) - 9*(x[17] - g__1)^2*(x[14]*sin(x[4])*sin(x[7])/9 + x[13])*(m__1 + m__p))*cos(x[4])^2 + ((6*L*sin(x[5])*m__1*x[12]^2*x[18]*(cos(x[7])^2 - 2)*cos(x[8])^2 - 36*(x[17] - g__1)*((L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*x[12]*sin(x[8])*cos(x[7])^2 - x[18]*sin(x[7])*(m__1 + m__p)*cos(x[7])/9 - 2*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*x[12]*sin(x[8]))*cos(x[8]) + 6*(x[17] - g__1)*x[13]*sin(x[7])*(L*x[12]*x[13]*sin(x[5])*m__1 - (7*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/6)*sin(x[8])*cos(x[7]) + 6*L*sin(x[5])*m__1*x[12]^2*x[18])*cos(x[6])^2 + (-72*(x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*sin(x[7])*x[12]*sin(x[6])*cos(x[8])^2 + (-6*(x[17] - g__1)*x[13]*(L*x[12]*x[13]*sin(x[5])*m__1 - (7*sin(x[4])*(m__1 + m__p)*(x[17] - g__1))/6)*sin(x[6])*cos(x[7]) - 12*L*x[12]^2*x[18]*sin(x[5])*sin(x[6])*sin(x[7])*sin(x[8])*m__1 - x[15]*(x[17] - g__1)^2*(m__1 + m__p))*cos(x[8]) + 36*(x[17] - g__1)*(x[18]*sin(x[8])*(m__1 + m__p)*cos(x[7])/9 + (L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*sin(x[7])*x[12])*sin(x[6]))*cos(x[6]) + 6*L*sin(x[5])*cos(x[8])^2*m__1*x[12]^2*x[18] - 36*(x[17] - g__1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - 2*(m__1 + m__p)*(x[17] - g__1)/9)*x[12]*sin(x[8])*cos(x[8]) - x[14]*sin(x[8])*(x[17] - g__1)^2*(m__1 + m__p)*cos(x[7]) - 6*L*sin(x[5])*m__1*x[12]^2*x[18] - x[15]*sin(x[6])*sin(x[7])*sin(x[8])*(x[17] - g__1)^2*(m__1 + m__p))*cos(x[4]) + 6*(x[17] - g__1)*sin(x[4])*x[12]*((L*x[12]^2*sin(x[5])*m__1*(cos(x[7])^2 - 2)*cos(x[8])^2 + (7*cos(x[7])*sin(x[7])*(m__1 + m__p)*(x[17] - g__1)*cos(x[8]))/6 + L*x[12]^2*sin(x[5])*m__1)*cos(x[6])^2 - 2*(L*x[12]^2*cos(x[8])*sin(x[5])*sin(x[7])*m__1 - (7*cos(x[7])*(m__1 + m__p)*(x[17] - g__1))/12)*sin(x[8])*sin(x[6])*cos(x[6]) + L*x[12]^2*sin(x[5])*m__1*(cos(x[8]) - 1)*(cos(x[8]) + 1)))*cos(x[5])^3 + (6*(((cos(x[7])^2 - 2)*cos(x[8])^2 - 2*cos(x[7])^2 + 1)*cos(x[6])^2 - 2*cos(x[6])*sin(x[7])*cos(x[8])*sin(x[6])*sin(x[8]) + cos(x[8])^2)*(x[17] - g__1)*m__1*x[13]^3*L*cos(x[4])^5 + 36*m__1*x[13]^2*(((x[12]*sin(x[8])*(x[17] - g__1)*cos(x[7])^2 - x[18]*cos(x[7])*sin(x[7])/3 - 2*x[12]*sin(x[8])*(x[17] - g__1))*cos(x[8]) + x[13]*cos(x[7])*sin(x[4])*sin(x[7])*sin(x[8])*(x[17] - g__1)/3)*cos(x[6])^2 + 2*(x[12]*sin(x[7])*(x[17] - g__1)*cos(x[8])^2 - x[13]*sin(x[4])*cos(x[7])*(x[17] - g__1)*cos(x[8])/6 - x[18]*cos(x[7])*sin(x[8])/6 - x[12]*sin(x[7])*(x[17] - g__1)/2)*sin(x[6])*cos(x[6]) + x[12]*cos(x[8])*sin(x[8])*(x[17] - g__1))*L*cos(x[4])^4 - 18*x[13]*((m__1*((x[17] - g__1)*x[12]^2 + ((7*x[17])/6 - (7*g__1)/6)*x[13]^2 - x[19]/6)*(cos(x[7])^2 - 2)*L*cos(x[8])^2 + ((2*L*x[13]*x[18]*cos(x[7])^2*sin(x[4])*sin(x[8])*m__1)/3 + 2*(x[17] - g__1)*(-11*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/36 + L*x[12]*x[13]*sin(x[4])*m__1)*sin(x[7])*cos(x[7]) - (4*L*x[13]*x[18]*sin(x[4])*sin(x[8])*m__1)/3)*cos(x[8]) + m__1*(((x[17] - g__1)*x[13]^2*cos(x[7])^2)/6 + (x[17] - g__1)*x[12]^2 + ((7*x[17])/6 - (7*g__1)/6)*x[13]^2 - x[19]/6)*L)*cos(x[6])^2 - 2*(-(2*L*x[13]*x[18]*cos(x[8])^2*sin(x[4])*sin(x[7])*m__1)/3 + m__1*((x[17] - g__1)*x[12]^2 + ((7*x[17])/6 - (7*g__1)/6)*x[13]^2 - x[19]/6)*sin(x[7])*L*sin(x[8])*cos(x[8]) - (x[17] - g__1)*(-11*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/36 + L*x[12]*x[13]*sin(x[4])*m__1)*sin(x[8])*cos(x[7]) + L*x[13]*x[18]*sin(x[4])*sin(x[7])*m__1/3)*sin(x[6])*cos(x[6]) + (((x[17] - g__1)*x[12]^2 + ((7*x[17])/6 - (7*g__1)/6)*x[13]^2 - x[19]/6)*cos(x[8])^2 + (2*x[13]*x[18]*cos(x[8])*sin(x[4])*sin(x[8]))/3 + (g__1 - x[17])*x[12]^2 + (-(5*x[17])/6 + (5*g__1)/6)*x[13]^2 + x[19]/6)*m__1*L)*cos(x[4])^3 + ((12*(-((m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/3 + L*x[12]*x[13]*sin(x[4])*m__1)*(cos(x[7])^2 - 2)*x[18]*cos(x[8])^2 - 36*x[13]*((x[17] - g__1)*sin(x[8])*(-(11*sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/36 + L*x[12]*x[13]*m__1)*cos(x[7])^2 + L*x[13]*x[18]*cos(x[7])*sin(x[7])*m__1/12 - 2*(x[17] - g__1)*sin(x[8])*(-(11*sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/36 + L*x[12]*x[13]*m__1))*cos(x[8]) - 4*x[18]*sin(x[5])*(m__1 + m__p)*(x[17] - g__1)*cos(x[7])^2 + 9*(x[17] - g__1)*(-(10*x[12]*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/9 + L*x[13]^3*sin(x[4])*m__1)*sin(x[7])*sin(x[8])*cos(x[7]) + 12*(-((m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/3 + L*x[12]*x[13]*sin(x[4])*m__1)*x[18])*cos(x[6])^2 + (-72*(x[17] - g__1)*x[13]*sin(x[7])*(-(11*sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/36 + L*x[12]*x[13]*m__1)*sin(x[6])*cos(x[8])^2 + (-9*(x[17] - g__1)*(-(10*x[12]*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/9 + L*x[13]^3*sin(x[4])*m__1)*sin(x[6])*cos(x[7]) + 8*x[18]*sin(x[6])*sin(x[7])*sin(x[8])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]) - 24*m__1*(x[12]*x[18]*sin(x[4])*sin(x[6])*sin(x[7])*sin(x[8]) - x[13]*x[15]*(x[17] - g__1)/24)*x[13]*L)*cos(x[8]) + 36*(-L*x[13]*x[18]*cos(x[7])*sin(x[8])*m__1/12 + (x[17] - g__1)*sin(x[7])*(-(11*sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/36 + L*x[12]*x[13]*m__1))*x[13]*sin(x[6]))*cos(x[6]) + 12*(-((m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/3 + L*x[12]*x[13]*sin(x[4])*m__1)*x[18]*cos(x[8])^2 - 36*(x[17] - g__1)*x[13]*sin(x[8])*(-(11*sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5]))/36 + L*x[12]*x[13]*m__1)*cos(x[8]) + L*x[13]^2*x[14]*sin(x[8])*m__1*(x[17] - g__1)*cos(x[7]) + 4*x[18]*sin(x[5])*(m__1 + m__p)*(x[17] - g__1) - 12*m__1*x[13]*L*(x[12]*x[18]*sin(x[4]) - x[13]*x[15]*sin(x[6])*sin(x[7])*sin(x[8])*(x[17] - g__1)/12))*cos(x[4])^2 + 18*(x[17] - g__1)*(((cos(x[7])^2 - 2)*x[12]*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/3 + L*x[12]*x[13]*m__1)*cos(x[8])^2 - ((-7*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/6 + L*x[12]*x[13]*sin(x[4])*m__1)*x[13]*sin(x[7])*cos(x[7])*cos(x[8]))/3 - (5*x[12]*sin(x[4])*sin(x[5])*(m__1 + m__p)*(x[17] - g__1)*cos(x[7])^2)/9 + (2*x[18]*sin(x[4])*sin(x[5])*sin(x[7])*sin(x[8])*(m__1 + m__p)*cos(x[7]))/9 + x[12]*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/3 + L*x[12]*x[13]*m__1))*cos(x[6])^2 + (-2*(x[18]*sin(x[4])*sin(x[5])*(m__1 + m__p)*cos(x[7])/9 + sin(x[7])*x[12]*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/3 + L*x[12]*x[13]*m__1)*sin(x[8]))*sin(x[6])*cos(x[8]) - (((-7*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/6 + L*x[12]*x[13]*sin(x[4])*m__1)*x[13]*sin(x[6])*cos(x[7]) + x[15]*sin(x[4])*sin(x[5])*(m__1 + m__p)*(x[17] - g__1)/6)*sin(x[8]))/3)*cos(x[6]) + x[12]*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/3 + L*x[12]*x[13]*m__1)*cos(x[8])^2 + sin(x[4])*sin(x[5])*(m__1 + m__p)*(x[17] - g__1)*(sin(x[6])*sin(x[7])*x[15] + x[14]*cos(x[7]))*cos(x[8])/18 - x[12]*(-sin(x[4])*(m__1 + m__p)*(x[17] - g__1)*sin(x[5])/3 + L*x[12]*x[13]*m__1))*cos(x[4]) + 7*x[12]*cos(x[6])*cos(x[7])*sin(x[5])*(x[17] - g__1)^2*(m__1 + m__p)*(cos(x[6])*sin(x[7])*sin(x[8]) - sin(x[6])*cos(x[8])))*cos(x[5])^2 + (-12*L*x[13]^3*cos(x[6])*cos(x[7])*sin(x[5])*m__1*(cos(x[6])*sin(x[7])*cos(x[8]) + sin(x[6])*sin(x[8]))*(x[17] - g__1)*cos(x[4])^4 - 12*m__1*sin(x[5])*x[13]^2*(((-x[18]*cos(x[7])^2/2 + x[18])*cos(x[8])^2 + x[13]*sin(x[4])*sin(x[8])*(cos(x[7])^2 - 2)*(x[17] - g__1)*cos(x[8]) - x[18]/2)*cos(x[6])^2 + 2*(x[13]*sin(x[4])*(x[17] - g__1)*cos(x[8])^2 + x[18]*cos(x[8])*sin(x[8])/2 - x[13]*sin(x[4])*(x[17] - g__1)/2)*sin(x[7])*sin(x[6])*cos(x[6]) - x[18]*cos(x[8])^2/2 + x[13]*sin(x[4])*sin(x[8])*(x[17] - g__1)*cos(x[8]) + x[18]/2)*L*cos(x[4])^3 + 18*(x[17] - g__1)*x[13]*(((L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/3)*(cos(x[7])^2 - 2)*cos(x[8])^2 - L*x[13]^2*cos(x[7])*cos(x[8])*sin(x[5])*sin(x[7])*m__1/3 - 5*(m__1 + m__p)*(x[17] - g__1)*cos(x[7])^2/9 + L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/3)*cos(x[6])^2 - 2*sin(x[8])*((L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/3)*sin(x[7])*cos(x[8]) + L*x[13]^2*cos(x[7])*sin(x[5])*m__1/6)*sin(x[6])*cos(x[6]) + (cos(x[8]) + 1)*(L*x[12]*x[13]*sin(x[4])*sin(x[5])*m__1 - ((m__1 + m__p)*(x[17] - g__1))/3)*(cos(x[8]) - 1))*cos(x[4])^2 + 10*(x[17] - g__1)*(sin(x[7])*cos(x[7])*(-(2*x[18]*cos(x[8]))/5 + x[13]*sin(x[4])*sin(x[8])*(x[17] - g__1))*cos(x[6])^2 + (-(x[17] - g__1)*(x[13]*cos(x[7])*sin(x[4])*sin(x[6]) - x[15]/10)*cos(x[8]) - (2*x[18]*cos(x[7])*sin(x[6])*sin(x[8]))/5)*cos(x[6]) + sin(x[8])*(x[17] - g__1)*(sin(x[6])*sin(x[7])*x[15] + x[14]*cos(x[7]))/10)*(m__1 + m__p)*cos(x[4]) - 7*x[12]*cos(x[6])*cos(x[7])*sin(x[4])*(x[17] - g__1)^2*(m__1 + m__p)*(cos(x[6])*sin(x[7])*cos(x[8]) + sin(x[6])*sin(x[8])))*cos(x[5]) + 6*(x[17] - g__1)*cos(x[4])*x[13]*(((1 + (cos(x[7])^2 - 2)*cos(x[8])^2)*cos(x[6])^2 - 2*cos(x[6])*sin(x[7])*cos(x[8])*sin(x[6])*sin(x[8]) + cos(x[8])^2 - 1)*m__1*x[13]^2*L*cos(x[4])^2 - (7*cos(x[6])*cos(x[7])*sin(x[5])*(m__1 + m__p)*(cos(x[6])*sin(x[7])*cos(x[8]) + sin(x[6])*sin(x[8]))*(x[17] - g__1))/6))/(cos(x[4])^4*m__1*(((((cos(x[7])^2 - 2)*cos(x[8])^2 - 2*cos(x[7])^2 + 1)*cos(x[6])^2 - 2*cos(x[6])*sin(x[7])*cos(x[8])*sin(x[6])*sin(x[8]) + cos(x[8])^2)*cos(x[4])^2 + 2*cos(x[6])*cos(x[7])*sin(x[4])*(cos(x[6])*sin(x[7])*sin(x[8]) - sin(x[6])*cos(x[8]))*cos(x[4]) - 2*(cos(x[8])^2 - 1/2)*(cos(x[7])^2 - 2)*cos(x[6])^2 + 4*cos(x[6])*sin(x[7])*cos(x[8])*sin(x[6])*sin(x[8]) - 2*cos(x[8])^2 + 1)*cos(x[5])^2 - 2*sin(x[5])*(cos(x[6])*cos(x[7])*(cos(x[6])*sin(x[7])*cos(x[8]) + sin(x[6])*sin(x[8]))*cos(x[4]) + sin(x[4])*(cos(x[8])*sin(x[8])*(cos(x[7])^2 - 2)*cos(x[6])^2 + 2*(cos(x[8])^2 - 1/2)*sin(x[7])*sin(x[6])*cos(x[6]) + cos(x[8])*sin(x[8])))*cos(x[5]) + (1 + (cos(x[7])^2 - 2)*cos(x[8])^2)*cos(x[6])^2 - 2*cos(x[6])*sin(x[7])*cos(x[8])*sin(x[6])*sin(x[8]) + cos(x[8])^2 - 1)*L*cos(x[5])^4)

This worksheet displays an ellipsoid internally tangent to the four sides of a tetrahedron.

The tetrahedron is a special case: it has a horizontal base with vertices A,B and C and its fourth vertex E is on the z axis.

However I have failed when trying to display an internally tangent ellipsoid in any other tetrahedron.

Will any tetrahedron support one or more internally tangent ellipsoids?

If so, are there conditions restricting the location of the mutual points of tangency?

Ellipsoid_in_a_tetrahedron.mw

Maple 2021.1/Windows 10.

When entering 2d expressions into the bottom line of a worksheet, i.e. at the bottom of the window, I can't see the underscores used to indicate bracketing.

A workaround is to use ^J to get another input prompt at the bottom of the window.

Is there some way to get a bigger margin at the bottom of the window?

Cheers,

Steve.

The square root of x+8-square root of x+9-square root of 2x+4

restart;
with(plots); with(LinearAlgebra);
_EnvHorizontalName := 'x';

_EnvVerticalName := 'y';

x1,y1,x2,y2,x3,y3:=0,-3,3,1,5,-2:   
A := [x1, y1]: B := [x2, y2]: C := [x3, y3]:

Barycentre := proc (A, B, t) description "Barycentre de 2 points A(1) et B(t) dans le rapport t";
return [(1-t)*A[1]+t*B[1], (1-t)*A[2]+t*B[2]] end proc;
ellip := proc (r1, r2) local a, b, c, d, e, f, D, E, F, eq1, eq2, eq3, eq4, eq5, eq6, x0, y0, EE, r3, sol, Ff, Tg;
global A, B, C;
r3 := -1/(r2*r1);
D := Barycentre(C, B, 1/(1-r1)); E := Barycentre(A, C, 1/(1-r2)); F := Barycentre(B, A, 1/(1-r3));
Ff := proc (x, y) options operator, arrow; a*x^2+2*b*x*y+c*y^2+2*d*x+2*e*y+f end proc;
Tg := proc (x0, y0, x, y) options operator, arrow; a*x*x0+b*(x*y0+y*x0)+c*y*y0+d*(x+x0)+e*(y+y0)+f end proc;
eq1 := Ff(D[1], D[2]);
eq2 := Ff(E[1], E[2]);
eq3 := Ff(F[1], F[2]);
eq4 := Tg(F[1], F[2], x1, y1);
eq5 := Tg(D[1], D[2], x2, y2);
eq6 := Tg(E[1], E[2], x3, y3);
sol := op(solve([eq1, eq2, eq3, eq4, eq5, eq6], [a, b, c, d, e]));
assign(sol);
EE := subs(f = 1, Ff(x, y) = 0) end proc;

ellip(-1, -7); tri := plot([A, B, C, A], color = blue):
 
po := plot([A, B, C], style = point, symbolsize = 15, symbol = solidcircle, color = red);
tp := textplot([[A[], "A"], [B[], "B"], [C[], "C"]], 'align' = {'above', 'left'});
x := 'x'; y := 'y';
ELL := seq(implicitplot(ellip(-7/11-(1/11)*j, -1/17-3*j*(1/17)), x = 0 .. 5, y = -3 .. 1, color = ColorTools:-Color([rand()/10^12, rand()/10^12, rand()/10^12])), j = 1 .. 17);
display([tri, ELL, po, tp], view = [-.5 .. 5.5, -4 .. 1.5], axes = none, scaling = constrained, size = [500, 500]);
Explore(implicitplot(ellip(r1, r2), x = 0 .. 5, y = -3 .. 1), parameters = [r1 = -2.18 .. -.7, r2 = -3 .. -.23]);
Can you tell me why this last instruction does't work ? Thank you.
 

I rewrite my code with Grid library using local vCPU of amazon 

discover no license of distributed HPC when setup command show need go to acresso.com

can Grid still be used and function with local 96 number of vCPU?

then when I test code, I can not pkill mserver in ps -aux in LInux 

can the performance really improved ? Because I suppose 3 to 5 minutes mserver will end and disappear from ps -aux but grid node of mserver still running

originally I can run 100 batches every day., but I have to monitor decrease of memory in order to determine whether can kill mserver for next batch 

I expect run 400 batches per day. But Can not kill mserver when using grid

In my code I had using time limit(30, ...) 

when using Grid seq of function , can lprint work normally to get results into text ?

i notice Grid up to 57, do I need to recalculate and revise code to fit 96 vCPU for grid number 96?

Hi MaplePrimes team,

 

I am aware that Maple is not designed for CAD and I am not here for you to help me build any advanced system like the example below.

 

Figure 1: Trimmed surface of fuselage to create airplane windows.

 

Here I my problem. Even using the adaptmesh option, creating serious trimmed surfaces requires large numbers of grids like for example [3000, 3000] and even beyond, which makes a mesh unnecessary on most of the surface and especially where we don’t need high resolution.

While if we limit the display volume with the Maple’s view command (view = [x1..x2, y1..y2, z1..z2]), the edges are always smooth regardless of the coordinates system or the type of mesh of the surface to be treated.

 

And so, the reason I’m writing this message is to ask you why creating trimmed surface with plot3d surface wouldn’t use Maple view’s algorithm to get smooth edges?

 

Future Alternative Solution:

I also take this opportunity to ask you when would it be possible to update the Maple’s grid option such that the point space will variable in term of surface variable. For example:

plot3d(<x(s,t), y(s,t), z(s,t)>, s = s1..s2, t = t1..t2, grid = [m(s,t), n(s,t)] )

 

I am sure that this solution, which for me does not seem to be difficult to implement, could be an alternative to enrich the mesh where we really need it and therefore a better control. What do you think?

 

Thank you in advance.

 

Best.

 

Guy.

First 10 11 12 13 14 15 16 Last Page 12 of 1924