modelWeather

Complex weather model

Information

Overview

Supplies weather data using a TRY - data set.

Concept

Input: a TRY data set in an accepted Modelica format (.mat, .txt, with header). The structure should be exactly the one of a TRY, status: TRY 2011.

Output:

  • Total radiation on "n" oriented surfaces
  • Cloud cover
  • Wind direction
  • Wind speed
  • Air temperature
  • Air pressure
  • Mass fraction of water in dry air
  • Relative humidity
  • Long wave sky radiation on horizontal surface
  • Long wave terrestrial radiation from horizontal surface

The outputs can be supplied individually or in one vector, with the exception of total solar radiation, which are always supplied separately in a vector.

Known Limitations

Be aware that the calculation of the total solar radiation may cause problems at simulation times close to sunset and sunrise. In this case, change the cut-off angles. refer to model RadOnTiltedSurf.

References

DWD: TRYHandbuch.2011.DWD,2011

Example Results

Examples.Weather.WeatherModels

  • May 02, 2013  by Ole Odendahl:
    Formatted documentation appropriately, Rewarded 5*****!
  • Mai 1, 2012  by Moritz Lauster and Ana Constantin:
    Improved beyond belief.
  • September 12, 2006  by Timo Haase:
    Implemented.

Parameters

TypeNameDefaultDescription
Location Properties
Modelica.Units.NonSI.Angle_degLatitude49.5latitude of location
Modelica.Units.NonSI.Angle_degLongitude8.5longitude of location
RealGroundReflection0.2ground reflection coefficient
Properties of Weather Data
Modelica.Units.NonSI.Time_hourDiffWeatherDataTime1difference between weather data time and UTC, e.g. +1 for CET
StringtableName"wetter"table name on file or in function usertab
StringfileNameModelica.Utilities.Files.loadResource("modelica://AixLib/Resources/weatherdata/TRY2010_12_Jahr_Modelica-Library.txt")file where matrix is stored
StringformatTRY"TRY 2010/2011"File format of test reference year (TRY)
Real[:]offset{0}offsets of output signals
Modelica.Blocks.Types.SmoothnesssmoothnessModelica.Blocks.Types.Smoothness.LinearSegmentsSmoothness of table interpolation
Modelica.Blocks.Types.ExtrapolationextrapolationModelica.Blocks.Types.Extrapolation.PeriodicExtrapolation of data outside the definition range
Real[1]startTime{0}output = offset for time < startTime (same value for all columns)
Solar radiation on oriented surfaces
DataBase.Weather.SurfaceOrientation.SurfaceOrientationBaseDataDefinitionSODDataBase.Weather.SurfaceOrientation.SurfaceOrientationData_N_E_S_W_Hor()Surface orientation data
Optional output vector
BooleanoutOpttrueOutput individual vectors instead of one vector [-]
BooleanCloud_coverfalseCloud cover [-] (TRY col 7)
BooleanWind_dirfalseWind direction [deg] (TRY col 8)
BooleanWind_speedfalseWind speed [m/s] (TRY col 9)
BooleanAir_tempfalseAir temperature [K] (TRY col 10)
BooleanAir_pressfalseAir pressure [Pa] (TRY col 11)
BooleanMass_fracfalseMass fraction of water in dry air [kg/kg] (TRY col 12)
BooleanRel_humfalseRealtive humidity of air [-] (TRY col 13)
BooleanSky_radfalseLongwave sky radiation on horizontal [W/m2] (TRY col 18)
BooleanTer_radfalseLongwave terrestric radiation from horizontal [W/m2] (TRY col 19)

Connectors

TypeNameDefaultDescription
Utilities.Interfaces.SolarRad_out[SOD.nSurfaces]SolarRadiation_OrientedSurfaces
Modelica.Blocks.Interfaces.RealOutput[m]WeatherDataVector
Modelica.Blocks.Interfaces.RealOutputCloudCover[0..8]
Modelica.Blocks.Interfaces.RealOutputWindDirectionin deg [0...360]
Modelica.Blocks.Interfaces.RealOutputWindSpeedin m/s
Modelica.Blocks.Interfaces.RealOutputAirTempin Kelvin
Modelica.Blocks.Interfaces.RealOutputAirPressurein Pa
Modelica.Blocks.Interfaces.RealOutputWaterInAirin kg/kg
Modelica.Blocks.Interfaces.RealOutputRelHumidityin percent
Modelica.Blocks.Interfaces.RealOutputSkyRadiationin W/m2
Modelica.Blocks.Interfaces.RealOutputTerrestrialRadiationin W/m2

Components

TypeNameDefaultDescription
BaseClasses.SunSun
RadOnTiltedSurface[SOD.nSurfaces]RadOnTiltedSurf
Modelica.Blocks.Sources.CombiTimeTableWeatherData
Modelica.Blocks.Routing.DeMultiplex3deMultiplex
Modelica.Blocks.Math.GainhPa_to_Pa
Modelica.Blocks.Math.Gainpercent_to_unit
Modelica.Blocks.Math.Gaing_to_kg
Modelica.Blocks.Math.UnitConversions.From_degCfrom_degC

Contents

NameDescription
RadOnTiltedSurface