IGLib
1.7.2
The IGLib base library EXTENDED - with other lilbraries and applications.
|
Public Member Functions | |
RoughBilliard () | |
void | PropagateRay () |
Propagate the ray from the current to the next point. The current r0 and A0 should already be known. Overwrites the r0 and A0 with the new values. More... | |
void | FollowATrajectory () |
Follows a trajectory of a billiard ball and writes the results to the list r. More... | |
void | WriteATrajectoryToFile (int fileNumber) |
void | WriteStateSpaceTrajectoryToFile (int fileNumber) |
void | ExploreStateSpace (double initCosGamma, double finalCosGamma, int stepsCosGamma, double initPhi, double finalPhi, int stepsPhi) |
Constructs a grid of initial conditions and runs a simulation for each of them. More... | |
Properties | |
double | a [get, set] |
The amplitude of the boundary's roughness (waviness). More... | |
int | n [get, set] |
The roughness of the boundary. More... | |
double[] | InitialPointPolar [get, set] |
The initial point of the current ray in polar coordinates. More... | |
double | InitialDirectionAngle [set] |
The direction vector of the current ray. More... | |
double | InitialPhi [get, set] |
double | InitialCosGamma [get, set] |
int | FirstScanIntervals [get, set] |
The number of intervals on which the presence of a solution is tested. More... | |
double | AccuracyGoal [get, set] |
The accuracy of the bisection. More... | |
int | NPropagations [get, set] |
The number of propagations that the FollowATrajectory() method will execute. More... | |
Private Member Functions | |
double | IntersectionFunction (double phi) |
Used to calculate the intersections of rays, which don't go through the origin, with the billiard boundary. If this method returns 0, then there is an intersection located at the input polar angle phi. More... | |
double | RadiusFunction (double phi) |
Returns the radius at which the boundary exists at a certain phi. More... | |
double | K (double phi) |
The normalization factor of the tangent and the normal to the boundary. More... | |
double | Comp1 (double phi) |
The x component of the tangent to the boundary. More... | |
double | Comp2 (double phi) |
The y component of the tangent to the boundary. More... | |
Private Attributes | |
double | _a = 0.1 |
The amplitude of the boundary's roughness (waviness). More... | |
int | _n = 5 |
The roughness of the boundary. More... | |
double[] | _r0Cart = new double[2] |
The initial point of the current ray. More... | |
double[] | _r0Polar = new double[2] |
The initial point of the current ray in polar coordinates. More... | |
double[] | _A0Cart = new double[2] |
The direction vector of the current ray. More... | |
double | _initialPhi |
double | _initialCosGamma |
double[] | _A1Cart = new double[2] |
A temporaray variable. More... | |
double[] | _r1Cart = new double[2] |
The initial point of the next ray. A temporary variable. More... | |
double | _alpha0 |
The angle between the ray and the x-axis in case the ray goes through the origin. More... | |
List< double[]> | _vPolar = new List<double[]>(10) |
A list of all the polar coordinates of the intersections between the ray and the boundary. More... | |
List< double[]> | _vCart = new List<double[]>(10) |
A list of all the cartesian coordinates of the intersections between the ray and the boundary. More... | |
double | _d0 |
The angular momentum. Also the distance between the current ray and the origin. More... | |
double | _beta0 |
The angle between the distance vector and the x-axis. More... | |
double[] | _n0Cart = new double[2] |
The normal vector to the boundary. Points outwards. More... | |
int | _firstScanIntervals = 10000 |
The number of intervals on which the presence of a solution is tested. More... | |
double | intervalWidth |
The interval width of the "search for rough positions of the intersections" method. More... | |
List< double[]> | solutionIntervals = new List<double[]>(10) |
The found intervals on which the solution exists. More... | |
double | firstValue |
The values at the start and at the end of the interval. More... | |
double | secondValue |
double | leftPoint |
The variables used for bisection - searching for precise positions of the solutions. More... | |
double | midPoint |
double | rightPoint |
double | leftValue |
double | midValue |
double | rightValue |
double | _accuracyGoal = 0.000000001 |
The accuracy of the bisection. More... | |
double | t |
A multiplier used at searching for the closest point in the direction of A. More... | |
double | chosenT |
double | _comp1 |
The x component of the tangent to the boundary. More... | |
double | _comp2 |
The y component of the tangent to the boundary. More... | |
double | _K |
The normalization factor of the tangent to the boundary. More... | |
double | _cosGamma = Double.NaN |
The projection of the direction vector on the tangent to the boundary. More... | |
int | _nPropagations = 500 |
List< double[]> | _r = new List<double[]>(100) |
A list of points marking the ray's path. More... | |
List< double[]> | _stateCoordinates = new List<double[]>(100) |
A list of projections of the direction vector on the tangent to the boundary. More... | |
|
inline |
|
inlineprivate |
Used to calculate the intersections of rays, which don't go through the origin, with the billiard boundary. If this method returns 0, then there is an intersection located at the input polar angle phi.
phi | The input polar angle. |
|
inlineprivate |
Returns the radius at which the boundary exists at a certain phi.
phi | The phi at which the boundary radius is being calculated. |
|
inlineprivate |
The normalization factor of the tangent and the normal to the boundary.
phi | The angle coordinate. |
|
inlineprivate |
The x component of the tangent to the boundary.
phi | The angle coordinate. |
|
inlineprivate |
The y component of the tangent to the boundary.
phi | The angle coordinate. |
|
inline |
Propagate the ray from the current to the next point. The current r0 and A0 should already be known. Overwrites the r0 and A0 with the new values.
|
inline |
Follows a trajectory of a billiard ball and writes the results to the list r.
|
inline |
|
inline |
|
inline |
Constructs a grid of initial conditions and runs a simulation for each of them.
///
initCosGamma | Initial projection of the momentum to the boundary. |
finalCosGamma | Final projection of the momentum to the boundary. |
stepsCosGamma | |
initPhi | |
finalPhi | |
stepsPhi |
Referenced by IG.MPetekLib.Application.Scripts._27Billiard.Run().
|
private |
The amplitude of the boundary's roughness (waviness).
|
private |
The roughness of the boundary.
|
private |
The initial point of the current ray.
|
private |
The initial point of the current ray in polar coordinates.
|
private |
The direction vector of the current ray.
|
private |
|
private |
|
private |
A temporaray variable.
|
private |
The initial point of the next ray. A temporary variable.
|
private |
The angle between the ray and the x-axis in case the ray goes through the origin.
|
private |
A list of all the polar coordinates of the intersections between the ray and the boundary.
|
private |
A list of all the cartesian coordinates of the intersections between the ray and the boundary.
|
private |
The angular momentum. Also the distance between the current ray and the origin.
|
private |
The angle between the distance vector and the x-axis.
|
private |
The normal vector to the boundary. Points outwards.
|
private |
The number of intervals on which the presence of a solution is tested.
|
private |
The interval width of the "search for rough positions of the intersections" method.
|
private |
The found intervals on which the solution exists.
|
private |
The values at the start and at the end of the interval.
|
private |
|
private |
The variables used for bisection - searching for precise positions of the solutions.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
The accuracy of the bisection.
|
private |
A multiplier used at searching for the closest point in the direction of A.
|
private |
|
private |
The x component of the tangent to the boundary.
|
private |
The y component of the tangent to the boundary.
|
private |
The normalization factor of the tangent to the boundary.
|
private |
The projection of the direction vector on the tangent to the boundary.
|
private |
|
private |
A list of points marking the ray's path.
|
private |
A list of projections of the direction vector on the tangent to the boundary.
|
getset |
The amplitude of the boundary's roughness (waviness).
Referenced by IG.MPetekLib.Application.Scripts._27Billiard.Run().
|
getset |
The roughness of the boundary.
Referenced by IG.MPetekLib.Application.Scripts._27Billiard.Run().
|
getset |
The initial point of the current ray in polar coordinates.
|
set |
The direction vector of the current ray.
|
getset |
|
getset |
|
getset |
The number of intervals on which the presence of a solution is tested.
|
getset |
The accuracy of the bisection.
|
getset |
The number of propagations that the FollowATrajectory() method will execute.
Referenced by IG.MPetekLib.Application.Scripts._27Billiard.Run().