-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathThermalForce.h
executable file
·42 lines (33 loc) · 1.21 KB
/
ThermalForce.h
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
/**
* @file ThermalForce.h
* @brief Defines the data and methods of the ThermalForce class
*
* @license This file is distributed under the BSD Open Source License.
* See LICENSE.TXT for details.
**/
#ifndef THERMALFORCE_H
#define THERMALFORCE_H
#include "Force.h"
class ThermalForce : public Force {
public:
ThermalForce(Cloud * const C, const double redFactor);
~ThermalForce();
virtual void force1(const double currentTime); // rk substep 1
virtual void force2(const double currentTime); // rk substep 2
virtual void force3(const double currentTime); // rk substep 3
virtual void force4(const double currentTime); // rk substep 4
virtual void writeForce(fitsfile * const file, int * const error) const;
virtual void readForce(fitsfile * const file, int * const error);
private:
RandCache *evenRandCache, *oddRandCache;
#ifdef DISPATCH_QUEUES
dispatch_group_t evenRandGroup, oddRandGroup;
dispatch_queue_t randQueue;
#endif
void force(const cloud_index currentParticle, const RandCache &RC);
static const doubleV randomCos(const RandCache &RC);
static const doubleV randomSin(const RandCache &RC);
protected:
double heatVal; //<! Strength of thermal force [N]
};
#endif // THERMALFORCE_H