Dear all,
I found an unexpected behavior of de Covariant Derivative during my research.
I am calculating covariant derivatives on the Ricci Scalar which solely depends on the radial coordinate, I will generalize this to a function f[r].
I need to calculate the following:
H[a_,b_] :=CD[a][CD[b][f[r]]]
In a simplified version I set the Metricg to that of polar coordinates diag(-1,1,r^2)
I defined CD with the command CD=LC[Metricg]
When I want to calculate the Hrr component I run the function like: H[{1,-polar},{1,-polar}]
The result I get is f''[r], which is the expected result. When I run H[{2,-polar},{2,-polar}], however, the function returns zero, while the connection piece of the second covariant derivative should return r*f'[r].
It seems that by giving an explicit value to an index of a tensor and then taking it's covariant derivative, it is no longer recognized as an index.
Is this the intended way it should function? It definitely isn't the most intuitive, leading me and my colleagues to quite some annoyances and I do not think it is mentioned anywhere in the reference guide. Thinking about how the package interprets input, however, it does make some sense the way it handles this situation.
I did also find one way to circumvent the problem. Using a delta[] function outside the CD you can specify the value and contract it using a dummy index and the CD will still 'see' the dummy index and thus compute the connection term.
Is there perhaps a more elegant solution to this problem?
Thank you for your time,
Kolja