Dendro  5.01
Dendro in Greek language means tree. The Dendro library is a large scale (262K cores on ORNL's Titan) distributed memory adaptive octree framework. The main goal of Dendro is to perform large scale multiphysics simulations efficeiently in mordern supercomputers. Dendro consists of efficient parallel data structures and algorithms to perform variational ( finite element) methods and finite difference mthods on 2:1 balanced arbitary adaptive octrees which enables the users to perform simulations raning from black holes (binary black hole mergers) to blood flow in human body, where applications ranging from relativity, astrophysics to biomedical engineering.
basis.h
1 //
2 // Created by milinda on 1/12/17.
3 //
4 
15 #ifndef SFCSORTBENCH_JACOBIPOLYNOMIAL_H
16 #define SFCSORTBENCH_JACOBIPOLYNOMIAL_H
17 
18 
19 #include "assert.h"
20 #include <iostream>
21 #include <math.h>
22 #include <cmath>
23 #include "cstring"
24 #ifdef WITH_BLAS_LAPACK
25 #include "lapac.h"
26 #endif
27 
28 #ifndef WITH_BLAS_LAPACK
29 template <typename T>
30 void printArray_1D(T *a, int length)
31 {
32  for (int i = 0; i < length; i++) { std::cout<<a[i]<<" "; }
33  std::cout<<std::endl;
34 }
35 
36 
37 template <typename T>
38 void printArray_2D(T *a, int length1,int length2)
39 {
40  for (int i = 0; i < length1; i++) {
41  for (int j = 0; j < length2; j++) {
42  std::cout << a[i * length2 + j] << " ";
43  }
44  std::cout<<std::endl;
45  }
46  std::cout<<std::endl;
47 }
48 
49 #endif
50 
51 
52 
53 namespace basis {
54 
72  void jacobip(double alpha, double beta, unsigned int N,
73  double *x, double *p , unsigned int np);
74 
92  void gradjacobip(double alpha, double beta, int N,double *x, double *dp, unsigned int np);
93 
107  void jacobiglq(double alpha, double beta, int N,
108  double *x, double *w);
109 
126  void jacobigq(double alpha, double beta, int N,
127  double *x, double *w);
128 
129 
130 
139  void lagrange(const double * x0, int N, int at, const double * x, double* px, int m);
140 
141 
142 
143 }
144 
145 #endif //SFCSORTBENCH_JACOBIPOLYNOMIAL_H
void jacobip(double alpha, double beta, unsigned int N, double *x, double *p, unsigned int np)
Definition: basis.cpp:19
void lagrange(const double *x0, int N, int at, const double *x, double *px, int m)
computes the Lagrange polynomials evalueated at x coords.
Definition: basis.cpp:217
Definition: basis.h:53
void jacobigq(double alpha, double beta, int N, double *x, double *w)
Definition: basis.cpp:93
void jacobiglq(double alpha, double beta, int N, double *x, double *w)
Definition: basis.cpp:171
void gradjacobip(double alpha, double beta, int N, double *x, double *dp, unsigned int np)
Definition: basis.cpp:72