Programming Reference for VirtualLab Fusion  2022.1
Static Public Member Functions | List of all members
AutomaticParaxialPropagation Class Reference

This class is subject to change. Programs using this class may require changes with a new version of VirtualLab.
Class containing static functions for automatic propagation of ComplexAmplitude. More...

Static Public Member Functions

static ComplexAmplitude AutomaticSpwFrt (ComplexAmplitude ca, double distance, Complex n, double numericalAccuracyFactor, bool automaticOutputFieldSizeShape, double outputFieldSizeFactor, VectorD outputFieldFieldSize, BasicParameter.eApertureShape outputFieldShape, double outputFieldBorderWidth, bool automaticOutputFieldSampling, double outputFieldSamplingFactor, int outputFieldEmbedFrameWidth, SamplingParameters outputFieldSamplingParameters, out bool areNumericalErrors)
 Automatic propagation of a FieldRepresentations.ComplexAmplitude. For short propagation distances ElementaryFieldScalingPropagationOperators.Spw is used. For long propagation distances ElementaryFieldScalingPropagationOperators.Frt is used. ComplexAmplitude is changed during the propagation. More...
 
static ComplexAmplitude AutomaticSpwFrt (ComplexAmplitude ca, double distance, Complex n, double numericalAccuracyFactor, out bool areNumericalErrors)
 Automatic propagation of a ComplexAmplitude. For short propagation distances ElementaryFieldScalingPropagationOperators.Spw is used. For long propagation distances ElementaryFieldScalingPropagationOperators.Frt is used. ComplexAmplitude is changed during the propagation. More...
 
static SamplingParameters GetAutomaticSpwFrtOutputFieldSamplingParameters (ComplexAmplitude ca, double distance, Complex n, double numericalAccuracyFactor)
 Calculates the sampling parameters of the output field of AutomaticSpwFrt function without performing a propagation simulation. More...
 

Detailed Description

This class is subject to change. Programs using this class may require changes with a new version of VirtualLab.
Class containing static functions for automatic propagation of ComplexAmplitude.

Member Function Documentation

◆ AutomaticSpwFrt() [1/2]

static ComplexAmplitude AutomaticSpwFrt ( ComplexAmplitude  ca,
double  distance,
Complex  n,
double  numericalAccuracyFactor,
bool  automaticOutputFieldSizeShape,
double  outputFieldSizeFactor,
VectorD  outputFieldFieldSize,
BasicParameter.eApertureShape  outputFieldShape,
double  outputFieldBorderWidth,
bool  automaticOutputFieldSampling,
double  outputFieldSamplingFactor,
int  outputFieldEmbedFrameWidth,
SamplingParameters  outputFieldSamplingParameters,
out bool  areNumericalErrors 
)
static

Automatic propagation of a FieldRepresentations.ComplexAmplitude. For short propagation distances ElementaryFieldScalingPropagationOperators.Spw is used. For long propagation distances ElementaryFieldScalingPropagationOperators.Frt is used. ComplexAmplitude is changed during the propagation.

Parameters
caComplexAmplitude to propagate.
distanceDesired propagation distance.
nComplex refractive index of media in which propagation is applied.
numericalAccuracyFactorThe accuracy factor. A larger factor leads to more accurate results but to higher computational effort.
automaticOutputFieldSizeShapeIf true the output field size, shape and border width are determined by VirtualLab automatically. Otherwise the values can be specified using the outputFieldSize, outputFieldShape and outputFieldBorderWidth parameters.
outputFieldSizeFactorIn case of automaticOutputFieldSizeShape VirtualLab estimates the correct size of the propagated field. The resulting value is multiplied by this factor.
outputFieldFieldSizeThe diameter of the output field in meters. The diameter is measured before the beginning of the border decay of amplitude.
outputFieldShapeThe shape of the field.
outputFieldBorderWidthThe width of the borders of the field relative to the field diameter. The border width is measured between the begin of the amplitude decay and the zero position of the field.
automaticOutputFieldSamplingEnables automatic determination of the required array size and number of sampling points of the output field to minimize numerical errors. Additionally the user may use the outputFieldSamplingFactor to additionally increase or reduce the number of sampling points. The array size of the output field will be calculated from the estimation of the field size multiplied by the outputFieldSizeFactor plus the outputFieldBorderWidth multiplied by the field size plus the embedFrameWidth multiplied by the sampling distance. If automaticOutputFieldSampling is false the outputFieldSamplingParameters will be used.
outputFieldSamplingFactorIf automaticOutputFieldSampling is true VirtualLab estimates the number of sampling points of the output field and multiplies the value by outputFieldSamplingFactor.
outputFieldEmbedFrameWidthIf automaticOutputFieldSampling is false additionally a frame with dark pixels (amplitude equals zero) around the field can be added. This embed frame is required since the continuous field distribution can be reconstructed using a sinc interpolation. This interpolation will introduce small sized loops that are larger than the numerical field size. To take this side loops at least partially into account during the interpolation this embed frame is required. The extension of this frame in sampling points can be specified by this parameter.
outputFieldSamplingParametersThe sampling parameters of the output field. Normally these sampling parameters should be equal to the inputFieldSamplingParameters but the use may change it to any other value.
areNumericalErrorsReturns true if the user defined settings of the numerical accuracy parameter may caused numerical errors during the propagation. This is typically the case if numericalAccuracyFactor is smaller than one.
Returns
The propagated field.

◆ AutomaticSpwFrt() [2/2]

static ComplexAmplitude AutomaticSpwFrt ( ComplexAmplitude  ca,
double  distance,
Complex  n,
double  numericalAccuracyFactor,
out bool  areNumericalErrors 
)
static

Automatic propagation of a ComplexAmplitude. For short propagation distances ElementaryFieldScalingPropagationOperators.Spw is used. For long propagation distances ElementaryFieldScalingPropagationOperators.Frt is used. ComplexAmplitude is changed during the propagation.

Parameters
caComplexAmplitude to propagate.
distanceDesired propagation distance.
nComplex refractive index of media in which propagation is applied.
numericalAccuracyFactorThis value allows to increase the numerical accuracy (values larger one) or decrease the numerical accuracy (values smaller than one) of the simulation result on the costs simulation time and RAM memory.
areNumericalErrorsTrue if the user defined settings of the numerical accuracy parameter may caused numerical errors during the propagation. This is typically the case if numericalAccuracyFactor is smaller than one.
Returns
Result of operation.

◆ GetAutomaticSpwFrtOutputFieldSamplingParameters()

static SamplingParameters GetAutomaticSpwFrtOutputFieldSamplingParameters ( ComplexAmplitude  ca,
double  distance,
Complex  n,
double  numericalAccuracyFactor 
)
static

Calculates the sampling parameters of the output field of AutomaticSpwFrt function without performing a propagation simulation.

Parameters
caComplexAmplitude to propagate.
distanceDesired propagation distance.
nComplex refracting index of media in which propagation is applied.
numericalAccuracyFactorThis value allows to increase the numerical accuracy (values larger one) or decrease the numerical accuracy (values smaller than one) of the simulation result on the costs simulation time and RAM memory.
Returns
The calculated sampling parameters.
Exceptions
PropagationOfHarmonicFieldsOnlyException