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

Exposed ddpcm modules in the Fortran API. More...

Functions/Subroutines

subroutine ddx_legacy::ddpcm (params, constants, workspace, state, phi_cav, psi, e_cav, tol, esolv, force, ddx_error)
 ddPCM solver More...
 
subroutine ddx_pcm::pcm_energy (constants, state, esolv, ddx_error)
 Compute the ddPCM energy. More...
 
subroutine ddx_pcm::pcm_setup (params, constants, workspace, state, phi_cav, psi, ddx_error)
 Given the potential at the cavity points, assemble the RHS for ddCOSMO or for ddPCM. More...
 
subroutine ddx_pcm::pcm_guess (params, constants, workspace, state, ddx_error)
 Do a guess for the primal ddPCM linear system. More...
 
subroutine ddx_pcm::pcm_guess_adjoint (params, constants, workspace, state, ddx_error)
 Do a guess for the adjoint ddPCM linear system. More...
 
subroutine ddx_pcm::pcm_solve (params, constants, workspace, state, tol, ddx_error)
 Solve the ddPCM primal linear system. More...
 
subroutine ddx_pcm::pcm_solve_adjoint (params, constants, workspace, state, tol, ddx_error)
 Solve the ddPCM adjpint linear system. More...
 
subroutine ddx_pcm::pcm_solvation_force_terms (params, constants, workspace, state, e_cav, force, ddx_error)
 Compute the solvation contribution to the ddPCM forces. More...
 

Detailed Description

Exposed ddpcm modules in the Fortran API.

Function/Subroutine Documentation

◆ ddpcm()

subroutine ddx_legacy::ddpcm ( 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(constants % ncav), intent(in)  phi_cav,
real(dp), dimension(constants % nbasis, params % nsph), intent(in)  psi,
real(dp), dimension(3, constants % ncav), intent(in)  e_cav,
real(dp), intent(in)  tol,
real(dp), intent(out)  esolv,
real(dp), dimension(3, params % nsph), intent(out), optional  force,
type(ddx_error_type), intent(inout)  ddx_error 
)

ddPCM solver

Solves the problem within PCM model using a domain decomposition approach.

Parameters
[in]paramsUser specified parameters
[in]constantsPrecomputed constants
[in,out]workspacePreallocated workspaces
[in,out]stateddx state (contains solutions and RHSs)
[in]phi_cavPotential at cavity points, size (ncav)
[in]psiRepresentation of the solute potential in spherical harmonics, size (nbasis, nsph)
[in]tolTolerance for the linear system solver
[out]esolvSolvation energy
[out]forceSolvation contribution to the forces
[in,out]ddx_errorddX error

Definition at line 420 of file ddx_legacy.f90.

◆ pcm_energy()

subroutine ddx_pcm::pcm_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 ddPCM energy.

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

Definition at line 31 of file ddx_pcm.f90.

◆ pcm_setup()

subroutine ddx_pcm::pcm_setup ( 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(constants % ncav), intent(in)  phi_cav,
real(dp), dimension(constants % nbasis, params % nsph), intent(in)  psi,
type(ddx_error_type), intent(inout)  ddx_error 
)

Given the potential at the cavity points, assemble the RHS for ddCOSMO or for ddPCM.

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

Definition at line 55 of file ddx_pcm.f90.

◆ pcm_guess()

subroutine ddx_pcm::pcm_guess ( 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,
type(ddx_error_type), intent(inout)  ddx_error 
)

Do a guess for the primal ddPCM linear system.

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

Definition at line 83 of file ddx_pcm.f90.

◆ pcm_guess_adjoint()

subroutine ddx_pcm::pcm_guess_adjoint ( 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,
type(ddx_error_type), intent(inout)  ddx_error 
)

Do a guess for the adjoint ddPCM linear system.

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

Definition at line 105 of file ddx_pcm.f90.

◆ pcm_solve()

subroutine ddx_pcm::pcm_solve ( 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), intent(in)  tol,
type(ddx_error_type), intent(inout)  ddx_error 
)

Solve the ddPCM primal linear system.

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

Definition at line 128 of file ddx_pcm.f90.

◆ pcm_solve_adjoint()

subroutine ddx_pcm::pcm_solve_adjoint ( 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), intent(in)  tol,
type(ddx_error_type), intent(inout)  ddx_error 
)

Solve the ddPCM adjpint 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 182 of file ddx_pcm.f90.

◆ pcm_solvation_force_terms()

subroutine ddx_pcm::pcm_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, constants % ncav), intent(in)  e_cav,
real(dp), dimension(3, params % nsph), intent(out)  force,
type(ddx_error_type), intent(inout)  ddx_error 
)

Compute the solvation contribution to the ddPCM forces.

Parameters
[in]params: General options
[in]constants: Precomputed constants
[in,out]workspace: Preallocated workspaces
[in,out]state: Solutions and relevant quantities
[in]e_cavelectric field, size (3, ncav)
[out]force: Geometrical contribution to the forces
[in,out]ddx_errorddX error

Definition at line 239 of file ddx_pcm.f90.