KratosMultiphysics / Kratos

Kratos Multiphysics (A.K.A Kratos) is a framework for building parallel multi-disciplinary simulation software. Modularity, extensibility and HPC are the main objectives. Kratos has BSD license and is written in C++ with extensive Python interface.
https://kratosmultiphysics.github.io/Kratos/
Other
1.02k stars 245 forks source link

[GeoMechanicsApplication][Thermal] Write the results of the initial stage to the output file #12379

Closed mnabideltares closed 3 months ago

mnabideltares commented 4 months ago

Description

The initial stage is necessary in the output file for visualization alongside the results. This is primarily required by the DSeries Team. However, the initial condition in Kratos cannot be written in the output in its current state.

To generate output, we propose the following ideas:

Use Dt=0 for the first time step. For transient simulations, Dt=0 should not result in any changes to the results. Therefore, the results are expected to be identical to the initial conditions. Subsequently, write the first time step as output. However, this approach has not been tested previously, and we are unsure if it will work correctly. Hopefully, it will not result in division by zero.

Alternatively, start from a negative time step and write the zero time step into the output.

mnabideltares commented 4 months ago

@mcgicjn2

It is possible to do it by multistage. At the first stage the parameter and material inputs need to be modified:

ProjectParameters.json

"problem_data": {
    "start_time":           -600.0,
    "end_time":             0,
    ...

"time_stepping":              {
    "time_step":                 600,
    "max_delta_time_factor":       1
    ...

MaterialParameters.json

"Variables": {
    ...
    "SPECIFIC_HEAT_CAPACITY_SOLID"  :  0.0,
    "SPECIFIC_HEAT_CAPACITY_WATER"  :  0.0,
    "THERMAL_CONDUCTIVITY_SOLID_XX" :  0.0,
    "THERMAL_CONDUCTIVITY_SOLID_YY" :  0.0,
    "THERMAL_CONDUCTIVITY_SOLID_XY" :  0.0,
    "THERMAL_CONDUCTIVITY_WATER"    :  0.0
    ...

For reference, attached 2 cases which are taken from the integration tests.

test_thermal_fixed_temperature_2D3N.zip test_thermal_heat_flux_2D3N.zip

rfaasse commented 3 months ago

Workaround was presented to relevant stakeholder, since this is not an official workflow, we don't need to add a test to our suite, so closing this issue.

FYI @mcgicjn2