ecterrab

14080 Reputation

24 Badges

19 years, 94 days

MaplePrimes Activity


These are answers submitted by ecterrab

I understand this command does what you want to do, i.e. sort by rank. An equivalent command may be in the Grobner or RegularChains packages.

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

This is your ODE

ODE := c1*(diff(f(x), x, x, x, x))+c2*(diff(f(x), x, x, x))/x+c3*(diff(f(x), x, x))/x^2+c4*(diff(f(x), x))/x^3+c5*f(x) = 0


Naturally, for any values of the c1, c2, c3, c4, c5 you have a different - yet perfectly valid - differential equation, so the ODE does not restrict the values of those five constants.
If I am understanding your question right, the question is which solutions can Maple find for the different cases where all these five constants are equal to 0 (then
f(x) is arbitrary) or taking them different from 0, one or more at a time, such that the resulting ODE is solvable by Maple.

To answer such a question use dsolve directly, just pass the ODE enclosed within [] or {}, and note the ranking I am using [f, {c1,c2,c3,c4,c5}] (for information on that, see the help page for PDEtools:-casesplit which is used by dsolve and pdsolve on background). To avoid cluttering, close with `:`, and here I just check a few

solutions := dsolve([ODE], [f, {c1, c2, c3, c4, c5}])

 

Consider the first case:

solutions[1]

{c1 = 0, c2 = 0, c3 = 0, c4 = 0, c5 = 0, f(x) = f(x)}

(1)

OK, that was easy. Next

solutions[2]

{c1 = 0, c2 = 0, c3 = 0, c4 = 0, c5 = c5, f(x) = 0}

(2)

Also easy. Move forward some few

solutions[4]

{c1 = 0, c2 = 0, c3 = c3, c4 = c4, c5 = c5, f(x) = c__1*x^((1/2)*(c3-c4)/c3)*BesselJ(-(1/4)*(c3-c4)/c3, (1/2)*(c5/c3)^(1/2)*x^2)+c__2*x^((1/2)*(c3-c4)/c3)*BesselY(-(1/4)*(c3-c4)/c3, (1/2)*(c5/c3)^(1/2)*x^2)}

(3)

Good, we are now in non-trivial territory, with three constants different from 0, J and Y are Bessel functions, and the solution depends on these three non-zero constants in a non-trivial way.

Etc.

And how many cases could Maple solve?

nops([solutions])

6``

(4)

NULL


 

Download solve_for_f_and_c1_to_c5.mw

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

Regardless of RootOf's caching approach, this error interruption should not happen in the first place. The problem is fixed, and the fix is distributed within the Maplesoft Physics Updates v.1808 or newer. To install, open Maple and input Physics:-Version(latest)

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

Using directly Maple TTY to avoid any interference: no error message.

I suggest you to revise you don't have anything interfering, and if you still see this error message you posted, then input 'tracelast;' and post its output here so that I could see how this message you get is produced. If entering tracelast results in nothing, executing the odetest line again, reproducing the error, then tracelast again.

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

To install the fix (works only for Maple 2024), as usual, open Maple and input Physics:-Version(latest)

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

Hi @nm
Note first that you show how to compute an implicit solution, for which dsolve([ode, IC], implicit) works fine and returns, exactly, the solution you show as my_new_sol.

The problem was related to computing an explicit solution, a process involving computing a series that happened to interrupt with that error you saw. That problem is solved and the adjustment is distributed within the latest Maplesoft Physics Updates for Maple 2024. (install via Physics:-version(latest))

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

While solving the ode + IC, the following call to solve is what hangs

ee := ((y(x)-1)*(y(x)+1))^(1/2)/(y(x)-1)^(1/2)/(y(x)+1)^(1/2)*ln(y(x)+(y(x)^2-1)^(1/2))-1/2*(y(x)^2-1)^(1/2)*(-ln(-y(x)^2+1)+2*ln((y(x)^2*x+((x^2-1)*(y(x)^2-1))^(1/2)*(y(x)^2-1)^(1/2)-x)/(y(x)^2-1)^(1/2)))/(y(x)-1)^(1/2)/(y(x)+1)^(1/2)-1/2*(y0^2-1)^(1/2)*(2*ln(y0+(y0^2-1)^(1/2))+ln(-y0^2+1)-2*ln((y0^2*x0+((x0^2-1)*(y0^2-1))^(1/2)*(y0^2-1)^(1/2)-x0)/(y0^2-1)^(1/2)))/(y0-1)^(1/2)/(y0+1)^(1/2)

((y(x)-1)*(y(x)+1))^(1/2)*ln(y(x)+(y(x)^2-1)^(1/2))/((y(x)-1)^(1/2)*(y(x)+1)^(1/2))-(1/2)*(y(x)^2-1)^(1/2)*(-ln(-y(x)^2+1)+2*ln((y(x)^2*x+((x^2-1)*(y(x)^2-1))^(1/2)*(y(x)^2-1)^(1/2)-x)/(y(x)^2-1)^(1/2)))/((y(x)-1)^(1/2)*(y(x)+1)^(1/2))-(1/2)*(y0^2-1)^(1/2)*(2*ln(y0+(y0^2-1)^(1/2))+ln(-y0^2+1)-2*ln((y0^2*x0+((x0^2-1)*(y0^2-1))^(1/2)*(y0^2-1)^(1/2)-x0)/(y0^2-1)^(1/2)))/((y0-1)^(1/2)*(y0+1)^(1/2))

(1)

solve(ee, y(x));  # hangs

NULL


 

Download issue_in_solve.mw

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft


This is a problem in solve.

restart;

eqs := [-2*arctanh((_C1-1)^(1/2)/_C1^(1/2)) = _C2, 0 = _C1^(3/2)*tanh(1/2*_C2)*sech(1/2*_C2)^2];
unknowns := {_C1,_C2};

[-2*arctanh((_C1-1)^(1/2)/_C1^(1/2)) = _C2, 0 = _C1^(3/2)*tanh((1/2)*_C2)*sech((1/2)*_C2)^2]

 

{_C1, _C2}

(1)

Good:

solve(eqs, unknowns)

{_C1 = 1, _C2 = 0}

(2)

Simpler:

tanh(_C2/2):
% = expand(%)

tanh((1/2)*_C2) = (cosh(_C2)-1)/sinh(_C2)

(3)

simplify((lhs-rhs)(%))

0

(4)

EQS := subs(%%, eqs)

[-2*arctanh((_C1-1)^(1/2)/_C1^(1/2)) = _C2, 0 = _C1^(3/2)*(cosh(_C2)/sinh(_C2)-1/sinh(_C2))*sech((1/2)*_C2)^2]

(5)

Not good:

solve(EQS, unknowns)

Warning, solutions may have been lost

 

The step that seems to be failing within solve: normalize functions in terms of independent exponentials

convert(EQS, exp)

[-2*arctanh((_C1-1)^(1/2)/_C1^(1/2)) = _C2, 0 = 4*_C1^(3/2)*(exp(_C2)-1)/((exp(_C2)+1)*(exp((1/2)*_C2)+exp(-(1/2)*_C2))^2)]

(6)

solve(%, unknowns)

{_C1 = 1, _C2 = 0}

(7)

NULL

Note as well that PDEtools:-Solve is not a solver 'itself' but a wrapper around the many Maple solvers (as explained in its help page), that returns results with a unified syntax and in addition performs an elimination step before forwarding to the corresponding solver. Expanding tanh(a/b) should not make solve fail - it seems a normalization of the expression in terms of independent exponentials, in solve, before proceeding, is failing. I will track this. Independent of that, the expansion is useful in several contexts but for tanh in particular it may be simpler to first do tanh -> sinh/cosh before expanding; that will probably workaround this issue in solve, but the problem itself, in solve, needs to be fixed.


PS: I added the workaround to solve's limitation mentioned, so that now PDEtools:-Solve returns a result. The adjustment is present in the latest Maplesoft Physics Updates for Maple 2024; as usual to install input Physics:-Version(latest).

Download why_PDEtools_Solve_fail_august_14_2024_(reviewed).mw

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

First, according to odeadvisor's help page,


The matching of the types is checked sequentially, and odeadvisor might return more than one type; otherwise, the first matching of a pattern interrupts the process and a classification is returned.

In fact, enter DEtools:-odeadvisor(ode, [dAlembert]) and you see your ode also matches dAlembert, not just separable.

Second, you realize the scope of a command like dsolve requires more than a classification: several ODEs can be tackled using different approaches, and choosing an appropriate one for each case requires considering multiple things. Your ode is a simple example of that. To make the point, a much more common, and complicated case is when the ODE does not match any standard classification but there are different symmetries available, sometimes also different integrating factors, all these leading to different forms of the solution. Anyway, solving your example using dAlembert's formulation is just more appropriate than tackling it as a separable equation.

Third, see ?dsolve,setup and you see you can force dsolve to use methods in an ordering different than the one I coded (mind you, the choice you see on that page is nontrivial).

Fourth, this ode you brought, as several other ones you have been posting, is nonlinear in the highest derivative; several methods require isolating the highest derivative, which involves choosing branches. Typically, the choice of a branch makes the solution valid only in some regions. This "problem" is unavoidable: either you accept an ode nonlinear in its highest derivative as a valid problem or not. If yes, you need to decide on what to do with these choices of branches. It is mainly for this reason I coded the implicit option.

With the above paragraphs in mind, this is what I see for your ode

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

 

First reply: "the indicated formula has singularities". I goofed with that comment (deleted now), as @vv tells below. The formula suggested by Wolinski above is now returned by the FunctionAdvisor and by convert(tan(z), Sum) as per pic below.

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft


 

To install the fix, open Maple and input Physics:-Version(latest).
The solution returned, however, is not the simplest you show but this other one:

ode := diff(y(x), x, x) = (diff(y(x), x))^3-(diff(y(x), x))^2

IC := y(0) = 3, (D(y))(0) = 1

dsolve([ode, IC])

y(x) = ln(LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1)))+4-ln(-RootOf(LambertW(-_Z*exp(-1))))

(1)

`assuming`([simplify(y(x) = ln(LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1)))+4-ln(-RootOf(LambertW(-_Z*exp(-1)))))], [positive])

y(x) = x+3-LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1))

(2)

odetest(y(x) = ln(LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1)))+4-ln(-RootOf(LambertW(-_Z*exp(-1)))), ode)

0

(3)

To test the IC requires using limit

limit(y(x) = ln(LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1)))+4-ln(-RootOf(LambertW(-_Z*exp(-1)))), x = 0)

y(0) = limit(ln(LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1)))+4-ln(-RootOf(LambertW(-_Z*exp(-1)))), x = 0)

(4)

simplify(y(0) = limit(ln(LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1)))+4-ln(-RootOf(LambertW(-_Z*exp(-1)))), x = 0))

y(0) = 3

(5)

limit(diff(y(x) = ln(LambertW(-RootOf(LambertW(-_Z*exp(-1)))*exp(x-1)))+4-ln(-RootOf(LambertW(-_Z*exp(-1)))), x), x = 0)

(D(y))(0) = 1

(6)

NULL


 

Download Fixed_in_v.1780.mw

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

 



Download representation_of_code_(reviewed).mw

PS: if you use Maple 2024, remember to input Physics:-Version(latest) to work with the current Physics version.

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft
 

Hi
d_[1](g(r)) will return different from 0 if and only if r depends on the Cartesian coordinates (that you defined as such). When you enter r = sqrt(x^2 + y^2 + z^2), so using the `=` operator, r does not get assigned anything. Input r and you see r as output. Use the assignment operator `:=` and i you will get what you were expecting.

Regarding diff(r, x) after you loaded the Physics:-Vectors package, that package comes with a diff command that automatically use the interdependency between Cartesian (x, y, z), Cylindrical (rho, phi, z) and Spherical coordinates (r, theta, phi) without you having to assign or state anything, and that in turn is also a setting: input Setup(geometricdifferentiation), and you see its value is false after loading Physics but before loading Vectors and true after loading it. This setting only affects the output of Physics:-Vectors:-diff, not Physics:-d_. I realize this is more of a design issue; intentional though: more often than otherwise, when using d_ we do not want geometricdifferentiation to interfere with computations, and if you want, it suffices to use := instead of = as mentioned above.

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft.

This is your worksheet with some minor corrections, comments, and three different ways of arriving at the same result (note you didn't say what is the result you expect)

 

restart

with(Physics)

with(Vectors)NULL

Setup(spacetimeindices = greek, spaceindices = lowercaselatin, su2indices = uppercaselatin, signature = `+++-`, coordinates = spherical)

[coordinatesystems = {X}, signature = `+ + + -`, spaceindices = lowercaselatin, spacetimeindices = greek, su2indices = uppercaselatin]

(1)

Setup(realobjects = {g, diff(x, x), diff(y(x), x), diff(z(x), x), f__A(X[1])})

[realobjects = {g, phi, r, rho, theta, x, `x'`, y, `y'`, z, `z'`, f__A(r)}]

(2)

I see you are using primed variables, which is perfectly fine, just recalling the prime in this context does not mean derivative.

 

Here is the first adjustment: you use the assignment operator :=, but on the left you put functionality: in doing so, you create a function, as you see in the output of your post, but after that, you only use the primed variables as symbols, not as functions, so your definition is not used (this is not related to Physics, but to how computer algebra systems work).

 

I am then removing the functionality on the lhs so that the primed variables have the value you indicated

diff(x, x) := r*sin(theta)*cos(phi)

r*sin(theta)*cos(phi)

(3)

diff(y(x), x) := r*sin(theta)*sin(phi)

r*sin(theta)*sin(phi)

(4)

diff(z(x), x) := r*cos(theta)

r*cos(theta)

(5)

Define(R[a] = [(diff(x, x))/r, (diff(y(x), x))/r, (diff(z(x), x))/r])

{Physics:-Dgamma[mu], Physics:-Psigma[mu], R[a], Physics:-d_[mu], Physics:-g_[mu, nu], Physics:-gamma_[a, b], Physics:-LeviCivita[alpha, beta, mu, nu], Physics:-SpaceTimeVector[mu](X)}

(6)

You see how the value is now taken into account:

R[definition]

R[a] = [sin(theta)*cos(phi), sin(theta)*sin(phi), cos(theta)]

(7)

Next you assigned to a sum, I imagine to want automatic simplification ... it is not how it works: if you want the following simplification you need to invoke it. I am changing that := by  = and show

(diff(x, x))^2+(diff(y(x), x))^2+(diff(z(x), x))^2 = r^2

r^2*sin(theta)^2*cos(phi)^2+r^2*sin(theta)^2*sin(phi)^2+r^2*cos(theta)^2 = r^2

(8)

simplify(r^2*sin(theta)^2*cos(phi)^2+r^2*sin(theta)^2*sin(phi)^2+r^2*cos(theta)^2 = r^2)

r^2 = r^2

(9)

Next you use X[1], not wrong but perhaps more clear: you could have used its value

X[1]

r

(10)

"Define(A[mu,~a] =(1-`f__A`(X[1]) )/(g*X[1])*LeviCivita[a, mu,j,4]* R[j] )  "

{A[mu, `~a`], Physics:-Dgamma[mu], Physics:-Psigma[mu], R[a], Physics:-d_[mu], Physics:-g_[mu, nu], Physics:-gamma_[a, b], Physics:-LeviCivita[alpha, beta, mu, nu], Physics:-SpaceTimeVector[mu](X)}

(11)

A[definition]

A[mu, `~a`] = (1-f__A(r))*Physics:-LeviCivita[4, a, j, mu]*R[j]/(g*r)

(12)

Here again you see the value of the primed variables, not themselves

A[]

A[mu, a] = Matrix(%id = 36893488158540457972)

(13)

Define(F[mu, nu, a] = d_[nu](A[mu, a])-d_[mu](A[nu, a])+LeviCivita[a, b, c, 4]*A[mu, b]*A[nu, c])

{A[mu, `~a`], Physics:-Dgamma[mu], F[mu, nu, a], Physics:-Psigma[mu], R[a], Physics:-d_[mu], Physics:-g_[mu, nu], Physics:-gamma_[a, b], Physics:-LeviCivita[alpha, beta, mu, nu], Physics:-SpaceTimeVector[mu](X)}

(14)

F[definition]

F[mu, nu, a] = Physics:-d_[nu](A[mu, a], [X])-Physics:-d_[mu](A[nu, a], [X])-Physics:-LeviCivita[4, a, b, c]*A[mu, b]*A[nu, c]

(15)

Again, the output involves the value of the primed variables

simplify(F[])

F[mu, nu, a] = _rtable[36893488153612237268]

(16)

Now the Sum over all the repeated indices

"`L__FST` := simplify(-1/(4)SumOverRepeatedIndices(F[mu,nu,a]  F[~mu,~nu,a])  )"

(1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(sin(theta)*sin(phi)*cos(theta)*cos(phi)*r-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(-1+f__A(r))^2*(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*sin(theta)*sin(phi)*cos(theta)*cos(phi)*g^2*r+(-2*r^2-1)*g^2))/(g^4*r^4)

(17)

Is this a scalar? Yes, in the sense that there are no tensors around. Is this the result you were expecting? I don't know, it would help if you type in the result you were expecting.

 

Also, you see that (17) above depends on theta and phi. You can determine the conditions on f__A(r) such that L__FST depends only on r by differentiating

simplify(diff(L__FST, theta))

(1/2)*(cos(phi)*((diff(f__A(r), r))^2*r^2-2*r*(-1+f__A(r))*(diff(f__A(r), r))+(-1+f__A(r))^2*(r^2+1))*sin(2*theta)+2*cos(2*theta)*r*sin(phi)*(-1+f__A(r))*(1-f__A(r)+r*(diff(f__A(r), r))))*cos(phi)/(r^4*g^2)

(18)

simplify(diff(L__FST, phi))

-(sin(theta)*sin(phi)*r*(diff(f__A(r), r))-(-1+f__A(r))*(r*cos(phi)*cos(theta)+sin(theta)*sin(phi)))*(sin(theta)*cos(phi)*(diff(f__A(r), r))*r+(-1+f__A(r))*(cos(theta)*r*sin(phi)-sin(theta)*cos(phi)))/(r^4*g^2)

(19)

 

Any f__A(r) that cancels both equations result in L__FST depending only on r.


Alternatively, you can compute the same but keeping the primed variables around till the last step, as follows

 

restart

with(Physics)

with(Vectors)``

Setup(spacetimeindices = greek, su2indices = lowercaselatin, signature = `+++-`, coordinates = spherical)

[coordinatesystems = {X}, signature = `+ + + -`, spacetimeindices = greek, su2indices = lowercaselatin]

(20)

Setup(realobjects = {g, diff(x, x), diff(y(x), x), diff(z(x), x), f__A(X[1])})

[realobjects = {g, phi, r, rho, theta, x, `x'`, y, `y'`, z, `z'`, f__A(r)}]

(21)

So do not assign the primed variables. Instead, create a set of substitution equations (i.e. use =, not :=) to be used only when you want

"x'(r, theta, phi)  = r * sin(theta) * cos(phi)"

`x'`(r, theta, phi) = r*sin(theta)*cos(phi)

(22)

"y'(r, theta, phi) = r * sin(theta) * sin(phi)"

`y'`(r, theta, phi) = r*sin(theta)*sin(phi)

(23)

"z'(r, theta, phi)  =r * cos(theta)"

`z'`(r, theta, phi) = r*cos(theta)

(24)

xyz := [`x'`(r, theta, phi) = r*sin(theta)*cos(phi), `y'`(r, theta, phi) = r*sin(theta)*sin(phi), `z'`(r, theta, phi) = r*cos(theta)]

[`x'`(r, theta, phi) = r*sin(theta)*cos(phi), `y'`(r, theta, phi) = r*sin(theta)*sin(phi), `z'`(r, theta, phi) = r*cos(theta)]

(25)

 

CompactDisplay(xyz)

`z'`(r, theta, phi)*`will now be displayed as`*`z'`

(26)

Proceed now using the primed variables themselves instead of their expression in terms of spherical coordinates

"Define(R[a] = [(x'(r,theta,phi))/(r),(y'(r,theta,phi))/(r),(z'(r,theta,phi))/(r)])"

{Physics:-Dgamma[mu], Physics:-Psigma[mu], R[a], Physics:-d_[mu], Physics:-g_[mu, nu], Physics:-LeviCivita[alpha, beta, mu, nu], Physics:-SpaceTimeVector[mu](X)}

(27)

You see now the definition in terms of the primed variables

R[definition]

R[a] = [`x'`(r, theta, phi)/r, `y'`(r, theta, phi)/r, `z'`(r, theta, phi)/r]

(28)

which all depend on the spherical coordinates

show

R[a] = [`x'`(r, theta, phi)/r, `y'`(r, theta, phi)/r, `z'`(r, theta, phi)/r]

(29)

Next, the following is an identity, I will assign it here to some name, eq, in order to use it for simplification purposes later

"eq :=  x'(r,theta,phi)^(2)+y'(r,theta,phi)^(2)+z'(r,theta,phi)^(2) =r^(2) "

`x'`(r, theta, phi)^2+`y'`(r, theta, phi)^2+`z'`(r, theta, phi)^2 = r^2

(30)

subs(xyz, eq)

r^2*sin(theta)^2*cos(phi)^2+r^2*sin(theta)^2*sin(phi)^2+r^2*cos(theta)^2 = r^2

(31)

simplify(r^2*sin(theta)^2*cos(phi)^2+r^2*sin(theta)^2*sin(phi)^2+r^2*cos(theta)^2 = r^2)

r^2 = r^2

(32)

Define now A

Define(A[mu, a] = (1-f__A(X[1]))*LeviCivita[a, mu, j, 4]*R[j]/(g*X[1]))

{A[mu, a], Physics:-Dgamma[mu], Physics:-Psigma[mu], R[a], Physics:-d_[mu], Physics:-g_[mu, nu], Physics:-LeviCivita[alpha, beta, mu, nu], Physics:-SpaceTimeVector[mu](X)}

(33)

A[definition]

A[mu, a] = (1-f__A(r))*Physics:-LeviCivita[4, a, j, mu]*R[j]/(g*r)

(34)

Here again you see the primed variables themselves, not their value

A[]

A[mu, a] = Matrix(%id = 36893488158429633340)

(35)

All primed ones are functions of the spherical coordinates:

show

A[mu, a] = Matrix(%id = 36893488158429633340)

(36)

Define now your F

Define(F[mu, nu, a] = d_[nu](A[mu, a])-d_[mu](A[nu, a])+LeviCivita[a, b, c, 4]*A[mu, b]*A[nu, c])

{A[mu, a], Physics:-Dgamma[mu], F[mu, nu, a], Physics:-Psigma[mu], R[a], Physics:-d_[mu], Physics:-g_[mu, nu], Physics:-LeviCivita[alpha, beta, mu, nu], Physics:-SpaceTimeVector[mu](X)}

(37)

F[definition]

F[mu, nu, a] = Physics:-d_[nu](A[mu, a], [X])-Physics:-d_[mu](A[nu, a], [X])-Physics:-LeviCivita[4, a, b, c]*A[mu, b]*A[nu, c]

(38)

Again, the output involves the primed variables, and their derivatives, denoted with an index

simplify(F[])

F[mu, nu, a] = _rtable[36893488152118081044]

(39)

Now the Sum over all the repeated indices

" -1/(4)SumOverRepeatedIndices(F[mu,nu,a] F[~mu,~nu,a]) "

-(1/2)*(-2*f__A(r)^2*(diff(`x'`(r, theta, phi), r))*(diff(`y'`(r, theta, phi), theta))*g^2*r^4-2*f__A(r)^2*(diff(`x'`(r, theta, phi), r))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4-2*f__A(r)^2*(diff(`y'`(r, theta, phi), theta))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+4*f__A(r)^2*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*g^2*r^3+4*f__A(r)^2*`z'`(r, theta, phi)*(diff(`z'`(r, theta, phi), r))*g^2*r^3+8*f__A(r)^2*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^3+4*f__A(r)^2*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^3+4*f__A(r)^2*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^3+4*f__A(r)*`y'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3+4*f__A(r)*`z'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3+8*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)^2*g^2*r^3+4*f__A(r)*(diff(`x'`(r, theta, phi), r))*(diff(`y'`(r, theta, phi), theta))*g^2*r^4+4*f__A(r)*(diff(`x'`(r, theta, phi), r))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+4*f__A(r)*(diff(`y'`(r, theta, phi), theta))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+2*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*(diff(f__A(r), r))*g^2*r^4+2*`z'`(r, theta, phi)*(diff(f__A(r), r))*(diff(`z'`(r, theta, phi), r))*g^2*r^4+4*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^4+2*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^4+2*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^4-8*f__A(r)*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*g^2*r^3-8*f__A(r)*`z'`(r, theta, phi)*(diff(`z'`(r, theta, phi), r))*g^2*r^3-16*f__A(r)*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^3-8*f__A(r)*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^3-8*f__A(r)*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^3-2*f__A(r)*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*(diff(f__A(r), r))*g^2*r^4-2*f__A(r)*`z'`(r, theta, phi)*(diff(f__A(r), r))*(diff(`z'`(r, theta, phi), r))*g^2*r^4-4*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^4-2*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^4-2*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^4-f__A(r)^2*(diff(`z'`(r, theta, phi), theta))^2*g^2*r^4-f__A(r)^2*(diff(`x'`(r, theta, phi), phi))^2*g^2*r^4-f__A(r)^2*(diff(`y'`(r, theta, phi), r))^2*g^2*r^4-2*f__A(r)^2*(diff(`x'`(r, theta, phi), r))^2*g^2*r^4-2*f__A(r)^2*(diff(`y'`(r, theta, phi), theta))^2*g^2*r^4-f__A(r)^2*(diff(`x'`(r, theta, phi), theta))^2*g^2*r^4-f__A(r)^2*(diff(`y'`(r, theta, phi), phi))^2*g^2*r^4-2*f__A(r)^2*(diff(`z'`(r, theta, phi), phi))^2*g^2*r^4-f__A(r)^2*(diff(`z'`(r, theta, phi), r))^2*g^2*r^4-`y'`(r, theta, phi)^2*(diff(f__A(r), r))^2*g^2*r^4-`z'`(r, theta, phi)^2*(diff(f__A(r), r))^2*g^2*r^4-2*(diff(f__A(r), r))^2*`x'`(r, theta, phi)^2*g^2*r^4+2*f__A(r)*(diff(`z'`(r, theta, phi), theta))^2*g^2*r^4+2*f__A(r)*(diff(`x'`(r, theta, phi), phi))^2*g^2*r^4+2*f__A(r)*(diff(`y'`(r, theta, phi), r))^2*g^2*r^4+4*f__A(r)*(diff(`x'`(r, theta, phi), r))^2*g^2*r^4+4*f__A(r)*(diff(`y'`(r, theta, phi), theta))^2*g^2*r^4+2*f__A(r)*(diff(`x'`(r, theta, phi), theta))^2*g^2*r^4+2*f__A(r)*(diff(`y'`(r, theta, phi), phi))^2*g^2*r^4+4*f__A(r)*(diff(`z'`(r, theta, phi), phi))^2*g^2*r^4+2*f__A(r)*(diff(`z'`(r, theta, phi), r))^2*g^2*r^4-4*f__A(r)^2*`y'`(r, theta, phi)^2*g^2*r^2-4*f__A(r)^2*`z'`(r, theta, phi)^2*g^2*r^2-8*f__A(r)^2*`x'`(r, theta, phi)^2*g^2*r^2-4*`y'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3-4*`z'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3-8*(diff(f__A(r), r))*`x'`(r, theta, phi)^2*g^2*r^3-2*(diff(`x'`(r, theta, phi), r))*(diff(`y'`(r, theta, phi), theta))*g^2*r^4-2*(diff(`x'`(r, theta, phi), r))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4-2*(diff(`y'`(r, theta, phi), theta))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+8*f__A(r)*`y'`(r, theta, phi)^2*g^2*r^2+8*f__A(r)*`z'`(r, theta, phi)^2*g^2*r^2+16*f__A(r)*`x'`(r, theta, phi)^2*g^2*r^2+4*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*g^2*r^3+4*`z'`(r, theta, phi)*(diff(`z'`(r, theta, phi), r))*g^2*r^3+8*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^3+4*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^3+4*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^3+2*f__A(r)^4*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2+2*f__A(r)^4*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+2*f__A(r)^4*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-(diff(`z'`(r, theta, phi), theta))^2*g^2*r^4-(diff(`x'`(r, theta, phi), phi))^2*g^2*r^4-(diff(`y'`(r, theta, phi), r))^2*g^2*r^4-2*(diff(`x'`(r, theta, phi), r))^2*g^2*r^4-2*(diff(`y'`(r, theta, phi), theta))^2*g^2*r^4-(diff(`x'`(r, theta, phi), theta))^2*g^2*r^4-(diff(`y'`(r, theta, phi), phi))^2*g^2*r^4-2*(diff(`z'`(r, theta, phi), phi))^2*g^2*r^4-(diff(`z'`(r, theta, phi), r))^2*g^2*r^4-8*f__A(r)^3*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2-8*f__A(r)^3*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-8*f__A(r)^3*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+12*f__A(r)^2*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2+12*f__A(r)^2*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+12*f__A(r)^2*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-4*`y'`(r, theta, phi)^2*g^2*r^2-4*`z'`(r, theta, phi)^2*g^2*r^2-8*`x'`(r, theta, phi)^2*g^2*r^2-8*f__A(r)*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2-8*f__A(r)*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-8*f__A(r)*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+f__A(r)^4*`y'`(r, theta, phi)^4+f__A(r)^4*`z'`(r, theta, phi)^4+f__A(r)^4*`x'`(r, theta, phi)^4-4*f__A(r)^3*`y'`(r, theta, phi)^4-4*f__A(r)^3*`z'`(r, theta, phi)^4-4*f__A(r)^3*`x'`(r, theta, phi)^4+6*f__A(r)^2*`y'`(r, theta, phi)^4+6*f__A(r)^2*`z'`(r, theta, phi)^4+6*f__A(r)^2*`x'`(r, theta, phi)^4-4*f__A(r)*`y'`(r, theta, phi)^4-4*f__A(r)*`z'`(r, theta, phi)^4-4*f__A(r)*`x'`(r, theta, phi)^4+2*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2+2*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+2*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+`y'`(r, theta, phi)^4+`z'`(r, theta, phi)^4+`x'`(r, theta, phi)^4)/(r^8*g^4)

(40)

Simplify the above taking into account eq

eq

`x'`(r, theta, phi)^2+`y'`(r, theta, phi)^2+`z'`(r, theta, phi)^2 = r^2

(41)

simplify(-(1/2)*(-f__A(r)^2*(diff(`z'`(r, theta, phi), theta))^2*g^2*r^4-f__A(r)^2*(diff(`x'`(r, theta, phi), phi))^2*g^2*r^4-f__A(r)^2*(diff(`y'`(r, theta, phi), r))^2*g^2*r^4-f__A(r)^2*(diff(`x'`(r, theta, phi), theta))^2*g^2*r^4-f__A(r)^2*(diff(`y'`(r, theta, phi), phi))^2*g^2*r^4-f__A(r)^2*(diff(`z'`(r, theta, phi), r))^2*g^2*r^4-`y'`(r, theta, phi)^2*(diff(f__A(r), r))^2*g^2*r^4-`z'`(r, theta, phi)^2*(diff(f__A(r), r))^2*g^2*r^4-2*f__A(r)^2*(diff(`x'`(r, theta, phi), r))^2*g^2*r^4-2*f__A(r)^2*(diff(`y'`(r, theta, phi), theta))^2*g^2*r^4-2*f__A(r)^2*(diff(`z'`(r, theta, phi), phi))^2*g^2*r^4-2*(diff(f__A(r), r))^2*`x'`(r, theta, phi)^2*g^2*r^4+2*f__A(r)*(diff(`z'`(r, theta, phi), theta))^2*g^2*r^4+2*f__A(r)*(diff(`x'`(r, theta, phi), phi))^2*g^2*r^4+2*f__A(r)*(diff(`y'`(r, theta, phi), r))^2*g^2*r^4+4*f__A(r)*(diff(`x'`(r, theta, phi), r))^2*g^2*r^4+4*f__A(r)*(diff(`y'`(r, theta, phi), theta))^2*g^2*r^4+2*f__A(r)*(diff(`x'`(r, theta, phi), theta))^2*g^2*r^4+2*f__A(r)*(diff(`y'`(r, theta, phi), phi))^2*g^2*r^4+4*f__A(r)*(diff(`z'`(r, theta, phi), phi))^2*g^2*r^4+2*f__A(r)*(diff(`z'`(r, theta, phi), r))^2*g^2*r^4-4*f__A(r)^2*`y'`(r, theta, phi)^2*g^2*r^2-4*f__A(r)^2*`z'`(r, theta, phi)^2*g^2*r^2-8*f__A(r)^2*`x'`(r, theta, phi)^2*g^2*r^2-4*`y'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3-4*`z'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3-8*(diff(f__A(r), r))*`x'`(r, theta, phi)^2*g^2*r^3-2*(diff(`x'`(r, theta, phi), r))*(diff(`y'`(r, theta, phi), theta))*g^2*r^4-2*(diff(`x'`(r, theta, phi), r))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4-2*(diff(`y'`(r, theta, phi), theta))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+8*f__A(r)*`y'`(r, theta, phi)^2*g^2*r^2+8*f__A(r)*`z'`(r, theta, phi)^2*g^2*r^2+16*f__A(r)*`x'`(r, theta, phi)^2*g^2*r^2+4*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*g^2*r^3+4*`z'`(r, theta, phi)*(diff(`z'`(r, theta, phi), r))*g^2*r^3+8*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^3+4*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^3+4*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^3+f__A(r)^4*`y'`(r, theta, phi)^4+f__A(r)^4*`z'`(r, theta, phi)^4+f__A(r)^4*`x'`(r, theta, phi)^4-4*f__A(r)^3*`y'`(r, theta, phi)^4-4*f__A(r)^3*`z'`(r, theta, phi)^4-4*f__A(r)^3*`x'`(r, theta, phi)^4+6*f__A(r)^2*`y'`(r, theta, phi)^4+6*f__A(r)^2*`z'`(r, theta, phi)^4+6*f__A(r)^2*`x'`(r, theta, phi)^4-4*f__A(r)*`y'`(r, theta, phi)^4-4*f__A(r)*`z'`(r, theta, phi)^4-4*f__A(r)*`x'`(r, theta, phi)^4+2*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2+2*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+2*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-(diff(`z'`(r, theta, phi), theta))^2*g^2*r^4-(diff(`x'`(r, theta, phi), phi))^2*g^2*r^4-(diff(`y'`(r, theta, phi), r))^2*g^2*r^4-(diff(`x'`(r, theta, phi), theta))^2*g^2*r^4-(diff(`y'`(r, theta, phi), phi))^2*g^2*r^4-(diff(`z'`(r, theta, phi), r))^2*g^2*r^4+2*f__A(r)^4*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2+2*f__A(r)^4*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+2*f__A(r)^4*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-2*(diff(`x'`(r, theta, phi), r))^2*g^2*r^4-2*(diff(`y'`(r, theta, phi), theta))^2*g^2*r^4-2*(diff(`z'`(r, theta, phi), phi))^2*g^2*r^4-8*f__A(r)^3*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2-8*f__A(r)^3*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-8*f__A(r)^3*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+12*f__A(r)^2*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2+12*f__A(r)^2*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2+12*f__A(r)^2*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-4*`y'`(r, theta, phi)^2*g^2*r^2-4*`z'`(r, theta, phi)^2*g^2*r^2-8*`x'`(r, theta, phi)^2*g^2*r^2-8*f__A(r)*`y'`(r, theta, phi)^2*`z'`(r, theta, phi)^2-8*f__A(r)*`y'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-8*f__A(r)*`z'`(r, theta, phi)^2*`x'`(r, theta, phi)^2-2*f__A(r)^2*(diff(`x'`(r, theta, phi), r))*(diff(`y'`(r, theta, phi), theta))*g^2*r^4-2*f__A(r)^2*(diff(`x'`(r, theta, phi), r))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4-2*f__A(r)^2*(diff(`y'`(r, theta, phi), theta))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+4*f__A(r)^2*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*g^2*r^3+4*f__A(r)^2*`z'`(r, theta, phi)*(diff(`z'`(r, theta, phi), r))*g^2*r^3+8*f__A(r)^2*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^3+4*f__A(r)^2*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^3+4*f__A(r)^2*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^3+4*f__A(r)*`y'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3+4*f__A(r)*`z'`(r, theta, phi)^2*(diff(f__A(r), r))*g^2*r^3+8*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)^2*g^2*r^3+4*f__A(r)*(diff(`x'`(r, theta, phi), r))*(diff(`y'`(r, theta, phi), theta))*g^2*r^4+4*f__A(r)*(diff(`x'`(r, theta, phi), r))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+4*f__A(r)*(diff(`y'`(r, theta, phi), theta))*(diff(`z'`(r, theta, phi), phi))*g^2*r^4+2*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*(diff(f__A(r), r))*g^2*r^4+2*`z'`(r, theta, phi)*(diff(f__A(r), r))*(diff(`z'`(r, theta, phi), r))*g^2*r^4+4*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^4+2*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^4+2*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^4-8*f__A(r)*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*g^2*r^3-8*f__A(r)*`z'`(r, theta, phi)*(diff(`z'`(r, theta, phi), r))*g^2*r^3-16*f__A(r)*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^3-8*f__A(r)*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^3-8*f__A(r)*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^3+`y'`(r, theta, phi)^4+`z'`(r, theta, phi)^4+`x'`(r, theta, phi)^4-2*f__A(r)*`y'`(r, theta, phi)*(diff(`y'`(r, theta, phi), r))*(diff(f__A(r), r))*g^2*r^4-2*f__A(r)*`z'`(r, theta, phi)*(diff(f__A(r), r))*(diff(`z'`(r, theta, phi), r))*g^2*r^4-4*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`x'`(r, theta, phi), r))*g^2*r^4-2*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`y'`(r, theta, phi), theta))*g^2*r^4-2*f__A(r)*(diff(f__A(r), r))*`x'`(r, theta, phi)*(diff(`z'`(r, theta, phi), phi))*g^2*r^4)/(r^8*g^4), {eq})

(1/2)*(2*g^2*r^2*(-1+f__A(r))^2*(diff(`y'`(r, theta, phi), theta))^2+2*g^2*(r*(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r+`x'`(r, theta, phi)*(r*(diff(f__A(r), r))-2*f__A(r)+2))*r*(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))+2*g^2*r^2*(-1+f__A(r))^2*(diff(`z'`(r, theta, phi), phi))^2+2*((-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r+`x'`(r, theta, phi)*(r*(diff(f__A(r), r))-2*f__A(r)+2))*g^2*r*(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))+2*g^2*r^2*(-1+f__A(r))^2*(diff(`x'`(r, theta, phi), r))^2+4*g^2*r*`x'`(r, theta, phi)*(-1+f__A(r))*(r*(diff(f__A(r), r))-2*f__A(r)+2)*(diff(`x'`(r, theta, phi), r))+g^2*r^2*(-1+f__A(r))^2*(diff(`y'`(r, theta, phi), r))^2+2*g^2*r*`y'`(r, theta, phi)*(-1+f__A(r))*(r*(diff(f__A(r), r))-2*f__A(r)+2)*(diff(`y'`(r, theta, phi), r))+g^2*r^2*(-1+f__A(r))^2*(diff(`z'`(r, theta, phi), r))^2+2*g^2*r*`z'`(r, theta, phi)*(-1+f__A(r))*(r*(diff(f__A(r), r))-2*f__A(r)+2)*(diff(`z'`(r, theta, phi), r))+g^2*r^2*(-1+f__A(r))^2*(diff(`x'`(r, theta, phi), theta))^2+g^2*r^2*(-1+f__A(r))^2*(diff(`z'`(r, theta, phi), theta))^2+g^2*r^2*(-1+f__A(r))^2*(diff(`x'`(r, theta, phi), phi))^2+g^2*r^2*(-1+f__A(r))^2*(diff(`y'`(r, theta, phi), phi))^2+g^2*(r*(diff(f__A(r), r))-2*f__A(r)+2)^2*`x'`(r, theta, phi)^2+(g*r*(diff(f__A(r), r))-2*(-(1/2)*f__A(r)+g+1/2)*(-1+f__A(r)))*(g*r*(diff(f__A(r), r))-2*((1/2)*f__A(r)+g-1/2)*(-1+f__A(r)))*r^2)/(r^6*g^4)

(42)

Express now the primed variables as functions of the spherical coordinates

xyz

[`x'`(r, theta, phi) = r*sin(theta)*cos(phi), `y'`(r, theta, phi) = r*sin(theta)*sin(phi), `z'`(r, theta, phi) = r*cos(theta)]

(43)

So your L__FST now is given by

L__FST := simplify(eval((1/2)*(2*g^2*r^2*(-1+f__A(r))^2*(diff(`y'`(r, theta, phi), theta))^2+2*g^2*(r*(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r+`x'`(r, theta, phi)*(r*(diff(f__A(r), r))-2*f__A(r)+2))*r*(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))+2*g^2*r^2*(-1+f__A(r))^2*(diff(`z'`(r, theta, phi), phi))^2+2*((-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r+`x'`(r, theta, phi)*(r*(diff(f__A(r), r))-2*f__A(r)+2))*g^2*r*(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))+2*g^2*r^2*(-1+f__A(r))^2*(diff(`x'`(r, theta, phi), r))^2+4*g^2*r*`x'`(r, theta, phi)*(-1+f__A(r))*(r*(diff(f__A(r), r))-2*f__A(r)+2)*(diff(`x'`(r, theta, phi), r))+g^2*r^2*(-1+f__A(r))^2*(diff(`y'`(r, theta, phi), r))^2+2*g^2*r*`y'`(r, theta, phi)*(-1+f__A(r))*(r*(diff(f__A(r), r))-2*f__A(r)+2)*(diff(`y'`(r, theta, phi), r))+g^2*r^2*(-1+f__A(r))^2*(diff(`z'`(r, theta, phi), r))^2+2*g^2*r*`z'`(r, theta, phi)*(-1+f__A(r))*(r*(diff(f__A(r), r))-2*f__A(r)+2)*(diff(`z'`(r, theta, phi), r))+g^2*r^2*(-1+f__A(r))^2*(diff(`x'`(r, theta, phi), theta))^2+g^2*r^2*(-1+f__A(r))^2*(diff(`z'`(r, theta, phi), theta))^2+g^2*r^2*(-1+f__A(r))^2*(diff(`x'`(r, theta, phi), phi))^2+g^2*r^2*(-1+f__A(r))^2*(diff(`y'`(r, theta, phi), phi))^2+g^2*(r*(diff(f__A(r), r))-2*f__A(r)+2)^2*`x'`(r, theta, phi)^2+(g*r*(diff(f__A(r), r))-2*(-(1/2)*f__A(r)+g+1/2)*(-1+f__A(r)))*(g*r*(diff(f__A(r), r))-2*((1/2)*f__A(r)+g-1/2)*(-1+f__A(r)))*r^2)/(r^6*g^4), xyz))

(1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(r*sin(theta)*cos(phi)*cos(theta)*sin(phi)-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*g^2*r*sin(theta)*cos(phi)*cos(theta)*sin(phi)+(-2*r^2-1)*g^2)*(-1+f__A(r))^2)/(r^4*g^4)

(44)

This is the same result obtained following the previous approach, where L__FST = (1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(sin(theta)*sin(phi)*cos(theta)*cos(phi)*r-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(-1+f__A(r))^2*(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*sin(theta)*sin(phi)*cos(theta)*cos(phi)*g^2*r+(-2*r^2-1)*g^2))/(g^4*r^4)

(1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(sin(theta)*sin(phi)*cos(theta)*cos(phi)*r-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(-1+f__A(r))^2*(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*sin(theta)*sin(phi)*cos(theta)*cos(phi)*g^2*r+(-2*r^2-1)*g^2))/(g^4*r^4)

(1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(r*sin(theta)*cos(phi)*cos(theta)*sin(phi)-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*g^2*r*sin(theta)*cos(phi)*cos(theta)*sin(phi)+(-2*r^2-1)*g^2)*(-1+f__A(r))^2)/(r^4*g^4)

(45)

simplify(L__FST-(1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(sin(theta)*sin(phi)*cos(theta)*cos(phi)*r-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(-1+f__A(r))^2*(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*sin(theta)*sin(phi)*cos(theta)*cos(phi)*g^2*r+(-2*r^2-1)*g^2))/(g^4*r^4))

0

(46)

A last verification, also resulting in the same: compute with everything inert, to revise by eye each step. This is the Lagrangian

"`L__FST` := -1/(4)SumOverRepeatedIndices(`%F`[mu,nu,a] `%F`[~mu,~nu,a]) "

-(1/4)*%F[1, 3, 1]*%F[`~1`, `~3`, 1]-(1/4)*%F[1, 3, 2]*%F[`~1`, `~3`, 2]-(1/4)*%F[1, 3, 3]*%F[`~1`, `~3`, 3]-(1/4)*%F[2, 3, 1]*%F[`~2`, `~3`, 1]-(1/4)*%F[2, 3, 2]*%F[`~2`, `~3`, 2]-(1/4)*%F[2, 3, 3]*%F[`~2`, `~3`, 3]-(1/4)*%F[3, 3, 1]*%F[`~3`, `~3`, 1]-(1/4)*%F[3, 3, 2]*%F[`~3`, `~3`, 2]-(1/4)*%F[3, 3, 3]*%F[`~3`, `~3`, 3]-(1/4)*%F[4, 3, 1]*%F[`~4`, `~3`, 1]-(1/4)*%F[4, 3, 2]*%F[`~4`, `~3`, 2]-(1/4)*%F[4, 3, 3]*%F[`~4`, `~3`, 3]-(1/4)*%F[1, 4, 1]*%F[`~1`, `~4`, 1]-(1/4)*%F[1, 4, 2]*%F[`~1`, `~4`, 2]-(1/4)*%F[1, 4, 3]*%F[`~1`, `~4`, 3]-(1/4)*%F[2, 4, 1]*%F[`~2`, `~4`, 1]-(1/4)*%F[2, 4, 2]*%F[`~2`, `~4`, 2]-(1/4)*%F[2, 4, 3]*%F[`~2`, `~4`, 3]-(1/4)*%F[3, 4, 1]*%F[`~3`, `~4`, 1]-(1/4)*%F[3, 4, 2]*%F[`~3`, `~4`, 2]-(1/4)*%F[3, 4, 3]*%F[`~3`, `~4`, 3]-(1/4)*%F[4, 4, 1]*%F[`~4`, `~4`, 1]-(1/4)*%F[4, 4, 2]*%F[`~4`, `~4`, 2]-(1/4)*%F[4, 4, 3]*%F[`~4`, `~4`, 3]-(1/4)*%F[1, 1, 1]*%F[`~1`, `~1`, 1]-(1/4)*%F[1, 1, 2]*%F[`~1`, `~1`, 2]-(1/4)*%F[1, 1, 3]*%F[`~1`, `~1`, 3]-(1/4)*%F[2, 1, 1]*%F[`~2`, `~1`, 1]-(1/4)*%F[2, 1, 2]*%F[`~2`, `~1`, 2]-(1/4)*%F[2, 1, 3]*%F[`~2`, `~1`, 3]-(1/4)*%F[3, 1, 1]*%F[`~3`, `~1`, 1]-(1/4)*%F[3, 1, 2]*%F[`~3`, `~1`, 2]-(1/4)*%F[3, 1, 3]*%F[`~3`, `~1`, 3]-(1/4)*%F[4, 1, 1]*%F[`~4`, `~1`, 1]-(1/4)*%F[4, 1, 2]*%F[`~4`, `~1`, 2]-(1/4)*%F[4, 1, 3]*%F[`~4`, `~1`, 3]-(1/4)*%F[1, 2, 1]*%F[`~1`, `~2`, 1]-(1/4)*%F[1, 2, 2]*%F[`~1`, `~2`, 2]-(1/4)*%F[1, 2, 3]*%F[`~1`, `~2`, 3]-(1/4)*%F[2, 2, 1]*%F[`~2`, `~2`, 1]-(1/4)*%F[2, 2, 2]*%F[`~2`, `~2`, 2]-(1/4)*%F[2, 2, 3]*%F[`~2`, `~2`, 3]-(1/4)*%F[3, 2, 1]*%F[`~3`, `~2`, 1]-(1/4)*%F[3, 2, 2]*%F[`~3`, `~2`, 2]-(1/4)*%F[3, 2, 3]*%F[`~3`, `~2`, 3]-(1/4)*%F[4, 2, 1]*%F[`~4`, `~2`, 1]-(1/4)*%F[4, 2, 2]*%F[`~4`, `~2`, 2]-(1/4)*%F[4, 2, 3]*%F[`~4`, `~2`, 3]

(47)

You see that the su2 indices, last index in F, run from 1 to 3 only

map2(op, -1, indets(-(1/4)*%F[1, 3, 1]*%F[`~1`, `~3`, 1]-(1/4)*%F[1, 3, 2]*%F[`~1`, `~3`, 2]-(1/4)*%F[1, 3, 3]*%F[`~1`, `~3`, 3]-(1/4)*%F[2, 3, 1]*%F[`~2`, `~3`, 1]-(1/4)*%F[2, 3, 2]*%F[`~2`, `~3`, 2]-(1/4)*%F[2, 3, 3]*%F[`~2`, `~3`, 3]-(1/4)*%F[3, 3, 1]*%F[`~3`, `~3`, 1]-(1/4)*%F[3, 3, 2]*%F[`~3`, `~3`, 2]-(1/4)*%F[3, 3, 3]*%F[`~3`, `~3`, 3]-(1/4)*%F[4, 3, 1]*%F[`~4`, `~3`, 1]-(1/4)*%F[4, 3, 2]*%F[`~4`, `~3`, 2]-(1/4)*%F[4, 3, 3]*%F[`~4`, `~3`, 3]-(1/4)*%F[1, 4, 1]*%F[`~1`, `~4`, 1]-(1/4)*%F[1, 4, 2]*%F[`~1`, `~4`, 2]-(1/4)*%F[1, 4, 3]*%F[`~1`, `~4`, 3]-(1/4)*%F[2, 4, 1]*%F[`~2`, `~4`, 1]-(1/4)*%F[2, 4, 2]*%F[`~2`, `~4`, 2]-(1/4)*%F[2, 4, 3]*%F[`~2`, `~4`, 3]-(1/4)*%F[3, 4, 1]*%F[`~3`, `~4`, 1]-(1/4)*%F[3, 4, 2]*%F[`~3`, `~4`, 2]-(1/4)*%F[3, 4, 3]*%F[`~3`, `~4`, 3]-(1/4)*%F[4, 4, 1]*%F[`~4`, `~4`, 1]-(1/4)*%F[4, 4, 2]*%F[`~4`, `~4`, 2]-(1/4)*%F[4, 4, 3]*%F[`~4`, `~4`, 3]-(1/4)*%F[1, 1, 1]*%F[`~1`, `~1`, 1]-(1/4)*%F[1, 1, 2]*%F[`~1`, `~1`, 2]-(1/4)*%F[1, 1, 3]*%F[`~1`, `~1`, 3]-(1/4)*%F[2, 1, 1]*%F[`~2`, `~1`, 1]-(1/4)*%F[2, 1, 2]*%F[`~2`, `~1`, 2]-(1/4)*%F[2, 1, 3]*%F[`~2`, `~1`, 3]-(1/4)*%F[3, 1, 1]*%F[`~3`, `~1`, 1]-(1/4)*%F[3, 1, 2]*%F[`~3`, `~1`, 2]-(1/4)*%F[3, 1, 3]*%F[`~3`, `~1`, 3]-(1/4)*%F[4, 1, 1]*%F[`~4`, `~1`, 1]-(1/4)*%F[4, 1, 2]*%F[`~4`, `~1`, 2]-(1/4)*%F[4, 1, 3]*%F[`~4`, `~1`, 3]-(1/4)*%F[1, 2, 1]*%F[`~1`, `~2`, 1]-(1/4)*%F[1, 2, 2]*%F[`~1`, `~2`, 2]-(1/4)*%F[1, 2, 3]*%F[`~1`, `~2`, 3]-(1/4)*%F[2, 2, 1]*%F[`~2`, `~2`, 1]-(1/4)*%F[2, 2, 2]*%F[`~2`, `~2`, 2]-(1/4)*%F[2, 2, 3]*%F[`~2`, `~2`, 3]-(1/4)*%F[3, 2, 1]*%F[`~3`, `~2`, 1]-(1/4)*%F[3, 2, 2]*%F[`~3`, `~2`, 2]-(1/4)*%F[3, 2, 3]*%F[`~3`, `~2`, 3]-(1/4)*%F[4, 2, 1]*%F[`~4`, `~2`, 1]-(1/4)*%F[4, 2, 2]*%F[`~4`, `~2`, 2]-(1/4)*%F[4, 2, 3]*%F[`~4`, `~2`, 3], indexed))

{1, 2, 3}

(48)

Compute the value of each of these inert F

TensorArray(%F[mu, nu, a] = F[mu, nu, a], output = setofequations)

{%F[1, 1, 1] = 0, %F[1, 1, 2] = 0, %F[1, 1, 3] = 0, %F[1, 2, 1] = (((diff(f__A(r), r))*`z'`(r, theta, phi)*r-(1-f__A(r))*(diff(`z'`(r, theta, phi), r))*r+2*(1-f__A(r))*`z'`(r, theta, phi))*g*r+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[1, 2, 2] = ((-1+f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[1, 2, 3] = ((1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(2*(-1+f__A(r))*`x'`(r, theta, phi)-(diff(f__A(r), r))*`x'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[1, 3, 1] = ((2*(-1+f__A(r))*`y'`(r, theta, phi)-(diff(f__A(r), r))*`y'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`y'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[1, 3, 2] = ((-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+((diff(f__A(r), r))*`x'`(r, theta, phi)*r-(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r+2*(1-f__A(r))*`x'`(r, theta, phi))*g*r+(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^4*g^2), %F[1, 3, 3] = ((1-f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[1, 4, 1] = 0, %F[1, 4, 2] = 0, %F[1, 4, 3] = 0, %F[2, 1, 1] = ((-(diff(f__A(r), r))*`z'`(r, theta, phi)*r+(1-f__A(r))*(diff(`z'`(r, theta, phi), r))*r-2*(1-f__A(r))*`z'`(r, theta, phi))*g*r-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[2, 1, 2] = (-(-1+f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[2, 1, 3] = ((-2*(-1+f__A(r))*`x'`(r, theta, phi)+(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[2, 2, 1] = 0, %F[2, 2, 2] = 0, %F[2, 2, 3] = 0, %F[2, 3, 1] = ((1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[2, 3, 2] = (-(1-f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[2, 3, 3] = ((-1+f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[2, 4, 1] = 0, %F[2, 4, 2] = 0, %F[2, 4, 3] = 0, %F[3, 1, 1] = ((-2*(-1+f__A(r))*`y'`(r, theta, phi)+(diff(f__A(r), r))*`y'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`y'`(r, theta, phi), r))*r)*g*r+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[3, 1, 2] = ((-(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r-2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^4*g^2), %F[3, 1, 3] = (-(1-f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[3, 2, 1] = ((-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[3, 2, 2] = ((1-f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[3, 2, 3] = (-(-1+f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[3, 3, 1] = 0, %F[3, 3, 2] = 0, %F[3, 3, 3] = 0, %F[3, 4, 1] = 0, %F[3, 4, 2] = 0, %F[3, 4, 3] = 0, %F[4, 1, 1] = 0, %F[4, 1, 2] = 0, %F[4, 1, 3] = 0, %F[4, 2, 1] = 0, %F[4, 2, 2] = 0, %F[4, 2, 3] = 0, %F[4, 3, 1] = 0, %F[4, 3, 2] = 0, %F[4, 3, 3] = 0, %F[4, 4, 1] = 0, %F[4, 4, 2] = 0, %F[4, 4, 3] = 0}

(49)

Now for the contravariant ones

"TensorArray(`%F`[~mu,~nu,a] = F[~mu,~nu,a],output=setofequations) "

{%F[`~1`, `~1`, 1] = 0, %F[`~1`, `~1`, 2] = 0, %F[`~1`, `~1`, 3] = 0, %F[`~1`, `~2`, 1] = ((2*(-1+f__A(r))*`z'`(r, theta, phi)-(diff(f__A(r), r))*`z'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`z'`(r, theta, phi), r))*r)*g*r+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~1`, `~2`, 2] = ((1-f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[`~1`, `~2`, 3] = ((-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+((diff(f__A(r), r))*`x'`(r, theta, phi)*r-(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r+2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[`~1`, `~3`, 1] = (((diff(f__A(r), r))*`y'`(r, theta, phi)*r-(1-f__A(r))*(diff(`y'`(r, theta, phi), r))*r+2*(1-f__A(r))*`y'`(r, theta, phi))*g*r-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~1`, `~3`, 2] = ((1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(2*(-1+f__A(r))*`x'`(r, theta, phi)-(diff(f__A(r), r))*`x'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r+(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^4*g^2), %F[`~1`, `~3`, 3] = ((-1+f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[`~1`, `~4`, 1] = 0, %F[`~1`, `~4`, 2] = 0, %F[`~1`, `~4`, 3] = 0, %F[`~2`, `~1`, 1] = ((-2*(-1+f__A(r))*`z'`(r, theta, phi)+(diff(f__A(r), r))*`z'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`z'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~2`, `~1`, 2] = (-(1-f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[`~2`, `~1`, 3] = ((-(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r-2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[`~2`, `~2`, 1] = 0, %F[`~2`, `~2`, 2] = 0, %F[`~2`, `~2`, 3] = 0, %F[`~2`, `~3`, 1] = ((-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[`~2`, `~3`, 2] = (-(-1+f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~2`, `~3`, 3] = ((1-f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~2`, `~4`, 1] = 0, %F[`~2`, `~4`, 2] = 0, %F[`~2`, `~4`, 3] = 0, %F[`~3`, `~1`, 1] = ((-(diff(f__A(r), r))*`y'`(r, theta, phi)*r+(1-f__A(r))*(diff(`y'`(r, theta, phi), r))*r-2*(1-f__A(r))*`y'`(r, theta, phi))*g*r+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~3`, `~1`, 2] = ((-2*(-1+f__A(r))*`x'`(r, theta, phi)+(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^4*g^2), %F[`~3`, `~1`, 3] = (-(-1+f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^4*g^2), %F[`~3`, `~2`, 1] = ((1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^4*g^2), %F[`~3`, `~2`, 2] = ((-1+f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~3`, `~2`, 3] = (-(1-f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^4*g^2), %F[`~3`, `~3`, 1] = 0, %F[`~3`, `~3`, 2] = 0, %F[`~3`, `~3`, 3] = 0, %F[`~3`, `~4`, 1] = 0, %F[`~3`, `~4`, 2] = 0, %F[`~3`, `~4`, 3] = 0, %F[`~4`, `~1`, 1] = 0, %F[`~4`, `~1`, 2] = 0, %F[`~4`, `~1`, 3] = 0, %F[`~4`, `~2`, 1] = 0, %F[`~4`, `~2`, 2] = 0, %F[`~4`, `~2`, 3] = 0, %F[`~4`, `~3`, 1] = 0, %F[`~4`, `~3`, 2] = 0, %F[`~4`, `~3`, 3] = 0, %F[`~4`, `~4`, 1] = 0, %F[`~4`, `~4`, 2] = 0, %F[`~4`, `~4`, 3] = 0}

(50)

At this point, you have the Lagrangian in terms of inert F in (47), so that you can follow by eye that the computation is running as expected, and in (49),(50) you have the value of each inert F. So go ahead and de-inertize all F in (47)NULL

value(-(1/4)*%F[1, 3, 1]*%F[`~1`, `~3`, 1]-(1/4)*%F[1, 3, 2]*%F[`~1`, `~3`, 2]-(1/4)*%F[1, 3, 3]*%F[`~1`, `~3`, 3]-(1/4)*%F[2, 3, 1]*%F[`~2`, `~3`, 1]-(1/4)*%F[2, 3, 2]*%F[`~2`, `~3`, 2]-(1/4)*%F[2, 3, 3]*%F[`~2`, `~3`, 3]-(1/4)*%F[3, 3, 1]*%F[`~3`, `~3`, 1]-(1/4)*%F[3, 3, 2]*%F[`~3`, `~3`, 2]-(1/4)*%F[3, 3, 3]*%F[`~3`, `~3`, 3]-(1/4)*%F[4, 3, 1]*%F[`~4`, `~3`, 1]-(1/4)*%F[4, 3, 2]*%F[`~4`, `~3`, 2]-(1/4)*%F[4, 3, 3]*%F[`~4`, `~3`, 3]-(1/4)*%F[1, 4, 1]*%F[`~1`, `~4`, 1]-(1/4)*%F[1, 4, 2]*%F[`~1`, `~4`, 2]-(1/4)*%F[1, 4, 3]*%F[`~1`, `~4`, 3]-(1/4)*%F[2, 4, 1]*%F[`~2`, `~4`, 1]-(1/4)*%F[2, 4, 2]*%F[`~2`, `~4`, 2]-(1/4)*%F[2, 4, 3]*%F[`~2`, `~4`, 3]-(1/4)*%F[3, 4, 1]*%F[`~3`, `~4`, 1]-(1/4)*%F[3, 4, 2]*%F[`~3`, `~4`, 2]-(1/4)*%F[3, 4, 3]*%F[`~3`, `~4`, 3]-(1/4)*%F[4, 4, 1]*%F[`~4`, `~4`, 1]-(1/4)*%F[4, 4, 2]*%F[`~4`, `~4`, 2]-(1/4)*%F[4, 4, 3]*%F[`~4`, `~4`, 3]-(1/4)*%F[1, 1, 1]*%F[`~1`, `~1`, 1]-(1/4)*%F[1, 1, 2]*%F[`~1`, `~1`, 2]-(1/4)*%F[1, 1, 3]*%F[`~1`, `~1`, 3]-(1/4)*%F[2, 1, 1]*%F[`~2`, `~1`, 1]-(1/4)*%F[2, 1, 2]*%F[`~2`, `~1`, 2]-(1/4)*%F[2, 1, 3]*%F[`~2`, `~1`, 3]-(1/4)*%F[3, 1, 1]*%F[`~3`, `~1`, 1]-(1/4)*%F[3, 1, 2]*%F[`~3`, `~1`, 2]-(1/4)*%F[3, 1, 3]*%F[`~3`, `~1`, 3]-(1/4)*%F[4, 1, 1]*%F[`~4`, `~1`, 1]-(1/4)*%F[4, 1, 2]*%F[`~4`, `~1`, 2]-(1/4)*%F[4, 1, 3]*%F[`~4`, `~1`, 3]-(1/4)*%F[1, 2, 1]*%F[`~1`, `~2`, 1]-(1/4)*%F[1, 2, 2]*%F[`~1`, `~2`, 2]-(1/4)*%F[1, 2, 3]*%F[`~1`, `~2`, 3]-(1/4)*%F[2, 2, 1]*%F[`~2`, `~2`, 1]-(1/4)*%F[2, 2, 2]*%F[`~2`, `~2`, 2]-(1/4)*%F[2, 2, 3]*%F[`~2`, `~2`, 3]-(1/4)*%F[3, 2, 1]*%F[`~3`, `~2`, 1]-(1/4)*%F[3, 2, 2]*%F[`~3`, `~2`, 2]-(1/4)*%F[3, 2, 3]*%F[`~3`, `~2`, 3]-(1/4)*%F[4, 2, 1]*%F[`~4`, `~2`, 1]-(1/4)*%F[4, 2, 2]*%F[`~4`, `~2`, 2]-(1/4)*%F[4, 2, 3]*%F[`~4`, `~2`, 3])

-(1/4)*((2*(-1+f__A(r))*`y'`(r, theta, phi)-(diff(f__A(r), r))*`y'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`y'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*(((diff(f__A(r), r))*`y'`(r, theta, phi)*r-(1-f__A(r))*(diff(`y'`(r, theta, phi), r))*r+2*(1-f__A(r))*`y'`(r, theta, phi))*g*r-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+((diff(f__A(r), r))*`x'`(r, theta, phi)*r-(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r+2*(1-f__A(r))*`x'`(r, theta, phi))*g*r+(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))*((1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(2*(-1+f__A(r))*`x'`(r, theta, phi)-(diff(f__A(r), r))*`x'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r+(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*((-1+f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))*((-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*(-(1-f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*(-(-1+f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*((1-f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-(diff(f__A(r), r))*`z'`(r, theta, phi)*r+(1-f__A(r))*(diff(`z'`(r, theta, phi), r))*r-2*(1-f__A(r))*`z'`(r, theta, phi))*g*r-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*((-2*(-1+f__A(r))*`z'`(r, theta, phi)+(diff(f__A(r), r))*`z'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`z'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*(-(-1+f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*(-(1-f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-2*(-1+f__A(r))*`x'`(r, theta, phi)+(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))*((-(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r-2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*((-2*(-1+f__A(r))*`y'`(r, theta, phi)+(diff(f__A(r), r))*`y'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`y'`(r, theta, phi), r))*r)*g*r+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*((-(diff(f__A(r), r))*`y'`(r, theta, phi)*r+(1-f__A(r))*(diff(`y'`(r, theta, phi), r))*r-2*(1-f__A(r))*`y'`(r, theta, phi))*g*r+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r-2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))*((-2*(-1+f__A(r))*`x'`(r, theta, phi)+(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^8*g^4)-(1/4)*(-(1-f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*(-(-1+f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*(((diff(f__A(r), r))*`z'`(r, theta, phi)*r-(1-f__A(r))*(diff(`z'`(r, theta, phi), r))*r+2*(1-f__A(r))*`z'`(r, theta, phi))*g*r+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*((2*(-1+f__A(r))*`z'`(r, theta, phi)-(diff(f__A(r), r))*`z'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`z'`(r, theta, phi), r))*r)*g*r+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*((1-f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(2*(-1+f__A(r))*`x'`(r, theta, phi)-(diff(f__A(r), r))*`x'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))*((-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+((diff(f__A(r), r))*`x'`(r, theta, phi)*r-(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r+2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))*((1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*((-1+f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*(-(-1+f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*(-(1-f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)

(51)

Introduce the value of the primed variables in terms of spherical coordinates to get your L__FST

L__FST := simplify(eval(-(1/4)*((2*(-1+f__A(r))*`y'`(r, theta, phi)-(diff(f__A(r), r))*`y'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`y'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*(((diff(f__A(r), r))*`y'`(r, theta, phi)*r-(1-f__A(r))*(diff(`y'`(r, theta, phi), r))*r+2*(1-f__A(r))*`y'`(r, theta, phi))*g*r-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+((diff(f__A(r), r))*`x'`(r, theta, phi)*r-(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r+2*(1-f__A(r))*`x'`(r, theta, phi))*g*r+(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))*((1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(2*(-1+f__A(r))*`x'`(r, theta, phi)-(diff(f__A(r), r))*`x'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r+(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*((-1+f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))*((-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*(-(1-f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*(-(-1+f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*((1-f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-(diff(f__A(r), r))*`z'`(r, theta, phi)*r+(1-f__A(r))*(diff(`z'`(r, theta, phi), r))*r-2*(1-f__A(r))*`z'`(r, theta, phi))*g*r-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*((-2*(-1+f__A(r))*`z'`(r, theta, phi)+(diff(f__A(r), r))*`z'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`z'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*(-(-1+f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*(-(1-f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-2*(-1+f__A(r))*`x'`(r, theta, phi)+(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))*((-(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r-2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*((-2*(-1+f__A(r))*`y'`(r, theta, phi)+(diff(f__A(r), r))*`y'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`y'`(r, theta, phi), r))*r)*g*r+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*((-(diff(f__A(r), r))*`y'`(r, theta, phi)*r+(1-f__A(r))*(diff(`y'`(r, theta, phi), r))*r-2*(1-f__A(r))*`y'`(r, theta, phi))*g*r+(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r-2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))*((-2*(-1+f__A(r))*`x'`(r, theta, phi)+(diff(f__A(r), r))*`x'`(r, theta, phi)*r+(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g-(1-f__A(r))*`y'`(r, theta, phi)^2*(-1+f__A(r)))/(r^8*g^4)-(1/4)*(-(1-f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*(-(-1+f__A(r))*(diff(`y'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*(((diff(f__A(r), r))*`z'`(r, theta, phi)*r-(1-f__A(r))*(diff(`z'`(r, theta, phi), r))*r+2*(1-f__A(r))*`z'`(r, theta, phi))*g*r+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*((2*(-1+f__A(r))*`z'`(r, theta, phi)-(diff(f__A(r), r))*`z'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`z'`(r, theta, phi), r))*r)*g*r+(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))*((1-f__A(r))*(diff(`z'`(r, theta, phi), theta))*r^2*g+(-1+f__A(r))^2*`y'`(r, theta, phi)*`z'`(r, theta, phi))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+(2*(-1+f__A(r))*`x'`(r, theta, phi)-(diff(f__A(r), r))*`x'`(r, theta, phi)*r-(-1+f__A(r))*(diff(`x'`(r, theta, phi), r))*r)*g*r-(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))*((-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g+((diff(f__A(r), r))*`x'`(r, theta, phi)*r-(1-f__A(r))*(diff(`x'`(r, theta, phi), r))*r+2*(1-f__A(r))*`x'`(r, theta, phi))*g*r-(-1+f__A(r))*`z'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*((-1+f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(1-f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))*((1-f__A(r))*(diff(`y'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))*(diff(`z'`(r, theta, phi), phi))*r^2*g+(-1+f__A(r))*`x'`(r, theta, phi)^2*(1-f__A(r)))/(r^8*g^4)-(1/4)*((1-f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))*((-1+f__A(r))*(diff(`x'`(r, theta, phi), theta))*r^2*g-(-1+f__A(r))^2*`y'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4)-(1/4)*(-(-1+f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))*(-(1-f__A(r))*(diff(`x'`(r, theta, phi), phi))*r^2*g-(-1+f__A(r))^2*`z'`(r, theta, phi)*`x'`(r, theta, phi))/(r^8*g^4), xyz))

(1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(r*sin(theta)*cos(phi)*cos(theta)*sin(phi)-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*g^2*r*sin(theta)*cos(phi)*cos(theta)*sin(phi)+(-2*r^2-1)*g^2)*(-1+f__A(r))^2)/(r^4*g^4)

(52)

This is again equation (17), the Lagrangian you got in the first approach

simplify(L__FST-(1/2)*(g^2*r^2*(sin(theta)^2*cos(phi)^2+1)*(diff(f__A(r), r))^2+2*g^2*r*(-1+f__A(r))*(sin(theta)*sin(phi)*cos(theta)*cos(phi)*r-sin(theta)^2*cos(phi)^2-1)*(diff(f__A(r), r))-(-1+f__A(r))^2*(1+f__A(r)^2-2*f__A(r)+g^2*(r^2*cos(theta)^2-sin(theta)^2)*cos(phi)^2+2*sin(theta)*sin(phi)*cos(theta)*cos(phi)*g^2*r+(-2*r^2-1)*g^2))/(g^4*r^4))

0

(53)

NULL


 

Download SU(2)-field-strength-tensor_(reviewed).mw

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

OK, it is fixed and the fix distributed as usual within Maplesoft's Physics Updates package, so input Physics:-Version(latest) and that's it.

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

1 2 3 4 5 6 7 Last Page 1 of 58