Plotting a Helix in Sympy: Troubleshooting and Tips

  • Context: Python 
  • Thread starter Thread starter JD_PM
  • Start date Start date
  • Tags Tags
    Helix Plot Python
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
6 replies · 2K views
JD_PM
Messages
1,125
Reaction score
156
I asked this question on SO, but I am having problems with it (I cannot even get into my account now). It seems that people using the IP I am using are asking a lot and that limits the number of questions I can ask. Please have a look at my question. Here's the link:
[Moderators note: bold large formatting removed. Please use plain text in PF posts.]
https://stackoverflow.com/questions/55576155/how-to-plot-a-helix-in-sympy
After seeing that comment I have tried:

>>>x = sp.symbols('x')
>>>sp.plotting.plot3d_parametric_line(sp.cos(x),sp.sin(x),x, (x,0,10))

But got not plot:

<sympy.plotting.plot.Plot at 0x29104c282e8>

Any help is appreciated.
 
Last edited by a moderator:
Physics news on Phys.org
DrClaude said:
Can you otherwise produce plots? Because the code you wrote works for me.

You can get more information on the plotting command at
https://docs.sympy.org/latest/modules/plotting.html#sympy.plotting.plot.plot3d_parametric_line

Thanks.

Following the same example SymPy provides us with I got the same kind of outcome:

Screenshot (323).png


A weird (for me of course, I have just started with SymPy) outcome between <>.

What am I missing?
 
It appears that your python installation is not capable of opening a window for plotting.

You'll have to give details of your setup.
 
  • Like
Likes   Reactions: JD_PM
JD_PM said:
I use Jupyter Notebook for running code.
I found this:
 
  • Like
Likes   Reactions: jim mcnamara and JD_PM
DrClaude said:
I found this:

Thanks, now fixed! :)

Screenshot (324).png