rl_raylib  1.1.10
rl_DielectricLayer Class Reference

A class encapsulating the multilayer reflection of a ray. More...

#include <rl_DielectricLayer.h>

Public Types

typedef rl_Traits::complex complex
 complex type
 
typedef rl_Traits::ERoughType ERoughType
 roughness type
 

Public Member Functions

 ~rl_DielectricLayer ()
 Destructor.
 
 rl_DielectricLayer (char const layer_name[]=0)
 Constructor. More...
 
 rl_DielectricLayer (rl_DielectricLayer const &other)
 DEEP Copy constructor. More...
 
 rl_DielectricLayer (rl_Traits::rl_DielectricPOD const *diel, std::size_t ndielpts, double layer_thickness, double roughness, rl_Traits::ERoughType roughness_type, rl_Traits::EInterpMode interp_mode, double bulkdensity, char const *layer_name, rl_Traits::Bool is_substrate=rl_Traits::False)
 Constructor. More...
 
void init (rl_Traits::rl_DielectricPOD const *diel, std::size_t ndielpts, double layer_thickness, double roughness, rl_Traits::ERoughType roughness_type, rl_Traits::EInterpMode interp_mode, double bulkdensity, char const *layer_name, rl_Traits::Bool is_substrate=rl_Traits::False)
 Initializer. More...
 
int setup_for (double energy, double sinphi)
 Set up layer state for given energy and graze angle. More...
 
void reflect_nlayer (rl_DielectricLayer layer[], int num)
 Compute reflectivity for a stack of num layers. More...
 
void reflect_amp (rl_DielectricLayer const &layer, double sinphi)
 Compute reflection amplitude for the interface between this layer and the layer immediately above it. More...
 
complex const & propagator () const
 The propagator for this layer. More...
 
double alpha () const
 Returns this layer's dielectric decrement (real part). More...
 
double gamma () const
 Returns this layer's dielectric decrement (imag part). More...
 
double roughness () const
 Returns the roughness parameter of the upper surface of this layer. More...
 
ERoughType roughness_type () const
 Returns the roughness type of the upper surface of this layer. More...
 
rl_ReflectionCoefPOD const & reflection_coef () const
 Returns this layer's complex reflection coefficient. More...
 
double reflectivity (double polarization_factor=0.0) const
 Returns: this layer's reflectivity. More...
 
rl_Traits::Bool is_substrate () const
 
rl_Traits::Bool is_vacuum () const
 
char const * layer_name () const
 
double energy_min () const
 
double energy_max () const
 
double thickness () const
 
double zcoat () const
 
double bulk_density_factor () const
 
std::ostream & dump_on (std::ostream &os, char const pre[]="", char const pst[]="") const
 Dumps layer information to a stream. More...
 
void cdump_on (std::FILE *of, char const pre[]="", char const pst[]="") const
 Dumps layer information to a C-style FILE* stream. More...
 
void cprint_constraints_on (std::FILE *of, char const pre[]="", char const pst[]="") const
 Dumps layer information and constraints to a C-style FILE* stream. More...
 

Detailed Description

A class encapsulating the multilayer reflection of a ray.

Given the energy and the sine of the graze angle, the reflection coefficient is evaluated.

Definition at line 60 of file rl_DielectricLayer.h.

Constructor & Destructor Documentation

◆ rl_DielectricLayer() [1/3]

rl_DielectricLayer::rl_DielectricLayer ( char const  layer_name[] = 0)

Constructor.

By default, constructs a VACUUM layer. Use init method to initialize for conditions other than vacuum.

Parameters
layer_nameoptional string naming the layer.

Definition at line 56 of file rl_DielectricLayer.cc.

◆ rl_DielectricLayer() [2/3]

rl_DielectricLayer::rl_DielectricLayer ( rl_DielectricLayer const &  other)

DEEP Copy constructor.

Parameters
otherrl_DielectricLayer to be copied.

Definition at line 98 of file rl_DielectricLayer.cc.

◆ rl_DielectricLayer() [3/3]

rl_DielectricLayer::rl_DielectricLayer ( rl_Traits::rl_DielectricPOD const *  diel,
std::size_t  ndielpts,
double  layer_thickness,
double  roughness,
rl_Traits::ERoughType  roughness_type,
rl_Traits::EInterpMode  interp_mode,
double  bulkdensity,
char const *  layer_name,
rl_Traits::Bool  is_substrate = rl_Traits::False 
)

Constructor.

Parameters
dielarray of dielectric decrement information.
ndielptsnumber of points in diel array.
layer_thicknesslayer thickness (Angstroms).
roughnesslayer roughness'' (Angstroms). @param roughness_type interlayer gradingroughness'' type.
interp_modetype of optical constant interpolation to be done.
bulkdensityrelative bulk density factor; 1 for full bulk density.
layer_namestring describing the layer composition.
is_substrateboolean: True if this is the substrate layer.

Definition at line 140 of file rl_DielectricLayer.cc.

Member Function Documentation

◆ alpha()

double rl_DielectricLayer::alpha ( ) const
inline

Returns this layer's dielectric decrement (real part).

Returns
this layer's dielectric decrement (real part).

Definition at line 524 of file rl_DielectricLayer.h.

◆ bulk_density_factor()

double rl_DielectricLayer::bulk_density_factor ( ) const
inline
Returns
the relative bulk density for this layer. 1.0 is nominal full bulk density

Definition at line 576 of file rl_DielectricLayer.h.

◆ cdump_on()

void rl_DielectricLayer::cdump_on ( std::FILE *  of,
char const  pre[] = "",
char const  pst[] = "" 
) const

Dumps layer information to a C-style FILE* stream.

Parameters
ofoutput file.
preoptional prefix string.
pstoptional postfix string.

Definition at line 832 of file rl_DielectricLayer.cc.

◆ cprint_constraints_on()

void rl_DielectricLayer::cprint_constraints_on ( std::FILE *  of,
char const  pre[] = "",
char const  pst[] = "" 
) const

Dumps layer information and constraints to a C-style FILE* stream.

Parameters
ofoutput file.
preoptional prefix string.
pstoptional postfix string.

Definition at line 876 of file rl_DielectricLayer.cc.

◆ dump_on()

std::ostream & rl_DielectricLayer::dump_on ( std::ostream &  os,
char const  pre[] = "",
char const  pst[] = "" 
) const

Dumps layer information to a stream.

Parameters
osstream.
preoptional prefix string.
pstoptional postfix string.

Definition at line 787 of file rl_DielectricLayer.cc.

◆ energy_max()

double rl_DielectricLayer::energy_max ( ) const
inline
Returns
the maximum energy allowed for this layer.

Definition at line 572 of file rl_DielectricLayer.h.

◆ energy_min()

double rl_DielectricLayer::energy_min ( ) const
inline
Returns
the minimum energy allowed for this layer.

Definition at line 568 of file rl_DielectricLayer.h.

◆ gamma()

double rl_DielectricLayer::gamma ( ) const
inline

Returns this layer's dielectric decrement (imag part).

Returns
this layer's dielectric decrement (imag part).

Definition at line 528 of file rl_DielectricLayer.h.

◆ init()

void rl_DielectricLayer::init ( rl_Traits::rl_DielectricPOD const *  diel,
std::size_t  ndielpts,
double  layer_thickness,
double  roughness,
rl_Traits::ERoughType  roughness_type,
rl_Traits::EInterpMode  interp_mode,
double  bulkdensity,
char const *  layer_name,
rl_Traits::Bool  is_substrate = rl_Traits::False 
)

Initializer.

Parameters
dielarray of dielectric decrement information.
ndielptsnumber of points in diel array.
layer_thicknesslayer thickness (Angstroms).
roughnessinterlayer grading "roughness" (Angstrom).
roughness_typeinterlayer grading "roughness" type.
interp_modetype of optical constant interpolation to be done.
bulkdensityrelative bulk density factor; 1 for full bulk density.
layer_namestring describing the layer composition.
is_substrateboolean: True if this is the substrate layer.

Definition at line 157 of file rl_DielectricLayer.cc.

◆ is_substrate()

rl_Traits::Bool rl_DielectricLayer::is_substrate ( ) const
inline
Returns
rl_Traits::True if this layer is the substrate, rl_Traits::False otherwise.

Definition at line 556 of file rl_DielectricLayer.h.

◆ is_vacuum()

