Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

BFLInterpolation.h

Go to the documentation of this file.
00001 
00002 //                                                                   //
00003 //authors: Costas Andreopoulos, Elias Athanasopoulos, George Tzanakos//
00004 //                Physics Department, University of Athens           //
00006 
00007 #ifndef BFLINTERPOLATION_H
00008 #define BFLINTERPOLATION_H
00009 
00010 #include <iostream>
00011 
00012 #include "TObject.h"
00013 #include "TVector3.h"
00014 #include "TObjArray.h"
00015 
00016 //#include "BField/BFLWingedEdge.h"
00017 //#include "BField/BFLVorOperator.h"
00018 //#include "BField/BFLCache.h"
00019 #include "BField/BfldInterpMethod.h"
00020 #include "BField/BfldGrid.h"
00021 
00022 class BFLWingedEdge;
00023 class BFLVorOperator;
00024 class BFLCache;
00025 class BFLNode;
00026 class BFLNode2ACell;
00027 class TIntList;
00028 
00029 const Int_t kFail = 1;
00030 const Int_t kMaxVtx = 8;
00031 
00032 //const Int_t kNaturalNeighbors = 1;
00033 
00034 class BFLInterpolation: public TObject
00035 {
00036 public: 
00037 
00038   //BFLInterpolation();
00039   BFLInterpolation(TObjArray * bfield, BFLWingedEdge * voronoi);
00040   ~BFLInterpolation();
00041 
00042   TVector3 GetB(const TVector3& PosVector,
00043                 const Bool_t updateSeedPolygon = kFALSE);
00044 
00045   virtual BFLCache* GetCache(void) { return fCache; }
00046   virtual void SetInterpolant(BfldInterpMethod::InterpMethod_t intp) {
00047       fHowToInterpolate = intp; 
00048   }
00049   virtual void SetGrid(BfldGrid::Grid_t grid) { fGrid = grid;  }
00050   virtual void SetVoronoi(BFLWingedEdge * vor) { fVor = vor; }
00051   virtual void SetBField(TObjArray * bfield) { fBField = bfield; }
00052   virtual void SetCache(BFLCache * cache) { fCache = cache; }
00053   virtual void SetSearchSeed(Int_t seed) { fSearchSeed = seed; }
00054   virtual Int_t GetLastPolygon(void) { return fCurrentPolygID; }
00055     
00056 private: 
00057 
00058   Int_t FormVoronoiCell(BFLNode * point);
00059   Double_t CellArea(TObjArray * vertices);
00060   TVector3 NNInterpolation(BFLNode * point);
00061   TVector3 CNInterpolation(BFLNode * point);
00062   TVector3 BilinearInterpolation(BFLNode * point);
00063   TVector3 PlanarInterpolation(BFLNode *point); //Added by A.G.
00064 
00065   void ResetForNextQuery(void);
00066   Bool_t IsInsideANSYSCell(BFLNode2ACell * TableEntry, BFLNode * point);
00067   void IntBI1stOrder(void);
00068 
00069   BfldInterpMethod::InterpMethod_t   fHowToInterpolate;
00070   BfldGrid::Grid_t                   fGrid;
00071   Int_t                              fCurrentPolygID;
00072   Int_t                              fSearchSeed;
00073   Int_t                              fNPolygs;
00074   TObjArray*                         fBField;
00075   TObjArray*                         fGenerators;
00076   BFLWingedEdge*                     fVor;
00077   BFLVorOperator*                    fOp;  
00078   BFLCache*                          fCache;
00079   TIntList*                          fPolygons;
00080   TObjArray*                         fVertices;
00081 
00082   ClassDef(BFLInterpolation,0)   // Field Vectors interpolation class  
00083 };
00084 
00085 #endif

Generated on Mon Feb 15 11:06:26 2010 for loon by  doxygen 1.3.9.1