LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
larg4::SimpleWireplaneAction Class Reference

#include "OpParamAction.h"

Inheritance diagram for larg4::SimpleWireplaneAction:
larg4::OpParamAction

Public Member Functions

 SimpleWireplaneAction (TVector3 WireDirection, TVector3 PlaneNormal, double WirePitch, double WireDiameter)
 
 SimpleWireplaneAction (std::vector< std::vector< double >>, int)
 
 ~SimpleWireplaneAction ()
 
double GetAttenuationFraction (G4ThreeVector PhotonDirection, G4ThreeVector PhotonPosition)
 

Private Attributes

G4ThreeVector fWireDirection
 
G4ThreeVector fPlaneNormal
 
double fDPRatio
 

Detailed Description

Definition at line 71 of file OpParamAction.h.

Constructor & Destructor Documentation

larg4::SimpleWireplaneAction::SimpleWireplaneAction ( TVector3  WireDirection,
TVector3  PlaneNormal,
double  WirePitch,
double  WireDiameter 
)

Definition at line 30 of file OpParamAction.cxx.

34  {
35  fWireDirection = G4ThreeVector(WireDirection.X(), WireDirection.Y(), WireDirection.Z()).unit();
36  fPlaneNormal = G4ThreeVector(PlaneNormal.X(), PlaneNormal.Y(), PlaneNormal.Z()).unit();
37  fDPRatio = WireDiameter / WirePitch;
38  }
larg4::SimpleWireplaneAction::SimpleWireplaneAction ( std::vector< std::vector< double >>  ,
int   
)
larg4::SimpleWireplaneAction::~SimpleWireplaneAction ( )

Definition at line 42 of file OpParamAction.cxx.

42 {}

Member Function Documentation

double larg4::SimpleWireplaneAction::GetAttenuationFraction ( G4ThreeVector  PhotonDirection,
G4ThreeVector  PhotonPosition 
)
virtual

Reimplemented from larg4::OpParamAction.

Definition at line 50 of file OpParamAction.cxx.

References util::abs().

52  {
53  G4ThreeVector ProjDirection =
54  PhotonDirection - fWireDirection * (fWireDirection.dot(PhotonDirection));
55  double CosTheta = std::abs(fPlaneNormal.dot(ProjDirection));
56  if (CosTheta < fDPRatio)
57  return 0;
58  else
59  return (1.0 - fDPRatio / CosTheta);
60  }
constexpr auto abs(T v)
Returns the absolute value of the argument.

Member Data Documentation

double larg4::SimpleWireplaneAction::fDPRatio
private

Definition at line 85 of file OpParamAction.h.

G4ThreeVector larg4::SimpleWireplaneAction::fPlaneNormal
private

Definition at line 84 of file OpParamAction.h.

G4ThreeVector larg4::SimpleWireplaneAction::fWireDirection
private

Definition at line 83 of file OpParamAction.h.


The documentation for this class was generated from the following files: