Hullzie16

438 Reputation

10 Badges

6 years, 173 days

MaplePrimes Activity


These are questions asked by Hullzie16

I am trying to plot a function where one of the variables is determind via a procedure that uses fsolve and depends on some parameters. When I go to try and make a plot using Explore to vary the parameters I get the following error:
"in fsolve  S  is in the equation, and is not solved for"
My worksheet is seen below:

restart;

 

T := 2^(2/3)*(16*CC(S,mu,Z,Pr)^2*Pi^2 + 2*Pi^2*Z^2 + 16*Pi*S*CC(S,mu,Z,Pr) + 3*S^2)*Pr^(1/3)/(4*(4*CC(S,mu,Z,Pr)*Pi + S)^(2/3)*(2*Pi^2*Z^2 + 4*Pi*S*CC(S,mu,Z,Pr) + S^2)^(2/3)*CC(S,mu,Z,Pr)^(1/3)*Pi^(2/3))

(1/4)*2^(2/3)*(16*CC(S, mu, Z, Pr)^2*Pi^2+2*Pi^2*Z^2+16*Pi*S*CC(S, mu, Z, Pr)+3*S^2)*Pr^(1/3)/((4*CC(S, mu, Z, Pr)*Pi+S)^(2/3)*(2*Pi^2*Z^2+4*Pi*S*CC(S, mu, Z, Pr)+S^2)^(2/3)*CC(S, mu, Z, Pr)^(1/3)*Pi^(2/3))

(1)

 

mu = 2^(2/3)*S*(16*C^2*Pi^2 - 2*Pi^2*Z^2 - S^2)*Pr^(1/3)/(4*(4*C*Pi + S)^(2/3)*(2*Pi^2*Z^2 + 4*C*Pi*S + S^2)^(2/3)*C^(4/3)*Pi^(2/3))

mu = (1/4)*2^(2/3)*S*(16*C^2*Pi^2-2*Pi^2*Z^2-S^2)*Pr^(1/3)/((4*C*Pi+S)^(2/3)*(2*Pi^2*Z^2+4*C*Pi*S+S^2)^(2/3)*C^(4/3)*Pi^(2/3))

(2)

CC:=proc(S,mu,Z,Pr)
fsolve((2),C,C=0.01..100)
end proc;

proc (S, mu, Z, Pr) fsolve(mu = (1/4)*2^(2/3)*S*(16*C^2*Pi^2-2*Pi^2*Z^2-S^2)*Pr^(1/3)/((4*C*Pi+S)^(2/3)*(2*Pi^2*Z^2+4*C*Pi*S+S^2)^(2/3)*C^(4/3)*Pi^(2/3)), C, C = 0.1e-1 .. 100) end proc

(3)

CC(1,0,0.5,0.2)

.1938622552

(4)

Explore(plot(T,0..15),parameters=[[mu=0 .. 1,minorticks=0.25],[Z=0..0.5,minorticks=0.1],[Pr=0..1,minorticks=0.25]])


When I try to move the sliders on my parameters this is where I get the error. I want to plot over S, but I can only get CC once I have all the other values including S. I assume it has something to do with the fact that my plotting variable is in the procedure?

Any help would be greatly appreciated, thanks. 

Download Explore_Plot_Problem.mw

I want the Minkowski metric in spherical coordinates, so I do the following:

restart;

with(Physics):

Setup(coordinatesystems=spherical,signature=`-+++`);

`Systems of spacetime coordinates are:`*{X = (t, r, theta, phi)}

 

[coordinatesystems = {X}, signature = `- + + +`]

(1)

g_[lineelement]

-Physics:-d_(t)^2+Physics:-d_(r)^2+Physics:-d_(theta)^2+Physics:-d_(phi)^2

(2)

 

Which is not correct, it should return:

-d_(t)^2 + d_(r)^2 + r^2*d_(theta)^2 + r^2*sin(theta)^2*d_(phi)^2

Any ideas why it is giving the wrong answer? I usually just define my metric manually, but I was curious why this is occuring. I also noticed something else strange: after running the worksheet, if I go back to the setup line and execute, it will return the correct expression! But if I execute restart and then Setup again, wrong answer. 

Any thoughts would be appreciated, thanks! 

Has anyone had any success in turning off the scrollable matrix feature on Mac? I found the post

 https://www.mapleprimes.com/questions/238061-How-To-Disable-The-New-Scrollable-Matrices

and tried to follow the steps outlined by Acer, but I cannot get it to work. Specifically, I greated a preference file at the location:

 //Users/$USER/Library/Preferences/Maple/<version>/Maple preferences which has the statement 

ScrollableMathTableOutput=false

Any success stories, or tips, will be greatly appreciated. 

Thanks. 

