stardis

Perform coupled heat transfer calculations
git clone git://git.meso-star.fr/stardis.git
Log | Files | Refs | README | LICENSE

stardis-solid.h (1872B)


      1 /* Copyright (C) 2018-2025 |Méso|Star> (contact@meso-star.com)
      2  *
      3  * This program is free software: you can redistribute it and/or modify
      4  * it under the terms of the GNU General Public License as published by
      5  * the Free Software Foundation, either version 3 of the License, or
      6  * (at your option) any later version.
      7  *
      8  * This program is distributed in the hope that it will be useful,
      9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
     10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
     11  * GNU General Public License for more details.
     12  *
     13  * You should have received a copy of the GNU General Public License
     14  * along with this program. If not, see <http://www.gnu.org/licenses/>. */
     15 
     16 #ifndef SDIS_SOLID_H
     17 #define SDIS_SOLID_H
     18 
     19 #include <rsys/rsys.h>
     20 #include <rsys/str.h>
     21 
     22 struct stardis;
     23 struct mem_allocator;
     24 
     25 /*******************************************************************************
     26  * Solid data
     27  ******************************************************************************/
     28 struct solid {
     29   struct str name;
     30   double lambda; /* Conductivity */
     31   double rho; /* Volumic mass */
     32   double cp; /* Calorific capacity */
     33   double delta; /* Numerical parameter */
     34   double tinit; /* Initial temperature */
     35   double imposed_temperature; /* Impose a T; SDIS_TEMPERATURE_NONE if unset */
     36   double vpower;
     37   double t0; /* End time of tinit */
     38   int is_outside; /* the solid is used for a boundary */
     39   int is_green; /* green computation (nothing to do with solid itself) */
     40   unsigned desc_id;
     41   unsigned solid_id;
     42 };
     43 
     44 res_T
     45 init_solid(struct mem_allocator* allocator, struct solid** dst);
     46 
     47 void
     48 release_solid
     49   (struct solid* desc,
     50    struct mem_allocator* allocator);
     51 
     52 res_T
     53 str_print_solid(struct str* str, const struct solid* solid);
     54 
     55 res_T
     56 create_solver_solid
     57   (struct stardis* stardis,
     58    const struct solid* solid_props);
     59 
     60 #endif