Physics VPython installation for PHYS160

 Note
This applies specifically to PHYS160, not PHYS140. For instructions on PHYS140, see the Physics VPython Installation for PHYS140 article.

Objective

Install Anaconda Python 2.7 and VPython for PHYS160 or 411 classes.

Environment

  • Chrome OS
  • Linux
  • Mac
  • Windows 7, 8, 10

Procedure

Mac and Windows

  1. Download the Anaconda Python 2 or 3 graphical installer from their website.
  2. Run the downloaded installer.
  3. Once it has finished, open Terminal (Mac) or Command Prompt (Windows) and enter the following: pip install vpython
  4. You can then start up jupyter with: jupyter notebook

Linux and Chrome OS

  1. At this time, we do not have a generally supported procedure for installing VPython on Linux and Chrome OS does not support the program. We recommend that you use Virtual Sites to run remotely on Windows.
  2. Once you are connected, open the Apps Anywhere webpage and search for VPython. Install the application and you can then launch it from the Apps Anywhere window.

Testing

  1. Test that Vpython is working by selecting “New” at the top right of the browser window that opens and selecting VPython from the drop down.
  2. In the code block, type the following:
from vpython import *

box()

A white box with a black background should appear

Additional notes

http://vpython.org/

If the user is having trouble getting VPython working in Jupyter notebook, they may have their path set incorrectly. On Macs, check their ~/.bash_profile file and verify that the anaconda install location is being loaded into their path correctly. Also verify that no other Python installations are appearing in the path first. The same can be done on Windows by typing "Environment Variables" in the Start Menu Bar and selecting the "Environment Variables" result.

Details

Article ID: 1625
Created
Wed 5/27/20 8:28 AM
Modified
Tue 10/13/20 10:00 AM