Overture  Version 25
InterpolatePoints.h
Go to the documentation of this file.
1 #ifndef INTERPOLATE_POINTS_CG_H
2 #define INTERPOLATE_POINTS_CG_H
3 
4 
5 // class that can be used to interpolate arbitrary points on a Composite grid.
6 
7 
9 {
10  public:
11 
13  {
17  };
18 
19  enum
20  {
23  };
24 
25 
26 
29 
30  int interpolatePoints(const RealArray & positionToInterpolate,
31  const realCompositeGridFunction & u,
32  RealArray & uInterpolated,
33  const Range & R0=nullRange,
34  const Range & R1=nullRange,
35  const Range & R2=nullRange,
36  const Range & R3=nullRange,
37  const Range & R4=nullRange );
38 
40  RealArray & uInterpolationCoeff);
41 
44  const Range & componentsFrom=nullRange,
45  const Range & componentsTo=nullRange,
46  const int numberOfGhostPointsToInterpolate=interpolateAllGhostPoints );
47 
50  const Range & componentsFrom=nullRange,
51  const Range & componentsTo=nullRange,
52  const int numberOfGhostPointsToInterpolate=interpolateAllGhostPoints );
53 
54 
55  // Here is a way to interpolate in two steps, this will save the interpolation info
56  int buildInterpolationInfo(const RealArray & positionToInterpolate,CompositeGrid & cg,
57  RealArray *projectedPoints=NULL,
58  IntegerArray *checkTheseGrids=NULL );
60  RealArray & uInterpolated,
61  const Range & R0=nullRange,
62  const Range & R1=nullRange,
63  const Range & R2=nullRange,
64  const Range & R3=nullRange,
65  const Range & R4=nullRange );
66 
67  // return the status array for the last interpolation.
68  const IntegerArray & getStatus() const;
69 
70  // return the index values and interpoleeGrid for the last interpolation.
71  int getInterpolationInfo(CompositeGrid & cg, IntegerArray & indexValues, IntegerArray & interpoleeGrid) const;
72 
73  // flag for specfying what information messages should be printed:
74  int setInfoLevel( int info );
75 
76  // Set the offset in grid lines from the unit cube where we are allowed to interpolate
77  int setInterpolationOffset( real widthInGridLines );
78 
79  // set the number of valid ghost points
81 
82  static int debug;
83 
84  protected:
85 
90 
93 
94  real interpolationOffset; // offset in grid lines from the unit cube where we are allowed to interpolate
95 
96  int infoLevel; // flag for specfying what information messages should be printed.
98 
99 };
100 
101 #endif