Skip to content

Some results of my research on the BiCGSTAB and GMRES methods for calculating sparse systems and fields using Fortran

License

Notifications You must be signed in to change notification settings

JNSresearcher/SOLVERS_BCGSTAB_GMRES

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 

Repository files navigation

The BiConjugate Gradient STABilization (BiCGSTAB) and Generalized Minimum RESidual (GMRES) methods for calculating linear sparse systems
of equations are presented, and the application of these methods to the calculation of three-dimensional fields is shown.

 Fortran codes are based on published algorithms:

Repository Structure

  The /SOLVERS directory contains :

  • /src
    • file SOLVERS_base.f90 contains an implementation of the BCGSTAB or GMRES methods for solving a linear sparse system: Ax = B.
    • file SOLVERS.f90 oriented on implementation of BCGSTAB or GMRES for calculating 3D fields. Explanations are given below.
    • file utilites.f90 contains subroutines for calculating the product of a sparse matrix by a vector,
      converting a matrix from full format to sparse CSR format, inverting a matrix and a subroutine for outputting
      calculation results to csv and vtk files. Paraview may be required to visualization vtk (free download: https://www.paraview.org/).
  • /example - contains example_SOLVERS_base.f90 A simple example of solve a sparse system Ax=B using GMRES or BCGSTAB methods.
    A small matrix is entered in full format, which is automatically converted to CSR format.
  • /test - contains test_SOLVERS.f90 this is a test for solving systems of equations for calculating
    three-dimensional vector fields using the BCGSTAB or GMRES methods. Here the field equations are presented
    in the format: $L(X) = B,$ where $L()$ is a linear operator corresponding to the finite-difference approximation of the PDE.
    This version uses a finite-difference approximation of the Laplace equation $L(X) = Laplacian(X)$ and
    a finite-difference approximation of the equation $L(X) = grad(div(X)) - Laplacian(X)$ (this is equivalent to $L(X)=Curl(Curl(X))$
    without using a matrix. Alternatively, for the Laplacian, on can use a sparse matrix,
    which is automatically generated to solve the equation $Ax=B$.
      All files contain comments.

About

Some results of my research on the BiCGSTAB and GMRES methods for calculating sparse systems and fields using Fortran

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published