![]() |
AmpTools
|
#include <ComplexParameter.h>
Public Member Functions | |
ComplexParameter (const string &name, MinuitMinimizationManager &aManager, complex< double > initialValue=complex< double >(1, 0), bool purelyReal=false) | |
~ComplexParameter () | |
void | update (const MISubject *callingSubject) |
void | setValue (complex< double > value) |
void | fix () |
void | free () |
const string & | name () const |
string | realName () const |
string | imagName () const |
bool | isPurelyReal () const |
bool | isFixed () const |
complex< double > | value () const |
const complex< double > * | constValuePtr () const |
complex< double > * | valuePtr () |
![]() | |
MIObserver () | |
virtual | ~MIObserver () |
This class manages the conversion of complex parameters to real parameters that minuit minimizes.
If a valid MinuitMinimizationManager reference is passed in it it registers two parameters with MinuitParameterManager when created. It is an also MIObserver – on update calls it maintains a complex< double > that represents the value of the parameter.
It is also useful to be able to create ComplexParameter objects with no connection to MinuitMinimizationManager in MPI implementations of the fitter. These objects are valid, but are not registered to or updated by the minimization manager.
Definition at line 68 of file ComplexParameter.h.
ComplexParameter::ComplexParameter | ( | const string & | name, |
MinuitMinimizationManager & | aManager, | ||
complex< double > | initialValue = complex< double >( 1, 0 ) , |
||
bool | purelyReal = false |
||
) |
This constructs the ComplexParameter.
[in] | name | the string giving the name of the parameter, real and imaginary parts of the parameter will be identified in MINUIT with this string plus "_re" or "_im" appened. |
[in] | aManager | an instance of the MinuitMinimizationManager with which to create and register the parameters |
[in] | initialValue | an optional initial value |
[in] | purelyReal | an optional argument that when set true forces the imaginary part of the complex number to zero |
Definition at line 46 of file ComplexParameter.cc.
ComplexParameter::~ComplexParameter | ( | ) |
This is the ComplexParameter destructor.
Definition at line 78 of file ComplexParameter.cc.
|
inline |
A function that returns a const pointer to the value of the parameter. This is useful, for example, when telling the AmplitudeManager to use an external parameter for a production amplitude.
Definition at line 167 of file ComplexParameter.h.
void ComplexParameter::fix | ( | ) |
This fixes the parameter at its current value.
Definition at line 114 of file ComplexParameter.cc.
void ComplexParameter::free | ( | ) |
This allows the parameter to float.
Definition at line 121 of file ComplexParameter.cc.
|
inline |
A function that returns the name of the parameter representing the imaginary part of the complex number.
Definition at line 142 of file ComplexParameter.h.
bool ComplexParameter::isFixed | ( | ) | const |
A function to see if the parameter is floating.
Definition at line 128 of file ComplexParameter.cc.
|
inline |
A function that returns a boolean indicating whether the parameter is purely real or not.
Definition at line 148 of file ComplexParameter.h.
|
inline |
A function that returns the name of the ComplexParameter
Definition at line 130 of file ComplexParameter.h.
|
inline |
A function that returns the name of the parameter representing the real part of the complex number.
Definition at line 136 of file ComplexParameter.h.
void ComplexParameter::setValue | ( | complex< double > | value | ) |
This sets the value of the parameter.
[in] | value | the desired value of the complex parameter |
Definition at line 103 of file ComplexParameter.cc.
|
virtual |
This is called by the MinuitInterface and triggers the updating of the values of the real and imaginary parts of the complex parameter.
[in] | callingSubject | pointer to the MinuitParameter representing either the real or imaginary part of the value |
Implements MIObserver.
Definition at line 90 of file ComplexParameter.cc.
|
inline |
A function that returns the current value of the complex parameter.
Definition at line 158 of file ComplexParameter.h.
|
inline |
A function that returns a pointer (not const) to the value of the parameter.
Definition at line 173 of file ComplexParameter.h.