Simply use mr = function('m')(r)
See https://nbviewer.jupyter.org/github/sagemanifolds/SageManifolds/blob/master/Worksheets/v1.3/SM_TOV.ipynb for a full example. Best wishes, Eric. Le dimanche 4 octobre 2020 à 10:15:43 UTC+2, matt...@gmail.com a écrit : > I am trying to calculate the general expression of the Kretschmann scalar > of metric depending a non specified function m(r): how do I define such a > function? II have tried with > def m(r) > but it is wrong since it expects a definition of the function > -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/sage-support/8021ebb0-eddb-4102-84dc-81b38900e47cn%40googlegroups.com.