/home/runner/work/kynema/kynema/kynema/src/solver/contribute_lambda_to_vector.hpp Source File

Kynema API: /home/runner/work/kynema/kynema/kynema/src/solver/contribute_lambda_to_vector.hpp Source File
Kynema API
A flexible multibody structural dynamics code for wind turbines
Loading...
Searching...
No Matches
contribute_lambda_to_vector.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <Kokkos_Core.hpp>
4
6
7namespace kynema::solver {
8
13template <typename DeviceType>
15 template <typename ValueType>
16 using View = Kokkos::View<ValueType, DeviceType>;
17 template <typename ValueType>
19 template <typename ValueType>
20 using LeftView = Kokkos::View<ValueType, Kokkos::LayoutLeft, DeviceType>;
21
24
27
30
32
34 void operator()(size_t constraint) const {
35 const auto base_num_dofs = count_active_dofs(base_node_freedom_signature(constraint));
36 const auto first_base_dof = base_node_freedom_table(constraint, 0);
37 for (auto component = 0U; component < base_num_dofs; ++component) {
38 Kokkos::atomic_add(
40 );
41 }
42
43 const auto target_num_dofs = count_active_dofs(target_node_freedom_signature(constraint));
44 const auto first_target_dof = target_node_freedom_table(constraint, 0);
45 for (auto component = 0U; component < target_num_dofs; ++component) {
46 Kokkos::atomic_add(
49 );
50 }
51 }
52};
53
54} // namespace kynema::solver
Definition calculate_error_sum_squares.hpp:5
A kernel which contributes the constraint Lagrange multiplier terms to the correct locations in the g...
Definition contribute_lambda_to_vector.hpp:14
ConstView< size_t *[6]> target_node_freedom_table
Definition contribute_lambda_to_vector.hpp:26
Kokkos::View< ValueType, DeviceType > View
Definition contribute_lambda_to_vector.hpp:16
typename View< ValueType >::const_type ConstView
Definition contribute_lambda_to_vector.hpp:18
ConstView< dof::FreedomSignature * > target_node_freedom_signature
Definition contribute_lambda_to_vector.hpp:23
Kokkos::View< ValueType, Kokkos::LayoutLeft, DeviceType > LeftView
Definition contribute_lambda_to_vector.hpp:20
ConstView< dof::FreedomSignature * > base_node_freedom_signature
Definition contribute_lambda_to_vector.hpp:22
ConstView< double *[6]> base_lambda_residual_terms
Definition contribute_lambda_to_vector.hpp:28
ConstView< size_t *[6]> base_node_freedom_table
Definition contribute_lambda_to_vector.hpp:25
KOKKOS_FUNCTION void operator()(size_t constraint) const
Definition contribute_lambda_to_vector.hpp:34
ConstView< double *[6]> target_lambda_residual_terms
Definition contribute_lambda_to_vector.hpp:29
LeftView< double *[1]> R
Definition contribute_lambda_to_vector.hpp:31