# 6.3.2. Tpetra Solvers

## 6.3.2.1. Klu2 Solver

Scope

  Tpetra Equation Solver

Summary

  Use a KLU2 direct solver.

    begin Klu2 Solver

    end Klu2 Solver

## 6.3.2.2. Superlu Solver

Scope

  Tpetra Equation Solver

Summary

  Use a SUPERLU direct solver.

    begin Superlu Solver

    end Superlu Solver

## 6.3.2.3. Umfpack Solver

Scope

  Tpetra Equation Solver

Summary

  Use a UMFPACK direct solver.

    begin Umfpack Solver

    end Umfpack Solver

## 6.3.2.4. Cg Solver

Scope

  Tpetra Equation Solver

Summary

  Use a conjugate gradient solver.

    begin Cg Solver

       Convergence Tolerance {=} value [ Minimum = tolerance_floor  ]

       Maximum Iterations {=} value

       Residual Output {=} [ {disabled | enabled}  ]

       Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

       begin Dd-Ilu Preconditioner
       end

       begin Dd-Ilut Preconditioner
       end

       begin Dd-Parilut Preconditioner
       end

       begin Expert Ifpack2 Preconditioner
       end

       begin Expert Teko Preconditioner
       end

       begin Fastilu Preconditioner
       end

       begin Jacobi Preconditioner
       end

       begin Muelu Preconditioner
       end

       begin Sgs Preconditioner
       end

       begin Sgs2 Preconditioner
       end

    end Cg Solver

### 6.3.2.4.1. Line Commands

###### Convergence Tolerance

Syntax

  Convergence Tolerance {=} value [ Minimum = tolerance_floor ]

Summary

  Set the convergence tolerance for the linear solver. Setting CONVERGENCE TOLERANCE = AUTOMATIC enables an autonomous linear convergence tolerance calculation, which is computed from a combination of the initial linear residual and user-specified nonlinear residual tolerance. An additional floor value on the linear convergence tolerance can be declared with CONVERGENCE TOLERANCE = AUTOMATIC MINIMUM = <val>, where the default floor value is 1.0e-6

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | string | –

###### Maximum Iterations

Syntax

  Maximum Iterations {=} value

Summary

  Set the maximum number of iterations taken by the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 300

###### Residual Output

Syntax

  Residual Output {=} [ {disabled | enabled} ]

Summary

  Output the residuals for every linear solve to the logfile.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –

###### Residual Scaling

Syntax

  Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

Summary

  Set the residual scaling for the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | {none | preconditioned_r0 | r0 | rhs} | r0

## 6.3.2.5. Bicgstab Solver

Scope

  Tpetra Equation Solver

Summary

  Use a bicgstab solver.

    begin Bicgstab Solver

       Convergence Tolerance {=} value [ Minimum = tolerance_floor  ]

       Maximum Iterations {=} value

       Residual Output {=} [ {disabled | enabled}  ]

       Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

       begin Dd-Ilu Preconditioner
       end

       begin Dd-Ilut Preconditioner
       end

       begin Dd-Parilut Preconditioner
       end

       begin Expert Ifpack2 Preconditioner
       end

       begin Expert Teko Preconditioner
       end

       begin Fastilu Preconditioner
       end

       begin Jacobi Preconditioner
       end

       begin Muelu Preconditioner
       end

       begin Sgs Preconditioner
       end

       begin Sgs2 Preconditioner
       end

    end Bicgstab Solver

### 6.3.2.5.1. Line Commands

###### Convergence Tolerance

Syntax

  Convergence Tolerance {=} value [ Minimum = tolerance_floor ]

Summary

  Set the convergence tolerance for the linear solver. Setting CONVERGENCE TOLERANCE = AUTOMATIC enables an autonomous linear convergence tolerance calculation, which is computed from a combination of the initial linear residual and user-specified nonlinear residual tolerance. An additional floor value on the linear convergence tolerance can be declared with CONVERGENCE TOLERANCE = AUTOMATIC MINIMUM = <val>, where the default floor value is 1.0e-6

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | string | –

###### Maximum Iterations

Syntax

  Maximum Iterations {=} value

Summary

  Set the maximum number of iterations taken by the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 300

###### Residual Output

Syntax

  Residual Output {=} [ {disabled | enabled} ]

Summary

  Output the residuals for every linear solve to the logfile.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –

###### Residual Scaling

Syntax

  Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

Summary

  Set the residual scaling for the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | {none | preconditioned_r0 | r0 | rhs} | r0

## 6.3.2.6. Gmres Solver

Scope

  Tpetra Equation Solver

Summary

  Use a GMRES solver.

    begin Gmres Solver

       Convergence Tolerance {=} value [ Minimum = tolerance_floor  ]

       Maximum Iterations {=} value

       Residual Output {=} [ {disabled | enabled}  ]

       Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

       Restart Iterations {=} value

       begin Dd-Ilu Preconditioner
       end

       begin Dd-Ilut Preconditioner
       end

       begin Dd-Parilut Preconditioner
       end

       begin Expert Ifpack2 Preconditioner
       end

       begin Expert Teko Preconditioner
       end

       begin Fastilu Preconditioner
       end

       begin Jacobi Preconditioner
       end

       begin Muelu Preconditioner
       end

       begin Sgs Preconditioner
       end

       begin Sgs2 Preconditioner
       end

    end Gmres Solver

### 6.3.2.6.1. Line Commands

###### Convergence Tolerance

Syntax

  Convergence Tolerance {=} value [ Minimum = tolerance_floor ]

Summary

  Set the convergence tolerance for the linear solver. Setting CONVERGENCE TOLERANCE = AUTOMATIC enables an autonomous linear convergence tolerance calculation, which is computed from a combination of the initial linear residual and user-specified nonlinear residual tolerance. An additional floor value on the linear convergence tolerance can be declared with CONVERGENCE TOLERANCE = AUTOMATIC MINIMUM = <val>, where the default floor value is 1.0e-6

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | string | –

###### Maximum Iterations

Syntax

  Maximum Iterations {=} value

Summary

  Set the maximum number of iterations taken by the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 300

###### Residual Output

Syntax

  Residual Output {=} [ {disabled | enabled} ]

Summary

  Output the residuals for every linear solve to the logfile.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –

###### Residual Scaling

Syntax

  Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

Summary

  Set the residual scaling for the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | {none | preconditioned_r0 | r0 | rhs} | r0

###### Restart Iterations

Syntax

  Restart Iterations {=} value

Summary

  Set the number of iterations between GMRES restarts.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 30

## 6.3.2.7. Poly Solver

Scope

  Tpetra Equation Solver

Summary

  Use a poly solver.

    begin Poly Solver

       Convergence Tolerance {=} value [ Minimum = tolerance_floor  ]

       Maximum Iterations {=} value

       Polynomial Order {=} value

       Residual Output {=} [ {disabled | enabled}  ]

       Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

       Restart Iterations {=} value

       begin Dd-Ilu Preconditioner
       end

       begin Dd-Ilut Preconditioner
       end

       begin Dd-Parilut Preconditioner
       end

       begin Expert Ifpack2 Preconditioner
       end

       begin Expert Teko Preconditioner
       end

       begin Fastilu Preconditioner
       end

       begin Jacobi Preconditioner
       end

       begin Muelu Preconditioner
       end

       begin Sgs Preconditioner
       end

       begin Sgs2 Preconditioner
       end

    end Poly Solver

### 6.3.2.7.1. Line Commands

###### Convergence Tolerance

Syntax

  Convergence Tolerance {=} value [ Minimum = tolerance_floor ]

Summary

  Set the convergence tolerance for the linear solver. Setting CONVERGENCE TOLERANCE = AUTOMATIC enables an autonomous linear convergence tolerance calculation, which is computed from a combination of the initial linear residual and user-specified nonlinear residual tolerance. An additional floor value on the linear convergence tolerance can be declared with CONVERGENCE TOLERANCE = AUTOMATIC MINIMUM = <val>, where the default floor value is 1.0e-6

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | string | –

###### Maximum Iterations

Syntax

  Maximum Iterations {=} value

Summary

  Set the maximum number of iterations taken by the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 300

###### Polynomial Order

Syntax

  Polynomial Order {=} value

Summary

  Set the polynomial order of polynomial preconditioner.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 5

###### Residual Output

Syntax

  Residual Output {=} [ {disabled | enabled} ]

Summary

  Output the residuals for every linear solve to the logfile.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –

###### Residual Scaling

Syntax

  Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

Summary

  Set the residual scaling for the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | {none | preconditioned_r0 | r0 | rhs} | r0

###### Restart Iterations

Syntax

  Restart Iterations {=} value

Summary

  Set the number of iterations between GMRES restarts.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 30

## 6.3.2.8. Gcrodr Solver

Scope

  Tpetra Equation Solver

Summary

  Use a GCRODR solver.

    begin Gcrodr Solver

       Convergence Tolerance {=} value [ Minimum = tolerance_floor  ]

       Maximum Iterations {=} value

       Recycled Blocks {=} value

       Residual Output {=} [ {disabled | enabled}  ]

       Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

       Restart Iterations {=} value

       begin Dd-Ilu Preconditioner
       end

       begin Dd-Ilut Preconditioner
       end

       begin Dd-Parilut Preconditioner
       end

       begin Expert Ifpack2 Preconditioner
       end

       begin Expert Teko Preconditioner
       end

       begin Fastilu Preconditioner
       end

       begin Jacobi Preconditioner
       end

       begin Muelu Preconditioner
       end

       begin Sgs Preconditioner
       end

       begin Sgs2 Preconditioner
       end

    end Gcrodr Solver

