CircularMeshGrid

class marxs.design.rowland.CircularMeshGrid(**kwargs)[source] [edit on github]

Bases: ElementsOnTorus

A collection of diffraction gratings on the Rowland torus filling a circle.

When initialized, it places elements in the space available on the Rowland circle, most commonly, this class is used to place grating facets.

After generation, individual facet positions can be adjusted by hand by editing the attributes elem_pos or elem_uncertainty. See marxs.simulation.Parallel for details.

After any of the elem_pos, elem_uncertainty or uncertainty is changed, generate_elements needs to be called to regenerate the facets on the GAS.

Parameters:
radiuslist of two floats

Inner and outer radius of the circle.

Define a new MARXS element.

Methods Summary

elemposyz()

Specify the element position in the yz plane

Methods Documentation

elemposyz()[source] [edit on github]

Specify the element position in the yz plane

For the torus, the Rowland circle lies in the xy plane and the symmetry axis of the torus is the y-axis. In this class, the position of the elements is specified in the yz plane in the coordinates of the torus and the remaining coordinate.

This function will be customized by derived classes.

Returns:
ypos, zposnp.array

1D arrays of y and z positions for the elements distributed in 2D.