107 INTEGER(INTG),
INTENT(IN) :: SOLUTION_METHOD
108 INTEGER(INTG),
INTENT(OUT) :: ERR
113 enters(
"DiffusionAdvectionDiffusion_EquationsSetSolnMethodSet",err,error,*999)
115 IF(
ASSOCIATED(equations_set))
THEN 116 IF(.NOT.
ALLOCATED(equations_set%SPECIFICATION))
THEN 117 CALL flagerror(
"Equations set specification is not allocated.",err,error,*999)
118 ELSE IF(
SIZE(equations_set%SPECIFICATION,1)/=3)
THEN 119 CALL flagerror(
"Equations set specification must have three entries for a "// &
120 &
"diffusion and advection-diffusion type equations set.",err,error,*999)
122 SELECT CASE(equations_set%SPECIFICATION(3))
124 SELECT CASE(solution_method)
128 CALL flagerror(
"Not implemented.",err,error,*999)
130 CALL flagerror(
"Not implemented.",err,error,*999)
132 CALL flagerror(
"Not implemented.",err,error,*999)
134 CALL flagerror(
"Not implemented.",err,error,*999)
136 CALL flagerror(
"Not implemented.",err,error,*999)
138 local_error=
"The specified solution method of "//
trim(
number_to_vstring(solution_method,
"*",err,error))//
" is invalid." 139 CALL flagerror(local_error,err,error,*999)
142 local_error=
"Equations set subtype of "//
trim(
number_to_vstring(equations_set%SPECIFICATION(3),
"*",err,error))// &
143 &
" is not valid for a diffusion & advection-diffusion equation type of a multi physics equations set class." 144 CALL flagerror(local_error,err,error,*999)
147 CALL flagerror(
"Equations set is not associated.",err,error,*999)
150 exits(
"DiffusionAdvectionDiffusion_EquationsSetSolnMethodSet")
152 999
errors(
"DiffusionAdvectionDiffusion_EquationsSetSolnMethodSet",err,error)
153 exits(
"DiffusionAdvectionDiffusion_EquationsSetSolnMethodSet")
168 INTEGER(INTG),
INTENT(OUT) :: ERR
173 enters(
"DiffusionAdvectionDiffusion_EquationsSetSetup",err,error,*999)
175 CALL flagerror(
"Not implemented.",err,error,*999)
177 exits(
"DiffusionAdvectionDiffusion_EquationsSetSetup")
179 999
errors(
"DiffusionAdvectionDiffusion_EquationsSetSetup",err,error)
180 exits(
"DiffusionAdvectionDiffusion_EquationsSetSetup")
194 INTEGER(INTG),
INTENT(IN) :: ELEMENT_NUMBER
195 INTEGER(INTG),
INTENT(OUT) :: ERR
199 enters(
"DiffusionAdvectionDiffusion_FiniteElementCalculate",err,error,*999)
201 CALL flagerror(
"Not implemented.",err,error,*999)
203 exits(
"DiffusionAdvectionDiffusion_FiniteElementCalculate")
205 999
errors(
"DiffusionAdvectionDiffusion_FiniteElementCalculate",err,error)
206 exits(
"DiffusionAdvectionDiffusion_FiniteElementCalculate")
220 INTEGER(INTG),
INTENT(IN) :: specification(:)
221 INTEGER(INTG),
INTENT(OUT) :: err
224 enters(
"DiffusionAdvectionDiffusion_EquationsSetSpecSet",err,error,*999)
226 CALL flagerror(
"Not implemented.",err,error,*999)
228 exits(
"DiffusionAdvectionDiffusion_EquationsSetSpecSet")
230 999
errors(
"DiffusionAdvectionDiffusion_EquationsSetSpecSet",err,error)
231 exits(
"DiffusionAdvectionDiffusion_EquationsSetSpecSet")
245 INTEGER(INTG),
INTENT(IN) :: problemSpecification(:)
246 INTEGER(INTG),
INTENT(OUT) :: err
250 INTEGER(INTG) :: problemSubtype
252 enters(
"DiffusionAdvectionDiffusion_ProblemSpecificationSet",err,error,*999)
254 IF(
ASSOCIATED(problem))
THEN 255 IF(
SIZE(problemspecification,1)==3)
THEN 256 SELECT CASE(problemsubtype)
260 localerror=
"The third problem specification of "//
trim(
numbertovstring(problemsubtype,
"*",err,error))// &
261 &
" is not valid for a coupled diffusion & advection-diffusion type of a multi physics problem." 262 CALL flagerror(localerror,err,error,*999)
264 IF(
ALLOCATED(problem%specification))
THEN 265 CALL flagerror(
"Problem specification is already allocated.",err,error,*999)
267 ALLOCATE(problem%specification(3),stat=err)
268 IF(err/=0)
CALL flagerror(
"Could not allocate problem specification.",err,error,*999)
273 CALL flagerror(
"Diffusion advection-diffusion transport problem specification must have 3 entries.",err,error,*999)
276 CALL flagerror(
"Problem is not associated.",err,error,*999)
279 exits(
"DiffusionAdvectionDiffusion_ProblemSpecificationSet")
281 999
errors(
"DiffusionAdvectionDiffusion_ProblemSpecificationSet",err,error)
282 exits(
"DiffusionAdvectionDiffusion_ProblemSpecificationSet")
297 INTEGER(INTG),
INTENT(OUT) :: ERR
301 TYPE(
solver_type),
POINTER :: SOLVER_DIFFUSION, SOLVER_ADVECTION_DIFFUSION
302 TYPE(
solver_equations_type),
POINTER :: SOLVER_EQUATIONS_DIFFUSION, SOLVER_EQUATIONS_ADVECTION_DIFFUSION
306 enters(
"DIFFUSION_ADVECTION_DIFFUSION_PROBLEM_SETUP",err,error,*999)
308 NULLIFY(control_loop)
310 NULLIFY(solver_diffusion)
311 NULLIFY(solver_advection_diffusion)
312 NULLIFY(solver_equations_diffusion)
313 NULLIFY(solver_equations_advection_diffusion)
314 IF(
ASSOCIATED(problem))
THEN 315 IF(.NOT.
ALLOCATED(problem%specification))
THEN 316 CALL flagerror(
"Problem specification is not allocated.",err,error,*999)
317 ELSE IF(
SIZE(problem%specification,1)<3)
THEN 318 CALL flagerror(
"Problem specification must have three entries for a diffusion-advection diffusion problem.", &
321 SELECT CASE(problem%SPECIFICATION(3))
327 SELECT CASE(problem_setup%SETUP_TYPE)
329 SELECT CASE(problem_setup%ACTION_TYPE)
335 local_error=
"The action type of "//
trim(
number_to_vstring(problem_setup%ACTION_TYPE,
"*",err,error))// &
337 &
" is invalid for a diffusion & advection-diffusion equation." 338 CALL flagerror(local_error,err,error,*999)
341 SELECT CASE(problem_setup%ACTION_TYPE)
348 control_loop_root=>problem%CONTROL_LOOP
352 local_error=
"The action type of "//
trim(
number_to_vstring(problem_setup%ACTION_TYPE,
"*",err,error))// &
354 &
" is invalid for a coupled diffusion & advection-diffusion equation." 355 CALL flagerror(local_error,err,error,*999)
359 control_loop_root=>problem%CONTROL_LOOP
361 SELECT CASE(problem_setup%ACTION_TYPE)
391 local_error=
"The action type of "//
trim(
number_to_vstring(problem_setup%ACTION_TYPE,
"*",err,error))// &
393 &
" is invalid for a coupled diffusion & advection-diffusion equation." 394 CALL flagerror(local_error,err,error,*999)
397 SELECT CASE(problem_setup%ACTION_TYPE)
400 control_loop_root=>problem%CONTROL_LOOP
423 control_loop_root=>problem%CONTROL_LOOP
439 local_error=
"The action type of "//
trim(
number_to_vstring(problem_setup%ACTION_TYPE,
"*",err,error))// &
441 &
" is invalid for a coupled diffusion & advection-diffusion equation." 442 CALL flagerror(local_error,err,error,*999)
445 local_error=
"The setup type of "//
trim(
number_to_vstring(problem_setup%SETUP_TYPE,
"*",err,error))// &
446 &
" is invalid for a coupled diffusion & advection-diffusion equation." 447 CALL flagerror(local_error,err,error,*999)
454 local_error=
"The problem subtype of "//
trim(
number_to_vstring(problem%SPECIFICATION(3),
"*",err,error))// &
455 &
" does not equal a coupled source diffusion & advection-diffusion equation subtype." 456 CALL flagerror(local_error,err,error,*999)
460 CALL flagerror(
"Problem is not associated.",err,error,*999)
463 exits(
"DIFFUSION_ADVECTION_DIFFUSION_PROBLEM_SETUP")
465 999 errorsexits(
"DIFFUSION_ADVECTION_DIFFUSION_PROBLEM_SETUP",err,error)
479 INTEGER(INTG),
INTENT(OUT) :: ERR
486 enters(
"DIFFUSION_ADVECTION_DIFFUSION_PRE_SOLVE",err,error,*999)
488 IF(
ASSOCIATED(control_loop))
THEN 489 IF(
ASSOCIATED(solver))
THEN 490 IF(
ASSOCIATED(control_loop%PROBLEM))
THEN 491 IF(.NOT.
ALLOCATED(control_loop%problem%specification))
THEN 492 CALL flagerror(
"Problem specification is not allocated.",err,error,*999)
493 ELSE IF(
SIZE(control_loop%problem%specification,1)<3)
THEN 494 CALL flagerror(
"Problem specification must have three entries for a diffusion-advection diffusion problem.", &
497 SELECT CASE(control_loop%PROBLEM%SPECIFICATION(3))
500 IF(solver%GLOBAL_NUMBER==1)
THEN 510 ELSE IF(solver%GLOBAL_NUMBER==2)
THEN 517 local_error=
"Problem subtype "//
trim(
number_to_vstring(control_loop%PROBLEM%SPECIFICATION(3),
"*",err,error))// &
518 &
" is not valid for a diffusion & advection-diffusion type of a multi physics problem class." 519 CALL flagerror(local_error,err,error,*999)
522 CALL flagerror(
"Problem is not associated.",err,error,*999)
525 CALL flagerror(
"Solver is not associated.",err,error,*999)
528 CALL flagerror(
"Control loop is not associated.",err,error,*999)
531 exits(
"DIFFUSION_ADVECTION_DIFFUSION_PRE_SOLVE")
533 999 errorsexits(
"DIFFUSION_ADVECTION_DIFFUSION_PRE_SOLVE",err,error)
547 INTEGER(INTG),
INTENT(OUT) :: ERR
553 enters(
"DIFFUSION_ADVECTION_DIFFUSION_POST_SOLVE",err,error,*999)
555 IF(
ASSOCIATED(control_loop))
THEN 556 IF(
ASSOCIATED(solver))
THEN 557 IF(
ASSOCIATED(control_loop%PROBLEM))
THEN 558 IF(.NOT.
ALLOCATED(control_loop%problem%specification))
THEN 559 CALL flagerror(
"Problem specification is not allocated.",err,error,*999)
560 ELSE IF(
SIZE(control_loop%problem%specification,1)<3)
THEN 561 CALL flagerror(
"Problem specification must have three entries for a diffusion-advection diffusion problem.", &
564 SELECT CASE(control_loop%PROBLEM%SPECIFICATION(3))
566 IF(solver%GLOBAL_NUMBER==1)
THEN 568 ELSE IF(solver%GLOBAL_NUMBER==2)
THEN 572 local_error=
"Problem subtype "//
trim(
number_to_vstring(control_loop%PROBLEM%SPECIFICATION(3),
"*",err,error))// &
573 &
" is not valid for a diffusion & advection-diffusion type of a multi physics problem class." 574 CALL flagerror(local_error,err,error,*999)
577 CALL flagerror(
"Problem is not associated.",err,error,*999)
580 CALL flagerror(
"Solver is not associated.",err,error,*999)
583 CALL flagerror(
"Control loop is not associated.",err,error,*999)
586 exits(
"DIFFUSION_ADVECTION_DIFFUSION_POST_SOLVE")
588 999 errorsexits(
"DIFFUSION_ADVECTION_DIFFUSION_POST_SOLVE",err,error)
602 INTEGER(INTG),
INTENT(OUT) :: ERR
608 enters(
"DiffusionAdvectionDiffusion_PostSolveOutputData",err,error,*999)
610 IF(
ASSOCIATED(control_loop))
THEN 611 IF(
ASSOCIATED(solver))
THEN 612 IF(
ASSOCIATED(control_loop%PROBLEM))
THEN 613 IF(.NOT.
ALLOCATED(control_loop%problem%specification))
THEN 614 CALL flagerror(
"Problem specification is not allocated.",err,error,*999)
615 ELSE IF(
SIZE(control_loop%problem%specification,1)<3)
THEN 616 CALL flagerror(
"Problem specification must have three entries for a diffusion-advection diffusion problem.", &
619 SELECT CASE(control_loop%PROBLEM%SPECIFICATION(3))
624 local_error=
"Problem subtype "//
trim(
number_to_vstring(control_loop%PROBLEM%SPECIFICATION(3),
"*",err,error))// &
625 &
" is not valid for a diffusion & advection-diffusion type of a multi physics problem class." 626 CALL flagerror(local_error,err,error,*999)
629 CALL flagerror(
"Problem is not associated.",err,error,*999)
632 CALL flagerror(
"Solver is not associated.",err,error,*999)
635 CALL flagerror(
"Control loop is not associated.",err,error,*999)
638 exits(
"DiffusionAdvectionDiffusion_PostSolveOutputData")
640 999
errors(
"DiffusionAdvectionDiffusion_PostSolveOutputData",err,error)
641 exits(
"DiffusionAdvectionDiffusion_PostSolveOutputData")
integer(intg), parameter equations_set_fem_solution_method
Finite Element Method solution method.
This module contains all basis function routines.
subroutine, public enters(NAME, ERR, ERROR,)
Records the entry into the named procedure and initialises the error code.
subroutine, public solvers_create_finish(SOLVERS, ERR, ERROR,)
Finish the creation of solvers.
This module contains all coordinate transformation and support routines.
integer(intg), parameter equations_set_gfem_solution_method
Grid-based Finite Element Method solution method.
integer(intg), parameter problem_diffusion_advection_diffusion_type
integer(intg), parameter problem_control_time_loop_type
Time control loop.
integer(intg), parameter problem_setup_control_type
Solver setup for a problem.
This module handles all problem wide constants.
integer(intg), parameter solver_equations_first_order_dynamic
Solver equations are first order dynamic.
integer(intg), parameter, public control_loop_node
The identifier for a each "leaf" node in a control loop.
subroutine, public diffusionadvectiondiffusion_equationssetspecset(equationsSet, specification, err, error,)
Sets the equation specification for a coupled diffusion & advection-diffusion equation type of a mult...
subroutine, public solver_dynamic_order_set(SOLVER, ORDER, ERR, ERROR,)
Sets/changes the order for a dynamic solver.
Converts a number to its equivalent varying string representation.
Contains information on the type of solver to be used.
subroutine, public diffusionadvectiondiffusion_equationssetsetup(EQUATIONS_SET, EQUATIONS_SET_SETUP, ERR, ERROR,)
Sets up the diffusion & advection-diffusion coupled equation.
subroutine, public solvers_number_set(SOLVERS, NUMBER_OF_SOLVERS, ERR, ERROR,)
Sets/changes the number of solvers.
integer(intg), parameter, public solver_dynamic_crank_nicolson_scheme
Crank-Nicolson dynamic solver.
subroutine, public solver_dynamic_degree_set(SOLVER, DEGREE, ERR, ERROR,)
Sets/changes the degree of the polynomial used to interpolate time for a dynamic solver.
This module handles all equations matrix and rhs routines.
integer(intg), parameter, public solver_dynamic_first_order
Dynamic solver has first order terms.
subroutine, public solver_type_set(SOLVER, SOLVE_TYPE, ERR, ERROR,)
Sets/changes the type for a solver.
Contains information on an equations set.
This module handles all equations routines.
This module contains all string manipulation and transformation routines.
subroutine, public solvers_create_start(CONTROL_LOOP, SOLVERS, ERR, ERROR,)
Start the creation of a solvers for the control loop.
Contains information on the solvers to be used in a control loop.
subroutine, public diffusion_advection_diffusion_problem_setup(PROBLEM, PROBLEM_SETUP, ERR, ERROR,)
Sets up the coupled diffusion-diffusion equations problem.
TThis module handles all routines pertaining to diffusion coupled to diffusion.
This module contains routines for timing the program.
subroutine, public solver_equations_sparsity_type_set(SOLVER_EQUATIONS, SPARSITY_TYPE, ERR, ERROR,)
Sets/changes the sparsity type for solver equations.
This module contains all mathematics support routines.
subroutine, public solvers_solver_get(SOLVERS, SOLVER_INDEX, SOLVER, ERR, ERROR,)
Returns a pointer to the specified solver in the list of solvers.
integer(intg), parameter solver_equations_linear
Solver equations are linear.
Contains information on a control loop.
This module provides an iso_varying_string module, conformant to the API specified in ISO/IEC 1539-2:...
subroutine, public solver_equations_create_finish(SOLVER_EQUATIONS, ERR, ERROR,)
Finishes the process of creating solver equations.
integer(intg), parameter, public solver_sparse_matrices
Use sparse solver matrices.
subroutine, public solver_equations_create_start(SOLVER, SOLVER_EQUATIONS, ERR, ERROR,)
Starts the process of creating solver equations.
integer(intg), parameter, public solver_dynamic_type
A dynamic solver.
integer(intg), parameter problem_setup_solvers_type
Solver setup for a problem.
This module contains all program wide constants.
subroutine, public solver_library_type_set(SOLVER, SOLVER_LIBRARY_TYPE, ERR, ERROR,)
Sets/changes the type of library type to use for the solver.
integer(intg), parameter problem_setup_initial_type
Initial setup for a problem.
integer(intg), parameter problem_coupled_source_diffusion_advec_diffusion_subtype
This module handles all advection-diffusion equation routines.
subroutine, public solver_equations_linearity_type_set(SOLVER_EQUATIONS, LINEARITY_TYPE, ERR, ERROR,)
Sets/changes the linearity type for solver equations.
subroutine, public exits(NAME)
Records the exit out of the named procedure.
recursive subroutine, public control_loop_solvers_get(CONTROL_LOOP, SOLVERS, ERR, ERROR,)
Returns a pointer to the solvers for a control loop.
This module contains all type definitions in order to avoid cyclic module references.
subroutine, public diffusionadvectiondiffusion_problemspecificationset(problem, problemSpecification, err, error,)
Sets the problem specification for a coupled diffusion & advection-diffusion problem.
This module contains all the low-level base routines e.g., all debug, control, and low-level communic...
Returns the specified control loop as indexed by the control loop identifier from the control loop ro...
subroutine, public control_loop_type_set(CONTROL_LOOP, LOOP_TYPE, ERR, ERROR,)
Sets/changes the control loop type.
integer(intg), parameter problem_multi_physics_class
subroutine, public diffusionadvectiondiffusion_equationssetsolnmethodset(EQUATIONS_SET, SOLUTION_METHOD, ERR, ERROR,)
Sets/changes the solution method for a coupled diffusion & advection-diffusion equation type of a mul...
subroutine, public diffusion_presolvestorecurrentsolution(CONTROL_LOOP, SOLVER, ERR, ERROR,)
This module handles all domain mappings routines.
integer(intg), parameter problem_setup_finish_action
Finish setup action.
This module handles all equations mapping routines.
Contains information about the solver equations for a solver.
integer(intg), parameter equations_set_gfv_solution_method
Grid-based Finite Volume solution method.
Contains information for a problem.
subroutine, public advectiondiffusion_presolvestorecurrentsoln(CONTROL_LOOP, SOLVER, ERR, ERROR,)
integer(intg), parameter equations_set_coupled_source_diffusion_advec_diffusion_subtype
subroutine diffusionadvectiondiffusion_postsolveoutputdata(CONTROL_LOOP, SOLVER, ERR, ERROR,)
Sets up the diffuion-diffusion problem post solve output data.
This module handles all distributed matrix vector routines.
This module handles all boundary conditions routines.
This module handles all solver routines.
This module contains all routines dealing with (non-distributed) matrix and vectors types...
subroutine, public control_loop_create_start(PROBLEM, CONTROL_LOOP, ERR, ERROR,)
Start the process of creating a control loop for a problem.
subroutine, public diffusion_advection_diffusion_pre_solve(CONTROL_LOOP, SOLVER, ERR, ERROR,)
Sets up the diffusion-diffusion problem pre-solve.
integer(intg), parameter problem_setup_solver_equations_type
Solver equations setup for a problem.
subroutine, public solver_dynamic_scheme_set(SOLVER, SCHEME, ERR, ERROR,)
Sets/changes the scheme for a dynamic solver.
integer(intg), parameter equations_set_fd_solution_method
Finite Difference solution method.
subroutine, public diffusion_advection_diffusion_post_solve(CONTROL_LOOP, SOLVER, ERR, ERROR,)
Sets up the diffusion-diffusion problem post solve.
Contains information on the setup information for an equations set.
integer(intg), parameter problem_setup_start_action
Start setup action.
subroutine, public solver_equations_time_dependence_type_set(SOLVER_EQUATIONS, TIME_DEPENDENCE_TYPE, ERR, ERROR,)
Sets/changes the time dependence type for solver equations.
This module handles all control loop routines.
integer(intg), parameter, public solver_cmiss_library
CMISS (internal) solver library.
subroutine, public errors(NAME, ERR, ERROR)
Records the exiting error of the subroutine.
This module defines all constants shared across equations set routines.
integer(intg), parameter equations_set_bem_solution_method
Boundary Element Method solution method.
subroutine, public solver_solver_equations_get(SOLVER, SOLVER_EQUATIONS, ERR, ERROR,)
Returns a pointer to the solver equations for a solver.
integer(intg), parameter equations_set_fv_solution_method
Finite Volume solution method.
subroutine, public diffusionadvectiondiffusion_finiteelementcalculate(EQUATIONS_SET, ELEMENT_NUMBER, ERR, ERROR,)
Calculates the element stiffness matrices and RHS for a coupled diffusion & advection-diffusion equat...
integer(intg), parameter, public solver_dynamic_first_degree
Dynamic solver uses a first degree polynomial for time interpolation.
recursive subroutine, public control_loop_create_finish(CONTROL_LOOP, ERR, ERROR,)
Finish the process of creating a control loop.
Flags an error condition.
This module handles all diffusion equation routines.
This module contains all kind definitions.
Temporary IO routines for fluid mechanics.