aboutsummaryrefslogtreecommitdiff
path: root/internal.h
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2016-08-28 10:07:20 +0200
committerAnton Khirnov <anton@khirnov.net>2016-08-28 11:14:30 +0200
commit2926c4ea6f9e34b8962a08dff372252537473bda (patch)
treeb64afad877bf5dff429c704af4e484cf57ee2dae /internal.h
parent63b25eca76d8481a0fdad339464d1eb617826583 (diff)
basis: disentangle the API from the global solver API
Diffstat (limited to 'internal.h')
-rw-r--r--internal.h18
1 files changed, 2 insertions, 16 deletions
diff --git a/internal.h b/internal.h
index ae9932a..78b3741 100644
--- a/internal.h
+++ b/internal.h
@@ -22,6 +22,7 @@
#include "brill_data.h"
+#include "basis.h"
#include "qfunc.h"
#define MAX(x, y) ((x) > (y) ? (x) : (y))
@@ -37,23 +38,9 @@
*/
#define EPS 1E-08
-/* a set of basis functions */
-typedef struct BasisSet {
- /* evaluate the idx-th basis function at the specified point*/
- double (*eval) (double coord, int idx, double sf);
- /* evaluate the first derivative of the idx-th basis function at the specified point*/
- double (*eval_diff1)(double coord, int idx, double sf);
- /* evaluate the second derivative of the idx-th basis function at the specified point*/
- double (*eval_diff2)(double coord, int idx, double sf);
- /**
- * Get the idx-th collocation point for the specified order.
- * idx runs from 0 to order - 1 (inclusive)
- */
- double (*colloc_point)(int order, int idx, double sf);
-} BasisSet;
typedef struct BDPriv {
- const BasisSet *basis[2];
+ BasisSetContext *basis[2];
QFuncContext *qfunc;
int nb_colloc_points[2];
@@ -66,7 +53,6 @@ typedef struct BDPriv {
#define NB_COEFFS(s) (s->nb_coeffs[0] * s->nb_coeffs[1])
#define NB_COLLOC_POINTS(s) (s->nb_colloc_points[0] * s->nb_colloc_points[1])
-extern const BasisSet bdi_sb_even_basis;
int bdi_solve(BDContext *bd);