cherab.nagdis.inversion.raytransfer.create_raytransfer_cylinderΒΆ

cherab.nagdis.inversion.raytransfer.create_raytransfer_cylinder(parent: _NodeBase, radius: float = 0.04, z_max: float = 0.66, z_min: float = -0.5, dr: float = 0.0015, dp: float = 2.0, dz: float = 0.02, step: float | None = None) RayTransferCylinderSourceΒΆ

Create a RayTransferCylinder object with the given parameters.

The z axis is aligned with the linear device magnetic axis.

Parameters:
parent: _NodeBaseΒΆ

Parent node of the RayTransferCylinder object.

radius: float = 0.04ΒΆ

Radius of the cylinder, by default 40.0 mm.

z_max: float = 0.66ΒΆ

Maximum z-coordinate of the cylinder, by default 0.66 m.

z_min: float = -0.5ΒΆ

Minimum z-coordinate of the cylinder, by default -0.5 m.

dr: float = 0.0015ΒΆ

Radial step size, by default 1.5 mm.

dp: float = 2.0ΒΆ

Polar step size, by default 2.0 degree.

dz: float = 0.02ΒΆ

Axial step size, by default 20 mm.

step: float | None = NoneΒΆ

Step size for the ray-transfer calculation, by default None. If None, the step size is set to 10% of the minimum of dr, dz, and dr * dp.

Returns:

RayTransferCylinder – RayTransferCylinder object.

Raises:
  • TypeError – If parent is not a scene-graph object.

  • ValueError – If radius, z_max, z_min, dr, dp, dz, or step are invalid.

Examples

>>> from raysect.optical import World
>>> from cherab.nagdis.inversion.raytransfer import create_raytransfer_cylinder
>>> world = World()
>>> cylinder = create_raytransfer_cylinder(world)