Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members

Node Class Reference

#include <Node.h>

List of all members.

Public Types

enum  Type {
  Muon, OT, ST, TT,
  VeloR, VeloPhi
}
 enumerator for the type of Node (XxxNode) More...

Public Member Functions

 Node ()
 Default Constructor.
 ~Node ()
 specific destructor
double chi2 () const
 Retrieve the local chi2.
Measurementmeasurement ()
 Retrieve the reference to the measurement.
Measurementmeasurement () const
 Retrieve the reference to the measurement.
Statestate ()
 Retrieve the reference to the state.
Statestate () const
 Retrieve the reference to the state.
virtual Nodeclone () const
 Clone the Node.
void setMeasurement (const Measurement &meas)
 Update the measurement.
void setState (const State &state)
 Update the state.
void setType (const Type &value)
 Update node type.
bool checkType (const Type &value) const
 Check node type.
double residual () const
 Retrieve const the residual value.
void setResidual (double value)
 Update the residual value.
double errResidual () const
 Retrieve const the residual error.
void setErrResidual (double value)
 Update the residual error.
const HepMatrix & projectionMatrix () const
 Retrieve const the projection matrix.
HepMatrix & projectionMatrix ()
 Retrieve the projection matrix.
void setProjectionMatrix (const HepMatrix &value)
 Update the projection matrix.

Protected Types

enum  flagsBits { typeBits = 0 }
 Offsets of bitfield flags. More...
enum  flagsMasks { typeMask = 0x3FL }
 Bitmasks for bitfield flags. More...

Protected Attributes

unsigned int m_flags
 the variety of node types

Private Attributes

Measurementm_measurement
 pointer to the measurement
Statem_state
 pointer to the state
double m_residual
 the residual value
double m_errResidual
 the residual error
HepMatrix m_projectionMatrix
 the projection matrix


Detailed Description

Node is a base class for classes linking track states to measurements.

Author:
Jose Hernando, Eduardo Rodrigues created Sun Apr 3 18:33:24 2005

Definition at line 35 of file Node.h.


Member Enumeration Documentation

enum Node::flagsBits [protected]
 

Offsets of bitfield flags.

Enumeration values:
typeBits 

Definition at line 112 of file Node.h.

00112 {typeBits = 0};

enum Node::flagsMasks [protected]
 

Bitmasks for bitfield flags.

Enumeration values:
typeMask 

Definition at line 115 of file Node.h.

00115 {typeMask = 0x3FL};

enum Node::Type
 

enumerator for the type of Node (XxxNode)

Enumeration values:
Muon 
OT 
ST 
TT 
VeloR 
VeloPhi 

Definition at line 40 of file Node.h.

00040            { Muon,
00041              OT,
00042              ST,
00043              TT,
00044              VeloR,
00045              VeloPhi };


Constructor & Destructor Documentation

Node::Node  )  [inline]
 

Default Constructor.

Definition at line 48 of file Node.h.

References m_errResidual, m_flags, m_measurement, m_projectionMatrix, m_residual, and m_state.

Referenced by clone().

00048          : m_flags(0),
00049            m_measurement(),
00050            m_state(),
00051            m_residual(0.0),
00052            m_errResidual(0.0),
00053            m_projectionMatrix() {}

Node::~Node  )  [inline]
 

specific destructor

Definition at line 136 of file Node.h.

References m_measurement, and m_state.

00137 {
00138 
00139   delete m_measurement;
00140   delete m_state;
00141         
00142 }


Member Function Documentation

bool Node::checkType const Type value  )  const [inline]
 

Check node type.

Definition at line 151 of file Node.h.

References m_flags, typeBits, and typeMask.

00152 {
00153   unsigned int val = (unsigned int)value;
00154   return 0 != ( m_flags & typeMask & ( val << typeBits ));
00155 }

double Node::chi2  )  const [inline]
 

Retrieve the local chi2.

Definition at line 192 of file Node.h.

References m_errResidual, and m_residual.

00193 {
00194 
00195   return (m_errResidual >0 ? m_residual/m_errResidual: 0);
00196         
00197 }

Node * Node::clone  )  const [inline, virtual]
 

Clone the Node.

Definition at line 227 of file Node.h.

References Node().

00228 {
00229 
00230   Node* me = new Node(); *me = *this; return me;
00231         
00232 }

