Auxiliary class for determination of smallest distance between pair of 3D points.  
 More...
#include <JGeometry3DToolkit.hh>
 | 
| template<class T >  | 
| static double  | getDmin (T __begin, T __end) | 
|   | Recursive method to find the smallest distance.  More...
  | 
|   | 
Auxiliary class for determination of smallest distance between pair of 3D points. 
Definition at line 131 of file JGeometry3DToolkit.hh.
 
  
  
      
        
          | JGEOMETRY3D::JSmallestDistance3D::JSmallestDistance3D  | 
          ( | 
           | ) | 
           | 
         
       
   | 
  
inline   | 
  
 
 
template<class T > 
  
  
      
        
          | static double JGEOMETRY3D::JSmallestDistance3D::getDmin  | 
          ( | 
          T  | 
          __begin,  | 
         
        
           | 
           | 
          T  | 
          __end  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
inlinestaticprotected   | 
  
 
Recursive method to find the smallest distance. 
- Parameters
 - 
  
    | __begin | begin of data  | 
    | __end | end of data  | 
  
   
- Returns
 - minimal distance 
 
Definition at line 141 of file JGeometry3DToolkit.hh.
  149         double Dmin = numeric_limits<double>::max();
 
  151         for (
T i = __begin; 
i != __end; ++
i) {
 
  152           for (
T j = 
i; ++
j != __end; ) {
 
  170         const double dl   = 
getDmin(__begin, i);
 
  171         const double dr   = 
getDmin(i,   __end);
 
  173         const double Dmin = min(dl, dr);
 
  178         while (--il != __begin && i ->getZ() - il->getZ() < Dmin) {}
 
  179         while (++ir != __end   && ir->getZ() - i ->getZ() < Dmin) {}
 
  185         return min(Dmin, dz);
 
std::vector< T >::difference_type distance(typename std::vector< T >::const_iterator first, typename PhysicsEvent::const_iterator< T > second)
Specialisation of STL distance. 
 
static const JSmallestDistance2D getSmallestDistance2D
Function object for smallest distance determination. 
 
double getDistance(const JFirst_t &first, const JSecond_t &second)
Get distance between objects. 
 
static double getDmin(T __begin, T __end)
Recursive method to find the smallest distance. 
 
static const JCompareZ compareZ
Function object for sorting elements. 
 
do set_variable OUTPUT_DIRECTORY $WORKDIR T
 
counter_type advance(counter_type &counter, const counter_type value, const counter_type limit=std::numeric_limits< counter_type >::max())
Advance counter. 
 
then usage $script< input file >[option[primary[working directory]]] nWhere option can be N
 
then JMuonMCEvt f $INPUT_FILE o $INTERMEDIATE_FILE d
 
 
 
 
template<class T > 
  
  
      
        
          | double JGEOMETRY3D::JSmallestDistance3D::operator()  | 
          ( | 
          T  | 
          __begin,  | 
         
        
           | 
           | 
          T  | 
          __end  | 
         
        
           | 
          ) | 
           |  const | 
         
       
   | 
  
inline   | 
  
 
Get smallest distance between two points. 
Note that this method changes the order of the elements.
- Parameters
 - 
  
    | __begin | begin of data  | 
    | __end | end of data  | 
  
   
- Returns
 - minimal distance 
 
Definition at line 229 of file JGeometry3DToolkit.hh.
  235       return getDmin(__begin, __end);
 
static double getDmin(T __begin, T __end)
Recursive method to find the smallest distance. 
 
static const JCompareZ compareZ
Function object for sorting elements. 
 
 
 
 
  
  
      
        
          | const JCompareZ JGEOMETRY3D::JSmallestDistance3D::compareZ | 
         
       
   | 
  
static   | 
  
 
 
The documentation for this class was generated from the following file: