yaeos__math_continuation Module

Implementation of Algower’s numerical continuation method.


Uses

  • module~~yaeos__math_continuation~~UsesGraph module~yaeos__math_continuation yaeos__math_continuation module~yaeos__constants yaeos__constants module~yaeos__math_continuation->module~yaeos__constants module~yaeos__math_linalg yaeos__math_linalg module~yaeos__math_continuation->module~yaeos__math_linalg iso_fortran_env iso_fortran_env module~yaeos__constants->iso_fortran_env module~yaeos__math_linalg->module~yaeos__constants

Used by

  • module~~yaeos__math_continuation~~UsedByGraph module~yaeos__math_continuation yaeos__math_continuation module~yaeos__equilibria_boundaries_phase_envelopes_pt yaeos__equilibria_boundaries_phase_envelopes_pt module~yaeos__equilibria_boundaries_phase_envelopes_pt->module~yaeos__math_continuation module~yaeos__equilibria_boundaries_phase_envelopes_px yaeos__equilibria_boundaries_phase_envelopes_px module~yaeos__equilibria_boundaries_phase_envelopes_px->module~yaeos__math_continuation module~yaeos__equilibria_boundaries_auxiliar yaeos__equilibria_boundaries_auxiliar module~yaeos__equilibria_boundaries_phase_envelopes_px->module~yaeos__equilibria_boundaries_auxiliar module~yaeos__equilibria_boundaries_phase_envelopes_tx yaeos__equilibria_boundaries_phase_envelopes_tx module~yaeos__equilibria_boundaries_phase_envelopes_tx->module~yaeos__math_continuation module~yaeos__equilibria_boundaries_phase_envelopes_tx->module~yaeos__equilibria_boundaries_auxiliar module~yaeos__equilibria_boundaries_pure_saturation yaeos__equilibria_boundaries_pure_saturation module~yaeos__equilibria_boundaries_pure_saturation->module~yaeos__math_continuation module~yaeos__math yaeos__math module~yaeos__math->module~yaeos__math_continuation proc~critical_line critical_line proc~critical_line->module~yaeos__math_continuation proc~critical_line->module~yaeos__math module~yaeos__equilibria yaeos__equilibria module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_pt module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_px module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_tx module~yaeos__equilibria->module~yaeos__equilibria_boundaries_pure_saturation module~yaeos__equilibria_binaries yaeos__equilibria_binaries module~yaeos__equilibria->module~yaeos__equilibria_binaries module~yaeos__equilibria_boundaries_generalized_isopleths yaeos__equilibria_boundaries_generalized_isopleths module~yaeos__equilibria->module~yaeos__equilibria_boundaries_generalized_isopleths module~yaeos__equilibria_boundaries_phase_envelopes_mp yaeos__equilibria_boundaries_phase_envelopes_mp module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_mp module~yaeos__equilibria_boundaries_phase_envelopes_mp_px yaeos__equilibria_boundaries_phase_envelopes_mp_px module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_mp_px module~yaeos__equilibria_boundaries_phase_envelopes_mp_tx yaeos__equilibria_boundaries_phase_envelopes_mp_tx module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_mp_tx module~yaeos__equilibria_boundaries_phase_envelopes_pt3 yaeos__equilibria_boundaries_phase_envelopes_pt3 module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_pt3 module~yaeos__equilibria_boundaries_phase_envelopes_px3 yaeos__equilibria_boundaries_phase_envelopes_px3 module~yaeos__equilibria->module~yaeos__equilibria_boundaries_phase_envelopes_px3 module~yaeos__equilibria_binaries->module~yaeos__math module~yaeos__equilibria_boundaries_auxiliar->module~yaeos__math module~yaeos__equilibria_boundaries_generalized_isopleths->module~yaeos__math module~yaeos__equilibria_boundaries_phase_envelopes_mp->module~yaeos__math module~yaeos__equilibria_boundaries_phase_envelopes_mp->module~yaeos__equilibria_boundaries_auxiliar module~yaeos__equilibria_boundaries_phase_envelopes_mp_px->module~yaeos__math module~yaeos__equilibria_boundaries_phase_envelopes_mp_px->module~yaeos__equilibria_boundaries_auxiliar module~yaeos__equilibria_boundaries_phase_envelopes_mp_tx->module~yaeos__math module~yaeos__equilibria_boundaries_phase_envelopes_mp_tx->module~yaeos__equilibria_boundaries_auxiliar module~yaeos__equilibria_boundaries_phase_envelopes_pt3->module~yaeos__math module~yaeos__equilibria_boundaries_phase_envelopes_px3->module~yaeos__math module~yaeos__equilibria_boundaries_phase_envelopes_px3->module~yaeos__equilibria_boundaries_auxiliar module~yaeos__models_ge_uniquac yaeos__models_ge_uniquac module~yaeos__models_ge_uniquac->module~yaeos__math proc~check_critical_jump check_critical_jump proc~check_critical_jump->module~yaeos__math proc~critical_point critical_point proc~critical_point->module~yaeos__math proc~detect_critical~3 detect_critical proc~detect_critical~3->module~yaeos__math proc~homotopy homotopy proc~homotopy->module~yaeos__math proc~look_for_cep look_for_cep proc~look_for_cep->module~yaeos__math proc~refit_rkpr_k refit_rkpr_k proc~refit_rkpr_k->module~yaeos__equilibria_boundaries_pure_saturation proc~solve_generalized_point solve_generalized_point proc~solve_generalized_point->module~yaeos__math proc~solve_mp_flash_point solve_mp_flash_point proc~solve_mp_flash_point->module~yaeos__math proc~solve_point PXEnvelMP%solve_point proc~solve_point->module~yaeos__math proc~solve_point~4 PTEnvelMP%solve_point proc~solve_point~4->module~yaeos__math proc~solve_point~7 TXEnvelMP%solve_point proc~solve_point~7->module~yaeos__math proc~solve_tp solve_TP proc~solve_tp->module~yaeos__math proc~solve_vxvyt solve_VxVyT proc~solve_vxvyt->module~yaeos__math proc~three_phase_line_f three_phase_line_F proc~three_phase_line_f->module~yaeos__math proc~three_phase_line_f_solve three_phase_line_F_solve proc~three_phase_line_f_solve->module~yaeos__math proc~volume Gerg2008%volume proc~volume->module~yaeos__math proc~volume~3 ArModel%volume proc~volume~3->module~yaeos__math module~yaeos yaeos module~yaeos->module~yaeos__equilibria module~yaeos__models yaeos__models module~yaeos->module~yaeos__models module~yaeos__models_ge_implementations yaeos__models_ge_implementations module~yaeos__models_ge_implementations->module~yaeos__models_ge_uniquac module~yaeos__models->module~yaeos__models_ge_implementations proc~psrk PSRK proc~psrk->module~yaeos__models_ge_implementations

