From 76a4a376f786c79b4c3005a295631dbf570d4d06 Mon Sep 17 00:00:00 2001 From: congo Date: Fri, 9 Dec 2022 14:19:16 +0100 Subject: [PATCH 1/2] update 2dbuilding_ns --- .../heatfluid/examples/2Dbuilding_NS/aero.cfg | 2 +- .../examples/2Dbuilding_NS/aero.json | 48 ++++++++++++------- 2 files changed, 33 insertions(+), 17 deletions(-) diff --git a/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.cfg b/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.cfg index fd9e0ac1..38de4425 100644 --- a/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.cfg +++ b/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.cfg @@ -5,7 +5,7 @@ case.dimension=2 [heat-fluid] mesh.filename=$cfgdir/aero.geo gmsh.hsize=0.025#0.01#0.02#0.07#0.1 -filename=$cfgdir/aero.json +json.filename=$cfgdir/aero.json use-natural-convection=1 Boussinesq.ref-temperature=280#293.15 diff --git a/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.json b/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.json index 207143f3..011a53cf 100644 --- a/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.json +++ b/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.json @@ -2,14 +2,31 @@ { "Name": "Thermo dynamics", "ShortName":"ThermoDyn", + "Metadata": + { + "version": "1", + "author": ["vincentchabannes","prudhomm","lberti","jobinhio"], + "date": "28/11/2022", + "references":[""] + }, "Models": { - "use-model-name":1, "fluid": { "equations": "Navier-Stokes" } }, + "Meshes": + { + "heatfluid": + { + "Import": + { + "mesh.filename":"$cfgdir/aero.geo", + "gmsh.hsize":"0.025" // 0.025#0.01#0.02#0.07#0.1 + } + } + }, "Materials": { "air": @@ -39,19 +56,19 @@ }, "BoundaryConditions": { - "velocity": + "fluid": { - "Dirichlet": + "velocity": { "exterior-walls": { "expr":"{0,0}" }, - "internal-surfaces": { "expr":"{0,0}" }, + "internal-surfaces": { "expr":"{0,0}" }, "heater1": { "expr":"{0,0}" }, "heater2": { "expr":"{0,0}" } } }, - "temperature": + "heat": { - "Dirichlet": + "temperature": { "heater1": { "expr":"310"/*"330"*/ }, "heater2": { "expr":"300"/*"320"*/ } @@ -63,7 +80,7 @@ "expr1":"1.0/(0.06+0.01/0.5 + 0.3/0.8 + 0.20/0.032 +0.016/0.313 +0.14)",// h coeff "expr2":"280"// temperature exterior }, - "exterior-walls-nofluid": + "exterior-walls-nofluid": { "expr1":"1.0/(0.06+0.01/0.5 + 0.3/0.8 + 0.20/0.032 +0.016/0.313 +0.14)",// h coeff "expr2":"280"// temperature exterior @@ -74,19 +91,18 @@ }, "PostProcess": { - "use-model-name":1, - "heat-fluid": + "heatfluid": { "Exports": { "fields":["fluid.velocity","fluid.pressure","heat.temperature","fluid.pid"] - } - }, - "fluid": - { - }, - "heat": - { + }, + "fluid": + { + }, + "heat": + { + } } } } From a10072ea492afe39d57e8c64f560b72fa9d7a815 Mon Sep 17 00:00:00 2001 From: congo Date: Fri, 9 Dec 2022 14:19:55 +0100 Subject: [PATCH 2/2] add report and imagesprefix as described in #144 --- .../heatfluid/pages/2Dbuilding_NS/README.adoc | 16 +- .../2Dbuilding_NS/heatfluid-information.adoc | 1388 +++++++++++++++++ 2 files changed, 1398 insertions(+), 6 deletions(-) create mode 100644 examples/modules/heatfluid/pages/2Dbuilding_NS/heatfluid-information.adoc diff --git a/examples/modules/heatfluid/pages/2Dbuilding_NS/README.adoc b/examples/modules/heatfluid/pages/2Dbuilding_NS/README.adoc index fa8f0ffa..896fd90c 100644 --- a/examples/modules/heatfluid/pages/2Dbuilding_NS/README.adoc +++ b/examples/modules/heatfluid/pages/2Dbuilding_NS/README.adoc @@ -2,6 +2,9 @@ :page-vtkjs: true :uri-data: https://github.com/feelpp/toolbox/blob/master/examples/modules/heatfluid/examples :uri-data-edit: https://github.com/feelpp/toolbox/edit/master/examples/modules/heatfluid/examples +:imagesprefix: +ifdef::env-github,env-browser,env-vscode[:imagesprefix: ../../assets/images/] + In this example, we simulate the phenomena of natural convection in an apartment of 2 rooms. We use the Navier-Stokes model to simulate the natural convection and the toolbox `heatfluid` to solve it. @@ -25,6 +28,7 @@ Copy case option to clipboard ++++ +NOTE: The report of the execution of the command above is available xref:2Dbuilding_NS/heatfluid-information.adoc[here]. == Data files The case data files are available in Github link:{uri-data}/2Dbuilding_NS/[here] @@ -40,7 +44,7 @@ stem:[\quad]The 2D thermal model of two parts separated by plaster is considered .Geometry of stem:[\Omega = \cup^3_{i=1} \Omega_i] with stem:[\partial \Omega = \Gamma_{D} \cup \Gamma_R] |==== -a| image:2Dbuilding_NS/geo.png[] +a| image:{imagesprefix}2Dbuilding_NS/geo.png[] |==== @@ -146,7 +150,7 @@ T = T_0 .Mesh with GMSH |==== -a| image:2Dbuilding_NS/mesh.png[] +a| image:{imagesprefix}2Dbuilding_NS/mesh.png[] |==== @@ -199,13 +203,13 @@ We observe that the flow circulate from the bottom to the top. The cooler fluid .Heat fluid over times |==== -a| image:2Dbuilding_NS/image1.png[] a| image:2Dbuilding_NS/image2.png[] -a| image:2Dbuilding_NS/image3.png[] a| image:2Dbuilding_NS/image4.png[] +a| image:{imagesprefix}2Dbuilding_NS/image1.png[] a| image:{imagesprefix}2Dbuilding_NS/image2.png[] +a| image:{imagesprefix}2Dbuilding_NS/image3.png[] a| image:{imagesprefix}2Dbuilding_NS/image4.png[] |==== .Average of temperature over times |==== -a| image:2Dbuilding_NS/graph1.png[] +a| image:{imagesprefix}2Dbuilding_NS/graph1.png[] |==== The graph show the steady state of temperature at 300K in all domains. @@ -213,7 +217,7 @@ The graph show the steady state of temperature at 300K in all domains. .Fluid velocity and pressure |==== -a| image:2Dbuilding_NS/velocity.png[] a|image:2Dbuilding_NS/pressure.png[] +a| image:{imagesprefix}2Dbuilding_NS/velocity.png[] a|image:{imagesprefix}2Dbuilding_NS/pressure.png[] |==== diff --git a/examples/modules/heatfluid/pages/2Dbuilding_NS/heatfluid-information.adoc b/examples/modules/heatfluid/pages/2Dbuilding_NS/heatfluid-information.adoc new file mode 100644 index 00000000..0a01df1d --- /dev/null +++ b/examples/modules/heatfluid/pages/2Dbuilding_NS/heatfluid-information.adoc @@ -0,0 +1,1388 @@ +:sectnums: + += Toolbox::heatfluid - Use Case Study + +== Environment + +[cols="2"] +|=== +<|prefix +<|heat-fluid + +<|keyword +<|heatfluid + +<|root repository +<|/home/congo/feelppdb/applications/models/aerothermics/ThermalBuilding/2d/np_1 + +<|number of processus +<|1 +|=== + + +== Materials Properties + +[cols="2"] +|=== +<|number of materials +<|2 +|=== + + +=== Material : air + +[cols="5",options="header"] +|=== +<|Name +<|Expression +<|Symbol +<|Shape +<|Components + +<|density +<|1 +<|materials_air_rho +<|scalar +<| + +<|dynamic-viscosity +<|0.0265 +<|materials_air_mu +<|scalar +<| + +<|specific-heat-capacity +<|1004 +<|materials_air_Cp +<|scalar +<| + +<|thermal-conductivity +<|0.03 +<|materials_air_k +<|scalar +<| + +<|thermal-expansion +<|0.00366 +<|materials_air_beta +<|scalar +<| +|=== + + +=== Material : internal-walls + +[cols="5",options="header"] +|=== +<|Name +<|Expression +<|Symbol +<|Shape +<|Components + +<|density +<|150 +<|materials_internal-walls_rho +<|scalar +<| + +<|dynamic-viscosity +<|1.0 +<|materials_internal-walls_mu +<|scalar +<| + +<|specific-heat-capacity +<|1000 +<|materials_internal-walls_Cp +<|scalar +<| + +<|thermal-conductivity +<|0.25 +<|materials_internal-walls_k +<|scalar +<| + +<|thermal-expansion +<|0.0 +<|materials_internal-walls_beta +<|scalar +<| +|=== + + +=== Multi-Materials + +[cols="5",options="header"] +|=== +<|Name +<|Expression +<|Symbol +<|Shape +<|Components + +<|density +<|concat(...) +<|materials_rho +<|scalar +<| + +<|dynamic-viscosity +<|concat(...) +<|materials_mu +<|scalar +<| + +<|specific-heat-capacity +<|concat(...) +<|materials_Cp +<|scalar +<| + +<|thermal-conductivity +<|concat(...) +<|materials_k +<|scalar +<| + +<|thermal-expansion +<|concat(...) +<|materials_beta +<|scalar +<| +|=== + + + +== Meshes + +=== Mesh : heatfluid + +[cols="2"] +|=== +<|Discretization +<|/Mesh/heatfluid + +<|filename +<|/home/congo/feelppdb/applications/models/aerothermics/ThermalBuilding/2d/np_1/heatfluid.mesh.msh +|=== + + +==== Import configuration + +[cols="2"] +|=== +<|geo-filename +<|/home/congo/Document/toolbox/examples/modules/heatfluid/examples/2Dbuilding_NS/aero.geo + +<|hsize +<|2.500000e-02 + +<|generate-partitioning +<|0 +|=== + + +==== Discretization + +[cols="2"] +|=== +<|dim +<|2 + +<|h_average +<|1.752744e-02 + +<|h_max +<|3.346642e-02 + +<|h_min +<|4.036591e-03 + +<|n_elements +<|20656 + +<|n_faces +<|31304 + +<|n_partition +<|1 + +<|n_points +<|10647 + +<|order +<|1 + +<|real_dim +<|2 + +<|shape +<|Simplex_2_1_2 +|=== + + + +==== Fields + + + + +== Algebraic Solver + +=== Backend + +[cols="2"] +|=== +<|prefix +<|heat-fluid + +<|type +<|petsc +|=== + + +=== KSP + +[cols="2"] +|=== +<|atol +<|1.000000e-50 + +<|dtol +<|1.000000e+05 + +<|maxit +<|1000 + +<|reuse-prec +<|0 + +<|rtol +<|1.000000e-08 + +<|type +<|preonly +|=== + + +=== SNES + +[cols="2"] +|=== +<|atol +<|1.000000e-50 + +<|maxit +<|50 + +<|reuse-jac +<|0 + +<|rtol +<|1.000000e-08 + +<|stol +<|1.000000e-08 +|=== + + +=== KSP in SNES + +[cols="2"] +|=== +<|maxit +<|1000 + +<|reuse-prec +<|0 + +<|rtol +<|1.000000e-05 +|=== + + +=== PC + +[cols="2"] +|=== +<|mat-solver-package +<|mumps + +<|type +<|lu +|=== + + + +== Toolbox Heat + +=== Environment + +[cols="2"] +|=== +<|prefix +<|heat-fluid.heat + +<|keyword +<|heat + +<|root repository +<|/home/congo/feelppdb/applications/models/aerothermics/ThermalBuilding/2d/np_1 + +<|number of processus +<|1 +|=== + + +=== Physics + +==== heat + +===== default + +[cols="2"] +|=== +<|modeling +<|heat + +<|type +<|heat + +<|name +<|default +|=== + + +[cols="2"] +|=== +<|Equation +<|u dot nabla T - div( k grad T ) = 0 +|=== + + +====== Convection + +[cols="2"] +|=== +<|expr +<|{fluid_U_0,fluid_U_1} +|=== + + +====== Parameters + +[cols="5",options="header"] +|=== +<|Name +<|Expression +<|Symbol +<|Shape +<|Components + +<|convection +<|{fluid_U_0,fluid_U_1} +<|physics_heat_default_convection +<|vectorial [2] +