### 6.3.2.8.1. Line Commands

###### Convergence Tolerance

Syntax

  Convergence Tolerance {=} value [ Minimum = tolerance_floor ]

Summary

  Set the convergence tolerance for the linear solver. Setting CONVERGENCE TOLERANCE = AUTOMATIC enables an autonomous linear convergence tolerance calculation, which is computed from a combination of the initial linear residual and user-specified nonlinear residual tolerance. An additional floor value on the linear convergence tolerance can be declared with CONVERGENCE TOLERANCE = AUTOMATIC MINIMUM = <val>, where the default floor value is 1.0e-6

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | string | –

###### Maximum Iterations

Syntax

  Maximum Iterations {=} value

Summary

  Set the maximum number of iterations taken by the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 300

###### Recycled Blocks

Syntax

  Recycled Blocks {=} value

Summary

  Set the number of recycle blocks in GCRODR.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 5

###### Residual Output

Syntax

  Residual Output {=} [ {disabled | enabled} ]

Summary

  Output the residuals for every linear solve to the logfile.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –

###### Residual Scaling

Syntax

  Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

Summary

  Set the residual scaling for the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | {none | preconditioned_r0 | r0 | rhs} | r0

###### Restart Iterations

Syntax

  Restart Iterations {=} value

Summary

  Set the number of iterations between GCRODR restarts.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 30

## 6.3.2.9. Expert Belos Solver

Scope

  Tpetra Equation Solver

Summary

  Use a Belos solver with parameters specified in an XML file.

    begin Expert Belos Solver

       Xml File {=} value

       begin Dd-Ilu Preconditioner
       end

       begin Dd-Ilut Preconditioner
       end

       begin Dd-Parilut Preconditioner
       end

       begin Expert Ifpack2 Preconditioner
       end

       begin Expert Teko Preconditioner
       end

       begin Fastilu Preconditioner
       end

       begin Jacobi Preconditioner
       end

       begin Muelu Preconditioner
       end

       begin Sgs Preconditioner
       end

       begin Sgs2 Preconditioner
       end

    end Expert Belos Solver

### 6.3.2.9.1. Line Commands

###### Xml File

Syntax

  Xml File {=} value

Summary

  Supply the name of an XML file containing a Belos parameter list.

Description

  The supplied XML file must contain a ParameterList with a “solution method” string parameter corresponding to the desired type of Belos solver. Any additional parameters that should be passed on to Belos should be part of a nested ParameterList with name=”Belos-Tpetra”.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | string | –

## 6.3.2.10. Preset Solver

Scope

  Tpetra Equation Solver

Summary

  Use a preset solver for a specific linear system type.

Description

  The preset solver for a given linear system type is intended to provide reasonable behavior for many problems of that type. If this proves to be insufficient, the user must provide more fine-grained control over solver settings. The equivalent command which produces the solver will be output to the log file, and this may be used as a starting point from which changes for robustness may be made (i.e. increasing GMRES subspace size or changing the preconditioner).

    begin Preset Solver

       Convergence Tolerance {=} value [ Minimum = tolerance_floor  ]

       Maximum Iterations {=} value

       Residual Output {=} [ {disabled | enabled}  ]

       Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

       Solver Type {=} {continuity | multiphysics | scalar_transport | thermal | thermal_bicgstab | thermal_symmetric}

    end Preset Solver

### 6.3.2.10.1. Line Commands

###### Convergence Tolerance

Syntax

  Convergence Tolerance {=} value [ Minimum = tolerance_floor ]

Summary

  Set the convergence tolerance for the linear solver. Setting CONVERGENCE TOLERANCE = AUTOMATIC enables an autonomous linear convergence tolerance calculation, which is computed from a combination of the initial linear residual and user-specified nonlinear residual tolerance. An additional floor value on the linear convergence tolerance can be declared with CONVERGENCE TOLERANCE = AUTOMATIC MINIMUM = <val>, where the default floor value is 1.0e-6

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | string | –

###### Maximum Iterations

Syntax

  Maximum Iterations {=} value

Summary

  Set the maximum number of iterations taken by the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | integer | 300

###### Residual Output

Syntax

  Residual Output {=} [ {disabled | enabled} ]

Summary

  Output the residuals for every linear solve to the logfile.

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –

###### Residual Scaling

Syntax

  Residual Scaling {=} {none | preconditioned_r0 | r0 | rhs}

Summary

  Set the residual scaling for the linear solver

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | {none | preconditioned_r0 | r0 | rhs} | r0

###### Solver Type

Syntax

  Solver Type {=} {continuity | multiphysics | scalar_transport | thermal | thermal_bicgstab | thermal_symmetric}

Summary

  Set the preset solver type

Parameter | Value | Default
--- | --- | ---
{=} | {= | are | is} | –
value | {continuity | multiphysics | scalar_transport | thermal | thermal_bicgstab | thermal_symmetric} | –