Maple 2021 Questions and Posts

These are Posts and Questions associated with the product, Maple 2021

restart;
with(geometry);
with(plots);
_EnvHorizontalName = 'x';
_EnvVerticalName = 'y';
Vdot := proc(U, V) local i; add(U[i]*V[i], i = 1 .. 2); end proc;
dist := proc(M, N) sqrt(Vdot(M - N, M - N)); end proc;
EQ := proc(M, N) local eq, a, b, c; eq := simplify(expand((y - M[2])/(x - M[1]) - (N[2] - M[2])/(N[1] - M[1]))*(x - P1[1])*(P2[1] - P1[1])); a := coeff(eq, x); b := coeff(eq, y); c := tcoeff(eq, [x, y]); RETURN(-a*x/c - b*y/c - 1); end proc;
R := 5;
ang := [2/3*Pi, -3*Pi*1/4, -Pi*1/6];
seq(point(`||`(P, i), [R*cos(ang[i]), R*sin(ang[i])]), i = 1 .. 3);
seq(dsegment(`||`(seg, i), [`||`(P, i), `||`(P, irem(i, 3) + 1)]), i = 1 .. 3);
circle(cir, [point(OO, [0, 0]), R]);
sol := solve(subs(x = 2, Equation(cir, [x, y])), y);
point(A, [2, sol[1]]);
triangle(Tri, [P1, P2, P3]);
incircle(inc, Tri, 'centername' = oo);
circle(Cr, [A, oo]);
sol := solve({Equation(Cr, [x, y]), Equation(inc, [x, y])}, {x, y});
point(H1, [subs(sol, x), subs(sol, y)]);
line(L, [A, oo]);
reflection(H2, H1, L);
line(L1, [A, H1]);
line(L2, [A, H2]);
Equation(cir, [x, y]);
Equation(L1, [x, y]);
sol := solve({Equation(L1, [x, y]), Equation(cir, [x, y])}, {x, y});
evalf(%);
point(M1, [subs(sol, x), subs(sol, y)]);
sol2 := solve({Equation(L2, [x, y]), Equation(cir, [x, y])}, {x, y});
evalf(%);
point(M2, [subs(sol2, x), subs(sol2, y)]);
triangle(TR, [M1, M2, A]);
display([draw([P1(symbol = solidcircle, symbolsize = 8, color = blue), P2(symbol = solidcircle, symbolsize = 8, color = blue), P3(symbol = solidcircle, symbolsize = 8, color = blue), A(symbol = solidcircle, symbolsize = 8, color = black), H1(symbol = solidcircle, symbolsize = 8, color = black), H2(symbol = solidcircle, symbolsize = 8, color = black), L1(color = black), L2(color = black), seg1(color = magenta), seg2(color = magenta), seg3(color = magenta), Cr(color = black), cir(color = magenta), inc(color = blue)]), textplot([seq([coordinates(`||`(P, i))[], convert(`||`(P, i), string)], i = 1 .. 3)], 'align' = {'above', 'left'})], view = [-6 .. 10, -15 .. 6], scaling = constrained, size = [800, 800], axes = none);
It seems that there is conusion between M1 and M2. How to write letters A, M1 ,M2, H1, H2 ? Thank you.

How do I plot a volume of revolution? I can plot other volumes using Student[Calculus1]]:-VolumeOfRevolution, but not this one. I get a blank plot. I do get the correct volume from output=value..

How do I plot this using plot3d?

restart;
a := 0; b := 1;
f := (x) -> x^2+2;
g := (x) -> 1/2*x+1;
V := int(f(x)^2 - g(x)^2,x=a..b)*Pi;
Student[Calculus1]:-VolumeOfRevolution(f(x),g(x),x=a..b,output=value);
Student[Calculus1]:-VolumeOfRevolution(f(x),g(x),x=a..b,output=plot);
 

Hello,

I have been trying to figure this out for a long time and can't find anyone else having the same problem.

