source: ThirdParty/mpqc_open/src/lib/math/symmetry/testpg.cc

Candidate_v1.6.1
Last change on this file was 860145, checked in by Frederik Heber <heber@…>, 8 years ago

Merge commit '0b990dfaa8c6007a996d030163a25f7f5fc8a7e7' as 'ThirdParty/mpqc_open'

  • Property mode set to 100644
File size: 940 bytes
Line 
1
2#include <math/symmetry/pointgrp.h>
3#include <math/symmetry/corrtab.h>
4
5using namespace sc;
6
7main(int argc, char *argv[])
8{
9 Ref<PointGroup> pg = new PointGroup(argv[1]);
10 Ref<PointGroup> pg2;
11 if (argc > 2) pg2 = new PointGroup(argv[2]);
12
13 //pg.char_table().print();
14
15 CharacterTable ct = pg->char_table();
16 CharacterTable ct2;
17 ct2=ct;
18
19 ct.print();
20
21 if (pg2.nonnull()) {
22 pg2->char_table().print();
23 if (argc <= 3) {
24 CorrelationTable corrtab(pg,pg2);
25 corrtab.print();
26 }
27 }
28
29 // test given axis rearrangements
30 for (int i=3; i<argc; i++) {
31 pg2->symm_frame().zero();
32 for (int j=0; j<3; j++) {
33 if (argv[i][j] == 'x') pg2->symm_frame()(j,0) = 1.0;
34 else if (argv[i][j] == 'y') pg2->symm_frame()(j,1) = 1.0;
35 else if (argv[i][j] == 'z') pg2->symm_frame()(j,2) = 1.0;
36 }
37 CorrelationTable corrtab(pg,pg2);
38 corrtab.print();
39 }
40}
Note: See TracBrowser for help on using the repository browser.