tardis.energy_input.gamma_ray_grid module

tardis.energy_input.gamma_ray_grid.calculate_distance_radial(photon, r_inner, r_outer)[source]

Calculates 3D distance to shell from gamma ray position

Parameters:
photonGXPhoton object
r_innerfloat
r_outerfloat
Returns:
distancefloat
tardis.energy_input.gamma_ray_grid.distance_trace(photon, inner_velocity, outer_velocity, total_opacity, current_time, next_time)[source]

Traces distance traveled by gamma ray and finds distance to next interaction and boundary

Parameters:
photonGXPhoton object
inner_velocityOne dimensional Numpy array, dtype float
outer_velocityOne dimensional Numpy array, dtype float
total_opacityfloat
current_timefloat
next_timefloat
Returns:
distance_interactionfloat
distance_boundaryfloat
distance_timefloat
shell_changeint
tardis.energy_input.gamma_ray_grid.move_packet(packet, distance)[source]

Moves packet a distance along its direction vector

Parameters:
packetGXPacket object
distancefloat
Returns:
packetGXPacket object