My Project
 All Classes Functions Variables Pages
musr.h
1 #ifndef MUSR_H
2 #define MUSR_H
3 
4 #include <cmath>
5 #include <stdio.h>
6 #include "array.h"
7 #include <gsl/gsl_matrix.h>
8 #include <gsl/gsl_linalg.h>
9 #include <gsl/gsl_blas.h>
10 
11 typedef struct vector{
12  double x,y,sqr,abs;
13  int m,n;
14 }vector;
15 
16 class MuSR{
17 public:
18  MuSR();
19  double sigma_triang(double Bex, double Bc2, double lambda);
20  double sigma_triangBLAS(double Bex, double Bc2, double lambda);
21  double sigma_quadBLAS(double Bex, double Bc2, double lambda);
22 private:
23  double Phi0;
24  double kappa;
25  double b;
26  double x1;
27  double x2;
28  double y2;
29  double S;
30  double Bctherm;
31  int N;
32  int NR;
33  int MaxIteration;
34  //reciproal space
35  int NK;
36  vector* K;
37  double* aAk;
38  double* ak;
39  double* bk;
40  // real space
41  int Nx;
42  int Ny;
43  double* x;
44  double* y;
45  double **B;
46  double **QAx;
47  double **QAy;
48  double **Q2;
49  double **Qx;
50  double **Qy;
51  double **p;
52  double **g;
53  double **w;
54  double **dwx;
55  double **dwy;
56  double **wA;
57  double **dwAx;
58  double **dwAy;
59 
60  double avgw;
61  double avgw2;
62  double avgw_wQ2_g;
63  double Bex;
64 
65  gsl_matrix* cosKR;
66  gsl_matrix* one_cosKR;
67  gsl_matrix* sinKRkx;
68  gsl_matrix* sinKRky;
69  gsl_matrix* sinKRQx;
70  gsl_matrix* sinKRQy;
71 
72  gsl_vector* vt;
73  gsl_vector* aK;
74  gsl_vector* aAK;
75  gsl_vector* bK;
76  gsl_vector* WR;
77  gsl_vector* dWxR;
78  gsl_vector* dWyR;
79  gsl_vector* Q2R;
80  gsl_vector* QxR;
81  gsl_vector* QyR;
82  gsl_vector* QAxR;
83  gsl_vector* QAyR;
84  gsl_vector* gR;
85  gsl_vector* pR;
86  gsl_vector* BR;
87 
88 
89 
90 
91  vector get_K(double m, double n);
92  double get_Q2(int iR);
93  double get_g(int iR);
94  double get_p(int iR);
95  void recalc_kspace_funtions();
96  void init_kspace(double Bex, double Bc2, double lambda);
97  void init_quadkspace(double Bex, double Bc2, double lambda);
98  void free_kspace();
99  void init_realspace();
100  void init_quadrealspace();
101  void free_realspace();
102  void init_BLAS(double Bex, double Bc2, double lambda);
103  void init_quadBLAS(double Bex, double Bc2, double lambda);
104  void free_BLAS();
105  double Kr(int ik, int ix, int iy);
106 };
107 
108 #endif // MUSR_H
Definition: musr.h:11
Definition: musr.h:16