ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/SHAPES/SHFunc.hpp
Revision: 1309
Committed: Fri Jun 25 20:10:53 2004 UTC (20 years ago) by chrisfen
File size: 897 byte(s)
Log Message:
Coefficients are now multiplied by the normalization factor - no longer do we need normalization in the visualizer

File Contents

# Content
1 #ifndef _SHFUNC_HPP_
2 #define _SHFUNC_HPP_
3
4 #include <string.h>
5
6 #define SH_SIN 0
7 #define SH_COS 1
8
9 class SHFunc {
10 public:
11
12 SHFunc();
13 virtual ~SHFunc() {}
14
15 void setL(int theL) { L = theL; };
16 int getL() { return L; }
17
18 void setM(int theM) { M = theM; };
19 int getM() { return M; }
20
21 double getCoefficient() {return coefficient;}
22 void setCoefficient(double co) {coefficient = co;}
23
24 void setType(short int theType) {funcType = theType;}
25 void makeSinFunc() {funcType = SH_SIN;}
26 void makeCosFunc() {funcType = SH_COS;}
27 short int getType() { return funcType; }
28 bool isSinFunc() { return funcType == SH_SIN ? true : false;}
29 bool isCosFunc() { return funcType == SH_COS ? true : false;}
30
31 double getValueAt(double costheta, double phi);
32
33 protected:
34
35 double LegendreP (int l, int m, double x);
36
37 int L;
38 int M;
39 short int funcType;
40 double coefficient;
41
42 };
43
44 #endif