pysrw.lib.srwlib.SRWLOptA#
- class pysrw.lib.srwlib.SRWLOptA(_shape='r', _ap_or_ob='a', _Dx=0, _Dy=0, _x=0, _y=0)[source]#
Bases:
SRWLOpt
Optical Element: Aperture / Obstacle
- __init__(_shape='r', _ap_or_ob='a', _Dx=0, _Dy=0, _x=0, _y=0)[source]#
- Parameters:
_shape – ‘r’ for rectangular, ‘c’ for circular
_ap_or_ob – ‘a’ for aperture, ‘o’ for obstacle
_Dx – horizontal transverse dimension [m]; in case of circular aperture, only Dx is used for diameter
_Dy – vertical transverse dimension [m]; in case of circular aperture, Dy is ignored
_x – horizontal transverse coordinate of center [m]
_y – vertical transverse coordinate of center [m]
Methods
__init__
([_shape, _ap_or_ob, _Dx, _Dy, _x, _y])- param _shape:
'r' for rectangular, 'c' for circular
get_orient
([_e])randomize
()Randomizes parameters of optical element according to self.RandParam to simulate e.g. impact of vibrations on coherence (in P-C calculations).
set_rand_par
(_rand_par)Sets list of params to be eventually randomized in some types of calculations :param _rand_par: list of params to be randomized; each element of this list should be: ['param_name', val_avg, val_range, meth]