v0.14.0
main_for_gcc.cpp
Go to the documentation of this file.
1 #include "../../src/FTensor.hpp"
2 #include <iostream>
3 using namespace FTensor;
4 using namespace std;
5 
6 #include "test_T0.hpp"
7 #include "test_T1.hpp"
8 #include "test_T2.hpp"
9 #include "test_T2s.hpp"
10 #include "test_T3as.hpp"
11 #include "test_T3ch.hpp"
12 
13 int main()
14 {
15  double t01(12), t02(14);
16 
17  Tensor0<double *> t0_1(&t01), t0_2(&t02);
18  Tensor1<double, 3> t1_1(1., 2., 3.), t1_2(4., 5., 6.), t1_3(7., 8., 9.);
19  Tensor2<double, 3, 3> t2_1(10., 20., 30., 40., 50., 60., 70., 80., 90.),
20  t2_2(11., 21., 31., 41., 51., 61., 71., 81., 91.),
21  t2_3(12., 22., 32., 42., 52., 62., 72., 82., 92.);
22  Tensor2<double, 4, 3> t2_4(10.1, 20.2, 30.3, 40.4, 50.5, 60.6, 70.7, 80.8,
23  90.9, 101., 111.1, 121.2);
24  Tensor2<double, 3, 4> t2_5(310.1, 420.2, 530.3, 640.4, 750.5, 560.6, 670.7,
25  280.8, 190.9, 3101., 4111.1, 8121.2);
26  Tensor2_symmetric<double, 3> t2s_1(13., 23., 33., 43., 53., 63.),
27  t2s_2(14., 24., 34., 44., 54., 64.), t2s_3(15., 25., 35., 45., 55., 65.);
28  Dg<double, 3, 3> t3dg_1(101., 102., 103., 104., 105., 106., 107., 108., 109.,
29  110., 111., 112., 113., 114., 115., 116., 117.,
30  118.),
31  t3dg_2(201., 202., 203., 204., 205., 206., 207., 208., 209., 210., 211.,
32  212., 213., 214., 215., 216., 217., 218.),
33  t3dg_3(301., 302., 303., 304., 305., 306., 307., 308., 309., 310., 311.,
34  312., 313., 314., 315., 316., 317., 318.);
35  Christof<double, 3, 3> t3ch_1(401., 402., 403., 404., 405., 406., 407., 408.,
36  409., 410., 411., 412., 413., 414., 415., 416.,
37  417., 418.),
38  t3ch_2(501., 502., 503., 504., 505., 506., 507., 508., 509., 510., 511.,
39  512., 513., 514., 515., 516., 517., 518.),
40  t3ch_3(601., 602., 603., 604., 605., 606., 607., 608., 609., 610., 611.,
41  612., 613., 614., 615., 616., 617., 618.);
42  Tensor3_antisymmetric<double, 3, 3> t3as_1(701., 702., 703., 704., 705.,
43  706., 707., 708., 709.),
44  t3as_2(801., 802., 803., 804., 805., 806., 807., 808., 809.),
45  t3as_3(901., 902., 903., 904., 905., 906., 907., 908., 909.);
46 
47  test_T0(13, t0_1, t0_2);
48  test_T1(t1_1, t1_2);
49  test_T2(t1_1, t1_2, t2_1, t2_2, t2_4, t2_5);
50  test_T2s(t1_1, t1_2, t2_1, t2_2, t2s_1, t2s_2, t2s_3);
51  test_T3ch(13, t0_1, t0_2, t1_1, t1_2, t2_1, t2_2, t2_3, t2s_1, t2s_2, t2s_3,
52  t3dg_1, t3dg_2, t3dg_3, t3ch_1, t3ch_2, t3ch_3);
53  test_T3as(t1_2, t2_2, t3dg_1, t3dg_2, t3as_1, t3as_2, t3as_3);
54 }
FTensor::Christof
Definition: Christof_value.hpp:9
FTensor
JSON compatible output.
Definition: Christof_constructor.hpp:6
test_T1.hpp
test_T2
void test_T2(const Tensor1< double, 3 > &t1_1, const Tensor1< double, 3 > &t1_2, const Tensor2< double, 3, 3 > &t2_1, const Tensor2< double, 3, 3 > &t2_2, const Tensor2< double, 4, 3 > &t2_4, const Tensor2< double, 3, 4 > &t2_5)
Definition: test_T2.cpp:65
FTensor::Tensor1< double, 3 >
FTensor::Tensor2_symmetric
Definition: Tensor2_symmetric_value.hpp:13
FTensor::Tensor2< double, 3, 3 >
test_T2.hpp
test_T2s
void test_T2s(Tensor1< double, 3 > &t1_1, const Tensor1< double, 3 > &t1_2, Tensor2< double, 3, 3 > &t2_1, const Tensor2< double, 3, 3 > &t2_2, Tensor2_symmetric< double, 3 > &t2s_1, const Tensor2_symmetric< double, 3 > &t2s_2, const Tensor2_symmetric< double, 3 > &t2s_3)
Definition: test_T2s.cpp:133
FTensor::Tensor3_antisymmetric
Definition: Tensor3_antisymmetric_value.hpp:8
test_T1
void test_T1(Tensor1< double, 3 > &t1_1, const Tensor1< double, 3 > &t1_2)
Definition: test_T1.cpp:8
test_T3ch
void test_T3ch(const int &, Tensor0< double * > &, const Tensor0< double * > &, Tensor1< double, 3 > &t1_1, const Tensor1< double, 3 > &, Tensor2< double, 3, 3 > &t2_1, const Tensor2< double, 3, 3 > &, const Tensor2< double, 3, 3 > &, Tensor2_symmetric< double, 3 > &t2s_1, const Tensor2_symmetric< double, 3 > &, const Tensor2_symmetric< double, 3 > &, Dg< double, 3, 3 > &, const Dg< double, 3, 3 > &t3dg_2, const Dg< double, 3, 3 > &, Christof< double, 3, 3 > &t3ch_1, const Christof< double, 3, 3 > &t3ch_2, const Christof< double, 3, 3 > &)
Definition: test_T3ch.cpp:7
test_T3as
void test_T3as(const Tensor1< double, 3 > &t1_2, const Tensor2< double, 3, 3 > &t2_2, Dg< double, 3, 3 > &t3dg_1, const Dg< double, 3, 3 > &t3dg_2, Tensor3_antisymmetric< double, 3, 3 > &t3as_1, const Tensor3_antisymmetric< double, 3, 3 > &t3as_2, const Tensor3_antisymmetric< double, 3, 3 > &t3as_3)
Definition: test_T3as.cpp:44
test_T0.hpp
test_T3as.hpp
test_T2s.hpp
test_T3ch.hpp
FTensor::Dg
Definition: Dg_value.hpp:9
FTensor::Tensor0
Definition: Tensor0.hpp:16
std
Definition: enable_if.hpp:5
main
int main()
Definition: main_for_gcc.cpp:13
test_T0
void test_T0(const int &T, Tensor0< double * > &t0_1, const Tensor0< double * > &t0_2)
Definition: test_T0.cpp:7