CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

| Download

GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it

Views: 418386
1
#include"typedef.h"
2
#include"getput.h"
3
#include"matrix.h"
4
#include"bravais.h"
5
6
int INFO_LEVEL;
7
8
main (int argc, char *argv[])
9
{
10
11
matrix_TYP **T,
12
*X;
13
bravais_TYP *G, *B;
14
int anz;
15
16
17
read_header(argc, argv);
18
if(FILEANZ != 2)
19
{
20
printf("Usage: Conj_bravais 'file1' 'file2' [-i] \n");
21
printf("\n");
22
printf("file1: bravais_TYP containing the group G.\n");
23
printf("file2: matrix_TYP containing a single matrix T.\n");
24
printf("\n");
25
printf("The program calculates TGT^{-1} and transforms all relevant\n");
26
printf("data of G. The result is a bravais_TYP, that is written to\n");
27
printf("standart output.\n");
28
printf("\n");
29
printf("Options:\n");
30
printf(" -i : Transform the group by T^{-1} G T.\n");
31
printf("\n");
32
if (is_option('h')){
33
exit(0);
34
}
35
else{
36
exit(31);
37
}
38
}
39
G = get_bravais(FILENAMES[0]);
40
T = mget_mat (FILENAMES[1], &anz);
41
rat2kgv(T[0]);
42
43
if (is_option('i')){
44
X = mat_inv(T[0]);
45
free_mat(T[0]);
46
T[0] = X;
47
}
48
49
B = konj_bravais(G, T[0]);
50
put_bravais(B, NULL, "konjugated bravais group");
51
52
exit(0);
53
}
54
55