tardis.spectrum.formal_integral.base module¶
- exception tardis.spectrum.formal_integral.base.BoundsError[source]¶
Bases:
IndexError
- tardis.spectrum.formal_integral.base.calculate_impact_parameters(radius_max, n_impact_parameters)[source]¶
Calculate n_impact_parameters impact parameters between 0 and radius_max
- Parameters:
- radius_maxfloat64
maximum radius
- n_impact_parametersint64
number of impact parameters
- Returns:
- float64
- tardis.spectrum.formal_integral.base.check_formal_integral_requirements(simulation_state, opacity_state, transport, raises=True)[source]¶
A method that determines if the formal integral can be performed with the current configuration settings
The function returns False if the configuration conflicts with the required settings. If raises evaluates to True, then a IntegrationError is raised instead
- Parameters:
- simulation_statetardis.model.SimulationState
State which holds information about each shell
- transport_solvertardis.transport.montecarlo.MonteCarloTransportSolver
The transport solver
- opacity_statetardis.opacities.opacity_state.OpacityState
Regular (non-numba) opacity state; will be converted to numba via
setup
- raisesbool, optional
flag to either raise an error or return False and issue a warning
- Returns:
- bool
True if the configuration is correct, False (or errors) otherwise