The solar calculator model provides information about the Sun direction and Sun load model. The available models are: More...
Public Types | |
enum | sunDirModel { mSunDirConstant, mSunDirTraking } |
Sun direction models. More... | |
enum | sunLModel { mSunLoadConstant, mSunLoadFairWeatherConditions, mSunLoadTheoreticalMaximum } |
Direct sun load models. More... | |
Public Member Functions | |
ClassName ("solarCalculator") | |
solarCalculator (const dictionary &, const fvMesh &) | |
Construct from dictionary. More... | |
~solarCalculator () | |
Destructor. More... | |
const vector | direction () const |
const acess to direction More... | |
vector & | direction () |
Non-const access to direction. More... | |
scalar | directSolarRad () |
Return direct solar irradiation. More... | |
scalar | diffuseSolarRad () |
Return diffuse solar irradiation. More... | |
scalar | C () |
Return C consntant. More... | |
scalar | beta () |
Return beta. More... | |
scalar | tetha () |
Return tetha. More... | |
sunDirModel | sunDirectionModel () const |
Return Sun direction model. More... | |
sunLModel | sunLoadModel () const |
Return Sun load model. More... | |
scalar | groundReflectivity () |
Return groundReflectivity. More... | |
const coordinateSystem & | coord () |
Return coordinateSystem. More... | |
scalar | sunTrackingUpdateInterval () |
Return sunTrackingUpdateInterval. More... | |
scalar | startTime () |
Return startTime. More... | |
void | correctSunDirection () |
Recalculate. More... | |
Static Protected Attributes | |
static const NamedEnum< sunDirModel, 2 > | sunDirectionModelTypeNames_ |
Sun direction models. More... | |
static const NamedEnum< sunLModel, 3 > | sunLoadModelTypeNames_ |
Sun load models. More... | |
Private Member Functions | |
solarCalculator (const solarCalculator &) | |
Disallow default bitwise copy construct. More... | |
void | operator= (const solarCalculator &) |
Disallow default bitwise assignment. More... | |
void | init () |
Init. More... | |
void | calculateBetaTetha () |
Calculate beta and tetha angles. More... | |
void | calculateSunDirection () |
Calculate Sun direction. More... | |
Private Attributes | |
const fvMesh & | mesh_ |
Reference to mesh. More... | |
dictionary | dict_ |
Dictionary. More... | |
vector | direction_ |
Direction. More... | |
scalar | directSolarRad_ |
Direct solar irradiation. More... | |
scalar | diffuseSolarRad_ |
Diffuse solar irradiation on vertical surfaces. More... | |
scalar | groundReflectivity_ |
Ground reflectivity. More... | |
scalar | A_ |
Fair weather direct solar load model parameters. More... | |
scalar | B_ |
scalar | beta_ |
scalar | tetha_ |
scalar | Setrn_ |
Maximum theoretical direct solar load model parameters. More... | |
scalar | SunPrime_ |
scalar | C_ |
Diffusive solar load model parameters. More... | |
sunDirModel | sunDirectionModel_ |
Sun direction model. More... | |
sunLModel | sunLoadModel_ |
Sun load model. More... | |
autoPtr< coordinateSystem > | coord_ |
Grid coordinate system. More... | |
vector | eastDir_ |
East grid orientation. More... | |
vector | gridUp_ |
Up grid orientation. More... | |
scalar | sunTrackingUpdateInterval_ |
Interval in decimal hours to update Sun direction for SunDirTraking. More... | |
scalar | startTime_ |
Start time for the Sun position (decimal hours) More... | |
The solar calculator model provides information about the Sun direction and Sun load model. The available models are:
For the Sun direction: 1) SunDirConstant : the direction is given in 'sunDirection' 2) SunDirTraking : the direction is calculated from the following parameters: localStandardMeridian : GMT (Local Zone Meridian) in hours startDay : day from 1 to 365) startTime: in hours longitude: in degrees latitude: in degrees gridUp: grid orientation upwards gridEast grid orientation eastwards
This model should be use in transient calculations. The keyword 'sunTrackingUpdateInterval' (in hours) specifies on which interval is the Sun direction updated.
Solar Load models available: 1) SunLoadConstant: direct and diffusive heat fluxes are provided by the entries 'directSolarRad' and 'diffuseSolarRad'
2) SunLoadFairWeatherConditions: The solar fluxes are calculated following the Fair Weather Conditions Method from the ASHRAE Handbook. The entries are: A : Apparent solar irradiation at air mass m = 0 B : Atmospheric extinction coefficient beta: Solar altitude (in degrees) above the horizontal. This can be read or calculated providing the respective parameters for Sun position explained above. groundReflectivity : ground reflectivity
In this model the flux is calculated as:
directSolarRad = A/exp(B/sin(beta));
3) SunLoadTheoreticalMaximum: The entries are: Setrn SunPrime: groundReflectivity : ground reflectivity
In this model the flux is calculated as:
directSolarRad = Setrn*SunPrime;
The diffuse on vertical/horizontal walls and ground-reflected radiation are calculated following the ASHRAE Handbook.
Definition at line 101 of file solarCalculator.H.
enum sunDirModel |
Sun direction models.
Enumerator | |
---|---|
mSunDirConstant | |
mSunDirTraking |
Definition at line 108 of file solarCalculator.H.
enum sunLModel |
Direct sun load models.
Enumerator | |
---|---|
mSunLoadConstant | |
mSunLoadFairWeatherConditions | |
mSunLoadTheoreticalMaximum |
Definition at line 115 of file solarCalculator.H.
|
private |
Disallow default bitwise copy construct.
solarCalculator | ( | const dictionary & | dict, |
const fvMesh & | mesh | ||
) |
Construct from dictionary.
Definition at line 257 of file solarCalculator.C.
~solarCalculator | ( | ) |
Destructor.
Definition at line 292 of file solarCalculator.C.
|
private |
Disallow default bitwise assignment.
|
private |
Init.
Definition at line 173 of file solarCalculator.C.
References Foam::exit(), Foam::exp(), Foam::FatalError, FatalErrorInFunction, Foam::mag(), Foam::nl, Foam::readScalar(), and Foam::sin().
|
private |
Calculate beta and tetha angles.
Definition at line 68 of file solarCalculator.C.
References Foam::acos(), Foam::asin(), solarCalculator::beta_, Foam::cos(), Foam::degToRad(), delta, solarCalculator::dict_, Foam::e, Foam::endl(), Foam::Info, dictionary::lookup(), M, Foam::max(), solarCalculator::mesh_, solarCalculator::mSunDirConstant, solarCalculator::mSunDirTraking, Foam::constant::mathematical::pi(), Foam::radToDeg(), Foam::readScalar(), Foam::sin(), solarCalculator::startTime_, solarCalculator::sunDirectionModel_, Foam::tab, solarCalculator::tetha_, fvMesh::time(), and dimensioned::value().
|
private |
Calculate Sun direction.
Definition at line 139 of file solarCalculator.C.
References Foam::cos(), Foam::endl(), Foam::Info, Foam::mag(), Foam::sin(), and Vector< scalar >::zero.
ClassName | ( | "solarCalculator" | ) |
const acess to direction
Definition at line 231 of file solarCalculator.H.
References solarCalculator::direction_.
Referenced by solarLoad::updateHitFaces(), and solarHeatLoad::updateHitFaces().
Non-const access to direction.
Definition at line 237 of file solarCalculator.H.
References solarCalculator::direction_.
|
inline |
Return direct solar irradiation.
Definition at line 243 of file solarCalculator.H.
References solarCalculator::directSolarRad_.
|
inline |
Return diffuse solar irradiation.
Definition at line 249 of file solarCalculator.H.
References solarCalculator::diffuseSolarRad_.
|
inline |
Return C consntant.
Definition at line 255 of file solarCalculator.H.
References solarCalculator::C_.
|
inline |
|
inline |
|
inline |
Return Sun direction model.
Definition at line 273 of file solarCalculator.H.
References solarCalculator::sunDirectionModel_.
Referenced by solarLoad::updateHitFaces(), and solarHeatLoad::updateHitFaces().
|
inline |
Return Sun load model.
Definition at line 279 of file solarCalculator.H.
References solarCalculator::sunLoadModel_.
|
inline |
Return groundReflectivity.
Definition at line 285 of file solarCalculator.H.
References solarCalculator::groundReflectivity_.
|
inline |
Return coordinateSystem.
Definition at line 291 of file solarCalculator.H.
References solarCalculator::coord_.
|
inline |
Return sunTrackingUpdateInterval.
Definition at line 297 of file solarCalculator.H.
References solarCalculator::sunTrackingUpdateInterval_.
Referenced by solarLoad::updateHitFaces(), and solarHeatLoad::updateHitFaces().
|
inline |
Return startTime.
Definition at line 303 of file solarCalculator.H.
References solarCalculator::startTime_.
void correctSunDirection | ( | ) |
Recalculate.
Definition at line 298 of file solarCalculator.C.
References Foam::exp(), Foam::max(), and Foam::sin().
Referenced by solarLoad::updateHitFaces(), and solarHeatLoad::updateHitFaces().
|
staticprotected |
Sun direction models.
Definition at line 126 of file solarCalculator.H.
|
staticprotected |
Sun load models.
Definition at line 129 of file solarCalculator.H.
|
private |
Reference to mesh.
Definition at line 137 of file solarCalculator.H.
Referenced by solarCalculator::calculateBetaTetha().
|
private |
Definition at line 140 of file solarCalculator.H.
Referenced by solarCalculator::calculateBetaTetha().
|
private |
Direction.
Definition at line 143 of file solarCalculator.H.
Referenced by solarCalculator::direction().
|
private |
Direct solar irradiation.
Definition at line 146 of file solarCalculator.H.
Referenced by solarCalculator::directSolarRad().
|
private |
Diffuse solar irradiation on vertical surfaces.
Definition at line 149 of file solarCalculator.H.
Referenced by solarCalculator::diffuseSolarRad().
|
private |
Ground reflectivity.
Definition at line 152 of file solarCalculator.H.
Referenced by solarCalculator::groundReflectivity().
|
private |
Fair weather direct solar load model parameters.
Definition at line 155 of file solarCalculator.H.
|
private |
Definition at line 156 of file solarCalculator.H.
|
private |
Definition at line 157 of file solarCalculator.H.
Referenced by solarCalculator::beta(), and solarCalculator::calculateBetaTetha().
|
private |
Definition at line 158 of file solarCalculator.H.
Referenced by solarCalculator::calculateBetaTetha(), and solarCalculator::tetha().
|
private |
Maximum theoretical direct solar load model parameters.
Definition at line 162 of file solarCalculator.H.
|
private |
Definition at line 163 of file solarCalculator.H.
|
private |
Diffusive solar load model parameters.
Definition at line 167 of file solarCalculator.H.
Referenced by solarCalculator::C().
|
private |
Sun direction model.
Definition at line 170 of file solarCalculator.H.
Referenced by solarCalculator::calculateBetaTetha(), and solarCalculator::sunDirectionModel().
|
private |
Sun load model.
Definition at line 173 of file solarCalculator.H.
Referenced by solarCalculator::sunLoadModel().
|
private |
Grid coordinate system.
Definition at line 176 of file solarCalculator.H.
Referenced by solarCalculator::coord().
|
private |
East grid orientation.
Definition at line 179 of file solarCalculator.H.
|
private |
Up grid orientation.
Definition at line 182 of file solarCalculator.H.
|
private |
Interval in decimal hours to update Sun direction for SunDirTraking.
Definition at line 185 of file solarCalculator.H.
Referenced by solarCalculator::sunTrackingUpdateInterval().
|
private |
Start time for the Sun position (decimal hours)
Definition at line 188 of file solarCalculator.H.
Referenced by solarCalculator::calculateBetaTetha(), and solarCalculator::startTime().
Copyright © 2011-2018 OpenFOAM | OPENFOAM® is a registered trademark of OpenCFD Ltd.