MaplePrimes Questions

I am having trouble removing assumptions that are stored within expresssions.

Example code:

assume(l1>0): # this assumptions later helps to find a solution for a geometric problem with two four-bar-linkages
a := sqrt(l1);
save a, "test.m";
restart;
read "test.m"
a; # the assumptions are stored within the saved data
l1:='l1'; # try to remove the assumption
a; # assumption in a still existing
subs({l1=2}, a); # nothing happens: I can not access l1 any more
subs({l1~=2}, a); # This does not work either, nothing changes in a

So my question is: How do I remove the assumption within a stored expression?

My main problem lies in the handling of the expression with assumptions. At some point, I want to generate Matlab code, and the codegen-command gives me:

Warning, the following variable name replacements were made: l1~ -> cg

 

Hi all

I have  a simple question in export as eps format in Maple. i want the converted eps file with no box, but when i use export as eps by right click on plotted figure in Maple and then select " Export As--> Encapsulated PostScript(EPS)...", the below mentioned box(as in sample attached picture) will appear. How can I remove it? The Sample picture is attached. 

will be grateful of any guidance.

Thanks in advance

Mahmood   Dadkhah

Ph.D Candidate

Applied Mathematics Department

I'm trying to find lypunov exponent for this  system of ODEs. I know I need to take the Jacobian but not sure if it's possible the way it's currently defined. If anyone could provide insight it would be much appreciated.

Eqns:= diff(omega(t),t)=-(G*MSat*beta^(2)*(xH(t)*sin(theta(t))-yH(t)* cos(theta(t)))*(xH(t)*cos(theta(t))+yH(t)*sin(theta(t))))/((xH(t)^(2)+yH(t)^(2))^(2.5)),diff(theta(t),t)=omega(t), diff(xH(t),t)=vxH(t),diff(vxH(t),t)=-(G*M*xH(t))/((xH(t)^(2)+yH(t)^(2))^(1.5)),diff(yH(t),t)=vyH(t),diff(vyH(t),t)=-(G*M*yH(t))/((xH(t)^(2)+yH(t)^(2))^(1.5)): ;

ICs := omega(0) = omega0, theta(0) = theta0, xH(0) = a*(1+e), yH(0) = 0, vxH(0) = 0, vyH(0) = sqrt(G*M*(1-e)/(a*(1+e)));

I want the exponent for omega, I  procedure that takes some initial conditions, changing just w0, and computes the long term value of omega. This plots a sort of bifurcation diagram. I'd like an estimate of the exponent to compare what I see. 

thanks for the help

ft

Hello,

 

I want to compute powers of the Laplace-beltrami operator in some surface (e.g. cylinder):

 

https://en.wikipedia.org/wiki/Laplace_operator#Coordinate_expressions

 

and evaluate it for a given scalar function on the surface (e.g. a function on the cylinder).  I'm wondering if I only have to write the laplace-beltrami operator and then compute a simple power of it, or if I have to take care and compute the powers of the Laplace-beltrami operator first and then evaluate at the function on the cylinder. If the second option is the correct one (I think so), how can I compute that with maple? There is some trick way to compute powers of differential operators?

 

Thanks,

Fernando

Variable exists but is not shown when using save/read with extension .m

My example maple code is

 

a:=b^2:

save a, "test1.m"

restart:

read "test1.m"

a;

 

after the read command, I can access the variable, but it is not shown under "Variables".

This lead to some confusion when debugging the worksheet. Can I change this somehow?

Using the input type file format is not a solution, since then reading takes forever for complicated expressions.

Further, in the read command documentation it says "This functionality is not intended for end users" for saving the file as .m. What does that mean?

I am a Mathematica user trying to make the switch to Maple, so first of all I apologise if I am making a stupid mistake here. The complete script is attached below.

I have the following line in my script:

    b := Trace(map(diff, HermitianTranspose(W), coords[1]) . map(diff, W, coords[1]))

W is a matrix defined earlier in the script. I can provide the context if it would help but I'm not sure if it's relevant to the issue I'm having. The problem is that

    simplify(b) assuming real, r>0

gives a vastly different result to

    simplify(Trace(map(diff, HermitianTranspose(W), coords[1]) . map(diff, W, coords[1]))) assuming real, r>0

How can this be? What can I do to make Maple simplify the expression correctly?

conifold_metric.mw

Hello, i am doing some schmidt-analysis on a stirling engine, but my question is rather simple. I have the measured presure P at a given time T as a 229x2 matrix, i also have a function, V__total(T), for the total volume of the engine at a given time T. 

I then go on to create a pointplot PV, which is rougly the shape of a potato. I now want to find the area enclosed by this point plot, is there any way? 

I do something like:

> DATA:=ImportMatrix(filepath,skiplines=1); %import data from .txt file, skip header line. 

>P:=DeleteColumn(DATA,1); %Isolate presure column

>T:=DeleteColumn(DATA,2); %Isolate time coliumn

>V:=V__total~(T); %Generate volume vector as a function of time T

>pointplot(<P|V>,connect=true);

Is there any wat to finde the area enclosed by the curve/ Int(P,V)

I don't know what is the problem with this. Please take a look at it. Any help is appreciated. Thanks.

restart

with(RealDomain)

[Im, Re, `^`, arccos, arccosh, arccot, arccoth, arccsc, arccsch, arcsec, arcsech, arcsin, arcsinh, arctan, arctanh, cos, cosh, cot, coth, csc, csch, eval, exp, expand, limit, ln, log, sec, sech, signum, simplify, sin, sinh, solve, sqrt, surd, tan, tanh]

(1)

with(Slode)

[DEdetermine, FPseries, FTseries, candidate_mpoints, candidate_points, dAlembertian_formal_sol, dAlembertian_series_sol, hypergeom_formal_sol, hypergeom_series_sol, mhypergeom_formal_sol, mhypergeom_series_sol, msparse_series_sol, polynomial_series_sol, rational_series_sol, series_by_leastsquare]

(2)

ODE := x*(diff(y(x), x, x))-(diff(y(x), x))-x*y(x)

x*(diff(diff(y(x), x), x))-(diff(y(x), x))-x*y(x)

(3)

SS := convert(sin(x), FormalPowerSeries)

Sum((-1)^k*x^(2*k+1)/factorial(2*k+1), k = 0 .. infinity)

(4)

FPseries(ODE = SS, y(x), v(n))

Error, the right-hand side of the differential equation must be a polynomial or a series in x

 

``

 

Download AA.mw

I want to obtain the taylor series of a function say sin(x) at x=0 up to infinity. I mean that I don't want a trauncated series. I tried using "series" and "taylor" but they just give the truncated series.

Well, long story short. Sat in class, got bored. Began thinking of how to plot different figures in maple.
This eventually leading to that of a rainbow. Anyone got a formula or something i can use to create one? :-)
Thanks ahead. :)

I have the following two PDEs:

PDE := diff(u(x, t), t) = diff(u(x, t), x, x)+sin(x+t)-cos(x+t);

IBC:= D[1](u)(0,t)=-sin(t),
D[1](u)(1,t)=-sin(1+t),
u(x,0)=cos(x);

pds := pdsolve( PDE, [IBC], numeric, time = t, range = 0 .. 1,
spacestep = 1/32, timestep = 1/32,
errorest=true
)

 

PDE2 := diff(v(x, t), t) = diff(v(x, t), x, x);
IBC2:= D[1](v)(0,t)=0,
D[1](v)(1,t)=-0.000065*v(1, t)^4,
v(x,0)=1;

pds1 := pdsolve( PDE2, [IBC2], numeric, time = t, range = 0 .. 1,
spacestep = 1/32, timestep = 1/32,
errorest=true
);

 

Now, what I want to do with these two PDEs is the following:

 

For each h=timestep=spacestep  = 1/16 , 1/32 , 1/64 , 1/128 , 1/256

Calculate the error norm ||E||_h = sqrt(sum_{j=0}^{1/h} h* |u(j*h,tval)-v(j*h,tval)|^2)

where tval is some chosen point between 0 and 1 (this value is fixed for each spacestep chosen).

 

And then plot the graph of log ||E||_h vs. log h above.

 

What I don't know is how to extract each time the spacestep and its PDE's two solutions, does someone have a suggested script to use here?

 

 

hello guys,

 

i have a system of autonomous equations which i want to plot its 3D phase space with directional field,

i have some problem with it :dy.mw , and i dont know how to command for add some directional field for 3D phase space .

 

thank you guys

 

Dear all;

Good morning everyone.

I solve a simple ode, i want how can I write this program as procedure with output the two coefficient involved in the solution, after solving with ics. i.e coef:=dsolve(ode);  in my example I want as output [4, -1] .

 

restart:
ode:=diff(y(x),x,x)=3*diff(y(x),x)-2*y(x);
coef:=dsolve(ode);
ics:=y(0)=3, D(y)(0)=2;
dsolve({ics,ode});

with best regards

 

I do not know! I am a novice in maple as well as in graph theory. I attach a doc in which i attempted to learn what is network. It seems alright with maple as it gives as what it understands as horizontal and vertical network. I do not expect a horizontal line as horizontal network and vertical line as vertical network, in which case a horizontal line with nodes 1 and 2 will be vertical network if  draw it vertically. The maple, in my opinion ( i am not a maple man) gives the answer in a vertical pattern, rightly so for clarity and space constraint.

I am sorry if i am confusing.  The document in my attempt to know more may give you also more insight. Thanks.

with(GraphTheory):

with(RandomGraphs):

N := GraphTheory:-RandomGraphs:-RandomNetwork(4, 0):

IsNetwork(N):

DrawNetwork(N, vertical)

 

with(GraphTheory):

with(RandomGraphs):

O1 := GraphTheory:-RandomGraphs:-RandomNetwork(4, 1):

GraphTheory:-IsNetwork(O1):

GraphTheory:-DrawNetwork(O1, vertical)

 

``

with(GraphTheory):

with(RandomGraphs):

P := GraphTheory:-RandomGraphs:-RandomNetwork(4, 0):

GraphTheory:-IsNetwork(P):

GraphTheory:-DrawNetwork(P, horizontal)

 

with(GraphTheory):

with(RandomGraphs):

Q := GraphTheory:-RandomGraphs:-RandomNetwork(4, 1):

GraphTheory:-IsNetwork(Q):

GraphTheory:-DrawNetwork(Q, horizontal)

 

``

 

Download MyAttempt.mwMyAttempt.mw

Why maple is not plotting the whole surface in the domain specified?

Thanks for the help.

First 1188 1189 1190 1191 1192 1193 1194 Last Page 1190 of 2428