Navigation: Scripting Reference Manual > Functions & Subroutines > SetIthPowerLawGRINMaterial

 

SetIthPowerLawGRINMaterial

 

Contact Us: fredsupport@photonengr.com

 

Description

This subroutine sets the wavelength, N1 and N2 values of the i'th sample in the table of a power-law GRIN material.

 

 

Syntax

SetIthPowerLawGrinMaterial(  matNode, ithSamp, wavl, n1, n2 )

 

 

Parameters

matNode As Long

Node number of the power-law grin material node being modified.

 

ithSamp As Long

Column-index (0-based) of the sample in the table that is being modified.  Samples are ordered by increasing wavelength so that the 0'th sample corresponds to the shortest wavelength.

 

wavl As Double

This parameter defines the wavelength (in microns) to which n1 and n2 correspond.

 

n1 As Double

This parameter is the on-axis refractive index value.

 

n2 As Double

This parameter is the cladding refractive index value.

 

 

Example

The example below demonstrates how to modify the 0'th sample of an existing power-law GRIN material.

 

Sub Main

    Dim matNode As Long

    matNode = FindMaterial( "Custom Power Law GRIN" )

    SetIthPowerLawGRINMaterial( matNode, 0, 0.5, 1.5, 1.49 )

    Update

 

End Sub

 

See Also

Materials Script Commands

 

 

 

 

 

Copyright © Photon Engineering, LLC