I use the built-in unit system for assigned values (short-cut is Ctrl+Shift+u) a lot when doing electronics calculations and electromagnetism, so I often use resistances and therefore need to use Ohm. This is very often an option in the "Choose Unit" drop-down menu on the right, but when too many units are brought into the same calculation the option dissappear. Usually I the go to the "Enter Unit" menu as to write the unit out myself I cannot figure out a way for it to accept greek letters. Does anyone know what to do?

Hi Everyone,

I intend to find the invariants of a 2nd-order Tensor using the representation of the rotational group as an Infinitesimal generator. However, maple does not seem to find the correct invariants $\tr \mathbf{a}$, $\tr \mathbf{a}^2$, $\tr \mathbf{a}^3$. Maple only returns an empty set. I can't seem to figure out why that is the case.

Here is my code

NULL

restart

with(PDETools)

assume(r >= 0)

interface(showassumed = 0)

X_z2 := (-a__21-a__12)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__11))+(a__11-a__22)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__12))-a__23*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__13))+(a__11-a__22)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__21))+(a__12+a__21)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__22))+a__13*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__23))-a__32*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__31))+a__31*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__32)) = 0

(-a__21-a__12)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__11))+(a__11-a__22)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__12))-a__23*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__13))+(a__11-a__22)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__21))+(a__12+a__21)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__22))+a__13*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__23))-a__32*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__31))+a__31*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__32)) = 0

(1)

X_y2 := (-a__31-a__13)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__11))-a__32*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__12))+(a__11-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__13))-a__23*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__21))+a__21*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__23))+(a__11-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__31))+a__12*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__32))+(a__13+a__31)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__33)) = 0

(-a__31-a__13)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__11))-a__32*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__12))+(a__11-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__13))-a__23*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__21))+a__21*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__23))+(a__11-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__31))+a__12*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__32))+(a__13+a__31)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__33)) = 0

(2)

X_x2 := -a__13*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__12))+a__12*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__13))-a__31*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__21))+(-a__32-a__23)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__22))+(a__22-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__23))+a__21*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__31))+(a__22-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__32))+(a__23+a__32)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__33)) = 0

-a__13*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__12))+a__12*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__13))-a__31*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__21))+(-a__32-a__23)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__22))+(a__22-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__23))+a__21*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__31))+(a__22-a__33)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__32))+(a__23+a__32)*(diff(f_1(x, y, z, a__11, a__12, a__13, a__21, a__22, a__23, a__31, a__32, a__33), a__33)) = 0

(3)

sys := [X_z2, X_y2, X_x2]

sol := pdsolve(sys)

(4)

NULL

Download SO(3)_spherical_2.mw

Any input would be appreciated!

 A:= <x1,y1,z1>:  B:= <x2,y2,z2>:  P :=<x3, y3, z3>:  H:=A+t*(B-A):  solve( (P-H)^+ . (B-A), t ):  'H'=eval(H, t=`%` );

Error, invalid powe, rhow to overcome this mistake ? Thank you.
Typesetting:-mambiguous( AAssign (x1commay1commaz1)colon  BAssign 

  (x2commay2commaz2)colon  P Assign(x3comma y3comma z3)colon  H

  AssignA + tast(Buminus0A)colon  solveApplyFunction( 

  Typesetting:-mambiguous((Puminus0H)circ + , 

  Typesetting:-merror("invalid power")) period (Buminus0A)comma t

   )colon  (H)equalsevalApplyFunction(Hcomma tequals% )semi)

                                                                                  Théorème de Brianchon
restart; with(plots):unprotect(gamma):
Error, missing operator or `;`
##Si un hexagone est circonscrit à un cercle, les droites qui joignent les sommets opposés passent par un même point.
_EnvHorizontalName := 'x';_EnvVerticalName := 'y';
                    _EnvHorizontalName := x

                     _EnvVerticalName := y

