1
$\begingroup$

f is a function of the coordinates x and y, how can I use the command DefScalarFunction to do this?

DefChart[ch,M,{0,1,2,3},{t[],x[],y[],z[]}]
DefScalarFunction[f]
$\endgroup$

1 Answer 1

1
$\begingroup$

There is no need to specify the number of arguments of a scalar function in xTensor. You just need to to specify that it is a scalar function, as you did, with DefScalarFunction[f]. Then you can use it with any number of arguments you want, say f[x[], y[]]. Of course, you should use it in your work with consistent arguments.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.