26 template<
class Equation,
int direction>
31 const typename Equation::ConservedVariables& conservedVariables)
32 : equation(equation), conservedVariables(conservedVariables) {
36 template<
typename VectorType>
39 auto eigenValues = equation.template computeEigenValues<direction>
44 real maxEigenValue = 0.0;
46 for (
size_t i = 0; i < eigenValues.size(); ++i) {
47 maxEigenValue = fmax(fabs(eigenValues[i]), maxEigenValue);
51 for (
size_t i = 0; i < eigenValues.size(); ++i) {
52 out[i] = maxEigenValue * in[i];
59 const Equation& equation;
60 typename Equation::ConservedVariables conservedVariables;
#define __host__
Definition: types.hpp:46
__device__ __host__ VectorType operator*(const VectorType &in)
Definition: RusanovMatrix.hpp:37
double real
Definition: types.hpp:65
__device__ __host__ RusanovMatrix(const Equation &equation, const typename Equation::ConservedVariables &conservedVariables)
Definition: RusanovMatrix.hpp:30
#define __device__
Definition: types.hpp:45
Definition: RusanovMatrix.hpp:27
Various utility functions to implement the tecno flux.
Definition: types.hpp:30