Multigrid extension for NeuroFEM 
  last change: 04.03.2008  

New Solver

This chapter is about the implementation of the new solver itself. Here you can find documentation of the functionality:
  • Methods and member
    Here you can find a short describtion what the different methods and members are used for

  • Data transfer
    Here you can find describtions of the data transfer methods

  • Initalization methods
    Here you can find informations about the methods used in the initialization phase

  • Solving methods
    Here you can find informations about the methods used in the solving phase

  • Full Multigrid Solver
    Here you can find informations about the full multigrid solver used in this project


The complete header of the solver class reads as follows:
Code from file "fmgsolver.h"
class FMGSolver {
  FMGSolver(Grid_c& VolumeGrid_);
  void Init(int ElemPerCell_, int numUnknowns_, int numCells_, doublereal* rhs_, doublereal* sol_);
  void Solve();
  Grid_c& VolumeGrid;
  int numUnknowns;
  int ElemPerCell;
  int numCells;
  doublereal* rhs;
  doublereal* sol;
  void GetNodePosition(int NodeNumber, double* XPos, double* YPos, double* ZPos);
  int* GetCellNodes(int CellNumber);
  double maxX, maxZ, maxY, minX, minZ, minY, deltaX, deltaZ, deltaY;
  int NumCellsX, NumCellsY, NumCellsZ;
  void GetBoundingBox();
  void MapNodeToIndices(int NodeNumber, int* i, int* j, int* k);
  void MapCellToIndices(int CellNumber, int* i, int* j, int* k);
  int sizeX, sizeY, sizeZ;
  int PaddingPower2(int input);
  int number_levels;
  int points, pointsx, pointsy, pointsz;
  int cgridcorrections;
  int presmooth;
  int postsmooth;
  int precg;
  int postcg;
  double eps;
  double omega;
  int vcycle[10];
  int counter[10];
  ParExPDE::StandardFETransferOperator* transfer_operator;
  ParExPDE::ETVariable* f;
  ParExPDE::ETVariable* u;
  ParExPDE::ETVariable* r;
  ParExPDE::ETVariable* d;
  ParExPDE::ETVariable* g;
  double* normi;
  ParExPDE::Blockgrid* grid;
  ParExPDE::Discretization* disc_levels;
  ParExPDE::Partition* partition;
  ParExPDE::LSMDifferentialOperator op;
  void BuildGrids();
  void BuildMatrix();
  void InitValues();
  void SolveProblem();
  void StoreSolution();
  void ShiftSolution();
  void CGIterate(int loopcount);
  void SolveProblemTry();
};