rheolef  6.5
geo_element_indirect_tst.cc
Go to the documentation of this file.
1 // alloues dynamiquement => la memoire n'est pas contigue globalement
2 #include "rheolef/distributed.h"
3 #include "rheolef/geo_element_indirect.h"
4 using namespace rheolef;
5 using namespace std;
6 
7 int main(int argc, char**argv)
8 {
9  environment distributed (argc, argv);
10  clog << "sizeof(size_t) = "
11  << sizeof(size_t) << endl;
12  clog << "sizeof(geo_element_indirect) = "
13  << sizeof(geo_element_indirect) << endl;
15  clog << "initial : "; x.dump(clog); clog << endl;
16  clog << "set shift 0 : "; x.set_shift(0); x.dump(clog); clog << endl;
17  cout << "shift = " << x.shift() << endl << flush;
18  clog << "set shift 7 : "; x.set_shift(7); x.dump(clog); clog << endl;
19  cout << "shift = " << x.shift() << endl << flush;
20  clog << "set orient -1 : "; x.set_orientation(-1); x.dump(clog); clog << endl;
21  cout << "orient = " << x.orientation() << endl << flush;
22  clog << "set orient 1 : "; x.set_orientation(1); x.dump(clog); clog << endl;
23  cout << "orient = " << x.orientation() << endl << flush;
24  clog << "set index 0 : "; x.set_index(0); x.dump(clog); clog << endl;
25  cout << "index = " << x.index() << endl << flush;
26  clog << "set index 8 : "; x.set_index(8); x.dump(clog); clog << endl;
27  cout << "index = " << x.index() << endl << flush;
28 }
29