Neko  0.8.1
A portable framework for high-order spectral element flow simulations
cg Module Reference

Defines various Conjugate Gradient methods. More...

Data Types

type  cg_t
 Standard preconditioned conjugate gradient method. More...
 

Functions/Subroutines

subroutine cg_init (this, n, max_iter, M, rel_tol, abs_tol)
 Initialise a standard PCG solver. More...
 
subroutine cg_free (this)
 Deallocate a standard PCG solver. More...
 
type(ksp_monitor_t) function cg_solve (this, Ax, x, f, n, coef, blst, gs_h, niter)
 Standard PCG solve. More...
 
subroutine second_cg_part (rtr, r, mult, w, alpha, n)
 

Variables

integer, parameter cg_p_space = 7
 

Detailed Description

Defines various Conjugate Gradient methods.

Function/Subroutine Documentation

◆ cg_free()

subroutine cg::cg_free ( class(cg_t), intent(inout)  this)
private

Deallocate a standard PCG solver.

Definition at line 99 of file cg.f90.

◆ cg_init()

subroutine cg::cg_init ( class(cg_t), intent(inout), target  this,
integer, intent(in)  n,
integer, intent(in)  max_iter,
class(pc_t), intent(inout), optional, target  M,
real(kind=rp), intent(inout), optional  rel_tol,
real(kind=rp), intent(inout), optional  abs_tol 
)

Initialise a standard PCG solver.

Definition at line 66 of file cg.f90.

◆ cg_solve()

type(ksp_monitor_t) function cg::cg_solve ( class(cg_t), intent(inout)  this,
class(ax_t), intent(inout)  Ax,
type(field_t), intent(inout)  x,
real(kind=rp), dimension(n), intent(inout)  f,
integer, intent(in)  n,
type(coef_t), intent(inout)  coef,
type(bc_list_t), intent(inout)  blst,
type(gs_t), intent(inout)  gs_h,
integer, intent(in), optional  niter 
)
private

Standard PCG solve.

Definition at line 129 of file cg.f90.

Here is the call graph for this function:

◆ second_cg_part()

subroutine cg::second_cg_part ( real(kind=rp), intent(inout)  rtr,
real(kind=rp), dimension(n), intent(inout)  r,
real(kind=rp), dimension(n), intent(in)  mult,
real(kind=rp), dimension(n), intent(in)  w,
real(kind=rp), intent(in)  alpha,
integer, intent(in)  n 
)
private

Definition at line 228 of file cg.f90.

Here is the caller graph for this function:

Variable Documentation

◆ cg_p_space

integer, parameter cg::cg_p_space = 7
private

Definition at line 48 of file cg.f90.