Ask Your Question

importing hyperbolic geometry modules

asked 2020-06-15 02:51:05 -0500

Daniel Massart gravatar image

hi everyone, when I type (in SageMath 9.0 Notebook) "from sage.geometry.hyperbolic_space.hyperbolic_point import * ", I get a long answer with bottom line "ImportError: cannot import name complex_number". Thinking it might fix it, I typed "from sage.rings.complex_number import* ", and got again "cannot import name complex_number". Does anyone know a way around this ? thanks in advance Daniel

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted

answered 2020-06-15 05:04:15 -0500

tmonteil gravatar image

This is not about an optional pip package, there is an issue with your Sage installation. How did you install it ? Could you please give us some informations so that someone can try to understand your problem:

  • which version of Sage did you use ?
  • which OS ?
  • did you install Sage from the distro ?
  • did you install Sage from the binaries, and which ones ?
  • did you compile Sage yourself ?
edit flag offensive delete link more


hi Thierry, and thanks a lot for your answer. I installed Sage 9.0 on Windows 10 in the dumbest possible way, by clicking "next" at every opportunity. I guess that answers your last three questions, although I'm not sure I fully understand them ? To install the surface_dynamics package I just used -pip install as suggested on V. Delecroix's web page, and it works just fine, so I thought something might be broken with the hyperbolic geometry package ?

Daniel Massart gravatar imageDaniel Massart ( 2020-06-15 10:46:18 -0500 )edit

about binaries : I think I chose the latest one, SageMath-9.0-Installer-v0.6.0.exe I do not remember having to compile anything

Daniel Massart gravatar imageDaniel Massart ( 2020-06-15 11:46:25 -0500 )edit

update : it works in the Sage console, just not in the Jupyter notebook environment ???? wtf ?

Daniel Massart gravatar imageDaniel Massart ( 2020-06-16 09:34:27 -0500 )edit

answered 2020-06-15 04:01:07 -0500

Daniel Massart gravatar image

ps I did install geometry and rings with sage -pip install package_name --user in the sage shell, then restarted Sage, then restarted my computer, and it still says "cannot import name complex_number". What gives ?

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2020-06-15 02:51:05 -0500

Seen: 29 times

Last updated: Jun 15