rl_Traits::Bool rl_DielectricLayer::is_vacuum ( ) const
inline
Returns
rl_Traits::True if this layer is the vacuum, rl_Traits::False otherwise.

Definition at line 560 of file rl_DielectricLayer.h.

◆ layer_name()

char const * rl_DielectricLayer::layer_name ( ) const
inline
Returns
the name of this layer as a character string.

Definition at line 564 of file rl_DielectricLayer.h.

◆ propagator()

rl_Traits::complex const & rl_DielectricLayer::propagator ( ) const
inline

The propagator for this layer.

Returns
propagator for this layer.

Definition at line 520 of file rl_DielectricLayer.h.

◆ reflect_amp()

void rl_DielectricLayer::reflect_amp ( rl_DielectricLayer const &  layer,
double  sinphi 
)

Compute reflection amplitude for the interface between this layer and the layer immediately above it.

sinphi is the graze angle at the topmost layer (i.e., in vacuum). Layer "layer" is assumed to be adjacent to this layer, with "layer" nearer the vacuum and this layer nearer the substrate. The reflection coefficient for this layer is updated.

PRECONDITION: The layers must be pre-initialized with setup_for

Parameters
layeradjacent layer above this layer, where above means closer to the vacuum.
sinphisine of the graze angle between the ray (in vacuum) and the top surface of the multilayer.

Definition at line 320 of file rl_DielectricLayer.cc.

◆ reflect_nlayer()

void rl_DielectricLayer::reflect_nlayer ( rl_DielectricLayer  layer[],
int  num 
)

Compute reflectivity for a stack of num layers.

PRECONDITION: The layers must be pre-initialized with setup_for and the reflection coefficients evaluated with reflect_amp.

Parameters
layerarray of layers.
numnumber of layers in the array.

Definition at line 516 of file rl_DielectricLayer.cc.

◆ reflection_coef()

rl_ReflectionCoefPOD const & rl_DielectricLayer::reflection_coef ( ) const
inline

Returns this layer's complex reflection coefficient.

Returns
this layer's complex reflection coefficient.

Definition at line 548 of file rl_DielectricLayer.h.

◆ reflectivity()

double rl_DielectricLayer::reflectivity ( double  polarization_factor = 0.0) const
inline

Returns: this layer's reflectivity.

Parameters
polarization_factor- polarization factor; it must be a value between -1 and 1.

The polarization factor is related to parallel (p) and perpendicular (s) polarization by: polarization_factor $ = (I_\mathit{perp} - I_\mathit{para}) / (I_\mathit{perp} + I_\mathit{para})$ or polarization_factor $ = (I_\mathit{s} - I_\mathit{p}) / (I_\mathit{s} + I_\mathit{p})$ where $I_\mathit{perp} and I_\mathit{para}$ are the perpendicular and parallel E-field intensities, respectively. Thus,

  • -1: pure parallel (p) polarization.
  • 0: completely unpolarized.
  • +1: pure perpendicular (s) polarization.
Returns
this layer's reflectivity

Definition at line 552 of file rl_DielectricLayer.h.

◆ roughness()

double rl_DielectricLayer::roughness ( ) const
inline

Returns the roughness parameter of the upper surface of this layer.

Returns
the roughness parameter of the upper surface of this layer.

Definition at line 544 of file rl_DielectricLayer.h.

◆ roughness_type()

rl_Traits::ERoughType rl_DielectricLayer::roughness_type ( ) const
inline

Returns the roughness type of the upper surface of this layer.

Returns
the roughness type of the upper surface of this layer.

Definition at line 540 of file rl_DielectricLayer.h.

◆ setup_for()

int rl_DielectricLayer::setup_for ( double  energy,
double  sinphi 
)

Set up layer state for given energy and graze angle.

Parameters
energyenergy (keV).
sinphisine of the graze angle between the ray (in vacuum) and the top surface of the multilayer.

Definition at line 220 of file rl_DielectricLayer.cc.

◆ thickness()

double rl_DielectricLayer::thickness ( ) const
inline
Returns
the layer thickness.

Definition at line 532 of file rl_DielectricLayer.h.

◆ zcoat()

double rl_DielectricLayer::zcoat ( ) const
inline
Returns
the layer dimensionless thickness.

Definition at line 536 of file rl_DielectricLayer.h.


The documentation for this class was generated from the following files: