23 #ifndef __FINLEY_UTIL_H__
24 #define __FINLEY_UTIL_H__
28 #include <escript/Data.h>
43 const int fs = in.getFunctionSpace().getTypeCode();
49 void gather(
int len,
const int* index,
int numData,
const double* in,
52 void addScatter(
int len,
const int* index,
int numData,
const double* in,
53 double* out,
int upperBound);
56 const std::vector<double>& B,
57 const std::vector<double>& C);
60 const std::vector<double>& B,
61 const std::vector<double>& C);
63 void invertSmallMat(
int len,
int dim,
const double* A,
double *invA,
66 void normalVector(
int len,
int dim,
int dim1,
const double* A,
double* Normal);
68 int getMinInt(
int dim,
int N,
const int* values);
70 int getMaxInt(
int dim,
int N,
const int* values);
72 std::pair<int,int>
getMinMaxInt(
int dim,
int N,
const int* values);
76 std::vector<int>
packMask(
const std::vector<short>& mask);
84 #endif // __FINLEY_UTIL_H__