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

Hello, I am testing (after compiling -installing) cadabra2. I see that if I evaluate the poincare_algebra.cnm example two times cadabra gives an error. You have to restart the kernel and then it works again. Is that normal? Thanks!

in General questions by (120 points)

1 Answer

0 votes

What happens here is that the post_process function converts the \commutator{#} argument in the line

{J_{\mu\nu}, P_{\mu}, W_{\mu} }::Depends(\commutator{#}).

to a 0, so that that line becomes

{J_{\mu\nu}, P_{\mu}, W_{\mu} }::Depends(0).

This does not happen on first run, because in that case the function post_process is not defined yet when the above line is encountered.

The problem is that unwrap (which is used in post_process) should have left \commutator{#} untouched.

Thanks for reporting this; will fix in a future update.

by (64.9k points)