Description This subroutine gets the parameters from a volume hologram efficiency specification. Gratings have a primary and secondary efficiency specification that allows an accounting of which side of the grating a ray is incident from. This script command retrieves the secondary efficiency specification. For more information, refer to the gratings help topic.
Syntax GetDiffractEfficiencyVolHOESecondary grat, nAve, dN, a, dA, thick, order0, order1, wavl
Parameters grat As Long Node number of the surface whose grating efficiency specification is being retrieved.
nAve As Double Average refractive index of the emulsion.
dN As Double Amplitude variation of the refractive index.
a As Double Absorption coefficient of the material (system units-1).
dA As Double Amplitude variation of the absorption coefficient (system units-1).
thick As Double Hologram emulsion thickness (system units).
order0 As String Meaning of the 0th diffraction order. Options are:
order1 As String Meaning of the 1st diffraction order. Options are:
wavl As Double Mean wavelength (microns) at which the hologram was recorded.
Examples The example below demonstrates how to retrieve the volume hologram efficiency parameters from the secondary efficiency table, modify the refractive index amplitude variation and then set the updated parameters back to the secondary efficiency table.
Sub main
Dim grat As Long grat = FindFullName( "Geometry.Elem 1.Surf 2" )
Dim nAve As Double, dN As Double, a As Double, dA As Double, thick As Double Dim order1 As String, order2 As String Dim wavl As Double GetDiffractEfficiencyVolHOESecondary( grat, nAve, dN, a, dA, thick, order1, order2, wavl )
Print "Grating settings:" Print "Node: " & Chr(9) & GetFullName( grat ) Print "N avg: " & Chr(9) & nAve Print "delta N: " & Chr(9) & dN Print "Absorption: " & Chr(9) & a Print "delta A: " & Chr(9) & dA Print "Thickness: " & Chr(9) & thick Print "Order 1: " & Chr(9) & order1 Print "Order 2: " & Chr(9) & order2 Print "Wavl: " & Chr(9) & wavl
'Change dN dN = dN + 0.005 SetDiffractEfficiencyVolHOESecondary( grat, nAve, dN, a, dA, thick, order1, order2, wavl ) Update
End Sub
See Also Diffraction Grating Script Commands
|