-
Notifications
You must be signed in to change notification settings - Fork 11
Material properties
- summary How to create a new material
As shown on the [Inputs] page, creating the `mesh` object for the simulation requires including a material object in the arguments of the `Mesh` instantiation
This means that the `hamopy\materials\standard.py` file contains the definition of an object called `wood_fibre`, which is of the `Material` class and includes all material data.
Material definition in hamopy is a bit tricky, as it was designed to give the user maximum freedom for defining fully customisable transport properties.
This page tells you how to
* [#Material_definition define] a new material, * [#Calling_properties use its properties] once they have been registered, * [#Switch_materials modify] a material in an existing mesh.
For purposes of reusability, the definition of a new material should preferably be done in a separate file which you can then import into your script (like `hamopy.materials.standard` above)
Once there, you may start by instantiating a new `Material` object:
The instantiation may take up to three arguments: the material name, its dry density and specific heat. || *Argument name* || *Format* || *Default value* || || `name` || `string` || `new_material` || || `rho` || `float` || 1000 kg/m^3^ || || `cp` || `float` || 1000 J/(kg.K) ||
Once created, the `Material` object contains the following set of methods to register all material properties.
If not provided at the instantiation, you can specify the dry density of the material like so:
In the current state of hamopy, the heat capacity of the dry material can be defined as a function of the temperature.
When called, the value of the heat capacity will then be `cp = cp_0 + T(°C) * cp_t`
The default value for `cp_t` is 0.
The thermal conductivity may be defined as a function of the moisture content and temperature.
When called, the value of the conductivity will then be `lambda = lambda_0 + w(kg/m3)/1000 * lambda_m + T(°C) * lambda_t`
The default value for `lambda_m` and `lambda_t` is 0.
There are currently two methods for defining the sorption isotherm:
* A 3^rd^ degree polynomial interpolation, fitted on a list of measurement points:
where the list given in the `'W'` key are the values of the moisture content measured at the relative humidities `'HR'`.
* The second method for defining the sorption isotherm is the van Genuchten mono- or multimodal law:
There are currently two methods for defining the water vapor permeability:
* By interpolation between measurement points:
* With the Schirmer law:
There are currently two methods for defining the liquid permeability:
* With an exponential law:
* With the Durner multi-modal law:
Note that if this method is not used in the definition of a material, this permeability will be set to `0` and liquid transfer will not be considered in the calculation.
The air permeability should be given in (m^2^). Only a constant value is expected:
Calling this method is optional: the default air permeability is `0`.
Once defined, all properties may be called as fonctions of the temperature `T` and capillary pressure `p_c`. The following methods are bound within the `Material` class for this purpose
|| *Method* || *Returns* || *Required arguments* || *Optional arguments|| || `rho` || Density || || || || `cp` || Heat capacity || || `T` || || `conduc` || Thermal conductivity || || `p_c`, `T` || || `w` || Moisture content || `p_c` || `T` || || `c_w` || Derivative of the moisture content || `p_c` || `T` || || `delta_p` || Vapor permeability || `p_c` || `T` || || `k_l` || Liquid permeability || `p_c` || `T` || || `k_air` || Air permeability || || ||
- Important*: hamopy is written with the capillary pressure as the driving potential for moisture transfer. All variables depending on the humidity are therefore methods expecting `p_c` as input argument, rather than the value of relative humidity or vapor pressure. Some functions are however available in the [Library] to easily switch from one another.
Once a material has been integrated into a `Mesh` object, it is still possible to change some of its properties and tell the mesh of the modifications:
This functionality is particularly interesting when running a large number of simulations with different material properties, like in case of a sensitivity analysis. The instantiation of the `Mesh` and `Material` objects is not repeated, which saves some time.
[Overview]