MaplePrimes Questions

Hi,

I'd like to know, if it is possible to define any sort of range for parameters in NonlinearFit. E. g. I know that one of parameters should be somewhere between 0.2 - 0.4. I know there is a possibility of initalvalues, but using it doesn't lead into this range.

Thanks.

Hi. So my question is how can I get Square brackets on the phone app in calculations or is it possible?

 

 

In a french magazine written by High Schools teachers I found this problem:

let a, b, p, q four strictly positive integers such that a > b^2 and p > q+1;
find 4-tuples (a, b, p, q) such that 

(a^2 - b^4) = p!/q!

Given the source of this problem I suspect that there is a trick to answering this question.
After some hours spent, I have found no general method to solve it, only a few solutions (first one and second one are almost obvious), for instance

rel := a^2 - b^4 = p!/q!:

eval(rel, [a= 5, b=1, q=1, p=4]);   
eval(rel, [a=11, b=1, q=1, p=5]);
eval(rel, [a=71, b=1, q=1, p=7]);
eval(rel, [a= 2, b=1, q=2, p=3]);
eval(rel, [a=19, b=1, q=2, p=6]);
eval(rel, [a=21, b=3, q=2, p=6]);

Do you have any idea how to solve this problem?
Could it be handled by Maple (without a systematic exploration of a part of N^4)?

Thanks in advance

lets say we have one or two lines 

y=2x-4 and y = -2x+4 is it possible to get Maple to illustrate the angle between these two lines in a plot? Or the angle of inclination in respect to the x-axes for them individually? 

kindly help me to find the inverse Laplace of this function. I tried but maple leaves the integral unevaluated.
 

restart

with(inttrans)

expr := exp(a-sqrt(a^2+b*s))/s

exp(a-(a^2+b*s)^(1/2))/s

(1)

`assuming`([invlaplace(expr, s, t)], [b > 0])

(1/2)*(b/Pi)^(1/2)*(int(exp(-a^2*_U1/b+a-(1/4)*b/_U1)/_U1^(3/2), _U1 = 0 .. t))

(2)

NULL


 

Download invrslplc.mw

how can revision of error in 

restart;
u0 := proc (x) options operator, arrow; 1+2*x end proc; h := 0;
for k from 0 to 5 do U := proc (k, h) options operator, arrow; eval((diff(u0(x), [`$`(x, k)]))/factorial(k), x = 0) end proc end do;
m := h+1;
for k from 0 to 5 do U := proc (k, h) options operator, arrow; (sum(sum(U(r, h-s)*U(k-r, s), s = 0 .. h), r = 0 .. k)+(k+1)*U(k, h))/m end proc end do;
U(0, 1);
Error, (in U) too many levels of recursion

 

I have the following expression.

Ps = (x - 600)(15000 + 400*(y - 4000)/2000 + 15000*0.40*(850 - x)/100) - y

Maple will evaluate this to:

Ps = (x - 600)(15000 + 400*(y - 4000)/2000 + 15000*0.40*(850 - x)/100) - y

Screenshot:

Plotting these two in 2D on Desmos to demonstrate: https://www.desmos.com/calculator/tvp4rbzxzp

These two are not the same expression. Is Maple broken or am I doing something wrong?

Hello. Please help me solve the ODE system

ODU_v2.mw
 

restart

with(linalg):

r1 := 1:

1

 

0.1111110000e-2

 

0

 

1920.000000+0.7407400000e-3*I

(1)

J := proc (n, x) options operator, arrow; BesselJ(n, x) end proc:

nsize := floor(2*k)+1;

3

(2)

