Store and handle lifetime spectra.
More...
#include <IMP/bff/DecayLifetimeHandler.h>
Store and handle lifetime spectra.
This is responsible for storing and handling lifetime spectra. A lifetime spectrum consists of a set of lifetimes and their corresponding amplitudes. The class provides methods to set and retrieve the lifetime spectrum, as well as to manipulate it.
Definition at line 32 of file DecayLifetimeHandler.h.
IMP::bff::DecayLifetimeHandler::DecayLifetimeHandler |
( |
std::vector< double > |
lifetime_spectrum = std::vector< double >() , |
|
|
bool |
use_amplitude_threshold = false , |
|
|
bool |
abs_lifetime_spectrum = false , |
|
|
double |
amplitude_threshold = std::numeric_limits< double >::epsilon() |
|
) |
| |
Construct a DecayLifetimeHandler object.
- Parameters
-
lifetime_spectrum | The initial lifetime spectrum (default: empty). |
use_amplitude_threshold | Whether to use the amplitude threshold (default: false). |
abs_lifetime_spectrum | Whether to use the absolute values of the lifetime spectrum (default: false). |
amplitude_threshold | The amplitude threshold (default: epsilon). |
void IMP::bff::DecayLifetimeHandler::add_lifetime |
( |
double |
amplitude, |
|
|
double |
lifetime |
|
) |
| |
Add a lifetime to the lifetime spectrum.
- Parameters
-
amplitude | The amplitude of the lifetime. |
lifetime | The lifetime value. |
bool IMP::bff::DecayLifetimeHandler::get_abs_lifetime_spectrum |
( |
| ) |
const |
Check if the absolute values of the lifetime spectrum are being used to compute the model function.
- Returns
- True if the absolute values are being used, false otherwise.
double IMP::bff::DecayLifetimeHandler::get_amplitude_threshold |
( |
| ) |
|
Get the amplitude threshold used to discriminate lifetimes with small amplitudes.
- Returns
- The amplitude threshold.
std::vector<double>& IMP::bff::DecayLifetimeHandler::get_lifetime_spectrum |
( |
| ) |
|
Get a reference to the lifetime spectrum.
- Returns
- A reference to the lifetime spectrum.
void IMP::bff::DecayLifetimeHandler::get_lifetime_spectrum |
( |
double ** |
output_view, |
|
|
int * |
n_output |
|
) |
| |
Get a view of the lifetime spectrum.
- Parameters
-
output_view | A pointer to the output view of the lifetime spectrum. |
n_output | A pointer to the number of elements in the output view. |
bool IMP::bff::DecayLifetimeHandler::get_use_amplitude_threshold |
( |
| ) |
|
Check if the amplitude threshold is being used to discriminate lifetimes with small amplitudes.
- Returns
- True if the amplitude threshold is being used, false otherwise.
virtual ::IMP::VersionInfo IMP::bff::DecayLifetimeHandler::get_version_info |
( |
| ) |
const |
|
overridevirtual |
void IMP::bff::DecayLifetimeHandler::set_abs_lifetime_spectrum |
( |
bool |
v | ) |
|
Set whether to use the absolute values of the lifetime spectrum to compute the model function.
- Parameters
-
v | True to use the absolute values, false otherwise. |
void IMP::bff::DecayLifetimeHandler::set_amplitude_threshold |
( |
double |
v | ) |
|
Set the amplitude threshold used to discriminate lifetimes with small amplitudes.
- Parameters
-
v | The amplitude threshold. |
void IMP::bff::DecayLifetimeHandler::set_lifetime_spectrum |
( |
std::vector< double > |
v | ) |
|
Set the lifetime spectrum.
- Parameters
-
v | The lifetime spectrum to set. |
void IMP::bff::DecayLifetimeHandler::set_use_amplitude_threshold |
( |
bool |
v | ) |
|
Set whether to use the amplitude threshold to discriminate lifetimes with small amplitudes.
- Parameters
-
v | True to use the amplitude threshold, false otherwise. |
The documentation for this class was generated from the following file: