emendes

225 Reputation

6 Badges

3 years, 322 days

MaplePrimes Activity


These are questions asked by emendes

Hello

Although I am (remotely) running the following piece of code in a linux machine with 256 GB of ram, the error msg "Execution stopped: Stack limit reached" comes out 

 

kernelopts(stacklimit);
NestList:= proc(f, x, n::nonnegint)
local R:= rtable(0..n, [x]), k;
   for k to n do R[k]:= simplify(f(R[k-1])) od:
   [seq(R)]
end proc:
n:=34;
yreal:=NestList(y-> 4*y*(1-y),1/8,n):

I have tried to increase stacklimit issuing the command "kernelopts(stacklimit=256000)" but to no avail.  Is there anything else I can do?  A similar code run successfully in a mac with Mathematica. 

Many thanks 

Ed

 

PS. The default kernelopts(stacklimit) shows 8192 on the linux machine and  but 32736 on the mac pro.  I was expecting a higher number on the linux machine.  

 

Hello

I need to add a legend to a figure using dataplot (I am not even sure that is the right option).  In what follows I show what I did.

 

dataplot([28,28,28],[.6481496576, .648149657615473, .6512873548],style='point',colorscheme=["Blue","Orange","Red"],	
labels = ["k", "y(k)"], legend = ["10-digit precision", "15-digit precision", "Floating-point iteration"] ,legendstyle = [font = ["HELVETICA", 9], location = right]);

The outcome is

As can be seen some parts of the legend are missing.

 

How can I get this right? Do I have other ways to do the same thing?  

 

Many thanks

 

Ed

 

Hello

I wonder how integrate can be applied term by term to the following nonlinear differential equation

(diff(y(t), t))*(diff(y(t), t, t, t))-(diff(y(t), t))*y(t)^2-(diff(y(t), t))*(diff(y(t), t, t))-(diff(y(t), t))*A*y(t)

The expected output will be something like 

(diff(y(t), t))*(diff(y(t), t, t))-(1/3)*y(t)^3-(1/2)*A*y(t)^2-(1/2)*(diff(y(t), t))^2+C+int((diff(y(s), s, s))^2, s = 0 .. t)
map(x-> integrate(x,t),(diff(y(t), t))*(diff(y(t), t, t, t))-(diff(y(t), t))*y(t)^2-(diff(y(t), t))*(diff(y(t), t, t))-(diff(y(t), t))*A*y(t))

solves most of it but not the first part. 

Many thanks

Ed

 

Hello

I know that anames( 'user' ) recovers the contents of the workspace but I wonder whether it would be possible to recover only the contents of each m-file read within a worksheet.  

Many thanks

Ed

 

Hello

I need to solve or reduce (similar to the command Reduce in Mathematica) sets of nonlinear equations.  One such example is shown below:

eqns := {-1+theta[3, 6] = 0, 1-theta[3, 6] = 0, alpha+rho-theta[2, 2]+theta[3, 3] = 0, -theta[3, 6]^2+1 = 0, theta[2, 2]*theta[3, 6]-alpha = 0, theta[2, 2]*theta[3, 6]^2-alpha = 0, -2*theta[3, 3]*theta[3, 6]-2*rho = 0, theta[1, 2]*theta[2, 1]*theta[3, 6]^2+1 = 0, -alpha^2+rho^2+theta[2, 2]^2-theta[3, 3]^2 = 0, -theta[2, 2]^2*theta[3, 6]+2*theta[2, 2]*theta[3, 3]*theta[3, 6]+alpha^2+2*alpha*rho = 0, -theta[1, 3]*theta[2, 2]^2*theta[3, 0]+theta[1, 3]*theta[2, 2]*theta[3, 0]*theta[3, 3]-alpha^2*beta-alpha*beta*rho = 0, -theta[1, 2]*theta[2, 1]*theta[2, 2]*theta[3, 6]+2*theta[1, 2]*theta[2, 1]*theta[3, 3]*theta[3, 6]-alpha-2*rho = 0, -theta[1, 2]*theta[2, 1]*theta[2, 2]*theta[3, 3]+theta[1, 2]*theta[2, 1]*theta[3, 3]^2+theta[1, 3]*theta[2, 2]*theta[3, 0]*theta[3, 6]+alpha*beta+alpha*rho+rho^2 = 0, -alpha^2*rho-alpha*rho^2+theta[1, 2]*theta[2, 1]*theta[2, 2]-theta[1, 2]*theta[2, 1]*theta[3, 3]+theta[1, 3]*theta[3, 0]*theta[3, 6]-theta[2, 2]^2*theta[3, 3]+theta[2, 2]*theta[3, 3]^2+alpha+beta+rho = 0}

 and the indeterminates are:

fc := {theta[1, 2], theta[1, 3], theta[2, 1], theta[2, 2], theta[3, 0], theta[3, 3], theta[3, 6]}

Since I do know the solution, I issued the following command to check for typos.

seq(subs(theta[1,2]=-1,theta[1,3]=-1,theta[2,1]=1,theta[2,2]=alpha,theta[3,0]=beta,theta[3,3]=-rho,theta[3,6]=1,eqns[i]),i=1..nops(eqns))

and the outcome is zero for all equations.

When I try the command solve as follows:

solve(eqns,fc);

the result is

{theta[1, 2] = theta[1, 2], theta[1, 3] = theta[1, 3], theta[2, 1] = -1/theta[1, 2], theta[2, 2] = alpha, theta[3, 0] = -beta/theta[1, 3], theta[3, 3] = -rho, theta[3, 6] = 1}

that should be right but it is not what I am expecting.  

How can maple return the solution needed?

 

Some sets of solutions do not have a solution as the one above.  Some indeterminates cannot be found, is there a way maple returns the solution of the ones that can be solved and reduced the set of equations into two parts, solved ones e non solved ones?  I can provide an example if needed.

 

Many thanks.

Ed

 

2 3 4 5 6 7 8 Page 4 of 9