/[escript]/trunk/paso/src/solve.c
ViewVC logotype

Diff of /trunk/paso/src/solve.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1028 by gross, Wed Mar 14 00:15:24 2007 UTC revision 1312 by ksteube, Mon Sep 24 06:18:44 2007 UTC
# Line 1  Line 1 
 /* $Id$ */  
1    
2    /* $Id$ */
3    
4  /*  /*******************************************************
5  ********************************************************************************   *
6  *               Copyright   2006 by ACcESS MNRF                                *   *           Copyright 2003-2007 by ACceSS MNRF
7  *                                                                              *   *       Copyright 2007 by University of Queensland
8  *                 http://www.access.edu.au                                     *   *
9  *           Primary Business: Queensland, Australia                            *   *                http://esscc.uq.edu.au
10  *     Licensed under the Open Software License version 3.0             *   *        Primary Business: Queensland, Australia
11  *        http://www.opensource.org/licenses/osl-3.0.php                        *   *  Licensed under the Open Software License version 3.0
12  ********************************************************************************   *     http://www.opensource.org/licenses/osl-3.0.php
13  */   *
14     *******************************************************/
15    
16  /**************************************************************/  /**************************************************************/
17    
# Line 45  void Paso_solve(Paso_SystemMatrix* A, Line 46  void Paso_solve(Paso_SystemMatrix* A,
46                                 double* out,                                 double* out,
47                                 double* in,                                 double* in,
48                                 Paso_Options* options) {                                 Paso_Options* options) {
49    
50    Paso_Performance pp;    Paso_Performance pp;
51    index_t package;    index_t package;
52    Paso_resetError();    Paso_resetError();
53    if (A->num_rows!=A->num_cols || A->col_block_size!=A->row_block_size) {    if (Paso_SystemMatrix_getGlobalNumCols(A) != Paso_SystemMatrix_getGlobalNumRows(A)
54                    || A->col_block_size!=A->row_block_size) {
55         Paso_setError(VALUE_ERROR,"Paso_solve: matrix has to be a square matrix.");         Paso_setError(VALUE_ERROR,"Paso_solve: matrix has to be a square matrix.");
56         return;         return;
57    }    }
# Line 64  void Paso_solve(Paso_SystemMatrix* A, Line 67  void Paso_solve(Paso_SystemMatrix* A,
67    
68          #ifdef SCSL          #ifdef SCSL
69          case PASO_SCSL:          case PASO_SCSL:
70              if (A->mpi_info->size>1) {
71                  Paso_setError(VALUE_ERROR,"Paso_solve: SCSL package does not support MPI.");
72                  return;
73              }
74            Paso_SCSL(A,out,in,options,&pp);            Paso_SCSL(A,out,in,options,&pp);
75            A->solver_package=PASO_SCSL;            A->solver_package=PASO_SCSL;
76            break;            break;
# Line 72  void Paso_solve(Paso_SystemMatrix* A, Line 79  void Paso_solve(Paso_SystemMatrix* A,
79        
80          #ifdef MKL          #ifdef MKL
81          case PASO_MKL:          case PASO_MKL:
82              if (A->mpi_info->size>1) {
83                  Paso_setError(VALUE_ERROR,"Paso_solve: MKL package does not support MPI.");
84                  return;
85              }
86            Paso_MKL(A,out,in,options,&pp);            Paso_MKL(A,out,in,options,&pp);
87            A->solver_package=PASO_MKL;            A->solver_package=PASO_MKL;
88            break;            break;
# Line 79  void Paso_solve(Paso_SystemMatrix* A, Line 90  void Paso_solve(Paso_SystemMatrix* A,
90    
91          #ifdef UMFPACK          #ifdef UMFPACK
92          case PASO_UMFPACK:          case PASO_UMFPACK:
93              if (A->mpi_info->size>1) {
94                  Paso_setError(VALUE_ERROR,"Paso_solve: UMFPACK package does not support MPI.");
95                  return;
96              }
97            Paso_UMFPACK(A,out,in,options,&pp);            Paso_UMFPACK(A,out,in,options,&pp);
98            A->solver_package=PASO_UMFPACK;            A->solver_package=PASO_UMFPACK;
99            break;            break;
# Line 121  void Paso_solve_free(Paso_SystemMatrix* Line 136  void Paso_solve_free(Paso_SystemMatrix*
136            Paso_UMFPACK_free(in);            Paso_UMFPACK_free(in);
137            break;            break;
138          #endif          #endif
139    
140     }     }
141  }  }
 /*  
  * $Log$  
  * Revision 1.2  2005/09/15 03:44:39  jgs  
  * Merge of development branch dev-02 back to main trunk on 2005-09-15  
  *  
  * Revision 1.1.2.2  2005/09/07 00:59:08  gross  
  * some inconsistent renaming fixed to make the linking work.  
  *  
  * Revision 1.1.2.1  2005/09/05 06:29:49  gross  
  * These files have been extracted from finley to define a stand alone libray for iterative  
  * linear solvers on the ALTIX. main entry through Paso_solve. this version compiles but  
  * has not been tested yet.  
  *  
  *  
  */  

Legend:
Removed from v.1028  
changed lines
  Added in v.1312

  ViewVC Help
Powered by ViewVC 1.1.26