Ignore:
Timestamp:
Apr 10, 2012, 1:55:49 PM (14 years ago)
Author:
Julian Iseringhausen <isering@…>
Children:
a40eea
Parents:
d24c2f
Message:

Merge recent changes of the vmg library into ScaFaCos.

Includes a fix for the communication problems on Jugene.

git-svn-id: https://svn.version.fz-juelich.de/scafacos/trunk@1666 5161e1c8-67bf-11de-9fd5-51895aff932f

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/solver/solver.hpp

    rd24c2f rac6d04  
    2020#include "mg.hpp"
    2121
    22 namespace VMGTests
    23 {
    24 class SolverTestSuite;
    25 }
    26 
    2722namespace VMG
    2823{
     
    3126{
    3227public:
    33   friend class VMGTests::SolverTestSuite;
    34 
    3528  Solver()
    3629  {
    3730    size = 0;
     31  }
     32
     33  Solver(int size) :
     34    size(size)
     35  {
     36    this->Realloc(size);
    3837  }
    3938
     
    4443  void Run(Grid& sol, Grid& rhs);
    4544
    46 private:
    47 
    48   virtual void Compute() = 0; ///< Solves the system of equations
    49   virtual void AssembleMatrix(const Grid& rhs) = 0; ///< Assembles all matrices and vectors.
    50   virtual void ExportSol(Grid& sol, Grid& rhs) = 0; ///< Exports the solution back to a given mesh.
    51 
    52   std::vector<vmg_float> A, b, x;
    53   int size;
    54 
    55 protected:
    5645  void Realloc(int n);
    5746  void Realloc(Grid& x);
     
    7362
    7463  const int& Size() const {return size;}
     64
     65protected:
     66  virtual void Compute() = 0; ///< Solves the system of equations
     67
     68private:
     69  virtual void AssembleMatrix(const Grid& rhs) = 0; ///< Assembles all matrices and vectors.
     70  virtual void ExportSol(Grid& sol, Grid& rhs) = 0; ///< Exports the solution back to a given mesh.
     71
     72  std::vector<vmg_float> A, b, x;
     73  int size;
    7574};
    7675
Note: See TracChangeset for help on using the changeset viewer.