16 #include "Alignment/CocoaVisMgr/interface/ALIVRMLMgr.h"
17 #include "Alignment/IgCocoaFileWriter/interface/IgCocoaFileMgr.h"
18 #include "Alignment/IgCocoaFileWriter/interface/ALIVisLightPath.h"
30 std::vector<OpticalObject*>::const_iterator vocite =
OptOList().begin();
37 if ((*vocite)->type() ==
"distance_target" &&
38 ((*(vocite + 1))->type() ==
"distancemeter" || (*(vocite + 1))->type() ==
"distancemeter1dim")) {
43 std::cerr <<
"!!! ERROR in MeasurementDistancemeter: " <<
name()
44 <<
" There should only be two objects of type 'distance_target' and 'distancemeter' " << std::endl;
45 std::cerr <<
" 1st: " << (*vocite)->name() <<
" 2nd: " << (*vocite + 1)->
name() << std::endl;
46 std::cerr <<
" 1st " << (*vocite)->type() <<
" 2nd " << (*vocite + 1)->
type() << std::endl;
53 ALIVisLightPath* vispath = 0;
57 vispath = IgCocoaFileMgr::getInstance().newLightPath(
name());
65 std::cout << std::endl <<
"@@@@ LR:OBJECT " << (*vocite)->name() << std::endl;
73 (*vocite)->participateInMeasurement(lightray, *
this, behav);
79 ALIVRMLMgr::getInstance().addLightPoint(lightray.
point());
81 std::cout <<
"ALIVRMLMg addLightPoint " << lightray.
point() << (*vocite)->name() << std::endl;
84 vispath->addLightPoint(lightray.
point(), *vocite);
90 std::cerr <<
"ERROR DE PROGRAMACION EN GetSimulatedValue" << std::endl;
96 std::cout <<
"end calculateSimulatedValue" << std::endl;
106 if (wordlist.size() == 1)
110 std::cerr <<
"!! Distancemeter Measurement setConversionFactor: WRONG FORMAT " << std::endl
111 <<
"It should be: DISTANCEMETER factor +- error " << std::endl
122 }
else if (dimfac == 1) {
124 }
else if (dimfac == 2) {
128 <<
" !!!EXITING: error in global option distancemeter_meas_value_dimension, it can only take values 0,1,2, not "
142 std::cout <<
"MeasurementDistancemeter::correctValueAndSigma: old value" << val <<
" +- " << sig << std::endl;
149 std::cout <<
"MeasuremenDistancemeter::correctValueAndSigma: new value " << val <<
" +- " << sig << std::endl;
void setValue(ALIint coor, ALIdouble val)
static GlobalOptionMgr * getInstance()
ALIstring getMeasuringBehaviour(const std::vector< OpticalObject * >::const_iterator vocite)
void setSigma(ALIint coor, ALIdouble val)
void correctValueAndSigma() override
static int IsNumber(const ALIstring &str)
const ALIdouble * sigma() const
const CLHEP::Hep3Vector & point() const
void setConversionFactor(const std::vector< ALIstring > &wordlist) override
const std::vector< OpticalObject * > & OptOList() const
static ALIbool getFirstTime()
static void dumpVS(const std::vector< ALIstring > &wl, const std::string &msg, std::ostream &outs=std::cout)
dumps a vector of strings with a message to outs
std::map< ALIstring, ALIdouble, std::less< ALIstring > > & GlobalOptions()
const ALIdouble * value() const
const ALIstring & type() const
void printStartCalculateSimulatedValue(const Measurement *meas)
const ALIstring & name() const
tuple size
Write out results.
void calculateSimulatedValue(ALIbool firstTime) override