-
-
Notifications
You must be signed in to change notification settings - Fork 20
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
Added Pressure ExchangeData, hexaedral elements and Modal Dynamic Modus #91
Added Pressure ExchangeData, hexaedral elements and Modal Dynamic Modus #91
Conversation
@@ -487,7 +493,13 @@ void PreciceInterface_ConfigureFaceCentersMesh(PreciceInterface *interface, Simu | |||
|
|||
interface->faceCenterCoordinates = malloc(interface->numElements * 3 * sizeof(double)); | |||
interface->preciceFaceCenterIDs = malloc(interface->numElements * 3 * sizeof(int)); | |||
getTetraFaceCenters(interface->elementIDs, interface->faceIDs, interface->numElements, sim->kon, sim->ipkon, sim->co, interface->faceCenterCoordinates); | |||
if (startsWith(&sim->lakon[1*8], "C3D4") || startsWith(&sim->lakon[1*8], "C3D10")){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why read at 1*8
instead of 0?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
0 should also work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is keeping it 1*8 fine?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think as long as the mesh uses only one type of elements it should work. In the long run if we want to support "hybrid" meshes we should change this but for now I expect it to work. (Unless maybe there is exactly one element?)
Thank you very much for this PR. I already had a quick look but will make a more complete review in a few days.
|
Hi Boris,
Actually I just implemented pressure as a read variable, because I need it that way and never thought about wether writing pressure is possible or would be useful for any kind of simulation. I'm not sure if CalculiX only outputs forces.
For MODAL DYNAMIC simulations you first need to calculate the eigenmodes, which can be stored by CalculiX in a file with the ending ".eig". (This doesn't have to be a coupled simulation!) I guess everything else related to the adapter works similar, even though I'm not quite sure wether the adapter is able to perform a clean exit of the simulation or not. Regarding your question about the temperature loading and residual stresses I'm unsure too, as my background isn't in structural mechanics either.
I did not think about mixed meshes yet, because i did not need them, thats true. But right now I see no pitfalls for the implementation for mixed meshes you suppose. |
Co-authored-by: Boris Martin <84379125+boris-martin@users.noreply.github.com>
I tried running the "perpendicular flap" tutorial with a modal dynamic analysis and it crashes (apparently because Quasi-Newton acceleration doesn't converge). Did you manage to get it running? Or am I using it wrong? I simply used the default .inp file and changed the DYNAMIC analysis with a FREQUENCY followed by a MODAL DYNAMIC analysis.
|
Hi Boris, What did your output look like that you think the problem was that quasi newton does not converge? |
Hi Matthias, It converges now, having both frequency and modal dynamic in one step seems to be what broke the simulation. Frequency file:
Dynamic file:
Also, I noticed running the frequency analysis with preCICE doesn't work. (The adapter says that preCICE doesn't support frequency analysis) |
In the frequency file there seems to be at least one END STEP too much, but I dont know if that changes anything. The zero displacement might also come from a too big Time Step for the Modal Dynamic Step. Or have you tried it without the DIRECT Keyword? |
The perpendicular flap moves when I use explicit coupling, but not implicit coupling. Examining |
* Improved error message (for missing mesh) (#88) * Added error message for missing faces mesh * Improved error message for missing nodes mesh * 2D simulations major overhaul (#92) Fixed 2D simulations being unusable with Temperature BC. Arbitrary number of elements on the Z-axis is now allowed and handled assuming data independant of the Z-axis. * Added Pressure ExchangeData, hexaedral elements and Modal Dynamic Modus (#91) * Added Pressure ExchangeData, hexaedral elements and Modal Dynamic Modus * Update dyna_precice.c Co-authored-by: Matthias Freimuth <matzefreim@gmail.com> Co-authored-by: Boris Martin <84379125+boris-martin@users.noreply.github.com> * format * Added warning of broken implicit coupling when using modal dynamic simulations * Fixed mesh configuration 2D coupling with Face meshes (#94) * Fixed mesh config for face mesh * Removed dead code * Fixed missing include * Fixed crash when using face meshes and element IDs don't start to 0 (#95) * Fixed crashing simulation when using face meshes and element IDs don't start to 0 * Typo Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * Typo Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * Typo Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * Update adapter/CCXHelpers.h Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * format * reverted fallow-argument-mismatch * format Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * Revert "Fixed crash when using face meshes and element IDs don't start to 0 (#95)" (#96) This reverts commit 9cfc0cf. * Update packaging script to Ubuntu 22.04 LTS (#98) * added ubuntu 22.04 to the list of OSes in Github action * updated to 2 Ubuntu LTS only, added fflags * fixed wrong distribution name * added preivous Ubuntu non-LTS * fixd missing os * typo * removed non LTS * Fixed face mesh config(correct PR) (#97) * Fixed crashing simulation when using face meshes and element IDs don't start to 0 * Typo Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * Typo Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * Typo Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * Update adapter/CCXHelpers.h Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> * format * format * restored script * Fixed implicit coupling in modal dynamic simulation. (#99) * Fixed missing checkpointing * fixed extra output in implicit coupling * removed deprecated warnings * Fixed crash when freeing unused pointers (#102) * init NULL pointers * Enable Static Step for FSI (#101) * Update ccx_2.19.c Enable basic Static Step * Update ccx_2.19.c * Update ccx_2.19.c * Add error messages when reading invalid data in modal dynamic simulations (#103) * registering modal dynamic * added forbidden reading types to modal dynamic sims * added actual error * Update adapter/PreciceInterface.c Co-authored-by: Gerasimos Chourdakis <makishourdakis@gmail.com> * Update adapter/PreciceInterface.h Co-authored-by: Gerasimos Chourdakis <makishourdakis@gmail.com> Co-authored-by: Gerasimos Chourdakis <makishourdakis@gmail.com> * basic infrastructure for proper checkpointingin dyna_precice * seemingly working implict + subcycling modal dynamic simulations * Prototype output buffer * added C API * added missing function * improved Buffer * Actual usage of the buffer, seemingly working * added short description of the buffer mechanism * cleanup * refactoring * format * removed dead code * renamed for consistency * no longer asking for length when loading data * cleanup * documentation * removed apparently useless memcpy (#104) * Make read/write data name parsing consistent (#108) * Update for CalculiX v2.20 (#109) Co-authored-by: Boris Martin <84379125+boris-martin@users.noreply.github.com> Co-authored-by: MatthiasFreimuth <34025080+MatthiasFreimuth@users.noreply.github.com> Co-authored-by: Matthias Freimuth <matzefreim@gmail.com> Co-authored-by: Boris Martin <boris.martin.be@gmail.com> Co-authored-by: Ishaan Desai <ishaandesai@gmail.com> Co-authored-by: Kyle Davis <kyle.davis@ipvs.uni-stuttgart.de>
This pull request has been mentioned on preCICE Forum on Discourse. There might be relevant details there: |
This PR enhances the adapter with respect to the following functionalities:
Closes issue #90 Related to issue #89 (Related to issue #87)
Once this PR is accepted the new functionalities should be described in the adapter's documentation.