n := 1; A1 := matrix([[(lambda(r)+2*mu(r))*r^2, 0], [0, mu(r)*r^2]]); B1 := matrix([[(diff(lambda(r), r)+2*(diff(mu(r), r)))*r^2+(lambda(r)+2*mu(r))*r, I*n*(lambda(r)+mu(r))*r], [I*n*(lambda(r)+mu(r))*r, (diff(mu(r), r))*r^2+mu(r)*r]]); C1 := matrix([[(diff(lambda(r), r))*r-lambda(r)-(n^2+2)*mu(r)+omega^2*rho(r)*r^2, I*n*((diff(lambda(r), r))*r-lambda(r)-3*mu(r))], [I*n*((diff(mu(r), r))*r+lambda(r)+3*mu(r)), -(diff(mu(r), r))*r-n^2*lambda(r)-(2*n^2+1)*mu(r)+omega^2*rho(r)*r^2]]); U := vector([U1(r), U2(r)]); DU := vector([diff(U1(r), r), diff(U2(r), r)]); D2U := vector([diff(U1(r), `$`(r, 2)), diff(U2(r), `$`(r, 2))]); T1 := multiply(A1, D2U); T2 := multiply(B1, DU); T3 := multiply(C1, U); prav := evalm(T1+T2+T3); pr1 := prav[1]; pr2 := prav[2]; p1 := evalc(Re(pr1)); p2 := evalc(Im(pr1)); p3 := evalc(Re(pr2)); p4 := evalc(Im(pr2)); WWVV := evalf(subs(x = k*r1, H(n, x)))*evalf(subs(x = k2*r1, H(n, x)))*n^2-evalf(subs(x = k*r1, DH(n, x)))*evalf(subs(x = k2*r1, DH(n, x)))*k*k2*r1^2; `αv1` := I*evalf(subs(x = k2*r1, DH(n, x)))*k2*omega*r1^2/WWVV; `αv2` := -evalf(subs(x = k2*r1, H(n, x)))*n*omega*r1/WWVV; `αv3` := (evalf(subs(x = k*r1, DJ(n, x)))*evalf(subs(x = k2*r1, DH(n, x)))*I^n*k*k2*r1^2-I^n*n^2*evalf(subs(x = k*r1, J(n, x)))*evalf(subs(x = k2*r1, H(n, x))))/WWVV; `αv4` := evalf(subs(x = k*r1, H(n, x)))*r1*n*omega/WWVV; `αv5` := -I*evalf(subs(x = k*r1, DH(n, x)))*r1^2*k*omega/WWVV; `αv6` := I*I^n*n*k*r1*(evalf(subs(x = k*r1, DJ(n, x)))*evalf(subs(x = k*r1, H(n, x)))-evalf(subs(x = k*r1, DH(n, x)))*evalf(subs(x = k*r1, J(n, x))))/WWVV; gv1 := rho1*(-evalf(subs(x = k*r1, D2H(n, x)))*k^2*r^2*(4*nu+3*xi)-3*evalf(subs(x = k*r1, DH(n, x)))*k*r1*xi+evalf(subs(x = k*r1, H(n, x)))*(-4*k^2*r1^2*nu-3*k^2*r1^2*xi+(3*I)*omega*r1^2-2*n^2*nu+3*n^2*xi))/(3*r1^2); gv2 := (6*rho1/(3*r1^2)*I)*n*nu*(evalf(subs(x = k2*r1, H(n, x)))-k2*r1*evalf(subs(x = k2*r1, DH(n, x)))); gv3 := rho1*(-I^n*evalf(subs(x = k*r1, D2J(n, x)))*k*r1^2*(4*nu+3*xi)+I^n*evalf(subs(x = k*r1, DJ(n, x)))*k*r1*(2*nu-3*xi)+I^n*evalf(subs(x = k*r1, J(n, x)))*(-4*k^2*r1^2*nu-3*k^2*r1^2*xi+(3*I)*omega*r1^2-2*n^2*nu+3*n^2*xi))/(3*r1^2); gv4 := (2*nu*rho1/r1^2*I)*n*(evalf(subs(x = k*r1, H(n, x)))-evalf(subs(x = k*r1, DH(n, x)))*k*r1); gv5 := nu*rho1*(evalf(subs(x = k2*r1, D2H(n, x)))*k2^2*r1^2-evalf(subs(x = k2*r1, D2H(n, x)))*k2*r1+evalf(subs(x = k2*r1, H(n, x)))*n^2)/r1^2; gv6 := (2*nu*rho1/r1^2*I)*n*I^n*(evalf(subs(x = k*r1, J(n, x)))-k*r1*evalf(subs(x = k*r1, DJ(n, x)))); E := matrix([[`αv1`*gv1+`αv4`*gv2+lambda(r1)/r1, `αv2`*gv1+`αv4`*gv2+I*n*lambda(r1)/r1], [`αv1`*gv4+`αv4`*gv5+I*n*mu(r1)/r1, `αv2`*gv4+`αv5`*gv5-mu(r1)/r1]]); G := vector([-gv1*`αv3`-gv2*`αv6`-gv3, -gv4*`αv3`-gv5*`αv6`-gv6]); e1 := (lambda2*n^2*evalf(subs(x = kl*r2, J(n, x)))-kl^2*r2^2*evalf(subs(x = kl*r2, D2J(n, x)))*(lambda2+2*mu2)-kl*lambda2*r2*evalf(subs(x = kl*r2, DJ(n, x))))/r2^2; e2 := (2*mu2*I)*n*(evalf(subs(x = kt*r2, J(n, x)))-kt*r2*evalf(subs(x = kt*r2, DJ(n, x))))/r2^2; e3 := (I*n*2)*(evalf(subs(x = kl*r2, J(n, x)))-kl*r2*evalf(subs(x = kl*r2, DJ(n, x))))/r2^2; e4 := (kt^2*r2^2*evalf(subs(x = kt*r2, D2J(n, x)))-kt*r2*evalf(subs(x = kt*r2, DJ(n, x)))+n^2*evalf(subs(x = kt*r2, J(n, x))))/r2^2; gamma1 := kt*r2*evalf(subs(x = kt*r2, DJ(n, x)))/WW; gamma2 := I*n*evalf(subs(x = kt*r2, J(n, x)))/WW; gamma3 := I*n*evalf(subs(x = kl*r2, J(n, x)))/WW; gamma4 := -kl*r2*evalf(subs(x = kl*r2, DJ(n, x)))/WW; WW := (kl*r2^2*evalf(subs(x = kl*r2, DJ(n, x)))*kt*evalf(subs(x = kt*r2, DJ(n, x)))-n^2*evalf(subs(x = kl*r2, J(n, x)))*evalf(subs(x = kt*r2, J(n, x))))/r2; F := matrix([[r2^2*(gamma1*e1+gamma3*e2+lambda(r2)/r2), r2^2*(gamma2*e1+gamma4*e2+I*n*lambda(r2)/r2)], [mu2*r2^2*(gamma1*e3+gamma3*e4+I*n*mu(r2)/(mu2*r2)), mu2*r2^2*(gamma2*e3+gamma4*e4-mu(r2)/(mu2*r2))]]); Ur1 := vector([U1(r1), U2(r1)]); Ur2 := vector([U1(r2), U2(r2)]); DUr1 := vector([Dx1(r1)+I*Dy1(r1), Dx2(r1)+I*Dy2(r1)]); DUr2 := vector([Dx1(r2)+I*Dy1(r2), Dx2(r2)+I*Dy2(r2)]); CCR1 := multiply(A1, DUr1); CCR2 := multiply(E, Ur1); CR := evalm(CCR1+CCR2); CCR11 := multiply(A1, DUr2); CCR22 := multiply(F, Ur2); CR2 := evalm(CCR11+CCR22); ggr1 := expand(evalc(Re(CR[1]))); ggr2 := expand(evalc(Im(CR[1]))); ggr3 := expand(evalc(Re(CR[2]))); ggr4 := expand(evalc(Im(CR[2]))); ggr5 := expand(evalc(Re(CR2[1]))); ggr6 := expand(evalc(Im(CR2[1]))); ggr7 := evalc(Re(CR2[2])); ggr8 := evalc(Im(CR2[2])); gr1 := subs(Dx1(r1) = (D(x1))(r1), Dx2(r1) = (D(x2))(r1), Dy1(r1) = (D(y1))(r1), Dy2(r1) = (D(y2))(r1), r = r1, ggr1); gr2 := subs(Dx1(r1) = (D(x1))(r1), Dx2(r1) = (D(x2))(r1), Dy1(r1) = (D(y1))(r1), Dy2(r1) = (D(y2))(r1), r = r1, ggr2); gr3 := subs(Dx1(r1) = (D(x1))(r1), Dx2(r1) = (D(x2))(r1), Dy1(r1) = (D(y1))(r1), Dy2(r1) = (D(y2))(r1), r = r1, ggr3); gr4 := subs(Dx1(r1) = (D(x1))(r1), Dx2(r1) = (D(x2))(r1), Dy1(r1) = (D(y1))(r1), Dy2(r1) = (D(y2))(r1), r = r1, ggr4); gr5 := subs(Dx1(r2) = (D(x1))(r2), Dx2(r2) = (D(x2))(r2), Dy1(r2) = (D(y1))(r2), Dy2(r2) = (D(y2))(r2), r = r2, ggr5); gr6 := subs(Dx1(r2) = (D(x1))(r2), Dx2(r2) = (D(x2))(r2), Dy1(r2) = (D(y1))(r2), Dy2(r2) = (D(y2))(r2), r = r2, ggr6); gr7 := subs(Dx1(r2) = (D(x1))(r2), Dx2(r2) = (D(x2))(r2), Dy1(r2) = (D(y1))(r2), Dy2(r2) = (D(y2))(r2), r = r2, ggr7); gr8 := subs(Dx1(r2) = (D(x1))(r2), Dx2(r2) = (D(x2))(r2), Dy1(r2) = (D(y1))(r2), Dy2(r2) = (D(y2))(r2), r = r2, ggr8); sys := p1 = 0, p2 = 0, p3 = 0, p4 = 0; Inits := gr3 = evalc(Re(G[2])), gr4 = evalc(Im(G[2])), gr1 = evalc(Re(G[1])), gr2 = evalc(Im(G[1])), gr5 = 0, gr6 = 0, gr7 = 0, gr8 = 0; dde := dsolve({Inits, sys}, numeric, [x1(r), x2(r), y1(r), y2(r)], method = bvp[trapdefer], 'maxmesh' = 5000)

