Neko 1.99.10
A portable framework for high-order spectral element flow simulations
Loading...
Searching...
No Matches
flow_ic.f90
Go to the documentation of this file.
1! Copyright (c) 2021-2026, The Neko Authors
2! All rights reserved.
3!
4! Redistribution and use in source and binary forms, with or without
5! modification, are permitted provided that the following conditions
6! are met:
7!
8! * Redistributions of source code must retain the above copyright
9! notice, this list of conditions and the following disclaimer.
10!
11! * Redistributions in binary form must reproduce the above
12! copyright notice, this list of conditions and the following
13! disclaimer in the documentation and/or other materials provided
14! with the distribution.
15!
16! * Neither the name of the authors nor the names of its
17! contributors may be used to endorse or promote products derived
18! from this software without specific prior written permission.
19!
20! THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21! "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22! LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
23! FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
24! COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
25! INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
26! BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
27! LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
28! CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29! LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
30! ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
31! POSSIBILITY OF SUCH DAMAGE.
32!
33!> Initial flow condition
34module flow_ic
35 use num_types, only : rp
36 use logger, only : neko_log, log_size
37 use gather_scatter, only : gs_t, gs_op_add
43 use field, only : field_t
44 use utils, only : neko_error, filename_chsuffix, &
46 use coefs, only : coef_t
47 use math, only : col2, cfill, cfill_mask, abscmp
48 use device_math, only : device_col2
51 use json_module, only : json_file
55 use point_zone, only : point_zone_t
58 use fld_file, only : fld_file_t
59 use file, only : file_t
62 use space, only : space_t, gll
63 use field_list, only : field_list_t
64 use operators, only : rotate_cyc
66 implicit none
67 private
68
72 end interface set_flow_ic
73
76
77contains
78
79 !> Set initial flow condition (builtin)
80 subroutine set_flow_ic_builtin(u, v, w, p, coef, gs, type, params)
81 type(field_t), intent(inout) :: u
82 type(field_t), intent(inout) :: v
83 type(field_t), intent(inout) :: w
84 type(field_t), intent(inout) :: p
85 type(coef_t), intent(in) :: coef
86 type(gs_t), intent(inout) :: gs
87 character(len=*) :: type
88 type(json_file), intent(inout) :: params
89 real(kind=rp) :: delta
90 real(kind=rp), allocatable :: uinf(:)
91 real(kind=rp), allocatable :: zone_value(:)
92 character(len=:), allocatable :: read_str
93 character(len=NEKO_EXPR_LEN), allocatable :: expr_str(:)
94
95 select case (trim(type))
96 case ('uniform') ! Uniform (Uinf, Vinf, Winf)
97
98 call json_get_or_lookup(params, 'value', uinf)
99 call set_flow_ic_uniform(u, v, w, uinf)
100
101 case ('expression') ! One mathematical expression per velocity component
102
103 call json_get(params, 'value', expr_str, filler = '')
104 call set_flow_ic_expression(u, v, w, expr_str)
105 if (allocated(expr_str)) deallocate(expr_str)
106
107 case ('blasius') ! Blasius boundary layer
108
109 call json_get_or_lookup(params, 'delta', delta)
110 call json_get(params, 'approximation', read_str)
111 call json_get_or_lookup(params, 'freestream_velocity', uinf)
112
113 call set_flow_ic_blasius(u, v, w, delta, uinf, read_str)
114
115 case ('point_zone') ! Point zone initial condition
116
117 call json_get_or_lookup(params, 'base_value', uinf)
118 call json_get(params, 'zone_name', read_str)
119 call json_get_or_lookup(params, 'zone_value', zone_value)
120
121 call set_flow_ic_point_zone(u, v, w, uinf, read_str, zone_value)
122
123 case ('field') ! Field initial condition (from fld file)
124
125 block
126 character(len=NEKO_FNAME_LEN) :: fname, mesh_fname
127 logical :: interpolate
128 type(json_file) :: interp_subdict
129
130 call json_get(params, 'file_name', read_str)
131 fname = trim(read_str)
132
133 call json_get_or_default(params, 'mesh_file_name', read_str, "none")
134 mesh_fname = trim(read_str)
135
136 call json_get_or_default(params, 'interpolate', interpolate, .false.)
137 call json_get_subdict_or_empty(params, "interpolation", interp_subdict)
138 call set_flow_ic_fld(u, v, w, p, fname, interpolate, &
139 mesh_fname, interp_subdict)
140 end block
141
142 case default
143 call neko_error('Invalid initial condition')
144 end select
145
146 call set_flow_ic_common(u, v, w, p, coef, gs)
147
148 end subroutine set_flow_ic_builtin
149
150 !> Set initial flow condition (user defined) for incompressible flows
151 !! @note No data is copied between the host and the device. The user routine
152 !! must leave the values where the backend operates on them, i.e. on the
153 !! device when running on GPUs.
154 subroutine set_flow_ic_user_incompressible(u, v, w, p, coef, gs, user_proc, &
155 scheme_name)
156 type(field_t), target, intent(inout) :: u
157 type(field_t), target, intent(inout) :: v
158 type(field_t), target, intent(inout) :: w
159 type(field_t), target, intent(inout) :: p
160 type(coef_t), intent(in) :: coef
161 type(gs_t), intent(inout) :: gs
162 procedure(user_initial_conditions_intf) :: user_proc
163 character(len=*), intent(in) :: scheme_name
164 real(kind=rp) :: um, vm, wm, pm, init
165 type(field_list_t) :: fields
166
167 call neko_log%message("Type: user")
168
169 call fields%init(4)
170 call fields%assign_to_field(1, u)
171 call fields%assign_to_field(2, v)
172 call fields%assign_to_field(3, w)
173 call fields%assign_to_field(4, p)
174
175 init = -huge(1.0_rp)
176 call field_cfill(u, init)
177 call field_cfill(v, init)
178 call field_cfill(w, init)
179 call field_cfill(p, init)
180
181 call user_proc(scheme_name, fields)
182
183 um = field_glmin(u)
184 vm = field_glmin(v)
185 wm = field_glmin(w)
186 pm = field_glmin(p)
187
188 if (abscmp(um, init)) call neko_error('Initial condition did not set u')
189 if (abscmp(vm, init)) call neko_error('Initial condition did not set v')
190 if (abscmp(wm, init)) call neko_error('Initial condition did not set w')
191 if (abscmp(pm, init)) call neko_error('Initial condition did not set p')
192
193 call set_flow_ic_common(u, v, w, p, coef, gs)
194
196
197 !> Set initial flow condition (user defined) for compressible flows
198 !! @note No data is copied between the host and the device. The user routine
199 !! must leave the values where the backend operates on them, i.e. on the
200 !! device when running on GPUs.
201 subroutine set_flow_ic_user_compressible(rho, u, v, w, p, coef, gs, &
202 user_proc, scheme_name)
203 type(field_t), target, intent(inout) :: rho
204 type(field_t), target, intent(inout) :: u
205 type(field_t), target, intent(inout) :: v
206 type(field_t), target, intent(inout) :: w
207 type(field_t), target, intent(inout) :: p
208 type(coef_t), intent(in) :: coef
209 type(gs_t), intent(inout) :: gs
210 procedure(user_initial_conditions_intf) :: user_proc
211 character(len=*), intent(in) :: scheme_name
212 real(kind=rp) :: rhom, um, vm, wm, pm, init
213 type(field_list_t) :: fields
214
215 call neko_log%message("Type: user (compressible flows)")
216
217 call fields%init(5)
218 call fields%assign_to_field(1, rho)
219 call fields%assign_to_field(2, u)
220 call fields%assign_to_field(3, v)
221 call fields%assign_to_field(4, w)
222 call fields%assign_to_field(5, p)
223
224 init = -huge(1.0_rp)
225 call field_cfill(rho, init)
226 call field_cfill(u, init)
227 call field_cfill(v, init)
228 call field_cfill(w, init)
229 call field_cfill(p, init)
230
231 call user_proc(scheme_name, fields)
232
233 rhom = field_glmin(rho)
234 um = field_glmin(u)
235 vm = field_glmin(v)
236 wm = field_glmin(w)
237 pm = field_glmin(p)
238
239 if (abscmp(rhom, init)) call neko_error('Initial condition did not set rho')
240 if (abscmp(um, init)) call neko_error('Initial condition did not set u')
241 if (abscmp(vm, init)) call neko_error('Initial condition did not set v')
242 if (abscmp(wm, init)) call neko_error('Initial condition did not set w')
243 if (abscmp(pm, init)) call neko_error('Initial condition did not set p')
244
245 call set_flow_ic_common(u, v, w, p, coef, gs)
246
247 ! Ensure continuity across elements for initial conditions
248 ! These variables are not treated in the common constructor
249 call gs%op(p%x, p%dof%size(), gs_op_add)
250 call gs%op(rho%x, rho%dof%size(), gs_op_add)
251
252 if (neko_bcknd_device .eq. 1) then
253 call device_col2(rho%x_d, coef%mult_d, rho%dof%size())
254 call device_col2(p%x_d, coef%mult_d, p%dof%size())
255 else
256 call col2(rho%x, coef%mult, rho%dof%size())
257 call col2(p%x, coef%mult, p%dof%size())
258 end if
259
260 end subroutine set_flow_ic_user_compressible
261
262 !> Make the initial velocity continuous across elements.
263 !! @details Operates on the device arrays when running on GPUs, so the
264 !! caller must make sure the values are there.
265 subroutine set_flow_ic_common(u, v, w, p, coef, gs)
266 type(field_t), intent(inout) :: u
267 type(field_t), intent(inout) :: v
268 type(field_t), intent(inout) :: w
269 type(field_t), intent(inout) :: p
270 type(coef_t), intent(in) :: coef
271 type(gs_t), intent(inout) :: gs
272
273 ! Ensure continuity across elements for initial conditions
274 call rotate_cyc(u, v, w, 1, coef)
275 call gs%op(u%x, u%dof%size(), gs_op_add)
276 call gs%op(v%x, v%dof%size(), gs_op_add)
277 call gs%op(w%x, w%dof%size(), gs_op_add)
278 call rotate_cyc(u, v, w, 0, coef)
279
280 if (neko_bcknd_device .eq. 1) then
281 call device_col2(u%x_d, coef%mult_d, u%dof%size())
282 call device_col2(v%x_d, coef%mult_d, v%dof%size())
283 call device_col2(w%x_d, coef%mult_d, w%dof%size())
284 else
285 call col2(u%x, coef%mult, u%dof%size())
286 call col2(v%x, coef%mult, v%dof%size())
287 call col2(w%x, coef%mult, w%dof%size())
288 end if
289
290 end subroutine set_flow_ic_common
291
292 !> Uniform initial condition
293 subroutine set_flow_ic_uniform(u, v, w, uinf)
294 type(field_t), intent(inout) :: u
295 type(field_t), intent(inout) :: v
296 type(field_t), intent(inout) :: w
297 real(kind=rp), intent(in) :: uinf(3)
298 integer :: n, i
299 character(len=LOG_SIZE) :: log_buf
300
301 call neko_log%message("Type : uniform")
302 write (log_buf, '(A, 3(ES12.6, A))') "Value: [", &
303 (uinf(i), ", ", i = 1, 2), uinf(3), "]"
304 call neko_log%message(log_buf)
305
306 call field_cfill(u, uinf(1))
307 call field_cfill(v, uinf(2))
308 call field_cfill(w, uinf(3))
309
310 end subroutine set_flow_ic_uniform
311
312 !> Set the initial condition from one mathematical expression per velocity
313 !! component.
314 !! @details The expressions are evaluated in every GLL point of the mesh,
315 !! with `x`, `y` and `z` bound to the coordinates of the point. Constants
316 !! declared under `case.constants` in the case file can be referred to by
317 !! name, see the `expression` module for the full syntax.
318 !! @param u The x-component of the velocity field.
319 !! @param v The y-component of the velocity field.
320 !! @param w The z-component of the velocity field.
321 !! @param expr The expressions, one per velocity component.
322 subroutine set_flow_ic_expression(u, v, w, expr)
323 type(field_t), target, intent(inout) :: u
324 type(field_t), target, intent(inout) :: v
325 type(field_t), target, intent(inout) :: w
326 character(len=*), intent(in) :: expr(:)
327 character(len=1), parameter :: comp(3) = ['u', 'v', 'w']
328 type(field_t), pointer :: f
329 integer :: i, n
330
331 if (size(expr) .ne. 3) then
332 call neko_error('The expression initial condition takes exactly ' // &
333 'three expressions, one per velocity component')
334 end if
335
336 call neko_log%message("Type : expression")
337 do i = 1, 3
338 call neko_log%message(comp(i) // " : " // trim(expr(i)))
339 end do
340
341 n = u%dof%size()
342
343 do i = 1, 3
344 select case (i)
345 case (1)
346 f => u
347 case (2)
348 f => v
349 case default
350 f => w
351 end select
352
353 call expression_eval_static(expr(i), f%x, n, &
354 f%dof%x%x, f%dof%y%x, f%dof%z%x, 'fluid initial condition')
355 end do
356
357 call u%copy_from(host_to_device, sync = .false.)
358 call v%copy_from(host_to_device, sync = .false.)
359 call w%copy_from(host_to_device, sync = .true.)
360 end subroutine set_flow_ic_expression
361
362 !> Set a Blasius profile as initial condition
363 !! @note currently limited to axis aligned flow
364 subroutine set_flow_ic_blasius(u, v, w, delta, uinf, type)
365 type(field_t), intent(inout) :: u
366 type(field_t), intent(inout) :: v
367 type(field_t), intent(inout) :: w
368 real(kind=rp), intent(in) :: delta
369 real(kind=rp), intent(in) :: uinf(3)
370 character(len=*), intent(in) :: type
371 procedure(blasius_profile), pointer :: bla => null()
372 integer :: i
373 character(len=LOG_SIZE) :: log_buf
374
375 call neko_log%message("Type : blasius")
376 write (log_buf, '(A,ES12.6)') "delta : ", delta
377 call neko_log%message(log_buf)
378 call neko_log%message("Approximation : " // trim(type))
379 write (log_buf, '(A,"[",2(ES12.6,","),ES12.6,"]")') "Value : ", &
380 uinf(1), uinf(2), uinf(3)
381 call neko_log%message(log_buf)
382
383 select case (trim(type))
384 case ('linear')
385 bla => blasius_linear
386 case ('quadratic')
387 bla => blasius_quadratic
388 case ('cubic')
389 bla => blasius_cubic
390 case ('quartic')
391 bla => blasius_quartic
392 case ('sin')
393 bla => blasius_sin
394 case ('tanh')
395 bla => blasius_tanh
396 case default
397 call neko_error('Invalid Blasius approximation')
398 end select
399
400 if ((uinf(1) .gt. 0.0_rp) .and. abscmp(uinf(2), 0.0_rp) &
401 .and. abscmp(uinf(3), 0.0_rp)) then
402 do i = 1, u%dof%size()
403 u%x(i,1,1,1) = bla(u%dof%z%x(i,1,1,1), delta, uinf(1))
404 v%x(i,1,1,1) = 0.0_rp
405 w%x(i,1,1,1) = 0.0_rp
406 end do
407 else if (abscmp(uinf(1), 0.0_rp) .and. (uinf(2) .gt. 0.0_rp) &
408 .and. abscmp(uinf(3), 0.0_rp)) then
409 do i = 1, u%dof%size()
410 u%x(i,1,1,1) = 0.0_rp
411 v%x(i,1,1,1) = bla(u%dof%x%x(i,1,1,1), delta, uinf(2))
412 w%x(i,1,1,1) = 0.0_rp
413 end do
414 else if (abscmp(uinf(1), 0.0_rp) .and. abscmp(uinf(2), 0.0_rp) &
415 .and. (uinf(3) .gt. 0.0_rp)) then
416 do i = 1, u%dof%size()
417 u%x(i,1,1,1) = 0.0_rp
418 v%x(i,1,1,1) = 0.0_rp
419 w%x(i,1,1,1) = bla(u%dof%y%x(i,1,1,1), delta, uinf(3))
420 end do
421 end if
422
423 call u%copy_from(host_to_device, sync = .false.)
424 call v%copy_from(host_to_device, sync = .false.)
425 call w%copy_from(host_to_device, sync = .true.)
426
427 end subroutine set_flow_ic_blasius
428
429 !> Set the initial condition of the flow based on a point zone.
430 !! @details The initial condition is set to the base value and then the
431 !! zone is filled with the zone value.
432 !! @param u The x-component of the velocity field.
433 !! @param v The y-component of the velocity field.
434 !! @param w The z-component of the velocity field.
435 !! @param base_value The base value of the initial condition.
436 !! @param zone_name The name of the point zone.
437 !! @param zone_value The value of the point zone.
438 subroutine set_flow_ic_point_zone(u, v, w, base_value, zone_name, zone_value)
439 type(field_t), intent(inout) :: u
440 type(field_t), intent(inout) :: v
441 type(field_t), intent(inout) :: w
442 real(kind=rp), intent(in), dimension(3) :: base_value
443 character(len=*), intent(in) :: zone_name
444 real(kind=rp), intent(in) :: zone_value(:)
445 character(len=LOG_SIZE) :: log_buf
446
447 ! Internal variables
448 class(point_zone_t), pointer :: zone
449 integer :: size
450
451 call neko_log%message("Type : point_zone")
452 write (log_buf, '(A,ES12.6)') "Base value : ", base_value
453 call neko_log%message(log_buf)
454 call neko_log%message("Zone name : " // trim(zone_name))
455 write (log_buf, '(A,"[",2(ES12.6,","),ES12.6," ]")') "Value : ", &
456 zone_value(1), zone_value(2), zone_value(3)
457 call neko_log%message(log_buf)
458
459 size = u%dof%size()
460 zone => neko_point_zone_registry%get_point_zone(trim(zone_name))
461
462 call cfill(u%x, base_value(1), size)
463 call cfill(v%x, base_value(2), size)
464 call cfill(w%x, base_value(3), size)
465 call cfill_mask(u%x, zone_value(1), size, zone%mask%get(), zone%size)
466 call cfill_mask(v%x, zone_value(2), size, zone%mask%get(), zone%size)
467 call cfill_mask(w%x, zone_value(3), size, zone%mask%get(), zone%size)
468
469 call u%copy_from(host_to_device, sync = .false.)
470 call v%copy_from(host_to_device, sync = .false.)
471 call w%copy_from(host_to_device, sync = .true.)
472
473 end subroutine set_flow_ic_point_zone
474
475 !> Set the initial condition of the flow based on a field.
476 !! @detail The fields are read from an `fld` file. If enabled, interpolation
477 !! is also possible. In that case, the mesh coordinates can be read from
478 !! another field in the `fld` field series.
479 !! @param u The x-component of the velocity field.
480 !! @param v The y-component of the velocity field.
481 !! @param w The z-component of the velocity field.
482 !! @param p The pressure field.
483 !! @param file_name The name of the "fld" file series.
484 !! @param interpolate Flag to indicate wether or not to interpolate the
485 !! values onto the current mesh.
486 !! @param file_name If interpolation is enabled the name of the "fld" file
487 !! containing the mesh coordinates (if they are not in `file_name`).
488 !! @param global_interp_subdict If interpolation is enabled, subdict
489 !! containing the interpolation parameters to use.
490 subroutine set_flow_ic_fld(u, v, w, p, file_name, &
491 interpolate, mesh_file_name, global_interp_subdict)
492 type(field_t), target, intent(inout) :: u
493 type(field_t), target, intent(inout) :: v
494 type(field_t), target, intent(inout) :: w
495 type(field_t), target, intent(inout) :: p
496 character(len=*), intent(inout) :: file_name
497 logical, intent(in) :: interpolate
498 character(len=*), intent(inout) :: mesh_file_name
499 type(json_file), intent(inout) :: global_interp_subdict
500
501 type(field_t), pointer :: us, vs, ws, ps
502
503 us => u
504 vs => v
505 ws => w
506 ps => p
507
508 if (trim(mesh_file_name) .eq. 'none') then
509 call import_fields(file_name, global_interp_subdict, &
510 u = us, v = vs, w = ws, p = ps, &
511 interpolate = interpolate)
512 else
513 call import_fields(file_name, global_interp_subdict, mesh_file_name, &
514 u = us, v = vs, w = ws, p = ps, &
515 interpolate = interpolate)
516 end if
517
518 nullify(us, vs, ws, ps)
519 end subroutine set_flow_ic_fld
520
521end module flow_ic
Synchronize a device or stream.
Definition device.F90:119
Abstract interface for computing a Blasius flow profile.
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.
Apply cyclic boundary condition to a vector field.
Abstract interface for user defined initial conditions.
Definition user_intf.f90:73
Coefficients.
Definition coef.f90:34
subroutine, public device_col2(a_d, b_d, n, strm)
Vector multiplication .
Device abstraction, common interface for various accelerators.
Definition device.F90:34
integer, parameter, public host_to_device
Definition device.F90:48
integer, parameter, public device_to_host
Definition device.F90:48
Evaluation of mathematical expressions given as strings in the case file.
integer, parameter, public neko_expr_len
Maximum length of an expression string read from the case file.
subroutine, public expression_eval_static(str, res, n, x, y, z, usage)
Compile an expression and evaluate it in a set of points, in a context where there is no time state.
real(kind=rp) function, public field_glmin(a, n)
Global minimum of all elements in a field .
subroutine, public field_cfill(a, c, n)
Set all elements to a constant c .
Defines a field.
Definition field.f90:34
Module for file I/O operations.
Definition file.f90:34
Simple module to handle fld file series. Provides an interface to the different fields sotred in a fl...
NEKTON fld file format.
Definition fld_file.f90:35
Initial flow condition.
Definition flow_ic.f90:34
subroutine, public set_flow_ic_fld(u, v, w, p, file_name, interpolate, mesh_file_name, global_interp_subdict)
Set the initial condition of the flow based on a field. @detail The fields are read from an fld file....
Definition flow_ic.f90:492
subroutine set_flow_ic_point_zone(u, v, w, base_value, zone_name, zone_value)
Set the initial condition of the flow based on a point zone.
Definition flow_ic.f90:439
subroutine set_flow_ic_uniform(u, v, w, uinf)
Uniform initial condition.
Definition flow_ic.f90:294
subroutine set_flow_ic_common(u, v, w, p, coef, gs)
Make the initial velocity continuous across elements.
Definition flow_ic.f90:266
subroutine set_flow_ic_expression(u, v, w, expr)
Set the initial condition from one mathematical expression per velocity component.
Definition flow_ic.f90:323
subroutine, public set_flow_ic_user_incompressible(u, v, w, p, coef, gs, user_proc, scheme_name)
Set initial flow condition (user defined) for incompressible flows.
Definition flow_ic.f90:156
subroutine, public set_flow_ic_builtin(u, v, w, p, coef, gs, type, params)
Set initial flow condition (builtin).
Definition flow_ic.f90:81
subroutine, public set_flow_ic_user_compressible(rho, u, v, w, p, coef, gs, user_proc, scheme_name)
Set initial flow condition (user defined) for compressible flows.
Definition flow_ic.f90:203
subroutine set_flow_ic_blasius(u, v, w, delta, uinf, type)
Set a Blasius profile as initial condition.
Definition flow_ic.f90:365
Defines a flow profile.
real(kind=rp) function, public blasius_quadratic(y, delta, u)
Quadratic approximate Blasius Profile .
real(kind=rp) function, public blasius_quartic(y, delta, u)
Quartic approximate Blasius Profile .
real(kind=rp) function, public blasius_sin(y, delta, u)
Sinusoidal approximate Blasius Profile .
real(kind=rp) function, public blasius_cubic(y, delta, u)
Cubic approximate Blasius Profile .
real(kind=rp) function, public blasius_tanh(y, delta, u)
Hyperbolic tangent approximate Blasius Profile from O. Savas (2012) where is the 99 percent thickne...
real(kind=rp) function, public blasius_linear(y, delta, u)
Linear approximate Blasius profile .
Gather-scatter.
Implements global_interpolation given a dofmap.
Importation of fields from fld files.
Routines to interpolate between different spaces.
Utilities for retrieving parameters from the case files.
subroutine, public json_get_subdict_or_empty(json, key, output)
Extract a sub-object from a json object and returns an empty object if the key is missing.
Logging routines.
Definition log.f90:34
type(log_t), public neko_log
Global log stream.
Definition log.f90:92
integer, parameter, public log_size
Definition log.f90:46
Definition math.F90:60
subroutine, public cfill(a, c, n)
Set all elements to a constant c .
Definition math.F90:611
subroutine, public col2(a, b, n)
Vector multiplication .
Definition math.F90:1095
subroutine, public cfill_mask(a, c, n, mask, n_mask)
Fill a constant to a masked vector. .
Definition math.F90:502
Build configurations.
integer, parameter neko_bcknd_device
integer, parameter, public rp
Global precision used in computations.
Definition num_types.f90:14
Operators.
Definition operators.f90:34
type(point_zone_registry_t), target, public neko_point_zone_registry
Global point_zone registry.
Defines a function space.
Definition space.f90:34
integer, parameter, public gll
Definition space.f90:50
Interfaces for user interaction with NEKO.
Definition user_intf.f90:34
Utilities.
Definition utils.f90:35
integer function, public extract_fld_file_index(fld_filename, default_index)
Extracts the index of a field file. For example, "myfield.f00045" will return 45. If the suffix of th...
Definition utils.f90:248
integer, parameter, public neko_fname_len
Definition utils.f90:42
subroutine, public neko_warning(warning_msg)
Reports a warning to standard output.
Definition utils.f90:454
subroutine, public filename_chsuffix(fname, new_fname, new_suffix)
Change a filename's suffix.
Definition utils.f90:195
Coefficients defined on a given (mesh, ) tuple. Arrays use indices (i,j,k,e): element e,...
Definition coef.f90:136
field_list_t, To be able to group fields together
A wrapper around a polymorphic generic_file_t that handles its init. This is essentially a factory fo...
Definition file.f90:56
Interface for NEKTON fld files.
Definition fld_file.f90:66
Gather-scatter kernel.
Implements global interpolation for arbitrary points in the domain.
Interpolation between two space::space_t.
Base abstract type for point zones.
The function space for the SEM solution fields.
Definition space.f90:64