Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

Dear all,

I'm having a bit of trouble figuring out some error messages in the Maple debugger. When I debug some procedures I'm getting error messages like "Error, invalid input: %1 expects its %-2 argument, %3, to be of type %4, but received %5". Since the procedure calls a lot of other procedures I have to check every single one of them, to see, which one gives me the error message. It would be easier if I would know, what procedure/type hides behind the variables %1,... Is there a way to check this from within the debugger?

Thanks a lot.

Im working on an assignment involving a rocket being launched vertically from rest. 
I have a eq. of motion that looks like this: v(t)=vs*ln(-m0/(r*t-m0))-g*t

Now Im supposed to implement the air resistance, and write an expression for the total force on the rocket. After that creating a plot displaying the speed v(t) as a function of time for both, with and without air resistance. 

All constants are known including CD, rho and A for the dragforce. 

I would be grateful if anyone could help me with this!

Thanks

Hello altogether,

I want to plot the numerical result of an ODE, which seems to be pretty simple at first sight, but the difficulty is that the boundaries are depending on the solution.

The following pseudo-code describes what I want to have, but it doesn't work. This code fills the RAM pretty fast and you will have to kill the process.

Free-boundary_prob.mw

Is it possible to calculate a solution to this problem numerically (or even analytically) and if yes, how?

Since I am new here, I am sorry for any bad-to-read maple code or any noob errors I have made. I would be very thankful, for any response and help.

Greetings

butterflyfart

sys := [(diff(c(t), t))*(diff(a(t), t))*(diff(b(t), t))+(diff(c(t), t))*t^2, (diff(c(t), t))*(diff(a(t), t))*t+(diff(c(t), t))*t*(diff(b(t), t)), (diff(c(t), t))*(diff(a(t), t))*(diff(b(t), t))+(diff(c(t), t))*(diff(a(t), t))*t+(diff(c(t), t))*t^2]
DEplot(sys, [a(t), b(t), c(t)], t = 0 .. 2, a = -15 .. 15, b = -15 .. 15, c = -15 .. 15, color = magnitude, title = `Stable Limit Cycles`, arrows = curve, dirfield = 800, axes = none);
odeplot(sys, [t, a(t), b(t), c(t)], -4 .. 4, color = orange);

with(RegularChains);
with(ConstructibleSetTools);
source1 := PolynomialRing([a, b, c, d]);
target1 := PolynomialRing([e1, e2, e3, e4]);
source1list := [eq2a, eq3a, eq4a, 0];
target1list := [eq2b, eq3b, eq4b, eq5b];
cs := PolynomialMapPreimage(target1list, source1list, source1, target1)

return
cs := constructible_set

then i type
Elements(constructible_set)

it return 

Elements(constructible_set)

 since source has less number of variables, in order to use this function

i add a dummy variable d to this and use 0 for the fourth equation

Dear Collagues

I wrote a code to solve a system of ode numerically. When the equations have been solved, I want to find the value of MTE which is in integral form. I check and see that the value of MTE is calculated wrong. I dont know why?

I calculated the values of MTE twice (another variable is masst below res1). Two different answers!!

I would be most grateful if you could help me.

Thank you

Here is my code

 

 

restart:
EPSILONE:=1:
#Digits:=10:

a[mu1]:=39.11:
b[mu1]:=533.9:
a[k1]:=7.47:
b[k1]:=0:

rhop:=5180:
rhobf:=998.2:
#gama1:=0.2;
mu1[bf]:=9.93/10000:
k1[bf]:=0.597:

rhost(eta):=1-phi(eta)+phi(eta)*rhop/rhobf;
#mu:=unapply(mu1[bf]/(1-phi(eta))^2.5,eta);
mu:=unapply(mu1[bf]*(1+a[mu1]*phi(eta)+b[mu1]*phi(eta)^2),eta);
#mu1[bf]:=9.93/10000:
k:=unapply(k1[bf]*(1+a[k1]*phi(eta)+b[k1]*phi(eta)^2),eta);
mu(eta)/mu1[bf];


