ddx 0.6.0
Libary for domain-decomposition methods for polarizable continuum models
Fortran interface: ddlpb

Functions/Subroutines

subroutine ddx_lpb::lpb_setup (params, constants, workspace, state, phi_cav, e_cav, psi, ddx_error)
 Given the potential and the electric field at the cavity points, assemble the RHS for ddLPB. More...
 
subroutine ddx_lpb::lpb_energy (constants, state, esolv, ddx_error)
 Compute the ddLPB energy. More...
 
subroutine ddx_lpb::lpb_guess (params, constants, workspace, state, tol, ddx_error)
 Do a guess for the primal ddLPB linear system. More...
 
subroutine ddx_lpb::lpb_guess_adjoint (params, constants, workspace, state, tol, ddx_error)
 Do a guess for the adjoint ddLPB linear system. More...
 
subroutine ddx_lpb::lpb_solve (params, constants, workspace, state, tol, ddx_error)
 Solve the ddLPB primal linear system. More...
 
subroutine ddx_lpb::lpb_solve_adjoint (params, constants, workspace, state, tol, ddx_error)
 Solve the adjoint ddLPB linear system. More...
 
subroutine ddx_lpb::lpb_solvation_force_terms (params, constants, workspace, state, hessianphi_cav, force, ddx_error)
 Compute the solvation terms of the forces (solute aspecific). This must be summed to the solute specific term to get the full forces. More...
 

Detailed Description

Function/Subroutine Documentation

◆ lpb_setup()

subroutine ddx_lpb::lpb_setup ( type(ddx_params_type), intent(in)  params,
type(ddx_constants_type), intent(inout)  constants,
type(ddx_workspace_type), intent(inout)  workspace,
type(ddx_state_type), intent(inout)  state,
real(dp), dimension(constants % ncav), intent(in)  phi_cav,
real(dp), dimension(3, constants % ncav), intent(in)  e_cav,
real(dp), dimension(constants % nbasis, params % nsph), intent(in)  psi,
type(ddx_error_type), intent(inout)  ddx_error 
)

Given the potential and the electric field at the cavity points, assemble the RHS for ddLPB.

Parameters
[in]paramsddx parameters
[in]constantsddx constants
[in,out]workspaceddx workspace
[in,out]stateddx state
[in]phi_cavelectrostatic potential at the cavity points
[in]e_cavelectrostatic field at the cavity points
[in]psirepresentation of the solute density
[in,out]ddx_errorddX error

Definition at line 35 of file ddx_lpb.f90.

◆ lpb_energy()

subroutine ddx_lpb::lpb_energy ( type(ddx_constants_type), intent(in)  constants,
type(ddx_state_type), intent(in)  state,
real(dp), intent(out)  esolv,
type(ddx_error_type), intent(inout)  ddx_error 
)

Compute the ddLPB energy.

Parameters
[in]constantsPrecomputed constants
[in]stateddx state (contains solutions and RHSs)
[out]esolvresulting energy
[in,out]ddx_errorddX error

Definition at line 103 of file ddx_lpb.f90.

◆ lpb_guess()

subroutine ddx_lpb::lpb_guess ( type(ddx_params_type), intent(in)  params,
type(ddx_constants_type), intent(inout)  constants,
type(ddx_workspace_type), intent(inout)  workspace,
type(ddx_state_type), intent(inout)  state,
real(dp), intent(in)  tol,
type(ddx_error_type), intent(inout)  ddx_error 
)

Do a guess for the primal ddLPB linear system.

Parameters
[in]paramsUser specified parameters
[in,out]constantsPrecomputed constants
[in,out]workspacePreallocated workspaces
[in,out]stateddx state (contains solutions and RHSs)
[in]toltolerance
[in,out]ddx_errorddX error

Definition at line 127 of file ddx_lpb.f90.

◆ lpb_guess_adjoint()

subroutine ddx_lpb::lpb_guess_adjoint ( type(ddx_params_type), intent(in)  params,
type(ddx_constants_type), intent(inout)  constants,
type(ddx_workspace_type), intent(inout)  workspace,
type(ddx_state_type), intent(inout)  state,
real(dp), intent(in)  tol,
type(ddx_error_type), intent(inout)  ddx_error 
)

Do a guess for the adjoint ddLPB linear system.

Parameters
[in]paramsUser specified parameters
[in]constantsPrecomputed constants
[in,out]workspacePreallocated workspaces
[in,out]stateddx state (contains solutions and RHSs)
[in]toltolerance
[in,out]ddx_errorddX error

Definition at line 157 of file ddx_lpb.f90.

◆ lpb_solve()

subroutine ddx_lpb::lpb_solve ( type(ddx_params_type), intent(in)  params,
type(ddx_constants_type), intent(inout)  constants,
type(ddx_workspace_type), intent(inout)  workspace,
type(ddx_state_type), intent(inout)  state,
real(dp), intent(in)  tol,
type(ddx_error_type), intent(inout)  ddx_error 
)

Solve the ddLPB primal linear system.

Parameters
[in]params: General options
[in]constants: Precomputed constants
[in,out]workspace: Preallocated workspaces
[in,out]state: Solutions, guesses and relevant quantities
[in]tol: Tolerance for the iterative solvers
[in,out]ddx_errorddX error

Definition at line 188 of file ddx_lpb.f90.

◆ lpb_solve_adjoint()

subroutine ddx_lpb::lpb_solve_adjoint ( type(ddx_params_type), intent(in)  params,
type(ddx_constants_type), intent(inout)  constants,
type(ddx_workspace_type), intent(inout)  workspace,
type(ddx_state_type), intent(inout)  state,
real(dp), intent(in)  tol,
type(ddx_error_type), intent(inout)  ddx_error 
)

Solve the adjoint ddLPB linear system.

Parameters
[in]params: General options
[in]constants: Precomputed constants
[in,out]workspace: Preallocated workspaces
[in,out]state: Solutions, guesses and relevant quantities
[in]tol: Tolerance for the iterative solvers
[in,out]ddx_errorddX error

Definition at line 236 of file ddx_lpb.f90.

◆ lpb_solvation_force_terms()

subroutine ddx_lpb::lpb_solvation_force_terms ( type(ddx_params_type), intent(in)  params,
type(ddx_constants_type), intent(in)  constants,
type(ddx_workspace_type), intent(inout)  workspace,
type(ddx_state_type), intent(inout)  state,
real(dp), dimension(3, 3, constants % ncav), intent(in)  hessianphi_cav,
real(dp), dimension(3, params % nsph), intent(out)  force,
type(ddx_error_type), intent(inout)  ddx_error 
)

Compute the solvation terms of the forces (solute aspecific). This must be summed to the solute specific term to get the full forces.

Parameters
[in]params: General options
[in]constants: Precomputed constants
[in,out]workspace: Preallocated workspaces
[in,out]state: Solutions and relevant quantities
[in]hessianphi_cav: Electric field gradient at the grid points
[out]force: Geometrical contribution to the forces
[in,out]ddx_errorddX error

Definition at line 286 of file ddx_lpb.f90.