solvers Module

Serveral GMRES-type Krylov solvers. Only applies to the (default) finest grid level


Uses

  • module~~solvers~~UsesGraph module~solvers solvers module~comm_variable comm_variable module~solvers->module~comm_variable module~cslp_solver CSLP_Solver module~solvers->module~cslp_solver module~deflaion_setup deflaion_setup module~solvers->module~deflaion_setup module~operators operators module~solvers->module~operators module~read_setup read_setup module~solvers->module~read_setup mpi mpi module~solvers->mpi module~comm_variable->mpi module~cslp_solver->module~comm_variable module~cslp_solver->module~operators module~cslp_solver->mpi module~mpi_setup mpi_setup module~cslp_solver->module~mpi_setup module~smoother smoother module~cslp_solver->module~smoother module~wavenumber wavenumber module~cslp_solver->module~wavenumber module~deflaion_setup->module~comm_variable module~deflaion_setup->module~cslp_solver module~deflaion_setup->module~operators module~deflaion_setup->mpi module~deflaion_setup->module~mpi_setup module~deflaion_setup->module~wavenumber module~operators->module~comm_variable module~operators->mpi module~define_bc define_BC module~operators->module~define_bc module~operators->module~mpi_setup module~operators->module~wavenumber module~read_setup->module~comm_variable module~read_setup->mpi module~define_bc->module~comm_variable module~define_bc->module~wavenumber module~mpi_setup->module~comm_variable module~mpi_setup->mpi module~smoother->module~comm_variable module~smoother->module~operators module~smoother->module~define_bc module~smoother->module~mpi_setup module~wavenumber->module~comm_variable module~wavenumber->mpi module~wavenumber->module~mpi_setup

Used by

  • module~~solvers~~UsedByGraph module~solvers solvers program~helmholtz_2d helmholtz_2d program~helmholtz_2d->module~solvers

Functions

public function Precond_x(x)

This is a routine to select which preconditioner is applied, Precond_x = P^(-1)x

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: x

Return Value complex(kind=realdp), (1-LAP:nx+LAP,1-LAP:ny+LAP)


Subroutines

public subroutine fullgmres(b, u, Rerror, iter)

Full GMRES without precondition

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: b
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: u
real(kind=realdp), intent(out) :: Rerror
integer, intent(inout) :: iter

public subroutine restartgmres(b, u, Rerror, iter_total)

Restart GMRES

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: b
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: u
real(kind=realdp), intent(out) :: Rerror
integer, intent(inout) :: iter_total

public subroutine Pre_fullgmres(b, u, Rerror, iter)

Full GMRES with left preconditioned

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: b
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: u
real(kind=realdp), intent(out) :: Rerror
integer, intent(inout) :: iter

public subroutine full_pgmres(b, u, Rerror, iter)

Full GMRES with right precondition

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: b
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: u
real(kind=realdp), intent(out) :: Rerror
integer, intent(inout) :: iter

public subroutine Pre_restartgmres(b, u, Rerror, iter)

Preconditioned restart GMRES

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: b
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: u
real(kind=realdp), intent(out) :: Rerror
integer, intent(inout) :: iter

public subroutine arnoldi(V, H, k)

ARNOLDI precess

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP,m_iter+1) :: V
complex(kind=realdp), intent(inout), dimension(m_iter+1,m_iter) :: H
integer, intent(in) :: k

public subroutine Prearnoldi(V, H, k)

Preconditioned ARNOLDI precess

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP,m_iter+1) :: V
complex(kind=realdp), intent(inout), dimension(m_iter+1,m_iter) :: H
integer, intent(in) :: k

public subroutine apply_givens_rotation(H, cs, sn, k)

APPLY GIVENS ROTATION

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(inout), dimension(m_iter+1,m_iter) :: H
complex(kind=realdp), intent(inout), dimension(m_iter+1) :: cs
complex(kind=realdp), intent(inout), dimension(m_iter+1) :: sn
integer, intent(in) :: k

public subroutine back_substitute(H, beta, k)

Apply BACK SUBSTITUTION

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(m_iter+1,m_iter) :: H
complex(kind=realdp), intent(inout), dimension(m_iter+1) :: beta
integer, intent(in) :: k

public subroutine full_pgcr(b, u, Rerror, iter)

Right preconditioned GCR

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: b
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: u
real(kind=realdp), intent(out) :: Rerror
integer, intent(inout) :: iter

public subroutine pfgmres(b, u, Rerror, iter)

Flexible GMRES with right precondition

Arguments

Type IntentOptional Attributes Name
complex(kind=realdp), intent(in), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: b
complex(kind=realdp), intent(inout), dimension(1-LAP:nx+LAP,1-LAP:ny+LAP) :: u
real(kind=realdp), intent(out) :: Rerror
integer, intent(inout) :: iter