double Node::errResidual  )  const [inline]
 

Retrieve const the residual error.

Definition at line 167 of file Node.h.

References m_errResidual.

00168 {
00169   return m_errResidual;
00170 }

Measurement & Node::measurement  )  const [inline]
 

Retrieve the reference to the measurement.

Definition at line 206 of file Node.h.

References m_measurement.

00207 {
00208 
00209   return *m_measurement;
00210         
00211 }

Measurement & Node::measurement  )  [inline]
 

Retrieve the reference to the measurement.

Definition at line 199 of file Node.h.

References m_measurement.

00200 {
00201 
00202   return *m_measurement;
00203         
00204 }

HepMatrix & Node::projectionMatrix  )  [inline]
 

Retrieve the projection matrix.

Definition at line 182 of file Node.h.

References m_projectionMatrix.

00183 {
00184   return m_projectionMatrix;
00185 }

const HepMatrix & Node::projectionMatrix  )  const [inline]
 

Retrieve const the projection matrix.

Definition at line 177 of file Node.h.

References m_projectionMatrix.

00178 {
00179   return m_projectionMatrix;
00180 }

double Node::residual  )  const [inline]
 

Retrieve const the residual value.

Definition at line 157 of file Node.h.

References m_residual.

00158 {
00159   return m_residual;
00160 }

void Node::setErrResidual double  value  )  [inline]
 

Update the residual error.

Definition at line 172 of file Node.h.

References m_errResidual.

00173 {
00174   m_errResidual = value;
00175 }

void Node::setMeasurement const Measurement meas  )  [inline]
 

Update the measurement.

Definition at line 234 of file Node.h.

References Measurement::clone(), and m_measurement.

00235 {
00236 
00237   m_measurement = meas.clone();
00238         
00239 }

void Node::setProjectionMatrix const HepMatrix &  value  )  [inline]
 

Update the projection matrix.

Definition at line 187 of file Node.h.

References m_projectionMatrix.

00188 {
00189   m_projectionMatrix = value;
00190 }

void Node::setResidual double  value  )  [inline]
 

Update the residual value.

Definition at line 162 of file Node.h.

References m_residual.

00163 {
00164   m_residual = value;
00165 }

void Node::setState const State state  )  [inline]
 

Update the state.

Definition at line 241 of file Node.h.

References State::clone(), m_state, and state().

00242 {
00243 
00244   m_state = state.clone();
00245         
00246 }

void Node::setType const Type value  )  [inline]
 

Update node type.

Definition at line 144 of file Node.h.

References m_flags, typeBits, and typeMask.

00145 {
00146   unsigned int val = (unsigned int)value;
00147   m_flags &= ~typeMask;
00148   m_flags |= ((((unsigned int)val) << typeBits) & typeMask);
00149 }

State & Node::state  )  const [inline]
 

Retrieve the reference to the state.

Definition at line 220 of file Node.h.

References m_state.

00221 {
00222 
00223   return *m_state;
00224         
00225 }

State & Node::state  )  [inline]
 

Retrieve the reference to the state.

Definition at line 213 of file Node.h.

References m_state.

Referenced by setState().

00214 {
00215 
00216   return *m_state;
00217         
00218 }


Member Data Documentation

double Node::m_errResidual [private]
 

the residual error

Definition at line 125 of file Node.h.

Referenced by chi2(), errResidual(), Node(), and setErrResidual().

unsigned int Node::m_flags [protected]
 

the variety of node types

Definition at line 118 of file Node.h.

Referenced by checkType(), Node(), and setType().

Measurement* Node::m_measurement [private]
 

pointer to the measurement

Definition at line 122 of file Node.h.

Referenced by measurement(), Node(), setMeasurement(), and ~Node().

HepMatrix Node::m_projectionMatrix [private]
 

the projection matrix

Definition at line 126 of file Node.h.

Referenced by Node(), projectionMatrix(), and setProjectionMatrix().

double Node::m_residual [private]
 

the residual value

Definition at line 124 of file Node.h.

Referenced by chi2(), Node(), residual(), and setResidual().

State* Node::m_state [private]
 

pointer to the state

Definition at line 123 of file Node.h.

Referenced by Node(), setState(), state(), and ~Node().


The documentation for this class was generated from the following file:
Generated on Thu Apr 7 22:43:29 2005 for New Track Event Model by doxygen 1.4.1