#eq1:=diff((mu(eta)/mu1[bf])*diff(u(eta),eta),eta)+rhost(eta)-Ha^2*u(eta);
eq1:=(a[mu1]*(diff(phi(eta), eta))+2*b[mu1]*phi(eta)*(diff(phi(eta), eta)))*(diff(u(eta), eta))+(1+a[mu1]*phi(eta)+b[mu1]*phi(eta)^2)*(diff(u(eta), eta, eta))+rhost(eta)-Ha^2*u(eta);
eq2:=diff((k(eta)/k1[bf])*diff(T(eta),eta),eta);
eq3:=diff(phi(eta),eta)+phi(eta)/(N_bt*(1+gama1*T(eta))^2)*diff(T(eta),eta):
eq2:=subs(phi(0)=phi0,eq2);
eq3:=subs(phi(0)=phi0,eq3);



eval(dsolve({eq3,phi(1)=phiv},phi(eta)),(T)(1)=1);
Phi:=normal(combine(%));
Teq:=isolate(eval(eq2,Phi),diff(T(eta),eta));
ueq1:=eval(eq1,Phi)=0:
ueq2:=subs(Teq,ueq1):


Agama1:=<<0.1>,<0.2>,<0.3>>:
ANBT:=<<0.2>,<1>,<10>>:
Aphiv:=<<0.02>,<0.06>,<0.1>>:
lambda:=0;
Ha:=0;
#NBT:=0.5:
N_bt:=cc*NBT+(1-cc)*10;
#phiv:=0.02:
 
kratio:=k1[p]/k1[bf];




eq1;
eq2;
eq3;

res1 := dsolve(subs(NBT=1,gama1=0.3,phiv=0.06,{eq1,eq2,eq3,u(0)=lambda*D(u)(0),D(u)(1)=0,T(0)=0,phi(1)=phiv,T(1)=1}), numeric,method=bvp[midrich],output=listprocedure,continuation=cc):
G0,G1,G2:=op(subs(subs(res1),[phi(eta),u(eta),diff(T(eta),eta)])):

masst:=evalf(int((1-G0(eta)+G0(eta)*rhop/rhobf)*G1(eta), eta = 0..1));
heatt:=(1+a[k1]*G0(0)+b[k1]*G0(0)^2)*G2(0);



for iNBT from 1 to 3 do

for iphi from 1 to 3 do

for igamma from 1 to 3 do

res := dsolve(subs(NBT=ANBT(iNBT),gama1=Agama1(igamma),phiv=Aphiv(iphi),{eq1,eq2,eq3,u(0)=lambda*D(u)(0),D(u)(1)=0,T(0)=0,phi(1)=phiv,T(1)=1}), numeric,method=bvp[midrich],output=listprocedure,continuation=cc):
F0,F1,F2:=op(subs(subs(res),[phi(eta),u(eta),diff(T(eta),eta)])):
MTE[iNBT,iphi,igamma]:=evalf(Int((1-F0(eta)+F0(eta)*rhop/rhobf)*F1(eta), eta = 0..1)):
HTC[iNBT,iphi,igamma]:=(1+a[k1]*F0(0)+b[k1]*F0(0)^2)*F2(0):

end do;

end do;

end do;

for iNBT from 1 to 3 do

for iphi from 1 to 3 do

for igamma from 1 to 3 do



print (convert(HTC[iNBT,iphi,igamma],float,9));

end do;

end do;

end do;
for iNBT from 1 to 3 do

for iphi from 1 to 3 do

for igamma from 1 to 3 do


print (convert(MTE[iNBT,iphi,igamma],float,9));

end do;

end do;

end do;


 

Amir

1.

with(RegularChains):
with(ConstructibleSetTools):
source1 := PolynomialRing([a,b,c]);
target1 := PolynomialRing([e1,e2,e3,e4]);
source1list := [eq2a, eq3a,eq4a];
target1list := [eq2b, eq3b, eq4b,eq5b];
cs := PolynomialMapPreimage(target1list, source1list, source1, target1);

Error, (in RegularChains:-ConstructibleSetTools:-PolynomialMapPreimage) number of map functions is different from number of variables in target space

 

in maple 15 do not have error, however now it has error for the code below

with(RegularChains): with(RegularChains): with(ConstructibleSetTools): 

source1 := PolynomialRing([e1, e2, e3]);
target1 := PolynomialRing([a, b, c]);
source1list := [-1*e1+2*e2+*e3, -1*e1+2*e2+*e3, -1*e1+2*e2+*e3];
target1list := [.....]; cs :=
PolynomialMapPreimage(target1list, source1list, source1, target1);

Error, invalid product/quotient

 

 

Hi guys,

 

i want to find d'alembertian of a function of Ricci scalar (f(R)) , but it seems something is wrong .

 

f(R).mw

 

thanks in advance

in harmonic ocillator version, why it has error after it dsolve?

with(Physics[Vectors]):
with(SumTools):
Setup(mathematicalnotation = true):

Qs is Qss*cos(m*t+phi);

H := 1/(8*Pi*c^2)*Summation(Commutator(diff(Qs*cos(w*t+phi),t)*diff(conjugate(Qs*cos(w*t+phi)),t)+w^2*Qs*cos(w*t+phi)*conjugate(Qs*cos(w*t+phi))),ks=1..3)-1/c*(Summation(conjugate(Qs*cos(w*t+phi)),ks=1..3));

or

H := 1/(8*Pi*c^2)*Summation(Commutator(diff(Qs,t)*diff(conjugate(Qs),t)+w^2*Qs*conjugate(Qs)),ks=1..3);

#Qs = p, Ps := Pss*sin(m*t+phi) Ps = qs

i use

H := 1/(8*Pi*c^2)*Summation(Commutator(diff(Qs*cos(w*t+phi),t)*diff(conjugate(Qs*cos(w*t+phi)),t)+w^2*Qs*cos(w*t+phi)*conjugate(Qs*cos(w*t+phi))),ks=1..3)-1/c*(Summation(conjugate(Qs*cos(w*t+phi)),ks=1..3));

 HJ := subs(Qs= diff(f(q,P,t), q), H);

H:=subs( f(q,P,t) = f1(q) + f2(t), HJ);
sol:=dsolve({rhs(H)=E,lhs(H)=E});
S:=rhs(sol[1][1]+sol[1][2]);
p:=diff(S,q);
Q:=diff(S,E);

Hello

when i am trying to isolate for Rev in the following expression

the program doesnt respond.do you know why?

I have tried without sucess to run the

Equation manipulator.

I get the following error:

"

Error, (in Maplets:-Tools:-CleanElements) invalid input: op expects 1 or 2 arguments, but received 0

"

Do I have to load some package for it to run?

I have searched for a solution but can not find one.

Getting desperate.. anyone?

TIA

LWc

Hi

How  can we draw diagrams in tripartite coordinate system?

Hello,

How to Factorize the coefficients of this matrix :

 

> A:=Matrix([[x^3+x-2,x^2+x],[x,x+1]]);

 

factor(A) does not work !

 

Thank you,

Gérard.

There is a desire to explore the process of filtration combustion. To do this, you must solve a system of differential equations in partial derivatives.
I write down all the equations.
Boundary conditions in Maple 2015.0 interpreted incorrectly.
I need to write like that:

 

 

given that:


It turns out so:

 

 

ie somewhere lost derivatives

,....

 

 

As in Maple record boundary conditions correct?

Thanking you in advance.

First 189 190 191 192 193 194 195 Last Page 191 of 2218