Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

I have a mapleTA question that blocks students from starting a mastery assignment until I tell them how to do the problem. But some students are gaming it but finding out the problem from an earlier section. I want to game back by making the answer change depending on the wall clock, that is the section they are in. To do so, I need a clock function to tell the time. Since I can call maple inside mapleTA, a maple solution will also work.

ElasticBeam.mw

 

Does anyone have any idea why I'm getting this plotting error? This should be working!!! Ahhh.

Hello,

I need some help with plotting the function with varying variables lambda and m ( varying from 0.1 to 1) which subject to the mutual constraint.

My function is:

> d:=(lambda, m) -> (0.1281008386e-3*m*lambda*(20.004936*lambda+21.004936*m+1)^2/(lambda+m)^2+0.1281008386e-3*(21.004936*lambda+21.004936*m-m*(1-lambda))^2/(lambda+m)^2)-(0.2690752038e-2+0.2690752038e-2*m*lambda);

The constraint is:

 

Is there a way to have interval arithmetics for complex inputs
(maple seems to name that range arithmetics in the help)?

x:=Pi/5;
shake(x);

              INTERVAL(0.628318529462 .. 0.628318531974)

shake(x*I);

    Error, (in evalr/shake) not a real number

Hi all,

I have gone through the help pages in my Maple 12, but cudn't really solve for roots of more than 1 pollynomial equations in parametric form. (I saw roots,parametric pollynomial function etc. & many more but cudnt do it with success).

my equations are coupled like, for example,

axy + bx - c*x*(x+y) = 0,

dxy + ey - f*y*(x+y) = 0,

