|
Programming Reference for VirtualLab Fusion
2022.1
|
This class is subject to change. Programs using this class may require changes with a new version of VirtualLab.
Class containing a set of harmonic fields (i.e. of instances of class ComplexAmplitude).
More...
Public Member Functions | |
| virtual int | Add (ComplexAmplitude ca) |
| Checks whether the passed parameter is a complexAmplitudeField type and adds it to either file list in RAM or file list in hard disk and returns index. More... | |
| void | Add (HarmonicFieldsSet hfsToAdd) |
| Adds all member fields of a given harmonic fields set. The same consistency rules as for adding single fields apply (for example a spectral harmonic fields set cannot be added to a spatial one). More... | |
| void | ClearAdvancedIndexerCache () |
| public help method to clear the cache which is used for the advanced indexer | |
| void | CopyCoordinateSystemsFromOtherHFS (HarmonicFieldsSet hfsSource) |
| support method to copy the coordinate system information from the source HFS to the current instance More... | |
| CartesianCoordinateSystem | GetCoordinateSystemForMember (int indexMember) |
| public property to get the Cartesian coordinate system that is associated with the member at index #indexMember More... | |
| int | GetNumberOfIncoherentModesPerWavelength (double wavelength) |
| Public support method which can be used to get the number of incoherent modes for a specified wavelength. More... | |
| List< double > | GetSortedListOfWavelength () |
| Public support method which provides a sorted list of all wavelengths present in the harmonic fields set. More... | |
| HarmonicFieldsSet () | |
| Default Constructor | |
| HarmonicFieldsSet (ComplexAmplitude[] fields) | |
| Constructor for generating a HarmonicFieldsSet out of list of harmonic field. All harmonic fields must be of the same type, must have the same dimensionality, polarization, and embedding medium - otherwise an ArgumentException is raised. More... | |
| HarmonicFieldsSet (HarmonicFieldsSet sf) | |
| copy constructor. More... | |
| HarmonicFieldsSet | IndexWiseSummation (HarmonicFieldsSet hfs) |
| Index wise summation of two harmonic fields, i.e. this[i] + hfs[i] (Complex Amplitude Summation) More... | |
| virtual void | Insert (int index, ComplexAmplitude ca) |
| Insert a ComplexAmplitude into the list. More... | |
| string | ModeNumberString (int index, bool omitWavelength=false) |
| Creates a string like "Field #1" to ensure the correct sorting in the parameter run. The number of digits is determined from the number of member fields in the harmonic fields set. More... | |
| string | ModeString (int indexWavelength, int indexIncoherentMode, bool omitWavelength=false) |
| Generates a human-readable string describing the specified mode. More... | |
| virtual void | RemoveAt (int index) |
| remove the specified ca file with the given index from the file list stored in RAM /Hard Disk. More... | |
| override void | RemoveSphericalPhaseFactor () |
| Removes the Spherical Phase Factor of all member fields. | |
| override void | Save (string fileName) |
| Saves current HarmonicFieldsSet into a file in binary format. More... | |
| void | SetCoordinateForMember (int indexMember, CartesianCoordinateSystem csToSet) |
| public support method which can be used to set the coordinate system for a specific member More... | |
| void | SetSameCoordinateSystemToAllMembers (CartesianCoordinateSystem csToSet) |
| public support method which set the coordinate system csToSet to all member of the harmonic fields set More... | |
Public Member Functions inherited from HarmonicFieldBase | |
| HarmonicFieldBase () | |
| Default constructor to initialize a new instance of the HarmonicFieldBase class. | |
| HarmonicFieldBase (HarmonicFieldBase field) | |
| Copy constructor to initialize a new instance of the HarmonicFieldBase class. More... | |
| HarmonicFieldBase (SerializationInfo info, StreamingContext context) | |
| Deserialization constructor to initialize new instance of the HarmonicFieldBase class. More... | |
| abstract void | RemoveSphericalPhaseFactor () |
| Removes the Spherical Phase Factor(s) from the field. | |
Public Member Functions inherited from FieldRepresentationObject | |
| override object | Clone () |
| Clones the current object. More... | |
| override bool | Equals (object otherObject, EqualityIntent equalityIntent) |
| Determines whether the specified Object is equal to this instance. More... | |
| FieldRepresentationObject () | |
| Standard constructor. | |
| FieldRepresentationObject (FieldRepresentationObject fro) | |
| Copy constructor. More... | |
| FieldRepresentationObject (SerializationInfo info, StreamingContext context) | |
| Deserialization constructor. See the ISerializable interface for more details. More... | |
| abstract void | Save (string filename) |
| Implementation of the IDocument Save function. More... | |
Public Member Functions inherited from IDocument | |
| void | Reload () |
| Reload function for the document | |
Static Public Member Functions | |
| static string | ModeStringOneIndex (int index) |
| Creates a string like "Field #1" to ensure the correct sorting in the parameter run. The number of digits is determined from the number of member fields in the harmonic fields set. More... | |
| static string | ModeStringTwoIndices (int indexWavelength, double wavelength, int indexIncoherentMode, int numberOfIncoherentModesForWavelength) |
| Generates a human-readable string describing the specified mode. More... | |
Properties | |
| int | Count [get] |
| Get the number of complex amplitude fields in the HarmonicFieldsSet. | |
| virtual bool | IsOneD [get] |
| Returns true if the first member is one dimensional. | |
| override bool | IsSpatial [get, set] |
Gets and sets whether all member fields are in spatial domain (if true) or spectral domain (if false). More... | |
| virtual ComplexAmplitude | this[int index] [get, set] |
| Indexer for access to the ComplexAmplitude object the harmonic fields set consists of with the possibility to check consistency. | |
| ComplexAmplitude | this[int wavelengthIndex, int incoherentIndex] [get, set] |
| Advanced indexer for the harmonic fields set The indexer is two-dimensional. The first index value is the index of the wavelength which shall be investigated. The (sorted) list of wavelengths can be evaluated by the method GetSortedListOfWavelength(). The second index value is the indexer for the incoherent mode of the specified wavelength index. The number of incoherent modes for a specific wavelength can be investigated by the method GetNumberOfIncoherentModesPerWavelength(double wavelength). In case that the index which shall be investigated is not valid, an ArgumentException is thrown, which contains additional information. More... | |
Properties inherited from HarmonicFieldBase | |
| abstract bool | IsSpatial [get, set] |
Gets and sets whether the field is in spatial domain (if true) or spectral domain (if false). | |
Properties inherited from FieldRepresentationObject | |
| OpticalSystems.HomogeneousMedium | EmbeddingMedium [get, set] |
| Medium the light field object is located in | |
| abstract FieldRepresentation | FieldRepresentation [get] |
| Get field representation. More... | |
| abstract string | FileExtension [get] |
| File extension More... | |
| abstract DocumentType | TypeOfDocument [get] |
| The type of the document. | |
Properties inherited from IDocument | |
| VirtualLabSession | Session [get, set] |
| every documents need to be handled in a session ==> default is the VirtualLab Mainsession | |
| NodeVLExplorer | TreeStructure [get] |
| every document should have a node (maybe with subnodes) in the VirtualLab Explorer | |
| DocumentType | TypeOfDocument [get] |
| Gets an enum entry specifying the type of the document. | |
This class is subject to change. Programs using this class may require changes with a new version of VirtualLab.
Class containing a set of harmonic fields (i.e. of instances of class ComplexAmplitude).
| HarmonicFieldsSet | ( | ComplexAmplitude[] | fields | ) |
Constructor for generating a HarmonicFieldsSet out of list of harmonic field. All harmonic fields must be of the same type, must have the same dimensionality, polarization, and embedding medium - otherwise an ArgumentException is raised.
| fields | Either a single ComplexAmplitude object or an array of ComplexAmplitude objects. |
copy constructor.
| sf | field to copy. |
|
virtual |
Checks whether the passed parameter is a complexAmplitudeField type and adds it to either file list in RAM or file list in hard disk and returns index.
| ca |
| void Add | ( | HarmonicFieldsSet | hfsToAdd | ) |
Adds all member fields of a given harmonic fields set. The same consistency rules as for adding single fields apply (for example a spectral harmonic fields set cannot be added to a spatial one).
| hfsToAdd | The HarmonicFieldsSet object to add. |
| void CopyCoordinateSystemsFromOtherHFS | ( | HarmonicFieldsSet | hfsSource | ) |
support method to copy the coordinate system information from the source HFS to the current instance
| hfsSource | the harmonic fields set from which the coordinate information shall be copied |
| CartesianCoordinateSystem GetCoordinateSystemForMember | ( | int | indexMember | ) |
public property to get the Cartesian coordinate system that is associated with the member at index #indexMember
| indexMember | the index for which the CS shall be evaluated |
| int GetNumberOfIncoherentModesPerWavelength | ( | double | wavelength | ) |
Public support method which can be used to get the number of incoherent modes for a specified wavelength.
| wavelength | The wavelength for which the number of incoherent modes should be evaluated. |
| List< double > GetSortedListOfWavelength | ( | ) |
Public support method which provides a sorted list of all wavelengths present in the harmonic fields set.
| HarmonicFieldsSet IndexWiseSummation | ( | HarmonicFieldsSet | hfs | ) |
Index wise summation of two harmonic fields, i.e. this[i] + hfs[i] (Complex Amplitude Summation)
| hfs | The second harmonic fields set to add to this harmonic fields set. |
|
virtual |
Insert a ComplexAmplitude into the list.
| index | The index at which the field shall be inserted. |
| ca | The field to insert. |
| string ModeNumberString | ( | int | index, |
| bool | omitWavelength = false |
||
| ) |
Creates a string like "Field #1" to ensure the correct sorting in the parameter run. The number of digits is determined from the number of member fields in the harmonic fields set.
| index | The index of the mode. It is converted to two indices (wavelength and incoherent index) and then something like "Wavelength #1: 532 nm; Incoherent Mode #1" is returned. |
| omitWavelength | If this optional parameter is set to true the actual wavelength is not written to the mode string (only the wavelength index). This is necessary for e.g. the Parameter Run as then the wavelength might change with every iteration. |
| string ModeString | ( | int | indexWavelength, |
| int | indexIncoherentMode, | ||
| bool | omitWavelength = false |
||
| ) |
Generates a human-readable string describing the specified mode.
| indexWavelength | The wavelength index of the mode. |
| indexIncoherentMode | The index of the incoherent mode. |
| omitWavelength | If this optional parameter is set to true the actual wavelength is not written to the mode string (only the wavelength index). This is necessary for e.g. the Parameter Run as then the wavelength might change with every iteration. |
|
static |
Creates a string like "Field #1" to ensure the correct sorting in the parameter run. The number of digits is determined from the number of member fields in the harmonic fields set.
| index | The index of the mode. An index of 0 is converted to "Field #1", an index of 1 to "Field #2" and so on. |
|
static |
Generates a human-readable string describing the specified mode.
| indexWavelength | The wavelength index of the mode. |
| wavelength | The wavelength itself. |
| indexIncoherentMode | The index of the incoherent mode. |
| numberOfIncoherentModesForWavelength | The number of incoherent modes for the given wavelength. |
|
virtual |
remove the specified ca file with the given index from the file list stored in RAM /Hard Disk.
| index |
|
virtual |
Saves current HarmonicFieldsSet into a file in binary format.
| fileName | Complete path of file. |
Implements FieldRepresentationObject.
| void SetCoordinateForMember | ( | int | indexMember, |
| CartesianCoordinateSystem | csToSet | ||
| ) |
public support method which can be used to set the coordinate system for a specific member
| indexMember | the index of the member for which the coordinate system shall be set |
| csToSet | the coordinate system that shall be set |
| void SetSameCoordinateSystemToAllMembers | ( | CartesianCoordinateSystem | csToSet | ) |
public support method which set the coordinate system csToSet to all member of the harmonic fields set
| csToSet | the cartesian coordinate system which shall be set |
|
getset |
Gets and sets whether all member fields are in spatial domain (if true) or spectral domain (if false).
|
getset |
Advanced indexer for the harmonic fields set The indexer is two-dimensional. The first index value is the index of the wavelength which shall be investigated. The (sorted) list of wavelengths can be evaluated by the method GetSortedListOfWavelength(). The second index value is the indexer for the incoherent mode of the specified wavelength index. The number of incoherent modes for a specific wavelength can be investigated by the method GetNumberOfIncoherentModesPerWavelength(double wavelength). In case that the index which shall be investigated is not valid, an ArgumentException is thrown, which contains additional information.
| wavelengthIndex | The index value for the wavelength. |
| incoherentIndex | The index value for the incoherent mode. |