38 use json_module,
only : json_file
69 procedure, pass(this) :: init_from_components => &
82 type(json_file),
intent(inout) :: json
83 class(
case_t),
intent(inout),
target :: case
84 character(len=:),
allocatable :: fieldname
85 character(len=20) :: fields(3)
89 call json_get(json,
"field", fieldname)
91 fields(1) =
"weak_grad_" // trim(fieldname) //
"_x"
92 fields(2) =
"weak_grad_" // trim(fieldname) //
"_y"
93 fields(3) =
"weak_grad_" // trim(fieldname) //
"_z"
95 call json%add(
"fields", fields)
97 call this%init_base(json,
case)
98 call this%writer%init(json,
case)
106 character(len=*) :: fieldname
111 "weak_grad_" // fieldname //
"_x")
113 "weak_grad_" // fieldname //
"_y")
115 "weak_grad_" // fieldname //
"_z")
123 call this%free_base()
124 call this%writer%free()
137 call opgrad(this%grad_x%x, this%grad_y%x, this%grad_z%x, this%u%x,&
138 this%case%fluid%c_Xh)
Retrieves a parameter by name or assigns a provided default value. In the latter case also adds the m...
Retrieves a parameter by name or throws an error.
Defines a simulation case.
Defines a registry for storing solution fields.
type(field_registry_t), target, public neko_field_registry
Global field registry.
Implements the field_writer_t type.
Implements fld_file_output_t.
Utilities for retrieving parameters from the case files.
integer, parameter, public dp
integer, parameter, public sp
integer, parameter, public rp
Global precision used in computations.
subroutine, public opgrad(ux, uy, uz, u, coef, es, ee)
Compute the weak gradient of a scalar field, i.e. the gradient multiplied by the mass matrix.
Simulation components are objects that encapsulate functionality that can be fit to a particular comp...
subroutine compute_(this, time)
Dummy compute function.
Module with things related to the simulation time.
Implements the weak_grad_t type.
subroutine weak_grad_init_from_json(this, json, case)
Constructor from json.
subroutine weak_grad_init_from_components(this, fieldname)
Actual constructor.
subroutine weak_grad_compute(this, time)
Compute the weak_grad field.
subroutine weak_grad_free(this)
Destructor.
A simulation component that writes a 3d field to a file.
A simple output saving a list of fields to a .fld file.
Base abstract class for simulation components.
A struct that contains all info about the time, expand as needed.
A simulation component that computes the weak gradient of a field. Wraps the opgrad operator.