13 #include "Alignment/CocoaVisMgr/interface/ALIVRMLMgr.h"
14 #include "Alignment/IgCocoaFileWriter/interface/IgCocoaFileMgr.h"
15 #include "Alignment/IgCocoaFileWriter/interface/ALIVisLightPath.h"
36 std::vector<OpticalObject*>::const_iterator vocite =
OptOList().begin();
41 if ((*vocite)->type() !=
"Xlaser") {
42 std::cerr <<
"!!ERROR MeasurementCOPS: first Optical object should be 'Xlaser'" << std::endl;
49 std::cerr <<
"!!ERROR MeasurementCOPS: last Optical object should be 'COPS'" << std::endl;
55 ALIVisLightPath* vispath = 0;
59 vispath = IgCocoaFileMgr::getInstance().newLightPath(
name());
63 std::cout << (vocite ==
OptOList().end()) <<
" vocite " << (*vocite)->name() << std::endl;
66 std::cout << std::endl <<
"@@@@ LR:OBJECT " << (*vocite)->name() << std::endl;
73 (*vocite)->participateInMeasurement(*lightray, *
this, behav);
78 ALIVRMLMgr::getInstance().addLightPoint(lightray->
point());
82 vispath->addLightPoint(lightray->
point(), *vocite);
87 std::cerr <<
"!! Last object is not Sensor 2D in measurement " <<
name() << std::endl;
94 std::cerr <<
"ERROR DE PROGRAMACION EN GetSimulatedValue" << std::endl;
100 std::cout <<
"end calculateSimulatedValue" << std::endl;
113 for (ii = 0; ii <
dim(); ii++) {
118 if (wordlist.size() == 1)
122 std::cerr <<
"!! SensorCOPS Measurement setConversionFactor: WRONG FORMAT " << std::endl
123 <<
"It should be: SENSOR2D displace_U displace_D displace_L displace_R " << std::endl
129 for (ii = 0; ii <
dim(); ii++) {
137 for (ii = 0; ii <
dim(); ii++) {
141 std::cout <<
"MeasurementCOPS::correctValueAndSigma: old value X " <<
value()[
ii] <<
" new " << val <<
" +- "
virtual const ALIdouble valueDimensionFactor() const
const ALIuint dim() const
void calculateSimulatedValue(ALIbool firstTime) override
void setValue(ALIint coor, ALIdouble val)
static GlobalOptionMgr * getInstance()
ALIstring getMeasuringBehaviour(const std::vector< OpticalObject * >::const_iterator vocite)
void correctValueAndSigma() override
static int IsNumber(const ALIstring &str)
const CLHEP::Hep3Vector & point() const
const std::vector< OpticalObject * > & OptOList() const
static ALIbool getFirstTime()
void setConversionFactor(const std::vector< ALIstring > &wordlist) override
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.