kinsol.h File Reference

#include <stdio.h>
#include <sundials/sundials_nvector.h>

Go to the source code of this file.

Defines

#define KIN_SUCCESS   0
#define KIN_INITIAL_GUESS_OK   1
#define KIN_STEP_LT_STPTOL   2
#define KIN_WARNING   99
#define KIN_MEM_NULL   -1
#define KIN_ILL_INPUT   -2
#define KIN_NO_MALLOC   -3
#define KIN_MEM_FAIL   -4
#define KIN_LINESEARCH_NONCONV   -5
#define KIN_MAXITER_REACHED   -6
#define KIN_MXNEWT_5X_EXCEEDED   -7
#define KIN_LINESEARCH_BCFAIL   -8
#define KIN_LINSOLV_NO_RECOVERY   -9
#define KIN_LINIT_FAIL   -10
#define KIN_LSETUP_FAIL   -11
#define KIN_LSOLVE_FAIL   -12
#define KIN_SYSFUNC_FAIL   -13
#define KIN_FIRST_SYSFUNC_ERR   -14
#define KIN_REPTD_SYSFUNC_ERR   -15
#define KIN_ETACHOICE1   1
#define KIN_ETACHOICE2   2
#define KIN_ETACONSTANT   3
#define KIN_NONE   0
#define KIN_LINESEARCH   1

Typedefs

typedef int(* KINSysFn )(N_Vector uu, N_Vector fval, void *f_data)
typedef void(* KINErrHandlerFn )(int error_code, const char *module, const char *function, char *msg, void *eh_data)
typedef void(* KINInfoHandlerFn )(const char *module, const char *function, char *msg, void *ih_data)

Functions

SUNDIALS_EXPORT void * KINCreate (void)
SUNDIALS_EXPORT int KINSetErrHandlerFn (void *kinmem, KINErrHandlerFn ehfun, void *eh_data)
SUNDIALS_EXPORT int KINSetErrFile (void *kinmem, FILE *errfp)
SUNDIALS_EXPORT int KINSetInfoHandlerFn (void *kinmem, KINInfoHandlerFn ihfun, void *ih_data)
SUNDIALS_EXPORT int KINSetInfoFile (void *kinmem, FILE *infofp)
SUNDIALS_EXPORT int KINSetFdata (void *kinmem, void *f_data)
SUNDIALS_EXPORT int KINSetPrintLevel (void *kinmemm, int printfl)
SUNDIALS_EXPORT int KINSetNumMaxIters (void *kinmem, long int mxiter)
SUNDIALS_EXPORT int KINSetNoInitSetup (void *kinmem, booleantype noInitSetup)
SUNDIALS_EXPORT int KINSetNoResMon (void *kinmem, booleantype noNNIResMon)
SUNDIALS_EXPORT int KINSetMaxSetupCalls (void *kinmem, long int msbset)
SUNDIALS_EXPORT int KINSetMaxSubSetupCalls (void *kinmem, long int msbsetsub)
SUNDIALS_EXPORT int KINSetEtaForm (void *kinmem, int etachoice)
SUNDIALS_EXPORT int KINSetEtaConstValue (void *kinmem, realtype eta)
SUNDIALS_EXPORT int KINSetEtaParams (void *kinmem, realtype egamma, realtype ealpha)
SUNDIALS_EXPORT int KINSetResMonParams (void *kinmem, realtype omegamin, realtype omegamax)
SUNDIALS_EXPORT int KINSetResMonConstValue (void *kinmem, realtype omegaconst)
SUNDIALS_EXPORT int KINSetNoMinEps (void *kinmem, booleantype noMinEps)
SUNDIALS_EXPORT int KINSetMaxNewtonStep (void *kinmem, realtype mxnewtstep)
SUNDIALS_EXPORT int KINSetMaxBetaFails (void *kinmem, long int mxnbcf)
SUNDIALS_EXPORT int KINSetRelErrFunc (void *kinmem, realtype relfunc)
SUNDIALS_EXPORT int KINSetFuncNormTol (void *kinmem, realtype fnormtol)
SUNDIALS_EXPORT int KINSetScaledStepTol (void *kinmem, realtype scsteptol)
SUNDIALS_EXPORT int KINSetConstraints (void *kinmem, N_Vector constraints)
SUNDIALS_EXPORT int KINSetSysFunc (void *kinmem, KINSysFn func)
SUNDIALS_EXPORT int KINMalloc (void *kinmem, KINSysFn func, N_Vector tmpl)
SUNDIALS_EXPORT int KINSol (void *kinmem, N_Vector uu, int strategy, N_Vector u_scale, N_Vector f_scale)
SUNDIALS_EXPORT int KINGetWorkSpace (void *kinmem, long int *lenrw, long int *leniw)
SUNDIALS_EXPORT int KINGetNumNonlinSolvIters (void *kinmem, long int *nniters)
SUNDIALS_EXPORT int KINGetNumFuncEvals (void *kinmem, long int *nfevals)
SUNDIALS_EXPORT int KINGetNumBetaCondFails (void *kinmem, long int *nbcfails)
SUNDIALS_EXPORT int KINGetNumBacktrackOps (void *kinmem, long int *nbacktr)
SUNDIALS_EXPORT int KINGetFuncNorm (void *kinmem, realtype *fnorm)
SUNDIALS_EXPORT int KINGetStepLength (void *kinmem, realtype *steplength)
SUNDIALS_EXPORT char * KINGetReturnFlagName (int flag)
SUNDIALS_EXPORT void KINFree (void **kinmem)


Define Documentation

#define KIN_ETACHOICE1   1

#define KIN_ETACHOICE2   2

#define KIN_ETACONSTANT   3

#define KIN_FIRST_SYSFUNC_ERR   -14

