Welcome to Cadabra Q&A, where you can ask questions and receive answers from other members of the community.
0 votes

Receiving this error

Traceback (most recent call last):
  File "<string>", line 2, in <module>
cadabra2.RuntimeException: Can only handle numerical exponents for weight counting.

when running

RicciFull;
drop_weight(_, $field = 3$);

RicciFull has many many terms like

$$h_{b}^{r} h_{d f} h_{e r}+\frac{1}{4}\partial^{b}{h} \partial^{c}{h^{d e}} h_{x}^{f} h^{x}_{c} h_{b}^{r} h_{d f} h_{e}^{s} h_{r s}+\frac{1}{4}\partial^{b}{h^{c d}} \partial_{c}{h^{e f}} h_{x}^{r} h^{x}_{b} h_{d r} h_{e f} $$

Note that

drop_weight(_, $field = 1$)
drop_weight(_, $ field = 3$);

works on a similar (much smaller) expression with the same fields in it.

$$h^{c}_{c}-h^{b c} h_{b c}+h^{b c} h_{b}^{d} h_{c d}-h^{b c} h_{b}^{d} h_{c}^{e} h_{d e}$$

in General questions by (520 points)

Can you email me the full notebook to info@cadabra.science? I can't tell from the bit you wrote whether this is a bug or something you did wrong with the input.

1 Answer

0 votes

I have already answered this by email: the problem was a declaration

\partial{#}::WeightInherit(type=Multiplicative);

which does not do what you want because this option is called 'multiplicative' (without the capital 'M'). I will check in a version shortly which will warn about this.

by (82.5k points)
...