I want to work in the Schwarzchild metric in 2 dimensions with the coordinates $v, r, \theta$. My hope was that I could define a scalar function made up of 2 other scalar functions:
$$\Psi(v,r,\theta) = v + \phi(r) + \chi(v,r,\theta).$$
Then later, define a vector whose components are the partial derivative of this scalar:
$$u_\mu = \partial_\mu \Psi.$$
I was hoping that upon creation of the chart and basis, that by taking the derivatives of this scalar it would for instance know that $\partial_v \phi(r)=0$ without my needing to insert substitutions.
Any attempt at a minimal working example is as follows:
Clear["Global`*"]
<< xAct`xCoba`
DefManifold[M, 3, {a, b, c, d, e, f}]
DefChart[coords, M, {0, 1, 2}, {v[], r[], \[Theta][]}]
DefScalarFunction[\[CapitalPhi], X, \[Phi], \[Chi]]
\[CapitalPsi] = v[] + \[Phi][r[]] + \[Chi][v[], r[], \[Theta][]]
PDcoords[{-b, -coords}][\[CapitalPsi]]
TableOfComponents[%, -sch]
This currently gives an output of:
Throw: Uncaught Throw[Null] returned to top level.
I'm pretty new to xCoba so apologies if this is just a misunderstanding of functions and their definitions.