Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
ApplyExtForceDust.hpp
Go to the documentation of this file.
1// -------------------------------------------------------//
2//
3// SHAMROCK code for hydrodynamics
4// Copyright (c) 2021-2026 Timothée David--Cléris <tim.shamrock@proton.me>
5// SPDX-License-Identifier: CeCILL Free Software License Agreement v2.1
6// Shamrock is licensed under the CeCILL 2.1 License, see LICENSE for more information
7//
8// -------------------------------------------------------//
9
10#pragma once
11
18
19#include "shambackends/vec.hpp"
24
25#define NODE_EDGES(X_RO, X_RW) \
26 /* ------------------- inputs ------------------- */ \
27 X_RO(shamrock::solvergraph::ScalarEdge<Tscal>, dt) \
28 X_RO(shamrock::solvergraph::Indexes<u32>, sizes) \
29 X_RO(shamrock::solvergraph::IFieldSpan<Tscal>, spans_rho_dust) \
30 X_RO(shamrock::solvergraph::IFieldSpan<Tscal>, spans_dt_rho_dust) \
31 X_RO(shamrock::solvergraph::IFieldSpan<Tvec>, spans_a_ext) \
32 \
33 /* ------------------- outputs ------------------- */ \
34 X_RW(shamrock::solvergraph::IFieldSpan<Tvec>, spans_rhov_dust)
35
37
46 template<class Tvec>
47 class ApplyExtForceDust : public shamrock::solvergraph::INode {
48 using Tscal = shambase::VecComponent<Tvec>;
49
50 u32 block_size;
51 u32 ndust;
52
53 public:
54 ApplyExtForceDust(u32 block_size, u32 ndust) : block_size(block_size), ndust(ndust) {}
55
56 EXPAND_NODE_EDGES(NODE_EDGES)
57
59
60 inline virtual std::string _impl_get_label() const { return "ApplyExtForceDust"; }
61
62 virtual std::string _impl_get_tex() const;
63 };
64
65} // namespace shammodels::basegodunov::modules
66
67#undef NODE_EDGES
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
Inode is node between data edges, takes multiple inputs, multiple outputs.
Definition INode.hpp:31
namespace for the basegodunov model modules