C_R

3527 Reputation

21 Badges

6 years, 54 days

MaplePrimes Activity


These are replies submitted by C_R

@Carl Love 
Do you use any non default GUI options?

If it is that frequent for you, you could maybe test

  • if cursor control of menus works. I.e.: does arrow right on your keyboard opens the sub menues.
  • does my workarround also work for you
  • does it depend on the mouse you are using (I don't think so, but I am waiting for an occasion that I can check myself)

Update. I could test:
Menus can still be controlled with the keyboard cursor.
I could not see a dependency on the computer mouse.

In your worksheet solve returns the 3 roots of period_eqn.
One real valued and two complex solutions.

Maybe its clearer this way
 

restartNULL

mu := 398600

398600

(1)

T := 2*3600

7200

(2)

period_eqn := T = 2*Pi*sqrt(a^3/mu)

7200 = (1/19930)*Pi*3986^(1/2)*(a^3)^(1/2)

(3)

sol_a := solve(period_eqn, {a})

{a = 600*23916^(1/3)/Pi^(2/3)}, {a = -300*23916^(1/3)/Pi^(2/3)+(300*I)*3^(1/2)*23916^(1/3)/Pi^(2/3)}, {a = -300*23916^(1/3)/Pi^(2/3)-(300*I)*3^(1/2)*23916^(1/3)/Pi^(2/3)}

(4)

whattype(sol_a)

exprseq

(5)

NULL

NULL


 

Download hw8_reply.mw

@vv 

Not in 2D (what I tried before asking). Thanks

@Axel Vogt 

This is what I meant: the File Explorer of Windows.

Before Windows 8, the File Explorer was termed Windows Explorer.

I will correct this.

@Carl Love 

I could not paste it as 1D. Pasting it in a Codeedit region works and produces a list of all files. 

Thank you for the answer.

 

I could not figure out what "?:=" does. Is that documented?

 

 

@zenterix 

The only documentation I read was the programming guide. To me it is more than a programming guide because it explains for a good extend Maples foundation. Maybe you should ask for a recommendation in a separate thread.

 

@salim-barzani 

Generate a plot for each parameter and then use plots:-display to plot all in once. Additionally you can use the legend option to label the plot, see ?plot,options

@salim-barzani 

I do not have time to look at it. What I see from the screen shots is that the solution does not look strucurally identical

I those situations I would enter the text book solution first and see how it plots. Then I would investigate the own solution.

@nm 

I am not aware of such a setting but I see that it could make sense as a GUI option. Maple has control over the cursor position since it is needed for editing. I assume that the initial cursor setting is unsing a Java default. Only Maplesoft can tell if this is correct.

Rondom jumps of the cursor position is something which should not happen. Maybe it is the cause that I get from time to time a split of 1D input into two lines of an execution group. I.e. enter is working as "shift enter" and creates a new line inside and execution group. I have to use "!" to execute. I never understood  why and when this happens.

@zenterix 
You must do it by hand, because the output of solve is a simplification endpoint of Maple (what Maple considers as "simple"). Compare
 

sqrt(-2*gamma__b^2 + 4*omega__0^2)/2;
(%^2)^(1/2);

 

It did not change with 2024.1. I tested it with 2024.0 which I could install in parallel.

However, a test with Maple 2018 shows that the former Java runtime environement sets the cursor at the start as you remembered.

 

@Carl Love 
This looks promissing, however so far I can only list Maple files in a directory but no subdirectories.

As I understand the help page this should list all *.mw files (but it does not)
 

FileTools:-ListDirectory("C:/", 'select' = "*.mw", 'depth' = 40);

 

@salim-barzani 
Not really for a 3d plot. You have to reformulate your problem. A third parameter is required in your complex expression that can be used in an amination call.

Or if 2d is OK for you, paste this into my reply at the very end

plots:-animate(plot, [map(Re, solnum), x = -50 .. 50], t = -50 .. 50, axes = boxed);
plots:-animate(plot, [map(Im, solnum), x = -50 .. 50], t = -50 .. 50, axes = boxed);


 

@salim-barzani 

Shure:

 

restart;

local gamma:

NULL

Added random values for the parameters theta and gamma

params := {alpha = 2.5, k = 3, w = 2, beta[3] = 3, beta[4] = 1.7,theta=0,gamma=1};

{alpha = 2.5, gamma = 1, k = 3, theta = 0, w = 2, beta[3] = 3, beta[4] = 1.7}

(1)

xi := sqrt(-1/(72*alpha*beta[4]+72*gamma*beta[4]))*(2*alpha*k*t+x)

(-1/(72*alpha*beta[4]+72*gamma*beta[4]))^(1/2)*(2*alpha*k*t+x)

(2)

We perhaps want to plot the magnitude and color it with the phase - so make [mag, phase]

sol1 := [U(xi), -k*x -(9*alpha*k^2*beta[4] + 2*beta[3]^2)/(9*beta[4])*t + theta];

[U((-1/(72*alpha*beta[4]+72*gamma*beta[4]))^(1/2)*(2*alpha*k*t+x)), -k*x-(1/9)*(9*alpha*k^2*beta[4]+2*beta[3]^2)*t/beta[4]+theta]

(3)

Assume some functional form for U(xi)

sol2 := eval(sol1, U(xi) = -beta[3]/(3*beta[4]) + beta[3]*sinh(xi)/(6*beta[4]*cosh(xi)) + beta[3]*cosh(xi)/(6*beta[4]*sinh(xi)));

[-(1/3)*beta[3]/beta[4]+(1/6)*beta[3]*sinh((-1/(72*alpha*beta[4]+72*gamma*beta[4]))^(1/2)*(2*alpha*k*t+x))/(beta[4]*cosh((-1/(72*alpha*beta[4]+72*gamma*beta[4]))^(1/2)*(2*alpha*k*t+x)))+(1/6)*beta[3]*cosh((-1/(72*alpha*beta[4]+72*gamma*beta[4]))^(1/2)*(2*alpha*k*t+x))/(beta[4]*sinh((-1/(72*alpha*beta[4]+72*gamma*beta[4]))^(1/2)*(2*alpha*k*t+x))), -k*x-(1/9)*(9*alpha*k^2*beta[4]+2*beta[3]^2)*t/beta[4]+theta]

(4)

insert numerical values

solnum :=eval(sol2, params);

[-.5882352940+(.2941176471*I)*sin(.7247137946*t+0.4831425297e-1*x)/cos(.7247137946*t+0.4831425297e-1*x)-(.2941176471*I)*cos(.7247137946*t+0.4831425297e-1*x)/sin(.7247137946*t+0.4831425297e-1*x), -3*x-23.67647059*t]

(5)

#plots:-complexplot3d(solnum, x = -50.. 50, t = -50..50);

P := Array(1 .. 2); P[1] := plot3d(map(Re, solnum), x = -50 .. 50, t = -50 .. 50, title = Re); P[2] := plot3d(map(Im, solnum), x = -50 .. 50, t = -50 .. 50, title = Im); plots:-display(P)

 

 

 

 

 

 

subs(x = Re(z), t = Im(z), solnum); plots:-complexplot3d(%[1], z = -50-50*I .. 50+50*I)

[-.5882352940+(.2941176471*I)*sin(.7247137946*Im(z)+0.4831425297e-1*Re(z))/cos(.7247137946*Im(z)+0.4831425297e-1*Re(z))-(.2941176471*I)*cos(.7247137946*Im(z)+0.4831425297e-1*Re(z))/sin(.7247137946*Im(z)+0.4831425297e-1*Re(z)), -3*Re(z)-23.67647059*Im(z)]

 

 

NULL

 

Download complexplot3d_reply.mw

I have never seen this before but I remember that you run Maple with modified kernelopts settings form default values.
When exactly do you get this message? After having executed input involving kernelopts?

First 22 23 24 25 26 27 28 Last Page 24 of 69