MaplePrimes Questions

Hi,

How do I solve numerically this set of equations with the following ICs to plot U1(x), phi(x),diff(phi(x),x) versus x:

diff(U1(x),x)=-diff(phi(x),x)/(U1(x)-T/U1(x));
diff(phi(x),x$2)=(1+A1*phi(x)+A2*phi(x)**(3/2)+A3*phi(x)**2)-(M1/U1(x));
where

A1:=(2*k-1)/(2*k-3);
A2:=8*sqrt(2/pi)*(beta-1)*k*Gamma(k)/(3*Gamma(k-0.5)*(2*k-3)**(3/2));
A3:=(4*k**2-1)/(2*(2*k-3)**2);
M1=0.1+sqrt(T+(1/A1));
(Gamma is gamma function)

assume, for example, T=0.1, pi=3.14, beta=0.6, k=3.5

ICs:

U1(x=0)=M1, phi(x=0)=0, diff(phi(x=0),x)=0.001.

Thanks.

I know we can use Maple LPSolver for linear programming problem (eg. https://www.maplesoft.com/support/help/Maple/view.aspx?path=Optimization/LPSolveMatrixForm), while I am wondering if we can use maple to solve a LP problem symbolically when some of the constants in those examples are unknow parameters.

If no, any suggestions of other solutions?I guess I have to do the simplex method manually? Thanks.

From help, it says

coulditbe routine returns true if there is a possible value of x1 that satisfies prop1

my question is, how to find out this condition/possible values that Maple found?  This infomration is very useful, but now I do not see how to obtain it. All what coulditbe retuirn is true or false.

Context of why I am asking:  Sometimes odetest do not verify its own solutions. And coulditbe can help in finding under what conditions the solution can satisfy the ode. Here is an example

restart;
ode:=diff(y(x),x) = abs(y(x))+1;
solExplicit:=dsolve(ode);
offset := odetest~([solExplicit],ode)

gives

[exp(-x)/_C1 - abs((-exp(-x) + _C1)/_C1) - 1, exp(x)*_C1 - abs(exp(x)*_C1 - 1) - 1]

Both solution fail odetest. 

coulditbe~(offset,0)

gives true

So there are assumptions/conditions which makes the solution satisfy the ODE. In this case, by inspection one can see what these conditions are. They are, for one solution:

(-exp(-x) + _C1)/_C1  >0

and for the other, the condition is

exp(x)*_C1 - 1 >0

Under these assumptions, odetest would have given 0 for each odetest.

And it is this information I wanted to obtain automatically from coulditbe.

In Mathematica, Reduce is used for this. Reduce gives conditions under which something is satisfied. For example, 

Reduce[ C[1] Exp[x] - Abs[C[1] Exp[x] - 1] - 1 == 0, {x, C[1]}, Reals]

Gives

C[1] >= Exp[-x]


While the above in  Maple

coulditbe( C[1]*exp(x)- abs( C[1]*exp(x)-1)-1 = 0)

gives true  only, but without the important information, true under what conditions.

Is there a different command in Maple which could give this information?

Hello, dear forum users!

Does anyone use the method of homotopy analysis (HAM) and the NOPH package in their work. (moderator: link)
 


It seems to me that only HAM can help.

I ask for help if someone has already mastered.

There are no developments, as I do not own the NOPH package.

Could anyone help me with: How to start a command-line terminal for Maple in Linux Ubuntu? Thanks a lot

Hi there.

I need to calculate multiplcations of huge polynoms with reducing in GF(2^m) with m>1000.

For example, modpol(a*a,f_t,t,2^N) with N=4007, degree(a)=8008 and degree(f_t)=8009.

Standard modpol calculates this in 4-5 sec on my computer.

Maybe there is an easy way to speed up this calculation?

Thank you.

ex.mw

nn.txt

Hi all,

I am new to maplesim and trying to learn it.

While simulation of the battery operated 4 wheeled driven electric vehicle 

it tells can't find solution.

 

 

Same time if i connect a fixed reference all four wheels are running (same place) but not moving since the frame fixed.

 

HELP ME TO SOLVE THIS.

 

thank you..

 

Hi everyone,

I am trying to integrate this function, however, it did not generate any results. Is there any chance to make this run?
 

I0 := 1/sqrt(1-C2OverC1*cos(t))^3

1/(1-C2OverC1*cos(t))^(3/2)

(1)

`assuming`([int(I0, t = 0 .. 2*Pi)], [C2OverC1 > -1, C2OverC1 < 1])

``

``

``


 

Download ellipticIntegral.mw

Hello all, 

Would you please tell me how to rewrite the expression 'Is_square' like 'Is_square2'?

The way how the first expression is re-written is that both numerator and denominator were divided by 'sigma^2*omega[rK]^2': 

One attempt I made was to use 'algsub' command using the subexpression ''sigma^2*omega[rK]'', but somehow it missed the term in the denominator. 


 

restart;

Is_square := M[dmax]*(sigma^2*omega[rK]^2 + omega[r]^2)*L[sigma]/(3*p*omega[r]*omega[rK]*L[mu]^2*sigma^2);

(1/3)*M[dmax]*(sigma^2*omega[rK]^2+omega[r]^2)*L[sigma]/(p*omega[r]*omega[rK]*L[mu]^2*sigma^2)

(1)

Is_square2 := M[dmax]*(1 + omega[r]^2/(sigma^2*omega[rK]^2))*L[sigma]/(3*p*omega[r]*L[mu]^2/omega[rK]);

(1/3)*M[dmax]*(1+omega[r]^2/(sigma^2*omega[rK]^2))*L[sigma]*omega[rK]/(p*omega[r]*L[mu]^2)

(2)

algsubs(omega[rK]*sigma^2=tt, Is_square);

(1/3)*M[dmax]*L[sigma]*(tt*omega[rK]+omega[r]^2)/(p*omega[r]*L[mu]^2*omega[rK]*sigma^2)

(3)

 


 

Download Qprime_20200621.mw

 

Suppose I have

with(GraphTheory):
vertices:=["M","P","C"]:
edge_weights:={[{"M","P"},3],[{"M","C"},1]}:

G1:=Graph(vertices,edge_weights)

EigenvectorCentrality(G1)
                                                  

Is it right to say the EigenvalueCentrality values correspond to the names in the vertices correspondingly?  ie M corresponds to 0.4415.. P corresponds to  0.4188.. and C corresponds to 0.1396... ?

 

restart;
sub:=x/C;
expr:=1/2*x*(p^2+a)/p;

And now

subs(p = sub, expr)

But

algsubs(p = sub,expr)

Notice one "p" is still not replaced. 

This is very annoying. I looked at help and did not see anything about this. I could have missed it. It looks like it does not replace "p" when it is in denominator:

algsubs(p = x,1/p)

Remains 1/p but 

subs(p = x,1/p)

gives 1/x as expected.

May be this is documented somewhere? But why it does this?

This was generated when running some code on Maple 2020.1.

Just wondering if this might indicate some problem internally, or is this something that can happen.

restart;
ZZ:=Int(-(a*_a^2+(_a^4*a^2-4*_a*b*y(x))^(1/2))/(a*_a^3+_a*(_a^4*a^2-4*_a*b*y(x))^(1/2)+6*y(x)),_a = _b .. x)+Intat(-2/(a*x^3+x*(a^2*x^4-4*_f*b*x)^(1/2)+6*_f)-Int(2/(_a^4*a^2-4*_a*_f*b)^(1/2)*b*_a/(a*_a^3+_a*(_a^4*a^2-4*_a*_f*b)^(1/2)+6*_f)+(a*_a^2+(_a^4*a^2-4*_a*_f*b)^(1/2))/(a*_a^3+_a*(_a^4*a^2-4*_a*_f*b)^(1/2)+6*_f)^2*(-2*_a^2/(_a^4*a^2-4*_a*_f*b)^(1/2)*b+6),_a = _b .. x),_f = y(x))+_C1 = 0;

timelimit(30,value(ZZ))

Error, (in discont/zero) too many levels of recursion

The problem is that I am not able to trap the error. This does not work

try
ZZ:=Int(-(a*_a^2+(_a^4*a^2-4*_a*b*y(x))^(1/2))/(a*_a^3+_a*(_a^4*a^2-4*_a*b*y(x))^(1/2)+6*y(x)),_a = _b .. x)+Intat(-2/(a*x^3+x*(a^2*x^4-4*_f*b*x)^(1/2)+6*_f)-Int(2/(_a^4*a^2-4*_a*_f*b)^(1/2)*b*_a/(a*_a^3+_a*(_a^4*a^2-4*_a*_f*b)^(1/2)+6*_f)+(a*_a^2+(_a^4*a^2-4*_a*_f*b)^(1/2))/(a*_a^3+_a*(_a^4*a^2-4*_a*_f*b)^(1/2)+6*_f)^2*(-2*_a^2/(_a^4*a^2-4*_a*_f*b)^(1/2)*b+6),_a = _b .. x),_f = y(x))+_C1 = 0;
timelimit(30,value(ZZ));
catch:
  print("ignore");
end try;

Error, (in discont/zero) too many levels of recursion

Why can't one catch this error inside try/catch? It means the whole program can not  continue.

Maple 2020.1

 by using its expansion Write the Maple  program.

 

Type the Maple command string that calculates this expression for the number of n arbitrarily entered from the keyboard.Can you help me please ?

  1. a1 = x and for every n >= 1 ,   

write the Maple procedure that calculates the term a100 for x = 2.

 

First 251 252 253 254 255 256 257 Last Page 253 of 2142