v0.14.0
Loading...
Searching...
No Matches
Functions
Number_test.cpp File Reference
#include "../../FTensor.hpp"
#include <iostream>

Go to the source code of this file.

Functions

int main ()
 

Function Documentation

◆ main()

int main ( )

Definition at line 6 of file Number_test.cpp.

7{
8 Tensor1<double, 3> y(0, 1, 2);
9 Tensor1<double, 3> x(2, 3, 4);
10 Tensor1<double, 3> n(5, 6, 7);
11 Tensor2 t2(1, 2, 3, 4, 5, 6, 7, 8, 9);
12
13 const Index<'i', 3> i;
14 const Index<'j'> j;
15 const Number<0> N0;
16 const Number<1> N1;
17 const Number<2> N2;
18
19 for(int ii = 0; ii < 100000000; ii++)
20 {
21 y(i) += (x(i) + n(i) + t2(i, N0))
22 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
23 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
24 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
25 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
26 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
27 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
28 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
29 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
30 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
31 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
32 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
33 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
34 // -(x(i)+n(i)+t2(i,N0))+(x(i)+n(i)+t2(i,N0))
35 ;
36 }
37 std::cout << y(0) << " " << y(1) << " " << y(2) << std::endl;
38}
static Number< 2 > N2
static Number< 1 > N1
static Number< 0 > N0
FTensor::Index< 'n', SPACE_DIM > n
FTensor::Index< 'i', SPACE_DIM > i
FTensor::Index< 'j', 3 > j