UniformRays
- class raytracing.UniformRays(yMax=1.0, yMin=None, thetaMax=1.5707963267948966, thetaMin=None, M=100, N=100)
Bases:
RaysA list of rays with uniform distribution.
- Parameters:
yMax (float) – Maximum height for the rays (default=1.0)
yMin (float) – Minimum height for the rays (default=None). If no value is assigned to this parameter it will be -yMax.
thetaMax (float) – Maximum angle for the rays (default=pi/2)
thetaMin (float) – Minimum angle for the rays (default=None) If no value is assigned to this parameter it will be -thetaMax
M (int) – Number of points that are defined for the height of rays
N (int) – Number of rays for each point
Examples
>>> from raytracing import * >>> nRays = 1000 # Increase for better resolution >>> minHeight=0 >>> maxHeight=50 >>> minTheta=0 >>> maxTheta=0.5 >>> # define a list of rays with uniform distribution >>> inputRays = UniformRays(yMin=minHeight, yMax=maxHeight, thetaMin=minTheta,thetaMax=maxTheta, N=nRays, M=10) >>> inputRays.display()
Methods
|
Inherited Methods
|
A ray can be appended to the List of the rays using this function. |
|
This function plots the intensity profiles of a list of rays. |
|
This function prints the progress of the iterations |
|
A list of rays can be loaded using this function. |
|
This functions calculates the histogram for the angle of the rays. |
|
This functions calculates the histogram for the height of the rays. |
|
A list of rays can be saved using this function. |
Attributes
|
Returns the number of rays in the list. |
|
|
|
Returns the angles of rays in the list. |
|
Returns the heights of rays in the list. |