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

Hi everyone!

I recently installed Cadabra on my Mac OS X 10.10.5 but I'm having trouble when compiling. Indeed, trying to run the following program (using cadabra2-gtk):

{\mu,\nu,\rho,\sigma,\lambda,\kappa,\alpha,\beta,\gamma,\xi}::Indices.
h_{\mu\nu};

then the following error shows up:

/usr/local/opt/python3/Frameworks/Python.framework/Versions/3.6/lib/python3.6/importlib/_bootstrap.py:205: RuntimeWarning: to-Python converter for std::__1::shared_ptr<cadabra::Ex> already registered; second conversion method ignored.\n return f(*args, **kwds)\n File \"<string>\", line 1\n _ = h_{\\mu\\nu}; display(_)\n ^\nSyntaxError: invalid syntax\n\

Any idea on what is the problem?

Thanks already for any help!

in Bug reports by

1 Answer

+1 vote
 
Best answer

In Cadabra 2.x you have to give expressions a name, so your 2nd line has to be something like

ex:= h_{\mu\nu};

This is what the SyntaxError in the last line of your error message refers to.

The first bit (about the to-Python converter) is harmless, you can ignore it.

by (83.0k points)
...