etc. and I need the roots (x,y...

Dear guides

I have an equation: "eq := Pi-arcsin(sqrt(2E)/sqrt(1+E))-arcsin(sqrt(2E)/sqrt(2+E))-2*sqrt(2E)=0;

when I use "solve" maple say: "Warning, solutions may have been lost" and get a bad result. How can I ontain a better answer?

thanks.

The goal of computing only a select number of eigenvectors of a real symmetric floating-point Matrix comes up now and then. For very large Matrices the memory requirements can be more restrictive than the timing.

The attached worksheet and code computes this, more quickly and with significantly less memory allocation than does the usual task of computing all eigenvectors. By using the supplied Matrix itself as a partial "workspace" the amount of additional workspace and memory allocation for the task is negligible.

For example, having created the very large Matrix in the first place,  essentially no significant further memory allocation is required to compute the largest eigenvalue and its associated eigenvector.

A little about this routine `SelectedEigenvectors` follows.

It only works in hardware double precision. It expects a float[8] datatype Matrix (because you are serious about using minimal memory!). It uses the CLAPACK function dsyevx, using the "wrapperless" version of Maple's external-calling mechanism. It seems to work fine in the systems I've tried so far: Maple 13 and 14 on both 32bit and 64bit Linux and Windows.

Whether it computes and returns the selected eigenvectors (alongside the selected eigenvalues, which are always returned) is controlled by the 'vectors=truefalse' optional argument. By default it uses the Matrix argument as partial workspace and so destroys the original data; but this can be overridden with the 'preserve=true' optional argument. The requested accuracy can be relaxed with the 'epsilon=float' optional argument, which might sometimes speed it up.

The input Matrix is presumed to be symmetric. By default it uses the data in the lower triangle, but this can be changed to be the upper triangle with the 'uplo' optional argument.

The choice of eigenvalues is controlled by the two integer arguments `il` and `iu`. If il=iu=n then only the nth largest eigenvalue is computed. If il=1 and iu=4 then the four smallest eigenvalues are computed.

It returns three things: a Vector of dimension n whose first m entries are the selected eigenvalues, a nxm Matrix whose columns are the m associated eigenvectors, and a Vector of dimension n whose entries indicate whether corresponding eigenvectors failed to converge.

I didn't enable float arguments such as `vl` and `vu` which in principle could allow one to supply a floating-point range in which to find eigenvalues.

I didn't make an optimization of having it do an initial "dummy" external call in which no calculation would be done, but which would instead query for and subsequently utilize the optimal-performance additonal float workspace size.

For reasons mysterious to me, on Windows the 64bit version runs almost exactly half as fast as the 32bit version.

Usually, the workspace for eigen-solving is implemented to be at least O(n^2) for an nxn Matrix. But this routine does only O(m+n) extra workspace allocation to compute the m eigenvectors. And that is linear. Which is the Big Deal.

A 5000x5000 datatype=float[8] (ie. hardware double precision) Matrix takes 200MB of memory. With the preserve=true option, this routine can compute just the largest eigenvector with only about 200MB of additional allocation. And if the original Matrix is no longer required then with the preserve=false option this routine can do that task with less than 1MB further allocation. In comparison, the regular LinearAlgebra:-Eigenvectors command would require about 600MB of additional memory allocation while computing all eigenvectors.

At size 5000x5000 this routine is only about four times faster than LinearAlgebra:-Eigenvectors. I suspect that is because it still has to compute in full the reduction to tridiagonal form.

Download dsyevx.mw

How could I have information of serial of a hard disk in Maple? Thank you very much!

Hey Guys, 

 

I have plotted the following graph, its the position of an elementary volume before a supernovae takes place.

 

x0=r0sinθ0cosΦ0

y0=r0sinθ0sinΦ0

z0=r0cosθ0

 

Created a mesh of 10 mesh points, divided the ranges  

0<r<1

0<θ<∏

Hey,

suppose I have got two quadratics varying with variable Q1 and two quadratics varying with Q2,

eg. P1=a+b*Q1^2 and P11=c+d*Q1^2

     P2=e+f*Q2^2 and P22=g-h*Q2^2

where a,b,c,d,e,f,g and h are finite constants such that curves P1 and P11 intersect at two values of Q1, one being negative and the other positive. The same is true for curves P2 and P22. Now, I can plot curves P1 and P2 on a 3D plot (x-axis = Q1 and y-axis=Q2 and z-axis=P1=P2...

I hope that someone will prove useful. Especially - for beginners

ani.zip

I am to solve this differential equation (nonlinear):

 

C'(t) = G[0]+0.1*sqrt(C(t))-C(t)*n+C[ude]*n

G[0] = 1.7*1.2*83

n = 6

C[ude] = 417

 

i need to use programming since the DE is nonlinear.

 

Does anybody have the solution to that?

Thanks in advance.

Best regards,

Marie

f:=x->x^3:
y[1]:=0.5:
y[3]:=subs(x=y[1],f(x)):
i := 2:
y[i] := y[i-1]-(y[1]-y[2+1])*(1/2):
i:=1:
g[i] := (y[i+1]-y[i+2])*x/(y[i]-y[i+1])+(y[i+2]*y[i]-y[i+1]*y[i+1])/(y[i]-y[i+1]):
g[i] := unapply(g[i], x):
h[i] := unapply(solve(y = g[i](x), x), y):
for i from 2 by 1 to 7 do
g[i]:=(f@h[i-1])(x);
g[i]:=unapply(g[i],x);
y[i+2]:=subs(x=y[i+1],g[i](x));
s:=solve(z=g[i](x),x);
h[i]:=unapply(s[1],z);
end do:

for i from -1 by -1 to -8 do

Is it possible to write a Maple program which prints itself and only itself?

Hey guys I'd be grateful if you can help me plot the following graph. It's the position of an elementary volume before a supernova takes place.

 

x0=r0sinθ0cosΦ0

y0=r0sinθ0sinΦ0

z0=r0cosθ0

 

create a mesh of 10 mesh points, divide the ranges

0<r<any positive value

First 1733 1734 1735 1736 1737 1738 1739 Last Page 1735 of 2234