aboutsummaryrefslogtreecommitdiff
path: root/src/basis.h
blob: 25eb0ae2efad13cd787f8514f7f24f1d746fd2da (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
 * basis.h
 *
 * Handle basis structures
 *
 * (c) 2007 Thomas White <taw27@cam.ac.uk>
 *
 *  dtr - Diffraction Tomography Reconstruction
 *
 */
 
#ifndef BASIS_H
#define BASIS_H

#ifdef HAVE_CONFIG_H
#include <config.h>
#endif

#include "control.h"

typedef struct {
	
	double x;
	double y;
	double z;
	
} Vector;

typedef struct basis_struct {
	Vector a;
	Vector b;
	Vector c;
} Basis;

typedef struct cell_struct {
	double a;
	double b;
	double c;
	double alpha;
	double beta;
	double gamma;
} UnitCell;

extern double basis_efom(struct reflectionlist_struct *reflectionlist, Basis *basis);
extern Basis basis_add(Basis u, Basis v);
extern UnitCell basis_get_cell(Basis *cell);

#endif	/* BASIS_H */