Testing rotations


In [2]:
from pyoptools.all import *


('Loading component library', 'Edmund', ' from files ', ['/home/wcamilo96/anaconda2/envs/pyoptools/lib/python2.7/site-packages/pyoptools-0.1.1-py2.7-linux-x86_64.egg/pyoptools/raytrace/library/Edmund/SphOptics1.cmp', '/home/wcamilo96/anaconda2/envs/pyoptools/lib/python2.7/site-packages/pyoptools-0.1.1-py2.7-linux-x86_64.egg/pyoptools/raytrace/library/Edmund/SphOptics.cmp'])

In [47]:
# Rotations 

S=System()

R=[Ray(pos=(0,0,0),dir=(1,0,0),wavelength=.450), # blue ray
   Ray(pos=(0,0,0),dir=(0,1,0),wavelength=.550), # yellow ray
   Ray(pos=(0,0,0),dir=(0,0,1),wavelength=.650)] # red ray



S.ray_add(R)
S.propagate()

Plot3D(S,center=(0,0,0),size=(4,3),scale=150,rot=[(pi/2,pi/2,pi/2),(0,0,0)])


Out[47]:

In [52]:
# 


S=System()

R=[Ray(pos=(0,0,0),dir=(1,0,0),wavelength=.450), # Blue
   Ray(pos=(0,0,0),dir=(0,1,0),wavelength=.550), # Yellow
   Ray(pos=(0,0,0),dir=(0,0,1),wavelength=.650)] # Red



S.ray_add(R)
S.propagate()

Plot3D(S,center=(0,0,0),size=(4,3),scale=150,rot=[(0,0,pi/2),(0,pi/2,0),(pi/2,0,0)])


Out[52]: