Maple 2021 Questions and Posts

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

with(geometry):
_EnvHorizontalName := x:
_EnvVerticalName := y:
a := 7:
b := a*(1/2 + 1/6*sqrt(45 - 24*sqrt(3)))^2:
r := b*sqrt(b)/(sqrt(a + b) + sqrt(a)):
point(A, -a, b): point(B, -a, -b):
point(C, a, -c): point(F, a, b):
Sq := square(Sq, [A, B, C, F]):
circle(C1, [point(P1, [r, 0]), r]):
circle(C2, [point(P2, [(1 + sqrt(3))*r, r]), r]):
circle(C3, [point(P3, [(1 + sqrt(3))*r, -r]), r]):
ellipse(E, x^2/a^2 + y^2/b^2 = 1, [x, y]):
solve({Equation(C1), x^2/a^2 + y^2/b^2 = 1}, {x, y}):
point(T, [5.349255162, 2.829908743]):
IsOnCircle(T, C1);
draw([E(color = cyan), C1(color = yellow, filled = true), T(symbol = solidcircle, symbolsize = 20, color = red), Sq, C2(color = red), C3(color = red),Sq(color=blue)], axes = normal, view = [-a .. a, -b .. b], scaling = constrained);
square: (196+(7*(1/2+(1/6)*(45-24*3^(1/2))^(1/2))^2+c)^2)^(1/2)-(196+196*(1/2+(1/6)*(45-24*3^(1/2))^(1/2))^4)^(1/2) = 0
square: (7/2)*(1/2+(1/6)*(45-24*3^(1/2))^(1/2))^2-(1/2)*c = 0
Error, (in geometry:-square) not enough information to define a square
                             false

Error, (in geometry:-draw) cannot determine the vertices for drawing .Why all these errors ? Thank you.

EqBIS := proc(P, U, V)
local a, eq1, M1, t, PU, PV, bissec1;
a := (P - U)/LinearAlgebra:-Norm(P - U, 2) + (P - V)/LinearAlgebra:-Norm(P - V, 2);
M1 := P + a*t;
eq1 := op(eliminate({x = M1[1], y = M1[2]}, t));
RETURN(op(eq1[2])); end proc;
EqBIS*([4, 5], [11, 7/3], [11, 5]);
why such a procedure gives no result Thabk you.

 

I have maplesim installed and I get the error "Error, `MapleSim` does not evaluate to a module" when I run A:=MapleSim:-LinkModel(); in a Maple worksheet.

Does anyone know how to solve this error?

Hi guys,

I know how to plot inequality system through using with(plots) and inequal term. however, I couldn't plot following system of inqulity equations:

alpha <= 0.0002500000000*(-18000.*m^2 + 47271.*m + 39514. + sqrt(3.24000000*10^8*m^4 - 1.701756000*10^9*m^3 - 4.266980559*10^9*m^2 - 3.036299412*10^9*m - 6.95987804*10^8))/(9.*m^2 + 12.*m + 4.), 0.00005000000000*(-90000.*m^2 + 237237.*m + 198158. + sqrt(8.100000000*10^9*m^4 - 4.270266000*10^10*m^3 - 1.069976858*10^11*m^2 - 7.612670111*10^10*m - 1.744924704*10^10))/(9.*m^2 + 12.*m + 4.) <= alpha, -0.6666666667 < m, m < -0.6665522013

please let me know how we can plot it.

with best

Hello everybody.

I wrote the attached code. this code gives a good result when "H" parameter is equal to 0.5. Even in this condition if I change other parameters, I can get a true result as well. But when I change "H" parameter to 0.6,0.7,0.8 or 0.9 the code can't be executed anymore and I can't get a result.

based on the paper, for H=0.6,0.7,0.8 or 0.9. we have a result.

what's the problem?

can anyone please help me to solve this problem?

thank you for your help in advance.

1.mw

restart:local D:
with(plots):
with(plottools):

a := 7;
b := a/2;
NULL;

r := b/2;
c := 2*sqrt(10)*r;
A := [c/2, c/2];
B := [c/2, -1/2*c];
C := [-c/2, (-c)/2];
D := [-c/2, c/2];
f := (x, y) -> x^2/a^2 + y^2/b^2 = 1;
Ell1 := rotate(implicitplot(f(x, y), x = -9 .. 9, y = -6 .. 6, color = blue), Pi/4);

g := (x, y) -> x^2/b^2 + y^2/a^2 = 1;
Ell2 := rotate(implicitplot(g(x, y), x = -10 .. 10, y = -10 .. 10, color = blue), Pi/4);

quadri := plot([A, B, C, D, A], x = -6 .. 6, y = -6 .. 6, filled = true, color = red, transparency = 0.7);
Cir1 := disk([c/2 - r, -c/2 + r], r, color = blue);
Cir2 := disk([-c/2 + r, -c/2 + r], r, color = blue);
Cir3 := disk([-c/2 + r, c/2 - r], r, color = blue);
Cir4 := disk([c/2 - r, c/2 - r], r, color = blue);
display([quadri, Ell1, Ell2, Cir1, Cir2, Cir3, Cir4], scaling = constrained, axes = normal);
how to find the equations of ellipses in order to fit them to discs and whiten the interior of ellipses ? Thank you.

restart;
with(LinearAlgebra);
with(plots);
NULL;

EqBIS := proc(P, U, V) local a, eq1, M1, t, PU, PV, bissec1; a := (P - U)/LinearAlgebra:-Norm(P - U, 2) + (P - V)/LinearAlgebra:-Norm(P - V, 2); M1 := P + a*t; eq1 := op(eliminate({x = M1[1], y = M1[2]}, t)); RETURN(op(eq1[2])); end proc;
NULL;
A := <4, 8>;
B := <4, 2>;
C := <1, 4>;
EqBIS(A, B, C);
NULL;

Cen := proc(M, N, R) local eq1, eq2, sol; eq1 := EqBIS(M, N, R) = 0; eq2 := EqBIS(N, M, R) = 0; sol := simplify(solve({eq1, eq2}, {x, y})); RETURN([subs(sol, x), subs(sol, y)]); end proc;
Cen(A,B,C):

CircleParm := t -> [(-t^2 + 1)/(t^2 + 1), 2*t/(t^2 + 1)];
P1 := Transpose(convert(CircleParm(1/4), Vector));

P2 := Transpose(convert(CircleParm(5), Vector));
P3 := Transpose(convert(CircleParm(-1/10), Vector));
P4 := Transpose(convert(CircleParm(-3/2), Vector));

C1 := Transpose(convert(Cen(P1, P2, P3), Vector));
Pts := [P1, P2, P3, P4, C1];

display(implicitplot([x^2 + y^2 - 1], x = -2 .. 2, y = -4 .. 2, colour = [blue], scaling = constrained), pointplot(Pts, symbolsize = 16));
Error, (in plots:-pointplot) incorrect number of coordinates in points data
NULL;Why this error. Thank you.


I'm using Maple 2021, and my Euler-Lagrange equation is coming out with a R[0] term that should not be there. I want to know what is causing this error and how I can fix it.

restartNULL

Lagrangian

 

Leq := (1/2)*R^2*[-cosh(rho1(tau)^2)*(diff(t(tau), tau))^2+(diff(rho1(tau), tau))^2+sinh(rho1(tau)^2)*(diff(theta1(tau), tau))^2]+(1/2)*R^2*[-cosh(rho2(tau)^2)*(diff(t(tau), tau))^2+(diff(rho2(tau), tau))^2+sinh(rho2(tau)^2)*(diff(theta2(tau), tau))^2]-(1/2)*k*rho1(tau)^2-(1/2)*k*rho2(tau)^2-(1/2*(tanh(rho2(tau)-rho1(tau))+1))*(rho2(tau)-rho1(tau))^2; L := subs({diff(rho1(tau), tau) = var4, diff(rho2(tau), tau) = var6, diff(t(tau), tau) = var2, diff(theta1(tau), tau) = var8, diff(theta2(tau), tau) = var10, rho1(tau) = var3, rho2(tau) = var5, t(tau) = var1, theta1(tau) = var7, theta2(tau) = var9}, Leq)

(1/2)*R^2*[-cosh(rho1(tau)^2)*(diff(t(tau), tau))^2+(diff(rho1(tau), tau))^2+sinh(rho1(tau)^2)*(diff(theta1(tau), tau))^2]+(1/2)*R^2*[-cosh(rho2(tau)^2)*(diff(t(tau), tau))^2+(diff(rho2(tau), tau))^2+sinh(rho2(tau)^2)*(diff(theta2(tau), tau))^2]-(1/2)*k*rho1(tau)^2-(1/2)*k*rho2(tau)^2-(1/2)*(-tanh(-rho2(tau)+rho1(tau))+1)*(rho2(tau)-rho1(tau))^2

(1.1)

Time Equation

 

epr11 := diff(L, var2); epr12 := diff(L, var1); epr13 := subs({var1 = t(tau), var10 = diff(theta2(tau), tau), var2 = diff(t(tau), tau), var3 = rho1(tau), var4 = diff(rho1(tau), tau), var5 = rho2(tau), var6 = diff(rho2(tau), tau), var7 = theta1(tau), var8 = diff(theta1(tau), tau), var9 = theta2(tau)}, epr11); epr14 := subs({var1 = t(tau), var10 = diff(theta2(tau), tau), var2 = diff(t(tau), tau), var3 = rho1(tau), var4 = diff(rho1(tau), tau), var5 = rho2(tau), var6 = diff(rho2(tau), tau), var7 = theta1(tau), var8 = diff(theta1(tau), tau), var9 = theta2(tau)}, epr12); epr15 := diff(epr13, tau); teq := epr15-epr14 = 0

2*R*[0]+(1/2)*R^2*[-4*rho1(tau)*(diff(rho1(tau), tau))*sinh(rho1(tau)^2)*(diff(t(tau), tau))-2*cosh(rho1(tau)^2)*(diff(diff(t(tau), tau), tau))]+(1/2)*R^2*[-4*rho2(tau)*(diff(rho2(tau), tau))*sinh(rho2(tau)^2)*(diff(t(tau), tau))-2*cosh(rho2(tau)^2)*(diff(diff(t(tau), tau), tau))] = 0

(2.1)

NULL


 

Download Maple_Help_Example.mw

 

Maple 2021.
I expect after exporting to pdf view of page with plot like on fig. 1.

It means with font=[TIMES, ROMAN, 12] as in maine text.
But I obtaned this view of page on pdf (fig. 2) with smaller font-size.

In previouse versions there are no the problem like this.
Dear community, how to fix this annoying inconvenience?

 fig. 1.  fig. 2.

Consider the following integral, shown below in this image.

>> Link to the Maple sheet: example.mw <<

Why does Maple provide erroneous results? Is there a bug in the software? I use Maple 2021.

Hi.  I am using the linux version of Maple.  I seem to experience more bombs in Maple/Linux vs MathCad/Windows.  The program just froze as I was entering text.  Just text.  It is not a disaster since I make very frequent saves.  But it is very annoying.  I was a heavy user of MathCad from about 2005 to 2019.  In the early days, it bombed a lot.  But I do not recall that it ever bombed when I was entering text.  Any suggestions?  Would there be a limition on the number of text characters?  Is it Linux?  Other than this problem, it is a great program.

restart:
eq := a*x^3 + b*x^2 + c*x + d;
 s := x1 + x2 + x3 = -b/a;
 sp := x1*x2 + x1*x3 + x2*x3 = c/a;
 p := x1*x2*x3 = -d/a;
sol:=solve({eq, p, s, sp}, {x1, x2, x3},explicit);                       
 a := 1;
b := -5;
c := 6;
d := -1;
 sol;                           

why is not successfull ?   Thank you.                 

I have a problem in plotting bellow function. actually because my main program is not working so I decided to do it in simple way. I found that my program in maple can't plot the function I introduced it as a procudure and is an implicit function. can you help me please?

>EQ := proc(x, t) local y, m, func;
                 m := 3;
                 func := m*x^2 + t*y^2 = 4;
          end proc;


>eq := EQ(x, 10);                              
                     eq := 3*x^2  + 10*y^2  = 4

>implicitplot(eq, x = -1 .. 1, y = 0 .. 2)
 Error, (in plots/implicitplot) invalid input: the following extra unknowns were found in the input expression: {y}
 

 

What is the [explict] relation between Maple's WeierstrassP and Weierstrass' P-function (e.g. https://en.wikipedia.org/wiki/Weierstrass_elliptic_function) ?

The worksheet here shows a couple of failed attempts at coaxing Maple to calculate the general solution of a pretty simple second order ODE.  I have also included the expected solution which I  have calculated by hand.  Perhaps I am missing a key trick.  Any ideas?

The ODE that I am actually interested in is significantly more complex. The one in the worksheet is a much simplified "bare bones" specimen that exhibits the issue that I am facing.

Attempt to solve with Heaviside

restart;

de := diff(u(x),x$2) = Heaviside(x - a)*u(x);

diff(diff(u(x), x), x) = Heaviside(x-a)*u(x)

dsolve fails:

dsolve(de);

u(x) = DESol({diff(diff(_Y(x), x), x)-Heaviside(x-a)*_Y(x)}, {_Y(x)})

Attempt to solve with piecewise

restart;

de := diff(u(x),x$2) = piecewise(x < a, 0, 1)*u(x);

de := diff(u(x), x, x) = piecewise(x < a, 0, 1)*u(x)

dsolve(de);

Error, (in dsolve) give the main variable as a second argument

dsolve(de, u(x));

Error, (in dsolve) give the main variable as a second argument

 

 

The solution is easy to calculate by hand

We just solve the (quite trivial) DE over the intervals x < a and x>a

separately, and patch the two solutions by requiring the continuity

of u(x) and diff(u(x), x) at x = a.  We get

sol := piecewise(x < a,
        x*c[1] + c[2],
        ((a*c[1] + c[1] + c[2])*exp(x))/(2*exp(a)) + ((a*c[1] - c[1] + c[2])*exp(-x))/(2*exp(-a)));

sol := piecewise(x < a, x*c[1]+c[2], (a*c[1]+c[1]+c[2])*exp(x)/(2*exp(a))+(a*c[1]-c[1]+c[2])*exp(-x)/(2*exp(-a)))

Download solving-an-ode.mw

First 7 8 9 10 11 12 13 Last Page 9 of 35