1

 

5860000000.*r^2*(diff(diff(x1(r), r), r))+5860000000.*r*(diff(x1(r), r))-4880000000.*r*(diff(y2(r), r))+(-6840000000.+0.1972224000e11*r^3-0.1380556800e11*r^2)*x1(r)-(15217.76256*r^3-10652.43379*r^2)*y1(r)+6840000000.*y2(r) = 0, 5860000000.*r^2*(diff(diff(y1(r), r), r))+5860000000.*r*(diff(y1(r), r))+4880000000.*r*(diff(x2(r), r))+(15217.76256*r^3-10652.43379*r^2)*x1(r)+(-6840000000.+0.1972224000e11*r^3-0.1380556800e11*r^2)*y1(r)-6840000000.*x2(r) = 0, 980000000.0*r^2*(diff(diff(x2(r), r), r))-4880000000.*r*(diff(y1(r), r))+980000000.0*r*(diff(x2(r), r))-6840000000.*y1(r)+(-6840000000.+0.1972224000e11*r^3-0.1380556800e11*r^2)*x2(r)-(15217.76256*r^3-10652.43379*r^2)*y2(r) = 0, 980000000.0*r^2*(diff(diff(y2(r), r), r))+4880000000.*r*(diff(x1(r), r))+980000000.0*r*(diff(y2(r), r))+6840000000.*x1(r)+(15217.76256*r^3-10652.43379*r^2)*x2(r)+(-6840000000.+0.1972224000e11*r^3-0.1380556800e11*r^2)*y2(r) = 0

 

980000000.0*(D(x2))(1)-3407670.437*x1(1)-979699593.0*y1(1)-982493864.9*x2(1)+2501551.625*y2(1) = -1147.143928, 980000000.0*(D(y2))(1)+979699593.0*x1(1)-3407670.437*y1(1)-2501551.625*x2(1)-982493864.9*y2(1) = 522.0509891, 5860000000.*(D(x1))(1)+1012610130.*x1(1)+3433520814.*y1(1)-3395293.932*x2(1)-3899703885.*y2(1) = 1553476.957-0.8860949e-3*r^2, 5860000000.*(D(y1))(1)-3433520814.*x1(1)+1012610130.*y1(1)+3899703885.*x2(1)-3395293.932*y2(1) = 582234.6500+.6073438988*r^2, 3750400000.*(D(x1))(.8)-0.1805979289e11*x1(.8)-3057.354840*y1(.8)+182.8516896*x2(.8)+0.2220128109e11*y2(.8) = 0, 3750400000.*(D(y1))(.8)+3057.354840*x1(.8)-0.1805979289e11*y1(.8)-0.2220128109e11*x2(.8)+182.8516896*y2(.8) = 0, 627200000.0*(D(x2))(.8)-182.8520640*x1(.8)-0.2610528071e11*y1(.8)-0.2508771663e11*x2(.8)-607.0797125*y2(.8) = 0, 627200000.0*(D(y2))(.8)+0.2610528071e11*x1(.8)-182.8520640*y1(.8)+607.0797125*x2(.8)-0.2508771663e11*y2(.8) = 0

 

Error, (in dsolve/numeric/BVPSolve) unable to store '-HFloat(8.860193192958832e-4)+0.8860949e-3*r^2' when datatype=float[8]

 

``


 

Download ODU_v2.mw

 

with(plots);
f := x -> x^3 + 3^x;
complexplot3d(f, -15 - 22*I .. 15 + 22*I);