PLaSK library
|
#include <solvers/optical/modal/expansion.hpp>
Public Types | |
enum | Component { E_UNSPECIFIED = 0 , E_TRAN = 1 , E_LONG = 2 } |
Specified component in polarization or symmetry. More... | |
Public Member Functions | |
Expansion (ModalBase *solver) | |
virtual | ~Expansion () |
TempMatrix | getTempMatrix () |
virtual void | beforeGetEpsilon () |
Prepare retrieval of refractive index. | |
virtual void | afterGetEpsilon () |
Finish retrieval of refractive index. | |
double | getLam0 () const |
Get lam0. | |
void | setLam0 (double lam) |
Set lam0. | |
void | clearLam0 () |
Clear lam0. | |
dcomplex | getK0 () const |
Get current k0. | |
void | setK0 (dcomplex k) |
Set current k0. | |
void | computeIntegrals () |
Compute all expansion coefficients. | |
virtual bool | diagonalQE (size_t PLASK_UNUSED(l)) const |
Tell if matrix for i-th layer is diagonal. | |
virtual size_t | matrixSize () const =0 |
Return size of the expansion matrix (equal to the number of expansion coefficients) | |
virtual void | getMatrices (size_t layer, cmatrix &RE, cmatrix &RH)=0 |
Get RE anf RH matrices. | |
virtual LazyData< Tensor3< dcomplex > > | getMaterialEps (size_t lay, const shared_ptr< const typename LevelsAdapter::Level > &level, InterpolationMethod interp)=0 |
Get epsilons index back from expansion. | |
virtual void | getDiagonalEigenvectors (cmatrix &Te, cmatrix &Te1, const cmatrix &RE, const cdiagonal &gamma) |
Get eigenvectors with some physical meaning when the layer is diagonal. | |
void | initField (WhichField which, InterpolationMethod method) |
Prepare for computations of the fields. | |
virtual double | integrateField (WhichField field, size_t layer, const cmatrix &TE, const cmatrix &TH, const std::function< std::pair< dcomplex, dcomplex >(size_t, size_t)> &vertical)=0 |
Compute ½ En·conj(Em) or ½ Hn·conj(Hm) | |
virtual double | integratePoyntingVert (const cvector &E, const cvector &H)=0 |
Compute vertical component of the Poynting vector for specified fields. | |
double | getModeFlux (size_t n, const cmatrix &TE, const cmatrix &TH) |
Compute vertical component of the Poynting vector for fields specified as matrix column. | |
virtual void | cleanupField () |
Cleanup after computatiations of the fields. | |
virtual LazyData< Vec< 3, dcomplex > > | getField (size_t l, const shared_ptr< const typename LevelsAdapter::Level > &level, const cvector &E, const cvector &H)=0 |
Compute electric or magnetic field on dst_mesh at certain level. | |
Public Attributes | |
WhichField | which_field |
InterpolationMethod | field_interpolation |
ModalBase * | solver |
Solver which performs calculations (and is the interface to the outside world) | |
dcomplex | k0 |
Frequency for which the actual computations are performed. | |
double | lam0 |
Material parameters wavelength. | |
LazyData< double > | temperature |
Obtained temperature. | |
bool | gain_connected |
Flag indicating if the gain is connected. | |
bool | epsilon_connected |
Flag indicating if inEpsilon is connected. | |
LazyData< Tensor2< double > > | gain |
Obtained gain. | |
LazyData< Tensor3< dcomplex > > | epsilons |
Obtained epsilons. | |
LazyData< double > | carriers |
Carriers concentration. | |
Protected Member Functions | |
virtual void | beforeLayersIntegrals (dcomplex PLASK_UNUSED(lam), dcomplex PLASK_UNUSED(glam)) |
Method called before layer integrals are computed. | |
virtual void | afterLayersIntegrals () |
Method called after layer integrals are computed. | |
virtual void | layerIntegrals (size_t layer, double lam, double glam)=0 |
Compute integrals for RE and RH matrices. | |
virtual void | prepareField () |
Prepare for computatiations of the fields. | |
Protected Attributes | |
TempMatrixPool | temporary |
Definition at line 30 of file expansion.hpp.
Specified component in polarization or symmetry.
Definition at line 33 of file expansion.hpp.
|
inline |
Definition at line 69 of file expansion.hpp.
|
inlinevirtual |
Definition at line 71 of file expansion.hpp.
Finish retrieval of refractive index.
Reimplemented in plask::optical::modal::ExpansionBessel.
Definition at line 115 of file expansion.hpp.
Method called after layer integrals are computed.
Definition at line 93 of file expansion.hpp.
Prepare retrieval of refractive index.
Reimplemented in plask::optical::modal::ExpansionBessel.
Definition at line 110 of file expansion.hpp.
|
inlineprotectedvirtual |
Method called before layer integrals are computed.
Definition at line 88 of file expansion.hpp.
Cleanup after computatiations of the fields.
Reimplemented in plask::optical::modal::ExpansionBessel, plask::optical::modal::ExpansionPW2D, and plask::optical::modal::ExpansionPW3D.
Definition at line 296 of file expansion.hpp.
|
inline |
Clear lam0.
Definition at line 128 of file expansion.hpp.
|
inline |
Compute all expansion coefficients.
Definition at line 149 of file expansion.hpp.
|
inlinevirtual |
Tell if matrix for i-th layer is diagonal.
l | layer number |
true
if the i-th matrix is diagonal Definition at line 208 of file expansion.hpp.
|
virtual |
Get eigenvectors with some physical meaning when the layer is diagonal.
[out] | Te | Resulting Te matrix |
[out] | Te1 | Resulting Te^1 matrix |
RE | RE matrix for the layer | |
gamma2 | gamma matrix for the layer |
Reimplemented in plask::optical::modal::ExpansionPW2D, and plask::optical::modal::ExpansionPW3D.
Definition at line 18 of file expansion.cpp.
|
pure virtual |
Compute electric or magnetic field on dst_mesh
at certain level.
l | layer number |
level | destination level |
E,H | electric and magnetic field coefficientscients |
dst_mesh
dst_mesh
Implemented in plask::optical::modal::ExpansionPW2D, plask::optical::modal::ExpansionPW3D, and plask::optical::modal::ExpansionBessel.
|
inline |
Get current k0.
Definition at line 137 of file expansion.hpp.
|
inline |
Get lam0.
Definition at line 118 of file expansion.hpp.
|
pure virtual |
Get epsilons index back from expansion.
lay | layer number |
mesh | mesh to get parameters to |
interp | interpolation method |
Implemented in plask::optical::modal::ExpansionPW2D, plask::optical::modal::ExpansionPW3D, and plask::optical::modal::ExpansionBessel.
|
pure virtual |
Get RE anf RH matrices.
layer | layer number | |
[out] | RE,RH | resulting matrix |
Implemented in plask::optical::modal::ExpansionPW2D, plask::optical::modal::ExpansionPW3D, plask::optical::modal::ExpansionBesselFini, and plask::optical::modal::ExpansionBesselInfini.
|
inline |
Compute vertical component of the Poynting vector for fields specified as matrix column.
n | column number |
TE | electric field coefficients matrix |
TH | magnetic field coefficients matrix |
Definition at line 279 of file expansion.hpp.
|
inline |
Definition at line 73 of file expansion.hpp.
|
inline |
Prepare for computations of the fields.
field | which field is computed |
method | interpolation method |
Definition at line 247 of file expansion.hpp.
|
pure virtual |
Compute ½ En·conj(Em) or ½ Hn·conj(Hm)
field | field to integrate | |
layer | layer number | |
TE | electric field coefficients matrix | |
TH | magnetic field coefficients matrix | |
[out] | result | ½ E·conj(E) or ½ H·conj(H) matrix |
Implemented in plask::optical::modal::ExpansionBessel, plask::optical::modal::ExpansionPW2D, and plask::optical::modal::ExpansionPW3D.
|
pure virtual |
Compute vertical component of the Poynting vector for specified fields.
E | electric field coefficients vector |
H | magnetic field coefficients vector |
Implemented in plask::optical::modal::ExpansionBessel, plask::optical::modal::ExpansionPW2D, and plask::optical::modal::ExpansionPW3D.
|
protectedpure virtual |
Compute integrals for RE and RH matrices.
layer | layer number |
lam | wavelength |
glam | wavelength for gain |
Implemented in plask::optical::modal::ExpansionBessel, plask::optical::modal::ExpansionPW2D, and plask::optical::modal::ExpansionPW3D.
|
pure virtual |
Return size of the expansion matrix (equal to the number of expansion coefficients)
Implemented in plask::optical::modal::ExpansionBessel, plask::optical::modal::ExpansionPW2D, and plask::optical::modal::ExpansionPW3D.
Prepare for computatiations of the fields.
Reimplemented in plask::optical::modal::ExpansionBessel, plask::optical::modal::ExpansionPW2D, and plask::optical::modal::ExpansionPW3D.
Definition at line 290 of file expansion.hpp.
|
inline |
Set current k0.
Definition at line 139 of file expansion.hpp.
Set lam0.
Definition at line 120 of file expansion.hpp.
Carriers concentration.
Definition at line 67 of file expansion.hpp.
bool plask::optical::modal::Expansion::epsilon_connected |
Flag indicating if inEpsilon is connected.
Definition at line 58 of file expansion.hpp.
Obtained epsilons.
Definition at line 64 of file expansion.hpp.
InterpolationMethod plask::optical::modal::Expansion::field_interpolation |
Definition at line 40 of file expansion.hpp.
Obtained gain.
Definition at line 61 of file expansion.hpp.
bool plask::optical::modal::Expansion::gain_connected |
Flag indicating if the gain is connected.
Definition at line 55 of file expansion.hpp.
dcomplex plask::optical::modal::Expansion::k0 |
Frequency for which the actual computations are performed.
Definition at line 46 of file expansion.hpp.
double plask::optical::modal::Expansion::lam0 |
Material parameters wavelength.
Definition at line 49 of file expansion.hpp.
ModalBase* plask::optical::modal::Expansion::solver |
Solver which performs calculations (and is the interface to the outside world)
Definition at line 43 of file expansion.hpp.
Obtained temperature.
Definition at line 52 of file expansion.hpp.
|
protected |
Definition at line 83 of file expansion.hpp.
WhichField plask::optical::modal::Expansion::which_field |
Definition at line 39 of file expansion.hpp.