49 ExecSpace
const& exec_space,
50 HodgeStarType hodge_star,
51 MetricDeterminantType metric_determinant,
52 MetricProdType metric_prod)
56 ddc::type_seq_merge_t<tensor::primes<tensor::lower_t<Indices1>>, Indices2>>>
60 ddc::type_seq_merge_t<tensor::primes<tensor::lower_t<Indices1>>, Indices2>>>
61 levi_civita_dom(levi_civita_accessor.domain());
62 ddc::Chunk levi_civita_alloc(
66 typename ExecSpace::memory_space>());
69 ddc::parallel_for_each(
71 hodge_star.non_indices_domain(),
73 typename HodgeStarType::non_indices_domain_t::discrete_element_type elem) {
74 tensor_prod(hodge_star[elem], metric_prod[elem], levi_civita);
75 hodge_star[elem] *= Kokkos::sqrt(Kokkos::abs(metric_determinant(elem)))
89 ExecSpace
const& exec_space,
90 HodgeStarType hodge_star,
94 ddc::to_type_seq_t<typename MetricIndex::subindices_domain_t>>);
96 ddc::to_type_seq_t<typename MetricType::accessor_t::natural_domain_t>>);
101 ddc::Chunk metric_det_alloc(
102 metric.non_indices_domain(),
103 ddc::KokkosAllocator<double, typename ExecSpace::memory_space>());
104 ddc::ChunkSpan metric_det(metric_det_alloc);
106 ddc::Chunk buffer_alloc(
107 ddc::cartesian_prod_t<
108 typename MetricType::non_indices_domain_t,
112 metric.non_indices_domain(),
116 ddc::KokkosAllocator<double, typename ExecSpace::memory_space>());
117 ddc::ChunkSpan buffer(buffer_alloc);
119 ddc::parallel_for_each(
121 metric.non_indices_domain(),
122 KOKKOS_LAMBDA(
typename MetricType::non_indices_domain_t::discrete_element_type elem) {
123 ddc::annotated_for_each(
127 [&](ddc::DiscreteElement<
130 buffer(elem, index) = metric.get(metric.access_element(
140 metric_prod_accessor;
141 ddc::Chunk metric_prod_alloc(
142 ddc::cartesian_prod_t<
143 typename MetricType::non_indices_domain_t,
145 metric.non_indices_domain(),
146 metric_prod_accessor.domain()),
147 ddc::KokkosAllocator<double, typename ExecSpace::memory_space>());
ddc::detail::convert_type_seq_to_discrete_domain_t< ddc::type_seq_merge_t< ddc::detail::TypeSeq< misc::convert_type_seq_to_t< tensor::TensorFullIndex, Indices1 > >, std::conditional_t<(ddc::type_seq_size_v< Indices2 >==0), ddc::detail::TypeSeq<>, ddc::detail::TypeSeq< misc::convert_type_seq_to_t< tensor::TensorAntisymmetricIndex, Indices2 > > > > > hodge_star_domain_t
Tensor(ddc::Chunk< ElementType, SupportType, Allocator >) -> Tensor< ElementType, SupportType, Kokkos::layout_right, typename Allocator::memory_space >