Hello,
I am currently migrating a script from Code_Aster v14 to v17.
In my workflow, I use a mesh from time step n-1 generated by Saturne, which is then projected onto the solid mesh at time step n in Aster.
The issue appears in the following loop where the pressure field is projected from the fluid mesh to the solid mesh:
# ============================================================
# PRESSURE PROJECTION -> SOLID
# ============================================================
Mproj = PROJ_CHAMP(MAILLAGE_1=mafluide, MAILLAGE_2=masolide,
METHODE='COLLOCATION', PROJECTION='NON',
VIS_A_VIS=_F(GROUP_MA_1=('mat',), GROUP_MA_2=('surfext',)),
ALARME='OUI', INFO=1)
stress = LIRE_RESU(FORMAT='MED', UNITE=4, TYPE_RESU='EVOL_CHAR', MODELE=modelflu,
FORMAT_MED=_F(NOM_CHAM='PRES', NOM_CHAM_MED='Normal Stress',
NOM_CMP=('PRES',), NOM_CMP_MED=('Scalar',)),
PROL_ZERO='OUI', TOUT_ORDRE='OUI', INFO=1)
PrjStr = PROJ_CHAMP(RESULTAT=stress, NOM_CHAM=('PRES',),
MATR_PROJECTION=Mproj, PROJECTION='OUI',
PROL_ZERO='OUI', TYPE_CHAM='NOEU', INFO=1)
chflu = AFFE_CHAR_MECA(MODELE=modelsol, EVOL_CHAR=PrjStr,
VERI_NORM='OUI', DOUBLE_LAGRANGE='OUI', INFO=1)
When running this in v17, I obtain the following error:
<EXCEPTION> <MED_12>
Vous avez demandé de relire un champ MED pour lequel les numéros de pas de temps
et d'itération ne sont pas égaux. Ce n'est pas autorisé dans LIRE_RESU.
Conseil : Utilisez readMedFileToResults.
I also tried the suggested solution using readMedFileToResults, but unfortunately it does not work in my case either.
The goal is to apply the pressure field from the previous fluid time step (n-1) onto the solid model at time step n.
This workflow was working correctly in v14, but it does not behave correctly in v17.
Has anyone already implemented this type of FSI coupling with projection between different time steps in v17, or encountered a similar issue when reading MED results?
Thank you in advance for your help.