MaplePrimes Questions

Hey everone, im trying to get 2 legends to apear on my plot im animateing. The problem here is that it just wont. Could you guys help me ?

Heres the code

c := x -> piecewise(0 <= x and x <= 450000, 0.37*x, 450000 < x, 0.37*x + 0.06*(x - 450000));
g := x -> piecewise(0 <= x and x <= 558000, 0.37*x, 558000 < x, 0.37*x + 0.12*(x - 558000));
A1 := plots:-animate(plot, [g(x), x = 0 .. skat, color = blue], frames = 20, skat = 0 .. 1000000);
A2 := plots:-animate(plot, [c(x), x = 0 .. skat, color = red], frames = 20, skat = 0 .. 1000000);
Do(%Plot2 = plots:-display([A1, A2], size = [1000, 700], gridlines = true, legend=["Line 1","Line 2"],legendstyle=[font=[Lucida, roman, 14], location=bottom]));
SetProperty("Plot2", ':-play', true, ':-refresh' = true);

Hi everybody,

Im trying to solve the following trivial pde using Maple 2018

pdsolve([diff(Y(x, t), t, t) = 0, Y(x, 0) = 0, (D[2](Y))(x, 1) = 0]);

Obviuosly the solution is Y(x, t) = 0, but Mapple 2018 is not giving any answer.

This works in Maple 2015.

Why is not working in Maple 2018?

Thanks,

Javier

 

I have the equation y^2=𝑎𝑥^3+𝑏𝑥^2+𝑐𝑥+𝑑.

How do I plot y against x as the coefficients a, b, c and d vary?

Thank you for your help.

hi

how can i write a number or word on the column or right the row of matrix as this pic

hi, I am trying to evaluate the following integrations (Note that; the values of alpha, lambda_1 and lambda_2) are random and they change with every iteration 

`&lambda;1_B`[so] := 10.94:

``

W[1] := evalf[4](int(`&alpha;_B`[so]^2/((z-1+`&alpha;_B`[so])^2*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])), z = 1 .. infinity)); W[2] := evalf[4](int(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])*ln(z)/((z-1+`&alpha;_B`[so])^2*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^2), z = 1 .. infinity)); W[3] := evalf[4](int(1/((z-1+`&alpha;_B`[so])^2*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^2), z = 1 .. infinity)); W[4] := evalf[4](int(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])*ln(z)^2/((z-1+`&alpha;_B`[so])^2*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^2), z = 1 .. infinity)); W[5] := evalf[4](int(1/((z-1+`&alpha;_B`[so])^3*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])), z = 1 .. infinity)); W[6] := evalf[4](int((z^(`&lambda;2_B`[so]/`&lambda;1_B`[so]))^2*ln(z)^2/((z-1+`&alpha;_B`[so])^2*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^3), z = 1 .. infinity)); W[7] := evalf[4](int(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])*ln(z)/((z-1+`&alpha;_B`[so])^2*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^3), z = 1 .. infinity)); W[8] := evalf[4](int(1/((z-1+`&alpha;_B`[so])^2*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^3), z = 1 .. infinity)); W[9] := evalf[4](int(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])*ln(z)/((z-1+`&alpha;_B`[so])^3*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^2), z = 1 .. infinity)); W[10] := evalf[4](int(1/((z-1+`&alpha;_B`[so])^4*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])), z = 1 .. infinity)); W[11] := evalf[4](int(1/((z-1+`&alpha;_B`[so])^3*(z^(`&lambda;2_B`[so]/`&lambda;1_B`[so])-1+`&alpha;_B`[so])^2), z = 1 .. infinity))

int(79.977249/((z+7.943)^2*(z^.1408592322+7.943)), z = 1 .. infinity)

 

Warning,  computation interrupted

 

Warning,  computation interrupted

 

0.1744e-1

 

Warning,  computation interrupted

 

0.3348e-2

 

Warning,  computation interrupted

 

Warning,  computation interrupted

 

Warning,  computation interrupted

 

Warning,  computation interrupted

 

Warning,  computation interrupted

 

``

``


 

Download ask_maple.mw

 

Hello,

What means, please, this error

 

Error, (in RootFinding:-Analytic) Maple was unable to allocate enough memory to complete this computation.  Please see ?alloc
 

 

What should I to do to overcome this error?

Hi guys,

 

I'm fairly new to programming as a whole, but I've currently set up a script which creates a matrix and then fills it in given a  condition. i.e if the x and y indices of the matrix are the same it has been told to add m^2F. If the y and x index differs by 3 is has been asked to fill in V3/4 and if they differ by 6 it has been asked to fill in V6/4. After the matrix is created it will then calculate the eigenvalues.

 

My question is as follows:

m^F is a constant and V3 and V6 are variables. I currently, manually, set a value of V3 and V6 at the top of the script and then calculate the eigenvalues. How would one go about reversing this process - i.e provide a set of eigenvalues and then perform a fit to find the best values of V3 and V6. Is this 'doable' in Maple or would it be best to use something else.

 

I have attached a copy of the script for viewing purposes in case what I have written is not very clear - Hindered_rotor.mw

 

Thanks for your time,

David

 

How 2 solve summation when M,  Z,  X are given with mixed conditions?

Hello everyone, I'm trying to run a simple calculation (Water flowing out of a pressurised container) using a combination of conservation of energy and conservation of mass. I have working models of the same system without pressurisation (purely gravity working) which work fine in Maple, but when re-writing the pressure as a function of the height of the water I receive the error:

"Error, (in DEtools/convertsys) unable to convert to an explicit first-order system".

 

The formula used is:

"Eq1:= -Rho_Water * A_Barrell * v_Barrel = Rho_Water * A_Nozzle * v_Nozzle"

Which returns:

"Eq1:= -25.23733555 * d/dt h_Water(t) = 0.5982 * (-190.1309944 - 13.64385474 * h_Water(t) + (d/dt h_Water(t))2)1/2"

With initial condition:

"ics1:= h_Water(0) = 0.2"

 

After giving the command:

"Sol1:= dsolve({Eq1, ics1}, numeric)"

Maple returns the aforementioned error. When trying to solve non-numerically the output is a list filled with "RootOf" and "_Z". Instinctively I would say the square root in the second part of the equation is the problem here, but I would not know how to fix this. Does anybody have a quick fix for this problem? Or is there a fundamental issue with the equation? Thank you in advance!

I have matrix:

m1 := Matrix([[x[0,0]=1,x[0,1]=1,x[0,2]=0,x[0,3]=0,x[0,4]=0,x[0,5]=0],[x[1,0]=0,x[1,1]=0,x[1,2]=1,x[1,3]=1,x[1,4]=0,x[1,5]=0],[x[2,0]=0,x[2,1]=0,x[2,2]=0,x[2,3]=0,x[2,4]=1,x[2,5]=1]]);

How to get values on the rhs of x without using for loops and create a matrix using these values?.

Results should be:

m2 := Matrix([[1,1,0,0,0],[0,0,1,1,0,0],[0,0,0,0,1,1]]);

 

How to write a code to get following Matrix D?