line := proc (x1, y1, x2, y2) options operator, arrow; (x-x1)*(y2-y1)-(y-y1)*(x2-x1) end proc:
R := 3:
ang := [0, (1/3)*Pi, 3*Pi*(1/4)+.2, 7*Pi*(1/6)+.4, 8*Pi*(1/5), 13*Pi*(1/7)]:
for i to 6 do P || i := [R*cos(ang[i]), R*sin(ang[i])] end do:
pts := [seq(P || i, i = 1 .. 6)]:
for i to 6 do tang || i := x*P || i[1]+y*P || i[2] = R^2 end do:
sol:=solve({tang1,tang3},{x,y}):Q13:=[subs(sol,x),subs(sol,y)]:
sol := solve({tang1, tang2}, {x, y}): Q1 := [subs(sol, x), subs(sol, y)]:
sol := solve({tang2, tang3}, {x, y}): Q2 := [subs(sol, x), subs(sol, y)]:
sol := solve({tang3, tang4}, {x, y}): Q3 := [subs(sol, x), subs(sol, y)]:
sol := solve({tang4, tang5}, {x, y}): Q4 := [subs(sol, x), subs(sol, y)]:
sol := solve({tang5, tang6}, {x, y}): Q5 := [subs(sol, x), subs(sol, y)]:
sol := solve({tang1, tang6}, {x, y}): Q6 := [subs(sol, x), subs(sol, y)]:
ptQ := [seq(Q || i, i = 1 .. 6)]:
line14 := line(Q1[1], Q1[2], Q4[1], Q4[2]): L14 := implicitplot(line14, x = -10 .. 10, y = -10 .. 10, color = red):
line25 := line(Q2[1], Q2[2], Q5[1], Q5[2]): L25 := implicitplot(line25, x = -10 .. 10, y = -10 .. 10, color = red):
line36 := line(Q3[1], Q3[2], Q6[1], Q6[2]): L36 := implicitplot(line36, x = -10 .. 10, y = -10 .. 10, color = red):
sol := solve({line14, line25}, {x, y}): I1 := [subs(sol, x), subs(sol, y)]:

