Skip to content

Free index error in derivatives #57

@gauravharsha

Description

@gauravharsha

In the current implementation, the differentiation of drudge tensors with respect to Indexed quantities is only allowed if the indices are not present as free indices (i.e., not summed over) in the original tensor. Consider, e.g.,

X(p) = t(p) + sum_q t(q) V(q)

Then, the derivative dX(p) / dt(p) should be:

dX(p) / dt(p) = 1 + V(p)

However, because the index "p" is a free index in the expression X, drudge throws an error:

Invalid index p clashing with existing free symbols

It comes from the following segment of the code: Link to the code source

I do not know the rationale behind this conditional throw, but it can and should be remedied.
Calculating derivatives is integral in obtaining stationarity equations, so the requested functionality would be beneficial.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions