ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-3.0/src/types/ShapeType.cpp
Revision: 1590
Committed: Mon Oct 18 16:29:53 2004 UTC (19 years, 8 months ago) by gezelter
File size: 1240 byte(s)
Log Message:
Working on getting Shapes into OOPSE

File Contents

# Content
1 #include "types/ShapeType.hpp"
2
3 using namespace oopse;
4
5 ShapeType::ShapeType(void) {
6 mass = 0.0;
7 I = new Matrix3x3d();
8
9 }
10
11 ShapeType::~ShapeType(void) {
12 }
13
14 double ShapeType::getContactValueAt(double costheta, double phi) {
15
16 vector<RealSphericalHarmonic*>::iterator contactIter;
17 double contactVal;
18
19 contactVal = 0.0;
20
21 for(contactIter = contactFuncs.begin(); contactIter != contactFuncs.end();
22 ++contactIter)
23 contactVal += (*contactIter)->getValueAt(costheta, phi);
24
25 return contactVal;
26 }
27
28 double ShapeType::getRangeValueAt(double costheta, double phi) {
29
30 vector<RealSphericalHarmonic*>::iterator rangeIter;
31 double rangeVal;
32
33 rangeVal = 0.0;
34
35 for(rangeIter = rangeFuncs.begin(); rangeIter != rangeFuncs.end();
36 ++rangeIter)
37 rangeVal += (*rangeIter)->getValueAt(costheta, phi);
38
39 return rangeVal;
40 }
41
42 double ShapeType::getStrengthValueAt(double costheta, double phi) {
43
44 vector<RealSphericalHarmonic*>::iterator strengthIter;
45 double strengthVal;
46
47 strengthVal = 0.0;
48
49 for(strengthIter = strengthFuncs.begin();
50 strengthIter != strengthFuncs.end();
51 ++strengthIter)
52 strengthVal += (*strengthIter)->getValueAt(costheta, phi);
53
54 return strengthVal;
55 }