46 #ifndef __G4VTWISTEDFACETED__
47 #define __G4VTWISTEDFACETED__
95 const G4bool calcnorm =
false,
116 virtual std::ostream &
StreamInfo(std::ostream& os)
const;
163 void CreateSurfaces();
209 p.
set(kInfinity,kInfinity,kInfinity); inside =
kOutside;
212 LastState(
const LastState&
r) : p(r.p), inside(r.inside){}
215 if (
this == &r) {
return *
this; }
216 p = r.p; inside = r.inside;
229 p.
set(kInfinity,kInfinity,kInfinity);
230 vec.set(kInfinity,kInfinity,kInfinity);
237 LastVector(
const LastVector&
r) : p(r.p), vec(r.vec)
240 surface[0] = r.surface[0];
244 if (&r ==
this) {
return *
this; }
245 p = r.p; vec = r.vec;
247 surface[0] = r.surface[0];
261 p.
set(kInfinity,kInfinity,kInfinity);
265 LastValue(
const LastValue&
r) : p(r.p),
value(r.
value){}
268 if (
this == &r) {
return *
this; }
269 p = r.p;
value = r.value;
277 class LastValueWithDoubleVector
280 LastValueWithDoubleVector()
282 p.
set(kInfinity,kInfinity,kInfinity);
283 vec.set(kInfinity,kInfinity,kInfinity);
286 ~LastValueWithDoubleVector(){}
287 LastValueWithDoubleVector(
const LastValueWithDoubleVector&
r)
289 LastValueWithDoubleVector&
operator=(
const LastValueWithDoubleVector&
r)
291 if (
this == &r) {
return *
this; }
292 p = r.p; vec = r.vec;
value = r.value;
301 LastState fLastInside;
302 LastVector fLastNormal;
303 LastValue fLastDistanceToIn;
304 LastValue fLastDistanceToOut;
305 LastValueWithDoubleVector fLastDistanceToInWithV;
306 LastValueWithDoubleVector fLastDistanceToOutWithV;
315 if(fCubicVolume != 0.) ;
316 else fCubicVolume = 2 * fDz
317 * ( ( fDx1 + fDx2 ) * fDy1 + ( fDx3 + fDx4 ) * fDy2 );
324 if(fSurfaceArea != 0.) ;
332 return ( fDx4 + fDx2 + ( fDx4 - fDx2 ) * ( 2 * phi ) / fPhiTwist ) ;
338 return ( fDx3 + fDx1 + ( fDx3 - fDx1 ) * ( 2 * phi ) / fPhiTwist ) ;
344 return ( fDy2 + fDy1 + ( fDy2 - fDy1 ) * ( 2 * phi ) / fPhiTwist ) ;