-
Notifications
You must be signed in to change notification settings - Fork 247
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] Heat problems with unused conditions #12840
Comments
Hey @takeshimg92! Thanks for the detailed report. At first glance, I think that the condition is adding some undesired contribution that results in something different to the do-nothing (adiabatic) that you would expect in this case. This is related to the I/O and will most probably fixed once we fully adopt the geometry-based one, which will have full control on the entities that are substituted by If you still have them, it will be very handy for us to have the test cases corresponding to each of the scenarios. Thanks in advance and sorry for the inconveniences. |
Hi @rubenzorrilla ! Thanks for the reply. |
Sure. The point is that so far, we had two ways of providing the elements/conditions info:
I suspect that the issue you're struggling with comes from the latter. Long story short, all conditions are being substituted by The geometry-based I/O relies on only writing geometries in the mdpa, something that BTW is the unique thing we should ask to any preprocessor. In other workds, elements/conditions (i.e., physics) must be in the Kratos side. Then the geometries in each model part are substituted by the |
I see. Thank you for the explanation! For now, I will keep the issue open (if I have time I can push a branch with the test showing the problem). |
I think that if you compressing and attachinc the case in here is enough (no need to create a test working with the testing framework). |
Hi @rubenzorrilla , I wrote a minimal example here: problematic_example.zip As a note, in my original comment I was using a LaplacianElement; here I am using a MixedLaplacianElement because I wanted access to temperature gradients, but the conclusion is the same. |
Great. We'll try to have a look ASAP. |
Description
TL;DR: keeping unused Conditions or SubModelParts on the MDPA for a heat problem yields wrong physics.
This is a problem I have noticed a few months back, only now reporting on it.
Considering the following simple heat diffusion problem in the ConvectionDiffusionApplication. I generate a tetrahedral mesh with 1263 nodes, corresponding to a beam which is 0.5m x 0.2m x 0.1cm along the x,y, z axes respectively.
Set up a Dirichlet condition at x=0 (surface
x_1
) for temperature T = 100 K. On the x=0.5 surface (call itx_2
) set a flux of -25000 W/m2, corresponding to a total power output of 500W.Setting thermal conductivity to 237 W/mK, the analytical solution for the temperature at x=0.5 is 47.257 K.
Scenario 1: construct MDPA with two submodelparts, x1 and x2, and only keep the Conditions that belong to these groups
Scenario 2: construct MDPA with more submodel parts (because why not?) -- create one at y=0 (
y_1
) and another at y=0.2 (y_2
). Keep the Conditions that belong to these groups (but still only enforce boundary conditions onx_1
andx_2
)Scenario 3: construct MDPA with just the two submodel parts x1 and x2, but keep all conditions (all the surfaces of the beam)
Scenario 4: construct MDPA with the 4 model parts above, but explicitly set the flux to zero at surfaces
y_1
andy_2
I don't understand what is happening here.
Scope
ConvectionDiffusionApplication
To Reproduce
My solver settings are standard:
I had the same error using
ThermalFace
andFluxCondition
for element_replace_settings.Expected behavior
In all cases, I would have expected temperature at x=0.5 to be equal to 47.257 K. Just having more conditions should not change the results if no additional boundary conditions are passed. Also, explicitly setting fluxes to zero at y_1, y_2 should be enough to replicate the original behavior.
Environment
The text was updated successfully, but these errors were encountered: