1 |
|
2 |
typedef struct IntegratorIdaPrecDJStruct{ |
3 |
N_Vector PIii; /**< diagonal elements of the inversed Jacobi preconditioner */ |
4 |
} IntegratorIdaPrecDataJacobi; |
5 |
|
6 |
typedef struct IntegratorIdaPrecDJFStruct{ |
7 |
linsolqr_system_t L; |
8 |
} IntegratorIdaPrecDataJacobian; |
9 |
|
10 |
/** |
11 |
Hold all the function pointers associated with a particular preconditioner |
12 |
We don't need to store the 'pfree' function here as it is allocated to the enginedata struct |
13 |
by the pcreate function (ensures that corresponding 'free' and 'create' are always used) |
14 |
|
15 |
@note IDA uses a different convention for function pointer types, so no '*'. |
16 |
*/ |
17 |
typedef struct IntegratorIdaPrecStruct{ |
18 |
IntegratorIdaPrecCreateFn *pcreate; |
19 |
IDASpilsPrecSetupFn psetup; |
20 |
IDASpilsPrecSolveFn psolve; |
21 |
} IntegratorIdaPrec; |
22 |
|
23 |
/*------ |
24 |
Full jacobian preconditioner -- experimental |
25 |
*/ |
26 |
|
27 |
void integrator_ida_pfree_jacobian(IntegratorIdaData *enginedata); |
28 |
|
29 |
const IntegratorIdaPrec prec_jacobian; |
30 |
|
31 |
/*------ |
32 |
Jacobi preconditioner -- experimental |
33 |
*/ |
34 |
|
35 |
void integrator_ida_pfree_jacobi(IntegratorIdaData *enginedata); |
36 |
|
37 |
const IntegratorIdaPrec prec_jacobi; |
38 |
|