#define KIN_ILL_INPUT   -2

#define KIN_INITIAL_GUESS_OK   1

#define KIN_LINESEARCH   1

Referenced by main().

#define KIN_LINESEARCH_BCFAIL   -8

#define KIN_LINESEARCH_NONCONV   -5

#define KIN_LINIT_FAIL   -10

#define KIN_LINSOLV_NO_RECOVERY   -9

#define KIN_LSETUP_FAIL   -11

#define KIN_LSOLVE_FAIL   -12

#define KIN_MAXITER_REACHED   -6

#define KIN_MEM_FAIL   -4

#define KIN_MEM_NULL   -1

#define KIN_MXNEWT_5X_EXCEEDED   -7

#define KIN_NO_MALLOC   -3

#define KIN_NONE   0

Referenced by main().

#define KIN_REPTD_SYSFUNC_ERR   -15

#define KIN_STEP_LT_STPTOL   2

#define KIN_SUCCESS   0

#define KIN_SYSFUNC_FAIL   -13

#define KIN_WARNING   99


Typedef Documentation

typedef void(* KINErrHandlerFn)(int error_code, const char *module, const char *function, char *msg, void *eh_data)

typedef void(* KINInfoHandlerFn)(const char *module, const char *function, char *msg, void *ih_data)

typedef int(* KINSysFn)(N_Vector uu, N_Vector fval, void *f_data)


Function Documentation

SUNDIALS_EXPORT void* KINCreate ( void   ) 

Referenced by main().

SUNDIALS_EXPORT void KINFree ( void **  kinmem  ) 

Referenced by main().

SUNDIALS_EXPORT int KINGetFuncNorm ( void *  kinmem,
realtype *  fnorm 
)

Referenced by main().

SUNDIALS_EXPORT int KINGetNumBacktrackOps ( void *  kinmem,
long int *  nbacktr 
)

SUNDIALS_EXPORT int KINGetNumBetaCondFails ( void *  kinmem,
long int *  nbcfails 
)

SUNDIALS_EXPORT int KINGetNumFuncEvals ( void *  kinmem,
long int *  nfevals 
)

SUNDIALS_EXPORT int KINGetNumNonlinSolvIters ( void *  kinmem,
long int *  nniters 
)

SUNDIALS_EXPORT char* KINGetReturnFlagName ( int  flag  ) 

SUNDIALS_EXPORT int KINGetStepLength ( void *  kinmem,
realtype *  steplength 
)

SUNDIALS_EXPORT int KINGetWorkSpace ( void *  kinmem,
long int *  lenrw,
long int *  leniw 
)

SUNDIALS_EXPORT int KINMalloc ( void *  kinmem,
KINSysFn  func,
N_Vector  tmpl 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetConstraints ( void *  kinmem,
N_Vector  constraints 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetErrFile ( void *  kinmem,
FILE *  errfp 
)

SUNDIALS_EXPORT int KINSetErrHandlerFn ( void *  kinmem,
KINErrHandlerFn  ehfun,
void *  eh_data 
)

SUNDIALS_EXPORT int KINSetEtaConstValue ( void *  kinmem,
realtype  eta 
)

SUNDIALS_EXPORT int KINSetEtaForm ( void *  kinmem,
int  etachoice 
)

SUNDIALS_EXPORT int KINSetEtaParams ( void *  kinmem,
realtype  egamma,
realtype  ealpha 
)

SUNDIALS_EXPORT int KINSetFdata ( void *  kinmem,
void *  f_data 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetFuncNormTol ( void *  kinmem,
realtype  fnormtol 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetInfoFile ( void *  kinmem,
FILE *  infofp 
)

SUNDIALS_EXPORT int KINSetInfoHandlerFn ( void *  kinmem,
KINInfoHandlerFn  ihfun,
void *  ih_data 
)

SUNDIALS_EXPORT int KINSetMaxBetaFails ( void *  kinmem,
long int  mxnbcf 
)

SUNDIALS_EXPORT int KINSetMaxNewtonStep ( void *  kinmem,
realtype  mxnewtstep 
)

SUNDIALS_EXPORT int KINSetMaxSetupCalls ( void *  kinmem,
long int  msbset 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetMaxSubSetupCalls ( void *  kinmem,
long int  msbsetsub 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetNoInitSetup ( void *  kinmem,
booleantype  noInitSetup 
)

SUNDIALS_EXPORT int KINSetNoMinEps ( void *  kinmem,
booleantype  noMinEps 
)

SUNDIALS_EXPORT int KINSetNoResMon ( void *  kinmem,
booleantype  noNNIResMon 
)

SUNDIALS_EXPORT int KINSetNumMaxIters ( void *  kinmem,
long int  mxiter 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetPrintLevel ( void *  kinmemm,
int  printfl 
)

SUNDIALS_EXPORT int KINSetRelErrFunc ( void *  kinmem,
realtype  relfunc 
)

SUNDIALS_EXPORT int KINSetResMonConstValue ( void *  kinmem,
realtype  omegaconst 
)

SUNDIALS_EXPORT int KINSetResMonParams ( void *  kinmem,
realtype  omegamin,
realtype  omegamax 
)

SUNDIALS_EXPORT int KINSetScaledStepTol ( void *  kinmem,
realtype  scsteptol 
)

Referenced by main().

SUNDIALS_EXPORT int KINSetSysFunc ( void *  kinmem,
KINSysFn  func 
)

SUNDIALS_EXPORT int KINSol ( void *  kinmem,
N_Vector  uu,
int  strategy,
N_Vector  u_scale,
N_Vector  f_scale 
)

Referenced by main().


Generated on Fri Sep 26 07:44:21 2008 for SimTKcore by  doxygen 1.5.6