Changeset 1535 for trunk/MagicSoft/Simulation/Detector/ReflectorII/ph2cph.c
- Timestamp:
- 10/09/02 19:15:28 (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Simulation/Detector/ReflectorII/ph2cph.c
r1431 r1535 94 94 float sx, sy; 95 95 float t1, t2; 96 float dummy = 0.; 97 96 98 97 99 void makeOmega(float theta, float phi); … … 255 257 256 258 } else { 257 258 d = (float) sqrt( b*b - 4.0*a*c ); 259 259 260 /* Introduce positiveness check, AM 3/7/2002 */ 261 262 dummy = b*b - 4.0*a*c; 263 264 if (dummy < 0.) /* No intersection */ 265 return 2; 266 267 d = (float) sqrt(dummy); 268 260 269 /* two possible values for z */ 261 270 … … 276 285 xcut[0] = xCT[0] + rCT[0]/rCT[2]*(xcut[2]-xCT[2]); 277 286 xcut[1] = xCT[1] + rCT[1]/rCT[2]*(xcut[2]-xCT[2]); 287 278 288 279 289 /* CBC */ … … 285 295 sx = Lin2Curv( xcut[0] ); 286 296 sy = Lin2Curv( xcut[1] ); 287 297 288 298 /* CBC */ 289 299 Debug("@4 sx sy %f %f\n", sx, sy); … … 310 320 if (distmirr2 < distmirr) { 311 321 i_mirror = i; 312 distmirr = distmirr2;322 distmirr = distmirr2; 313 323 } 314 324 }
Note:
See TracChangeset
for help on using the changeset viewer.