TrioCFD 1.9.8
TrioCFD documentation
Loading...
Searching...
No Matches
SPV2.h
1/****************************************************************************
2* Copyright (c) 2022, CEA
3* All rights reserved.
4*
5* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
6* 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
7* 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
8* 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
9*
10* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
11* IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
12* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
13*
14*****************************************************************************/
15#ifndef SPV2_H
16#define SPV2_H
17extern "C" {
18#ifdef F77_Majuscule
19 void F77DECLARE(ILUTV2)(const int* n, const double* a, const int* ja, const int* ia,const int* lfil,const double* droptol, const double* alu, const int* jlu, const int* ju, const int* iwk,const double* w,const int* jw, const int* ierr);
20
21#else
22 void F77DECLARE(ilutv2)(const int* n, const double* a, const int* ja, const int* ia,const int* lfil,const double* droptol, const double* alu, const int* jlu, const int* ju, const int* iwk,const double* w,const int* jw, const int* ierr);
23
24#endif
25}
26#ifndef F77_Majuscule
27inline void F77NAME(ILUTV2)(const int* n, const double* a, const int* ja, const int* ia,const int* lfil,const double* droptol, const double* alu, const int* jlu,const int* ju, const int* iwk,const double* w,const int* jw, const int* ierr)
28{
29 F77NAME(ilutv2)( n,a,ja,ia,lfil,droptol,alu,jlu,ju,iwk,w,jw, ierr)
30 ;
31}
32
33#endif
34
35//MILU0
36extern "C" {
37#ifdef F77_Majuscule
38 void F77DECLARE(MILU0V2)(const int* n, const double* a, const int* ja, const int* ia, const double* alu, const int* jlu, const int* ju, const int* jw, const int* ierr);
39
40#else
41 void F77DECLARE(milu0v2)(const int* n, const double* a, const int* ja, const int* ia, const double* alu, const int* jlu, const int* ju, const int* jw, const int* ierr);
42
43#endif
44}
45#ifndef F77_Majuscule
46inline void F77NAME(MILU0V2)(const int* n, const double* a, const int* ja, const int* ia, const double* alu, const int* jlu, const int* ju, const int* jw, const int* ierr)
47{
48 F77NAME(milu0v2)( n,a,ja,ia,alu,jlu,ju,jw, ierr)
49 ;
50}
51
52#endif
53
54//ILU0
55extern "C" {
56#ifdef F77_Majuscule
57 void F77DECLARE(ILU0V2)(const int* n, const double* a, const int* ja, const int* ia, const double* alu, const int* jlu, const int* ju, const int* jw, const int* ierr);
58
59#else
60 void F77DECLARE(ilu0v2)(const int* n, const double* a, const int* ja, const int* ia, const double* alu, const int* jlu, const int* ju, const int* jw, const int* ierr);
61
62#endif
63}
64#ifndef F77_Majuscule
65inline void F77NAME(ILU0V2)(const int* n, const double* a, const int* ja, const int* ia, const double* alu, const int* jlu, const int* ju, const int* jw, const int* ierr)
66{
67 F77NAME(ilu0v2)( n,a,ja,ia,alu,jlu,ju,jw, ierr)
68 ;
69}
70
71#endif
72extern "C" {
73#ifdef F77_Majuscule
74
75
76 void F77DECLARE(LUSOLV2) (const int* const,const double* const,
77 const double* const,const double* const,
78 const int* const,const int* const);
79
80 void F77DECLARE(LUTSOLV2) (const int* const,const double* const,
81 const double* const,const double* const,
82 const int* const,const int* const);
83
84 void F77DECLARE(PGMRESV2)(const int* const, const int* const, const double* const, double* const,
85 const double* const, const double* const, const int* const, const int* const,
86 const double* const, const int* const, const int* const, const double* const,
87 const int* const, const int* const, int* const);
88 void F77NAME(CGV2)(const int* const a, const double* const b,
89 double* c, int* d,double* e, double* f );
90
91 void F77NAME(BCGSTABV2)(const int* const a, const double* const b,
92 double* c, int* d,double* e, double* f );
93
94 void F77NAME(GMRESV2)(const int* const a, const double* const b,
95 double* c, int* d,double* e, double* f );
96
97#else
98
99 void F77DECLARE(lusolv2) (const int* const,const double* const,
100 const double* const,const double* const,
101 const int* const,const int* const);
102
103 void F77DECLARE(lutsolv2) (const int* const,const double* const,
104 const double* const,const double* const,
105 const int* const,const int* const);
106
107 void F77DECLARE(pgmresv2)(const int* const, const int* const, const double* const, double* const,
108 const double* const, const double* const, const int* const, const int* const,
109 const double* const, const int* const, const int* const, const double* const,
110 const int* const, const int* const, int* const);
111 void F77NAME(cgv2)(const int* const a, const double* const b,
112 double* c, int* d,double* e, double* f );
113
114 void F77NAME(bcgstabv2)(const int* const a, const double* const b,
115 double* c, int* d,double* e, double* f );
116
117 void F77NAME(gmresv2)(const int* const a, const double* const b,
118 double* c, int* d,double* e, double* f );
119
120#endif
121}
122#ifndef F77_Majuscule
123
124inline void F77NAME(LUSOLV2) (const int* const a, const double* const b,
125 const double* const c, const double* const d,
126 const int* const e, const int* const f)
127{
128 F77NAME(lusolv2)(a,b,c,d,e,f);
129}
130
131inline void F77NAME(LUTSOLV2) (const int* const a, const double* const b,
132 const double* const c, const double* const d,
133 const int* const e, const int* const f)
134{
135 F77NAME(lutsolv2)(a,b,c,d,e,f);
136}
137
138
139/*! @brief
140 *
141 */
142inline void F77NAME(PGMRESV2)(const int* const a, const int* const b,
143 const double* const c, double* const d,
144 const double* const e, const double* const f,
145 const int* const g, const int* const h,
146 const double* const i, const int* const j,
147 const int* const k, const double* const l,
148 const int* const m, const int* const n, int* const o)
149{
150 F77NAME(pgmresv2)(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o);
151}
152inline void F77NAME(CGV2)(const int* const a, const double* const b,
153 double* c,int* d,double* e,double* f )
154{
155 F77NAME(cgv2)(a,b,c,d,e,f);
156}
157
158inline void F77NAME(BCGSTABV2)(const int* const a, const double* const b,
159 double* c,int* d,double* e,double* f )
160{
161 F77NAME(bcgstabv2)(a,b,c,d,e,f);
162}
163
164inline void F77NAME(GMRESV2)(const int* const a, const double* const b,
165 double* c,int* d,double* e,double* f )
166{
167 F77NAME(gmresv2)(a,b,c,d,e,f);
168}
169#endif
170#endif