Programming Reference for VirtualLab Fusion
2025.1
|
This class is subject to change. Programs using this class may require changes with a new version of VirtualLab.
Class to represent a harmonic field mode
More...
Public Member Functions | |
void | EmbedExtractEquidistantFieldData (Vector newNumberOfPoints) |
public support method to embed/extract the equidistant field data matrix to new number of pixels defined by the user | |
QuadraticFunction | ExtractQuadraticPhaseFromEquidistantFieldData () |
public support function to extract/fit a quadratic phase from equidistant 2PI modulo data | |
Complex | GetComplexRefractiveIndexOfEmbeddingMedium () |
Public property to get the complex refractive index of the embedding medium for the stored wavelength. | |
ComplexField | GetEquidistantExData () |
public support method to get the equidistant data for the Ex field component | |
ComplexField | GetEquidistantEyData () |
public support method to get the equidistant data for the Ey field component | |
double[] | GetGridlessWavefrontData (out VectorD[] gridlessCoordinates, out VectorD[] gradientWavefrontPhase) |
public support method get the gridless information stored in the harmonic field mode object for describing the wavefront phase | |
ComplexField | GetMeshInformationOfGridlessWavefrontData () |
public support method to get the mesh information stored on the gridless wavefront data object | |
VectorD | GetPhysicalCoordinateOfSamplingPointForFieldData (Vector pixelCoordinate) |
public support method to get the physical coordinate (of the equidistant sampled field data) for given pixel index | |
double | GetRealRefractiveIndexOfEmbeddingMedium () |
Public property to get the real refractive index of the embedding medium for the stored wavelength. | |
HarmonicFieldMode (ComplexField equidistantFieldDataEx, ComplexField equidistantFieldDataEy, VectorD samplingDistanceEquidistantFieldData, VectorD centerPositionEquidistantFieldData, VectorD[] coordinatesWavefrontPhase, double[] valuesWavefrontPhase, VectorD[] gradientWavefrontPhase, ComplexField meshInformation, HomogeneousMedium mediumOfMode, double wavelength, CartesianCoordinateSystem coordinateSystemOfMode, bool modeGivenInKDomain, double runTime, int modeIndex=-1) | |
standard constructor of the Harmonic Field Mode class (using rudimentary type data definitions) | |
HarmonicFieldMode (DataArray2D griddedData_V, DataArray2D griddedData_WavefrontPhase, HomogeneousMedium mediumOfMode, double wavelength, CartesianCoordinateSystem coordinateSystemOfMode, double runTime, int modeIndex=0, int numberGridlessPointsX=31, int numberGridlessPointsY=31) | |
constructor for harmonic field mode which takes the equidistant sampled U field as well as equidistant sampled wavefront phase information and generates a harmonic field mode with x/y number of gridless sampling points | |
HarmonicFieldMode (DataArray2D griddedData_V, DataArrayGridLess gridlessData_Wavefront, HomogeneousMedium mediumOfMode, double wavelength, CartesianCoordinateSystem coordinateSystemOfMode, bool modeGivenInKDomain, double runTime, int modeIndex=0) | |
standard constructor of the Harmonic Field Mode class (using complex VirtualLab type data definitions) | |
HarmonicFieldMode (HarmonicFieldMode modeToCopy) | |
copy constructor of the harmonic field mode | |
VectorD | InterpolateGradientOfWavefrontDataAtPoint (VectorD position) |
public property to interpolate the wavefront phase value at specified position | |
double | InterpolateWavefrontDataAtPoint (VectorD position) |
public property to interpolate the wavefront phase value at specified position | |
HarmonicFieldMode | PerformFastFourierTransform (double oversamplingFactorWavefrontDowngrade=1.0) |
public support method to perform fast Fourier transform (FFT) to change domain from x to k or vice versa | |
HarmonicFieldMode | PerformSemiAnalyticalFourierTransform (double oversamplingFactorWavefrontDowngrade=1.0) |
public support method to perform semi-analytical Fourier transform (SFT) to change domain from x to k or vice versa | |
void | PhaseDowngradeFullWavefrontPhase (double oversamplingFactor) |
public support method to perform a phase downgrade. The wavefront phase information will be fully transfered to the phase information of the field data. This function will handle an automatically resampling of the equidistant field data. | |
void | PhaseDowngradeWithoutLinearPhase (double oversamplingFactor) |
public support method to perform a phase downgrade. The wavefront phase information will be transfered to the phase information of the field data, besides a fitted linear phase. The linear phase fit is handled internally inside the support method. This function will handle an automatically resampling of the equidistant field data. | |
void | PhaseDowngradeWithoutQuadraticAndLinearPhase (double oversamplingFactor) |
public support method to perform a phase downgrade. The wavefront phase information will be transfered to the phase information of the field data, besides a fitted linear phase and quadratic phase. The linear & quadratic phase fits is handled internally inside the support method. This function will handle an automatically resampling of the equidistant field data. | |
VectorC | PointInterpolationEquidistantFieldData (VectorD position) |
public support method to perform a point interpolation on the equidistant sampled field data | |
void | ResampleFieldDataViaSamplingDistance (VectorD newSamplingDistance) |
public support method to resample the equidistant field data to new sampling parameters | |
void | ResampleFieldDataViaSamplingPoints (Vector newNumberOfPoints) |
public support method to resample the equidistant field data to new number of sampling points | |
void | SetEquidistantExData (ComplexField newExData) |
public support method to set the data matrix for the equidistant field data Ex | |
void | SetEquidistantEyData (ComplexField newEyData) |
public support method to set the data matrix for the equidistant field data Ey | |
void | SetGridlessWavefrontData (double[] wavefrontPhaseValues, VectorD[] gradientWavefrontPhase) |
public property to set the gridless wavefront phase data to the internal stored data | |
void | SetGridlessWavefrontData (VectorD[] coordinates, double[] wavefrontPhaseValues, VectorD[] gradientWavefrontPhase, ComplexField triangleInformation) |
public support method to set the gridless wavefront data (including its gradients) on a newly set of mesh (defined by set of coordinate and mesh/triangle information | |
void | ShowGriddedFieldData (string caption) |
public support method to show the gridded field data | |
void | ShowGridlessWavefrontData (string caption) |
public support method to show the gridless wavefront data | |
Static Public Member Functions | |
static HarmonicFieldMode | GenerateDefaultHarmonicFieldMode (HomogeneousMedium mediumOfMode, double wavelength, VectorD sizeOfField, bool generateFieldInKDomain, int numberOfGriddedPointsX=101, int numberOfGriddedPointsY=101) |
static support function to generate a default harmonic field mode (Ex component will be set to 1/Ey to 0 & wavefront will be set to planar) default number of sampling points are used. | |
static DataArrayGridLess | GenerateGridlessDataArrayWavefrontInformationHexapolar (int density, double radius, VectorD centerOfCoordiantes, bool generateInKDomain) |
static support method to generate a gridless data array for storage of wavefront information (wavefront values and gradients) on a hexapolar grid | |
static DataArrayGridLess | GenerateGridlessDataArrayWavefrontInformationOnXYGrid (Vector numberOfPoint, VectorD size, VectorD centerOfCoordiantes, bool generateInKDomain) |
static support method to generate a gridless data array for storage of wavefront information (wavefront values and gradients) on a regular x/y grid | |
static VectorD[] | GenerateNonEquidistantCoordinateHexapolar (int density, double radius, VectorD centerOfCoordinates, out ComplexField meshInformation) |
static support method to generate mesh information (containing coordinates and triangle information) for a hexapolar grid | |
static VectorD[] | GenerateNonEquidistantCoordinateOnXYGrid (Vector numberOfPoint, VectorD size, VectorD centerOfCoordiantes, out ComplexField meshInformation) |
static support method to generate mesh information (containing coordinates and triangle information) for a XY grid | |
Properties | |
VectorD | CenterOfFieldData [get] |
public property to get the center of stored equidistant field data | |
CartesianCoordinateSystem | CoordinateSystem [get] |
public property to get the coordinate system of the harmonic field mode | |
HomogeneousMedium | EmbeddingMedium [get, set] |
public property to set and get the embedding medium of the harmonic field mode | |
bool | ModeGivenInKDomain [get] |
public property to get whether harmonic field mode is given in k-domain (true) or x-domain (false) | |
int | ModeIndex [get, set] |
public property to set and get the index of the harmonic mode object | |
int | NumberOfGridlessWavefrontPhaseSamples [get] |
public property to get the number of gridless data points stored for gridless data | |
Vector | NumberOfSamplingPointsFieldData [get] |
public property to get the number of sampling points for the equidistant field data | |
double | RunTime [get, set] |
public property to set and get the runtime of the harmonic field mode object | |
VectorD | SamplingDistanceFieldData [get] |
public property to get the sampling distance of the equidistant sampled field data | |
VectorD | SizeOfFieldData [get] |
public property to get the size of the equidistant sampled field data | |
double | Wavelength [get] |
public property to get the wavelength of the harmonic field mode | |
This class is subject to change. Programs using this class may require changes with a new version of VirtualLab.
Class to represent a harmonic field mode
HarmonicFieldMode | ( | DataArray2D | griddedData_V, |
DataArrayGridLess | gridlessData_Wavefront, | ||
HomogeneousMedium | mediumOfMode, | ||
double | wavelength, | ||
CartesianCoordinateSystem | coordinateSystemOfMode, | ||
bool | modeGivenInKDomain, | ||
double | runTime, | ||
int | modeIndex = 0 |
||
) |
standard constructor of the Harmonic Field Mode class (using complex VirtualLab type data definitions)
griddedData_V | gridded data to define the field components |
gridlessData_Wavefront | gridless data for the definition of wavefront (and gradient) |
mediumOfMode | the medium of the harmonic field mode |
wavelength | the wavelength of the harmonic field mode |
coordinateSystemOfMode | the coordinate system of the harmonic field mode |
modeGivenInKDomain | boolean flag whether mode is present in k-domain |
runTime | double value that contains the runtime information of the harmonic field mode |
modeIndex | the index of the harmonic field mode (if no index is defined, 0 is used) |
ArgumentException | throws argument exception in case input data is not consistent |
HarmonicFieldMode | ( | ComplexField | equidistantFieldDataEx, |
ComplexField | equidistantFieldDataEy, | ||
VectorD | samplingDistanceEquidistantFieldData, | ||
VectorD | centerPositionEquidistantFieldData, | ||
VectorD[] | coordinatesWavefrontPhase, | ||
double[] | valuesWavefrontPhase, | ||
VectorD[] | gradientWavefrontPhase, | ||
ComplexField | meshInformation, | ||
HomogeneousMedium | mediumOfMode, | ||
double | wavelength, | ||
CartesianCoordinateSystem | coordinateSystemOfMode, | ||
bool | modeGivenInKDomain, | ||
double | runTime, | ||
int | modeIndex = -1 |
||
) |
standard constructor of the Harmonic Field Mode class (using rudimentary type data definitions)
equidistantFieldDataEx | complex field which contains the equidistant field information of the Ex component |
equidistantFieldDataEy | complex field which contains the equidistant field information of the Ey component |
samplingDistanceEquidistantFieldData | the sampling distance of the equidistantly sampled field data |
centerPositionEquidistantFieldData | the center position of the equidistantly field data |
coordinatesWavefrontPhase | the coordinates for the gridless wavefront data |
valuesWavefrontPhase | the values of the wavefront data (stored in gridless format) |
gradientWavefrontPhase | the gradients of the wavefront data (stored in gridless format) |
meshInformation | information on the mesh/triangle (this could be extracted from ex |
mediumOfMode | the medium of the harmonic field mode |
wavelength | the wavelength of the harmonic field mode |
coordinateSystemOfMode | the coordinate system of the harmonic field mode |
modeGivenInKDomain | boolean flag whether mode is present in k-domain |
runTime | double value that contains the runtime information of the harmonic field mode |
modeIndex | the index of the harmonic field mode (if no index is defined, -1 is used) |
ArgumentException | throws argument exception in case input data is not consistent |
HarmonicFieldMode | ( | HarmonicFieldMode | modeToCopy | ) |
copy constructor of the harmonic field mode
modeToCopy | the mode to be copied |
HarmonicFieldMode | ( | DataArray2D | griddedData_V, |
DataArray2D | griddedData_WavefrontPhase, | ||
HomogeneousMedium | mediumOfMode, | ||
double | wavelength, | ||
CartesianCoordinateSystem | coordinateSystemOfMode, | ||
double | runTime, | ||
int | modeIndex = 0 , |
||
int | numberGridlessPointsX = 31 , |
||
int | numberGridlessPointsY = 31 |
||
) |
constructor for harmonic field mode which takes the equidistant sampled U field as well as equidistant sampled wavefront phase information and generates a harmonic field mode with x/y number of gridless sampling points
griddedData_V | the equidistantly sampled data for U |
griddedData_WavefrontPhase | the gridded data to define the wavefront phase |
mediumOfMode | the medium of the mode |
wavelength | the wavelength of the mode |
coordinateSystemOfMode | the coordinate system of the mode |
runTime | run time to store at the mode |
modeIndex | optional parameters for |
numberGridlessPointsX | |
numberGridlessPointsY |
ArgumentException |
void EmbedExtractEquidistantFieldData | ( | Vector | newNumberOfPoints | ) |
public support method to embed/extract the equidistant field data matrix to new number of pixels defined by the user
newNumberOfPoints | the number of pixels to be used for embed/extract operation |
QuadraticFunction ExtractQuadraticPhaseFromEquidistantFieldData | ( | ) |
public support function to extract/fit a quadratic phase from equidistant 2PI modulo data
|
static |
static support function to generate a default harmonic field mode (Ex component will be set to 1/Ey to 0 & wavefront will be set to planar) default number of sampling points are used.
mediumOfMode | the medium of the harmonic field mode to be generated |
wavelength | the wavelength to be used for generation of default harmonic field mode |
sizeOfField | the size to use for generation of default harmonic field mode |
generateFieldInKDomain | boolean flag, whether harmonic field mode shall be generated in k-domain (true) or x-domain |
numberOfGriddedPointsX | optional parameter for the number of points in x-direction |
numberOfGriddedPointsY | optional parameter for the number of points in y-direction |
|
static |
static support method to generate a gridless data array for storage of wavefront information (wavefront values and gradients) on a hexapolar grid
density | the density (defines the number of rings to be generated) |
radius | the radius on which the coordinates shall be generated |
centerOfCoordiantes | the coordinate center for the coordinate generation |
generateInKDomain | boolean flag whether data array information shall be given in k (true) or x (false) domain |
|
static |
static support method to generate a gridless data array for storage of wavefront information (wavefront values and gradients) on a regular x/y grid
numberOfPoint | the number of grid points in x- and y-direction |
size | the size on which the coordinates shall be generated |
centerOfCoordiantes | the coordinate center for the coordinate generation |
generateInKDomain | boolean flag whether data array information shall be given in k (true) or x (false) domain |
|
static |
static support method to generate mesh information (containing coordinates and triangle information) for a hexapolar grid
density | the density (defines the number of rings to be generated) |
radius | radius of the hexapolar mesh to generate |
centerOfCoordinates | the center of the coordinates to generate |
meshInformation | out parameter for the triangle information |
|
static |
static support method to generate mesh information (containing coordinates and triangle information) for a XY grid
numberOfPoint | number of points to generate |
size | the size of the mesh to be generated |
centerOfCoordiantes | the center of the coordinates to generate |
meshInformation | out parameter for the triangle information |
Complex GetComplexRefractiveIndexOfEmbeddingMedium | ( | ) |
Public property to get the complex refractive index of the embedding medium for the stored wavelength.
ComplexField GetEquidistantExData | ( | ) |
public support method to get the equidistant data for the Ex field component
ComplexField GetEquidistantEyData | ( | ) |
public support method to get the equidistant data for the Ey field component
double[] GetGridlessWavefrontData | ( | out VectorD[] | gridlessCoordinates, |
out VectorD[] | gradientWavefrontPhase | ||
) |
public support method get the gridless information stored in the harmonic field mode object for describing the wavefront phase
gridlessCoordinates | out parameter for the list of coordinates on which the data is defined |
gradientWavefrontPhase | out parameter for list of gradients of the wavefront phase (on associated coordinate) |
ComplexField GetMeshInformationOfGridlessWavefrontData | ( | ) |
public support method to get the mesh information stored on the gridless wavefront data object
public support method to get the physical coordinate (of the equidistant sampled field data) for given pixel index
pixelCoordinate | the pixel coordinate for which the physical coordinate shall be evaluated |
ArgumentException | if pixel index is smaller 0 or larger then number of given sampling points, an ArgumentException is thrown |
double GetRealRefractiveIndexOfEmbeddingMedium | ( | ) |
Public property to get the real refractive index of the embedding medium for the stored wavelength.
public property to interpolate the wavefront phase value at specified position
position | position information on which the wavefront phase data shall be interpolated |
double InterpolateWavefrontDataAtPoint | ( | VectorD | position | ) |
public property to interpolate the wavefront phase value at specified position
position | position information on which the wavefront phase data shall be interpolated |
HarmonicFieldMode PerformFastFourierTransform | ( | double | oversamplingFactorWavefrontDowngrade = 1::0 | ) |
public support method to perform fast Fourier transform (FFT) to change domain from x to k or vice versa
oversamplingFactorWavefrontDowngrade | optional parameter that shall be used for phase downgrade |
HarmonicFieldMode PerformSemiAnalyticalFourierTransform | ( | double | oversamplingFactorWavefrontDowngrade = 1::0 | ) |
public support method to perform semi-analytical Fourier transform (SFT) to change domain from x to k or vice versa
oversamplingFactorWavefrontDowngrade | optional parameter that shall be used for phase downgrade |
void PhaseDowngradeFullWavefrontPhase | ( | double | oversamplingFactor | ) |
public support method to perform a phase downgrade. The wavefront phase information will be fully transfered to the phase information of the field data. This function will handle an automatically resampling of the equidistant field data.
oversamplingFactor | The user can define an additional oversampling factor, which will be applied to the automatically evaluated sampling distance necessary to resolve the wavefront phase in 2PI modulo format. |
void PhaseDowngradeWithoutLinearPhase | ( | double | oversamplingFactor | ) |
public support method to perform a phase downgrade. The wavefront phase information will be transfered to the phase information of the field data, besides a fitted linear phase. The linear phase fit is handled internally inside the support method. This function will handle an automatically resampling of the equidistant field data.
oversamplingFactor | The user can define an additional oversampling factor, which will be applied to the automatically evaluated sampling distance necessary to resolve the wavefront phase in 2PI modulo format. |
void PhaseDowngradeWithoutQuadraticAndLinearPhase | ( | double | oversamplingFactor | ) |
public support method to perform a phase downgrade. The wavefront phase information will be transfered to the phase information of the field data, besides a fitted linear phase and quadratic phase. The linear & quadratic phase fits is handled internally inside the support method. This function will handle an automatically resampling of the equidistant field data.
oversamplingFactor | The user can define an additional oversampling factor, which will be applied to the automatically evaluated sampling distance necessary to resolve the wavefront phase in 2PI modulo format. |
public support method to perform a point interpolation on the equidistant sampled field data
position | the position to evaluate |
void ResampleFieldDataViaSamplingDistance | ( | VectorD | newSamplingDistance | ) |
public support method to resample the equidistant field data to new sampling parameters
newSamplingDistance | the sampling distance of the equidistantly sample field data that shall be used for interpolation |
void ResampleFieldDataViaSamplingPoints | ( | Vector | newNumberOfPoints | ) |
public support method to resample the equidistant field data to new number of sampling points
newNumberOfPoints | the sampling points of the equidistantly sample field data that shall be used for interpolation |
void SetEquidistantExData | ( | ComplexField | newExData | ) |
public support method to set the data matrix for the equidistant field data Ex
newExData | the new data matrix for Ex to set |
ArgumentException | in case number of pixel does not match, ArgumentException is thrown |
void SetEquidistantEyData | ( | ComplexField | newEyData | ) |
public support method to set the data matrix for the equidistant field data Ey
newEyData | the new data matrix for Ey to set |
ArgumentException | in case number of pixel does not match, ArgumentException is thrown |
void SetGridlessWavefrontData | ( | double[] | wavefrontPhaseValues, |
VectorD[] | gradientWavefrontPhase | ||
) |
public property to set the gridless wavefront phase data to the internal stored data
wavefrontPhaseValues | array of wavefront phase data values to be set |
gradientWavefrontPhase | array of wavefront phase gradient values to be set |
ArgumentException | in case the number of input values does not match to the internal data structures, an argument exception will be thrown |
void SetGridlessWavefrontData | ( | VectorD[] | coordinates, |
double[] | wavefrontPhaseValues, | ||
VectorD[] | gradientWavefrontPhase, | ||
ComplexField | triangleInformation | ||
) |
public support method to set the gridless wavefront data (including its gradients) on a newly set of mesh (defined by set of coordinate and mesh/triangle information
coordinates | the coordinates to set |
wavefrontPhaseValues | the wavefront phase samples to set |
gradientWavefrontPhase | the wavefront phase gradient samples to set |
triangleInformation | the mesh/triangle information |
ArgumentException | in case any input parameter is not initialized, or the number of values does not match with the number of coordinates, an argument exception is thrown |
void ShowGriddedFieldData | ( | string | caption | ) |
public support method to show the gridded field data
caption | caption for output |
void ShowGridlessWavefrontData | ( | string | caption | ) |
public support method to show the gridless wavefront data
caption | caption for output |
|
get |
public property to get the center of stored equidistant field data