MY TRY: (But it' s not completely what I seek)

restart:

k:=1:
M:=2:
N:=2^k*(M+1):

U:=Matrix(M+1,M+1):
for r from 2 to M+1 do
for s from 1 to r-1 do
if type(r+s,odd) then
U(r,s):=2^(k+1)*sqrt((2*r-1)*(2*s-1)):
 else 0 end if:
end do:
end do:

#Let's find Matrix D, In here it' s shown matrix DD 
DD:=Matrix(N,N,shape=diagonal,fill=U);

Dear all,

I hope everyone helps me about the problem of converting a permutation into numbers and vice versa on maple

Let Sn denote the set of all permutations of the set {0, 1, ..., n − 1}

Lehmer code is a bijective function l : Sn ->{0, 1, 2, ..., n! − 1}.

Define function l(S)=Sum(ci x (n − 1 − i)! ) where S in Sn and ci is the number of elements of the set { j > i | sj < si }

Inverse Lehmer code is a bijective function l−1 : {0, 1, 2, ..., n! − 1} -> Sn

For example: n=4 -->{0, 1, 2, 3}, for S = (0, 2, 1, 3) , so c0 = 0, c1 = 1 ( j=2 > i=1 and sj = 1 < si = 2), c2 = 0, c3 = 0 -->

I(S) = 0 x (3-0)! + 1 x (3 - 1)! + 0 x (3-2)! + 0 x (3 - 3)! = 2! = 2. So I((0, 2, 1, 3)) =2  and I-1(2) = (0, 2, 1, 3).

How to calculate I and I-1 on maple? Please help me! Thanks alot.

 

 

restart;

##########  omega and theta are variables,where J[3],F[2],H[2],etc are constants.

#### I tried with "evlf" and "evlc" command but maple was not ready to provide the solution,please help me to solve this

t1:=-1/(-16.*omega^2+exp(-4*omega)+exp(4*omega)-2.)*(-(0.5817764173e-1*I)*exp((2/9)*omega*cos(theta))*omega^5*cos(theta)*J[3]-(.6981317009*I)*exp((2/9)*omega*cos(theta))*omega^4*cos(theta)*H[3]-0.4524927691e-1*exp(.2222222222*omega*(cos(theta)-9.))*cos(theta)*omega^3*G[3]-.6205615118*exp(.1111111111*omega*(2.*cos(theta)-9.))*cos(theta)*omega^3*H[2]+.6205615118*exp(.1111111111*omega*(2.*cos(theta)-9.))*cos(theta)*omega^3*F[2]+.9308422676*exp(.2222222222*omega*(cos(theta)-9.))*cos(theta)*omega^4*H[3]-.1034269187*exp(.1111111111*omega*(2.*cos(theta)-9.))*cos(theta)*omega^3*G[2]-0.7757018900e-1*exp(.1111111111*omega*(2.*cos(theta)-9.))*cos(theta)*omega^2*G[2]-0.7757018898e-1*exp(.2222222222*omega*(cos(theta)-9.))*cos(theta)*omega^4*J[3]-0.9696273622e-1*exp(.2222222222*omega*(cos(theta)-9.))*cos(theta)*omega^3*J[3]-0.4524927691e-1*exp(.2222222222*omega*(cos(theta)-9.))*cos(theta)*omega^2*J[3]-.2714956613*exp(.2222222222*omega*(cos(theta)-9.))*cos(theta)*omega^2*H[3]-0.7757018898e-1*exp(.2222222222*omega*(cos(theta)-9.))*cos(theta)*omega^4*G[3]+0.8726646261e-1*exp((2/9)*omega*cos(theta))*omega^3*J[3])*cos((2/9)*omega*sin(theta));

t2:=int(int(t1,omega=0..infinity),theta=0..2*Pi);

 

 

Is there any Maple command to detect whether the degree of a polynomial w.r.t. all variables is less or equal 1?

For example, if $f=ax+by-1$ when $x$ and $y$ are variables then the output is true and if $g=a*x^2+b*y-c$ then it returns false. 

Problem copying a document to Maple Cloud (Public domain)

• Reset password

• Verified email is correct

• Chose File → Save to Cloud... (or clicked Send Document to Cloud on Maple Cloud palette) either way opend Login dialog

• Entered  Account = Maplesoft account, my Email and password then clicked Log in.  The following message appears: "The account type or email address or password is incorrect"

I've saved .mw files to Maple Cloud before with no problems.  Any help appreciated.

Thanks, Les

First 557 558 559 560 561 562 563 Last Page 559 of 2308