pRC
multi-purpose Tensor Train library for C++
Loading...
Searching...
No Matches
view.hpp
Go to the documentation of this file.
1// SPDX-License-Identifier: BSD-2-Clause
2
3#ifndef pRC_TENSOR_TRAIN_OPERATOR_FUNCTIONS_VIEW_H
4#define pRC_TENSOR_TRAIN_OPERATOR_FUNCTIONS_VIEW_H
5
8
9namespace pRC
10{
11 template<class X, If<TensorTrain::IsOperatorView<RemoveReference<X>>> = 0>
12 static inline constexpr X view(X &&a)
13 {
14 return forward<X>(a);
15 }
16
17 template<class T, class M, class N, class R>
18 static inline constexpr auto view(
20 {
22 }
23
24 template<class T, class M, class N, class R>
25 static inline constexpr auto view(TensorTrain::Operator<T, M, N, R> &a)
26 {
28 }
29
30 template<class T, class M, class N, class R>
31 static inline constexpr auto view(
32 TensorTrain::Operator<T, M, N, R> const &&) = delete;
33}
34#endif // pRC_TENSOR_TRAIN_OPERATOR_FUNCTIONS_VIEW_H
Definition reference_to_const.hpp:20
Definition type_traits.hpp:17
Definition cholesky.hpp:18
static constexpr X view(X &&a)
Returns a TensorView obtained from a TensorView.
Definition view.hpp:22
static constexpr Conditional< IsSatisfied< C >, RemoveConstReference< X >, X > copy(X &&a)
Definition copy.hpp:13