Changeset 2464 for branches/hpc33
- Timestamp:
- 04/13/12 12:57:18 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/hpc33/src/STGrid.cpp
- Property svn:mergeinfo changed
/trunk/src/STGrid.cpp merged: 2461
r2459 r2464 1058 1058 center_(0) = xcen.getValue( "rad" ) ; 1059 1059 center_(1) = ycen.getValue( "rad" ) ; 1060 } 1060 double base = 0.5 * (xmin + xmax) ; 1061 int maxrotate = 1 ; 1062 int nelem = 2 * maxrotate + 1 ; 1063 double *sep = new double[nelem] ; 1064 for ( int i = 0 ; i < nelem ; i++ ) 1065 sep[i] = abs(base - center_[0] - (i-maxrotate) * C::_2pi) ; 1066 // os << "sep[0]=" << sep[0] << endl 1067 // << "sep[1]=" << sep[1] << endl 1068 // << "sep[2]=" << sep[2] << LogIO::POST ; 1069 int idx = 0 ; 1070 base = sep[0] ; 1071 int nrotate = 0 ; 1072 while ( idx < nelem ) { 1073 if ( base > sep[idx] ) { 1074 base = sep[idx] ; 1075 nrotate = idx ; 1076 } 1077 idx++ ; 1078 } 1079 delete sep ; 1080 nrotate -= maxrotate ; 1081 // os << "nrotate = " << nrotate << LogIO::POST ; 1082 center_[0] += nrotate * C::_2pi ; 1083 } 1084 // os << "xmin=" << xmin << LogIO::POST ; 1085 // os << "center_=" << center_ << LogIO::POST ; 1061 1086 1062 1087 - Property svn:mergeinfo changed
Note:
See TracChangeset
for help on using the changeset viewer.