30#define NODE_EDGES(X_RO, X_RW) \
33 X_RO(shamrock::solvergraph::Indexes<u32>, sizes) \
35 X_RO(shamrock::solvergraph::IFieldSpan<TgridVec>, spans_block_min) \
37 X_RO(shamrock::solvergraph::IFieldSpan<TgridVec>, spans_block_max) \
41 X_RW(shamrock::solvergraph::IFieldSpan<Tvec>, spans_coordinates)
45 template<
class Tvec,
class Tgr
idVec>
47 using Tscal = shambase::VecComponent<Tvec>;
52 Tscal grid_coord_to_pos_fact;
55 NodeComputeCoordinates(
u32 block_size,
u32 block_nside, Tscal grid_coord_to_pos_fact)
56 : block_size(block_size), block_nside(block_nside),
57 grid_coord_to_pos_fact(grid_coord_to_pos_fact) {
59 if (block_nside != 2) {
61 shambase::format(
"this module assume block_nside=2, got {}", block_nside));
65 EXPAND_NODE_EDGES(NODE_EDGES)
69 inline virtual std::string
_impl_get_label()
const {
return "ComputeCoordinates"; }
utility to manipulate AMR blocks
std::uint32_t u32
32 bit unsigned integer
virtual std::string _impl_get_tex() const
get the tex of the node
virtual std::string _impl_get_label() const
get the label of the node
void _impl_evaluate_internal()
evaluate the node
Inode is node between data edges, takes multiple inputs, multiple outputs.
void throw_with_loc(std::string message, SourceLocation loc=SourceLocation{})
Throw an exception and append the source location to it.
namespace for the basegodunov model modules
utility class to handle AMR blocks