I am looking at the d'Almbert operator for the Minkowski metric in cartesian coordinates. When using the dAlmbertian command and converting to partial derivatives it gets the coefficients wrong, the negatives are not in the correct place based on the metric. But when I manually write the operator with the metric and derivative operator it returns the correct answer. Any thoughts on this? 

See attached, thank you. 

restart;

with(Physics):

Setup(coordinatesystems=cartesian,signature=`-+++`,metric=Minkowski)

 

`Systems of spacetime coordinates are:`*{X = (t, x, y, z)}

 

_______________________________________________________

 

`The Minkowski metric in coordinates `*[t, x, y, z]

 

`Signature: `(`- + + +`)

 

_______________________________________________________

 

Physics:-g_[mu, nu] = Matrix(%id = 36893488152289591652)

 

[coordinatesystems = {X}, metric = {(1, 1) = -1, (2, 2) = 1, (3, 3) = 1, (4, 4) = 1}, signature = `- + + +`]

(1)

g_[lineelement]

-Physics:-d_(t)^2+Physics:-d_(x)^2+Physics:-d_(y)^2+Physics:-d_(z)^2

(2)

CompactDisplay(phi(t,x,y,z))

phi(t, x, y, z)*`will now be displayed as`*phi

(3)

dAlembertian(phi(X))

Physics:-dAlembertian(phi(X), [X])

(4)

convert(%,diff)

-(diff(diff(phi(X), t), t))-(diff(diff(phi(X), x), x))-(diff(diff(phi(X), y), y))+diff(diff(phi(X), z), z)

(5)

g_[~mu,~nu]*d_[nu](d_[mu](phi(X)))

Physics:-g_[`~mu`, `~nu`]*Physics:-d_[mu](Physics:-d_[nu](phi(X), [X]), [X])

(6)

SumOverRepeatedIndices((6))

-(diff(diff(phi(X), t), t))+diff(diff(phi(X), x), x)+diff(diff(phi(X), y), y)+diff(diff(phi(X), z), z)

(7)
 

 

dAlmbert.mw

Suppose I have a metric g, and I want to perform a conformal transformation g = exp(2Phi(X))*g, is there a straightforward way to do this for curvature quantitieies (Christoffel, Ricci Scalar etc)? I was able to do it rather easily for the Christoffel symbols, as seen below, but it required me making a substitution for each index pair. While this isn't horrible, it would be nice if there was a way to do it without this procedure.

** Edited to make it Phi(X) 

restart;

with(Physics):CompactDisplay(Phi(X)):

Phi(X)*`will now be displayed as`*Phi

(1)

Setup(metric=arbitrary):

_______________________________________________________

 

`Systems of spacetime coordinates are:`*{X = (x1, x2, x3, x4)}

 

`Default differentiation variables for d_, D_ and dAlembertian are:`*{X = (x1, x2, x3, x4)}

 

`The arbitrary metric in coordinates `*[x1, x2, x3, x4]

 

`Signature: `(`- - - +`)

 

_______________________________________________________

 

Physics:-g_[mu, nu] = Matrix(%id = 36893488152300428092)

(2)

Christoffel[~alpha,beta,nu,definition]

Physics:-Christoffel[`~alpha`, beta, nu] = (1/2)*Physics:-g_[`~alpha`, `~mu`]*(Physics:-d_[nu](Physics:-g_[mu, beta], [X])+Physics:-d_[beta](Physics:-g_[mu, nu], [X])-Physics:-d_[mu](Physics:-g_[beta, nu], [X]))

(3)

Simplify(eval((3),[g_[mu,beta]=exp(2*Phi(X))*g_[mu,beta],g_[mu,nu]=exp(2*Phi(X))*g_[mu,nu],g_[beta,nu]=exp(2*Phi(X))*g_[beta,nu]]))

Physics:-Christoffel[`~alpha`, beta, nu] = exp(2*Phi(X))*(Physics:-d_[nu](Phi(X), [X])*Physics:-g_[beta, `~alpha`]+Physics:-d_[beta](Phi(X), [X])*Physics:-g_[nu, `~alpha`]-Physics:-d_[`~alpha`](Phi(X), [X])*Physics:-g_[beta, nu]+Physics:-Christoffel[`~alpha`, beta, nu])

(4)

expand((4))

Physics:-Christoffel[`~alpha`, beta, nu] = (exp(Phi(X)))^2*Physics:-d_[nu](Phi(X), [X])*Physics:-g_[beta, `~alpha`]+(exp(Phi(X)))^2*Physics:-d_[beta](Phi(X), [X])*Physics:-g_[nu, `~alpha`]-(exp(Phi(X)))^2*Physics:-d_[`~alpha`](Phi(X), [X])*Physics:-g_[beta, nu]+(exp(Phi(X)))^2*Physics:-Christoffel[`~alpha`, beta, nu]

(5)
 

 

Any thoughts appreciated, thank you!

MyConformal.mw

1 2 3 4 5 6 Page 1 of 6