00001 /* 00002 * ----------------------------------------------------------------- 00003 * $Revision: 1.3 $ 00004 * $Date: 2006/11/29 00:05:07 $ 00005 * ----------------------------------------------------------------- 00006 * Programmer: Radu Serban @ LLNL 00007 * ----------------------------------------------------------------- 00008 * Copyright (c) 2006, The Regents of the University of California. 00009 * Produced at the Lawrence Livermore National Laboratory. 00010 * All rights reserved. 00011 * For details, see the LICENSE file. 00012 * ----------------------------------------------------------------- 00013 * Header file for the KINSOL dense linear solver KINLAPACK. 00014 * ----------------------------------------------------------------- 00015 */ 00016 00017 #ifndef _KINLAPACK_H 00018 #define _KINLAPACK_H 00019 00020 #ifdef __cplusplus /* wrapper to enable C++ usage */ 00021 extern "C" { 00022 #endif 00023 00024 #include <kinsol/kinsol_direct.h> 00025 #include <sundials/sundials_lapack.h> 00026 00027 /* 00028 * ================================================================= 00029 * E X P O R T E D F U N C T I O N S 00030 * ================================================================= 00031 */ 00032 00033 /* 00034 * ----------------------------------------------------------------- 00035 * Function : KINLapackDense 00036 * ----------------------------------------------------------------- 00037 * A call to the KINLapackDense function links the main solver 00038 * with the KINLAPACK linear solver using dense Jacobians. 00039 * 00040 * kinmem is the pointer to the solver memory returned by KINCreate. 00041 * 00042 * N is the size of the ODE system. 00043 * 00044 * The return value of KINLapackDense is one of: 00045 * KINDIRECT_SUCCESS if successful 00046 * KINDIRECT_MEM_NULL if the KINSOL memory was NULL 00047 * KINDIRECT_MEM_FAIL if there was a memory allocation failure 00048 * KINDIRECT_ILL_INPUT if a required vector operation is missing 00049 * ----------------------------------------------------------------- 00050 */ 00051 00052 SUNDIALS_EXPORT int KINLapackDense(void *kinmem, int N); 00053 00054 /* 00055 * ----------------------------------------------------------------- 00056 * Function : KINLapackBand 00057 * ----------------------------------------------------------------- 00058 * A call to the KINLapackBand function links the main solver 00059 * with the KINLAPACK linear solver using banded Jacobians. 00060 * 00061 * kinmem is the pointer to the solver memory returned by KINCreate. 00062 * 00063 * N is the size of the ODE system. 00064 * 00065 * mupper is the upper bandwidth of the band Jacobian approximation. 00066 * 00067 * mlower is the lower bandwidth of the band Jacobian approximation. 00068 * 00069 * The return value of KINLapackBand is one of: 00070 * KINDIRECT_SUCCESS if successful 00071 * KINDIRECT_MEM_NULL if the KINSOL memory was NULL 00072 * KINDIRECT_MEM_FAIL if there was a memory allocation failure 00073 * KINDIRECT_ILL_INPUT if a required vector operation is missing 00074 * or if a bandwidth has an illegal value. 00075 * ----------------------------------------------------------------- 00076 */ 00077 00078 SUNDIALS_EXPORT int KINLapackBand(void *kinmem, int N, int mupper, int mlower); 00079 00080 #ifdef __cplusplus 00081 } 00082 #endif 00083 00084 #endif