1 /* 2 User interface for the timestepping package. This package 3 is for use in solving time-dependent PDEs. 4 */ 5 #if !defined(__PETSCTS_H) 6 #define __PETSCTS_H 7 #include "petscsnes.h" 8 PETSC_EXTERN_CXX_BEGIN 9 10 /*S 11 TS - Abstract PETSc object that manages all time-steppers (ODE integrators) 12 13 Level: beginner 14 15 Concepts: ODE solvers 16 17 .seealso: TSCreate(), TSSetType(), TSType, SNES, KSP, PC 18 S*/ 19 typedef struct _p_TS* TS; 20 21 /*E 22 TSType - String with the name of a PETSc TS method or the creation function 23 with an optional dynamic library name, for example 24 http://www.mcs.anl.gov/petsc/lib.a:mytscreate() 25 26 Level: beginner 27 28 .seealso: TSSetType(), TS 29 E*/ 30 #define TSType char* 31 #define TSEULER "euler" 32 #define TSBEULER "beuler" 33 #define TSPSEUDO "pseudo" 34 #define TSCRANK_NICHOLSON "crank-nicholson" 35 #define TSSUNDIALS "sundials" 36 #define TSRUNGE_KUTTA "runge-kutta" 37 #define TSPYTHON "python" 38 #define TSTHETA "theta" 39 #define TSGL "gl" 40 #define TSSSP "ssp" 41 42 /*E 43 TSProblemType - Determines the type of problem this TS object is to be used to solve 44 45 Level: beginner 46 47 .seealso: TSCreate() 48 E*/ 49 typedef enum {TS_LINEAR,TS_NONLINEAR} TSProblemType; 50 51 /* Logging support */ 52 extern PetscClassId PETSCTS_DLLEXPORT TS_CLASSID; 53 54 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSInitializePackage(const char[]); 55 56 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSCreate(MPI_Comm,TS*); 57 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSDestroy(TS); 58 59 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetProblemType(TS,TSProblemType); 60 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetProblemType(TS,TSProblemType*); 61 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSMonitorSet(TS,PetscErrorCode(*)(TS,PetscInt,PetscReal,Vec,void*),void *,PetscErrorCode (*)(void*)); 62 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSMonitorCancel(TS); 63 64 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetOptionsPrefix(TS,const char[]); 65 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSAppendOptionsPrefix(TS,const char[]); 66 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetOptionsPrefix(TS,const char *[]); 67 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetFromOptions(TS); 68 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetUp(TS); 69 70 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetSolution(TS,Vec); 71 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetSolution(TS,Vec*); 72 73 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetDuration(TS,PetscInt,PetscReal); 74 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetDuration(TS,PetscInt*,PetscReal*); 75 76 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSMonitorDefault(TS,PetscInt,PetscReal,Vec,void*); 77 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSMonitorSolution(TS,PetscInt,PetscReal,Vec,void*); 78 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSStep(TS,PetscInt *,PetscReal*); 79 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSolve(TS,Vec); 80 81 82 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetInitialTimeStep(TS,PetscReal,PetscReal); 83 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetTimeStep(TS,PetscReal*); 84 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetTime(TS,PetscReal*); 85 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetTime(TS,PetscReal); 86 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetTimeStepNumber(TS,PetscInt*); 87 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetTimeStep(TS,PetscReal); 88 89 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetRHSFunction(TS,PetscErrorCode (*)(TS,PetscReal,Vec,Vec,void*),void*); 90 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetMatrices(TS,Mat,PetscErrorCode (*)(TS,PetscReal,Mat*,Mat*,MatStructure*,void*),Mat,PetscErrorCode (*)(TS,PetscReal,Mat*,Mat*,MatStructure*,void*),MatStructure,void*); 91 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetMatrices(TS,Mat*,Mat*,void**); 92 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetRHSJacobian(TS,Mat,Mat,PetscErrorCode (*)(TS,PetscReal,Vec,Mat*,Mat*,MatStructure*,void*),void*); 93 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetRHSJacobian(TS,Mat*,Mat*,void**); 94 95 typedef PetscErrorCode (*TSIFunction)(TS,PetscReal,Vec,Vec,Vec,void*); 96 typedef PetscErrorCode (*TSIJacobian)(TS,PetscReal,Vec,Vec,PetscReal,Mat*,Mat*,MatStructure*,void*); 97 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetIFunction(TS,TSIFunction,void*); 98 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetIJacobian(TS,Mat,Mat,TSIJacobian,void*); 99 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetIJacobian(TS,Mat*,Mat*,TSIJacobian*,void**); 100 101 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSDefaultComputeJacobianColor(TS,PetscReal,Vec,Mat*,Mat*,MatStructure*,void*); 102 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSDefaultComputeJacobian(TS,PetscReal,Vec,Mat*,Mat*,MatStructure*,void*); 103 104 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetPreStep(TS, PetscErrorCode (*)(TS)); 105 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetPostStep(TS, PetscErrorCode (*)(TS)); 106 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSDefaultPreStep(TS); 107 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSDefaultPostStep(TS); 108 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPreStep(TS); 109 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPostStep(TS); 110 111 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoSetTimeStep(TS,PetscErrorCode(*)(TS,PetscReal*,void*),void*); 112 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoDefaultTimeStep(TS,PetscReal*,void*); 113 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoComputeTimeStep(TS,PetscReal *); 114 115 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoSetVerifyTimeStep(TS,PetscErrorCode(*)(TS,Vec,void*,PetscReal*,PetscTruth*),void*); 116 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoDefaultVerifyTimeStep(TS,Vec,void*,PetscReal*,PetscTruth*); 117 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoVerifyTimeStep(TS,Vec,PetscReal*,PetscTruth*); 118 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoSetTimeStepIncrement(TS,PetscReal); 119 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPseudoIncrementDtFromInitialDt(TS); 120 121 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSPythonSetType(TS,const char[]); 122 123 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSComputeRHSFunction(TS,PetscReal,Vec,Vec); 124 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSComputeRHSJacobian(TS,PetscReal,Vec,Mat*,Mat*,MatStructure*); 125 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSComputeIFunction(TS,PetscReal,Vec,Vec,Vec); 126 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSComputeIJacobian(TS,PetscReal,Vec,Vec,PetscReal,Mat*,Mat*,MatStructure*); 127 128 /* Dynamic creation and loading functions */ 129 extern PetscFList TSList; 130 extern PetscTruth TSRegisterAllCalled; 131 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetType(TS,const TSType*); 132 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetType(TS,const TSType); 133 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSRegister(const char[], const char[], const char[], PetscErrorCode (*)(TS)); 134 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSRegisterAll(const char[]); 135 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSRegisterDestroy(void); 136 137 /*MC 138 TSRegisterDynamic - Adds a creation method to the TS package. 139 140 Synopsis: 141 PetscErrorCode TSRegisterDynamic(char *name, char *path, char *func_name, PetscErrorCode (*create_func)(TS)) 142 143 Not Collective 144 145 Input Parameters: 146 + name - The name of a new user-defined creation routine 147 . path - The path (either absolute or relative) of the library containing this routine 148 . func_name - The name of the creation routine 149 - create_func - The creation routine itself 150 151 Notes: 152 TSRegisterDynamic() may be called multiple times to add several user-defined tses. 153 154 If dynamic libraries are used, then the fourth input argument (create_func) is ignored. 155 156 Sample usage: 157 .vb 158 TSRegisterDynamic("my_ts", "/home/username/my_lib/lib/libO/solaris/libmy.a", "MyTSCreate", MyTSCreate); 159 .ve 160 161 Then, your ts type can be chosen with the procedural interface via 162 .vb 163 TS ts; 164 TSCreate(MPI_Comm, &ts); 165 TSSetType(ts, "my_ts") 166 .ve 167 or at runtime via the option 168 .vb 169 -ts_type my_ts 170 .ve 171 172 Notes: $PETSC_ARCH occuring in pathname will be replaced with appropriate values. 173 If your function is not being put into a shared library then use TSRegister() instead 174 175 Level: advanced 176 177 .keywords: TS, register 178 .seealso: TSRegisterAll(), TSRegisterDestroy() 179 M*/ 180 #if defined(PETSC_USE_DYNAMIC_LIBRARIES) 181 #define TSRegisterDynamic(a,b,c,d) TSRegister(a,b,c,0) 182 #else 183 #define TSRegisterDynamic(a,b,c,d) TSRegister(a,b,c,d) 184 #endif 185 186 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetSNES(TS,SNES*); 187 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetKSP(TS,KSP*); 188 189 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSView(TS,PetscViewer); 190 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSViewFromOptions(TS,const char[]); 191 192 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSetApplicationContext(TS,void *); 193 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGetApplicationContext(TS,void **); 194 195 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSMonitorLGCreate(const char[],const char[],int,int,int,int,PetscDrawLG *); 196 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSMonitorLG(TS,PetscInt,PetscReal,Vec,void *); 197 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSMonitorLGDestroy(PetscDrawLG); 198 199 /*S 200 TSGLAdapt - Abstract object that manages time-step adaptivity 201 202 Level: beginner 203 204 .seealso: TSGL, TSGLAdaptCreate(), TSGLAdaptType 205 S*/ 206 typedef struct _p_TSGLAdapt *TSGLAdapt; 207 208 /*E 209 TSGLAdaptType - String with the name of TSGLAdapt scheme or the creation function 210 with an optional dynamic library name, for example 211 http://www.mcs.anl.gov/petsc/lib.a:mytsgladaptcreate() 212 213 Level: beginner 214 215 .seealso: TSGLAdaptSetType(), TS 216 E*/ 217 #define TSGLAdaptType char* 218 #define TSGLADAPT_NONE "none" 219 #define TSGLADAPT_SIZE "size" 220 #define TSGLADAPT_BOTH "both" 221 222 /*MC 223 TSGLAdaptRegisterDynamic - adds a TSGLAdapt implementation 224 225 Synopsis: 226 PetscErrorCode TSGLAdaptRegisterDynamic(char *name_scheme,char *path,char *name_create,PetscErrorCode (*routine_create)(TS)) 227 228 Not Collective 229 230 Input Parameters: 231 + name_scheme - name of user-defined adaptivity scheme 232 . path - path (either absolute or relative) the library containing this scheme 233 . name_create - name of routine to create method context 234 - routine_create - routine to create method context 235 236 Notes: 237 TSGLAdaptRegisterDynamic() may be called multiple times to add several user-defined families. 238 239 If dynamic libraries are used, then the fourth input argument (routine_create) 240 is ignored. 241 242 Sample usage: 243 .vb 244 TSGLAdaptRegisterDynamic("my_scheme",/home/username/my_lib/lib/libO/solaris/mylib.a, 245 "MySchemeCreate",MySchemeCreate); 246 .ve 247 248 Then, your scheme can be chosen with the procedural interface via 249 $ TSGLAdaptSetType(ts,"my_scheme") 250 or at runtime via the option 251 $ -ts_adapt_type my_scheme 252 253 Level: advanced 254 255 Notes: Environmental variables such as ${PETSC_ARCH}, ${PETSC_DIR}, ${PETSC_LIB_DIR}, 256 and others of the form ${any_environmental_variable} occuring in pathname will be 257 replaced with appropriate values. 258 259 .keywords: TSGLAdapt, register 260 261 .seealso: TSGLAdaptRegisterAll() 262 M*/ 263 #if defined(PETSC_USE_DYNAMIC_LIBRARIES) 264 # define TSGLAdaptRegisterDynamic(a,b,c,d) TSGLAdaptRegister(a,b,c,0) 265 #else 266 # define TSGLAdaptRegisterDynamic(a,b,c,d) TSGLAdaptRegister(a,b,c,d) 267 #endif 268 269 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptRegister(const char[],const char[],const char[],PetscErrorCode (*)(TSGLAdapt)); 270 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptRegisterAll(const char[]); 271 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptRegisterDestroy(void); 272 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptInitializePackage(const char[]); 273 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptFinalizePackage(void); 274 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptCreate(MPI_Comm,TSGLAdapt*); 275 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptSetType(TSGLAdapt,const TSGLAdaptType); 276 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptSetOptionsPrefix(TSGLAdapt,const char[]); 277 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptChoose(TSGLAdapt,PetscInt,const PetscInt[],const PetscReal[],const PetscReal[],PetscInt,PetscReal,PetscReal,PetscInt*,PetscReal*,PetscTruth*); 278 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptView(TSGLAdapt,PetscViewer); 279 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptSetFromOptions(TSGLAdapt); 280 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAdaptDestroy(TSGLAdapt); 281 282 /*E 283 TSGLAcceptType - String with the name of TSGLAccept scheme or the function 284 with an optional dynamic library name, for example 285 http://www.mcs.anl.gov/petsc/lib.a:mytsglaccept() 286 287 Level: beginner 288 289 .seealso: TSGLSetAcceptType(), TS 290 E*/ 291 #define TSGLAcceptType char* 292 #define TSGLACCEPT_ALWAYS "always" 293 294 typedef PetscErrorCode (*TSGLAcceptFunction)(TS,PetscReal,PetscReal,const PetscReal[],PetscTruth*); 295 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLAcceptRegister(const char[],const char[],const char[],TSGLAcceptFunction); 296 297 /*MC 298 TSGLAcceptRegisterDynamic - adds a TSGL acceptance scheme 299 300 Synopsis: 301 PetscErrorCode TSGLAcceptRegisterDynamic(char *name_scheme,char *path,char *name_create,PetscErrorCode (*routine_create)(TS)) 302 303 Not Collective 304 305 Input Parameters: 306 + name_scheme - name of user-defined acceptance scheme 307 . path - path (either absolute or relative) the library containing this scheme 308 . name_create - name of routine to create method context 309 - routine_create - routine to create method context 310 311 Notes: 312 TSGLAcceptRegisterDynamic() may be called multiple times to add several user-defined families. 313 314 If dynamic libraries are used, then the fourth input argument (routine_create) 315 is ignored. 316 317 Sample usage: 318 .vb 319 TSGLAcceptRegisterDynamic("my_scheme",/home/username/my_lib/lib/libO/solaris/mylib.a, 320 "MySchemeCreate",MySchemeCreate); 321 .ve 322 323 Then, your scheme can be chosen with the procedural interface via 324 $ TSGLSetAcceptType(ts,"my_scheme") 325 or at runtime via the option 326 $ -ts_gl_accept_type my_scheme 327 328 Level: advanced 329 330 Notes: Environmental variables such as ${PETSC_ARCH}, ${PETSC_DIR}, ${PETSC_LIB_DIR}, 331 and others of the form ${any_environmental_variable} occuring in pathname will be 332 replaced with appropriate values. 333 334 .keywords: TSGL, TSGLAcceptType, register 335 336 .seealso: TSGLRegisterAll() 337 M*/ 338 #if defined(PETSC_USE_DYNAMIC_LIBRARIES) 339 # define TSGLAcceptRegisterDynamic(a,b,c,d) TSGLAcceptRegister(a,b,c,0) 340 #else 341 # define TSGLAcceptRegisterDynamic(a,b,c,d) TSGLAcceptRegister(a,b,c,d) 342 #endif 343 344 /*E 345 TSGLType - family of time integration method within the General Linear class 346 347 Level: beginner 348 349 .seealso: TSGLSetType(), TSGLRegister() 350 E*/ 351 #define TSGLType char* 352 #define TSGL_IRKS "irks" 353 354 /*MC 355 TSGLRegisterDynamic - adds a TSGL implementation 356 357 Synopsis: 358 PetscErrorCode TSGLRegisterDynamic(char *name_scheme,char *path,char *name_create,PetscErrorCode (*routine_create)(TS)) 359 360 Not Collective 361 362 Input Parameters: 363 + name_scheme - name of user-defined general linear scheme 364 . path - path (either absolute or relative) the library containing this scheme 365 . name_create - name of routine to create method context 366 - routine_create - routine to create method context 367 368 Notes: 369 TSGLRegisterDynamic() may be called multiple times to add several user-defined families. 370 371 If dynamic libraries are used, then the fourth input argument (routine_create) 372 is ignored. 373 374 Sample usage: 375 .vb 376 TSGLRegisterDynamic("my_scheme",/home/username/my_lib/lib/libO/solaris/mylib.a, 377 "MySchemeCreate",MySchemeCreate); 378 .ve 379 380 Then, your scheme can be chosen with the procedural interface via 381 $ TSGLSetType(ts,"my_scheme") 382 or at runtime via the option 383 $ -ts_gl_type my_scheme 384 385 Level: advanced 386 387 Notes: Environmental variables such as ${PETSC_ARCH}, ${PETSC_DIR}, ${PETSC_LIB_DIR}, 388 and others of the form ${any_environmental_variable} occuring in pathname will be 389 replaced with appropriate values. 390 391 .keywords: TSGL, register 392 393 .seealso: TSGLRegisterAll() 394 M*/ 395 #if defined(PETSC_USE_DYNAMIC_LIBRARIES) 396 # define TSGLRegisterDynamic(a,b,c,d) TSGLRegister(a,b,c,0) 397 #else 398 # define TSGLRegisterDynamic(a,b,c,d) TSGLRegister(a,b,c,d) 399 #endif 400 401 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLRegister(const char[],const char[],const char[],PetscErrorCode(*)(TS)); 402 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLRegisterAll(const char[]); 403 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLRegisterDestroy(void); 404 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLInitializePackage(const char[]); 405 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLFinalizePackage(void); 406 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLSetType(TS,const TSGLType); 407 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLGetAdapt(TS,TSGLAdapt*); 408 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSGLSetAcceptType(TS,const TSGLAcceptType); 409 410 /* 411 PETSc interface to Sundials 412 */ 413 #ifdef PETSC_HAVE_SUNDIALS 414 typedef enum { SUNDIALS_ADAMS=1,SUNDIALS_BDF=2} TSSundialsLmmType; 415 extern const char *TSSundialsLmmTypes[]; 416 typedef enum { SUNDIALS_MODIFIED_GS = 1,SUNDIALS_CLASSICAL_GS = 2 } TSSundialsGramSchmidtType; 417 extern const char *TSSundialsGramSchmidtTypes[]; 418 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsSetType(TS,TSSundialsLmmType); 419 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsGetPC(TS,PC*); 420 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsSetTolerance(TS,PetscReal,PetscReal); 421 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsGetIterations(TS,PetscInt *,PetscInt *); 422 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsSetGramSchmidtType(TS,TSSundialsGramSchmidtType); 423 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsSetGMRESRestart(TS,PetscInt); 424 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsSetLinearTolerance(TS,PetscReal); 425 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsSetExactFinalTime(TS,PetscTruth); 426 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsMonitorInternalSteps(TS,PetscTruth); 427 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSSundialsGetParameters(TS,PetscInt *,long*[],double*[]); 428 #endif 429 430 EXTERN PetscErrorCode PETSCTS_DLLEXPORT TSRKSetTolerance(TS,PetscReal); 431 432 EXTERN PetscErrorCode PETSCKSP_DLLEXPORT TSSetDM(TS,DM); 433 EXTERN PetscErrorCode PETSCKSP_DLLEXPORT TSGetDM(TS,DM*); 434 435 PETSC_EXTERN_CXX_END 436 #endif 437