24 cout <<
"ERROR: RectangularCylindricalMFGrid: unexpected orientation: x: " 25 << localXDir <<
" y: " << localYDir << endl;
29 inFile >> n1 >> n2 >> n3;
30 double xref, yref, zref;
31 inFile >> xref >> yref >> zref;
32 double stepx, stepy, stepz;
33 inFile >> stepx >> stepy >> stepz;
35 vector<BVector> fieldValues;
37 int nLines = n1*n2*n3;
38 fieldValues.reserve(nLines);
39 for (
int iLine=0; iLine<nLines; ++iLine){
40 inFile >> Bx >> By >> Bz;
41 fieldValues.push_back(
BVector(Bx,By,Bz));
46 if (lastEntry !=
"complete"){
47 cout <<
"ERROR during file reading: file is not complete" << endl;
54 cout <<
"Grid reference point in grid system: " << xref <<
"," << yref <<
"," << zref << endl;
55 cout <<
"Grid reference point in global x,y,z: " << grefp << endl;
56 cout <<
"Grid reference point in local x,y,z: " << lrefp << endl;
57 cout <<
"steps " << stepx <<
"," << stepy <<
"," << stepz << endl;
60 Grid1D gridX( lrefp.perp(), lrefp.perp() + stepx*(n1-1), n1);
62 Grid1D gridY( yref, yref + stepy*(n2-1), n2);
63 Grid1D gridZ( lrefp.z(), lrefp.z() + stepz*(n3-1), n3);
71 cout << endl <<
"Dump of RectangularCylindricalMFGrid" << endl;
72 cout <<
"Number of points from Grid1D " 75 cout <<
"Reference Point from Grid1D " 78 cout <<
"Basic Distance from Grid1D " 82 cout <<
"Dumping " <<
grid_.
data().size() <<
" field values " << endl;
88 const float minimalSignificantR = 1
e-6;
90 if (R < minimalSignificantR) {
107 double&
a,
double&
b,
double&
c)
const
const Grid1D & grida() const
virtual void toGridFrame(const LocalPoint &p, double &a, double &b, double &c) const
find grid coordinates for point. For debugging and validation only.
GloballyPositioned< float >::GlobalVector GlobalVector
GloballyPositioned< float >::LocalPoint LocalPoint
ReturnType interpolate(Scalar a, Scalar b, Scalar c)
LocalPoint toLocal(const GlobalPoint &gp) const
const Grid1D & gridc() const
virtual void dump() const
const Container & data() const
GloballyPositioned< float >::GlobalPoint GlobalPoint
virtual LocalPoint fromGridFrame(double a, double b, double c) const
find grid coordinates for point. For debugging and validation only.
GloballyPositioned< float >::LocalVector LocalVector
const GloballyPositioned< float > & frame() const
Local reference frame.
RectangularCylindricalMFGrid(binary_ifstream &istr, const GloballyPositioned< float > &vol)
virtual LocalVector uncheckedValueInTesla(const LocalPoint &p) const
Interpolated field value at given point; does not check for exceptions.
int index(Scalar a, Scalar &f) const
const Grid1D & gridb() const