syned.beamline.shape.SphericalCylinder
- class syned.beamline.shape.SphericalCylinder(radius=1.0, convexity=0, cylinder_direction=0)[source]
Constructor.
- Parameters:
radius (float) – the radius of the circular section.
convexity (int (as defined by Convexity), optional) – NONE = -1, UPWARD = 0, DOWNWARD = 1.
cylinder_direction (int (as defined by Direction), optional) – NONE = -1, UPWARD = 0, DOWNWARD = 1.
Methods
__init__([radius, convexity, cylinder_direction])create_sphere_from_p_q([p, q, ...])Defines an spherical surface.
create_sphere_from_radius([radius, convexity])Defines an spherical surface.
create_spherical_cylinder_from_p_q([p, q, ...])- param p:
distance source-optical element.
Creates a spherical cylinder.
duplicate()Returns a copy of the SYNED object instance.
from_hex_tring(hex_string)get_convexity()Gets the convexity flag.
get_cylinder_direction()Returns the cylinder direction.
get_radius()Returns the radius of the sphere.
get_radius_from_p_q([p, q, grazing_angle])Calculates the radius of the sphere from factory parameters (1/p+1/q=2/(R sin theta_grazing)))
get_radius_from_p_q_sagittal([p, q, ...])Calculates the sagittal radius from the factory parameters (1/p + 1/q = 2 sin(grazing_angle)/Rs).
get_value_from_key_name(key)Gets a value using its key value.
info()Get text info of recurrent SYNED objects.
info_recurrent(fd[, prefix])Get text info of recurrent SYNED objects.
initialize_from_p_q([p, q, grazing_angle])Calculates and sets the radius of curvature in the corresponding direction (tangential or sagittal.
keys()Returns the keys of the supporting doctionary.
set_value_from_key_name(key, value)Sets a value using its key value.
to_dictionary()Returns a dictionary with the object fields.
to_full_dictionary()Returns a dictionary with the object fields, including other syned objects embedded or list of elements.
to_hex_tring()to_json([file_name])Writes a json file with the SYNED object data.