Lines Matching +full:runs +full:- +full:on
1 ! Copyright (c) 2017-2026, Lawrence Livermore National Security, LLC and other CEED contributors.
2 ! All Rights Reserved. See the top-level LICENSE and NOTICE files for details.
4 ! SPDX-License-Identifier: BSD-2-Clause
10 …es a simple usage of libCEED to compute the volume of a 3D body using matrix-free application of a…
13 ! The example has no dependencies, and is designed to be self-contained.
16 ! All libCEED objects use a Ceed device object constructed based on a command line argument (-ceed).
20 ! make ex1-volume [CEED_DIR = </path/to/libceed>]
22 ! Sample runs:
24 ! ./ex1-volume-f
25 ! ./ex1-volume-f -ceed /cpu/self
26 ! ./ex1-volume-f -ceed /gpu/cuda
28 ! Test in 1D-3D
29 ! TESTARGS(name = "1D User QFunction") -ceed {ceed_resource} -d 1 -t
30 ! TESTARGS(name = "2D User QFunction") -ceed {ceed_resource} -d 2 -t
31 ! TESTARGS(name = "3D User QFunction") -ceed {ceed_resource} -d 3 -t
32 ! TESTARGS(name = "1D Gallery QFunction") -ceed {ceed_resource} -d 1 -t -g
33 ! TESTARGS(name = "2D Gallery QFunction") -ceed {ceed_resource} -d 2 -t -g
34 ! TESTARGS(name = "3D Gallery QFunction") -ceed {ceed_resource} -d 3 -t -g
39 include 'ex1-volume-f.h'
41 !-----------------------------------------------------------------------
68 r = r - 1
74 !-----------------------------------------------------------------------
112 nd(i) = num_xyz(i) * (p - 1) + 1
116 ! elem: 0 1 n-1
117 ! |---*-...-*---|---*-...-*---|- ... -|--...--|
118 ! num_nodes: 0 1 p-1 p p+1 2*p n*p
126 re = i - 1
136 r_nodes = j - 1
139 g_nodes = g_nodes + (e_xyz(k) * (p - 1) + mod(r_nodes, p)) * g_nodes_stride
143 elem_nodes((i - 1) * num_nodes + j) = g_nodes
156 !-----------------------------------------------------------------------
176 coords(i) = 0.5d0 + (1.d0/sqrt(3.d0)) * sin((2.d0/3.d0) * m_pi * (coords(i) - 0.5d0))
192 !-----------------------------------------------------------------------
218 nd(i) = num_xyz(i) * (p - 1) + 1
235 r_nodes = i - 1
239 … coords(scalar_size * (j - 1) + i) = ((d_1d/(p - 1)) + nodes(mod(d_1d, p - 1) + 1))/num_xyz(j)
252 !-----------------------------------------------------------------------
288 prob_size = -1
302 case ('-h')
305 case ('-c', '-ceed')
308 case ('-d')
313 case ('-m')
317 case ('-p')
321 case ('-q')
325 case ('-s')
329 case ('-b')
334 case ('-t')
337 case ('-g')
354 write (*, *) ' Ceed specification [-c] : ', ceed_spec
355 write (*, *) ' Mesh dimension [-d] : ', fe_dim
356 write (*, *) ' Mesh degree [-m] : ', mesh_degree
357 write (*, *) ' Solution degree [-p] : ', sol_degree
358 write (*, *) ' Num. 1D quadrature pts [-q] : ', num_qpts
359 write (*, *) ' Approx. # unknowns [-s] : ', prob_size
361 write (*, *) ' QFunction source [-g] : gallery'
363 write (*, *) ' QFunction source [-g] : header'
367 write (*, *) 'Test/quiet mode is OFF (use -t to enable)'
369 write (*, *) 'Test/quiet mode is ON'
375 ! Select appropriate backend and logical device based on the (-ceed) command line argument
383 ! Determine the mesh size based on the given approximate problem size
440 &//'ex1-volume-f-c.h:build_mass'//char(0), qf_build, err)
468 &//'ex1-volume-f-c.h:apply_mass'//char(0), qf_apply, err)
480 ! Create auxiliary solution-size vectors
497 ! Benchmark runs
500 write (*, *) ' Executing ', benchmark, ' benchmarking runs...'
523 write (*, *) 'Volume error :', (exact_volume - computed_volume)
527 if (abs(exact_volume - computed_volume) > 200.d0 * 1e-15) then
529 write (*, *) 'Volume error : ', (exact_volume - computed_volume)
533 if (abs(exact_volume - computed_volume) > 1e-5) then
535 write (*, *) 'Volume error : ', (exact_volume - computed_volume)
557 !-----------------------------------------------------------------------