SimpleGeometry

This class represents a basic unbounded geometry, composed of a single material and extending infinitely. It is intended solely for testing purposes. For practical geometry implementations, please refer instead to the ExternalGeometry and StratifiedGeometry classes.

Constructor

class SimpleGeometry(material, density)

Generates a Monte Carlo geometry consisting of a single sector with the specified material and density. The argument for the material must be consistent with a MaterialDefinition. The density can be specified as a float, indicating a uniform density value (in g/cm3), or as a DensityGradient object. For instance,

>>> geometry = goupil.SimpleGeometry("H2O", 1.0)

Attributes

SimpleGeometry.density: DensityGradient | float

The medium density model. This attribute is mutable. For instance,

>>> geometry.density = 1.025 # g/cm^3
SimpleGeometry.material: MaterialDefinition

The material that makes up the propagation medium. This attribute is not mutable.

>>> geometry.material
H2O