TimeSegment

class TimeSegment(start, end, pulses)

Represents a time segment associated with a list of pulses.

A TimeSegment is a time interval that includes all pulses which are active throughout that interval. It is a read-only view that wraps a PulseList and provides additional metadata for plotting and simulation.

Initialize a time segment.

Parameters:
  • start – Start time of the segment.

  • end – End time of the segment.

  • pulses – Active pulses corresponding to the segment.

Methods

append(new_pulse)

Appending a pulse is disabled for TimeSegment instances.

discretize_plot(function)

Discretize the time segment for plotting.

discretize_simulation(...[, n_eval, ...])

Discretize the time segment for simulation.

signal([driving_field_name])

Return the combined signal for this time segment.

Attributes

duration

Duration of the time segment.

end

End time of the segment.

is_all_constant_envelope

Check if all pulses have a constant envelope.

max_frequency

Maximal frequency of the time segment's pulses.

n_nonzero_frequencies

Number of unique non-zero frequencies in the segment.

n_pulses

Number of pulses in the segment.

plot

Cached plotting data for this segment; None until prepared.

simulation

Cached discretized simulation data for this segment; None until prepared.

start

Start time of the segment.