Running VPython in Sage Math Cloud

107 views
Skip to first unread message

Aaron Titus

unread,
Aug 3, 2016, 3:10:30 PM8/3/16
to vpytho...@googlegroups.com

SageMathCloud can be used to run Jupyter VPython in less than 2 minutes. Here are the steps:


1. Go to https://cloud.sagemath.com/


2. Click “Create new project” and name it “VPython” and click “Create project without upgrades”


3. In the Terminal Command box on the right side, type “pip install vpython” and click the “run” icon


4. Enter a file name on the left side of the page like “sphere” and click the pulldown menu for “Create” and select “Jupyter Notebook”


5. Input the following in the first cell and run it:


from vpython import *

sphere()


6. My preference is to type the following at a minimum:


from math import *

from vpython import *

scene=canvas()

sphere()


This allows you to create more canvases in later cells. In the second cell, you can run



scene=canvas()

box()


and you will see two canvases. This is how I run multiple VPython programs in a single notebook.


This is the extent of my knowledge of Sage Math Cloud but it seems promising because you can run VPython.


Aaron

Reply all
Reply to author
Forward
0 new messages