v0.15.0
Loading...
Searching...
No Matches
Christof_numeral.hpp
Go to the documentation of this file.
1/* This is for expressions where an int is used for one slot, and an
2 Index for the others, yielding a Tensor2_symmetric_Expr or
3 Tensor2_Expr. */
4
5#pragma once
6
7namespace FTensor
8{
9 template <class A, class T> class Christof_numeral_0
10 {
11 const A iterA;
12 const int N;
13
14 public:
15 T operator()(const int N1, const int N2) const { return iterA(N, N1, N2); }
16 Christof_numeral_0(const A &a, const int NN) : iterA(a), N(NN) {}
17 };
18
19 /* We can use this version for when there is an int in either of the
20 last slots, because Christof is symmetric. */
21
22 template <class A, class T> class Christof_numeral_1
23 {
24 const A iterA;
25 const int N;
26
27 public:
28 T operator()(const int N1, const int N2) const { return iterA(N1, N, N2); }
29 Christof_numeral_1(const A &a, const int NN) : iterA(a), N(NN) {}
30 };
31}
constexpr double a
Christof_numeral_0(const A &a, const int NN)
T operator()(const int N1, const int N2) const
Christof_numeral_1(const A &a, const int NN)
T operator()(const int N1, const int N2) const
Tensors class implemented by Walter Landry.
Definition FTensor.hpp:51