lineP23 := line(P2[1], P2[2], P3[1], P3[2]): lineP56 := line(P5[1], P5[2], P6[1], P6[2]):
sol := solve({lineP23, lineP56}, {x, y}): gamma := [subs(sol, x), subs(sol, y)]:
Error, attempting to assign to `gamma` which is protected.  Try declaring `local gamma`; see ?protect for details.
lineP12 := line(P1[1], P1[2], P2[1], P2[2]): lineP45 := line(P4[1], P4[2], P5[1], P5[2]):
sol := solve({lineP12, lineP45}, {x, y}): beta := [subs(sol, x), subs(sol, y)]:
lineP34 := line(P3[1], P3[2], P4[1], P4[2]): lineP16 := line(P1[1], P1[2], P6[1], P6[2]):
sol := solve({lineP16, lineP34}, {x, y}): alpha := [subs(sol, x), subs(sol, y)]:
pl:= line(alpha[1], alpha[2], gamma[1], gamma[2]):
hexa := seq(implicitplot(tang||i, x = -20 .. 20, y = -20 .. 20, linestyle=3,color = blue),i=1..6);
hexa:=plot([seq([P||i,P||(i mod 6)+1],i=1..6),color=green); 
hexa:=plot([seq([P||i,P||(i+1)],i=1..6)],thickness=4,color=green); 
hex:=plot([[Q1,Q2],[Q2,Q3],[Q3,Q4],[Q4,Q5],[Q5,Q6],[Q6,Q1]],thickness=4,color=green);
tp := textplot({seq([op(pts[i]), cat("P", i)], i = 1 .. 6)}, 'align' = {'above', 'left'});
tpq := textplot({seq([op(ptQ[i]), cat("Q", i)], i = 1 .. 6)}, 'align' = {'above', 'left'});
TP:=textplot([[I1[],"I"],[alpha[],"alpha"],[beta[],"beta"],[gamma[],"gamma"]],'align' = {'above', 'left'});
slopes:=[seq(((dx,dy)->dy/dx)((pts[i]-pts[(i mod 6)+1])[]),i=1..6)];
lines:=zip((pt,slope)->y=slope*(x-pt[1])+pt[2],pts,slopes);
plotpts:=plot(pts,style=point,colour=red,symbol=solidcircle,symbolsize=5);
plotptQ:=plot(ptQ,style=point,colour=black,symbol=solidcircle,symbolsize=5);
plotlines:=plot(rhs~(lines),style=line,linestyle=3,colour=magenta);
cir:=implicitplot(x^2+y^2=R^2,x=-R..R,y=-R..R,color=black);
PL:=implicitplot(pl,x=-1..15,y=-15..6,color=blue,thickness=3);

 hexa := implicitplot(tang1, x = -20 .. 20, y = -20 .. 20, 

   linestyle = 3, color = blue), implicitplot(tang2, 

   x = -20 .. 20, y = -20 .. 20, linestyle = 3, color = blue), 

   implicitplot(tang3, x = -20 .. 20, y = -20 .. 20, 

   linestyle = 3, color = blue), implicitplot(tang4, 

   x = -20 .. 20, y = -20 .. 20, linestyle = 3, color = blue), 

   implicitplot(tang5, x = -20 .. 20, y = -20 .. 20, 

   linestyle = 3, color = blue), implicitplot(tang6, 

   x = -20 .. 20, y = -20 .. 20, linestyle = 3, color = blue)


Error, `)` unexpected
display(plotpts,plotptQ,plotlines,hex,cir,L14,L25,L36,PL,tp,tpq,TP,axis = [gridlines = [4, color = blue]],
view=[-6..10,-15..6],scaling=constrained,axes=none,size=[800,800]);
display(plotpts, plotptQ, plotlines, hex, cir, 

  implicitplot(0, x = -10 .. 10, y = -10 .. 10, color = red), 

  implicitplot(0, x = -10 .. 10, y = -10 .. 10, color = red), 

  implicitplot(0, x = -10 .. 10, y = -10 .. 10, color = red), PL, 

  tp, tpq, TP, axis = [gridlines = [4, color = blue]], 

  view = [-6 .. 10, -15 .. 6], scaling = constrained, 

  axes = none, size = [800, 800])


NULL;
I don’t know how to correct those mistakes. Thank you to help me.

I want to write a program in differential geometry that get g as a metric matrix then calculate christoffel.

Thank you for your consideration.

with(ImageTools);
U1 := Read("C:/Users/S/Desktop/StarPicture.jpg"):

ttt0 := textplot([0 + 0.5, (5 + 0) - 0.5, " Star ", color = "blue", font = ["times", "roman", "bold", 40]]):
display(ttt0, U1, axes = none, size = [400, 160]);

This is the error I get:

Error, (in plots:-display) cannot display array with other plots

I can see Maple doesn't allow adding images to plots. But is there a way around that?

I want to be able to virtually have a white box that I can add plots to such as curves, text, and images at certain locations etc? I want to do that with actual Maple code in the worksheet, without having to mouse-clicking Menu, insert, etc.

Thanks

The loop for HFS _data_2 and SFS_data_2 and the loop for HFS _data_3 and SFS_data_3 do not seem to be terminated. I do not know what it is the issue here. Anyone who can help this?

Negativity_(v12_beta_gamma_mu).mw

Thank you in advance,

Hello

I wonder if there is a way to parallelize the function listed below.   It deals with a set of sets (dynamical systems).  As far as I can see the problem is with subs and simplify.  In some cases a division by zero shows up (the reason I added try..catch and had to use for). 

The procedure should remove the systems with imaginary coefficients and return the valid indices.  

Many thanks

Ed

Obs.:  The number of dynamical systems can easily be greater than 10,000.  Any speed improvement is welcome.

Example of one such a dynamical system is

[(-x*rho*xi[6]*(beta - 1)*sqrt(((rho + beta - 1)*sigma - beta + 1)^2*xi[8]^2/(beta - 1)^2) - xi[8]*(-2*y*sigma*xi[7]*xi[6]^2*(beta - 1)^2 + (sigma*rho + (sigma + 1)*(beta - 1))*x*rho*xi[6] + 2*sigma*z*rho^2*xi[8]))/(2*xi[6]*xi[8]*rho*(beta - 1)), (-(beta - 1)*(-y*sigma*xi[7]*xi[6]^2*(beta - 1)^2 + rho^2*(sigma*z*xi[8] + x^2))*xi[6]*sqrt(((rho + beta - 1)*sigma - beta + 1)^2*xi[8]^2/(beta - 1)^2) - (2*sigma*(beta - 1)^2*(y*xi[7]*(rho + beta - 1)*sigma/2 + x^2*rho + y*(beta - 1)*xi[7]/2)*xi[6]^3 + 2*x*z*rho*sigma*xi[8]*(beta - 1)^2*xi[6]^2 + (-z*xi[8]*(rho + beta - 1)*sigma^2 + ((2*beta^2*z - 3*beta*z + z)*xi[8] + x^2*rho - (beta - 1)*(-2*beta*y*xi[7] + x^2))*sigma + x^2*(beta - 1))*rho^2*xi[6] + 2*x*z*rho^3*sigma*xi[8])*xi[8])/(2*xi[8]*sigma*(beta - 1)*(rho^2 + (beta - 1)^2*xi[6]^2)*xi[6]*xi[7]), (-(-x*sigma*(beta - 1)^2*xi[6]^3 + (beta - 1)^2*(sigma*y*xi[7] + x^2)*xi[6]^2 - rho^2*sigma*x*xi[6] - sigma*z*rho^2*xi[8])*(beta - 1)*rho*sqrt(((rho + beta - 1)*sigma - beta + 1)^2*xi[8]^2/(beta - 1)^2) + xi[8]*(-2*y*sigma^2*xi[7]*(beta - 1)^4*xi[6]^4 + 2*(rho*(rho + beta - 1)*sigma/2 + (beta - 1)*((-beta + 1/2)*rho + y*(beta - 1)*xi[7]))*sigma*(beta - 1)^2*x*xi[6]^3 + (beta - 1)^2*(((-y*xi[7] + 2*z*xi[8])*rho + y*(beta - 1)*xi[7])*sigma^2 + (x^2*rho + (beta - 1)*(-2*beta*y*xi[7] - 2*beta*z*xi[8] + x^2 + y*xi[7]))*sigma - x^2*(beta - 1))*rho*xi[6]^2 + 2*(rho*(rho + beta - 1)*sigma/2 + (beta - 1)*((-beta + 1/2)*rho + y*(beta - 1)*xi[7]))*sigma*x*rho^2*xi[6] + xi[8]*sigma*z*((rho - beta + 1)*sigma - beta + 1)*rho^3))/(2*xi[8]^2*sigma*(beta - 1)*rho*(rho^2 + (beta - 1)^2*xi[6]^2))]

coefmodel

{beta = 8/3, rho = 28, sigma = 10}

and phi and coe equal to 

[[], [], []]

 

cleanSystems := proc(sys::list,phi::list,coe::list,coefmodel::{list,set})
description "This function applies coefficient values to a system and remove it if the coef is somehow imaginary":
local i,aaa:=table(),bbb:=table(),ccc:=table(),ind:=table():
for i from 1 to nops(sys) do
  try
   aaa[i]:=simplify(subs(coefmodel,sys[i])):
   if has(aaa[i],I) then
      aaa[i]:=NULL:
      bbb[i]:=NULL:
      ccc[i]:=NULL:
      ind[i]:=NULL:
   else
      bbb[i]:=simplify(subs(coefmodel,phi[i])):
      ccc[i]:=simplify(subs(coefmodel,coe[i])):
      ind[i]:=i:
   end if:
  catch:
   aaa[i]:=NULL:
   bbb[i]:=NULL:
   ccc[i]:=NULL:
   ind[i]:=NULL:
  end try:
end do:
aaa:=convert(aaa,list):print(nops(aaa)):
bbb:=convert(bbb,list):print(nops(bbb)):
ccc:=convert(ccc,list):print(nops(ccc)):
ind:=convert(ind,list):print(nops(ind)):
return(aaa,bbb,ccc,ind):
end proc:

 

Hi. I'm having a problem with the command phase portrait on maple when i'm trying to make a phase portrait of my autonomous differential equations. The problem is i can't get arrows on my phase portrait to see how the system behave with different intial value conditions, so my questions is how can i add arrows to the phase portrait? See below for a image of my code

Hello

I'm a Master student and for my thesis I need to get the following function in Maple with the if then commando (or onother one that will get the same result):

But I didn't find the solution yet.

Can anyone help me out?

Thank you in advance.

Hi everyone 

I have a question regarding an animation. The maple file is attached at the bottom. (parts of it are from tomleslie 12910

I have two spheres which move and rotate over time. Now I would like to show one ball at a certain time and the other one at a certain time and not both over the whole animation.

For example:

x1 should only be shown and visible from time -1 to 0 

x2  should only be shown and visible from time 0 to 1 

Because I want to show a kind of transition from x1 to x2 at the time 0 i cannot just start one animation at -1 and the other at 0 because then they would run at the sime time which is not the goal. 

has anyone an idea?

Thanks in advance!

how_transition.mw

restart
EQ := proc(M, N) RETURN((y - M[2])/(x - M[1]) = (N[2] - M[2])/(N[1] - M[1])); end proc:
 with(plots):   
 with(geometry):   
_EnvHorizontalName := 'x':   _
EnvVerticalName := 'y':  
a := 7;  b := 5;  
c:=sqrt(a^2-b^2); 
 t:= (3* Pi)/(4):    
ellipse(el,x^2/a^2 + y^2/b^2 - 1 ): 
 point(M1, a*cos(t),b*sin(t)):  
point(F1,-c,0):point(F2,c,0):    
line( L1,[F1,M4]): 
point(M1, a*cos(t),b*sin(t)):  
EQ([a*cos(t),b*sin(t)],[-c,0]);  
solve(`%`,y);m:=coeff(`%`,x);   
line(L3,y=m*(x-c)); 
op(solve({x^2/a^2 + y^2/b^2 - 1 =0, y=m*(x-c)},{x,y},explicit)[2])[1]:xM2:=rhs(`%`):  
op(solve({x^2/a^2 + y^2/b^2 - 1 =0, y=m*(x-c)},{x,y},explicit)[2])[2]:yM2:=rhs(`%`):  
point(M2,xM2,yM2); 
line( tang1,x*xM2/a^2 + y*yM2/b^2 = 1);  
intersection(C1,L1,tang1);  
line(L4,[F1,M2]);  C1:=[ HorizontalCoord(C1), VerticalCoord(C1)]; 
 F1:=[-c,0];M2:= [ HorizontalCoord(M2), VerticalCoord(M2)];    
display( [ textplot( [[ -c, 0, "F1"],[ c,0, "F2"] ,                         
[ HorizontalCoord(M1), VerticalCoord(M1), "M1"],                          
[ HorizontalCoord(M2), VerticalCoord(M2), "M2"],                         
[ HorizontalCoord(C1), VerticalCoord(C1), "C1"] ],'align'={"above",'right'},                       [polygonplot([C1,F1,M2], color=blue,filled=true,transparency=0.9)]);     
draw( [ el(color=red),M1(color=black,symbol=solidcircle, symbolsize=16),
                      M2(color=black,symbol=solidcircle, symbolsize=16),                      
                      L1( color=black),L3(color=green),L4(color=green),                      
                      tang1(color=red), 
                      F1(color=blue, symbol=solidcircle, symbolsize=16),                      
                      F2(color=red, symbol=solidcircle, symbolsize=16),
                      C1(color=black, symbol=solidcircle, symbolsize=16),                     ],                                    axes=none ) ] );
Error, missing operator or `;` Many errors Icant corrected.  Thank you.

Hello;

Hope you are fine. I need to learn how can I call my code in the other file of maple, define new value for A and can get results. For this purpose, I just take an simple example as

questionmaple.mw

restart; A := 5; B := 10; AAA[0] := 10; for i from 0 while i <= A do AAA[i+1] := B*i*AAA[0] end do

5

 

10

 

10

 

0

 

100

 

200

 

300

 

400

 

500

(1)
 

``

Download questionmaple.mw

4 5 6 7 8 9 10 Last Page 6 of 35