Abstract Interfaces

abstract interface

  • public subroutine continuation_function(X, ns, S, F, dF, dFdS)

    Arguments

    Type IntentOptional Attributes Name
    real(kind=pr), intent(in) :: X(:)
    integer, intent(in) :: ns
    real(kind=pr), intent(in) :: S
    real(kind=pr), intent(out) :: F(:)
    real(kind=pr), intent(out) :: dF(:,:)
    real(kind=pr), intent(out) :: dFdS(:)

abstract interface

  • public subroutine continuation_solver(fun, iters, X, ns, S, dS, dXdS, point, max_iters, F, df, dfds, tol)

    Solver to solve a point during numerical contination.

    Arguments

    Type IntentOptional Attributes Name
    procedure(continuation_function) :: fun

    Function to solve

    integer, intent(out) :: iters

    Number of iterations needed

    real(kind=pr), intent(inout) :: X(:)

    Variables vector

    integer, intent(in) :: ns

    Specification number

    real(kind=pr), intent(in) :: S

    Specification value

    real(kind=pr), intent(in) :: dS

    Delta spec

    real(kind=pr), intent(in) :: dXdS(:)
    integer, intent(in) :: point

    Point number

    integer, intent(in) :: max_iters

    Maximum iterations

    real(kind=pr), intent(out) :: F(:)

    Function values at solved point

    real(kind=pr), intent(out) :: df(:,:)

    Jacobian values

    real(kind=pr), intent(out) :: dfds(:)

    dFdS

    real(kind=pr), intent(in) :: tol

    Solver tolerance

abstract interface

  • public function continuation_stopper(X, ns, S, dS, dXdS, iterations)

    Function that returns true if the method should stop

    Arguments

    Type IntentOptional Attributes Name
    real(kind=pr), intent(inout) :: X(:)

    Vector of variables

    integer, intent(inout) :: ns

    Position of specified variable

    real(kind=pr), intent(inout) :: S

    Specification variable value

    real(kind=pr), intent(inout) :: dS

    Step of specification in the method

    real(kind=pr), intent(inout) :: dXdS(:)

    integer, intent(in) :: iterations

    Iterations needed to converge point

    Return Value logical

abstract interface

  • public subroutine process(X, ns, S, dS, dXdS, iterations)

    Subroutine to make variation in the method after a point converged

    Arguments

    Type IntentOptional Attributes Name
    real(kind=pr), intent(inout) :: X(:)

    Vector of variables

    integer, intent(inout) :: ns

    Position of specified variable

    real(kind=pr), intent(inout) :: S

    Specification variable value

    real(kind=pr), intent(inout) :: dS

    Step of specification in the method

    real(kind=pr), intent(inout) :: dXdS(:)

    integer, intent(in) :: iterations

    Iterations needed to converge point


Derived Types

type, public ::  ContinuationVariable

Components

Type Visibility Attributes Name Initial
real(kind=pr), public :: S
real(kind=pr), public, allocatable :: X(:)
real(kind=pr), public :: dS
integer, public :: ns

Functions

public function continuation(f, X0, ns0, S0, dS0, max_points, solver_tol, update_specification, postprocess, solver, stop) result(XS)

Numerical continuation of a function.

Read more…

Arguments

Type IntentOptional Attributes Name
procedure(continuation_function) :: f

Function to trace

real(kind=pr), intent(in) :: X0(:)

Initial point

integer, intent(in) :: ns0

Initial specification

real(kind=pr), intent(in) :: S0

Initial specification value

real(kind=pr), intent(in) :: dS0

Initial

integer, intent(in) :: max_points

Maximum number of points to trace

real(kind=pr), intent(in) :: solver_tol

Point solver tolerance

procedure(process), optional :: update_specification

Procedure to select the new specification and define the next step (\DeltaS)\, defaults to:

Read more…
procedure(process), optional :: postprocess

Any kind of postprocess that could be done after defining the next step

procedure(continuation_solver), optional :: solver

Solver procedures, uses Newton-Raphson by default

procedure(continuation_stopper), optional :: stop

Stopping procedure

Return Value real(kind=pr), (max_points,size(X0))


Subroutines

public subroutine full_newton(fun, iters, X, ns, S, dS, dXdS, point, max_iters, F, df, dfds, tol)

Subroutine to solve a point.

Read more…

Arguments

Type IntentOptional Attributes Name
procedure(continuation_function) :: fun

Function to solve

integer, intent(out) :: iters

Number of iterations needed

real(kind=pr), intent(inout) :: X(:)

Variables vector

integer, intent(in) :: ns
real(kind=pr), intent(in) :: S
real(kind=pr), intent(in) :: dS
real(kind=pr), intent(in) :: dXdS(:)
integer, intent(in) :: point
integer, intent(in) :: max_iters

Maximum iterations

real(kind=pr), intent(out) :: F(:)

Function values at solved point

real(kind=pr), intent(out) :: df(:,:)

Jacobian values

real(kind=pr), intent(out) :: dfds(:)

dFdS

real(kind=pr), intent(in) :: tol