From 5ed36a9701f60477920d5c33077739aeaa627310 Mon Sep 17 00:00:00 2001 From: "pascale.noyret" Date: Thu, 14 Sep 2017 11:09:34 +0200 Subject: [PATCH] merge avec les devloppts de l ete --- Adao/ADAO_Cata_V0_V7_7_0.py | 2 +- Adao/ADAO_Cata_V0_V8_3_0_DEV.py | 1270 +++++++++++++++++ Adao/configuration_Adao.py | 15 +- Adao/prefs_Adao.py | 18 +- Adao/qtEficas_Adao.py | 7 +- Editeur/Objecttreeitem.py | 4 +- Editeur/session.py | 2 +- InterfaceQT4/browser.py | 12 +- InterfaceQT4/compomclist.py | 2 +- InterfaceQT4/editor.py | 46 +- InterfaceQT4/eficas_go.py | 12 +- InterfaceQT4/monChoixCommande.py | 44 +- InterfaceQT4/qtSaisie.py | 5 + InterfaceQT4/ssIhm.py | 11 +- MAP/configuration_MAP.py | 2 +- MAP/prefs_MAP.py | 3 + MED/CataAZ.py | 210 +++ MED/Elementary_Lists_52996_Cata.py | 86 ++ MED/Elementary_Lists_53000_Cata.py | 52 + MED/Elementary_Lists_53013_Cata.py | 59 + MED/Elementary_Lists_53036_Cata.py | 59 + MED/Elementary_Lists_Cata.py | 59 + MED/Global_Condition_Cata.py | 53 + MED/Many_Concepts_52983_Cata.py | 39 + MED/Many_Concepts_52988_Cata.py | 76 + MED/Many_Concepts_52989_Cata.py | 77 + MED/Many_Concepts_52992_Cata.py | 76 + MED/Matrix_Cata.py | 87 ++ MED/Nested_Cond_52945_Cata.py | 61 + MED/Nested_Cond_52946_Cata.py | 62 + MED/Nested_Cond_52947_Cata.py | 17 + MED/Nested_Cond_52948_Cata.py | 21 + MED/Nested_Cond_52949_Cata.py | 19 + MED/Nested_Cond_52952_Cata.py | 60 + MED/Separate_Blocks_52958_Cata.py | 29 + MED/Separate_Blocks_52963_Cata.py | 40 + MED/Separate_Blocks_52966_Cata.py | 48 + MED/Separate_Blocks_52972_Cata.py | 66 + MED/Separate_Blocks_52975_Cata.py | 66 + MED/a | 110 ++ MED/cata_diapo.py | 48 + MED/cata_med.py | 29 + .../configuration_MED.py | 0 MED/images/essaiAster.png | Bin 0 -> 11576 bytes MED/items_integer_space.txt | 2 + .../monCode_qtEficas.py | 0 MED/prefs.py | 22 + MED/prefs_MED.py | 48 + MED/prefs_monCode.py | 68 + {PSEN_N1 => MED}/properties.py | 0 Aster/qtEficas_aster.py => MED/qtEficas_AZ.py | 0 .../qtEficas_Med.py | 0 MED/typescript | 34 + MT/MT_Cata_V2016.py | 1066 ++++++++++++++ MT/mesScripts_MT.py | 9 +- MT/opsOT.py | 20 - MT/reecrit_comm.py_VOprofile.py | 58 + MT/sdll124a.machine | 207 +++ MT/txtZone.py | 227 +++ MT/txtZonePN.py | 227 +++ {Aster => OldCodes/Aster}/CMakeLists.txt | 0 {Aster => OldCodes/Aster}/Cata/CMakeLists.txt | 0 {Aster => OldCodes/Aster}/Cata/__init__.py | 0 .../Aster}/Cata/cataSTA11/__init__.py | 0 .../Aster}/Cata/cataSTA11/cata.py | 0 .../Aster}/Cata/cataSTA11/ops.py | 0 {Aster => OldCodes/Aster}/INSTALL | 0 {Aster => OldCodes/Aster}/Include.com | 0 {Aster => OldCodes/Aster}/LICENSE.TERMS | 0 {Aster => OldCodes/Aster}/NEWS | 0 {Aster => OldCodes/Aster}/README | 0 {Aster => OldCodes/Aster}/Tests/README | 0 .../Aster}/Tests/Recette/az.comm | 0 .../Aster}/Tests/Recette/efica01a.11 | 0 .../Aster}/Tests/Recette/efica01a.com0 | 0 .../Aster}/Tests/Recette/efica01a.comm | 0 {Aster => OldCodes/Aster}/Tests/d0.comm | 0 {Aster => OldCodes/Aster}/Tests/err.comm | 0 {Aster => OldCodes/Aster}/Tests/err2.comm | 0 {Aster => OldCodes/Aster}/Tests/err3.comm | 0 {Aster => OldCodes/Aster}/Tests/incl.11 | 0 {Aster => OldCodes/Aster}/Tests/incl.12 | 0 {Aster => OldCodes/Aster}/Tests/incl.13 | 0 {Aster => OldCodes/Aster}/Tests/incl.14 | 0 {Aster => OldCodes/Aster}/Tests/incl.15 | 0 {Aster => OldCodes/Aster}/Tests/incl.16 | 0 {Aster => OldCodes/Aster}/Tests/incl.17 | 0 {Aster => OldCodes/Aster}/Tests/incl.25 | 0 {Aster => OldCodes/Aster}/Tests/incl1.comm | 0 {Aster => OldCodes/Aster}/Tests/inclmat.comm | 0 {Aster => OldCodes/Aster}/Tests/inclmat2.comm | 0 {Aster => OldCodes/Aster}/Tests/j0.comm | 0 {Aster => OldCodes/Aster}/Tests/j1.comm | 0 {Aster => OldCodes/Aster}/Tests/j1.ini | 0 {Aster => OldCodes/Aster}/Tests/j2.ini | 0 {Aster => OldCodes/Aster}/Tests/jdc.ini | 0 {Aster => OldCodes/Aster}/Tests/p0.comm | 0 {Aster => OldCodes/Aster}/Tests/p1.comm | 0 {Aster => OldCodes/Aster}/Tests/p2.comm | 0 {Aster => OldCodes/Aster}/Tests/p3.comm | 0 {Aster => OldCodes/Aster}/Tests/perr.comm | 0 {Aster => OldCodes/Aster}/Tests/perr2.comm | 0 {Aster => OldCodes/Aster}/Tests/pincl.11 | 0 {Aster => OldCodes/Aster}/Tests/pp.comm | 0 {Aster => OldCodes/Aster}/Tests/princ.comm | 0 {Aster => OldCodes/Aster}/Tests/princ.ini | 0 {Aster => OldCodes/Aster}/Tests/princl.11 | 0 {Aster => OldCodes/Aster}/Tests/princl.12 | 0 {Aster => OldCodes/Aster}/Tests/princl.14 | 0 {Aster => OldCodes/Aster}/Tests/princl.35 | 0 {Aster => OldCodes/Aster}/Tests/qincl.11 | 0 {Aster => OldCodes/Aster}/Tests/rincl.11 | 0 {Aster => OldCodes/Aster}/Tests/torsion.comm | 0 {Aster => OldCodes/Aster}/__init__.py | 0 {Aster => OldCodes/Aster}/a.dat | 0 {Aster => OldCodes/Aster}/alphasdist.py | 0 .../Aster}/configuration_ASTER.py | 0 .../Aster}/configuration_Aster.py | 0 {Aster => OldCodes/Aster}/eficasManager.py | 0 {Aster => OldCodes/Aster}/eficas_aster.py | 0 {Aster => OldCodes/Aster}/lance_test.sh | 0 {Aster => OldCodes/Aster}/prefs.py | 0 {Aster => OldCodes/Aster}/prefs.py.win | 0 {Aster => OldCodes/Aster}/prefs_ASTER.py | 0 {Aster => OldCodes/Aster}/prefs_Aster.py | 0 {Aster => OldCodes/Aster}/properties.py | 0 OldCodes/Aster/qtEficas_aster.py | 32 + {Aster => OldCodes/Aster}/qtGroup.py | 0 {Aster => OldCodes/Aster}/reecrit_comm.py | 0 {Aster => OldCodes/Aster}/sdist.py | 0 {Aster => OldCodes/Aster}/style.py | 0 {Aster => OldCodes/Aster}/test_eficas.py | 0 .../CarmelCND}/CMakeLists.txt | 0 .../CarmelCND}/CarmelCND_Cata.py | 0 .../CarmelCND}/PourTraductionCarmel.py | 0 .../CarmelCND}/PrepareRunCarmel.py | 0 .../CarmelCND}/acquiertGroupes.py | 0 .../CarmelCND/configuration_CARMELCND.py | 0 {CarmelCND => OldCodes/CarmelCND}/prefs.py | 0 .../CarmelCND}/prefs_CARMELCND.py | 0 OldCodes/CarmelCND/qtEficas_CarmelCND.py | 32 + .../CarmelCS}/CMakeLists.txt | 0 .../CarmelCS}/CarmelCS_cata.py | 0 .../CarmelCS/configuration_CARMELCS.py | 0 .../CarmelCS}/pilotyacsCS.py | 0 {CarmelCS => OldCodes/CarmelCS}/prefs.py | 0 .../CarmelCS}/prefs_CARMELCS.py | 0 .../CarmelCS/qtEficas_CarmelCS.py | 0 .../Openturns_Study}/CMakeLists.txt | 0 .../OpenTURNS_Cata_Study_V1.py | 0 .../OpenTURNS_Cata_Study_V10.py | 0 .../OpenTURNS_Cata_Study_V2.py | 0 .../OpenTURNS_Cata_Study_V3.py | 0 .../OpenTURNS_Cata_Study_V4.py | 0 .../OpenTURNS_Cata_Study_V5.py | 0 .../OpenTURNS_Cata_Study_V6.py | 0 .../OpenTURNS_Cata_Study_V7.py | 0 .../OpenTURNS_Cata_Study_V7.py.orig | 0 .../OpenTURNS_Cata_Study_V8.py | 0 .../OpenTURNS_Cata_Study_V9.py | 0 .../configuration_OPENTURNS_STUDY.py | 0 .../Openturns_Study}/opsOT.py | 0 .../Openturns_Study}/prefs.py | 0 .../Openturns_Study}/prefs_OPENTURNS_STUDY.py | 0 .../Openturns_Study}/properties.py | 0 .../qtEficas_openturns_study.py | 0 .../Openturns_Study}/sdistOTqt.py | 0 .../Openturns_Study}/style.py | 0 .../test/MinMax_ExpPlane.comm | 0 .../Openturns_Study}/test/MinMax_ExpPlane.py | 0 .../test/MinMax_RandomSampling.comm | 0 .../Openturns_Wrapper}/CMakeLists.txt | 0 .../OpenTURNS_Cata_Wrapper_V1.py | 0 .../OpenTURNS_Cata_Wrapper_V2.py | 0 .../OpenTURNS_Cata_Wrapper_V3.py | 0 .../OpenTURNS_Cata_Wrapper_V4.py | 0 .../configuration_OPENTURNS_WRAPPER.py | 0 .../Openturns_Wrapper}/prefs.py | 0 .../prefs_OPENTURNS_WRAPPER.py | 0 .../Openturns_Wrapper}/properties.py | 0 .../qtEficas_openturns_wrapper.py | 0 .../Openturns_Wrapper}/sdistOTqt.py | 0 .../Openturns_Wrapper}/style.py | 0 {PSEN_N1 => OldCodes/PSEN_N1}/PSEN_Cata_N1.py | 0 .../PSEN_N1/configuration_PSEN_N1.py | 0 .../PSEN_N1}/mesScripts_PSEN_N1.py | 0 {PSEN_N1 => OldCodes/PSEN_N1}/opsPSEN_N1.py | 0 {PSEN_N1 => OldCodes/PSEN_N1}/prefs.py | 0 .../PSEN_N1}/prefs_PSEN_N1.py | 0 {ZCracks => OldCodes/PSEN_N1}/properties.py | 0 .../PSEN_N1}/qtEficas_PSEN_N1.py | 0 {PSEN_N1 => OldCodes/PSEN_N1}/run.py | 0 {Sep => OldCodes/Sep}/CMakeLists.txt | 0 {Sep => OldCodes/Sep}/SEP_Cata_V0.py | 0 {Sep => OldCodes/Sep}/SEP_Cata_V1.py | 0 {Sep => OldCodes/Sep}/SEP_Cata_V1_2.py | 0 {Sep => OldCodes/Sep}/SEP_Cata_V1_3.py | 0 {Sep => OldCodes/Sep}/SEP_Cata_V1_4.py | 0 {Sep => OldCodes/Sep}/__init__.py | 0 {Sep => OldCodes/Sep}/catalogues_sep.ini | 0 {Sep => OldCodes/Sep}/configuration_SEP.py | 0 {Sep => OldCodes/Sep}/editeur.ini | 0 {Sep => OldCodes/Sep}/prefs.py | 0 {Sep => OldCodes/Sep}/prefs_SEP.py | 0 {Sep => OldCodes/Sep}/properties.py | 0 {Sep => OldCodes/Sep}/qtEficas_SEP.py | 0 {Sep => OldCodes/Sep}/sdistSEP.py | 0 {Sep => OldCodes/Sep}/style.py | 0 {UiQT4 => OldCodes/UiQT4}/CMakeLists.txt | 0 {UiQT4 => OldCodes/UiQT4}/Newdoc.tgz | Bin {UiQT4 => OldCodes/UiQT4}/Tuple2.ui | 0 {UiQT4 => OldCodes/UiQT4}/Tuple3.ui | 0 {UiQT4 => OldCodes/UiQT4}/desBaseWidget.ui | 0 {UiQT4 => OldCodes/UiQT4}/desChoixCata.ui | 0 {UiQT4 => OldCodes/UiQT4}/desChoixCode.ui | 0 .../UiQT4}/desChoixCommandes.ui | 0 {UiQT4 => OldCodes/UiQT4}/desChoixLangue.ui | 0 .../UiQT4}/desGroupeOptionnel.ui | 0 {UiQT4 => OldCodes/UiQT4}/desRecherche.ui | 0 .../UiQT4}/desRechercheCatalogue.ui | 0 {UiQT4 => OldCodes/UiQT4}/desSelectVal.ui | 0 {UiQT4 => OldCodes/UiQT4}/desViewRegles.ui | 0 {UiQT4 => OldCodes/UiQT4}/desViewTexte.ui | 0 {UiQT4 => OldCodes/UiQT4}/desVisu.ui | 0 .../UiQT4}/desWidget4a6RadioButton.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetBloc.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetCB.ui | 0 .../UiQT4}/desWidgetCommande.ui | 0 .../UiQT4}/desWidgetCommentaire.ui | 0 .../UiQT4}/desWidgetCreeParam.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetDate.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetFact.ui | 0 .../UiQT4}/desWidgetFactPlie.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetFormule.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetHeure.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetInactif.ui | 0 .../UiQT4}/desWidgetInformation.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetMatrice.ui | 0 .../UiQT4}/desWidgetOptionnel.ui | 0 .../UiQT4}/desWidgetOptionnelMC.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetParam.ui | 0 .../UiQT4}/desWidgetPlusieursBase.ui | 0 .../UiQT4}/desWidgetPlusieursInto.ui | 0 .../UiQT4}/desWidgetPlusieursIntoOrdonne.ui | 0 .../UiQT4}/desWidgetPlusieursPlie.ui | 0 .../UiQT4}/desWidgetPlusieursTuple.ui | 0 .../UiQT4}/desWidgetRadioButton.ui | 0 .../UiQT4}/desWidgetSDCOInto.ui | 0 .../UiQT4}/desWidgetSimpBase.ui | 0 .../UiQT4}/desWidgetSimpBool.ui | 0 .../UiQT4}/desWidgetSimpComplexe.ui | 0 .../UiQT4}/desWidgetSimpFichier.ui | 0 .../UiQT4}/desWidgetSimpSalome.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetSimpTxt.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetTuple2.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetTuple3.ui | 0 .../UiQT4}/desWidgetUniqueSDCO.ui | 0 {UiQT4 => OldCodes/UiQT4}/desWidgetVide.ui | 0 {UiQT4 => OldCodes/UiQT4}/eficas_en.0106.ts | 0 {UiQT4 => OldCodes/UiQT4}/eficas_en.ts | 0 {UiQT4 => OldCodes/UiQT4}/eficas_fr.0106.ts | 0 {UiQT4 => OldCodes/UiQT4}/eficas_fr.ts | 0 {UiQT4 => OldCodes/UiQT4}/makefile | 0 {UiQT4 => OldCodes/UiQT4}/myMain.ui | 0 {ZCracks => OldCodes/ZCracks}/CMakeLists.txt | 0 OldCodes/ZCracks/configuration_ZCRACKS.py | 43 + .../ZCracks}/mesScripts_ZCRACKS.py | 0 {ZCracks => OldCodes/ZCracks}/monCode_Cata.py | 0 .../ZCracks}/monCode_Cata.py.V0 | 0 {ZCracks => OldCodes/ZCracks}/prefs.py | 0 .../ZCracks}/prefs_ZCRACKS.py | 0 OldCodes/ZCracks/properties.py | 24 + OldCodes/ZCracks/qtEficas_ZCracks.py | 33 + {ts => OldCodes/ts}/Telemac_Cata.py | 0 {ts => OldCodes/ts}/a.py | 0 {ts => OldCodes/ts}/dicoparser.py | 0 {ts => OldCodes/ts}/main.ts | 0 {ts => OldCodes/ts}/prefs.py | 0 {ts => OldCodes/ts}/telemac2dv6p3.dico | 0 {ts => OldCodes/ts}/test_cata.py | 0 {ts => OldCodes/ts}/test_dicoparser.py | 0 {ts => OldCodes/ts}/test_translator.py | 0 {ts => OldCodes/ts}/translator.py | 0 {ts => OldCodes/ts}/tsparser.py | 0 ProcessOutputs_Eficas/PSEN_Cata_N1.py | 112 +- .../configuration_PSEN_N1.py | 2 +- ProcessOutputs_Eficas/mesScripts_PSEN_N1.py | 48 +- ProcessOutputs_Eficas/opsPSEN_N1.py | 144 +- ProcessOutputs_Eficas/prefs_PSEN_N1.py | 3 +- ProcessOutputs_Eficas/qtEficas_PSEN_N1.py | 9 +- SPECA/SPECA_Cata_V2_00.py | 458 ++++++ Telemac/reecrit_cas_en_comm.py | 57 + Traducteur/changeValeur.py | 4 +- Traducteur/dictErreurs.py | 4 +- Traducteur/inseremocle.py | 1 - Traducteur/utils.py | 2 +- UiQT5/desWidgetFactHorizon.ui | 428 ++++++ UiQT5/desWidgetPlusieursInto.ui | 2 +- VirtualPolymer/VP | 5 + VirtualPolymer/VP_Cata_V2.py | 178 ++- VirtualPolymer/lienDB.py | 395 ++++- VirtualPolymer/listesDB.py | 20 +- VirtualPolymer/opsOT.py | 20 - boundary_conditions/CMakeLists.txt | 32 + boundary_conditions/__init__.py | 0 boundary_conditions/appli.py | 45 + .../boundary_conditions_cata.py | 59 + .../configuration_boundary_conditions.py | 48 + .../generator_boundary_conditions.py | 57 + boundary_conditions/prefs.py | 18 + .../prefs_boundary_conditions.py | 21 + convert/convert_python.py | 14 +- generator/generator_python.py | 3 + mascaret/CMakeLists.txt | 31 + mascaret/__init__.py | 0 mascaret/appli.py | 76 + mascaret/configuration_mascaret.py | 46 + mascaret/mascaret_V7_cata.py | 107 ++ mascaret/prefs.py | 18 + mascaret/prefs_mascaret.py | 28 + 320 files changed, 7359 insertions(+), 352 deletions(-) create mode 100755 Adao/ADAO_Cata_V0_V8_3_0_DEV.py create mode 100755 MED/CataAZ.py create mode 100644 MED/Elementary_Lists_52996_Cata.py create mode 100644 MED/Elementary_Lists_53000_Cata.py create mode 100644 MED/Elementary_Lists_53013_Cata.py create mode 100644 MED/Elementary_Lists_53036_Cata.py create mode 100755 MED/Elementary_Lists_Cata.py create mode 100755 MED/Global_Condition_Cata.py create mode 100644 MED/Many_Concepts_52983_Cata.py create mode 100644 MED/Many_Concepts_52988_Cata.py create mode 100644 MED/Many_Concepts_52989_Cata.py create mode 100644 MED/Many_Concepts_52992_Cata.py create mode 100644 MED/Matrix_Cata.py create mode 100644 MED/Nested_Cond_52945_Cata.py create mode 100644 MED/Nested_Cond_52946_Cata.py create mode 100644 MED/Nested_Cond_52947_Cata.py create mode 100644 MED/Nested_Cond_52948_Cata.py create mode 100644 MED/Nested_Cond_52949_Cata.py create mode 100644 MED/Nested_Cond_52952_Cata.py create mode 100644 MED/Separate_Blocks_52958_Cata.py create mode 100644 MED/Separate_Blocks_52963_Cata.py create mode 100644 MED/Separate_Blocks_52966_Cata.py create mode 100644 MED/Separate_Blocks_52972_Cata.py create mode 100644 MED/Separate_Blocks_52975_Cata.py create mode 100644 MED/a create mode 100644 MED/cata_diapo.py create mode 100644 MED/cata_med.py rename CarmelCND/configuration_CARMELCND.py => MED/configuration_MED.py (100%) create mode 100644 MED/images/essaiAster.png create mode 100644 MED/items_integer_space.txt rename CarmelCS/qtEficas_CarmelCS.py => MED/monCode_qtEficas.py (100%) create mode 100644 MED/prefs.py create mode 100644 MED/prefs_MED.py create mode 100644 MED/prefs_monCode.py rename {PSEN_N1 => MED}/properties.py (100%) rename Aster/qtEficas_aster.py => MED/qtEficas_AZ.py (100%) rename CarmelCND/qtEficas_CarmelCND.py => MED/qtEficas_Med.py (100%) create mode 100644 MED/typescript create mode 100644 MT/MT_Cata_V2016.py delete mode 100644 MT/opsOT.py create mode 100755 MT/reecrit_comm.py_VOprofile.py create mode 100644 MT/sdll124a.machine create mode 100644 MT/txtZone.py create mode 100644 MT/txtZonePN.py rename {Aster => OldCodes/Aster}/CMakeLists.txt (100%) rename {Aster => OldCodes/Aster}/Cata/CMakeLists.txt (100%) rename {Aster => OldCodes/Aster}/Cata/__init__.py (100%) rename {Aster => OldCodes/Aster}/Cata/cataSTA11/__init__.py (100%) rename {Aster => OldCodes/Aster}/Cata/cataSTA11/cata.py (100%) rename {Aster => OldCodes/Aster}/Cata/cataSTA11/ops.py (100%) rename {Aster => OldCodes/Aster}/INSTALL (100%) rename {Aster => OldCodes/Aster}/Include.com (100%) rename {Aster => OldCodes/Aster}/LICENSE.TERMS (100%) rename {Aster => OldCodes/Aster}/NEWS (100%) rename {Aster => OldCodes/Aster}/README (100%) rename {Aster => OldCodes/Aster}/Tests/README (100%) rename {Aster => OldCodes/Aster}/Tests/Recette/az.comm (100%) rename {Aster => OldCodes/Aster}/Tests/Recette/efica01a.11 (100%) rename {Aster => OldCodes/Aster}/Tests/Recette/efica01a.com0 (100%) rename {Aster => OldCodes/Aster}/Tests/Recette/efica01a.comm (100%) rename {Aster => OldCodes/Aster}/Tests/d0.comm (100%) rename {Aster => OldCodes/Aster}/Tests/err.comm (100%) rename {Aster => OldCodes/Aster}/Tests/err2.comm (100%) rename {Aster => OldCodes/Aster}/Tests/err3.comm (100%) rename {Aster => OldCodes/Aster}/Tests/incl.11 (100%) rename {Aster => OldCodes/Aster}/Tests/incl.12 (100%) rename {Aster => OldCodes/Aster}/Tests/incl.13 (100%) rename {Aster => OldCodes/Aster}/Tests/incl.14 (100%) rename {Aster => OldCodes/Aster}/Tests/incl.15 (100%) rename {Aster => OldCodes/Aster}/Tests/incl.16 (100%) rename {Aster => OldCodes/Aster}/Tests/incl.17 (100%) rename {Aster => OldCodes/Aster}/Tests/incl.25 (100%) rename {Aster => OldCodes/Aster}/Tests/incl1.comm (100%) rename {Aster => OldCodes/Aster}/Tests/inclmat.comm (100%) rename {Aster => OldCodes/Aster}/Tests/inclmat2.comm (100%) rename {Aster => OldCodes/Aster}/Tests/j0.comm (100%) rename {Aster => OldCodes/Aster}/Tests/j1.comm (100%) rename {Aster => OldCodes/Aster}/Tests/j1.ini (100%) rename {Aster => OldCodes/Aster}/Tests/j2.ini (100%) rename {Aster => OldCodes/Aster}/Tests/jdc.ini (100%) rename {Aster => OldCodes/Aster}/Tests/p0.comm (100%) rename {Aster => OldCodes/Aster}/Tests/p1.comm (100%) rename {Aster => OldCodes/Aster}/Tests/p2.comm (100%) rename {Aster => OldCodes/Aster}/Tests/p3.comm (100%) rename {Aster => OldCodes/Aster}/Tests/perr.comm (100%) rename {Aster => OldCodes/Aster}/Tests/perr2.comm (100%) rename {Aster => OldCodes/Aster}/Tests/pincl.11 (100%) rename {Aster => OldCodes/Aster}/Tests/pp.comm (100%) rename {Aster => OldCodes/Aster}/Tests/princ.comm (100%) rename {Aster => OldCodes/Aster}/Tests/princ.ini (100%) rename {Aster => OldCodes/Aster}/Tests/princl.11 (100%) rename {Aster => OldCodes/Aster}/Tests/princl.12 (100%) rename {Aster => OldCodes/Aster}/Tests/princl.14 (100%) rename {Aster => OldCodes/Aster}/Tests/princl.35 (100%) rename {Aster => OldCodes/Aster}/Tests/qincl.11 (100%) rename {Aster => OldCodes/Aster}/Tests/rincl.11 (100%) rename {Aster => OldCodes/Aster}/Tests/torsion.comm (100%) rename {Aster => OldCodes/Aster}/__init__.py (100%) rename {Aster => OldCodes/Aster}/a.dat (100%) rename {Aster => OldCodes/Aster}/alphasdist.py (100%) rename {Aster => OldCodes/Aster}/configuration_ASTER.py (100%) rename {Aster => OldCodes/Aster}/configuration_Aster.py (100%) rename {Aster => OldCodes/Aster}/eficasManager.py (100%) rename {Aster => OldCodes/Aster}/eficas_aster.py (100%) rename {Aster => OldCodes/Aster}/lance_test.sh (100%) rename {Aster => OldCodes/Aster}/prefs.py (100%) rename {Aster => OldCodes/Aster}/prefs.py.win (100%) rename {Aster => OldCodes/Aster}/prefs_ASTER.py (100%) rename {Aster => OldCodes/Aster}/prefs_Aster.py (100%) rename {Aster => OldCodes/Aster}/properties.py (100%) create mode 100755 OldCodes/Aster/qtEficas_aster.py rename {Aster => OldCodes/Aster}/qtGroup.py (100%) rename {Aster => OldCodes/Aster}/reecrit_comm.py (100%) rename {Aster => OldCodes/Aster}/sdist.py (100%) rename {Aster => OldCodes/Aster}/style.py (100%) rename {Aster => OldCodes/Aster}/test_eficas.py (100%) rename {CarmelCND => OldCodes/CarmelCND}/CMakeLists.txt (100%) rename {CarmelCND => OldCodes/CarmelCND}/CarmelCND_Cata.py (100%) rename {CarmelCND => OldCodes/CarmelCND}/PourTraductionCarmel.py (100%) rename {CarmelCND => OldCodes/CarmelCND}/PrepareRunCarmel.py (100%) rename {CarmelCND => OldCodes/CarmelCND}/acquiertGroupes.py (100%) rename CarmelCS/configuration_CARMELCS.py => OldCodes/CarmelCND/configuration_CARMELCND.py (100%) rename {CarmelCND => OldCodes/CarmelCND}/prefs.py (100%) rename {CarmelCND => OldCodes/CarmelCND}/prefs_CARMELCND.py (100%) create mode 100755 OldCodes/CarmelCND/qtEficas_CarmelCND.py rename {CarmelCS => OldCodes/CarmelCS}/CMakeLists.txt (100%) rename {CarmelCS => OldCodes/CarmelCS}/CarmelCS_cata.py (100%) rename PSEN_N1/configuration_PSEN_N1.py => OldCodes/CarmelCS/configuration_CARMELCS.py (100%) rename {CarmelCS => OldCodes/CarmelCS}/pilotyacsCS.py (100%) rename {CarmelCS => OldCodes/CarmelCS}/prefs.py (100%) rename {CarmelCS => OldCodes/CarmelCS}/prefs_CARMELCS.py (100%) rename ZCracks/qtEficas_ZCracks.py => OldCodes/CarmelCS/qtEficas_CarmelCS.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/CMakeLists.txt (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V1.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V10.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V2.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V3.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V4.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V5.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V6.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V7.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V7.py.orig (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V8.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/OpenTURNS_Cata_Study_V9.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/configuration_OPENTURNS_STUDY.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/opsOT.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/prefs.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/prefs_OPENTURNS_STUDY.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/properties.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/qtEficas_openturns_study.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/sdistOTqt.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/style.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/test/MinMax_ExpPlane.comm (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/test/MinMax_ExpPlane.py (100%) rename {Openturns_Study => OldCodes/Openturns_Study}/test/MinMax_RandomSampling.comm (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/CMakeLists.txt (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/OpenTURNS_Cata_Wrapper_V1.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/OpenTURNS_Cata_Wrapper_V2.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/OpenTURNS_Cata_Wrapper_V3.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/OpenTURNS_Cata_Wrapper_V4.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/configuration_OPENTURNS_WRAPPER.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/prefs.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/prefs_OPENTURNS_WRAPPER.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/properties.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/qtEficas_openturns_wrapper.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/sdistOTqt.py (100%) rename {Openturns_Wrapper => OldCodes/Openturns_Wrapper}/style.py (100%) rename {PSEN_N1 => OldCodes/PSEN_N1}/PSEN_Cata_N1.py (100%) rename ZCracks/configuration_ZCRACKS.py => OldCodes/PSEN_N1/configuration_PSEN_N1.py (100%) rename {PSEN_N1 => OldCodes/PSEN_N1}/mesScripts_PSEN_N1.py (100%) rename {PSEN_N1 => OldCodes/PSEN_N1}/opsPSEN_N1.py (100%) rename {PSEN_N1 => OldCodes/PSEN_N1}/prefs.py (100%) rename {PSEN_N1 => OldCodes/PSEN_N1}/prefs_PSEN_N1.py (100%) rename {ZCracks => OldCodes/PSEN_N1}/properties.py (100%) rename {PSEN_N1 => OldCodes/PSEN_N1}/qtEficas_PSEN_N1.py (100%) rename {PSEN_N1 => OldCodes/PSEN_N1}/run.py (100%) rename {Sep => OldCodes/Sep}/CMakeLists.txt (100%) rename {Sep => OldCodes/Sep}/SEP_Cata_V0.py (100%) rename {Sep => OldCodes/Sep}/SEP_Cata_V1.py (100%) rename {Sep => OldCodes/Sep}/SEP_Cata_V1_2.py (100%) rename {Sep => OldCodes/Sep}/SEP_Cata_V1_3.py (100%) rename {Sep => OldCodes/Sep}/SEP_Cata_V1_4.py (100%) rename {Sep => OldCodes/Sep}/__init__.py (100%) rename {Sep => OldCodes/Sep}/catalogues_sep.ini (100%) rename {Sep => OldCodes/Sep}/configuration_SEP.py (100%) rename {Sep => OldCodes/Sep}/editeur.ini (100%) rename {Sep => OldCodes/Sep}/prefs.py (100%) rename {Sep => OldCodes/Sep}/prefs_SEP.py (100%) rename {Sep => OldCodes/Sep}/properties.py (100%) rename {Sep => OldCodes/Sep}/qtEficas_SEP.py (100%) rename {Sep => OldCodes/Sep}/sdistSEP.py (100%) rename {Sep => OldCodes/Sep}/style.py (100%) rename {UiQT4 => OldCodes/UiQT4}/CMakeLists.txt (100%) rename {UiQT4 => OldCodes/UiQT4}/Newdoc.tgz (100%) rename {UiQT4 => OldCodes/UiQT4}/Tuple2.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/Tuple3.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desBaseWidget.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desChoixCata.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desChoixCode.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desChoixCommandes.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desChoixLangue.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desGroupeOptionnel.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desRecherche.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desRechercheCatalogue.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desSelectVal.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desViewRegles.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desViewTexte.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desVisu.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidget4a6RadioButton.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetBloc.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetCB.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetCommande.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetCommentaire.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetCreeParam.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetDate.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetFact.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetFactPlie.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetFormule.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetHeure.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetInactif.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetInformation.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetMatrice.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetOptionnel.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetOptionnelMC.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetParam.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetPlusieursBase.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetPlusieursInto.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetPlusieursIntoOrdonne.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetPlusieursPlie.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetPlusieursTuple.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetRadioButton.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetSDCOInto.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetSimpBase.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetSimpBool.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetSimpComplexe.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetSimpFichier.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetSimpSalome.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetSimpTxt.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetTuple2.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetTuple3.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetUniqueSDCO.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/desWidgetVide.ui (100%) rename {UiQT4 => OldCodes/UiQT4}/eficas_en.0106.ts (100%) rename {UiQT4 => OldCodes/UiQT4}/eficas_en.ts (100%) rename {UiQT4 => OldCodes/UiQT4}/eficas_fr.0106.ts (100%) rename {UiQT4 => OldCodes/UiQT4}/eficas_fr.ts (100%) rename {UiQT4 => OldCodes/UiQT4}/makefile (100%) rename {UiQT4 => OldCodes/UiQT4}/myMain.ui (100%) rename {ZCracks => OldCodes/ZCracks}/CMakeLists.txt (100%) create mode 100644 OldCodes/ZCracks/configuration_ZCRACKS.py rename {ZCracks => OldCodes/ZCracks}/mesScripts_ZCRACKS.py (100%) rename {ZCracks => OldCodes/ZCracks}/monCode_Cata.py (100%) rename {ZCracks => OldCodes/ZCracks}/monCode_Cata.py.V0 (100%) rename {ZCracks => OldCodes/ZCracks}/prefs.py (100%) rename {ZCracks => OldCodes/ZCracks}/prefs_ZCRACKS.py (100%) create mode 100644 OldCodes/ZCracks/properties.py create mode 100755 OldCodes/ZCracks/qtEficas_ZCracks.py rename {ts => OldCodes/ts}/Telemac_Cata.py (100%) rename {ts => OldCodes/ts}/a.py (100%) rename {ts => OldCodes/ts}/dicoparser.py (100%) rename {ts => OldCodes/ts}/main.ts (100%) rename {ts => OldCodes/ts}/prefs.py (100%) rename {ts => OldCodes/ts}/telemac2dv6p3.dico (100%) rename {ts => OldCodes/ts}/test_cata.py (100%) rename {ts => OldCodes/ts}/test_dicoparser.py (100%) rename {ts => OldCodes/ts}/test_translator.py (100%) rename {ts => OldCodes/ts}/translator.py (100%) rename {ts => OldCodes/ts}/tsparser.py (100%) create mode 100644 SPECA/SPECA_Cata_V2_00.py create mode 100755 Telemac/reecrit_cas_en_comm.py create mode 100644 UiQT5/desWidgetFactHorizon.ui create mode 100644 VirtualPolymer/VP delete mode 100644 VirtualPolymer/opsOT.py create mode 100644 boundary_conditions/CMakeLists.txt create mode 100644 boundary_conditions/__init__.py create mode 100644 boundary_conditions/appli.py create mode 100644 boundary_conditions/boundary_conditions_cata.py create mode 100644 boundary_conditions/configuration_boundary_conditions.py create mode 100644 boundary_conditions/generator_boundary_conditions.py create mode 100644 boundary_conditions/prefs.py create mode 100644 boundary_conditions/prefs_boundary_conditions.py create mode 100644 mascaret/CMakeLists.txt create mode 100644 mascaret/__init__.py create mode 100644 mascaret/appli.py create mode 100644 mascaret/configuration_mascaret.py create mode 100644 mascaret/mascaret_V7_cata.py create mode 100644 mascaret/prefs.py create mode 100644 mascaret/prefs_mascaret.py diff --git a/Adao/ADAO_Cata_V0_V7_7_0.py b/Adao/ADAO_Cata_V0_V7_7_0.py index a39d3133..b9e8c02b 100755 --- a/Adao/ADAO_Cata_V0_V7_7_0.py +++ b/Adao/ADAO_Cata_V0_V7_7_0.py @@ -78,7 +78,7 @@ def F_VectorSerie(statut, fv=NoCheckInNS) : return FACT( statut = statut, FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", ), defaut="Script"), SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", - SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si ariable interne de meme nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), ), STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), diff --git a/Adao/ADAO_Cata_V0_V8_3_0_DEV.py b/Adao/ADAO_Cata_V0_V8_3_0_DEV.py new file mode 100755 index 00000000..78beda68 --- /dev/null +++ b/Adao/ADAO_Cata_V0_V8_3_0_DEV.py @@ -0,0 +1,1270 @@ +#-*-coding:iso-8859-1-*- +# +# Copyright (C) 2008-2017 EDF R&D +# +# This file is part of SALOME ADAO module +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# +# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +# +# Author: Jean-Philippe Argaud, jean-philippe.argaud@edf.fr, EDF R&D + +# -------------------------------------------------------- +# Generated by AdaoCatalogGenerator on 2017-03-06 09:14:06 +# -------------------------------------------------------- + +import os, re +import Accas +from Accas import * + +JdC = JDC_CATA ( + code = 'ADAO', + execmodul = None, + regles = ( AU_MOINS_UN ('ASSIMILATION_STUDY','CHECKING_STUDY'), AU_PLUS_UN ('ASSIMILATION_STUDY','CHECKING_STUDY')), + ) +VERSION_CATALOGUE='V8_3_0' + +def NoCheckInNS(filename): + return 1 +NoCheckInNS.info = "" +def DirectOperatorInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^def[\s]*DirectOperator[\s]*\(") + for ln in fc: + if cr.match(ln): return 1 + cr = re.compile("^DirectOperator[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +DirectOperatorInNS.info = u"The Python file has to contain explicitly a \"DirectOperator\" function definition with only one vector as argument." +def TangentOperatorInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^def[\s]*TangentOperator[\s]*\(") + for ln in fc: + if cr.match(ln): return 1 + cr = re.compile("^TangentOperator[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +TangentOperatorInNS.info = u"The Python file has to contain explicitly a \"TangentOperator\" function definition with only one pair of vectors as argument." +def AdjointOperatorInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^def[\s]*AdjointOperator[\s]*\(") + for ln in fc: + if cr.match(ln): return 1 + cr = re.compile("^AdjointOperator[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +AdjointOperatorInNS.info = u"The Python file has to contain explicitly an \"AdjointOperator\" function definition with only one pair of vectors as argument." + +def F_VectorSerie(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", ), defaut="Script"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def F_Function(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("ScriptWithOneFunction", "ScriptWithFunctions", "ScriptWithSwitch", "FunctionDict", ), defaut="ScriptWithOneFunction"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def F_Matrix(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", ), defaut="Script"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def F_DiagonalSparseMatrix(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", ), defaut="String"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def F_Vector(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", ), defaut="Script"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def F_Dict(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", ), defaut="Script"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def F_ScalarSparseMatrix(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", ), defaut="String"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", defaut="1.", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def ObservationErrorInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^ObservationError[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +ObservationErrorInNS.info = u"The Python file has to contain explicitly a \"ObservationError\" variable." +def F_ObservationError(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Matrix", "ScalarSparseMatrix", "DiagonalSparseMatrix", ), defaut="ScalarSparseMatrix"), + Matrix = BLOC ( condition = " INPUT_TYPE in ( 'Matrix', ) ", + data = F_Matrix("o", fv), + ), + ScalarSparseMatrix = BLOC ( condition = " INPUT_TYPE in ( 'ScalarSparseMatrix', ) ", + data = F_ScalarSparseMatrix("o", fv), + ), + DiagonalSparseMatrix = BLOC ( condition = " INPUT_TYPE in ( 'DiagonalSparseMatrix', ) ", + data = F_DiagonalSparseMatrix("o", fv), + ), + ) + +def ObservationInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^Observation[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +ObservationInNS.info = u"The Python file has to contain explicitly a \"Observation\" variable." +def F_Observation(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Vector", "VectorSerie", ), defaut="Vector"), + Vector = BLOC ( condition = " INPUT_TYPE in ( 'Vector', ) ", + data = F_Vector("o", fv), + ), + VectorSerie = BLOC ( condition = " INPUT_TYPE in ( 'VectorSerie', ) ", + data = F_VectorSerie("o", fv), + ), + ) + +def BackgroundErrorInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^BackgroundError[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +BackgroundErrorInNS.info = u"The Python file has to contain explicitly a \"BackgroundError\" variable." +def F_BackgroundError(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Matrix", "ScalarSparseMatrix", "DiagonalSparseMatrix", ), defaut="ScalarSparseMatrix"), + Matrix = BLOC ( condition = " INPUT_TYPE in ( 'Matrix', ) ", + data = F_Matrix("o", fv), + ), + ScalarSparseMatrix = BLOC ( condition = " INPUT_TYPE in ( 'ScalarSparseMatrix', ) ", + data = F_ScalarSparseMatrix("o", fv), + ), + DiagonalSparseMatrix = BLOC ( condition = " INPUT_TYPE in ( 'DiagonalSparseMatrix', ) ", + data = F_DiagonalSparseMatrix("o", fv), + ), + ) + +def ObservationOperatorInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^ObservationOperator[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +ObservationOperatorInNS.info = u"The Python file has to contain explicitly a \"ObservationOperator\" variable." +def F_ObservationOperator(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Matrix", "Function", ), defaut="Function"), + Matrix = BLOC ( condition = " INPUT_TYPE in ( 'Matrix', ) ", + data = F_Matrix("o", fv), + ), + Function = BLOC ( condition = " INPUT_TYPE in ( 'Function', ) ", + data = F_Function("o", fv), + ), + ) + +def CheckingPointInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^CheckingPoint[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +CheckingPointInNS.info = u"The Python file has to contain explicitly a \"CheckingPoint\" variable." +def F_CheckingPoint(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Vector", ), defaut="Vector"), + Vector = BLOC ( condition = " INPUT_TYPE in ( 'Vector', ) ", + data = F_Vector("o", fv), + ), + ) + +def ControlInputInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^ControlInput[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +ControlInputInNS.info = u"The Python file has to contain explicitly a \"ControlInput\" variable." +def F_ControlInput(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Vector", "VectorSerie", ), defaut="Vector"), + Vector = BLOC ( condition = " INPUT_TYPE in ( 'Vector', ) ", + data = F_Vector("o", fv), + ), + VectorSerie = BLOC ( condition = " INPUT_TYPE in ( 'VectorSerie', ) ", + data = F_VectorSerie("o", fv), + ), + ) + +def BackgroundInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^Background[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +BackgroundInNS.info = u"The Python file has to contain explicitly a \"Background\" variable." +def F_Background(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Vector", "VectorSerie", ), defaut="Vector"), + Vector = BLOC ( condition = " INPUT_TYPE in ( 'Vector', ) ", + data = F_Vector("o", fv), + ), + VectorSerie = BLOC ( condition = " INPUT_TYPE in ( 'VectorSerie', ) ", + data = F_VectorSerie("o", fv), + ), + ) + +def AlgorithmParametersInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^AlgorithmParameters[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +AlgorithmParametersInNS.info = u"The Python file has to contain explicitly a \"AlgorithmParameters\" variable." +def F_AlgorithmParameters(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Dict", ), defaut="Dict"), + Dict = BLOC ( condition = " INPUT_TYPE in ( 'Dict', ) ", + data = F_Dict("o", fv), + ), + ) + +def EvolutionErrorInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^EvolutionError[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +EvolutionErrorInNS.info = u"The Python file has to contain explicitly a \"EvolutionError\" variable." +def F_EvolutionError(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Matrix", "ScalarSparseMatrix", "DiagonalSparseMatrix", ), defaut="ScalarSparseMatrix"), + Matrix = BLOC ( condition = " INPUT_TYPE in ( 'Matrix', ) ", + data = F_Matrix("o", fv), + ), + ScalarSparseMatrix = BLOC ( condition = " INPUT_TYPE in ( 'ScalarSparseMatrix', ) ", + data = F_ScalarSparseMatrix("o", fv), + ), + DiagonalSparseMatrix = BLOC ( condition = " INPUT_TYPE in ( 'DiagonalSparseMatrix', ) ", + data = F_DiagonalSparseMatrix("o", fv), + ), + ) + +def UserDataInitInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^UserDataInit[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +UserDataInitInNS.info = u"The Python file has to contain explicitly a \"UserDataInit\" variable." +def F_UserDataInit(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Dict", ), defaut="Dict"), + Dict = BLOC ( condition = " INPUT_TYPE in ( 'Dict', ) ", + data = F_Dict("o", fv), + ), + ) + +def EvolutionModelInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^EvolutionModel[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +EvolutionModelInNS.info = u"The Python file has to contain explicitly a \"EvolutionModel\" variable." +def F_EvolutionModel(statut, fv=NoCheckInNS) : return FACT( + statut=statut, + Stored = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Choix de stockage interne ou non du concept parent", ang="Choice of the storage or not of the parent concept"), + INPUT_TYPE = SIMP(statut="o", typ = "TXM", into=("Matrix", "Function", ), defaut="Function"), + Matrix = BLOC ( condition = " INPUT_TYPE in ( 'Matrix', ) ", + data = F_Matrix("o", fv), + ), + Function = BLOC ( condition = " INPUT_TYPE in ( 'Function', ) ", + data = F_Function("o", fv), + ), + ) + +def F_UserPostAnalysis(statut, fv=NoCheckInNS) : return FACT( + statut = statut, + FROM = SIMP(statut = "o", typ = "TXM", into=("String", "Script", "Template", ), defaut="Template"), + SCRIPT_DATA = BLOC ( condition = " FROM in ( 'Script', ) ", + SCRIPT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(fv)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant si nécessaire la définition d'une variable interne de même nom que le concept parent", ang="Waiting for a script file name, with or without the full path to find it, containing if necessary the definition of an internal variable of the same name as the parent concept"), + ), + STRING_DATA = BLOC ( condition = " FROM in ( 'String', ) ", + STRING = SIMP(statut = "o", typ = "TXM", fr="En attente d'une chaine de caractères entre guillements. Pour construire un vecteur ou une matrice, ce doit être une suite de nombres, utilisant un espace ou une virgule pour séparer deux éléments et un point-virgule pour séparer deux lignes", ang="Waiting for a string in quotes. To build a vector or a matrix, it has to be a float serie, using a space or comma to separate two elements in a line, a semi-colon to separate rows"), + ), + SCRIPTWITHFUNCTIONS_DATA = BLOC ( condition = " FROM in ( 'ScriptWithFunctions', ) ", + SCRIPTWITHFUNCTIONS_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS), FunctionVal(TangentOperatorInNS), FunctionVal(AdjointOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variables internes trois fonctions de calcul nommées DirectOperator, TangentOperator et AdjointOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variables three computation functions named DirectOperator, TangentOperator and AdjointOperator"), + ), + SCRIPTWITHONEFUNCTION_DATA = BLOC ( condition = " FROM in ( 'ScriptWithOneFunction', ) ", + SCRIPTWITHONEFUNCTION_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py'), FunctionVal(DirectOperatorInNS)], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant en variable interne une seule fonction de calcul nommée DirectOperator", ang="Waiting for a script file name, with or without the full path to find it, containing as internal variable only one function named DirectOperator"), + DifferentialIncrement = SIMP(statut="o", typ = "R", val_min=0, val_max=1, defaut=0.01, fr="Incrément de la perturbation dX pour calculer la dérivée, construite en multipliant X par l'incrément en évitant les valeurs nulles", ang="Increment of dX perturbation to calculate the derivative, build multiplying X by the increment avoiding null values"), + CenteredFiniteDifference = SIMP(statut="o", typ = "I", into=(0, 1), defaut=0, fr="Formulation centrée (1) ou décentrée (0) pour la méthode des différences finies", ang="Centered (1) or uncentered (0) formulation for the finite differences method"), + EnableMultiProcessing = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0, fr="Calculs élémentaires effectués en séquentiel (0) ou en parallèle (1) dans la méthode des différences finies", ang="Elementary calculations done sequentially (0) or in parallel (1) in the finite differences method"), + NumberOfProcesses = SIMP(statut="f", typ = "I", val_min=0, defaut=0, fr="Nombre de processus parallèles, 0 pour un contrôle automatique", ang="Number of parallel processes, 0 for automatic control"), + ), + SCRIPTWITHSWITCH_DATA = BLOC ( condition = " FROM in ( 'ScriptWithSwitch', ) ", + SCRIPTWITHSWITCH_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')], fr="En attente d'un nom de fichier script, avec ou sans le chemin complet pour le trouver, contenant un switch pour les calculs direct, tangent et adjoint", ang="Waiting for a script file name, with or without the full path to find it, containing a switch for direct, tangent and adjoint computations"), + ), + TEMPLATE_DATA = BLOC (condition = " FROM in ( 'Template', ) ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "AnalysisPrinter", into=("AnalysisPrinter", "AnalysisSaver", "AnalysisPrinterAndSaver")), + AnalysisPrinter = BLOC (condition = " Template == 'AnalysisPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa" ), + ), + AnalysisSaver = BLOC (condition = " Template == 'AnalysisSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + AnalysisPrinterAndSaver = BLOC (condition = " Template == 'AnalysisPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nxa=numpy.ravel(ADD.get('Analysis')[-1])\nprint 'Analysis:',xa\nf='/tmp/analysis.txt'\nprint 'Analysis saved in \"%s\"'%f\nnumpy.savetxt(f,xa)" ), + ), + ), + ) + +def F_InitChoice() : return ("Background", + "BackgroundError", + "Observation", + "ObservationError", + "ObservationOperator", + "EvolutionModel", + "EvolutionError", + "AlgorithmParameters", + "UserPostAnalysis", + ) + +def F_Init(statut) : return FACT(statut = statut, + INIT_FILE = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]), + TARGET_LIST = SIMP(statut = "o", typ = "TXM", min=1, max="**", into=F_InitChoice(), validators=(VerifExiste(2))), + ) + +def F_ObserverTemplate() : return BLOC(condition = " NodeType == 'Template' ", + Template = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "ValuePrinter", into=("ValuePrinter", "ValueAndIndexPrinter", "ValueSeriePrinter", "ValueSaver", "ValueSerieSaver", "ValuePrinterAndSaver", "ValueIndexPrinterAndSaver", "ValueSeriePrinterAndSaver", "ValueGnuPlotter", "ValueSerieGnuPlotter", "ValuePrinterAndGnuPlotter", "ValueSeriePrinterAndGnuPlotter", "ValuePrinterSaverAndGnuPlotter", "ValueSeriePrinterSaverAndGnuPlotter", "ValueMean", "ValueStandardError", "ValueVariance", "ValueL2Norm", "ValueRMS")), + ValuePrinter = BLOC (condition = " Template == 'ValuePrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "print(str(info)+\" \"+str(var[-1]))", fr="Imprime sur la sortie standard la valeur courante de la variable", ang="Print on standard output the current value of the variable" ), + ), + ValueAndIndexPrinter = BLOC (condition = " Template == 'ValueAndIndexPrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "print(str(info)+(\" index %i:\"%(len(var)-1))+\" \"+str(var[-1]))", fr="Imprime sur la sortie standard la valeur courante de la variable, en ajoutant son index", ang="Print on standard output the current value of the variable, adding its index" ), + ), + ValueSeriePrinter = BLOC (condition = " Template == 'ValueSeriePrinter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "print(str(info)+\" \"+str(var[:]))", fr="Imprime sur la sortie standard la série des valeurs de la variable", ang="Print on standard output the value series of the variable" ), + ), + ValueSaver = BLOC (condition = " Template == 'ValueSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy, re\nv=numpy.array(var[-1], ndmin=1)\nglobal istep\ntry:\n istep += 1\nexcept:\n istep = 0\nf='/tmp/value_%s_%05i.txt'%(info,istep)\nf=re.sub('\s','_',f)\nprint('Value saved in \"%s\"'%f)\nnumpy.savetxt(f,v)", fr="Enregistre la valeur courante de la variable dans un fichier du répertoire '/tmp' nommé 'value...txt' selon le nom de la variable et l'étape d'enregistrement", ang="Save the current value of the variable in a file of the '/tmp' directory named 'value...txt' from the variable name and the saving step" ), + ), + ValueSerieSaver = BLOC (condition = " Template == 'ValueSerieSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy, re\nv=numpy.array(var[:], ndmin=1)\nglobal istep\ntry:\n istep += 1\nexcept:\n istep = 0\nf='/tmp/value_%s_%05i.txt'%(info,istep)\nf=re.sub('\s','_',f)\nprint('Value saved in \"%s\"'%f)\nnumpy.savetxt(f,v)", fr="Enregistre la série des valeurs de la variable dans un fichier du répertoire '/tmp' nommé 'value...txt' selon le nom de la variable et l'étape", ang="Save the value series of the variable in a file of the '/tmp' directory named 'value...txt' from the variable name and the saving step" ), + ), + ValuePrinterAndSaver = BLOC (condition = " Template == 'ValuePrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy, re\nv=numpy.array(var[-1], ndmin=1)\nprint(str(info)+\" \"+str(v))\nglobal istep\ntry:\n istep += 1\nexcept:\n istep = 0\nf='/tmp/value_%s_%05i.txt'%(info,istep)\nf=re.sub('\s','_',f)\nprint('Value saved in \"%s\"'%f)\nnumpy.savetxt(f,v)", fr="Imprime sur la sortie standard et, en même temps enregistre dans un fichier, la valeur courante de la variable", ang="Print on standard output and, in the same time save in a file, the current value of the variable" ), + ), + ValueIndexPrinterAndSaver = BLOC (condition = " Template == 'ValueIndexPrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy, re\nv=numpy.array(var[-1], ndmin=1)\nprint(str(info)+(\" index %i:\"%(len(var)-1))+\" \"+str(v))\nglobal istep\ntry:\n istep += 1\nexcept:\n istep = 0\nf='/tmp/value_%s_%05i.txt'%(info,istep)\nf=re.sub('\s','_',f)\nprint('Value saved in \"%s\"'%f)\nnumpy.savetxt(f,v)", fr="Imprime sur la sortie standard et, en même temps enregistre dans un fichier, la valeur courante de la variable, en ajoutant son index", ang="Print on standard output and, in the same time save in a file, the current value of the variable, adding its index" ), + ), + ValueSeriePrinterAndSaver = BLOC (condition = " Template == 'ValueSeriePrinterAndSaver' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy, re\nv=numpy.array(var[:], ndmin=1)\nprint(str(info)+\" \"+str(v))\nglobal istep\ntry:\n istep += 1\nexcept:\n istep = 0\nf='/tmp/value_%s_%05i.txt'%(info,istep)\nf=re.sub('\s','_',f)\nprint('Value saved in \"%s\"'%f)\nnumpy.savetxt(f,v)", fr="Imprime sur la sortie standard et, en même temps, enregistre dans un fichier la série des valeurs de la variable", ang="Print on standard output and, in the same time, save in a file the value series of the variable" ), + ), + ValueGnuPlotter = BLOC (condition = " Template == 'ValueGnuPlotter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy, Gnuplot\nv=numpy.array(var[-1], ndmin=1)\nglobal ifig, gp\ntry:\n ifig += 1\n gp(' set style data lines')\nexcept:\n ifig = 0\n gp = Gnuplot.Gnuplot(persist=1)\n gp(' set style data lines')\ngp('set title \"%s (Figure %i)\"'%(info,ifig))\ngp.plot( Gnuplot.Data( v, with_='lines lw 2' ) )", fr="Affiche graphiquement avec Gnuplot la valeur courante de la variable", ang="Graphically plot with Gnuplot the current value of the variable" ), + ), + ValueSerieGnuPlotter = BLOC (condition = " Template == 'ValueSerieGnuPlotter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy, Gnuplot\nv=numpy.array(var[:], ndmin=1)\nglobal ifig, gp\ntry:\n ifig += 1\n gp(' set style data lines')\nexcept:\n ifig = 0\n gp = Gnuplot.Gnuplot(persist=1)\n gp(' set style data lines')\ngp('set title \"%s (Figure %i)\"'%(info,ifig))\ngp.plot( Gnuplot.Data( v, with_='lines lw 2' ) )", fr="Affiche graphiquement avec Gnuplot la série des valeurs de la variable", ang="Graphically plot with Gnuplot the value series of the variable" ), + ), + ValuePrinterAndGnuPlotter = BLOC (condition = " Template == 'ValuePrinterAndGnuPlotter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "print(str(info)+\" \"+str(var[-1]))\nimport numpy, Gnuplot\nv=numpy.array(var[-1], ndmin=1)\nglobal ifig,gp\ntry:\n ifig += 1\n gp(' set style data lines')\nexcept:\n ifig = 0\n gp = Gnuplot.Gnuplot(persist=1)\n gp(' set style data lines')\ngp('set title \"%s (Figure %i)\"'%(info,ifig))\ngp.plot( Gnuplot.Data( v, with_='lines lw 2' ) )", fr="Imprime sur la sortie standard et, en même temps, affiche graphiquement avec Gnuplot la valeur courante de la variable", ang="Print on standard output and, in the same time, graphically plot with Gnuplot the current value of the variable" ), + ), + ValueSeriePrinterAndGnuPlotter = BLOC (condition = " Template == 'ValueSeriePrinterAndGnuPlotter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "print(str(info)+\" \"+str(var[:]))\nimport numpy, Gnuplot\nv=numpy.array(var[:], ndmin=1)\nglobal ifig,gp\ntry:\n ifig += 1\n gp(' set style data lines')\nexcept:\n ifig = 0\n gp = Gnuplot.Gnuplot(persist=1)\n gp(' set style data lines')\ngp('set title \"%s (Figure %i)\"'%(info,ifig))\ngp.plot( Gnuplot.Data( v, with_='lines lw 2' ) )", fr="Imprime sur la sortie standard et, en même temps, affiche graphiquement avec Gnuplot la série des valeurs de la variable", ang="Print on standard output and, in the same time, graphically plot with Gnuplot the value series of the variable" ), + ), + ValuePrinterSaverAndGnuPlotter = BLOC (condition = " Template == 'ValuePrinterSaverAndGnuPlotter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "print(str(info)+\" \"+str(var[-1]))\nimport numpy, re\nv=numpy.array(var[-1], ndmin=1)\nglobal istep\ntry:\n istep += 1\nexcept:\n istep = 0\nf='/tmp/value_%s_%05i.txt'%(info,istep)\nf=re.sub('\s','_',f)\nprint('Value saved in \"%s\"'%f)\nnumpy.savetxt(f,v)\nimport Gnuplot\nglobal ifig,gp\ntry:\n ifig += 1\n gp(' set style data lines')\nexcept:\n ifig = 0\n gp = Gnuplot.Gnuplot(persist=1)\n gp(' set style data lines')\ngp('set title \"%s (Figure %i)\"'%(info,ifig))\ngp.plot( Gnuplot.Data( v, with_='lines lw 2' ) )", fr="Imprime sur la sortie standard et, en même temps, enregistre dans un fichier et affiche graphiquement la valeur courante de la variable ", ang="Print on standard output and, in the same, time save in a file and graphically plot the current value of the variable" ), + ), + ValueSeriePrinterSaverAndGnuPlotter = BLOC (condition = " Template == 'ValueSeriePrinterSaverAndGnuPlotter' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "print(str(info)+\" \"+str(var[:]))\nimport numpy, re\nv=numpy.array(var[:], ndmin=1)\nglobal istep\ntry:\n istep += 1\nexcept:\n istep = 0\nf='/tmp/value_%s_%05i.txt'%(info,istep)\nf=re.sub('\s','_',f)\nprint('Value saved in \"%s\"'%f)\nnumpy.savetxt(f,v)\nimport Gnuplot\nglobal ifig,gp\ntry:\n ifig += 1\n gp(' set style data lines')\nexcept:\n ifig = 0\n gp = Gnuplot.Gnuplot(persist=1)\n gp(' set style data lines')\ngp('set title \"%s (Figure %i)\"'%(info,ifig))\ngp.plot( Gnuplot.Data( v, with_='lines lw 2' ) )", fr="Imprime sur la sortie standard et, en même temps, enregistre dans un fichier et affiche graphiquement la série des valeurs de la variable", ang="Print on standard output and, in the same, time save in a file and graphically plot the value series of the variable" ), + ), + ValueMean = BLOC (condition = " Template == 'ValueMean' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nprint(str(info)+\" \"+str(numpy.nanmean(var[-1])))", fr="Imprime sur la sortie standard la moyenne de la valeur courante de la variable", ang="Print on standard output the mean of the current value of the variable" ), + ), + ValueStandardError = BLOC (condition = " Template == 'ValueStandardError' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nprint(str(info)+\" \"+str(numpy.nanstd(var[-1])))", fr="Imprime sur la sortie standard l'écart-type de la valeur courante de la variable", ang="Print on standard output the standard error of the current value of the variable" ), + ), + ValueVariance = BLOC (condition = " Template == 'ValueVariance' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nprint(str(info)+\" \"+str(numpy.nanvar(var[-1])))", fr="Imprime sur la sortie standard la variance de la valeur courante de la variable", ang="Print on standard output the variance of the current value of the variable" ), + ), + ValueL2Norm = BLOC (condition = " Template == 'ValueL2Norm' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nv = numpy.matrix( numpy.ravel( var[-1] ) )\nprint(str(info)+\" \"+str(float( numpy.linalg.norm(v) )))", fr="Imprime sur la sortie standard la norme L2 de la valeur courante de la variable", ang="Print on standard output the L2 norm of the current value of the variable" ), + ), + ValueRMS = BLOC (condition = " Template == 'ValueRMS' ", + ValueTemplate = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "import numpy\nv = numpy.matrix( numpy.ravel( var[-1] ) )\nprint(str(info)+\" \"+str(float( numpy.sqrt((1./v.size)*(v*v.T)) )))", fr="Imprime sur la sortie standard la racine de la moyenne des carrés (RMS), ou moyenne quadratique, de la valeur courante de la variable", ang="Print on standard output the root mean square (RMS), or quadratic mean, of the current value of the variable" ), + ), + ) + +def F_Observers(statut) : return FACT( + statut=statut, + SELECTION = SIMP(statut="o", defaut=[], typ="TXM", min=0, max="**",homo="SansOrdreNiDoublon", validators=NoRepeat(), into=(['Analysis', 'Innovation', 'InnovationAtCurrentState', 'CurrentState', 'CurrentOptimum', 'IndexOfOptimum', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum', 'SimulatedObservationAtCurrentOptimum', 'BMA', 'OMA', 'OMB', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'GradientOfCostFunctionJ', 'GradientOfCostFunctionJb', 'GradientOfCostFunctionJo', 'SigmaObs2', 'SigmaBck2', 'APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'Residu'])), + #SELECTION = SIMP(statut="o", defaut=[], typ="TXM", min=0, max="**", validators=NoRepeat(), into=(['Analysis', 'Innovation', 'InnovationAtCurrentState', 'CurrentState', 'CurrentOptimum', 'IndexOfOptimum', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum', 'SimulatedObservationAtCurrentOptimum', 'BMA', 'OMA', 'OMB', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'GradientOfCostFunctionJ', 'GradientOfCostFunctionJb', 'GradientOfCostFunctionJo', 'SigmaObs2', 'SigmaBck2', 'APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'Residu'])), + Analysis = BLOC (condition=" 'Analysis' in set(SELECTION) ", + Analysis_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "Analysis"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + Innovation = BLOC (condition=" 'Innovation' in set(SELECTION) ", + Innovation_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "Innovation"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + InnovationAtCurrentState = BLOC (condition=" 'InnovationAtCurrentState' in set(SELECTION) ", + InnovationAtCurrentState_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "InnovationAtCurrentState"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + CurrentState = BLOC (condition=" 'CurrentState' in set(SELECTION) ", + CurrentState_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "CurrentState"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + CurrentOptimum = BLOC (condition=" 'CurrentOptimum' in set(SELECTION) ", + CurrentOptimum_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "CurrentOptimum"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + IndexOfOptimum = BLOC (condition=" 'IndexOfOptimum' in set(SELECTION) ", + IndexOfOptimum_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "IndexOfOptimum"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + SimulatedObservationAtBackground = BLOC (condition=" 'SimulatedObservationAtBackground' in set(SELECTION) ", + SimulatedObservationAtBackground_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "SimulatedObservationAtBackground"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + SimulatedObservationAtCurrentState = BLOC (condition=" 'SimulatedObservationAtCurrentState' in set(SELECTION) ", + SimulatedObservationAtCurrentState_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "SimulatedObservationAtCurrentState"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + SimulatedObservationAtOptimum = BLOC (condition=" 'SimulatedObservationAtOptimum' in set(SELECTION) ", + SimulatedObservationAtOptimum_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "SimulatedObservationAtOptimum"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + SimulatedObservationAtCurrentOptimum = BLOC (condition=" 'SimulatedObservationAtCurrentOptimum' in set(SELECTION) ", + SimulatedObservationAtCurrentOptimum_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "SimulatedObservationAtCurrentOptimum"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + BMA = BLOC (condition=" 'BMA' in set(SELECTION) ", + BMA_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "BMA"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + OMA = BLOC (condition=" 'OMA' in set(SELECTION) ", + OMA_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "OMA"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + OMB = BLOC (condition=" 'OMB' in set(SELECTION) ", + OMB_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "OMB"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + CostFunctionJ = BLOC (condition=" 'CostFunctionJ' in set(SELECTION) ", + CostFunctionJ_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "CostFunctionJ"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + CostFunctionJb = BLOC (condition=" 'CostFunctionJb' in set(SELECTION) ", + CostFunctionJb_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "CostFunctionJb"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + CostFunctionJo = BLOC (condition=" 'CostFunctionJo' in set(SELECTION) ", + CostFunctionJo_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "CostFunctionJo"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + GradientOfCostFunctionJ = BLOC (condition=" 'GradientOfCostFunctionJ' in set(SELECTION) ", + GradientOfCostFunctionJ_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "GradientOfCostFunctionJ"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + GradientOfCostFunctionJb = BLOC (condition=" 'GradientOfCostFunctionJb' in set(SELECTION) ", + GradientOfCostFunctionJb_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "GradientOfCostFunctionJb"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + GradientOfCostFunctionJo = BLOC (condition=" 'GradientOfCostFunctionJo' in set(SELECTION) ", + GradientOfCostFunctionJo_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "GradientOfCostFunctionJo"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + SigmaObs2 = BLOC (condition=" 'SigmaObs2' in set(SELECTION) ", + SigmaObs2_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "SigmaObs2"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + SigmaBck2 = BLOC (condition=" 'SigmaBck2' in set(SELECTION) ", + SigmaBck2_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "SigmaBck2"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + APosterioriCorrelations = BLOC (condition=" 'APosterioriCorrelations' in set(SELECTION) ", + APosterioriCorrelations_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "APosterioriCorrelations"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + APosterioriCovariance = BLOC (condition=" 'APosterioriCovariance' in set(SELECTION) ", + APosterioriCovariance_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "APosterioriCovariance"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + APosterioriStandardDeviations = BLOC (condition=" 'APosterioriStandardDeviations' in set(SELECTION) ", + APosterioriStandardDeviations_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "APosterioriStandardDeviations"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + APosterioriVariances = BLOC (condition=" 'APosterioriVariances' in set(SELECTION) ", + APosterioriVariances_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "APosterioriVariances"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + Residu = BLOC (condition=" 'Residu' in set(SELECTION) ", + Residu_data = FACT(statut = "o", + Scheduler = SIMP(statut = "f", typ = "TXM"), + Info = SIMP(statut = "o", typ = "TXM", defaut = "Residu"), + NodeType = SIMP(statut = "o", typ = "TXM", min=1, max=1, defaut = "Template", into=("String", "Script", "Template")), + PythonScript = BLOC (condition = " NodeType == 'String' ", + Value = SIMP(statut = "o", typ = "TXM") + ), + UserFile = BLOC (condition = " NodeType == 'Script' ", + Value = SIMP(statut = "o", typ = "FichierNoAbs", validators=[OnlyStr(), FileExtVal('py')]) + ), + ObserverTemplate = F_ObserverTemplate(), + ), + ), + ) + +def AlgorithmParametersInNS(filename): + if os.path.exists(filename): + fc = open(filename, 'r').readlines() + cr = re.compile("^AlgorithmParameters[\s]*=") + for ln in fc: + if cr.match(ln): return 1 + return 0 +AlgorithmParametersInNS.info = u"The Python file has to contain explicitly an \"AlgorithmParameters\" variable." +def F_AlgorithmParameters(statut, algos_names, fv=NoCheckInNS) : return FACT( + statut = statut, + Algorithm = SIMP(statut="o", typ = "TXM", into = algos_names ), + Parameters = SIMP(statut="f", typ = "TXM", into=("Defaults", "Dict") ), + Dict = BLOC ( condition = " Parameters == 'Dict' ", + statut="f", + data = F_Dict("o", fv), + ), + Parameters3DVAR = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == '3DVAR') ", + statut="f", + Bounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes"), + CostDecrementTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-07, fr="Diminution relative minimale du cout lors de l'arrêt"), + GradientNormTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-05, fr="Maximum des composantes du gradient lors de l'arrêt"), + MaximumNumberOfSteps = SIMP(statut="f", typ="I", val_min=-1, min=1, max=1, defaut=15000, fr="Nombre maximal de pas d'optimisation"), + Minimizer = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="LBFGSB", into=['LBFGSB', 'TNC', 'CG', 'NCG', 'BFGS'], fr="Minimiseur utilisé"), + NumberOfSamplesForQuantiles = SIMP(statut="f", typ="I", val_min=1, min=1, max=1, defaut=100, fr="Nombre d'échantillons simulés pour le calcul des quantiles"), + ProjectedGradientTolerance = SIMP(statut="f", typ="R", val_min=-1, min=1, max=1, defaut=-1.0, fr="Maximum des composantes du gradient projeté lors de l'arrêt"), + Quantiles = SIMP(statut="f", typ="TXM", max="**", into=None, fr="Liste des valeurs de quantiles"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + SimulationForQuantiles = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="Linear", into=['Linear', 'NonLinear'], fr="Type de simulation pour l'estimation des quantiles"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'BMA', 'OMA', 'OMB', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'CurrentState', 'CurrentOptimum', 'IndexOfOptimum', 'Innovation', 'InnovationAtCurrentState', 'CostFunctionJAtCurrentOptimum', 'SigmaObs2', 'MahalanobisConsistency', 'SimulationQuantiles', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum', 'SimulatedObservationAtCurrentOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + Parameters4DVAR = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == '4DVAR') ", + statut="f", + Bounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes"), + ConstrainedBy = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="EstimateProjection", into=['EstimateProjection'], fr="Prise en compte des contraintes"), + CostDecrementTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-07, fr="Diminution relative minimale du cout lors de l'arrêt"), + EstimationOf = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="State", into=['State', 'Parameters'], fr="Estimation d'etat ou de parametres"), + GradientNormTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-05, fr="Maximum des composantes du gradient lors de l'arrêt"), + MaximumNumberOfSteps = SIMP(statut="f", typ="I", val_min=-1, min=1, max=1, defaut=15000, fr="Nombre maximal de pas d'optimisation"), + Minimizer = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="LBFGSB", into=['LBFGSB', 'TNC', 'CG', 'NCG', 'BFGS'], fr="Minimiseur utilisé"), + ProjectedGradientTolerance = SIMP(statut="f", typ="R", val_min=-1, min=1, max=1, defaut=-1.0, fr="Maximum des composantes du gradient projeté lors de l'arrêt"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['BMA', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'IndexOfOptimum', 'CurrentOptimum', 'CostFunctionJAtCurrentOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersBlue = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'Blue') ", + statut="f", + NumberOfSamplesForQuantiles = SIMP(statut="f", typ="I", val_min=1, min=1, max=1, defaut=100, fr="Nombre d'échantillons simulés pour le calcul des quantiles"), + Quantiles = SIMP(statut="f", typ="TXM", max="**", into=None, fr="Liste des valeurs de quantiles"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + SimulationForQuantiles = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="Linear", into=['Linear', 'NonLinear'], fr="Type de simulation pour l'estimation des quantiles"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'BMA', 'OMA', 'OMB', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation', 'SigmaBck2', 'SigmaObs2', 'MahalanobisConsistency', 'SimulationQuantiles', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersDerivativeFreeOptimization = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'DerivativeFreeOptimization') ", + statut="f", + Bounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes"), + CostDecrementTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-07, fr="Diminution relative minimale du cout lors de l'arrêt"), + MaximumNumberOfFunctionEvaluations = SIMP(statut="f", typ="I", val_min=-1, min=1, max=1, defaut=15000, fr="Nombre maximal d'évaluations de la fonction"), + MaximumNumberOfSteps = SIMP(statut="f", typ="I", val_min=-1, min=1, max=1, defaut=15000, fr="Nombre maximal de pas d'optimisation"), + Minimizer = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="BOBYQA", into=['BOBYQA', 'COBYLA', 'NEWUOA', 'POWELL', 'SIMPLEX', 'SUBPLEX'], fr="Minimiseur utilisé"), + QualityCriterion = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="AugmentedWeightedLeastSquares", into=['AugmentedWeightedLeastSquares', 'AWLS', 'DA', 'WeightedLeastSquares', 'WLS', 'LeastSquares', 'LS', 'L2', 'AbsoluteValue', 'L1', 'MaximumError', 'ME'], fr="Critère de qualité utilisé"), + StateVariationTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=0.0001, fr="Variation relative maximale de l'état lors de l'arrêt"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'CostFunctionJAtCurrentOptimum', 'CurrentOptimum', 'IndexOfOptimum', 'InnovationAtCurrentState', 'BMA', 'OMA', 'OMB', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentOptimum', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersEnsembleBlue = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'EnsembleBlue') ", + statut="f", + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CurrentState', 'Innovation', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersExtendedBlue = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'ExtendedBlue') ", + statut="f", + NumberOfSamplesForQuantiles = SIMP(statut="f", typ="I", val_min=1, min=1, max=1, defaut=100, fr="Nombre d'échantillons simulés pour le calcul des quantiles"), + Quantiles = SIMP(statut="f", typ="TXM", max="**", into=None, fr="Liste des valeurs de quantiles"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + SimulationForQuantiles = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="Linear", into=['Linear', 'NonLinear'], fr="Type de simulation pour l'estimation des quantiles"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'BMA', 'OMA', 'OMB', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation', 'SigmaBck2', 'SigmaObs2', 'MahalanobisConsistency', 'SimulationQuantiles', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersExtendedKalmanFilter = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'ExtendedKalmanFilter') ", + statut="f", + Bounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes"), + ConstrainedBy = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="EstimateProjection", into=['EstimateProjection'], fr="Prise en compte des contraintes"), + EstimationOf = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="State", into=['State', 'Parameters'], fr="Estimation d'etat ou de parametres"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'BMA', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersKalmanFilter = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'KalmanFilter') ", + statut="f", + EstimationOf = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="State", into=['State', 'Parameters'], fr="Estimation d'etat ou de parametres"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'BMA', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersLinearLeastSquares = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'LinearLeastSquares') ", + statut="f", + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['OMA', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersNonLinearLeastSquares = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'NonLinearLeastSquares') ", + statut="f", + Bounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes"), + CostDecrementTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-07, fr="Diminution relative minimale du cout lors de l'arrêt"), + GradientNormTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-05, fr="Maximum des composantes du gradient lors de l'arrêt"), + MaximumNumberOfSteps = SIMP(statut="f", typ="I", val_min=-1, min=1, max=1, defaut=15000, fr="Nombre maximal de pas d'optimisation"), + Minimizer = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="LBFGSB", into=['LBFGSB', 'TNC', 'CG', 'NCG', 'BFGS', 'LM'], fr="Minimiseur utilisé"), + ProjectedGradientTolerance = SIMP(statut="f", typ="R", val_min=-1, min=1, max=1, defaut=-1.0, fr="Maximum des composantes du gradient projeté lors de l'arrêt"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['BMA', 'OMA', 'OMB', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersParticleSwarmOptimization = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'ParticleSwarmOptimization') ", + statut="f", + BoxBounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes d'incréments de paramètres"), + GroupRecallRate = SIMP(statut="f", typ="R", val_min=0.0, val_max=1.0, min=1, max=1, defaut=0.5, fr="Taux de rappel au meilleur insecte du groupe (entre 0 et 1)"), + MaximumNumberOfFunctionEvaluations = SIMP(statut="f", typ="I", val_min=-1, min=1, max=1, defaut=15000, fr="Nombre maximal d'évaluations de la fonction"), + MaximumNumberOfSteps = SIMP(statut="f", typ="I", val_min=0, min=1, max=1, defaut=50, fr="Nombre maximal de pas d'optimisation"), + NumberOfInsects = SIMP(statut="f", typ="I", val_min=-1, min=1, max=1, defaut=100, fr="Nombre d'insectes dans l'essaim"), + QualityCriterion = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="AugmentedWeightedLeastSquares", into=['AugmentedWeightedLeastSquares', 'AWLS', 'AugmentedPonderatedLeastSquares', 'APLS', 'DA', 'WeightedLeastSquares', 'WLS', 'PonderatedLeastSquares', 'PLS', 'LeastSquares', 'LS', 'L2', 'AbsoluteValue', 'L1', 'MaximumError', 'ME'], fr="Critère de qualité utilisé"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['BMA', 'OMA', 'OMB', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + SwarmVelocity = SIMP(statut="f", typ="R", val_min=0.0, min=1, max=1, defaut=1.0, fr="Vitesse de groupe imposée par l'essaim"), + ), + ParametersQuantileRegression = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'QuantileRegression') ", + statut="f", + Bounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes"), + CostDecrementTolerance = SIMP(statut="f", typ="R", min=1, max=1, defaut=1e-06, fr="Maximum de variation de la fonction d'estimation lors de l'arrêt"), + MaximumNumberOfSteps = SIMP(statut="f", typ="I", val_min=1, min=1, max=1, defaut=15000, fr="Nombre maximal de pas d'optimisation"), + Minimizer = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="MMQR", into=['MMQR'], fr="Minimiseur utilisé"), + Quantile = SIMP(statut="f", typ="R", val_min=0.0, val_max=1.0, min=1, max=1, defaut=0.5, fr="Quantile pour la regression de quantile"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['BMA', 'OMA', 'OMB', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation', 'SimulatedObservationAtBackground', 'SimulatedObservationAtCurrentState', 'SimulatedObservationAtOptimum'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersUnscentedKalmanFilter = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'UnscentedKalmanFilter') ", + statut="f", + Alpha = SIMP(statut="f", typ="R", val_min=0.0001, val_max=1.0, min=1, max=1, defaut=1.0, fr=""), + Beta = SIMP(statut="f", typ="R", min=1, max=1, defaut=2.0, fr=""), + Bounds = SIMP(statut="f", typ="TXM", fr="Liste des valeurs de bornes"), + ConstrainedBy = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="EstimateProjection", into=['EstimateProjection'], fr="Prise en compte des contraintes"), + EstimationOf = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="State", into=['State', 'Parameters'], fr="Estimation d'etat ou de parametres"), + Kappa = SIMP(statut="f", typ="I", val_max=2, min=1, max=1, defaut=0, fr=""), + Reconditioner = SIMP(statut="f", typ="R", val_min=0.001, val_max=10.0, min=1, max=1, defaut=1.0, fr=""), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['APosterioriCorrelations', 'APosterioriCovariance', 'APosterioriStandardDeviations', 'APosterioriVariances', 'BMA', 'CurrentState', 'CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'Innovation'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersAdjointTest = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'AdjointTest') ", + statut="f", + AmplitudeOfInitialDirection = SIMP(statut="f", typ="R", min=1, max=1, defaut=1.0, fr="Amplitude de la direction initiale de la dérivée directionnelle autour du point nominal"), + EpsilonMinimumExponent = SIMP(statut="f", typ="I", val_min=-20, val_max=0, min=1, max=1, defaut=-8, fr="Exposant minimal en puissance de 10 pour le multiplicateur d'incrément"), + InitialDirection = SIMP(statut="f", typ="TXM", fr="Direction initiale de la dérivée directionnelle autour du point nominal"), + ResiduFormula = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="ScalarProduct", into=['ScalarProduct'], fr="Formule de résidu utilisée"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CurrentState', 'Residu', 'SimulatedObservationAtCurrentState'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersFunctionTest = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'FunctionTest') ", + statut="f", + NumberOfPrintedDigits = SIMP(statut="f", typ="I", val_min=0, min=1, max=1, defaut=5, fr="Nombre de chiffres affichés pour les impressions de réels"), + NumberOfRepetition = SIMP(statut="f", typ="I", val_min=1, min=1, max=1, defaut=1, fr="Nombre de fois où l'exécution de la fonction est répétée"), + SetDebug = SIMP(statut="f", typ="I", min=1, max=1, defaut=0, fr="Activation du mode debug lors de l'exécution"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CurrentState', 'SimulatedObservationAtCurrentState'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersGradientTest = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'GradientTest') ", + statut="f", + AmplitudeOfInitialDirection = SIMP(statut="f", typ="R", min=1, max=1, defaut=1.0, fr="Amplitude de la direction initiale de la dérivée directionnelle autour du point nominal"), + AmplitudeOfTangentPerturbation = SIMP(statut="f", typ="R", val_min=1e-10, val_max=1.0, min=1, max=1, defaut=0.01, fr="Amplitude de la perturbation pour le calcul de la forme tangente"), + EpsilonMinimumExponent = SIMP(statut="f", typ="I", val_min=-20, val_max=0, min=1, max=1, defaut=-8, fr="Exposant minimal en puissance de 10 pour le multiplicateur d'incrément"), + InitialDirection = SIMP(statut="f", typ="TXM", fr="Direction initiale de la dérivée directionnelle autour du point nominal"), + ResiduFormula = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="Taylor", into=['Norm', 'TaylorOnNorm', 'Taylor'], fr="Formule de résidu utilisée"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CurrentState', 'Residu', 'SimulatedObservationAtCurrentState'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersLinearityTest = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'LinearityTest') ", + statut="f", + AmplitudeOfInitialDirection = SIMP(statut="f", typ="R", min=1, max=1, defaut=1.0, fr="Amplitude de la direction initiale de la dérivée directionnelle autour du point nominal"), + AmplitudeOfTangentPerturbation = SIMP(statut="f", typ="R", val_min=1e-10, val_max=1.0, min=1, max=1, defaut=0.01, fr="Amplitude de la perturbation pour le calcul de la forme tangente"), + EpsilonMinimumExponent = SIMP(statut="f", typ="I", val_min=-20, val_max=0, min=1, max=1, defaut=-8, fr="Exposant minimal en puissance de 10 pour le multiplicateur d'incrément"), + InitialDirection = SIMP(statut="f", typ="TXM", fr="Direction initiale de la dérivée directionnelle autour du point nominal"), + ResiduFormula = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="CenteredDL", into=['CenteredDL', 'Taylor', 'NominalTaylor', 'NominalTaylorRMS'], fr="Formule de résidu utilisée"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CurrentState', 'Residu', 'SimulatedObservationAtCurrentState'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersSamplingTest = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'SamplingTest') ", + statut="f", + QualityCriterion = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="AugmentedWeightedLeastSquares", into=['AugmentedWeightedLeastSquares', 'AWLS', 'AugmentedPonderatedLeastSquares', 'APLS', 'DA', 'WeightedLeastSquares', 'WLS', 'PonderatedLeastSquares', 'PLS', 'LeastSquares', 'LS', 'L2', 'AbsoluteValue', 'L1', 'MaximumError', 'ME'], fr="Critère de qualité utilisé"), + SampleAsExplicitHyperCube = SIMP(statut="f", typ="TXM", max="**", into=None, fr="Points de calcul définis par un hyper-cube dont on donne la liste des échantillonages de chaque variable comme une liste"), + SampleAsIndependantRandomVariables = SIMP(statut="f", typ="TXM", max="**", into=None, fr="Points de calcul définis par un hyper-cube dont les points sur chaque axe proviennent de l'échantillonage indépendant de la variable selon la spécification ['distribution',[parametres],nombre]"), + SampleAsMinMaxStepHyperCube = SIMP(statut="f", typ="TXM", max="**", into=None, fr="Points de calcul définis par un hyper-cube dont on donne la liste des échantillonages de chaque variable par un triplet [min,max,step]"), + SampleAsnUplet = SIMP(statut="f", typ="TXM", max="**", into=None, fr="Points de calcul définis par une liste de n-uplet"), + SetDebug = SIMP(statut="f", typ="I", min=1, max=1, defaut=0, fr="Activation du mode debug lors de l'exécution"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CostFunctionJ', 'CostFunctionJb', 'CostFunctionJo', 'CurrentState', 'InnovationAtCurrentState', 'SimulatedObservationAtCurrentState'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ParametersTangentTest = BLOC (condition = " (Parameters == 'Defaults') and (Algorithm == 'TangentTest') ", + statut="f", + AmplitudeOfInitialDirection = SIMP(statut="f", typ="R", min=1, max=1, defaut=1.0, fr="Amplitude de la direction initiale de la dérivée directionnelle autour du point nominal"), + AmplitudeOfTangentPerturbation = SIMP(statut="f", typ="R", val_min=1e-10, val_max=1.0, min=1, max=1, defaut=0.01, fr="Amplitude de la perturbation pour le calcul de la forme tangente"), + EpsilonMinimumExponent = SIMP(statut="f", typ="I", val_min=-20, val_max=0, min=1, max=1, defaut=-8, fr="Exposant minimal en puissance de 10 pour le multiplicateur d'incrément"), + InitialDirection = SIMP(statut="f", typ="TXM", fr="Direction initiale de la dérivée directionnelle autour du point nominal"), + ResiduFormula = SIMP(statut="f", typ="TXM", min=1, max=1, defaut="Taylor", into=['Taylor'], fr="Formule de résidu utilisée"), + SetSeed = SIMP(statut="f", typ="TXM", fr="Graine fixée pour le générateur aléatoire"), + StoreSupplementaryCalculations = SIMP(statut="f", typ="TXM", max="**", into=['CurrentState', 'Residu', 'SimulatedObservationAtCurrentState'], fr="Liste de calculs supplémentaires à stocker et/ou effectuer"), + ), + ) + +def F_variables(statut) : return FACT( + statut=statut, + regles = ( MEME_NOMBRE ('NAMES', 'SIZES')), + NAMES = SIMP(statut="o", typ="TXM", max="**", validators=NoRepeat()), + SIZES = SIMP(statut="o", typ="I", val_min=1, max="**") + ) +def ChDir(dirname): + os.chdir(os.path.abspath(dirname)) + return 1 +ChDir.info = u"This has to be a regular directory path." + +ASSIMILATION_STUDY = PROC(nom="ASSIMILATION_STUDY", + op=None, + repetable = "n", + StudyName = SIMP(statut="o", typ = "TXM", defaut="ADAO Calculation Case"), + StudyRepertory = SIMP(statut="f", typ = "Repertoire", validators=FunctionVal(ChDir), min=1, max=1), + Debug = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0), + AlgorithmParameters = F_AlgorithmParameters("o",("3DVAR", "4DVAR", "Blue", "DerivativeFreeOptimization", "EnsembleBlue", "ExtendedBlue", "ExtendedKalmanFilter", "KalmanFilter", "LinearLeastSquares", "NonLinearLeastSquares", "ParticleSwarmOptimization", "QuantileRegression", "UnscentedKalmanFilter", ), AlgorithmParametersInNS), + Background = F_Background("o", BackgroundInNS), + BackgroundError = F_BackgroundError("o", BackgroundErrorInNS), + Observation = F_Observation("o", ObservationInNS), + ObservationError = F_ObservationError("o", ObservationErrorInNS), + ObservationOperator = F_ObservationOperator("o"), + EvolutionModel = F_EvolutionModel("f"), + EvolutionError = F_EvolutionError("f", EvolutionErrorInNS), + ControlInput = F_ControlInput("f"), + UserDataInit = F_Init("f"), + UserPostAnalysis = F_UserPostAnalysis("o"), + InputVariables = F_variables("f"), + OutputVariables = F_variables("f"), + Observers = F_Observers("f") + ) + +CHECKING_STUDY = PROC(nom="CHECKING_STUDY", + op=None, + repetable = "n", + StudyName = SIMP(statut="o", typ = "TXM", defaut="ADAO Checking Case"), + StudyRepertory = SIMP(statut="f", typ = "Repertoire", validators=FunctionVal(ChDir), min=1, max=1), + Debug = SIMP(statut="f", typ = "I", into=(0, 1), defaut=0), + AlgorithmParameters = F_AlgorithmParameters("o", ("AdjointTest", "FunctionTest", "GradientTest", "LinearityTest", "ObserverTest", "SamplingTest", "TangentTest", ), AlgorithmParametersInNS), + CheckingPoint = F_CheckingPoint("o", CheckingPointInNS), + BackgroundError = F_BackgroundError("f", BackgroundErrorInNS), + Observation = F_Observation("f", ObservationInNS), + ObservationError = F_ObservationError("f", ObservationErrorInNS), + ObservationOperator = F_ObservationOperator("o"), + UserDataInit = F_Init("f"), + Observers = F_Observers("f") + ) diff --git a/Adao/configuration_Adao.py b/Adao/configuration_Adao.py index eacd427b..5e1c7245 100644 --- a/Adao/configuration_Adao.py +++ b/Adao/configuration_Adao.py @@ -20,7 +20,6 @@ # # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com # -# Author: André Ribes, andre.ribes@edf.fr, EDF R&D """ Ce module sert pour charger les paramètres de configuration d'EFICAS @@ -28,15 +27,12 @@ # Modules Python # print "passage dans la surcharge de configuration pour Adao" import os, sys, string, types, re -import traceback -from daUtils.qtversion import useQT5 -if useQT5: - from PyQt5.QtGui import * -else: - from PyQt4.QtGui import * + # Modules Eficas -from Editeur import utils + + +#from Editeur import Eficas_utils from InterfaceQT4 import configuration # Classe de base permettant de lire, afficher @@ -45,7 +41,6 @@ class CONFIG(configuration.CONFIG_BASE): def __init__(self,appli,repIni): - #self.labels_eficas = ['lang'] self.labels_eficas=['lang','rep_cata','catalogues','closeAutreCommande','closeFrameRechercheCommande','closeEntete','taille'] configuration.CONFIG_BASE.__init__(self,appli,repIni) @@ -62,7 +57,7 @@ class CONFIG(configuration.CONFIG_BASE): # Format des catalogues... # (code, version, catalogue, formatIn, formatOut) # Il faut les mettre dans un tuple - self.catalogues = (("ADAO", "V0", os.path.join(self.rep_ini, 'ADAO_Cata_V0.py'), "adao"),) + #self.catalogues = (("ADAO", "V0", os.path.join(self.rep_ini, 'ADAO_Cata_V0.py'), "adao"),) def make_config(appli,rep): diff --git a/Adao/prefs_Adao.py b/Adao/prefs_Adao.py index 490b46cd..ae4ded16 100644 --- a/Adao/prefs_Adao.py +++ b/Adao/prefs_Adao.py @@ -1,8 +1,8 @@ # -*- coding: utf-8 -*- import os,sys -# repIni sert à localiser le fichier editeur.ini -# Obligatoire +# repIni sert a localiser le fichier editeur.ini + repIni=os.path.dirname(os.path.abspath(__file__)) INSTALLDIR=os.path.join(repIni,'..') sys.path[:0]=[INSTALLDIR] @@ -12,18 +12,22 @@ sys.path[:0]=[INSTALLDIR] encoding='iso-8859-1' # Choix des catalogues -# format du Tuple (code,version,catalogue,formatOut, finit par defaut Ãventuellement) +# format du Tuple (code,version,catalogue,formatOut, finit par defaut eventuellement) catalogues = ( # ('Adao','V1',os.path.join(repIni,'ADAO_Cata_V1.py'),'python','python'), - ('Adao','V770',os.path.join(repIni,'ADAO_Cata_V0_V7_7_0.py'),'python','python'), +# ('Adao','V770',os.path.join(repIni,'ADAO_Cata_V0_V7_7_0.py'),'python','python'), + ('Adao','V83',os.path.join(repIni,'ADAO_Cata_V0_V8_3_0_DEV.py'),'dico','python'), # ('Adao','V751',os.path.join(repIni,'ADAO_Cata_V0_V7_5_1.py'),'python','python'), ) -# lang indique la langue utilisée pour les chaines d'aide : fr ou ang +# lang indique la langue utilisee pour les chaines d'aide : fr ou ang + lang='fr' closeAutreCommande = True closeFrameRechercheCommande = True -closeEntete = True - +#closeEntete = True +closeArbre = True +translatorFichier = os.path.join(repIni,'Adao') +nombreDeBoutonParLigne=1 diff --git a/Adao/qtEficas_Adao.py b/Adao/qtEficas_Adao.py index 8091a2c0..03d15b9e 100755 --- a/Adao/qtEficas_Adao.py +++ b/Adao/qtEficas_Adao.py @@ -19,7 +19,6 @@ # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com # """ - Ce module sert à lancer EFICAS configuré pour Syrthes """ # Modules Python @@ -28,6 +27,10 @@ import prefs name='prefs_'+prefs.code __import__(name) -import sys +#import sys +#reload(sys) +#sys.setdefaultencoding('latin1') + from InterfaceQT4 import eficas_go +print eficas_go eficas_go.lance_eficas(code=prefs.code) diff --git a/Editeur/Objecttreeitem.py b/Editeur/Objecttreeitem.py index 0d974573..58653335 100644 --- a/Editeur/Objecttreeitem.py +++ b/Editeur/Objecttreeitem.py @@ -299,7 +299,7 @@ class ObjectTreeItem(TreeItem,Delegate): index = self.get_index_child(name) return self.addobject(name,index) - def append_brother(self,name,pos='after'): + def appendBrother(self,name,pos='after'): """ Permet d'ajouter un frere a self par defaut on l'ajoute apres self @@ -310,7 +310,7 @@ class ObjectTreeItem(TreeItem,Delegate): elif pos == 'after': index = index +1 else: - print((tr("%d n'est pas un index valide pour append_brother", pos))) + print((tr("%d n'est pas un index valide pour appendBrother", pos))) return return self.parent.addobject(name,index) diff --git a/Editeur/session.py b/Editeur/session.py index 954f277d..1f7bb5a3 100644 --- a/Editeur/session.py +++ b/Editeur/session.py @@ -288,7 +288,7 @@ def parse(args): options.comm.append(file) options.studies.append({"comm":file}) #print options.studies - elif len(args)==1 and (re.search('.comm',file) or re.search('.map',file)): + elif len(args)==1 and (re.search('.comm',file) or re.search('.map',file) or re.search('.cas',file)): try : f=open(file,'w') f.close() diff --git a/InterfaceQT4/browser.py b/InterfaceQT4/browser.py index 712a813b..7e9427c6 100644 --- a/InterfaceQT4/browser.py +++ b/InterfaceQT4/browser.py @@ -189,7 +189,7 @@ class JDCTree( QTreeWidget,GereRegles ): def choisitPremier(self,name): self.editor.layoutJDCCHOIX.removeWidget(self.racine.fenetre) self.racine.fenetre.close() - new_node=self.racine.append_brother(name,'after') + new_node=self.racine.appendBrother(name,'after') # type de noeud COMMENT = "COMMENTAIRE" @@ -407,7 +407,7 @@ class JDCNode(QTreeWidgetItem,GereRegles): pos = 'after' else: pos = 'before' - return self.append_brother( COMMENT, pos ) + return self.appendBrother( COMMENT, pos ) def addParameters( self, after=True ): """ @@ -416,7 +416,7 @@ class JDCNode(QTreeWidgetItem,GereRegles): self.editor.init_modif() if after: pos = 'after' else: pos = 'before' - child=self.append_brother( PARAMETERS, pos ) + child=self.appendBrother( PARAMETERS, pos ) return child @@ -434,7 +434,7 @@ class JDCNode(QTreeWidgetItem,GereRegles): # Methodes de creation et destruction de noeuds # Certaines de ces methodes peuvent etre appelees depuis l'externe #------------------------------------------------------------------ - def append_brother(self,name,pos='after',plier=False): + def appendBrother(self,name,pos='after',plier=False): """ Permet d'ajouter un objet frere a l'objet associe au noeud self par defaut on l'ajoute immediatement apres @@ -455,7 +455,7 @@ class JDCNode(QTreeWidgetItem,GereRegles): if pos == 'before': index = index elif pos == 'after': index = index +1 else: - print(six.text_type(pos), tr(" n'est pas un index valide pour append_brother")) + print(six.text_type(pos), tr(" n'est pas un index valide pour appendBrother")) return 0 return self.treeParent.append_child(name,pos=index,plier=plier) @@ -767,7 +767,7 @@ class JDCNode(QTreeWidgetItem,GereRegles): child=None try : #if 1 : - child = self.append_brother(objet_a_copier,pos) + child = self.appendBrother(objet_a_copier,pos) except : pass return child diff --git a/InterfaceQT4/compomclist.py b/InterfaceQT4/compomclist.py index 8ae69573..cbfde1cb 100644 --- a/InterfaceQT4/compomclist.py +++ b/InterfaceQT4/compomclist.py @@ -61,7 +61,7 @@ class Node(browser.JDCNode,typeNode.PopUpMenuNodeMinimal): def doPaste(self,node_selected,pos): objet_a_copier = self.item.get_copie_objet() # before est un effet de bord heureux sur l index - child=self.append_brother(objet_a_copier,'before') + child=self.appendBrother(objet_a_copier,'before') if self.editor.fenetreCentraleAffichee : self.editor.fenetreCentraleAffichee.node.affichePanneau() self.update_node_label_in_black() self.parent().build_children() diff --git a/InterfaceQT4/editor.py b/InterfaceQT4/editor.py index 134549a5..2e247640 100755 --- a/InterfaceQT4/editor.py +++ b/InterfaceQT4/editor.py @@ -53,6 +53,7 @@ from . import browser from . import readercata DictExtensions= {"MAP" : ".map", "TELEMAC" : '.cas'} +debug = False @@ -282,7 +283,8 @@ class JDCEditor(Ui_baseWidget,QWidget): ### - #print ('in runPSEN_N1', dico) + print ('in runPSEN_N1', dico) + print (dico) from Run import run run(dico) #res,txt_exception=run(dico) @@ -306,7 +308,7 @@ class JDCEditor(Ui_baseWidget,QWidget): for k in dico['CONTINGENCY_PROCESSING']: #print (k) if k[0:19] == 'Component_List_For_' or k[0:21] =='Contingency_List_For_' : - newK=k.replace('___',' ') + newK=k.replace('__',' ') l="'"+str(newK)+"'" dico['CONTINGENCY_PROCESSING'][l]=dico['CONTINGENCY_PROCESSING'][k] del dico['CONTINGENCY_PROCESSING'][k] @@ -431,7 +433,9 @@ class JDCEditor(Ui_baseWidget,QWidget): # Le convertisseur existe on l'utilise #appli = self p=convert.plugins[self.appliEficas.format_fichier_in]() + p.readfile(fn) + if p.text=="" : self.nouveau=1 pareil,texteNew=self.verifieCHECKSUM(p.text) #if texteNew == "" @@ -441,7 +445,19 @@ class JDCEditor(Ui_baseWidget,QWidget): memeVersion,texteNew=self.verifieVersionCataDuJDC(p.text) if memeVersion == 0 : texteNew=self.traduitCatalogue(texteNew) p.text=texteNew + + #import cProfile, pstats, StringIO + #pr = cProfile.Profile() + #pr.enable() + text=p.convert('exec',self.appliEficas) + #pr.disable() + #s = StringIO.StringIO() + #sortby = 'cumulative' + #ps = pstats.Stats(pr, stream=s).sort_stats(sortby) + #ps.print_stats() + #print (s.getvalue()) + if not p.cr.estvide(): self.affiche_infos("Erreur a la conversion",Qt.red) else : @@ -910,7 +926,8 @@ class JDCEditor(Ui_baseWidget,QWidget): else: txt += eol txt=self.ajoutVersionCataDsJDC(txt) - checksum=self.get_checksum(txt) + if self.code != 'PSEN' and self.code != 'PSEN_N1' : checksum=self.get_checksum(txt) + else : checksum='' txt=txt+checksum if self.code=="TELEMAC" : return 1 try: @@ -1447,20 +1464,22 @@ class JDCEditor(Ui_baseWidget,QWidget): if monMC== None : monMC= ouChercher.addentite(MCFils) monMC.isvalid() - #-------------------------------------# + #-------------------------------------------------# def getValeur(self,nomEtape,MCFils,listeAvant=()): - #-------------------------------------# + #-------------------------------------------------# # dans le JDC ouChercher=None for e in self.jdc.etapes: if e.nom == nomEtape : ouChercher=e; break + if debug : print ('etape trouvee', ouChercher) if ouChercher==None : return None for mot in listeAvant : ouChercher=ouChercher.get_child(mot,restreint="oui") - #print (mot, ouChercher) + if debug : print (mot, ouChercher) if ouChercher==None : return None monMC=ouChercher.get_child(MCFils,restreint="oui") + if debug : print ('monMC', monMC) if monMC== None : return None return monMC.valeur @@ -1589,6 +1608,7 @@ class JDCEditor(Ui_baseWidget,QWidget): ouChercher=ouChercher.entites[k] MCADetruire=ouChercher.entites[nomDuMC] ouChercher.ordre_mc.remove(nomDuMC) + print ('remove de ', nomDuMC) del ouChercher.entites[nomDuMC] del self.dicoNouveauxMC[nomDuMC] @@ -1608,6 +1628,10 @@ class JDCEditor(Ui_baseWidget,QWidget): #Nouveau.ordre_mc=[] ouChercher.entites[nomDuMC]=Nouveau ouChercher.ordre_mc.append(nomDuMC) + #print ('ajout de ', nomDuMC) + #traceback.print_stack() + # ajout CIST sauvegarde + if nomDuMC in self.dicoNouveauxMC : del self.dicoNouveauxMC[nomDuMC] self.dicoNouveauxMC[nomDuMC]=('ajoutDefinitionMC',nomEtape,listeAvant,nomDuMC,typ,args) #print self.dicoNouveauxMC @@ -1717,8 +1741,12 @@ class JDCEditor(Ui_baseWidget,QWidget): indexFin=text.find(":FIN CHECKSUM") checkAvant=text[indexDeb:indexFin+13] textJDC=text[0:indexDeb]+text[indexFin+13:-1] - checksum=self.get_checksum(textJDC) - pareil=(checkAvant==checksum) + if self.code != 'PSEN' and self.code != 'PSEN_N1': + checksum=self.get_checksum(textJDC) + pareil=(checkAvant==checksum) + else : + pareil=1 + #if self.code=='PSEN' return pareil, textJDC #---------------------------# @@ -1759,7 +1787,7 @@ class JDCEditor(Ui_baseWidget,QWidget): def _newPSEN_N1(self): #---------------------------# texte="CASE_SELECTION();N_PROCESSING_OPTIONS();CONTINGENCY_OPTIONS();CONTINGENCY_SELECTION();\nCONTINGENCY_PROCESSING(); " - texte="CONTINGENCY_SELECTION();\nCONTINGENCY_PROCESSING(); " + #texte="CONTINGENCY_SELECTION();\nCONTINGENCY_PROCESSING(); " return texte #---------------------------# diff --git a/InterfaceQT4/eficas_go.py b/InterfaceQT4/eficas_go.py index f6178f4e..14ad60ff 100755 --- a/InterfaceQT4/eficas_go.py +++ b/InterfaceQT4/eficas_go.py @@ -134,11 +134,11 @@ def lance_eficas_param(code='Adao',fichier=None,version='V0',macro='ASSIMILATION options=session.parse(sys.argv) from .qtEficas import Appli - app = QApplication(sys.argv) - Eficas=Appli(code=code,ssCode=None) + #app = QApplication(sys.argv) + #Eficas=Appli(code=code,ssCode=None,salome=0) from .ssIhm import QWParentSSIhm - parent=QWParentSSIhm(code,Eficas,version) + Eficas=QWParentSSIhm(code,version) from . import readercata if not hasattr ( Eficas, 'readercata'): @@ -151,6 +151,12 @@ def lance_eficas_param(code='Adao',fichier=None,version='V0',macro='ASSIMILATION parameters=getJdcParameters(texte,macro) return parameters +def getEficasSsIhm(code='Adao',version='V0'): + from .qtEficasSsIhm import AppliSsIhm + app = QApplication(sys.argv) + Eficas=Appli(code=code,ssCode=None,salome=0) + return Eficas + def getJdcParameters(jdc,macro): """ This function converts the data from the specified macro of the diff --git a/InterfaceQT4/monChoixCommande.py b/InterfaceQT4/monChoixCommande.py index 0c28f887..ce9be4e6 100644 --- a/InterfaceQT4/monChoixCommande.py +++ b/InterfaceQT4/monChoixCommande.py @@ -135,7 +135,7 @@ class MonChoixCommande(Ui_ChoixCommandes,QWidget): if self.name != None : plier=self.editor.afficheCommandesPliees if nodeCourrant==self.node : nouveau=self.node.append_child(self.name,'first',plier) - else : nouveau=nodeCourrant.append_brother(self.name,plier=plier) + else : nouveau=nodeCourrant.appendBrother(self.name,plier=plier) else : nouveau = 0 if nouveau == 0 : return # on n a pas insere le noeud @@ -195,9 +195,14 @@ class MonChoixCommande(Ui_ChoixCommandes,QWidget): rbcmd=(QRadioButton(tr(cmd))) self.buttonGroup.addButton(rbcmd) self.commandesLayout.addWidget(rbcmd) - if self.editor.simpleClic : rbcmd.mouseReleaseEvent=self.insereNoeudApresClick - else : rbcmd.mouseDoubleClickEvent=self.insereNoeudApresClick - self.buttonGroup.buttonClicked.connect(self.rbClique) + #if self.editor.simpleClic : rbcmd.mouseReleaseEvent=self.insereNoeudApresClick + #else : rbcmd.mouseDoubleClickEvent=self.insereNoeudApresClick + #self.buttonGroup.buttonClicked.connect(self.rbClique) + if not(self.editor.simpleClic ): rbcmd.mouseDoubleClickEvent=self.insereNoeudApresClick + if self.editor.simpleClic : + self.buttonGroup.buttonClicked.connect(self.rbCliqueEtInsere) + else : + self.buttonGroup.buttonClicked.connect(self.rbClique) elif self.affiche_groupe==1 : listeGroupes,dictGroupes=self.jdc.get_groups() for grp in listeGroupes: @@ -218,9 +223,11 @@ class MonChoixCommande(Ui_ChoixCommandes,QWidget): rbcmd=(QRadioButton(tr(cmd))) self.buttonGroup.addButton(rbcmd) self.commandesLayout.addWidget(rbcmd) - if self.editor.simpleClic : rbcmd.mouseReleaseEvent=self.insereNoeudApresClick - else : rbcmd.mouseDoubleClickEvent=self.insereNoeudApresClick - self.buttonGroup.buttonClicked.connect(self.rbClique) + if not(self.editor.simpleClic ): rbcmd.mouseDoubleClickEvent=self.insereNoeudApresClick + if self.editor.simpleClic : + self.buttonGroup.buttonClicked.connect(self.rbCliqueEtInsere) + else : + self.buttonGroup.buttonClicked.connect(self.rbClique) label2=QLabel(self) label2.setText(" ") self.listeWidget.append(label2) @@ -238,11 +245,14 @@ class MonChoixCommande(Ui_ChoixCommandes,QWidget): rbcmd=(QRadioButton(tr(cmd))) self.buttonGroup.addButton(rbcmd) self.commandesLayout.addWidget(rbcmd) - if self.editor.simpleClic : rbcmd.mouseReleaseEvent=self.insereNoeudApresClick - else : rbcmd.mouseDoubleClickEvent=self.insereNoeudApresClick - self.buttonGroup.buttonClicked.connect(self.rbClique) + if not(self.editor.simpleClic ): rbcmd.mouseDoubleClickEvent=self.insereNoeudApresClick + if self.editor.simpleClic : + self.buttonGroup.buttonClicked.connect(self.rbCliqueEtInsere) + else : + self.buttonGroup.buttonClicked.connect(self.rbClique) + def ajoutePushButtons(self): if hasattr(self,'buttonGroup') : for b in self.buttonGroup.buttons(): @@ -264,9 +274,19 @@ class MonChoixCommande(Ui_ChoixCommandes,QWidget): self.verticalLayout.addLayout(self.maGrilleBouton) col=-1 ligne = 0 + if self.affiche_alpha==1 : liste=self.creeListeCommande(None) - for cmd in liste : + elif self.affiche_ordre: + liste=self.creeListeCommande(None) + listeFiltre=self.creeListeCommande(None) + liste=[] + if self.editor.Ordre_Des_Commandes == None : Ordre_Des_Commandes=listeFiltre + else : Ordre_Des_Commandes=self.editor.Ordre_Des_Commandes + for cmd in Ordre_Des_Commandes : + if cmd in listeFiltre : + liste.append(cmd) + for cmd in liste : col=col+1 if col == self.editor.nombreDeBoutonParLigne : col=0 @@ -302,7 +322,7 @@ class MonChoixCommande(Ui_ChoixCommandes,QWidget): def rbClique(self,id): self.name=self.dicoCmd[str(id.text())] definitionEtape=getattr(self.jdc.cata[0],self.name) - commentaire=getattr(definitionEtape,self.jdc.lang) + #commentaire=getattr(definitionEtape,self.jdc.lang) try : commentaire=getattr(definitionEtape,self.jdc.lang) except : diff --git a/InterfaceQT4/qtSaisie.py b/InterfaceQT4/qtSaisie.py index 86eabea5..174eb4c3 100644 --- a/InterfaceQT4/qtSaisie.py +++ b/InterfaceQT4/qtSaisie.py @@ -110,6 +110,11 @@ class SaisieValeur(object): except : valeur=valeurBrute + # pour traiter 11.0 - 30.0 pour le CIST + if (valeurTraitee and (type(valeurTraitee) in types.StringTypes) and (self.node.item.wait_TXM())) : + valeur=str(valeurTraitee) + + if type(valeur) in (list,tuple) : if self.node.item.wait_complex() : indice = 0 diff --git a/InterfaceQT4/ssIhm.py b/InterfaceQT4/ssIhm.py index 350cfb73..7ac43144 100644 --- a/InterfaceQT4/ssIhm.py +++ b/InterfaceQT4/ssIhm.py @@ -51,16 +51,9 @@ class appliEficasSSIhm(object): self.CONFIGURATION = configuration.make_config(self,prefsCode.repIni) class QWParentSSIhm(object): - def __init__(self,code,appliEficas,version_code,ssCode=None): + def __init__(self,code,version_code): self.ihm="QT" self.code=code self.version_code=version_code - self.ssCode=ssCode - if ssCode != None : - self.format_fichier= ssCode #par defaut - #prefsCode.NAME_SCHEME=ssCode - else : - self.format_fichier="python" #par defaut - self.appliEficas=appliEficas - self.appliEficas.ssCode=ssCode + self.format_fichier="python" #par defaut diff --git a/MAP/configuration_MAP.py b/MAP/configuration_MAP.py index 78613652..6c997677 100644 --- a/MAP/configuration_MAP.py +++ b/MAP/configuration_MAP.py @@ -38,7 +38,7 @@ class CONFIG(configuration.CONFIG_BASE): self.adresse="ftp://ftp.pleiade.edf.fr/projets/MAP/OnlineDoc/MAP2014.1/components" self.labels_user=['exec_acrobat','savedir','path_doc'] - self.labels_eficas=['exec_acrobat','savedir','path_doc','catalogues'] + self.labels_eficas=['exec_acrobat','savedir','path_doc','catalogues','closeAutreCommande','closeFrameRechercheCommande','taille'] #self.cataFile="catalogues_MAP.ini" configuration.CONFIG_BASE.__init__(self,appli,repIni) diff --git a/MAP/prefs_MAP.py b/MAP/prefs_MAP.py index 07014f30..f134bd1d 100644 --- a/MAP/prefs_MAP.py +++ b/MAP/prefs_MAP.py @@ -39,6 +39,7 @@ path_doc = os.path.join(repIni,'Doc') exec_acrobat = "/usr/bin/xpdf" savedir = os.environ['HOME'] affiche = "groupe" +taille = 1400 rep_cata=os.path.dirname(os.path.abspath(__file__)) @@ -53,4 +54,6 @@ catalogues=( ('MAP','Map',os.path.join(rep_cata,'mapcata.py'), 'essai'), ) +closeAutreCommande = True +closeFrameRechercheCommande = True diff --git a/MED/CataAZ.py b/MED/CataAZ.py new file mode 100755 index 00000000..b6e6494e --- /dev/null +++ b/MED/CataAZ.py @@ -0,0 +1,210 @@ +# coding: utf-8 +import types +from Accas import * + +class grno(GEOM): + """ + Classe servant à définir le nom d'un groupe de noeuds dans le fichier de commande + En clair : un chaine de longueur 24. + """ + def __convert__(cls,valeur): + """ + Fonction de verification de la longueur de la chaine + """ + if isinstance(valeur, (str,unicode)) and len(valeur.strip()) <= 24: + return valeur.strip() + raise ValueError(_(u'On attend une chaine de caractères (de longueur <= 24).')) + __convert__ = classmethod(__convert__) + +class grma(GEOM): + """ + Classe servant à définir le nom d'un groupe de mailles dans le fichier de commande + En clair : un chaine de longueur 24. + """ + def __convert__(cls,valeur): + """ + Fonction de verification de la longueur de la chaine + """ + if isinstance(valeur, (str,unicode)) and len(valeur.strip()) <= 24: + return valeur.strip() + raise ValueError(_(u'On attend une chaine de caractères (de longueur <= 24).')) + __convert__ = classmethod(__convert__) + + +class Tuple: + def __init__(self,ntuple): + self.ntuple=ntuple + + def __convert__(self,valeur): + if type(valeur) == types.StringType: return None + if len(valeur) != self.ntuple: return None + return valeur + + def info(self): + return "Tuple de %s elements" % self.ntuple + + __repr__=info + __str__=info + +class ObjetUtilisateur(ASSD): pass + + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + ) + + +EXAMPLE = PROC (nom = 'EXAMPLE', + op=None, + + TITRE = SIMP(statut ='o', typ = 'TXM', defaut = 'Mon Etude',), + TITRE2 = SIMP(statut ='f', typ = 'TXM', ), +) +CREEOBJET = OPER (nom="CREEOBJET", + op=None, + sd_prod=ObjetUtilisateur, + UIinfo={"groupes":("Group1",)}, + + TITLE = SIMP(statut ='o', typ = 'TXM', defaut = '',), + RB1 = SIMP(statut ='o', typ = 'I', into = [1,2,3],), + RB2 = SIMP(statut ='o', typ = 'I', into = [1,2,3,4,5,6,],), + CB = SIMP(statut ='o', typ = 'I', into = [1,2,3,4,5,6,7,8,9],), + MBool = SIMP(statut ='o', typ = bool,), + MFile = SIMP(statut ='o', typ = ('Fichier','All Files (*)')), + MDir = SIMP(statut ='o', typ = 'Repertoire'), + Reel1 = SIMP(statut ='o', typ = 'R'), + Compl = SIMP(statut ='o', typ = 'C'), + Tuple2 = SIMP(statut ='o', typ = Tuple(2), validators=VerifTypeTuple(('R','R'))), + Tuple3 = SIMP(statut ='o', typ = Tuple(3), validators=VerifTypeTuple(('R','R','R'))), + InSalome = SIMP(statut ='o', typ = SalomeEntry), + + LTITLE = SIMP(statut ='o', typ = 'TXM', max='**', defaut = '',), + LRB2 = SIMP(statut ='o', typ = 'I', max = '**', into = [1,2,3,4,5,6,],), + LCB = SIMP(statut ='o', typ = 'I', max = '**', homo="SansOrdreNiDoublon", into = [1,2,3,4,5,6,7,8,9],), + LReel1 = SIMP(statut ='o', typ = 'R', max = "**"), + LCompl = SIMP(statut ='o', typ = 'C', max = "**"), + LTuple2 = SIMP(statut ='o', typ = Tuple(2), validators=VerifTypeTuple(('R','R')), max = "**"), + LTuple3 = SIMP(statut ='o', typ = Tuple(3), validators=VerifTypeTuple(('R','R','R')), max = "**"), + LInSalome = SIMP(statut ='o', typ = SalomeEntry, max="**"), + + LREEL = SIMP(statut ='f', typ = 'R', max='**', defaut = '',), +) + +UTILISEOBJET = PROC (nom="UTILISEOBJET", + op=None, + UIinfo={"groupes":("Group1",)}, + Obj = SIMP (statut ='o', typ = ObjetUtilisateur,) +) + +ESSAI_FACT=OPER(nom="ESSAI_FACT", + sd_prod=ObjetUtilisateur, + op=None, + fr="Affectation de caractéristiques à des éléments de structure", + regles = (AU_MOINS_UN('Poutre','Barre'), + EXCLUS('Discret','Discret_2D'),), + Info = SIMP(statut='f',typ='I', defaut= 1 ,into=(1,2) ), + Verif = SIMP(statut='f',typ='TXM',validators=NoRepeat(),max='**',into=("Maille","Noeud") ), +# +# ============================================================================== + Poutre = FACT(statut= 'f',max= '**', + Section = SIMP(statut= 'o',typ= 'TXM' ,into= ("GENERALE","RECTANGLE","CERCLE") ), + + b_generale = BLOC(condition = " Section == 'GENERALE'", + regles = (UN_PARMI('Maille','GroupeMailles'),), + Maille = SIMP(statut= 'f',typ= 'TXM' ,validators= NoRepeat(),max= '**'), + GroupeMailles = SIMP(statut= 'f',typ= grma,validators= NoRepeat(),max= '**'), + + Vari = SIMP(statut= 'f',typ= 'TXM',into= ("CONSTANT","HOMOTHETIQUE"),defaut= "CONSTANT"), + + b_constant = BLOC(condition = "Vari == 'CONSTANT'", + regles = (PRESENT_ABSENT('Table','Cara'), + PRESENT_PRESENT('Table','Nom'), + PRESENT_PRESENT('Cara','Valeur'),), + Table = SIMP(statut= 'f',typ='TXM'), + Nom = SIMP(statut= 'f',typ= 'TXM'), + Cara = SIMP(statut= 'o',typ= 'TXM',min= 4 ,max= 5, + fr= "A,IY,IZ,JX sont des paramètres obligatoires", + validators= [NoRepeat(), Compulsory(['A','IY','IZ','JX'])], + into= ("A","IY","IZ","AY","AZ","EY","EZ","JX","RY","RZ","RT","JG","IYR2","IZR2","AI") ), + Valeur = SIMP(statut= 'f',typ= 'R',min= 4 ,max= 15), + ), + ), + b_rectangle = BLOC(condition = "Section == 'RECTANGLE'", + regles = (UN_PARMI('Maille','GroupeMailles'),), + Maille = SIMP(statut= 'f',typ= 'TXM' ,validators= NoRepeat(),max= '**'), + GroupeMailles = SIMP(statut= 'f',typ= grma,validators= NoRepeat(),max= '**'), + Vari = SIMP(statut= 'f',typ= 'TXM',into= ("CONSTANT","HOMOTHETIQUE","AFFINE"),defaut= "CONSTANT"), + b_constant = BLOC(condition = "Vari == 'CONSTANT'", + Cara = SIMP(statut= 'o',typ= 'TXM',min= 1 ,max= 4, + validators = [NoRepeat(), + OrVal( [AndVal( [Compulsory(['H']),Absent(['HY','HZ','EPY','EPZ'])] ), + AndVal( [Compulsory(['HY','HZ']),Together(['EPY','EPZ']),Absent(['H','EP'])] )] )], + into= ("H","EP", "HY","HZ","EPY","EPZ"),), + Valeur = SIMP(statut= 'o',typ= 'R',min= 1 ,max= 4), + ), + + Metrique = SIMP(statut= 'f',typ= 'TXM',defaut= "NON",into= ("OUI","NON") ), + Fcx = SIMP(statut= 'f',typ= 'R'), + Tuyau = SIMP(statut= 'f',typ= 'I',val_max= 10,defaut= 3), + ), + ), +# +# ============================================================================== + Barre = FACT(statut='f',max='**', + regles = (UN_PARMI('Maille','GroupeMailles'),), + Maille = SIMP(statut='f',typ='TXM' ,validators=NoRepeat(),max='**'), + GroupeMailles = SIMP(statut='f',typ=grma,validators=NoRepeat(),max='**'), + Section = SIMP(statut='o',typ='TXM',into=("GENERALE","RECTANGLE","CERCLE") ), + b_generale = BLOC(condition = "Section=='GENERALE'", + regles = (PRESENT_ABSENT('Table','Cara'), + PRESENT_PRESENT('Table','Nom'), + PRESENT_PRESENT('Cara','Valeur')), + Table = SIMP(statut='f',typ='TXM'), + Nom = SIMP(statut='f',typ='TXM',validators=LongStr(1,24) ), + Cara = SIMP(statut='f',typ='TXM',into=("A",) ), + Valeur = SIMP(statut='f',typ='R',min=1,max=1 ), + ), + b_rectangle = BLOC(condition = "Section=='RECTANGLE'", + Cara = SIMP(statut='o',typ='TXM', min=1, max=4, + validators = [NoRepeat(), + OrVal( [AndVal( [Compulsory(['H']),Absent(['HY','HZ','EPY','EPZ'])] ), + AndVal( [Compulsory(['HY','HZ']),Together(['EPY','EPZ']),Absent(['H','EP'])] )] )], + into=("H","EP","HZ","HY","EPY","EPZ"), ), + Valeur = SIMP(statut='o',typ='R',min=1,max=4 ), ), + b_cercle = BLOC(condition = "Section=='CERCLE'", + Cara = SIMP(statut='o',typ='TXM',validators=[NoRepeat(),Compulsory(['R'])],min=1,max=2,into=("R","EP") ), + Valeur = SIMP(statut='o',typ='R',min=1,max=2 ), ), + ), +# +# ============================================================================== + Discret = FACT(statut='f',max='**', + REPERE = SIMP(statut='f',typ='TXM',into=("LOCAL","GLOBAL") ), + AMOR_HYST = SIMP(statut='f',typ='R' ), + SYME = SIMP(statut='f',typ='TXM',defaut="OUI",into=("OUI","NON"),), + b_SYME_OUI = BLOC(condition="SYME=='OUI'", + fr="SYMETRIQUE: Affectation de matrices de rigidité, de masse ou d'amortissement à des mailles ou noeuds", + Cara = SIMP(statut='o',typ='TXM',validators=NoRepeat(),max=1,defaut="None", + into = ("K_T_D_N", "K_T_D_L", "K_TR_D_N", "K_TR_D_L", "K_T_N", "K_T_L", "K_TR_N", "K_TR_L", + "M_T_D_N", "M_T_D_L", "M_TR_D_N", "M_TR_D_L", "M_T_N", "M_T_L", "M_TR_N", "M_TR_L", + "A_T_D_N", "A_T_D_L", "A_TR_D_N", "A_TR_D_L", "A_T_N", "A_T_L", "A_TR_N", "A_TR_L",),), + # Affection des caractéristiques de RIGIDITE/AMORTISSEMENT/MASSE + b_AK_T_D_N = BLOC(condition = "((Cara=='K_T_D_N')or(Cara=='A_T_D_N'))", + fr = "Noeud: 3 valeurs (triangulaire supérieure par colonne)", + regles = (UN_PARMI('Maille','GroupeMailles','Noeud','GROUP_NO'),), + Noeud = SIMP(statut='f',typ='TXM' ,validators=NoRepeat(),max='**'), + GROUP_NO = SIMP(statut='f',typ=grno,validators=NoRepeat(),max='**'), + Maille = SIMP(statut='f',typ='TXM' ,validators=NoRepeat(),max='**'), + GroupeMailles = SIMP(statut='f',typ=grma,validators=NoRepeat(),homo='SansOrdreNiDoublon',max='**'), + Valeur = SIMP(statut='o',typ='R',min=3 ,max=3 ),), + ), + ), +# +# ============================================================================== + Discret_2D = FACT(statut='f',max='**', + REPERE = SIMP(statut='f',typ='TXM',into=("LOCAL","GLOBAL") ), + AMOR_HYST = SIMP(statut='f',typ='R' ), + SYME = SIMP(statut='f',typ='TXM',defaut="OUI",into=("OUI","NON"),), + ), +) + + diff --git a/MED/Elementary_Lists_52996_Cata.py b/MED/Elementary_Lists_52996_Cata.py new file mode 100644 index 00000000..f3cc11c8 --- /dev/null +++ b/MED/Elementary_Lists_52996_Cata.py @@ -0,0 +1,86 @@ +# coding: utf-8 + +from Accas import * + +#class myMesh(ASSD): pass +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(#AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('ALL_LISTS'), + #AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN') + ) +) + +class grma(): + def __convert__(cls,valeur): + if isinstance(valeur, (str,unicode)) and len(valeur.strip()) <= 24 : #and ("item" in (valeur.strip())) + return valeur.strip() + raise ValueError("Name length does not contain \"test\" and is longer than allowed, 24") + __convert__ = classmethod(__convert__) + +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +switch_facultatif=True #change 'o' to 'f' of some widgets in the loop +#empty_defauts=True + +def myBloc(num): + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + defauts0=["","",True,"'phenomena_"+myNum+"'",mySeveral(list_item_body,2)] #presence of default values + defauts_mask=[False,False,True,True,True] #switch off defaults of some types + defauts=list() + for id0 in range(len(defauts0)): + if defauts_mask[id0]: + item=", defaut="+str(defauts0[id0]) + else: + item="" + defauts.append(item) + #print defauts + + opt=['o','o','o','o','o'] #initial default obligation of items in FACT groups + #make different widgets optional, one by one: + myLen=len(opt) + if switch_facultatif: + make_f=(num)%myLen + opt[make_f]='f' + #print opt + #if empty_defauts: + # clean_defaut=num%myLen + + myString="BLOC(condition=\"MESH==\'mesh_"+myNum+"'\""+defauts[0]+", AFFE=FACT(statut='"+opt[1]+"'"+defauts[1]+", ALL=SIMP(statut='"+opt[2]+"', typ=bool,ang='ALL "+myNum+" help EN'"+defauts[2]+"),PHENOMENA=SIMP(statut='"+opt[3]+"',typ='TXM',into=mySeveral('phenomena_',"+str(num)+")"+defauts[3]+"), MODELISATION=SIMP(statut='"+opt[4]+"',typ='TXM', min=2,max='**',into=mySeveral('"+list_item_body+"',"+str(num*4)+")"+defauts[4]+", ang='Input "+myNum+" list EN', fr='Input "+myNum+" list FR'),),)" + print myString + return eval(myString) + +ALL_LISTS=OPER(nom="ALL_LISTS",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + ang="Model mesh definition EN", + reentrant='n', + #regles=(AU_MOINS_UN('LIST_O_CHECKTEXT','LIST_F_CHECKTEXT','LIST_O_ANY','LIST_F_ANY')), + + #LIST_O_NOREPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,validators=NoRepeat(),min=3, max='**'), + #LIST_F_NOREPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,validators=NoRepeat(),min=3, max='**'), + #LIST_F_REPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,min=3, max='**'), + #LIST_O_REPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,min=3, max='**'), + + #LIST_F_NOREPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',validators=NoRepeat(),min=3, max='**'), + #LIST_O_NOREPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3,validators=NoRepeat(), max='**'), + #LIST_O_REPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3, max='**'), + #LIST_F_REPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',min=3, max='**'), + + #LIST_O_NOREPEAT_CHECKTEXT_ADD=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), min=3, max='**'), + #LIST_F_REPEAT_ANYTEXT_ADD=SIMP(statut='f',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), min=3, max='**'), + + LIST_O_NOREPEAT_CHECKTEXT_ADD_NODEFAUT=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03","item04","text04",), min=3, max='**'), + #LIST_O_NOREPEAT_CHECKTEXT_ADD_DEFAUT=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), defaut=('item01','item02','item03'), min=3, max='**'), +) + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','ALL_LISTS','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','ALL_LISTS','FIN') diff --git a/MED/Elementary_Lists_53000_Cata.py b/MED/Elementary_Lists_53000_Cata.py new file mode 100644 index 00000000..0dbba473 --- /dev/null +++ b/MED/Elementary_Lists_53000_Cata.py @@ -0,0 +1,52 @@ +# coding: utf-8 +from Accas import * + +#class myMesh(ASSD): pass +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(#AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('ALL_LISTS'), + #AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN') + ) +) + + +ALL_LISTS=OPER(nom="ALL_LISTS",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + ang="Model mesh definition EN", + reentrant='n', + LIST_O_NOREPEAT_CHECKTEXT_ADD_DEFAUT=SIMP(statut='o',typ="TXM",validators=NoRepeat(), + into=("item01","text01","item02","text02","item03","text03","item04","text04","item05","text05",), + defaut=('item01','item02','item03'), + homo="SansOrdreNiDoublon", + min=3, max='**'), + + #regles=(AU_MOINS_UN('LIST_O_CHECKTEXT','LIST_F_CHECKTEXT','LIST_O_ANY','LIST_F_ANY')), + + #LIST_O_NOREPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,validators=NoRepeat(),min=3, max='**'), + #LIST_F_NOREPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,validators=NoRepeat(),min=3, max='**'), + #LIST_F_REPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,min=3, max='**'), + #LIST_O_REPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,min=3, max='**'), + + #LIST_F_NOREPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',validators=NoRepeat(),min=3, max='**'), + #LIST_O_NOREPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3,validators=NoRepeat(), max='**'), + #LIST_O_REPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3, max='**'), + #LIST_F_REPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',min=3, max='**'), + + #LIST_O_NOREPEAT_CHECKTEXT_ADD=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), min=3, max='**'), + #LIST_F_REPEAT_ANYTEXT_ADD=SIMP(statut='f',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), min=3, max='**'), + + #LIST_O_NOREPEAT_CHECKTEXT_ADD_NODEFAUT=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03","item04","text04",), min=3, max='**'), + + + #LIST_O_SANSORDRENODOUBLON_CHECKTEXT_DEFAUT=SIMP(statut='o',typ=grma,homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), defaut=('item01','item02','item03'), min=3, max='**'), +) + + + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','ALL_LISTS','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','ALL_LISTS','FIN') diff --git a/MED/Elementary_Lists_53013_Cata.py b/MED/Elementary_Lists_53013_Cata.py new file mode 100644 index 00000000..cf371ff2 --- /dev/null +++ b/MED/Elementary_Lists_53013_Cata.py @@ -0,0 +1,59 @@ +# coding: utf-8 +from Accas import * + +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(#AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('ALL_LISTS'), + #AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN') + ) +) + +class grma(): + def __convert__(cls,valeur): + if isinstance(valeur, (str,unicode)) and len(valeur.strip()) <= 12 and ("item" in (valeur.strip()).lower()): # + return valeur.strip() + raise ValueError("Name length does not contain \"test\" and is longer than allowed, 12") + __convert__ = classmethod(__convert__) + +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +ALL_LISTS=OPER(nom="ALL_LISTS",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + fr="All lists definition FR", + ang="All lists definition EN", + reentrant='n', + #regles=(AU_MOINS_UN('LIST_O_CHECKTEXT','LIST_F_CHECKTEXT','LIST_O_ANY','LIST_F_ANY')), + + L1_LIST_O_NOREPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,validators=NoRepeat(),min=3, max='**', ang='Obligatory, No Repetitions, checked text, EN'), + L2_LIST_F_NOREPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,validators=NoRepeat(),min=3, max='**', ang='Optional, No Repetitions, checked text, EN'), + L3_LIST_F_REPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,min=3, max='**',ang='Optional, Allowed Repetitions, checked text, EN'), + L4_LIST_O_REPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,min=3, max='**',ang='Obligatory, Allowed Repetitions, checked text, EN'), + + L5_LIST_F_NOREPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',validators=NoRepeat(),min=3, max='**',ang='Optional, No Repetitions, any text, EN'), + L6_LIST_O_NOREPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3,validators=NoRepeat(), max='**',ang='Obligatory, No Repetitions, any text, EN'), + L7_LIST_O_REPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3, max='**',ang='Obligatory, Allowed Repetitions, any text, EN'), + L8_LIST_F_REPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',min=3, max='**',ang='Optional, Allowed Repetitions, any text, EN'), + + L9_LIST_O_NOREPEAT_CHECKTEXT_ADD=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With spare list, Obligatory, No Repetitions, checked text, EN',), + L10_LIST_F_REPEAT_ANYTEXT_ADD=SIMP(statut='f',typ='TXM', into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With spare list, Optional, Allowed Repetitions, any text, EN'), + L11_LIST_O_REPEAT_CHECKTEXT_ADD_NODEFAUT=SIMP(statut='o',typ=grma, into=("item01","text01","item02","text02","item03","text03","item04","text04"),ang='With spare list, obligatory, No Repetitions, checked text, no default values, EN', min=3, max='**'), + L12_LIST_O_NOREPEAT_CHECKTEXT_ADD_DEFAUT=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03","item04","text04","item05","text05",), defaut=('item01','item02','item03'), min=3, max='**',ang='With spare list, Obligatory, No Repetitions, checked text, with default values EN'), + + L13_LIST_F_SANSORDRENODOUBLON_ANYTEXT_NODEFAUT=SIMP(statut='f',typ='TXM',homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With check boxes, Optional, any text, no defaults, EN'), + L14_LIST_O_SANSORDRENODOUBLON_CHECKTEXT_NODEFAUT=SIMP(statut='o',typ=grma,homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With check boxes, Obligatory, checked text, EN'), + L15_LIST_O_SANSORDRENODOUBLON_CHECKTEXT_DEFAUT=SIMP(statut='o',typ=grma,homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03","item02","text02","item01","text01",), defaut=('item01','item02','item03'), min=3, max='**', ang='With check boxes, Obligatory, checked text, with default values, EN'), +) + + + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','ALL_LISTS','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','ALL_LISTS','FIN') diff --git a/MED/Elementary_Lists_53036_Cata.py b/MED/Elementary_Lists_53036_Cata.py new file mode 100644 index 00000000..5cdc0faa --- /dev/null +++ b/MED/Elementary_Lists_53036_Cata.py @@ -0,0 +1,59 @@ +# coding: utf-8 +from Accas import * + +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(#AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('ALL_LISTS'), + #AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN') + ) +) + +class grma(): + def __convert__(cls,valeur): + if isinstance(valeur, (str,unicode)) and len(valeur.strip()) <= 12 and ("item" in (valeur.strip()).lower()): # + return valeur.strip() + raise ValueError("Name length does not contain \"item\" and is longer than allowed, 12") + __convert__ = classmethod(__convert__) + +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +ALL_LISTS=OPER(nom="ALL_LISTS",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + fr="All lists definition FR", + ang="All lists definition EN", + reentrant='n', + #regles=(AU_MOINS_UN('LIST_O_CHECKTEXT','LIST_F_CHECKTEXT','LIST_O_ANY','LIST_F_ANY')), + + L1_LIST_O_NOREPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,validators=NoRepeat(),min=3, max='**', ang='Obligatory, No Repetitions, checked text, EN'), + L2_LIST_F_NOREPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,validators=NoRepeat(),min=3, max='**', ang='Optional, No Repetitions, checked text, EN'), + L3_LIST_F_REPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,min=3, max='**',ang='Optional, Allowed Repetitions, checked text, EN'), + L4_LIST_O_REPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,min=3, max='**',ang='Obligatory, Allowed Repetitions, checked text, EN'), + + L5_LIST_F_NOREPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',validators=NoRepeat(),min=3, max='**',ang='Optional, No Repetitions, any text, EN'), + L6_LIST_O_NOREPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3,validators=NoRepeat(), max='**',ang='Obligatory, No Repetitions, any text, EN'), + L7_LIST_O_REPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3, max='**',ang='Obligatory, Allowed Repetitions, any text, EN'), + L8_LIST_F_REPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',min=3, max='**',ang='Optional, Allowed Repetitions, any text, EN'), + + L9_LIST_O_NOREPEAT_CHECKTEXT_ADD=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With spare list, Obligatory, No Repetitions, checked text, EN',), + L10_LIST_F_REPEAT_ANYTEXT_ADD=SIMP(statut='f',typ='TXM', into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With spare list, Optional, Allowed Repetitions, any text, EN'), + L11_LIST_O_REPEAT_CHECKTEXT_ADD_NODEFAUT=SIMP(statut='o',typ=grma, into=("item01","text01","item02","text02","item03","text03","item04","text04"),ang='With spare list, obligatory, No Repetitions, checked text, no default values, EN', min=3, max='**'), + L12_LIST_O_NOREPEAT_CHECKTEXT_ADD_DEFAUT=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03","item04","text04","item05","text05",), defaut=('item01','item02','item03'), min=3, max='**',ang='With spare list, Obligatory, No Repetitions, checked text, with default values EN'), + + L13_LIST_F_SANSORDRENODOUBLON_ANYTEXT_NODEFAUT=SIMP(statut='f',typ='TXM',homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With check boxes, Optional, any text, no defaults, EN'), + L14_LIST_O_SANSORDRENODOUBLON_CHECKTEXT_NODEFAUT=SIMP(statut='o',typ=grma,homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With check boxes, Obligatory, checked text, EN'), + L15_LIST_O_SANSORDRENODOUBLON_CHECKTEXT_NOREPEAT_DEFAUT=SIMP(statut='o',typ=grma,homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03","item03","text03","item02","text02","item01","text01",), defaut=('item01','item02','item03'), min=3, max='**', ang='With check boxes, Obligatory, checked text, with default values, EN'), #validators=NoRepeat(), +) + + + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','ALL_LISTS','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','ALL_LISTS','FIN') diff --git a/MED/Elementary_Lists_Cata.py b/MED/Elementary_Lists_Cata.py new file mode 100755 index 00000000..92d20b35 --- /dev/null +++ b/MED/Elementary_Lists_Cata.py @@ -0,0 +1,59 @@ +# coding: utf-8 +from Accas import * + +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(#AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('ALL_LISTS'), + #AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN') + ) +) + +class grma(): + def __convert__(cls,valeur): + if isinstance(valeur, (str,unicode)) and len(valeur.strip()) <= 12 and ("item" in (valeur.strip()).lower()): # + return valeur.strip() + raise ValueError("Name length does not contain \"test\" and is longer than allowed, 12") + __convert__ = classmethod(__convert__) + +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +ALL_LISTS=OPER(nom="ALL_LISTS",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + fr="All lists definition FR", + ang="All lists definition EN", + reentrant='n', + #regles=(AU_MOINS_UN('LIST_O_CHECKTEXT','LIST_F_CHECKTEXT','LIST_O_ANY','LIST_F_ANY')), + + L1_LIST_O_NOREPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,validators=NoRepeat(),min=3, max='**', ang='Obligatory, No Repetitions, checked text, EN'), + L2_LIST_F_NOREPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,validators=NoRepeat(),min=3, max='**', ang='Optional, No Repetitions, checked text, EN'), + L3_LIST_F_REPEAT_CHECKTEXT=SIMP(statut='f',typ=grma,min=3, max='**',ang='Optional, Allowed Repetitions, checked text, EN'), + L4_LIST_O_REPEAT_CHECKTEXT=SIMP(statut='o',typ=grma,min=3, max='**',ang='Obligatory, Allowed Repetitions, checked text, EN'), + + L5_LIST_F_NOREPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',validators=NoRepeat(),min=3, max='**',ang='Optional, No Repetitions, any text, EN'), + L6_LIST_O_NOREPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3,validators=NoRepeat(), max='**',ang='Obligatory, No Repetitions, any text, EN'), + L7_LIST_O_REPEAT_ANYTEXT=SIMP(statut='o',typ='TXM',min=3, max='**',ang='Obligatory, Allowed Repetitions, any text, EN'), + L8_LIST_F_REPEAT_ANYTEXT=SIMP(statut='f',typ='TXM',min=3, max='**',ang='Optional, Allowed Repetitions, any text, EN'), + + L9_LIST_O_NOREPEAT_CHECKTEXT_ADD=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With spare list, Obligatory, No Repetitions, checked text, EN',), + L10_LIST_F_REPEAT_ANYTEXT_ADD=SIMP(statut='f',typ='TXM', into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With spare list, Optional, Allowed Repetitions, any text, EN'), + L11_LIST_O_REPEAT_CHECKTEXT_ADD_NODEFAUT=SIMP(statut='o',typ=grma, into=("item01","text01","item02","text02","item03","text03","item04","text04"),ang='With spare list, obligatory, No Repetitions, checked text, no default values, EN', min=3, max='**'), + L12_LIST_O_NOREPEAT_CHECKTEXT_ADD_DEFAUT=SIMP(statut='o',typ=grma,validators=NoRepeat(), into=("item01","text01","item02","text02","item03","text03","item04","text04","item05","text05",), defaut=('item01','item02','item03'), min=3, max='**',ang='With spare list, Obligatory, No Repetitions, checked text, with default values EN'), + + L13_LIST_F_SANSORDRENODOUBLON_ANYTEXT_NODEFAUT=SIMP(statut='f',typ='TXM',homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With check boxes, Optional, any text, no defaults, EN'), + L14_LIST_O_SANSORDRENODOUBLON_CHECKTEXT_NODEFAUT=SIMP(statut='o',typ=grma,homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), min=3, max='**',ang='With check boxes, Obligatory, checked text, EN'), + L15_LIST_O_SANSORDRENODOUBLON_CHECKTEXT_DEFAUT=SIMP(statut='o',typ=grma,homo="SansOrdreNiDoublon", into=("item01","text01","item02","text02","item03","text03",), defaut=('item01','item02','item03'), min=3, max='**', ang='With check boxes, Obligatory, checked text, with default values, EN'), +) + + + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','ALL_LISTS','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','ALL_LISTS','FIN') diff --git a/MED/Global_Condition_Cata.py b/MED/Global_Condition_Cata.py new file mode 100755 index 00000000..02396340 --- /dev/null +++ b/MED/Global_Condition_Cata.py @@ -0,0 +1,53 @@ +# coding: utf-8 +from Accas import * +#class myModel(ASSD): pass + +JdC = JDC_CATA(code='GLOB_COND', + execmodul=None, + regles=(AU_PLUS_UN('TYPES',), + AU_PLUS_UN('INITS',), + AU_PLUS_UN('DATAS',), + #A_CLASSER('TYPES','INITS','DATAS') + ) +); + +TYPES=PROC(nom='TYPES',op=None,UIinfo={"groupes":("Global_Workflow",)}, #sd_prod=myModel, + MODE=SIMP( + typ='TXM', + statut='o', + position='global_jdc', + into=("MANUAL","AUTOMATIC","MIXED"), + defaut="AUTOMATIC", + ), +); + +liste_condition=('INITS', 'DATAS') + +INITS=PROC(nom='INITS',op=None,UIinfo={"groupes":("INI_param",)}, + ini_manual=BLOC(condition="MODE == 'MANUAL'", + Informer=SIMP(statut='o',typ='TXM', defaut="INITS MANUAL"), + ), + ini_auto=BLOC(condition="MODE == 'AUTOMATIC'", + Informer=SIMP(statut='o', typ='TXM', defaut="INITS AUTOMATIC",), + ), + ini_mixed=BLOC(condition="MODE == 'MIXED'", + Informer=SIMP(statut='o',typ='TXM', defaut="INITS MIXED",), + ), +); +DATAS=PROC(nom='DATAS',op=None,UIinfo={"groupes":("DATAS",)}, + data_manual=BLOC(condition="MODE == 'MANUAL'", + Informer=SIMP(statut='o',typ='TXM', defaut="DATAS MANUAL", + ), + ), + data_auto=BLOC(condition="MODE == 'AUTOMATIC'", + Informer=SIMP(statut='o', typ='TXM', defaut="DATAS AUTOMATIC", + ), + ), + data_mixed=BLOC(condition="MODE == 'MIXED'", + Informer=SIMP(statut='o',typ='TXM', defaut="DATAS MIXED", + ), + ), +); + +Classement_Commandes_Ds_Arbre=('TYPES','INITS','DATAS') +Ordre_Des_Commandes = ('TYPES','INITS','DATAS') diff --git a/MED/Many_Concepts_52983_Cata.py b/MED/Many_Concepts_52983_Cata.py new file mode 100644 index 00000000..70f099ac --- /dev/null +++ b/MED/Many_Concepts_52983_Cata.py @@ -0,0 +1,39 @@ +# coding: utf-8 + +from Accas import * + +#class myMesh(ASSD): pass +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(UN_PARMI('DEBUT', 'POURSUITE'), + AU_MOINS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN'))) + +DEBUT=PROC(nom="DEBUT", op=68, repetable='n', UIinfo={"groupes":("Group1",)}, ang="Debut Eng help", + PAR_LOT=SIMP(ang="Debut Par Lot help En",statut='o',typ=bool, defaut=True), +) +AFFE_MODELE=OPER(nom="AFFE_MODELE",op=None,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + ang="Model mesh definition EN", + MESH=SIMP(statut='o',typ='TXM',into=("mesh_01","mesh_02","mesh_03","mesh_04",) , defaut="mesh_01"), + #reentrant='n', + #regles=(AU_MOINS_UN('AFFE','AFFE_SOUS_STRUC'),UN_PARMI('MAILLAGE','GRILLE')), + + + block_mesh_01=BLOC(condition="MESH=='mesh_01'", + AFFE=FACT(statut='o', + ALL=SIMP(statut='o', typ=bool,ang='ALL 01 help EN', defaut=True), + PHENOMENA=SIMP(statut='o',typ='TXM',into=('phenomena_01','phenomena_02',), defaut='phenomena_01'), + #MODELISATION=SIMP(statut='o',typ='TXM', min=2,max='**', into=("mesh_01","mesh_02","mesh_03","mesh_04",) ,ang='Input 01 list EN', fr='Input 01 list FR'), + MODELISATION=SIMP(statut='o',typ='TXM', min=2,max='**', into=('Item_01_01','Item_01_02',) ,ang='Input 01 list EN', fr='Input 01 list FR'), + ), + ), +) +FIN=PROC(nom="FIN",op=9999,repetable='n',ang="Finish help EN",UIinfo={"groupes":("Group1",)}, + FORMAT_HDF =SIMP(ang="Save HDF EN",statut='f',typ='TXM',defaut="NON",into=("OUI","NON",) ), +) + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH','AFFE_MODELE','FIN') +Ordre_Des_Commandes = ('DEBUT','MESH','AFFE_MODELE','FIN') diff --git a/MED/Many_Concepts_52988_Cata.py b/MED/Many_Concepts_52988_Cata.py new file mode 100644 index 00000000..52d4f10f --- /dev/null +++ b/MED/Many_Concepts_52988_Cata.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +from Accas import * + +class myMesh(ASSD): pass +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('AFFE_MODELE'), + AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN'))) + +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +switch_facultatif=True #change 'o' to 'f' of some widgets in the loop +empty_defauts=True + +def myBloc(num): + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + defauts0=["","",True,"'phenomena_"+myNum+"'",mySeveral(list_item_body,2)] #presence of default values + defauts_mask=[False,False,True,True,True] #switch off defaults of some types + defauts=list() + for id0 in range(len(defauts0)): + if defauts_mask[id0]: + item=", defaut="+str(defauts0[id0]) + else: + item="" + defauts.append(item) + #print defauts + + opt=['o','o','o','o','o'] #initial default obligation of items in FACT groups + #make some widgets optional: + myLen=len(opt) + if switch_facultatif: + make_f=(num)%myLen + opt[make_f]='f' + #print opt + if empty_defauts: + clean_defaut=num%myLen + + myString="BLOC(condition=\"MESH==\'mesh_"+myNum+"'\""+defauts[0]+", AFFE=FACT(statut='"+opt[1]+"'"+defauts[1]+", ALL=SIMP(statut='"+opt[2]+"', typ=bool,ang='ALL "+myNum+" help EN'"+defauts[2]+"),PHENOMENA=SIMP(statut='"+opt[3]+"',typ='TXM',into=mySeveral('phenomena_',"+str(num)+")"+defauts[3]+"), MODELISATION=SIMP(statut='"+opt[4]+"',typ='TXM', min=2,max='**',into=mySeveral('"+list_item_body+"',"+str(num*4)+")"+defauts[4]+", ang='Input "+myNum+" list EN', fr='Input "+myNum+" list FR'),),)" + print myString + return eval(myString) + +DEBUT=PROC(nom="DEBUT", op=10, repetable='n', UIinfo={"groupes":("Group1",)}, ang="Debut Eng help", + PAR_LOT=SIMP(ang="Debut Par Lot help En",statut='o',typ=bool, defaut=True), +); + +AFFE_MODELE=OPER(nom="AFFE_MODELE",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + ang="Model mesh definition EN", + reentrant='n', + regles=(AU_MOINS_UN('APPROVED')), + MESH=SIMP(statut='o',typ='TXM',into=mySeveral("mesh_",4) ,defaut="mesh_01"), + APPROVED=SIMP(statut="o", typ=bool), + block_mesh_01=myBloc(1), + block_mesh_02=myBloc(2), + block_mesh_03=myBloc(3), + block_mesh_04=myBloc(4), +) + + +FIN=PROC(nom="FIN",op=9999,repetable='n',ang="Finish help EN",UIinfo={"groupes":("Group1",)}, + FORMAT_HDF =SIMP(ang="Save HDF EN",statut='f',typ='TXM',defaut="NON",into=("OUI","NON",) ), +); + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','AFFE_MODELE','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','AFFE_MODELE','FIN') diff --git a/MED/Many_Concepts_52989_Cata.py b/MED/Many_Concepts_52989_Cata.py new file mode 100644 index 00000000..930d9e89 --- /dev/null +++ b/MED/Many_Concepts_52989_Cata.py @@ -0,0 +1,77 @@ +# coding: utf-8 + +from Accas import * + +#class myMesh(ASSD): pass +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('AFFE_MODELE'), + AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN'))) + +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +switch_facultatif=True #change 'o' to 'f' of some widgets in the loop +#empty_defauts=True + +def myBloc(num): + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + defauts0=["","",True,"'phenomena_"+myNum+"'",mySeveral(list_item_body,2)] #presence of default values + defauts_mask=[False,False,True,True,True] #switch off defaults of some types + defauts=list() + for id0 in range(len(defauts0)): + if defauts_mask[id0]: + item=", defaut="+str(defauts0[id0]) + else: + item="" + defauts.append(item) + #print defauts + + opt=['o','o','o','o','o'] #initial default obligation of items in FACT groups + #make different widgets optional, one by one: + myLen=len(opt) + if switch_facultatif: + make_f=(num)%myLen + opt[make_f]='f' + #print opt + #if empty_defauts: + # clean_defaut=num%myLen + + myString="BLOC(condition=\"MESH==\'mesh_"+myNum+"'\""+defauts[0]+", AFFE=FACT(statut='"+opt[1]+"'"+defauts[1]+", ALL=SIMP(statut='"+opt[2]+"', typ=bool,ang='ALL "+myNum+" help EN'"+defauts[2]+"),PHENOMENA=SIMP(statut='"+opt[3]+"',typ='TXM',into=mySeveral('phenomena_',"+str(num)+")"+defauts[3]+"), MODELISATION=SIMP(statut='"+opt[4]+"',typ='TXM', min=2,max='**',into=mySeveral('"+list_item_body+"',"+str(num*4)+")"+defauts[4]+", ang='Input "+myNum+" list EN', fr='Input "+myNum+" list FR'),),)" + print myString + return eval(myString) + +DEBUT=PROC(nom="DEBUT", op=10, repetable='n', UIinfo={"groupes":("Group1",)}, ang="Debut Eng help", + PAR_LOT=SIMP(ang="Debut Par Lot help En",statut='o',typ=bool, defaut=True), +); + +AFFE_MODELE=OPER(nom="AFFE_MODELE",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + ang="Model mesh definition EN", + reentrant='n', + regles=(AU_MOINS_UN('APPROVED')), + MESH=SIMP(statut='o',typ='TXM',into=mySeveral("mesh_",4) ,defaut="mesh_01"), + APPROVED=SIMP(statut="f", typ=bool), # presence of this item will validate the whole group + PAR_LOT=SIMP(ang="Debut Par Lot help En",statut='o',typ='I', defaut=True), + block_mesh_01=myBloc(1), + block_mesh_02=myBloc(2), + block_mesh_03=myBloc(3), + block_mesh_04=myBloc(4), +) + + +FIN=PROC(nom="FIN",op=9999,repetable='n',ang="Finish help EN",UIinfo={"groupes":("Group1",)}, + FORMAT_HDF =SIMP(ang="Save HDF EN",statut='f',typ='TXM',defaut="NON",into=("OUI","NON",) ), +); + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','AFFE_MODELE','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','AFFE_MODELE','FIN') diff --git a/MED/Many_Concepts_52992_Cata.py b/MED/Many_Concepts_52992_Cata.py new file mode 100644 index 00000000..13145b96 --- /dev/null +++ b/MED/Many_Concepts_52992_Cata.py @@ -0,0 +1,76 @@ +# coding: utf-8 + +from Accas import * + +#class myMesh(ASSD): pass +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(AU_PLUS_UN('DEBUT', 'POURSUITE'), + AU_PLUS_UN('AFFE_MODELE'), + AU_PLUS_UN('FIN'), + A_CLASSER(('DEBUT', 'POURSUITE'), 'FIN'))) + +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +switch_facultatif=True #change 'o' to 'f' of some widgets in the loop +#empty_defauts=True + +def myBloc(num): + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + defauts0=["","",True,"'phenomena_"+myNum+"'",mySeveral(list_item_body,2)] #presence of default values + defauts_mask=[False,False,True,True,False] #switch off defaults of some types + defauts=list() + for id0 in range(len(defauts0)): + if defauts_mask[id0]: + item=", defaut="+str(defauts0[id0]) + else: + item="" + defauts.append(item) + #print defauts + + opt=['o','o','o','o','o'] #initial default obligation of items in FACT groups + #make different widgets optional, one by one: + myLen=len(opt) + if switch_facultatif: + make_f=(num)%myLen + opt[make_f]='f' + #print opt + #if empty_defauts: + # clean_defaut=num%myLen + + myString="BLOC(condition=\"MESH==\'mesh_"+myNum+"'\""+defauts[0]+", AFFE=FACT(statut='"+opt[1]+"'"+defauts[1]+", ALL=SIMP(statut='"+opt[2]+"', typ=bool,ang='ALL "+myNum+" help EN'"+defauts[2]+"),PHENOMENA=SIMP(statut='"+opt[3]+"',typ='TXM',into=mySeveral('phenomena_',"+str(num)+")"+defauts[3]+"), MODELISATION=SIMP(statut='"+opt[4]+"',typ='TXM', min=4,max='**',into=mySeveral('"+list_item_body+"',"+str(num*4)+")"+defauts[4]+", ang='Input "+myNum+" list EN', fr='Input "+myNum+" list FR'),),)" + print myString + return eval(myString) + +DEBUT=PROC(nom="DEBUT", op=10, repetable='n', UIinfo={"groupes":("Group1",)}, ang="Debut Eng help", + PAR_LOT=SIMP(ang="Debut Par Lot help En",statut='o',typ=bool, defaut=True), +); + +AFFE_MODELE=OPER(nom="AFFE_MODELE",op=18,sd_prod=myModel, + UIinfo={"groupes":("Group1",)}, + ang="Model mesh definition EN", + reentrant='n', + regles=(AU_MOINS_UN('APPROVED')), + MESH=SIMP(statut='o',typ='TXM',into=mySeveral("mesh_",4) ,defaut="mesh_01"), + APPROVED=SIMP(statut="f", typ=bool), # presence of this item will validate the whole group + block_mesh_01=myBloc(1), + block_mesh_02=myBloc(2), + block_mesh_03=myBloc(3), + block_mesh_04=myBloc(4), +) + + +FIN=PROC(nom="FIN",op=9999,repetable='n',ang="Finish help EN",UIinfo={"groupes":("Group1",)}, + FORMAT_HDF =SIMP(ang="Save HDF EN",statut='f',typ='TXM',defaut="NON",into=("OUI","NON",) ), +); + +Classement_Commandes_Ds_Arbre=('DEBUT','MESH_TYPES','AFFE_MODELE','FIN') + +Ordre_Des_Commandes = ('DEBUT','MESH_TYPES','AFFE_MODELE','FIN') diff --git a/MED/Matrix_Cata.py b/MED/Matrix_Cata.py new file mode 100644 index 00000000..268a77bf --- /dev/null +++ b/MED/Matrix_Cata.py @@ -0,0 +1,87 @@ +# coding: utf-8 +from Accas import * + +class loi ( ASSD ) : pass +class variable ( ASSD ) : pass + +class Matrice: + def __init__(self,nbLigs=None,nbCols=None,methodeCalculTaille=None,formatSortie="ligne",valSup=None,valMin=None,structure=None): + self.nbLigs=nbLigs + self.nbCols=nbCols + self.methodeCalculTaille=methodeCalculTaille + self.formatSortie=formatSortie + self.valSup=valSup + self.valMin=valMin + self.structure=structure + + def __convert__(self,valeur): + # Attention ne verifie pas grand chose + if type(valeur) != types.ListType : + return None + return valeur + + def info(self): + return "Matrice %s x %s" % (self.nbLigs, self.nbCols) + + __repr__=info + __str__=info + + + +class myModel(ASSD): pass + +JdC = JDC_CATA(code='PATTERNS', + execmodul=None, + regles=(AU_MOINS_UN ( 'CORRELATION' ), + ) +) + +DETERMINISTICVARIABLE = OPER ( nom = "DETERMINISTICVARIABLE", + sd_prod = variable, + op = None, + fr = "Variable deterministe", + ang = "Deterministic variable", + + N = SIMP ( statut = 'o', typ = "TXM", fr = "Nom", ang = "Name", defaut = "Var1" ), + T = SIMP ( statut = 'o', defaut = "in", into = ( "in" , "out", ), typ = "TXM", fr = "Type", ang = "Type" ), + R = SIMP ( statut = 'o', defaut = 0, typ = "I", fr = "Rang", ang = "Rank" ), +) + +DISTRIBUTION = OPER ( nom = "DISTRIBUTION", + sd_prod = loi, + op = 68, + fr = "Definitions des lois marginales utilisees par les variables d'entree", + + R = SIMP ( statut = "o", typ = "R", max = 1, val_min = 0., fr = "Parametre R de la loi | R > 0", ang = "R parameter | R > 0", defaut = 0.5 ), + # T > R + T = SIMP ( statut = "o", typ = "R", max = 1, val_min = 0., fr = "Parametre T de la loi | T > R", ang = "T parameter | T > R", defaut = 0.7 ), + A = SIMP ( statut = "o", typ = "R", max = 1, fr = "Borne inferieure du support de la loi", ang = "Support lower bound", defaut = 0.1 ), + # B > A + B = SIMP ( statut = "o", typ = "R", max = 1, fr = "Borne superieure du support de la loi", ang = "Support upper bound", defaut = 0.3 ), +) + +VARIABLE = PROC ( nom = "VARIABLE", + op = None, + docu = "", + fr = "Variable probabiliste", + ang = "Probabilistic variable", + + ModelVariable = SIMP ( statut = "o", typ = ( variable, ), fr = "Variable d'entrée du modèle", ang = "Input variable of the model" ), + Distribution = SIMP ( statut = "o", typ = ( loi, ), fr = "Modélisation probabiliste", ang = "Probabilistic modelisation" ), +) + +CORRELATION = PROC ( nom = 'CORRELATION', + op = None, + docu = "", + fr = "Correlation entre variables", + ang = "Variable correlation", + + CorrelationMatrix = SIMP ( statut = "o", typ = Matrice(nbLigs=None, + nbCols=None, + methodeCalculTaille='NbDeVariables', + valSup=1, + valMin=-1, + structure="symetrique"), + fr = "Matrice de correlation entre les variables d'entree", + ang = "Correlation matrix for input variables" ), +) diff --git a/MED/Nested_Cond_52945_Cata.py b/MED/Nested_Cond_52945_Cata.py new file mode 100644 index 00000000..9d3b119d --- /dev/null +++ b/MED/Nested_Cond_52945_Cata.py @@ -0,0 +1,61 @@ +# coding: utf-8 + +from Accas import * + +class loi(): pass + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +use_and=False #switch off second condition about MAX_ROWS while it does not work for blocks greater than 2 +def cond2(myMax=False): + if use_and: + if myMax: + out= " and MAX_ROWS>="+str(myMax) + else: + out="" + else: + out="" + print out + return out + +PROC_01 = PROC(nom = "PROC_01",op = None, ang="Help for PROC_01 EN", + MAX_ROWS=SIMP(statut='o',typ='I',val_min=1,val_max=8, defaut=8), + PROCGROUP1=SIMP(statut='o',typ='TXM',into=("1A","2A","add new row",)), + wideblock1=BLOC(condition='PROCGROUP1=="add new row"'+cond2(1), + PROCGROUP2=SIMP(statut='o',typ='TXM',into=("1A","add new row","3A",)), + wideblock2=BLOC(condition='PROCGROUP2=="add new row"'+cond2(2), + PROCGROUP3=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + PROCGROUP689=SIMP(statut='o',typ='TXM',), + wideblock3=BLOC(condition='PROCGROUP3=="add new row"'+cond2(3), + PROCGROUP4=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + wideblock4=BLOC(condition='PROCGROUP4=="add new row"'+cond2(4), + PROCGROUP5=SIMP(statut='o',typ='TXM',into=("add new row","2","3",)), + wideblock5=BLOC(condition='PROCGROUP5=="add new row"'+cond2(5), + PROCGROUP6=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock6=BLOC(condition='PROCGROUP6=="add new row"'+cond2(6), + PROCGROUP7=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + wideblock7=BLOC(condition='PROCGROUP7=="add new row"'+cond2(7), + PROCGROUP8=SIMP(statut='o',typ='TXM',into=("add new row","2","3",)), + wideblock8=BLOC(condition='PROCGROUP8=="add new row"'+cond2(8), + ) + ) + ) + ) + ) + ) + ) + ) +) + +#LEV1 = OPER( nom = "LEV1", +# sd_prod=loi, +# op=68, +# fr='LEV1 FR', +# Boolean01=SIMP( statut = 'o',typ = bool, defaut=True, fr = 'Bool mandatory FR', ang = 'Bool mandatory EN'), +# SelectedItem=SIMP(statut = 'o',typ = 'TXM', into=["01_01","01_02","01_03","01_04"], fr="FR"), +#) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Nested_Cond_52946_Cata.py b/MED/Nested_Cond_52946_Cata.py new file mode 100644 index 00000000..fef5edf0 --- /dev/null +++ b/MED/Nested_Cond_52946_Cata.py @@ -0,0 +1,62 @@ +# coding: utf-8 + +from Accas import * + +class loi(): pass + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +use_and=True #switch off second condition about MAX_ROWS while it does not work for blocks greater than 2 +def cond2(myMax=False): + if use_and: + if myMax: + out= " and MAX_ROWS>="+str(myMax) + else: + out="" + else: + out="" + print out + return out + +PROC_01 = PROC(nom = "PROC_01",op = None, ang="Help for PROC_01 EN", + MAX_ROWS=SIMP(statut='o',typ='I',val_min=1,val_max=8, defaut=8), + PROCGROUP1=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock1=BLOC(condition='PROCGROUP1=="add new row"'+cond2(1), + PROCGROUP2=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + #wideblock2=BLOC(condition='PROCGROUP2=="add new row"', + wideblock2=BLOC(condition='MAX_ROWS == 8', + #wideblock2=BLOC(condition='PROCGROUP2=="add new row" and (MAX_ROWS > 2)', + PROCGROUP3=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock3=BLOC(condition='PROCGROUP3=="add new row"'+cond2(3), + PROCGROUP4=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + wideblock4=BLOC(condition='PROCGROUP4=="add new row"'+cond2(4), + PROCGROUP5=SIMP(statut='o',typ='TXM',into=("add new row","2","3",)), + wideblock5=BLOC(condition='PROCGROUP5=="add new row"'+cond2(5), + PROCGROUP6=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock6=BLOC(condition='PROCGROUP6=="add new row"'+cond2(6), + PROCGROUP7=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + wideblock7=BLOC(condition='PROCGROUP7=="add new row"'+cond2(7), + PROCGROUP8=SIMP(statut='o',typ='TXM',into=("add new row","2","3",)), + wideblock8=BLOC(condition='PROCGROUP8=="add new row"'+cond2(8), + ) + ) + ) + ) + ) + ) + ) + ) +) + +#LEV1 = OPER( nom = "LEV1", +# sd_prod=loi, +# op=68, +# fr='LEV1 FR', +# Boolean01=SIMP( statut = 'o',typ = bool, defaut=True, fr = 'Bool mandatory FR', ang = 'Bool mandatory EN'), +# SelectedItem=SIMP(statut = 'o',typ = 'TXM', into=["01_01","01_02","01_03","01_04"], fr="FR"), +#) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Nested_Cond_52947_Cata.py b/MED/Nested_Cond_52947_Cata.py new file mode 100644 index 00000000..bf3be39e --- /dev/null +++ b/MED/Nested_Cond_52947_Cata.py @@ -0,0 +1,17 @@ +# coding: utf-8 + +from Accas import * + +class loi(): pass + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) + +PROC_01 = PROC(nom = "PROC_01",op = None, ang="Help for PROC_01 EN", + PROCGROUP1=SIMP(statut='o',typ='TXM',into=("a1","a2","a3",)), +) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Nested_Cond_52948_Cata.py b/MED/Nested_Cond_52948_Cata.py new file mode 100644 index 00000000..81f216f8 --- /dev/null +++ b/MED/Nested_Cond_52948_Cata.py @@ -0,0 +1,21 @@ +# coding: utf-8 + +from Accas import * + +class loi(ASSD): pass + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) + +PER_01 = OPER( nom = "PER_01", + sd_prod=loi, + op=68, + fr='LEV1 FR', + Boolean01=SIMP( statut = 'o',typ = bool, defaut=True, fr = 'Bool mandatory FR', ang = 'Bool mandatory EN'), + SelectedItem=SIMP(statut = 'o',typ = 'TXM', into=["01_01","01_02","01_03","01_04"], fr="FR"), +) + +#Classement_Commandes_Ds_Arbre=('OPER_01',) + +#Ordre_Des_Commandes = ('OPER_01',) diff --git a/MED/Nested_Cond_52949_Cata.py b/MED/Nested_Cond_52949_Cata.py new file mode 100644 index 00000000..d09011a3 --- /dev/null +++ b/MED/Nested_Cond_52949_Cata.py @@ -0,0 +1,19 @@ +# coding: utf-8 + +from Accas import * + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) + +PROC_01 = PROC(nom = "PROC_01",op = None, ang="Help for PROC_01 EN", + MAX_ROWS=SIMP(statut='o',typ='I',val_min=1,val_max=8, defaut=8), + PROCGROUP1=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock1=BLOC(condition='PROCGROUP1 in "add new row"', + PROCGROUP2=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + ) +) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Nested_Cond_52952_Cata.py b/MED/Nested_Cond_52952_Cata.py new file mode 100644 index 00000000..47a8d7c5 --- /dev/null +++ b/MED/Nested_Cond_52952_Cata.py @@ -0,0 +1,60 @@ +# coding: utf-8 + +from Accas import * + +class loi(): pass + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +use_and=False #switch off second condition about MAX_ROWS while it does not work for blocks greater than 2 +def cond2(myMax=False): + if use_and: + if myMax: + out= " and MAX_ROWS>="+str(myMax) + else: + out="" + else: + out="" + #print out + return out + +PROC_01 = PROC(nom = "PROC_01",op = None, ang="Help for PROC_01 EN", + MAX_ROWS=SIMP(statut='o',typ='I',val_min=1,val_max=8, defaut=8), + PROCGROUP1=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock1=BLOC(condition='PROCGROUP1=="add new row"'+cond2(1), + PROCGROUP2=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + wideblock2=BLOC(condition='PROCGROUP2=="add new row"'+cond2(2), + PROCGROUP3=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock3=BLOC(condition='PROCGROUP3=="add new row"'+cond2(3), + PROCGROUP4=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + wideblock4=BLOC(condition='PROCGROUP4=="add new row"'+cond2(4), + PROCGROUP5=SIMP(statut='o',typ='TXM',into=("add new row","2","3",)), + wideblock5=BLOC(condition='PROCGROUP5=="add new row"'+cond2(5), + PROCGROUP6=SIMP(statut='o',typ='TXM',into=("1","2","add new row",)), + wideblock6=BLOC(condition='PROCGROUP6=="add new row"'+cond2(6), + PROCGROUP7=SIMP(statut='o',typ='TXM',into=("1","add new row","3",)), + wideblock7=BLOC(condition='PROCGROUP7=="add new row"'+cond2(7), + PROCGROUP8=SIMP(statut='o',typ='TXM',into=("add new row","2","3",)), + wideblock8=BLOC(condition='PROCGROUP8=="add new row"'+cond2(8), + ) + ) + ) + ) + ) + ) + ) + ) +) + +#LEV1 = OPER( nom = "LEV1", +# sd_prod=loi, +# op=68, +# fr='LEV1 FR', +# Boolean01=SIMP( statut = 'o',typ = bool, defaut=True, fr = 'Bool mandatory FR', ang = 'Bool mandatory EN'), +# SelectedItem=SIMP(statut = 'o',typ = 'TXM', into=["01_01","01_02","01_03","01_04"], fr="FR"), +#) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Separate_Blocks_52958_Cata.py b/MED/Separate_Blocks_52958_Cata.py new file mode 100644 index 00000000..1327a3fb --- /dev/null +++ b/MED/Separate_Blocks_52958_Cata.py @@ -0,0 +1,29 @@ +# coding: utf-8 + +from Accas import * + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +def several(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +NUMERICAL_PARAMETERS=PROC(nom = "NUMERICAL_PARAMETERS", op=None, ang="Help for NUMERICAL_PARAMETERS, English version", + #Equations=SIMP(statut = 'o',typ = 'TXM',into=("EF","VF","BS"),defaut="EF"), + Solver_definition=FACT(statut = 'o', + Solver = SIMP(statut = 'o',typ = 'TXM', into=several("Solver_",12), defaut="Solver_06"), + ) +) +PASCALE=PROC(nom = "PASCALE", op=None, ang="Help for NUMERICAL_PARAMETERS, English version", + Equations=SIMP(statut = 'o',typ = 'TXM',into=("EF","VF","BS"),defaut="EF"), + Solver_definition=FACT(statut = 'o', + Solver = SIMP(statut = 'o',typ = 'TXM', into=several("Solver_",12), defaut="Solver_06"), + ) +) + +Classement_Commandes_Ds_Arbre=('NUMERICAL_PARAMETERS',) + +Ordre_Des_Commandes = ('NUMERICAL_PARAMETERS',) diff --git a/MED/Separate_Blocks_52963_Cata.py b/MED/Separate_Blocks_52963_Cata.py new file mode 100644 index 00000000..c115196f --- /dev/null +++ b/MED/Separate_Blocks_52963_Cata.py @@ -0,0 +1,40 @@ +# coding: utf-8 + +from Accas import * + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +def myFact(num): + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + myString="FACT(statut = 'f', List_"+myNum+" = SIMP(statut = 'o',typ = 'TXM', into=mySeveral('"+list_item_body+"',12), defaut='"+list_item_body+myNum+"'),Real_"+myNum+" = SIMP(statut = 'o',typ = 'R', defaut = "+str(num/100.)+", ang='Real "+myNum+" help EN'),Integer_"+myNum+" = SIMP(statut = 'o',typ = 'I', defaut = "+str(100+num)+",ang='Max_Iter "+myNum+" help EN'))" + print myString + return eval(myString) + + +PROC_01=PROC(nom = "PROC_01", op=None, ang="Help for PROC_01, English version",fr="Help for PROC_01, French version", docu="", + Radio_01=SIMP(statut = 'f',typ = 'TXM',into=("EF","VF","BS"),defaut="EF"), + FACT_01=myFact(1), + FACT_02=myFact(2), + FACT_03=myFact(3), + FACT_04=myFact(4), + FACT_05=myFact(5), + FACT_06=myFact(6), + FACT_07=myFact(7), + FACT_08=myFact(8), + FACT_09=myFact(9), + FACT_10=myFact(10), + FACT_11=myFact(11), + FACT_12=myFact(12), +) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Separate_Blocks_52966_Cata.py b/MED/Separate_Blocks_52966_Cata.py new file mode 100644 index 00000000..baef1eb1 --- /dev/null +++ b/MED/Separate_Blocks_52966_Cata.py @@ -0,0 +1,48 @@ +# coding: utf-8 + +from Accas import * + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +switch_facultatif=False #change 'o' to 'f' of some widgets in the loop + +def myFact(num): + opt=['o','f','o','o'] + if switch_facultatif: + myLen=len(opt) + make_f=(num-1)%myLen + opt[make_f]='f' + #print opt + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + myString="FACT(statut = '"+opt[0]+"', List_"+myNum+" = SIMP(statut = '"+opt[1]+"',typ = 'TXM', into=mySeveral('"+list_item_body+"',12), defaut='"+list_item_body+myNum+"'),Real_"+myNum+" = SIMP(statut = '"+opt[2]+"',typ = 'R', defaut = "+str(num/100.)+", ang='Real "+myNum+" help EN'),Integer_"+myNum+" = SIMP(statut = '"+opt[3]+"',typ = 'I', defaut = "+str(100+num)+",ang='Max_Iter "+myNum+" help EN'))" + print myString + return eval(myString) + + +PROC_01=PROC(nom = "PROC_01", op=None, ang="Help for PROC_01, English version",fr="Help for PROC_01, French version", docu="", + Radio_01=SIMP(statut = 'o',typ = 'TXM',into=("EF","VF","BS"),defaut="EF"), + FACT_01=myFact(1), + FACT_02=myFact(2), + FACT_03=myFact(3), + FACT_04=myFact(4), + FACT_05=myFact(5), + FACT_06=myFact(6), + FACT_07=myFact(7), + FACT_08=myFact(8), + FACT_09=myFact(9), + FACT_10=myFact(10), + FACT_11=myFact(11), + FACT_12=myFact(12), +) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Separate_Blocks_52972_Cata.py b/MED/Separate_Blocks_52972_Cata.py new file mode 100644 index 00000000..88927e49 --- /dev/null +++ b/MED/Separate_Blocks_52972_Cata.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +from Accas import * + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +switch_facultatif=True #change 'o' to 'f' of some widgets in the loop +empty_defauts=True + +def myFact(num): + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + + defauts0=["","'"+list_item_body+myNum+"'", str(num/100.), str(100+num), "'Text_"+myNum+"'" ] #presence of default values + defauts_mask=[False,True,True,False,True] #switch off defaults of some types + defauts=list() + for id0 in range(len(defauts0)): + if defauts_mask[id0]: + item=", defaut="+defauts0[id0] + else: + item="" + defauts.append(item) + print defauts + + opt=['o','o','o','o','o'] #initial default obligation of items in FACT groups + #make some widgets optional: + myLen=len(opt) + if switch_facultatif: + make_f=(num)%myLen + opt[make_f]='f' + #print opt + if empty_defauts: + clean_defaut=num%myLen + + + myString="FACT(statut = '"+opt[0]+"', List_"+myNum+" = SIMP(statut = '"+opt[1]+"',typ = 'TXM', into=mySeveral('"+list_item_body+"',12)"+defauts[1]+"),Real_"+myNum+" = SIMP(statut = '"+opt[2]+"',typ = 'R'"+defauts[2]+", ang='Real "+myNum+" help EN'),Integer_"+myNum+" = SIMP(statut = '"+opt[3]+"',typ = 'I'"+defauts[3]+",ang='Integer "+myNum+" help EN'),Text_"+myNum+" = SIMP(statut = '"+opt[4]+"',typ = 'TXM'"+defauts[4]+",ang='Text "+myNum+" help EN'))" + print myString + return eval(myString) + + +PROC_01=PROC(nom = "PROC_01", op=None, ang="Help for PROC_01, English version",fr="Help for PROC_01, French version", docu="", + Radio_01=SIMP(statut = 'o',typ = 'TXM',into=("EF","VF","BS"),defaut="EF"), + FACT_01=myFact(1), + FACT_02=myFact(2), + FACT_03=myFact(3), + FACT_04=myFact(4), + FACT_05=myFact(5), + #FACT_06=myFact(6), + #FACT_07=myFact(7), + #FACT_08=myFact(8), + #FACT_09=myFact(9), + #FACT_10=myFact(10), + #FACT_11=myFact(11), + #FACT_12=myFact(12), +) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/Separate_Blocks_52975_Cata.py b/MED/Separate_Blocks_52975_Cata.py new file mode 100644 index 00000000..88927e49 --- /dev/null +++ b/MED/Separate_Blocks_52975_Cata.py @@ -0,0 +1,66 @@ +# coding: utf-8 + +from Accas import * + +JdC = JDC_CATA (code = 'PATTERNS', + execmodul = None, + ) +def mySeveral(suffix,num): + out=list() + for i in range(1,num+1): + out.append(suffix+str(i).zfill(2)) + return out + +switch_facultatif=True #change 'o' to 'f' of some widgets in the loop +empty_defauts=True + +def myFact(num): + myNum=str(num).zfill(2) + list_item_body="Item_"+myNum+"_" + + defauts0=["","'"+list_item_body+myNum+"'", str(num/100.), str(100+num), "'Text_"+myNum+"'" ] #presence of default values + defauts_mask=[False,True,True,False,True] #switch off defaults of some types + defauts=list() + for id0 in range(len(defauts0)): + if defauts_mask[id0]: + item=", defaut="+defauts0[id0] + else: + item="" + defauts.append(item) + print defauts + + opt=['o','o','o','o','o'] #initial default obligation of items in FACT groups + #make some widgets optional: + myLen=len(opt) + if switch_facultatif: + make_f=(num)%myLen + opt[make_f]='f' + #print opt + if empty_defauts: + clean_defaut=num%myLen + + + myString="FACT(statut = '"+opt[0]+"', List_"+myNum+" = SIMP(statut = '"+opt[1]+"',typ = 'TXM', into=mySeveral('"+list_item_body+"',12)"+defauts[1]+"),Real_"+myNum+" = SIMP(statut = '"+opt[2]+"',typ = 'R'"+defauts[2]+", ang='Real "+myNum+" help EN'),Integer_"+myNum+" = SIMP(statut = '"+opt[3]+"',typ = 'I'"+defauts[3]+",ang='Integer "+myNum+" help EN'),Text_"+myNum+" = SIMP(statut = '"+opt[4]+"',typ = 'TXM'"+defauts[4]+",ang='Text "+myNum+" help EN'))" + print myString + return eval(myString) + + +PROC_01=PROC(nom = "PROC_01", op=None, ang="Help for PROC_01, English version",fr="Help for PROC_01, French version", docu="", + Radio_01=SIMP(statut = 'o',typ = 'TXM',into=("EF","VF","BS"),defaut="EF"), + FACT_01=myFact(1), + FACT_02=myFact(2), + FACT_03=myFact(3), + FACT_04=myFact(4), + FACT_05=myFact(5), + #FACT_06=myFact(6), + #FACT_07=myFact(7), + #FACT_08=myFact(8), + #FACT_09=myFact(9), + #FACT_10=myFact(10), + #FACT_11=myFact(11), + #FACT_12=myFact(12), +) + +Classement_Commandes_Ds_Arbre=('PROC_01',) + +Ordre_Des_Commandes = ('PROC_01',) diff --git a/MED/a b/MED/a new file mode 100644 index 00000000..0018d1d5 --- /dev/null +++ b/MED/a @@ -0,0 +1,110 @@ +ESSAI_FACT=OPER(nom="ESSAI_FACT", + sd_prod=ObjetUtilisateur, + op=None, + fr=tr("Affectation de caractéristiques à des éléments de structure"), + regles = (AU_MOINS_UN('Poutre','Barre'), + EXCLUS('Discret','Discret_2D'),), + Info = SIMP(statut='f',typ='I', defaut= 1 ,into=(1,2) ), + Verif = SIMP(statut='f',typ='TXM',validators=NoRepeat(),max='**',into=("Maille","Noeud") ), +# +# ============================================================================== + Poutre = FACT(statut= 'f',max= '**', + Section = SIMP(statut= 'o',typ= 'TXM' ,into= ("GENERALE","RECTANGLE","CERCLE") ), + + b_generale = BLOC(condition = " Section == 'GENERALE'", + regles = (UN_PARMI('Maille','GroupeMailles'),), + Maille = SIMP(statut= 'f',typ= ma ,validators= NoRepeat(),max= '**'), + GroupeMailles = SIMP(statut= 'f',typ= grma,validators= NoRepeat(),max= '**'), + + Vari = SIMP(statut= 'f',typ= 'TXM',into= ("CONSTANT","HOMOTHETIQUE"),defaut= "CONSTANT"), + + b_constant = BLOC(condition = "Vari == 'CONSTANT'", + regles = (PRESENT_ABSENT('Table','Cara'), + PRESENT_PRESENT('Table','Nom'), + PRESENT_PRESENT('Cara','Valeur'),), + Table = SIMP(statut= 'f',typ='TXM'), + Nom = SIMP(statut= 'f',typ= 'TXM'), + Cara = SIMP(statut= 'o',typ= 'TXM',min= 4 ,max= 5, + fr= tr("A,IY,IZ,JX sont des paramètres obligatoires"), + validators= [NoRepeat(), Compulsory(['A','IY','IZ','JX'])], + into= ("A","IY","IZ","AY","AZ","EY","EZ","JX","RY","RZ","RT","JG","IYR2","IZR2","AI") ), + Valeur = SIMP(statut= 'f',typ= 'R',min= 4 ,max= 15), + ), + ), + b_rectangle = BLOC(condition = "Section == 'RECTANGLE'", + regles = (UN_PARMI('Maille','GroupeMailles'),), + Maille = SIMP(statut= 'f',typ= ma ,validators= NoRepeat(),max= '**'), + GroupeMailles = SIMP(statut= 'f',typ= grma,validators= NoRepeat(),max= '**'), + Vari = SIMP(statut= 'f',typ= 'TXM',into= ("CONSTANT","HOMOTHETIQUE","AFFINE"),defaut= "CONSTANT"), + b_constant = BLOC(condition = "Vari == 'CONSTANT'", + Cara = SIMP(statut= 'o',typ= 'TXM',min= 1 ,max= 4, + validators = [NoRepeat(), + OrVal( [AndVal( [Compulsory(['H']),Absent(['HY','HZ','EPY','EPZ'])] ), + AndVal( [Compulsory(['HY','HZ']),Together(['EPY','EPZ']),Absent(['H','EP'])] )] )], + into= ("H","EP", "HY","HZ","EPY","EPZ"),), + Valeur = SIMP(statut= 'o',typ= 'R',min= 1 ,max= 4), + ), + + Metrique = SIMP(statut= 'f',typ= 'TXM',defaut= "NON",into= ("OUI","NON") ), + Fcx = SIMP(statut= 'f',typ= 'R'), + Tuyau = SIMP(statut= 'f',typ= 'I',val_max= 10,defaut= 3), + ), + ), +# +# ============================================================================== + Barre = FACT(statut='f',max='**', + regles = (UN_PARMI('Maille','GroupeMailles'),), + Maille = SIMP(statut='f',typ=ma ,validators=NoRepeat(),max='**'), + GroupeMailles = SIMP(statut='f',typ=grma,validators=NoRepeat(),max='**'), + Section = SIMP(statut='o',typ='TXM',into=("GENERALE","RECTANGLE","CERCLE") ), + b_generale = BLOC(condition = "Section=='GENERALE'", + regles = (PRESENT_ABSENT('Table','Cara'), + PRESENT_PRESENT('Table','Nom'), + PRESENT_PRESENT('Cara','Valeur')), + Table = SIMP(statut='f',typ=table_sdaster), + Nom = SIMP(statut='f',typ='TXM',validators=LongStr(1,24) ), + Cara = SIMP(statut='f',typ='TXM',into=("A",) ), + Valeur = SIMP(statut='f',typ='R',min=1,max=1 ), + ), + b_rectangle = BLOC(condition = "Section=='RECTANGLE'", + Cara = SIMP(statut='o',typ='TXM', min=1, max=4, + validators = [NoRepeat(), + OrVal( [AndVal( [Compulsory(['H']),Absent(['HY','HZ','EPY','EPZ'])] ), + AndVal( [Compulsory(['HY','HZ']),Together(['EPY','EPZ']),Absent(['H','EP'])] )] )], + into=("H","EP","HZ","HY","EPY","EPZ"), ), + Valeur = SIMP(statut='o',typ='R',min=1,max=4 ), ), + b_cercle = BLOC(condition = "Section=='CERCLE'", + Cara = SIMP(statut='o',typ='TXM',validators=[NoRepeat(),Compulsory(['R'])],min=1,max=2,into=("R","EP") ), + Valeur = SIMP(statut='o',typ='R',min=1,max=2 ), ), + ), +# +# ============================================================================== + Discret = FACT(statut='f',max='**', + REPERE = SIMP(statut='f',typ='TXM',into=("LOCAL","GLOBAL") ), + AMOR_HYST = SIMP(statut='f',typ='R' ), + SYME = SIMP(statut='f',typ='TXM',defaut="OUI",into=("OUI","NON"),), + b_SYME_OUI = BLOC(condition="SYME=='OUI'", + fr=tr("SYMETRIQUE: Affectation de matrices de rigidité, de masse ou d'amortissement à des mailles ou noeuds"), + Cara = SIMP(statut='o',typ='TXM',validators=NoRepeat(),max=1,defaut="None", + into = ("K_T_D_N", "K_T_D_L", "K_TR_D_N", "K_TR_D_L", "K_T_N", "K_T_L", "K_TR_N", "K_TR_L", + "M_T_D_N", "M_T_D_L", "M_TR_D_N", "M_TR_D_L", "M_T_N", "M_T_L", "M_TR_N", "M_TR_L", + "A_T_D_N", "A_T_D_L", "A_TR_D_N", "A_TR_D_L", "A_T_N", "A_T_L", "A_TR_N", "A_TR_L",),), + # Affection des caractéristiques de RIGIDITE/AMORTISSEMENT/MASSE + b_AK_T_D_N = BLOC(condition = "((Cara=='K_T_D_N')or(Cara=='A_T_D_N'))", + fr = tr("Noeud: 3 valeurs (triangulaire supérieure par colonne)"), + regles = (UN_PARMI('Maille','GroupeMailles','Noeud','GROUP_NO'),), + Noeud = SIMP(statut='f',typ=no ,validators=NoRepeat(),max='**'), + GROUP_NO = SIMP(statut='f',typ=grno,validators=NoRepeat(),max='**'), + Maille = SIMP(statut='f',typ=ma ,validators=NoRepeat(),max='**'), + GroupeMailles = SIMP(statut='f',typ=grma,validators=NoRepeat(),homo='SansOrdreNiDoublon',max='**'), + Valeur = SIMP(statut='o',typ='R',min=3 ,max=3 ),), + ), + ), +# +# ============================================================================== + Discret_2D = FACT(statut='f',max='**', + REPERE = SIMP(statut='f',typ='TXM',into=("LOCAL","GLOBAL") ), + AMOR_HYST = SIMP(statut='f',typ='R' ), + SYME = SIMP(statut='f',typ='TXM',defaut="OUI",into=("OUI","NON"),), + ), +) diff --git a/MED/cata_diapo.py b/MED/cata_diapo.py new file mode 100644 index 00000000..0c5268ef --- /dev/null +++ b/MED/cata_diapo.py @@ -0,0 +1,48 @@ +# coding: utf-8 + +from Accas import * +class Tuple: + def __init__(self,ntuple): + self.ntuple=ntuple + + def __convert__(self,valeur): + import types + if type(valeur) == types.StringType: + return None + if len(valeur) != self.ntuple: + return None + return valeur + + def info(self): + return "Tuple de %s elements" % self.ntuple + + __repr__=info + __str__=info + + + +class forme ( ASSD ) : pass + +JdC = JDC_CATA (code = 'MED', + execmodul = None, + ) + +FORME_GEOMETRIQUE=OPER(nom='FORME_GEOMETRIQUE',sd_prod =forme ,op=None, + Forme=SIMP(statut="o",typ='TXM',into=[ 'carre', 'cercle', 'triangle' ],defaut='carre'), + bloc_pour_Carre = BLOC (condition = "Forme=='carre'", + Cote=SIMP(statut="o",typ='I'), ) , # fin bloc_pour_carre + bloc_pour_cercle = BLOC (condition ="Forme=='cercle'", + rayon=SIMP(statut="o",typ='I'), ) , # fin bloc_pour_cercle + + DE_NOMBREUSES_WIDGETS= FACT(statut="o", + Stop_Criteria = SIMP(statut = 'o',typ = Tuple(3),validators = VerifTypeTuple(('R','R','R'))), + Fichier_Med = SIMP( statut = 'o', typ = ('Fichier', 'Med Files (*.med);;All Files (*)',),), + ListeDeChoixPlusGrande=SIMP(statut="o",typ='TXM',into=['a','b,','c','d','e','f','g','h'], + homo="SansOrdreNiDoublon",), + Un_Parametre_Facultatif=SIMP(statut="f",typ='TXM') + + ), + Couleur=SIMP(statut = 'f',typ='TXM'), + Matiere=SIMP(statut = 'f',typ='TXM'), +); + diff --git a/MED/cata_med.py b/MED/cata_med.py new file mode 100644 index 00000000..4640f81e --- /dev/null +++ b/MED/cata_med.py @@ -0,0 +1,29 @@ +# coding: utf-8 + +from Accas import * + +JdC = JDC_CATA (code = 'MED', + execmodul = None, + ) +FAS=PROC(nom='FAS',op=None, + FAMILY_MESH_NAME_REF = FACT(statut='o', max='**', + + NAME=SIMP(statut="o",typ='TXM'), + ELEM=FACT(statut="f", max="**", + NUM=SIMP(statut="o",typ='TXM',), + NAME=SIMP(statut="o",typ='TXM',), + ATT=FACT(statut="f", + NBR=SIMP(statut="o", max=1 , typ = 'I'), + DES=SIMP(statut="o", max="**", typ = 'TXM'), + IDE=SIMP(statut="o", max="**", typ = 'I'), + VAL=SIMP(statut="o", max="**", typ = 'I'), + ), + GRO=FACT(statut="f", + NBR=SIMP(statut="o", max=1 , typ = 'I'), + NOM=SIMP(statut="o", max="**", typ='TXM'), + ), + ), + ), +); + + diff --git a/CarmelCND/configuration_CARMELCND.py b/MED/configuration_MED.py similarity index 100% rename from CarmelCND/configuration_CARMELCND.py rename to MED/configuration_MED.py diff --git a/MED/images/essaiAster.png b/MED/images/essaiAster.png new file mode 100644 index 0000000000000000000000000000000000000000..d01c5de8247a040c043bd9a33dc6499ab4993d54 GIT binary patch literal 11576 zcmV-8EyvP{P)00004b3#c}2nYxW zdZgXgFbngSdJ^%n907*naRCt^$ zyT`6=S$3xPO~1@`$6gb0!(^l<$Sev}6(CeYJ-wXXMi5Zy2@(WB4V4HclPo49!`-;< zxb2pkUX7Elu;%*5_}viy<$wNPYyS^#&=@!jJpR+4x%~AP-2c-D)Fiq7AHODFDat&0s-Hx&nxT_613ZDM=A1FD|>~_rifm~)@{O4ccb{kHAeot%^ec$u=fBl49 zX6$cv*k4^xuPn}Pk(1}+|NY;HA3VE%ct!i-hW-Ec7xLMow++=TsI5S)S3LfBN8>eZ z?p39;4XUFY&re-p71m=A11E8e2uu=ptfs-ERaD6OUjuX3&Vb3 zRW18Z9|+Tc=?z*Li^+oF^hkYoge;hTIuJgc5gLkwS|Qxufe*;G(!9QetwqQdad#w# zi1CKu@R8Ma%hmtzcktPY@qA!BX5_fA|9($eMlOHx1ie z@nKJUEl|4_dwoq68YCp|NlC&qbNcB6^JyYEi$K#~@9?pp{b{ECdBNX3Q1>4D`5GGq zemr2d8lfsyXy#KUl*;vQzeaC+YS$uD<@9ty#7bEvHdiam>kaAJ;I=(x87aez5nxaR zCy6%^VJpkw2M^g_@@K;exxj(d?{&e z*2t#8kkRqs$WbMl7B>IzHKh}rzkP>RhIYHAkPsn|eWu;CbicepUGDIC;_%&D=I>6p zrboR{tiHa$51BA~OscHbSA2^9%s2)#n)b7X%~v-_*Kz#uXS4))%8(ORfAa!g6U9r) zL!gF?U0W{x<^|(BfSeRvg?Sv&!jY$pe${gE zx38%Jp8oX%dGB#AI>ItzTSL|@b~4=mBkZmluewWJv)( zCJy5hX;=^n?9S4@>T%aA(jb}s{gLJF!0qq9Wb_m9dP07zn$`5VH_wiKrYzJH820;FNsFsrvdFNb(@e_VhqgRePVq3MAP)# z{P(Ys*A8)4dGXDcq^6=uCVZNSj|<(UWA*p1FxwU9_eaiu`ozmWyg;uF`yV~W)RwFQ?d>(&Utf`G;O<}E z(b7<#X38n??sQ`2$eaKCpSbw?n!o(lMw-j?%RVk?}DjLLtUT90zovAXEjb zVKIc`Bjp$g#WOAoo!d|w1*(!0#PdKEhVk>8*VBFZ5^XACIbf|u^%o=&sY%fm%hSK!v$?)Pt_`4?hEz3z}} z&H3G#$A9`rzv+=%!DqkvEv0Xm_ak@z{E@ymC9E7>|j=AAe+edE)E; z>9>6N#~;zJ*T|+Lq)LnxqZPw(PZ%e{{Rv&Q#TS826RpiGCa9%(FU ztkiQsmO>sf-EKwqhfCD9BNk056{Q7-{R#2tk^78Rj?GsW*tRFBgkA6GZU#zPSUw#o zIpU0F^Z6F{)dl6&A#`CmjpS2c`L{=kNZ9K)1aA?i!seo<|7L}Lvtf08$@y_${`7>I zGq3*B7pTuJQN1J&h4O=9dvSxA1k1Y*e6XJG_pd0mVU7z*cf@h#^ywqRyZ87*Bm|FE zy2n++G6lp_VEp;Om?mz%{2bL-5}Bw3&a4RgiTLvoKQ5Fg>3?&J+iVd{hYp2#PK?Jh z>n)uAaz{x4b)zxA+Jbe+Qn0&*@Tp;bdxZ1CbUd^BV$169UZ7rXm}90af#uzvbabI_~9jvwyvA0Oy{bxr+zOX)3bvu1vLB>95tE#2o^+UA0X z`*%Ft4}9~tf54|1KPLR!C*~i1ARh;0qu5+EXc4C84G;zM{gJqT;QD6A>KC68+J+P& zjcTc{*Qgjd|MZEj-?9Gtm)LJMnC*sC1TjubZ;!YliKjF55OKFH{U2^Ht2L#Jq`5MG zI52#-r_LGONY*dbw6CwIYm07Mj2}7t`yS>Ai6opCRFI6{ABg7}D=f{6h9U}O2^-l6A$={B_6 zo+_X=1|8-j=fgc}lnmegOf3Ta;u3w?lLcf1%4!OQ$NNXDYFK~0Mg8&;b<-h)VK_aK z-yKm3!aTqTRE50R(Z7005{BvSj``n@EZ={GC16%7x?eV|-dsZKIKJJpoJORu5GH!F z;&?ydmxU}q&Xv_|kG*Y)!0GJ)v2`qe`9yvUH0ze}eouJ&@%it57!U~Jm}#~eRp9ui z_oy0Jty|{r4;;-0*4LNJ!+>4)gt*XbJ4QL8ZPQ?8K|CI)=S08V(cEs))*vJ#VJNAR zrbtbd_3b6>TI701(Sj;9a*4z~as9WiIDY$y>ND-_1@-fe5H<6DPkK9%ejYK&QEw#M zzk7*&^8$>Zo@T;BVE*Zz-4|O-l}vXdWWn~gFHl=eS|YpKE21rY`uDf=W<~s%@b?)L z8s?{nUZ9pp*$u3}UcmyxyMZMyT>bhhE`Ifz@qW+rX^;JsP&W(S&3F|#KRjSo4yi4o zXf&e2EC@f$q&cB`!D%^>4uKP#_w|bI>l;MBW)3GpnqXY8L*@LZ6Ec7%v-|1| zn?GEzhzRq-=ogyRn)S^k{x2t%yP3XS(S6l2J`KbS_VtS0?_SVeUb7rVhEIQ{xmlra z*R<;``o#)kE$ME+>W(@~T(4RE?wV%XuoTJobU>RbVO*$bK^n#C7h7_Z(J>*?h^+!q zGqaztYeWCl1w|`z4wP}k|9ph#QP(SSESwJ$LTl0-DL+3F=Ri7))D&sIYFPdL0()_R z+-;Z-BjNtY=}!-wKRl2JkM10HquKoOCCyhGg0%<_$B&P+7Ye5>PlrsM1>Mb-%imog zUab+wN648h6YZ;)_z;O&BPGPA!1Vsez(^F&^hEWR@xz(*7c176mpmNru(BiP#P)WF zHrX;i4&)5(O-KLbB|#*l$b{hxIF`E;)A7W`=eLNBK`F_3f5g8%QbWMCmgP8-PKos0 zOdT@ag=PQK6GCLrk?v*B_U~WOy?jLonf-@*^2ambhexI#9#9jsn+?q`R&0KEgSH(( zMbdm?`t}L`>BwsL0)Lt*KQB1zurC_ai%VGdtalyb`3^BD#$`rU$@FfI5}E1lh(F(< z#TwH!WE~j~nW8;2vtw?AQ@ zAUsX9!ccaG_D#?3_n&bV9yQJQyA$y)Q|7?U?_Z-D$J5&fRLY25OUVt>@kqDsDALfb zUvf@Q#P?75k0bNJBieXS_EP@gI?I`Sgf=nM9Dd$wQh&_vKq z(0zSP`^^iYSeW)l(iFJ)@{;|-BO*bwS!3T^Qk6rBOmo#^R+1tl*?aQ)f%I-9o=2?G zbgMPxg<$=M*KA+EVvHU!2hJbwi0@D6M-UFyuNp*J<6f-Dt3oCdKMd4UM&ycdmHwAE z=$9L6%(&2?UUoE}tthi&|Cc@Ha*J@4ie&ii6Z4-RXp)3;LbjFeWsB=Oa-(UlEbJV1 z-I9Vw-71E62l6}5k{61}s36c`nc4j6CE^!bYHwhU`2B)WigAoIG-P1_$-JD{h%Jj> z7>{Rkh!i1MzCYuC9!c{=e{%&?+!r0||L_^j%?&<844UEn&z%1BfKw~F&pK9LUNW3d zs3;Le5RNll14>Jj(Ug$r-)zyhYo_RFie(rN*j8g!mKZWN1javpz`kgC`tA{)X4IkJ z;q{IOm{Q>{T@>U>(95SmusAL3}S|@Bjn8DJ^6g3 zd>U9gOaJwT)o*V(E(5*2AWRdrB$O4Lp9bQ%P`swSUSqc#k}QP%%<OJxiR&b(M#j5|dc>hFrzo0^*-}T6yBaRDAr)fX` zlC;$rY3SCHav#W3pucLVMse9&V|RZE(eYig3zoarf~MX>(-lI=GyIr|A!47xX{rbo3Bc@o6? zGhvIwC7|t`Q?~wbM zJdCvM3j3F?C`mFBIRuvFo^l>> zZbiS_QJh2BhGjkwhMDv<5RVhfj}cPBylU8OF5pU2UtUsmLnKg(pc+FAnOFm*NQ5a+ z3LpOXp6&I9^2xJ&I#E#cFIUjPm>0Bl*3D#|od~H~Lbxo#XcO4-sVoc<5peceV z5+Qlw*|Y!tBQ|Q35R{*fOz#6CD)1U1V0nyiil7zI34-#BWn_ER^YP!`VowSyG}1jY zULP~rC(hq}Wc>M#m%n^N{mh|t)|5CB?nknRJPw%F;9hmejiK9h6saJ2)Ty#0k4zHN zIJm7Cx1}h^a|EBrqi4E5Ql18sku2j0{m?Uidt#YpR0jDNsa9f)!QM2qU)@5lm=0&+ zA(G-5672u^2W+-vT{!K}w5mrhndLZOl|dJ%GEuX@Z92lVAXBD9g`bZUd1gM$Xe)Rh z_c#fvM11m8DM+6(dVRuLNqj%xY)8-q*C@pQ`M>1E zB7`7?nR*WRX`tC{P*NjWMX805GIhW3^p|_gl&DXcWq3eogL5kof_(IZus|);5HOu$ z^Xes`1%10_9vA%KfGn0QJpO4y&jqAFDMLwuLPaP+cV(!yVy}8~BZ%if6$RldLS%#y zRCr%SJ3w)fgSuji^?rK9c5nV@5o)f0C_<13yOuuWv zDSRq`poTy=Pvnmabydg)Osf$>QI4G;W2TCj30o zON9>$(m9qIS-t7WPY3czlIB4F;(}x<6@eKR{11=lED-G#%lU}D7x-l%JtcH48NIeB z*RXEa6j2by5Mv;ZN33&9;~oB}sSIQKqOF}J`eDo-pvDYo;%Pmz{^u-ER z;6fxH55y&4n-v$I-4fzV924oh&<&YdEKVres}*+JLfhhNWOZ?YSO&sy#0^kYMeKT# zX^~1H5a`C@r!x7HAm#;sSa7A%UThhc8K~5qK`Mi}UZKPeF+9=C z3#$oqe{%^9Y%Y72F_OZoDsTYSmDb!dOihCiIQQrh@J)$ytoQkB3V2}NPenmL|O zCS%tLyp70< zmWwYxXAu>ILDWP|1z|K&uGxP&uxSj=HTXG_D73o`!^Z>jIdbv4&k0J=thSV}0D@FJ z{%~g5Cz>mb>oy2&D8Vz|A0bB+pp-;!4IPHsSh7$+p=lh;l*vjlemJpmn&x6h96gO{ z5LD(kqShT!OURIgK*tK{oRCJ6=Y{@ag$HCUoc9NulT>L5lc$!%>GX*j6BnN~(Df*- z$>)f!4&5}2(;3@sNK_QCoIK0nh;0li26D;xalxM_@~|NKhW=(vSPCU1loLdMLNzUf zM9m8#CDL#}Z(gy~fXyH(xV0oEi^Wil!PbOoG-$^(1(cOUAL&fP)K2JRAqD3B37z3Q z&Zz3>O-B`Ax*qKu$B%dDwsp*pBg3bWcITMq1*J60G$4IuUIOi<#W;tSE$MKgNMO|? zn>8gbe>If~U=Ts$(}-FB7I_5BF$1*j%WOs2{zGGMO6~NA85SgI6Sct zS5%`=RpZYd|Kmq?zqmzG0f9^kU6lnnV4b9dgfId>FQjR~nijXRlulukCFX>{BB zjZ9(UJe(=}85+&-e#R<`q%!M0RXMa)%x|9%fBMt=8m2RK27IOhMR-=*jwB_fZSdht znG?;rr^-kbl012qk0;V&z-%P$vn@h8tP*5VsYVmY2oEyBxPQQE_dFjg#88+X_ZSK_ z3S?@irxT(y=uWfvNSFglnrN3wdhn!Ds5RqUM;NDP$3JIsnW$OO>_{N+XPBSpxAqvk5Ee3^6707}@{$gdw3-H6SY0Lg&^j`!i*V2n$BF%u`@K zdb-OMLP~Og$V{CR!!RR_!mb+T`8h_N9v&!XO-(b6aU`GdANR-wL@oGIXk3e*7KBr{ zbwfCgNF7?3g> z0mD3dy6c9LEwb}uQ@{yStJu8QF-!)3cP8DupX_%)GNJuSF zralY5lSj^i`Lv)qjj9T<2$&N_NNTFoV`K^w<(NsICX8;eeTztiBfYp{85VS_k+mgHktt1xjYGb^Kuw+~6v9hZwnH{8ZqpLyK)aR1Au>&8 z3~P`A*$ZeTHcM1nX}1mIF;QoMKPFmZiCLhvW?l-@-HG;gLv|5#B6S5FbV5mskrix( zu0ghjQvd2)2~9ZPLs2L;q!Os-08=KUjKwfLobl1Kx>(~b*Hl-qyERf(s!NE*((P7+ zn2GZY)uJyQUIvU=lWWBE7HJe^@dO``)}deYgp^Rq;-3cMvS2gJejtg8>pE=KR9RW3 z8NrBhmI~B5qE`la*^v#TF;V=CrC}N;Ry&K<4TOZMP)eqx#IPK=ym^fl+ELO-4v+#A zA5lnzlUUv0&5W=Xr9sq8I0VW$B4tK)2H7@<5NKVC+(_h&Mo2|88K*nC^);$BoX6*F z5@SM`j4}@0cI0tpIeCmWgu_7e3zUjmHDoHqDu@LESQL*RKeFytRIiwC6RqwDAz`cI zG>wSkLf5oZ3U!r9V!<^#P=XXALJIO+kwt(hbYJe!y#^&vo#Wbl4x&YC1X4M2j>xJB zerEA!T)##3ky;{Z-Jv^8o-_D>FJ~INr7D4Xv7)~;B=12zi%x$CXt$=SN)eXh-4W*$ zN@h@yMWF;wDFJ*!Dc;9wO)>B?LwC6;%t? zK4(g%Q3zcr$CczB&^+#$uzYf zDI}3;I*W2Gp=NBfgt(yFhFk)A4WiCJe`o)Q4utaMr%!?Qi`MqPep*XB;`p{ChsF=YY|1FWC9dvnW?EV zo)7r*ObL-RSL)F5 zf$@I8S`Erk{KRVA;0H+@0;@L|C<4Jjq6fQzdh zKYOI33q*;za1_6w zqGn1*WaE%Rf}J_;PxNh1c;^ugtTE)0P~QI=+5i9yzDYzuR5fC>qNa*%9m;Bwl1QO3 z($Z`jpg~<%bmwS9MfN?b5{W)iY9W`%%7AHlG6Rv8-Zl6d5VJ?r1;0piu?kTVML^aP z6)UxjsG^7%LV(l5fpYdp1;R(-;XpVBYS2_6@xuW#S9E8YbtFeH!r)?pny6)>bseJD zoK6eMO4@Y;8%w+DDFn_>Cqya8V%S~uR3)$%TiTl~^p)Nud`L*2s6l`#sLKu^6Ezod zOqjk!wiaa+XhBtqkUUbhm|!3zrt`$&GtmdEaY$3iji9OuLJ($22@xH#N5o7z3=k?I z&XhS*Nb@_0Zj6(tSL&N7yf ztN(C~u#z!)j8T-fVY}`SA07zj0g)xTy+A04B0=9ntLcnEj*%D!ih{oDi3zMI#5ALF zp~#BT4q+rER#Gk~`P^8aj}vtas34if6U0ik4Yg^&NwTig7%9WV{4}BK6c8C?uB03g zSs-%2T8nH8LR-w0CM+%edX0~PJcHB;=`7h)HtrQQdP2@rD^bd@q(E~i$)liY6(uFw zrXdPJMbkHzq#O~}G8=_?u_JU6Cl$3=a`p%ow38@fh*KelfG`dv3qB-Nb{w9LAZBc9 zi6v8%z(~RH;Y_KLB4^gSE$Plvh6TA6IB5_TlBjgXfUo4~j4p~849oiyS{a4xG}=mB z%`9U;Z7fo0RHL2`Fhs!>LGa+miQ+57jN56j4W)I@G#^2#g-k_efpQw5X8dU+oEL2G zD7zLZDxp?r97shLpw}CW$SmiHc=t$NCf1ibaInmt&W;29`Wh)I!s?EXzc# zaR1#qRyS+5U%x;#&w;wEg;+piNX3(YOdt#fK?KHVmdb372 zL5$CuuAUR3(?|zNN~4!D4f+3m$xk?EL2%ZLQ$(k)-7&0LS{192$p87D8r;)gLy6X*W1naMMtZ%MB!w~M!RikSv&jEQUh@7cm zq3RBaq9%`@JWZ>S(vo7PV{>QNMmBDfs~K5 zs=+u1N-!Tiga3fsZ4jMAC`~>mtg+7zB_N4{w1$`!Ix7U3I4201X*y6tp`0T3;*r+% z#8^o&ph6%onS999BEU(;W}-F%w{CG)E%vgdmQ1-%WL2=69b#ChenM9t2{{5FNw~PSSRkkTcBB*Qq&VYL>X(u}lZT`9vN(DI}Che0Un4 z)vyGoJKS2ZzkAE&)hiAUcMu|07D7yvCL$EL)fygW`nKor>4*mAhX+c{SZPUqA%(GoHX^Gb5d2E+1*yj$t{F#(-26d1FvY zQA&aw(MltAWwq;w(@6jIj_Sbb_8Aqjpx2h#7%CMXGtwyB$}oO-N7sLWiWOZY&tl9~ z@RnRFsyt`H)hVRVKtsq8BOtembRH3Pjcy&XwTL8;J5Py$aC*LimlBk&wA&R+Y>?M2 ztuhQxClHn9(h@>p|L(|It?+Z^#nmmtVPL!6a^4?lR++xGiLF~X+~CoAJ3$`puObbpFTXJ zAxr^Q0*OJl4JH&)oRO(PR!NeTN`#W1#i3ESZO5`?Twidaq3S}c1$VI~$3hJSi6T|c zDNPU)-Fii^&|KYOT8(TZ|9=T*mK(=*M8UXo4PDJ9Dd`Qi3>e=3dJGr_{PE;L5+(Lf zU3KU5NADpMh=Yuiq{MH3exa<9_P;AQi$BaXV>o<%rMKmA(&+_tJLBFhKmPNL{XG%} z4Nb5N#1e^@$b1?JCrc`k+m9>OgRO>(y3u@Nd%JPJ-#C6eQM%CjLm6?lW6MY{mF?>t z>oivJ*h&51IBHJhQV7eDS_~eLWZ2T3mNytIO?lMXxc~PjdEPJ~&{C!KLU;;vsrY#$ zZ9@GPskswpu->AV2|Wh760D!8sgQew(bKGE_%t)U45U4w%n@QGZjn!a{Xou%^7lsl z_eRur(I)o;X^~8t;^paA>yoD`Gd)X{7Z|T{rUe&h$JojDcJdRWvO{>idSIMiGtq z%Yk8jp#)7Uf_gR>o$$_*Q^Gihh(?VX)jNY%beV|z9c*Lx_=E~0)(>=PDM2`_m#Y7a?W%C=K}lfN+Alu|I=v3`G}xlT--Jtq9FzQ6~@yEv5KKD^!lhrAHp+DD&fN`xn|}oE(mLbofqrk~d&P7`Z3V46YBPx5 z@#9P~LQEAuX!fO1?&k4gvGzu_w#+<;LypLbw~Uc2t+Cm&!f{=1)ibI3iwC(ncL(*2H@PSgdpz7dq6?-jAYXz9VDoW}z(uME#4k~>tWG1IPZ zoG%+)3`z>JC8TQN?MgkU$D0+eaI;3)8P!+JU|D0v4gm=jV*`4zm_w#lL7g|46bE_2 z(CJBY{o{sxU8qw>L@@rq^f!-xUQui2`o}lY_ee_{>;29&zToOW>KA%dw0>ti&0ODi zMrYZ+T#&UQWNf{4_O~nU^%*-^#=}5=8Hw)~h!$Z-n~`$a>AImj9NhRQgd6BVLE_Hs z%SPIE+BDG7r0a!VD|ToG$rZO32$n2@b{^e5-+92+c!%IMIl~9HK>zyzSr1!6sZ)e7jFVsIB zQIkgng9#d1#oB-kmZSu6LO2*wsVs+Add_IwY5D=DW|%qrF2uK;55o~{8n!{d?`;1P qLN3%HkZNQa9ZEoK!5, 'IDE': , 'DES': , 'VAL': , 'statut': 'f'} +() +{'max': 1, 'typ': 'I', 'statut': 'o'} +() +{'max': '**', 'typ': 'TXM', 'statut': 'o'} +() +{'NOM': , 'NBR': , 'statut': 'f'} +() +{'NAME': , 'statut': 'f', 'max': '**', 'ATT': , 'NUM': , 'GRO': } +() +{'NAME': , 'ELEM': , 'statut': 'o'} +() +{'nom': 'FAS', 'FAMILY_MESH_NAME_REF': , 'op': None} +]0;A96028@dsp0780471: ~/QT5GitEficasTravail/eficas/monCodeA96028@dsp0780471:~/QT5GitEficasTravail/eficas/monCode$ exit + +Script terminé sur mar. 29 nov. 2016 15:37:13 CET diff --git a/MT/MT_Cata_V2016.py b/MT/MT_Cata_V2016.py new file mode 100644 index 00000000..6911bb19 --- /dev/null +++ b/MT/MT_Cata_V2016.py @@ -0,0 +1,1066 @@ +## -*- coding: utf-8 -*- +# +## -------------------------------------------------- +## debut entete +## -------------------------------------------------- +# +# 20120510 : suppression de la valeur par defaut de MATERIAU->PARAMETRES_MAT->NU +# changement du nom MATERIAU->PARAMETRES_MAT->MASS_VOL en MATERIAU->PARAMETRES_MAT->RHO +# +# 20120619 : changement ordre d'affichage des macros -> ordre de création +# 20120725 : modification definition (matrices A,K,M) palier et support +# 20130411 : ajout elements dans palier generalise (mail tdg + comm tdg) +# +# todo : supprimer les noeuds -> definir les elements par leur longueur +# +# +# +# +# + + + + +from Accas import * +# + +import types +class Tuple: + def __init__(self,ntuple): + self.ntuple=ntuple + + def __convert__(self,valeur): + if type(valeur) == types.StringType: + return None + if len(valeur) != self.ntuple: + return None + return valeur + + def info(self): + return "Tuple de %s elements" % self.ntuple + + __repr__=info + __str__=info + + +#CONTEXT.debug = 1 +VERSION_CATALOGUE="2016.0.0"; +JdC = JDC_CATA(code = 'MT', + execmodul = None, + regles = (AU_MOINS_UN ( 'LIGNE_ARBRE',), + AU_PLUS_UN ( 'LIGNE_ARBRE',)), + ) # Fin JDC_CATA + +class Direction(ASSD): pass +class Materiau(ASSD): pass +#class Masse(ASSD): pass +class Zone(ASSD): pass +class Palier(ASSD): pass +#class Masse(ASSD): pass +#class ConditionsAuxLimites(ASSD): pass +class LigneArbre(ASSD): pass +class Support(ASSD): pass +class Butee(ASSD): pass +class PalTor(ASSD):pass +#class Noeud(ASSD): pass + +## def macro_noeuds(self, NOEUD, **args): +## """ +## """ +## if NOEUD is not None: +## self.type_sdprod(NOEUD, Noeud) +## pass +## else: +## raise AsException("Impossible de typer les concepts resultats") + +## return Noeuds + +############################# DIRECTION ######################################## +DIRECTION = MACRO(nom = "DIRECTION", + op = None, + sd_prod = Direction, + reentrant = 'n', + UIinfo = {"groupes": ("Machine tournante",)}, + fr = "Renseignement de la direction de la ligne d'arbres", + AXE = SIMP(statut = 'o', + typ = 'TXM', + fr = "Direction de l'axe de la ligne d'arbres", + min=1, + max=1, + into = ('HORIZONTAL','VERTICAL'), + defaut = 'HORIZONTAL', + ), # end AXE + ) # end DIRECTION + + +############################# MATERIAUX ######################################## +# @todo +# introduction manuelle => dans ce cas l'utilisateur definit le +# materiau comme ci-dessous +# recuperation depuis une bibliothèque de materiau => sera specife +# plus tard +MATERIAUX = MACRO(nom = 'MATERIAUX', + op = None, + sd_prod = Materiau, + reentrant = 'n', + UIinfo = {"groupes": ("Machine tournante",)}, + fr = "Renseignement des caracteristiques des materiaux", + TYPE_INTRO = SIMP(statut='o', + fr = "Mode de description des caracteristiques des materiaux", + typ='TXM', + into=('MANUELLE','FICHIER'), + min=1, + max=1, + defaut='MANUELLE', + ), # end TYPE_INTRO + PARAMETRES_MAT = BLOC(condition = "((TYPE_INTRO == 'MANUELLE') )", + #MASS_VOL = SIMP(statut='o', typ='R', min=1, max=1, fr='masse volumique'), + fr = "Saisie manuelle des caracteristiques du materiau", + RHO = SIMP(statut='o', + typ='R', + min=1, + fr='Masse volumique (kg/m**3)', + ), # end RHO + E = SIMP(statut='o', + typ='R', + min=1, + max=1, + fr="Module d'Young (Pa)", + ), # end E + NU = SIMP(statut='o', + typ='R', + min=1, + max=1, + val_min=-1.0, + val_max=0.5, + fr='Coefficient de cisaillement (-1.0 <= NU <= 0.5)', + ), # end NU + ALPHA = SIMP(statut='f', + typ='R', + min=1, + max=1, + fr = "Coefficient permettant de construire une matrice d'amortissement visqueux proportionnel a la rigidite", + ), # end ALPHA + BETA = SIMP(statut='f', + typ='R', + min=1, + max=1, + fr = "Coefficient permettant de construire une matrice d'amortissement visqueux proportionnel a la masse", + ), # end BETA + GAMA = SIMP(statut='f', + typ='R', + min=1, + max=1, + fr = "Coefficient d'amortissement hysteretique permettant de definir le module d'Young complexe", + ), # end GAMA + ), # end PARAMETRES_MAT + FICHIER_MAT = BLOC(condition = "((TYPE_INTRO == 'FICHIER') )", + MATERIAU_CATALOGUE = SIMP(statut='o', + fr="Fichier decrivant les caracteristiques materiaux (format decrit dans le Manuel Utilisateur)", + min=1, + max=1, + typ=('Fichier','Fichier materiau (*.*)'), + ), # end MATERIAU_CATALOGUE + ), # end FICHIER_MAT + #SIMP(typ=('Fichier','JDC Files (*.comm)'),docu='',min=1,max=1,statut='o',defaut=None) + ) # end MATERIAU + + + +############################# ZONES ######################################## +ZONE = MACRO(nom = 'ZONE', + op = None, + sd_prod = Zone, + reentrant = 'n', + UIinfo = {"groupes":("Machine tournante",)}, + fr = "Description d'une zone (comportant noeuds et elements, et en option masses ponctuelles et fissures)", + regles = (AU_MOINS_UN("ELEMENTS")), + MASSE = FACT(statut='f', + min=0, + max='**', + fr = "Description des masses ponctuelles", + #POSITION = SIMP(statut='o', + NOEUD = SIMP(statut='o', + typ='TXM', + defaut=None, + fr = "Definition de la position axiale de la masse (label du noeud de la ligne d'arbres en vis-a-vis)", + ), # end POSITION + TYPE_MASSE = SIMP(statut='o', + typ='TXM', + fr = "Renseignement du type de masse consideree", + into=('DISQUE','AILETTE','QUELCONQUE'), + ), # end TYPE_MASSE + DISQUE = BLOC(condition = "((TYPE_MASSE == 'DISQUE') )", + TYPE_SAISIE = SIMP(statut='o', + typ='TXM', + fr = "Type de saisie des parametres du DISQUE", + into = ('MECANIQUE','GEOMETRIQUE'), + defaut = 'MECANIQUE' + ), # end TYPE_SAISIE + PARAMETRES_MECANIQUE = BLOC(condition = "TYPE_SAISIE == 'MECANIQUE'", + PARAMETRES = FACT(statut = 'o', + fr = "Parametres mecaniques pour un DISQUE", + MASSE = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Masse du DISQUE (kg)", + ), # end MASSE_DISQUE + INERTIEX = SIMP(statut='o', + typ='R', + fr = "Inertie du DISQUE en X (kg.m**2)", + ), # end INERTIEX + INERTIEY = SIMP(statut='o', + typ='R', + fr = "Inertie du DISQUE en Y (kg.m**2)", + ), # end INERTIEY + INERTIEZ = SIMP(statut='o', + typ='R', + fr = "Inertie du DISQUE en Z (axe de rotation de la ligne d'arbres)(kg.m**2)", + ), # end INERTIEZ + ) # end PARAMETRES_DISQUE_M + ), # end PARAMETRES_MECANIQUE + PARAMETRES_GEOMETRIQUE = BLOC(condition = "TYPE_SAISIE == 'GEOMETRIQUE'", + PARAMETRES = FACT(statut = 'o', + fr = "Parametres geometriques pour un DISQUE", + DIAMETRE_EXT = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Diametre exterieur du DISQUE (m)", + ), # end MASSE_DISQUE + DIAMETRE_INT = SIMP(statut='o', + typ='R', + fr = "Diametre interieur du DISQUE (m). Verifier le diametre exterieur du rotor avant saisie", + ), # end INERTIEX + EPAISSEUR = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Epaisseur (dans la direction axiale) du DISQUE (m)", + ), # end INERTIEY + MATERIAU = SIMP(statut='o', + typ=Materiau, + fr = "Materiau constituant le DISQUE (doit avoir ete defini via une entree MATERIAUX)", + ), # end INERTIEZ + ) # nd PARAMETRES_DISQUE_G + ), # end PARAMETRES_MECANIQUE + ), # end DISQUE + AILETTE = BLOC(condition = "((TYPE_MASSE == 'AILETTE') )", + TYPE_SAISIE = SIMP(statut='o', + typ='TXM', + fr = "Type de saisie des parametres de la rangee d'AILETTES", + into = ('MECANIQUE','GEOMETRIQUE'), + defaut = 'MECANIQUE' + ), # end TYPE_SAISIE + PARAMETRES_MECANIQUE = BLOC(condition = "TYPE_SAISIE == 'MECANIQUE'", + PARAMETRES = FACT(statut = 'o', + fr = "Parametres mecaniques de la rangee d'AILETTES", + MASSE = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Masse de la rangee d'AILETTES (kg)", + ), # end MASSE_AILETTE + INERTIEX = SIMP(statut='o', + typ='R', + fr = "Inertie de la rangee d'AILETTES en X (kg.m**2)", + ), # end INERTIEX + INERTIEY = SIMP(statut='o', + typ='R', + fr = "Inertie de la rangee d'AILETTES en Y (kg.m**2)", + ), # end INERTIEY + INERTIEZ = SIMP(statut='o', + typ='R', + fr = "Inertie de la rangee d'AILETTES en Z (axe de rotation de la ligne d'arbres) (kg.m**2)", + ), # end INERTIEZ + ) # nd PARAMETRES_AILETTE_M + ), # end PARAMETRES_MECANIQUE + PARAMETRES_GEOMETRIQUE = BLOC(condition = "TYPE_SAISIE == 'GEOMETRIQUE'", + PARAMETRES = FACT(statut = 'o', + fr = "Parametres geometriques d'une AILETTE", + MASSE_AILETTE = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Masse d'une AILETTE (kg)", + ), # end MASSE_AILETTE + RAYON = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Distance entre le pied de l'AILETTE et le centre de rotation (m). Verifier le diametre exterieur du rotor avant saisie", + ), # end RAYON + HAUTEUR = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Distance entre les deux extremites de l'AILETTE (m)", + ), # end HAUTEUR + BASE = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Largeur du pied de l'AILETTE (m)", + ), # end BASE + NOMBRE = SIMP(statut='o', + typ='I', + val_min=1, + fr = "Nombre d'AILETTES dans la rangee", + ), + ) # end PARAMETRES_DISQUE + ), # end PARAMETRES_MECANIQUE + ), # end AILETTE + QUELCONQUE = BLOC(condition = "((TYPE_MASSE == 'QUELCONQUE') )", + #TYPE_SAISIE = SIMP(statut='c',typ='TXM',defaut="MECANIQUE"), # cf 20120622 test : mot-clé caché + PARAMETRES = FACT(statut = 'o', + fr = "Parametres pour masse de type QUELCONQUE", + MASSE = SIMP(statut='o', + typ='R', + val_min=0, + fr = "Masse (m)", + ), # end MASSE + INERTIEX = SIMP(statut='o', + typ='R', + fr = "Inertie en X (kg.m**2)", + ), # end INERTIEX + INERTIEY = SIMP(statut='o', + typ='R', + fr = "Inertie en Y (kg.m**2)", + ), # end INERTIEY + INERTIEZ = SIMP(statut='o', + typ='R', + fr = "Inertie en Z (axe de rotation de la ligne d'arbres) (kg.m**2)", + ), # end INERTIEZ + ), # end PARAMETRES_QUELCONQUE + ), # end QUELCONQUE + ), # end MASSE + ESSAI=SIMP(typ = Tuple(2), + max = '**', + validators=VerifTypeTuple(('TXM','R')),), + + NOEUDS = FACT(fr = "Definition des noeuds de la zone (2 noeuds minimum)", + statut='o', + min=2, + max='**', + NOM = SIMP(statut='o', + typ='TXM', + fr="Label du noeud", + ), # end NOM + POSITION_AXIALE = SIMP(statut='o', + typ='R', + defaut=0.0, + val_min=0.0, + fr = "Position axiale du noeud (relative par rapport au debut de la zone (1er noeud a 0m)) (m)", + ), # end X + ), # end NOEUDS + ELEMENTS = FACT(fr = "Definition des elements poutre de la zone", + statut='o', + min=1, + max='**', + NOM = SIMP(statut='o', + typ='TXM', + fr="Label de l'element" + ), # end NOM + NOEUD_DEBUT = SIMP(statut='o', + typ='TXM', + fr= "Noeud de debut de l'element poutre (label d'un noeud)" + ), # end DEBUT + NOEUD_FIN = SIMP(statut='o', + typ='TXM', + fr= "Noeud de fin de l'element poutre (label d'un noeud)" + ), # end FIN + RAFFINEMENT = SIMP(fr = "Choix de raffiner l'element poutre", + statut='o', + typ='TXM', + into=('OUI','NON'), + defaut='NON' + ), # end RAFFINEMENT + PARAM_RAFFINEMENT = BLOC(fr = "Nombre de points supplementaires a ajouter pour le raffinement (nombre elements : 1 -> nb points + 1)", + condition = "((RAFFINEMENT == 'OUI') )", + NB_POINTS_SUPPL = SIMP(statut='o', + typ='I' + ), # end NB_POINTS_SUPPL + ), # end PARAM_RAFFINEMENT + MATERIAU = SIMP(statut='o', + typ=Materiau, + fr= "Materiau constituant l'element poutre (doit avoir ete defini via une entree MATERIAUX)" + ), # end MATERIAU + SECTION_MASSE = FACT(statut='o', + fr = "Section a partir de laquelle est determinee la masse de l'element poutre", + TYPE_SECTION = SIMP(statut='o', + fr = "Choix d'une section de dimensions constantes ou variables", + typ='TXM', + into=('CONSTANTE','VARIABLE'), + defaut='CONSTANTE', + ), # end TYPE_SECTION + DIAM_EXTERN_DEBUT = SIMP(statut='o', + typ='R', + fr = "Diametre exterieur en debut d'element poutre (m)", + ), # end DIAM_EXTERN_DEBUT + DIAM_INTERN_DEBUT = SIMP(statut='o', + typ='R', + fr = "Diametre interieur en debut d'element poutre (m) (different de 0 si element creux)", + ), # end DIAM_INTERN_DEBUT + PARAMETRE_SECT_VAR = BLOC(condition = "((TYPE_SECTION == 'VARIABLE') )", + fr = "Renseignement des dimensions de fin d'element (variation lineaire entre le debut et la fin)", + DIAM_EXTERN_SORTIE = SIMP(statut='o', + typ='R', + fr = "Diametre exterieur en fin d'element (m)", + ), # end DIAM_EXTERN_SORTIE + DIAM_INTERN_SORTIE = SIMP(statut='o', + typ='R', + fr = "Diametre interieur en fin d'element (m)", + ), # DIAM_INTERN_SORTIE + ), + ), # end SECTION_MASSE + SECTION_RIGIDITE = FACT(statut='f', + fr = "Section a partir de laquelle est determinee la rigidite de l'element poutre", + TYPE_SECTION = SIMP(statut='o', + fr = "Choix d'une section de dimensions constantes ou variables", + typ='TXM', + into=('CONSTANTE','VARIABLE'), + defaut='CONSTANTE', + ), # end TYPE_SECTION + DIAM_EXTERN_DEBUT = SIMP(statut='o', + typ='R', + fr = "Diametre exterieur en debut d'element poutre (m)", + ), # end DIAM_EXTERN_DEBUT + DIAM_INTERN_DEBUT = SIMP(statut='o', + typ='R', + fr = "Diametre interieur en debut d'element poutre (m) (different de 0 si element creux)", + ), # end DIAM_INTERN_DEBUT + PARAMETRE_SECT_VAR = BLOC(condition = "((TYPE_SECTION == 'VARIABLE') )", + fr = "Renseignement des dimensions de fin d'element (variation lineaire entre le debut et la fin)", + DIAM_EXTERN_SORTIE = SIMP(statut='o', + typ='R', + fr = "Diametre exterieur en fin d'element (m)", + ), # end DIAM_EXTERN_SORTIE + DIAM_INTERN_SORTIE = SIMP(statut='o', + typ='R', + fr = "Diametre interieur en fin d'element (m)", + ), # end DIAM_INTERN_SORTIE + ), # end PARAMETRE_SECT_VAR + ), # end SECTION_RIGIDITE + ), # end ELEMENTS + FISSURE = FACT(statut='f', + fr="Description d'une fissure sur un noeud de l'arbre (licite uniquement si les elements poutres a gauche et a droite du noeud ont des sections masse et rigidite constantes)", + MATERIAU = SIMP(statut='o', + typ=Materiau, + fr="Materiau a la position de la fissure (doit avoir ete defini via une entree MATERIAUX)" + ), # end MATERIAU + NOEUD_FISSURE = SIMP(statut='o', + typ='TXM', + fr="Label du noeud ou est positionnee la fissure", + ), # end POSITION_FISSURE + ORIENTATION_FISSURE = SIMP(statut='o', + typ='R', + fr="Angle initial du fond de fissure par rapport à sa définition dans la loi de comportement de fissure (0. par defaut)(degres)", + ), # end ORIENTATION_FISSURE + FICHIER_RAIDEUR = SIMP(statut='o', + typ=('Fichier','Fichier loi de raideur (*.*)'), + fr="Fichier contenant la loi de comportement en raideur de la fissure", + ), # end FICHIER_RAIDEUR + DIAMETRE = SIMP(statut='o', + typ='R', + fr="Diametre du rotor a l'emplacement de la fissure (m)", + ), # end DIAMETRE + ), # end FISSURE + + ) # end ZONE + +############################# PALIERS ######################################## +PALIER = MACRO(nom = 'PALIER', + op = None, + sd_prod = Palier, + reentrant = 'n', + UIinfo = {"groupes":("Machine tournante",)}, + fr = "Description d'un palier radial", + POSITION = SIMP(statut='o', + typ='R', + defaut=0.0, + fr = "Position axiale (absolue) du palier radial (m)", + ), # end POSITION + TYPE_PALIER = SIMP(statut='o', + fr = "Type de palier radial", + typ='TXM', + into=('PALIER LINEAIRE','PALIER NON-LINEAIRE','LAME FLUIDE'), + ), # end TYPE_PALIER + PALIER_LINEAIRE = BLOC(condition = "((TYPE_PALIER == 'PALIER LINEAIRE') )", + fr = "Description d'un palier radial lineaire", + TYPE_SAISIE = SIMP(statut='o', + fr = "Mode de description des caracteristiques du palier radial lineaire", + typ='TXM', + into=('MANUELLE', 'CATALOGUE'), + ), # end TYPE_SAISIE + MANUELLE = BLOC(condition = "((TYPE_SAISIE == 'MANUELLE') )", + fr = "Saisie manuelle des caracteristiques du palier radial lineaire", + CARAC_PALIER = FACT(statut = 'o',max='**',fr = "Caracteristiques du palier par vitesse de rotation de la ligne d'arbres", + VITESSE_ROTATION = SIMP(statut='o', + typ='R', + fr= "Vitesse de rotation (tr/min)", + ), # end VITESSE_ROTATION + SYME = SIMP(statut = 'o', + typ = 'TXM', + max = 1, + fr = "Symetrie des matrices du palier radial lineaire (KXY=KYX et AXY=AYX)", + into = ('OUI','NON'), + defaut = 'OUI', + ), # end SYME + RIGIDITE_NS = BLOC(condition="(SYME=='NON')", + RIGIDITE=FACT(statut='o',fr="Renseignement des caracteristiques non-symetriques de rigidite du palier radial lineaire", + KXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXX dans la matrice de rigidite (N/m)", + ),# end KXX + KXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXY dans la matrice de rigidite (N/m)", + ),# end KXY + KYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYX dans la matrice de rigidite (N/m)", + ),# end KYX + KYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYY dans la matrice de rigidite (N/m)", + ),# end KYY + ), # end RIGIDITE + ), # end RIGIDITE_S + RIGIDITE_S = BLOC(condition="(SYME=='OUI')", + RIGIDITE=FACT(statut='o',fr="Renseignement des caracteristiques symetriques de rigidite du palier radial lineaire", + KXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXX dans la matrice de rigidite (N/m)", + ),# end KXX + KXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXY dans la matrice de rigidite (N/m)", + ),# end KXY + KYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYY dans la matrice de rigidite (N/m)", + ),# end KYY + ), # end RIGIDITE + ), # end RIGIDITE_NS + AMORTISSEMENT_NS = BLOC(condition="(SYME=='NON')", + AMORTISSEMENT=FACT(statut='o',fr="Renseignement des caracteristiques non-symetriques d'amortissement du palier radial lineaire", + AXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXX dans la matrice d'amortissement (N.s/m)", + ),# end AXX + AXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXY dans la matrice d'amortissement (N.s/m)", + ),# end AXY + AYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYX dans la matrice d'amortissement (N.s/m)", + ),# end AYX + AYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYY dans la matrice d'amortissement (N.s/m)", + ),# end AYY + ), # end AMORTISSEMENT + ), # end AMORTISSEMENT_NS + AMORTISSEMENT_S = BLOC(condition="(SYME=='OUI')", + AMORTISSEMENT=FACT(statut='o',fr="Renseignement des caracteristiques symetriques d'amortissement du palier radial lineaire", + AXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXX dans la matrice d'amortissement (N.s/m)", + ),# end AXX + AXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXY dans la matrice d'amortissement (N.s/m)", + ),# end AXY + AYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYY dans la matrice d'amortissement (N.s/m)", + ),# end AYY + ), # end AMORTISSEMENT + ), # end AMORTISSEMENT_S + ), # end CARAC_PALIER + ),# end MANUELLE + CATALOGUE = BLOC(condition = "((TYPE_SAISIE == 'CATALOGUE') )", + fr = "Renseignement des fichiers contenant les caracteristiques du palier radial lineaire", + CATALOGUE_AMORTISSEMENT = SIMP(statut='o', + min=1, + max=1, + typ='Fichier', + fr="Fichier decrivant les caracteristiques d'amortissement (N.s/m) du palier radial lineaire (format decrit dans le Manuel Utilisateur)", + ), # end CATALOGUE_AMORTISSEMENT + CATALOGUE_RIGIDITE = SIMP(statut='o', + min=1, + max=1, + typ='Fichier', + fr="Fichier decrivant les caracteristiques de rigidite (N/m) du palier radial lineaire (format decrit dans le Manuel Utilisateur)", + ), # end CATALOGUE_RIGIDITE + ), # end CATALOGUE + ), # end PALIER_LINEAIRE + LAME_FLUIDE = BLOC(condition = "((TYPE_PALIER == 'LAME FLUIDE') )", + fr = "Description d'une lame fluide", + TYPE_SAISIE = SIMP(statut='o', + fr = "Mode de description des caracteristiques de la lame fluide", + typ='TXM', + defaut = 'MANUELLE', + #into=('MANUELLE', 'CATALOGUE'), #Fonctionnalite catalogue non encore implementee + into=('MANUELLE',), + ), # end TYPE_SAISIE + MANUELLE = BLOC(condition = "((TYPE_SAISIE == 'MANUELLE') )", + fr = "Saisie manuelle des caracteristiques de la lame fluide", + CARAC_PALIER = FACT(statut = 'o',max='**',fr = "Caracteristiques de la lame fluide par vitesse de rotation de la ligne d'arbres", + SYME = SIMP(statut = 'o', + typ = 'TXM', + max = 1, + fr = "Symetrie des matrices de la lame fluide (KXY=KYX et AXY=AYX)", + into = ('OUI','NON'), + defaut = 'OUI', + ), # end SYME + RIGIDITE_NS = BLOC(condition="(SYME=='NON')", + RIGIDITE=FACT(statut='o',fr="Renseignement des caracteristiques non-symetriques de rigidite de la lame fluide", + KXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXX dans la matrice de rigidite (N/m)", + ),# end KXX + KXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXY dans la matrice de rigidite (N/m)", + ),# end KXY + KYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYX dans la matrice de rigidite (N/m)", + ),# end KYX + KYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYY dans la matrice de rigidite (N/m)", + ),# end KYY + ), # end RIGIDITE_NS + RIGIDITE_S = BLOC(condition="(SYME=='OUI')", + RIGIDITE=FACT(statut='o',fr="Renseignement des caracteristiques symetriques de rigidite de la lame fluide", + KXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXX dans la matrice de rigidite (N/m)", + ),# end KXX + KXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXY dans la matrice de rigidite (N/m)", + ),# end KXY + KYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYY dans la matrice de rigidite (N/m)", + ),# end KYY + ), # end RIGIDITE + ), # end RIGIDITE_S + AMORTISSEMENT_NS = BLOC(condition="(SYME=='NON')", + AMORTISSEMENT=FACT(statut='o',fr="Renseignement des caracteristiques non-symetriques d'amortissement de la lame fluide", + AXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXX dans la matrice d'amortissement (N.s/m)", + ),# end AXX + AXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXY dans la matrice d'amortissement (N.s/m)", + ),# end AXY + AYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYX dans la matrice d'amortissement (N.s/m)", + ),# end AYX + AYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYY dans la matrice d'amortissement (N.s/m)", + ),# end AYY + ), # end AMORTISSEMENT + ), # end AMORTISSEMENT + ), # end AMORTISSEMENT_NS + AMORTISSEMENT_S = BLOC(condition="(SYME=='OUI')", + AMORTISSEMENT=FACT(statut='o',fr="Renseignement des caracteristiques symetriques d'amortissement de la lame fluide", + AXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXX dans la matrice d'amortissement (N.s/m)", + ),# end AXX + AXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXY dans la matrice d'amortissement (N.s/m)", + ),# end AXY + AYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYY dans la matrice d'amortissement (N.s/m)", + ),# end AYY + ), # end AMORTISSEMENT + ), # end AMORTISSEMENT_S + MASSE_NS = BLOC(condition="(SYME=='NON')", + MASSE=FACT(statut='o',fr="Renseignement des caracteristiques non symetriques de masse de la lame fluide", + MXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MXX dans la matrice de masse (kg)", + ),# end MXX + MXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MXY dans la matrice de masse (kg)", + ),# end MXY + MYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MYX dans la matrice de masse (kg)", + ),# end MYX + MYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MYY dans la matrice de masse (kg)", + ),# end MYY + ), # end MASSE + ), # end MASSE_NS + MASSE_S = BLOC(condition="(SYME=='OUI')", + MASSE=FACT(statut='o',fr="Renseignement des caracteristiques symetriques de masse de la lame fluide", + MXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MXX dans la matrice de masse (kg)", + ),# end MXX + MXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MXY dans la matrice de masse (kg)", + ),# end MXY + MYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MYY dans la matrice de masse (kg)", + ),# end MYY + ), # end MASSE + ), # end MASSE_S + VITESSE_ROTATION = SIMP(statut='o', + typ='R', + fr= "Vitesse de rotation (tr/min)", + ), # end VITESSE_ROTATION + ), # end CARAC_PALIER + ), # end MANUELLE + #Fonctionnalite non encore implementee + CATALOGUE = BLOC(condition = "((TYPE_SAISIE == 'CATALOGUE') )", + PALIERS_CATALOGUE = SIMP(statut='o', + min=1, + max=1, + typ='Fichier', + fr="Format du fichier : CSV.", + ), # end PALIERS_CATALOGUE + ), # end CATALOGUE + + ), # end LAME_FLUIDE + PALIER_NON_LINEAIRE = BLOC(condition = "((TYPE_PALIER == 'PALIER NON-LINEAIRE') )", + fr = "Description d'un palier non-lineaire (licite uniquement en cas d'analyse de type 'TRANSITOIRE ACCIDENTEL'", + TYPE = SIMP(statut='o', + typ='TXM', + into=('PAPANL','PAFINL','PAHYNL','PACONL'), + defaut=None, + fr="Type de palier non-lineaire parmi ceux proposes dans Edyos", + ), # end TYPE + REPERTOIRE_EDYOS = SIMP(statut='o', + typ=('Repertoire'), + defaut=None, + fr="Repertoire 'CDC' du palier non-lineaire utilise (les fichiers Geometrie et Donnees doivent exister dans les repertoires parents respectivement de niveau 2 et 1 de CDC)", + ), # end REPERTOIRE_EDYOS + ), # end PALIER_NON_LINEAIRE + ) # end PALIER + +PALIER_TORSION=MACRO(nom="PALIER_TORSION", + op=None, + sd_prod=PalTor, + reentrant='n', + UIinfo={"groupes":("Machine tournante",)}, + fr="Description d'un palier de torsion", + POSITION = SIMP(statut='o',typ='R',defaut=0.0,fr = "Position axiale (absolue) du palier de torsion (m)",), # end POSITION + TYPE_SAISIE = SIMP(statut='o',typ='TXM',into=('MANUELLE',),fr = "Mode de description des caracteristiques du palier de torsion",), # end TYPE_SAISIE + MANUELLE = BLOC(condition = "((TYPE_SAISIE == 'MANUELLE') )", + fr = "Saisie manuelle des caracteristiques du palier de torsion", + CARAC_PALIER = FACT(statut = 'o',max=1,fr = "Caracteristiques du palier par vitesse de rotation de l'arbre", + VITESSE_ROTATION = SIMP(statut='o',typ='R',min=1,max='**',fr= "Liste des vitesses de rotation (tr/min)",), # end VITESSE_ROTATION + KRZ = SIMP(statut = 'o',typ = 'R',min=1,max = '**',fr = "Liste des caracteristiques de rigidite (N/m) du palier de torsion en fonction de la vitesse de rotation",),# end KRZ + ARZ = SIMP(statut = 'o',typ = 'R',min=1,max = '**',fr = "Liste des caracteristiques d'amortissement (N.s/m) du palier de torsion en fonction de la vitesse de rotation",),# end ARZ + MRZ = SIMP(statut = 'f',typ = 'R',min=1,max = '**',fr = "Liste des caracteristiques de masse ajoutee (kg) du palier de torsion en fonction de la vitesse de rotation",),# end MRZ + ),#end CARAC_PALIER + ), # end MANUELLE + #Fonctionnalite pas encore implementee + CATALOGUE = BLOC(condition = "((TYPE_SAISIE == 'CATALOGUE') )", + fr = "Renseignement des fichiers contenant les caracteristiques du palier de torsion", + CATA_PALIER = SIMP(statut='o',min=1,max=1,typ='Fichier',fr="Format du fichier : CSV.",), # end CATA_PALIER + ), # end CATALOGUE + )#end PALIER TORSION + +BUTEE=MACRO(nom="BUTEE", + op=None, + sd_prod=Butee, + reentrant='n', + UIinfo={"groupes":("Machine tournante",)}, + fr="Description d'une butee", + POSITION = SIMP(statut='o',typ='R',defaut=0.0,fr = "Position axiale (absolue) de la butee (m)",), # end POSITION + TYPE_BUTEE = SIMP(statut='o',typ='TXM',into=('BUTEE LINEAIRE',),fr = "Type de butee",), # end TYPE_BUTEE, BUTEE NON LINEAIRE reintegrable + BUTEE_LINEAIRE=BLOC(condition="TYPE_BUTEE=='BUTEE LINEAIRE'", + fr = "Description d'une butee lineaire", + TYPE_SAISIE = SIMP(statut='o',typ='TXM',into=('MANUELLE',),fr = "Mode de description des caracteristiques de la butee lineaire",), # end TYPE_SAISIE; 'CATALOGUE' reintegrable + MANUELLE=BLOC(condition="TYPE_SAISIE=='MANUELLE'", + fr = "Saisie manuelle des caracteristiques de la butee lineaire", + CARAC_BUTEE=FACT(statut='o',max=1,fr="Caracteristiques de la butee en fonction de la vitesse de rotation", + VITESSE_ROTATION=SIMP(statut='o',typ='R',min=1,max='**',fr="Liste des vitesses de rotation (tr/min)",), + SYMETRIQUE=SIMP(statut='o',typ='TXM',min=1,max=1,into=("OUI","NON"),defaut="OUI",fr="Symetrie des matrices de la butee (KRXRY=KRYRX , ARXRY=ARYRX et MRXRY=MRYRX)",), + + RIGIDITE_NS = BLOC(condition="(SYMETRIQUE=='NON')", + RIGIDITE=FACT(statut='o',max=1,fr="Caracteristiques non-symetriques de rigidite de la butee lineaire en fonction de la vitesse de rotation", + KZZ=SIMP(statut='o',typ='R',min=1,max='**',fr="Rigidite axiale (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + KRXRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Rigidite directe de rotation autour de l'axe X (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + KRXRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Rigidite croisee de rotation autour de l'axe X (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + KRYRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Rigidite croisee de rotation autour de l'axe Y (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + KRYRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Rigidite directe de rotation autour de l'axe Y (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + ), #END RIGIDITE + ),#END RIGIDITE_NS + RIGIDITE_S = BLOC(condition="(SYMETRIQUE=='OUI')", + RIGIDITE=FACT(statut='o',max=1,fr="Caracteristiques symetriques de rigidite de la butee lineaire en fonction de la vitesse de rotation", + KZZ=SIMP(statut='o',typ='R',min=1,max='**',fr="Rigidite axiale (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + KRXRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Rigidite directe de rotation autour de l'axe X (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + KRXRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Rigidite croisee de rotation autour de l'axe X (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + KRYRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Rigidite directe de rotation autour de l'axe Y (N/m) de la butee lineaire en fonction de la vitesse de rotation"), + ), #END RIGIDITE + ),#END RIGIDITE_S + + AMORTISSEMENT_NS = BLOC(condition="(SYMETRIQUE=='NON')", + AMORTISSEMENT=FACT(statut='o',max=1,fr="Caracteristiques non-symetriques d'amortissement de la butee lineaire en fonction de la vitesse de rotation", + AZZ=SIMP(statut='o',typ='R',min=1,max='**',fr="Amortissement axial (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ARXRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Amortissement direct de rotation autour de l'axe X (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ARXRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Amortissement croise de rotation autour de l'axe X (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ARYRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Amortissement croise de rotation autour de l'axe Y (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ARYRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Amortissement croise de rotation autour de l'axe Y (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ),#END AMORTISSEMENT + ),#END AMORTISSEMENT_NS + AMORTISSEMENT_S = BLOC(condition="(SYMETRIQUE=='OUI')", + AMORTISSEMENT=FACT(statut='o',max=1,fr="Caracteristiques symetriques d'amortissement de la butee lineaire en fonction de la vitesse de rotation", + AZZ=SIMP(statut='o',typ='R',min=1,max='**',fr="Amortissement axial (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ARXRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Amortissement direct de rotation autour de l'axe X (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ARXRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Amortissement croise de rotation autour de l'axe X (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ARYRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Amortissement croise de rotation autour de l'axe Y (N.s/m) de la butee lineaire en fonction de la vitesse de rotation"), + ),#END AMORTISSEMENT + ),#END AMORTISSEMENT_S + + INERTIE_NS = BLOC(condition="(SYMETRIQUE=='NON')", + INERTIE=FACT(statut='f',max=1,fr="Caracteristiques non-symetriques de masse ajoutee de la butee lineaire en fonction de la vitesse de rotation", + MZZ=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee axiale (kg) de la butee lineaire en fonction de la vitesse de rotation"), + MRXRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee directe de rotation autour de l'axe X (kg) de la butee lineaire en fonction de la vitesse de rotation"), + MRXRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee croisee de rotation autour de l'axe X (kg) de la butee lineaire en fonction de la vitesse de rotation"), + MRYRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee croisee de rotation autour de l'axe Y (kg) de la butee lineaire en fonction de la vitesse de rotation"), + MRYRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee croisee de rotation autour de l'axe Y (kg) de la butee lineaire en fonction de la vitesse de rotation"), + ),#END INERTIE + ),#END INERTIE_NS + INERTIE_S = BLOC(condition="(SYMETRIQUE=='OUI')", + INERTIE=FACT(statut='f',max=1,fr="Caracteristiques symetriques de masse ajoutee de la butee lineaire en fonction de la vitesse de rotation", + MZZ=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee axiale (kg) de la butee lineaire en fonction de la vitesse de rotation"), + MRXRX=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee directe de rotation autour de l'axe X (kg) de la butee lineaire en fonction de la vitesse de rotation"), + MRXRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee croisee de rotation autour de l'axe X (kg) de la butee lineaire en fonction de la vitesse de rotation"), + MRYRY=SIMP(statut='f',typ='R',min=1,max='**',fr="Masse ajoutee croisee de rotation autour de l'axe Y (kg) de la butee lineaire en fonction de la vitesse de rotation"), + ),#END INERTIE + ),#END INERTIE_S + + ),#END CARA_BUTEE + ),#end MANUELLE + CATALOGUE=BLOC(condition="TYPE_SAISIE=='CATALOGUE'", + fr = "Renseignement des fichiers contenant les caracteristiques de la butee lineaire", + ),#END CATALOGUE + ),#END BUTEE LINEAIRE + + BUTEE_NON_LINEAIRE=BLOC(condition="TYPE_BUTEE=='BUTEE NON LINEAIRE'", + fr = "Description d'une butee non-lineaire", + ),#END BUTEE NON LINEAIRE + + );#END BUTEE + +############################# SUPPORT ######################################## +SUPPORT = MACRO(nom = "SUPPORT", + op = None, + sd_prod = Support, + reentrant = 'n', + UIinfo = {"groupes":("Machine tournante",)}, + fr = "Description d'un support ", + TYPE_SUPPORT = SIMP(statut='o', + fr = "Type de support", + typ='TXM', + defaut="RIGIDE", + into=("RIGIDE", "SIMPLIFIE", "GENERALISE", ), + ), # end TYPE_SUPPORT + SIMPLIFIE = BLOC(condition = "((TYPE_SUPPORT == 'SIMPLIFIE') )", + fr = "Description d'un support simplifie", + RIGIDITE = FACT(statut='o', fr = "Renseignement des caracteristiques de rigidite du support simplifie", + KXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXX dans la matrice de rigidite (N/m)", + ),# end KXX + KXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KXY dans la matrice de rigidite (N/m)", + ),# end KXY + KYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYX dans la matrice de rigidite (N/m)", + ),# end KYX + KYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de KYY dans la matrice de rigidite (N/m)", + ),# end KYY + ), # end RIGIDITE + AMORTISSEMENT = FACT(statut='o', fr= "Renseignement des caracteristiques d'amortissement du support simplifie", + AXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXX dans la matrice d'amortissement (N.s/m)", + ),# end AXX + AXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AXY dans la matrice d'amortissement (N.s/m)", + ),# end AXY + AYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYX dans la matrice d'amortissement (N.s/m)", + ),# end AYX + AYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de AYY dans la matrice d'amortissement (N.s/m)", + ),# end AYY + ), # end AMORTISSEMENT + MASSE = FACT(statut='o', fr= "Renseignement des caracteristiques de masse du support simplifie", + MXX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MXX dans la matrice de masse (kg)", + ),# end MXX + MXY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MXY dans la matrice de masse (kg)", + ),# end MXY + MYX = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MYX dans la matrice de masse (kg)", + ),# end MYX + MYY = SIMP(statut = 'o', + typ = 'R', + max = 1, + fr = "Valeur de MYY dans la matrice de masse (kg)", + ),# end MYY + ), # end MASSE + ), # end SIMPLIFIE + GENERALISE = BLOC(condition = "((TYPE_SUPPORT == 'GENERALISE') )", + fr = "Description d'un support generalise", + ANGL_NAUT = SIMP(statut='f', + fr="Rotation du modele du support generalise a effectuer pour coincider avec le repere de la ligne d'arbres (rotation autour de X, puis Y, puis Z (degres))", + typ='R', + min=3,max=3, + ), # end ANGL_NAUT + TRANS = SIMP(statut='f', + fr="Translation du modele du support generalise a effectuer pour que ses noeuds de connexion soient confondus avec ceux de la ligne d'arbres (translation suivant X, Y et Z (m))", + typ='R', + min=3,max=3, + ), # end TRANS + MAIL_TDG = SIMP(statut='o', + fr="Fichier du maillage du support generalise", + typ=("Fichier","Fichier maillage TdG (*.*)"), + min=1,max=1, + ), # end MAIL_TDG + COMM_TDG = SIMP(statut='o', + fr="Fichier de la mise en donnees du support generalise", + typ=("Fichier","Fichier commande TdG (*.*)"), + min=1,max=1, + ), # end COMM_TDG + NOM_MACRO_ELEMENT_DYNAMIQUE = SIMP(statut='o', + fr="Nom du macro element dynamique cree pour le support generalise", + typ='TXM', + min=1,max=1, + ), # end NOM_MACRO_ELEMENT_DYNAMIQUE + NOM_INTERFACE = SIMP(statut='o', + fr="Nom de l'interface cree pour le support generalise", + typ='TXM', + min=1,max=1, + ), # end NOM_INTERFACE + NOM_GROUP_MA_MASSIF = SIMP(statut='o', + fr="Nom du groupe de maille representant le support generalise", + typ='TXM', + min=1,max=1, + ), # end NOM_GROUP_MA_MASSIF + REDUIT = SIMP(statut='f', + fr="Introduction du mot-cle REDUIT pour le cas ou le nombre d'interfaces n'est pas identique entre le support generalise et la ligne d'arbres", + typ='TXM', + into=("OUI",), + defaut="OUI", + ), # end REDUIT + ), # end GENERALISE + ) # end SUPPORT + +############################# LIGNE_ARBRE ######################################## +LIGNE_ARBRE = MACRO(nom = 'LIGNE_ARBRE', + op = None, + sd_prod = LigneArbre, + reentrant = 'n', + UIinfo = {"groupes":("Machine tournante",)}, + fr = "Description de la ligne d'arbres", + DIRECTION = SIMP(statut='o', + fr = "Direction de la ligne d'arbres consideree (choisir une des entrees DIRECTION creees)", + typ=Direction, + min=1, + max=1, + ), # end DIRECTION + ZONES = SIMP(statut='o', + fr = "Zone(s) composant la ligne d'arbres (choisir, en faisant attention a l'ordre, parmi les entrees ZONE creees)", + typ=Zone, + min=1, + max='**', + ), # end ZONES + PALIERS = SIMP(statut='o', + fr = "Paliers supportant la ligne d'arbres (choisir, en faisant attention a l'ordre, parmi les entrees PALIER creees)", + typ=Palier, + min=2, + max='**', + ), # end PALIERS + + BUTEES = SIMP(statut='f', + fr = "Butee(s) guidant axialement la ligne d'arbres (choisir, en faisant attention a l'ordre, parmi les entrees BUTEES creees)", + typ=Butee, + max='**' + ),#end BUTEE + PALIERS_TORSION=SIMP(statut='f', + fr = "Palier(s) de torsion de la ligne d'arbres (choisir, en faisant attention a l'ordre, parmi les entrees PALIERS_TORSION creees)", + typ=PalTor, + max='**' + ),#end PALIERS_TORSION + SUPPORTS = SIMP(statut='o', + fr = "Supports sous les paliers (choisir, en faisant attention a l'ordre, parmi les entrees SUPPORTS creees)", + typ=Support, + min=1, + max='**', + ), # end SUPPORTS + ) # end LIGNE_ARBRE + diff --git a/MT/mesScripts_MT.py b/MT/mesScripts_MT.py index 30d46079..010ea2d6 100644 --- a/MT/mesScripts_MT.py +++ b/MT/mesScripts_MT.py @@ -45,11 +45,12 @@ def import_zone(listeparam): #print editor.updateJdc #editor.updateJdc(itemWidget,txt) - editor.updateJdcEtape(itemWidget,texte) + retour = editor.updateJdcEtape(itemWidget,texte) + if retour : - oldItem=itemParent.children[index] - oldItem.select() - oldItem.supprimeNoeud() + oldItem=itemParent.children[index] + oldItem.select() + oldItem.supprimeNoeud() # le dictionnaire des commandes a la structure suivante : diff --git a/MT/opsOT.py b/MT/opsOT.py deleted file mode 100644 index e2af4083..00000000 --- a/MT/opsOT.py +++ /dev/null @@ -1,20 +0,0 @@ -# -*- coding: iso-8859-1 -*- - -def INCLUDE(self,FileName,**args): - """ - Fonction sd_prod pour la macro INCLUDE - """ - if hasattr(self,'change_fichier'): - delattr(self,'change_fichier') - delattr(self,'fichier_ini') - - self.make_include2(fichier=FileName) - -def INCLUDE_context(self,d): - """ - Fonction op_init pour macro INCLUDE - """ - for k,v in self.g_context.items(): - d[k]=v - - diff --git a/MT/reecrit_comm.py_VOprofile.py b/MT/reecrit_comm.py_VOprofile.py new file mode 100755 index 00000000..2ea327f2 --- /dev/null +++ b/MT/reecrit_comm.py_VOprofile.py @@ -0,0 +1,58 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +# CONFIGURATION MANAGEMENT OF EDF VERSION +# ====================================================================== +# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG +# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY +# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY +# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR +# (AT YOUR OPTION) ANY LATER VERSION. +# +# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT +# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF +# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU +# GENERAL PUBLIC LICENSE FOR MORE DETAILS. +# +# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE +# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER, +# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE. +# +# +# ====================================================================== + +""" +""" +# Modules Python +from __future__ import absolute_import + +import sys,os + +# Modules Eficas +import prefs +if hasattr(prefs,'encoding'): + # Hack pour changer le codage par defaut des strings + import sys + reload(sys) + sys.setdefaultencoding(prefs.encoding) + del sys.setdefaultencoding + # Fin hack + + +sys.path.append(os.path.join(os.path.abspath(os.path.dirname(__file__)),'..')) +from InterfaceQT4 import eficas_go + +from PyQt5.QtWidgets import QApplication +app = QApplication(sys.argv) +# on veut ouvrir un fichier directement au lancement d'Eficas + + +import cProfile, pstats, StringIO +pr = cProfile.Profile() +pr.enable() +eficas_go.lance_eficas_ssIhm_reecrit(code='MT',fichier = 'gros_modele_MT.comm',ou = 'toto',cr=True) +pr.disable() +s = StringIO.StringIO() +sortby = 'cumulative' +ps = pstats.Stats(pr, stream=s).sort_stats(sortby) +ps.print_stats() +print s.getvalue() diff --git a/MT/sdll124a.machine b/MT/sdll124a.machine new file mode 100644 index 00000000..ecc40046 --- /dev/null +++ b/MT/sdll124a.machine @@ -0,0 +1,207 @@ + +DIRE=DIRECTION(AXE='HORIZONTAL',); + +MAT=MATERIAUX(TYPE_INTRO='MANUELLE', + RHO=7800.0, + E=2e+11, + NU=0.3,); + +P1=PALIER(POSITION=0.0, + TYPE_PALIER='PALIER LINEAIRE', + TYPE_SAISIE='MANUELLE', + CARAC_PALIER=( + _F(VITESSE_ROTATION=0.0, + SYME='NON', + RIGIDITE=_F(KXX=70000000.0, + KXY=0.0, + KYX=0.0, + KYY=50000000.0,), + AMORTISSEMENT=_F(AXX=700.0, + AXY=0.0, + AYX=0.0, + AYY=500.0,),), + _F(VITESSE_ROTATION=None, + SYME='OUI', + RIGIDITE=_F(KXX=None, + KXY=None, + KYY=None,), + AMORTISSEMENT=_F(AXX=None, + AXY=None, + AYY=None,),),),); + +P2=PALIER(POSITION=1.3, + TYPE_PALIER='PALIER LINEAIRE', + TYPE_SAISIE='MANUELLE', + CARAC_PALIER=_F(VITESSE_ROTATION=0.0, + SYME='NON', + RIGIDITE=_F(KXX=70000000.0, + KXY=0.0, + KYX=0.0, + KYY=50000000.0,), + AMORTISSEMENT=_F(AXX=700.0, + AXY=0.0, + AYX=0.0, + AYY=500.0,),),); + +Z=ZONE(MASSE=(_F(NOEUD='N3', + TYPE_MASSE='DISQUE', + TYPE_SAISIE='GEOMETRIQUE', + PARAMETRES=_F(DIAMETRE_EXT=0.24, + DIAMETRE_INT=0.1, + EPAISSEUR=0.05, + MATERIAU=MAT,),), + _F(NOEUD='N6', + TYPE_MASSE='DISQUE', + TYPE_SAISIE='GEOMETRIQUE', + PARAMETRES=_F(DIAMETRE_EXT=0.4, + DIAMETRE_INT=0.1, + EPAISSEUR=0.05, + MATERIAU=MAT,),), + _F(NOEUD='N11', + TYPE_MASSE='DISQUE', + TYPE_SAISIE='GEOMETRIQUE', + PARAMETRES=_F(DIAMETRE_EXT=0.4, + DIAMETRE_INT=0.1, + EPAISSEUR=0.06, + MATERIAU=MAT,),),), + NOEUDS=(_F(NOM='N1', + POSITION_AXIALE=0.0,), + _F(NOM='N2', + POSITION_AXIALE=0.0,), + _F(NOM='N3', + POSITION_AXIALE=0.0,), + _F(NOM='N4', + POSITION_AXIALE=0.0,), + _F(NOM='N5', + POSITION_AXIALE=0.0,), + _F(NOM='N6', + POSITION_AXIALE=0.0,), + _F(NOM='N7', + POSITION_AXIALE=0.0,), + _F(NOM='N8', + POSITION_AXIALE=0.0,), + _F(NOM='N9', + POSITION_AXIALE=0.0,), + _F(NOM='N10', + POSITION_AXIALE=0.0,), + _F(NOM='N11', + POSITION_AXIALE=0.0,), + _F(NOM='N12', + POSITION_AXIALE=0.0,), + _F(NOM='N13', + POSITION_AXIALE=0.0,), + _F(NOM='N14', + POSITION_AXIALE=0.0,),), + ELEMENTS=(_F(NOM='E1', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E2', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E3', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E4', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E5', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E6', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E7', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E8', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E9', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E10', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E11', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E12', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),), + _F(NOM='E13', + NOEUD_DEBUT=None, + NOEUD_FIN=None, + RAFFINEMENT='NON', + MATERIAU=MAT, + SECTION_MASSE=_F(TYPE_SECTION='CONSTANTE', + DIAM_EXTERN_DEBUT=0.1, + DIAM_INTERN_DEBUT=0.0,),),),); + +SUPP=SUPPORT(TYPE_SUPPORT='RIGIDE',); + +LA=LIGNE_ARBRE(DIRECTION=DIRE, + ZONES=Z, + PALIERS=(P1,P2,), + SUPPORTS=SUPP,); +#VERSION_CATALOGUE:2016.0.0:FIN VERSION_CATALOGUE +#CHECKSUM:285dfc315d1960bb4f61ff9617312f36 -:FIN CHECKSUM \ No newline at end of file diff --git a/MT/txtZone.py b/MT/txtZone.py new file mode 100644 index 00000000..89f4204f --- /dev/null +++ b/MT/txtZone.py @@ -0,0 +1,227 @@ +texte="ZONE(NOEUDS=(_F(NOM='N1',POSITION_AXIALE=0.0,),\ + _F(NOM='N2',POSITION_AXIALE=0.1,),\ + _F(NOM='N3',POSITION_AXIALE=0.2,),\ + _F(NOM='N4',POSITION_AXIALE=0.3,),\ + _F(NOM='N5',POSITION_AXIALE=0.4,),\ + _F(NOM='N6',POSITION_AXIALE=0.5,),\ + _F(NOM='N7',POSITION_AXIALE=0.6,),\ + _F(NOM='N8',POSITION_AXIALE=0.7,),\ + _F(NOM='N9',POSITION_AXIALE=0.8,),\ + _F(NOM='N10',POSITION_AXIALE=0.9,),\ + _F(NOM='N11',POSITION_AXIALE=1.0,),\ + _F(NOM='N12',POSITION_AXIALE=1.1,),\ + _F(NOM='N13',POSITION_AXIALE=1.2,),\ + _F(NOM='N14',POSITION_AXIALE=1.3,),\ +),\ + ELEMENTS=(_F(NOM='E1',\ + NOEUD_DEBUT='N1',\ + NOEUD_FIN='N2',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E2',\ + NOEUD_DEBUT='N2',\ + NOEUD_FIN='N3',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E3',\ + NOEUD_DEBUT='N3',\ + NOEUD_FIN='N4',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E4',\ + NOEUD_DEBUT='N4',\ + NOEUD_FIN='N5',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E5',\ + NOEUD_DEBUT='N5',\ + NOEUD_FIN='N6',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E6',\ + NOEUD_DEBUT='N6',\ + NOEUD_FIN='N7',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E7',\ + NOEUD_DEBUT='N7',\ + NOEUD_FIN='N8',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.05,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.05,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.05,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.05,),),\ + _F(NOM='E8',\ + NOEUD_DEBUT='N8',\ + NOEUD_FIN='N9',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E9',\ + NOEUD_DEBUT='N9',\ + NOEUD_FIN='N10',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E10',\ + NOEUD_DEBUT='N10',\ + NOEUD_FIN='N11',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E11',\ + NOEUD_DEBUT='N11',\ + NOEUD_FIN='N12',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E12',\ + NOEUD_DEBUT='N12',\ + NOEUD_FIN='N13',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E13',\ + NOEUD_DEBUT='N13',\ + NOEUD_FIN='N14',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ +),\ + MASSE=(_F(NOEUD='N5',\ + TYPE_MASSE='AILETTE',\ + TYPE_SAISIE='MECANIQUE',\ + PARAMETRES=_F(MASSE=1.3,\ + INERTIEX=0.1,\ + INERTIEY=0.1,\ + INERTIEZ=0.05,),),\ + _F(NOEUD='N8',\ + TYPE_MASSE='QUELCONQUE',\ + PARAMETRES=_F(MASSE=1.2,\ + INERTIEX=0.0,\ + INERTIEY=0.0,\ + INERTIEZ=0.0,),),\ +),\ +),\ +" diff --git a/MT/txtZonePN.py b/MT/txtZonePN.py new file mode 100644 index 00000000..89f4204f --- /dev/null +++ b/MT/txtZonePN.py @@ -0,0 +1,227 @@ +texte="ZONE(NOEUDS=(_F(NOM='N1',POSITION_AXIALE=0.0,),\ + _F(NOM='N2',POSITION_AXIALE=0.1,),\ + _F(NOM='N3',POSITION_AXIALE=0.2,),\ + _F(NOM='N4',POSITION_AXIALE=0.3,),\ + _F(NOM='N5',POSITION_AXIALE=0.4,),\ + _F(NOM='N6',POSITION_AXIALE=0.5,),\ + _F(NOM='N7',POSITION_AXIALE=0.6,),\ + _F(NOM='N8',POSITION_AXIALE=0.7,),\ + _F(NOM='N9',POSITION_AXIALE=0.8,),\ + _F(NOM='N10',POSITION_AXIALE=0.9,),\ + _F(NOM='N11',POSITION_AXIALE=1.0,),\ + _F(NOM='N12',POSITION_AXIALE=1.1,),\ + _F(NOM='N13',POSITION_AXIALE=1.2,),\ + _F(NOM='N14',POSITION_AXIALE=1.3,),\ +),\ + ELEMENTS=(_F(NOM='E1',\ + NOEUD_DEBUT='N1',\ + NOEUD_FIN='N2',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E2',\ + NOEUD_DEBUT='N2',\ + NOEUD_FIN='N3',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E3',\ + NOEUD_DEBUT='N3',\ + NOEUD_FIN='N4',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E4',\ + NOEUD_DEBUT='N4',\ + NOEUD_FIN='N5',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E5',\ + NOEUD_DEBUT='N5',\ + NOEUD_FIN='N6',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E6',\ + NOEUD_DEBUT='N6',\ + NOEUD_FIN='N7',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E7',\ + NOEUD_DEBUT='N7',\ + NOEUD_FIN='N8',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.05,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.05,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.05,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.05,),),\ + _F(NOM='E8',\ + NOEUD_DEBUT='N8',\ + NOEUD_FIN='N9',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E9',\ + NOEUD_DEBUT='N9',\ + NOEUD_FIN='N10',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E10',\ + NOEUD_DEBUT='N10',\ + NOEUD_FIN='N11',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E11',\ + NOEUD_DEBUT='N11',\ + NOEUD_FIN='N12',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E12',\ + NOEUD_DEBUT='N12',\ + NOEUD_FIN='N13',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ + _F(NOM='E13',\ + NOEUD_DEBUT='N13',\ + NOEUD_FIN='N14',\ + RAFFINEMENT='NON',\ + MATERIAU=MAT,\ + SECTION_MASSE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.1,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.1,\ + DIAM_INTERN_SORTIE=0.0,),\ + SECTION_RIGIDITE=_F(TYPE_SECTION='VARIABLE',\ + DIAM_EXTERN_DEBUT=0.11,\ + DIAM_INTERN_DEBUT=0.0,\ + DIAM_EXTERN_SORTIE=0.11,\ + DIAM_INTERN_SORTIE=0.0,),),\ +),\ + MASSE=(_F(NOEUD='N5',\ + TYPE_MASSE='AILETTE',\ + TYPE_SAISIE='MECANIQUE',\ + PARAMETRES=_F(MASSE=1.3,\ + INERTIEX=0.1,\ + INERTIEY=0.1,\ + INERTIEZ=0.05,),),\ + _F(NOEUD='N8',\ + TYPE_MASSE='QUELCONQUE',\ + PARAMETRES=_F(MASSE=1.2,\ + INERTIEX=0.0,\ + INERTIEY=0.0,\ + INERTIEZ=0.0,),),\ +),\ +),\ +" diff --git a/Aster/CMakeLists.txt b/OldCodes/Aster/CMakeLists.txt similarity index 100% rename from Aster/CMakeLists.txt rename to OldCodes/Aster/CMakeLists.txt diff --git a/Aster/Cata/CMakeLists.txt b/OldCodes/Aster/Cata/CMakeLists.txt similarity index 100% rename from Aster/Cata/CMakeLists.txt rename to OldCodes/Aster/Cata/CMakeLists.txt diff --git a/Aster/Cata/__init__.py b/OldCodes/Aster/Cata/__init__.py similarity index 100% rename from Aster/Cata/__init__.py rename to OldCodes/Aster/Cata/__init__.py diff --git a/Aster/Cata/cataSTA11/__init__.py b/OldCodes/Aster/Cata/cataSTA11/__init__.py similarity index 100% rename from Aster/Cata/cataSTA11/__init__.py rename to OldCodes/Aster/Cata/cataSTA11/__init__.py diff --git a/Aster/Cata/cataSTA11/cata.py b/OldCodes/Aster/Cata/cataSTA11/cata.py similarity index 100% rename from Aster/Cata/cataSTA11/cata.py rename to OldCodes/Aster/Cata/cataSTA11/cata.py diff --git a/Aster/Cata/cataSTA11/ops.py b/OldCodes/Aster/Cata/cataSTA11/ops.py similarity index 100% rename from Aster/Cata/cataSTA11/ops.py rename to OldCodes/Aster/Cata/cataSTA11/ops.py diff --git a/Aster/INSTALL b/OldCodes/Aster/INSTALL similarity index 100% rename from Aster/INSTALL rename to OldCodes/Aster/INSTALL diff --git a/Aster/Include.com b/OldCodes/Aster/Include.com similarity index 100% rename from Aster/Include.com rename to OldCodes/Aster/Include.com diff --git a/Aster/LICENSE.TERMS b/OldCodes/Aster/LICENSE.TERMS similarity index 100% rename from Aster/LICENSE.TERMS rename to OldCodes/Aster/LICENSE.TERMS diff --git a/Aster/NEWS b/OldCodes/Aster/NEWS similarity index 100% rename from Aster/NEWS rename to OldCodes/Aster/NEWS diff --git a/Aster/README b/OldCodes/Aster/README similarity index 100% rename from Aster/README rename to OldCodes/Aster/README diff --git a/Aster/Tests/README b/OldCodes/Aster/Tests/README similarity index 100% rename from Aster/Tests/README rename to OldCodes/Aster/Tests/README diff --git a/Aster/Tests/Recette/az.comm b/OldCodes/Aster/Tests/Recette/az.comm similarity index 100% rename from Aster/Tests/Recette/az.comm rename to OldCodes/Aster/Tests/Recette/az.comm diff --git a/Aster/Tests/Recette/efica01a.11 b/OldCodes/Aster/Tests/Recette/efica01a.11 similarity index 100% rename from Aster/Tests/Recette/efica01a.11 rename to OldCodes/Aster/Tests/Recette/efica01a.11 diff --git a/Aster/Tests/Recette/efica01a.com0 b/OldCodes/Aster/Tests/Recette/efica01a.com0 similarity index 100% rename from Aster/Tests/Recette/efica01a.com0 rename to OldCodes/Aster/Tests/Recette/efica01a.com0 diff --git a/Aster/Tests/Recette/efica01a.comm b/OldCodes/Aster/Tests/Recette/efica01a.comm similarity index 100% rename from Aster/Tests/Recette/efica01a.comm rename to OldCodes/Aster/Tests/Recette/efica01a.comm diff --git a/Aster/Tests/d0.comm b/OldCodes/Aster/Tests/d0.comm similarity index 100% rename from Aster/Tests/d0.comm rename to OldCodes/Aster/Tests/d0.comm diff --git a/Aster/Tests/err.comm b/OldCodes/Aster/Tests/err.comm similarity index 100% rename from Aster/Tests/err.comm rename to OldCodes/Aster/Tests/err.comm diff --git a/Aster/Tests/err2.comm b/OldCodes/Aster/Tests/err2.comm similarity index 100% rename from Aster/Tests/err2.comm rename to OldCodes/Aster/Tests/err2.comm diff --git a/Aster/Tests/err3.comm b/OldCodes/Aster/Tests/err3.comm similarity index 100% rename from Aster/Tests/err3.comm rename to OldCodes/Aster/Tests/err3.comm diff --git a/Aster/Tests/incl.11 b/OldCodes/Aster/Tests/incl.11 similarity index 100% rename from Aster/Tests/incl.11 rename to OldCodes/Aster/Tests/incl.11 diff --git a/Aster/Tests/incl.12 b/OldCodes/Aster/Tests/incl.12 similarity index 100% rename from Aster/Tests/incl.12 rename to OldCodes/Aster/Tests/incl.12 diff --git a/Aster/Tests/incl.13 b/OldCodes/Aster/Tests/incl.13 similarity index 100% rename from Aster/Tests/incl.13 rename to OldCodes/Aster/Tests/incl.13 diff --git a/Aster/Tests/incl.14 b/OldCodes/Aster/Tests/incl.14 similarity index 100% rename from Aster/Tests/incl.14 rename to OldCodes/Aster/Tests/incl.14 diff --git a/Aster/Tests/incl.15 b/OldCodes/Aster/Tests/incl.15 similarity index 100% rename from Aster/Tests/incl.15 rename to OldCodes/Aster/Tests/incl.15 diff --git a/Aster/Tests/incl.16 b/OldCodes/Aster/Tests/incl.16 similarity index 100% rename from Aster/Tests/incl.16 rename to OldCodes/Aster/Tests/incl.16 diff --git a/Aster/Tests/incl.17 b/OldCodes/Aster/Tests/incl.17 similarity index 100% rename from Aster/Tests/incl.17 rename to OldCodes/Aster/Tests/incl.17 diff --git a/Aster/Tests/incl.25 b/OldCodes/Aster/Tests/incl.25 similarity index 100% rename from Aster/Tests/incl.25 rename to OldCodes/Aster/Tests/incl.25 diff --git a/Aster/Tests/incl1.comm b/OldCodes/Aster/Tests/incl1.comm similarity index 100% rename from Aster/Tests/incl1.comm rename to OldCodes/Aster/Tests/incl1.comm diff --git a/Aster/Tests/inclmat.comm b/OldCodes/Aster/Tests/inclmat.comm similarity index 100% rename from Aster/Tests/inclmat.comm rename to OldCodes/Aster/Tests/inclmat.comm diff --git a/Aster/Tests/inclmat2.comm b/OldCodes/Aster/Tests/inclmat2.comm similarity index 100% rename from Aster/Tests/inclmat2.comm rename to OldCodes/Aster/Tests/inclmat2.comm diff --git a/Aster/Tests/j0.comm b/OldCodes/Aster/Tests/j0.comm similarity index 100% rename from Aster/Tests/j0.comm rename to OldCodes/Aster/Tests/j0.comm diff --git a/Aster/Tests/j1.comm b/OldCodes/Aster/Tests/j1.comm similarity index 100% rename from Aster/Tests/j1.comm rename to OldCodes/Aster/Tests/j1.comm diff --git a/Aster/Tests/j1.ini b/OldCodes/Aster/Tests/j1.ini similarity index 100% rename from Aster/Tests/j1.ini rename to OldCodes/Aster/Tests/j1.ini diff --git a/Aster/Tests/j2.ini b/OldCodes/Aster/Tests/j2.ini similarity index 100% rename from Aster/Tests/j2.ini rename to OldCodes/Aster/Tests/j2.ini diff --git a/Aster/Tests/jdc.ini b/OldCodes/Aster/Tests/jdc.ini similarity index 100% rename from Aster/Tests/jdc.ini rename to OldCodes/Aster/Tests/jdc.ini diff --git a/Aster/Tests/p0.comm b/OldCodes/Aster/Tests/p0.comm similarity index 100% rename from Aster/Tests/p0.comm rename to OldCodes/Aster/Tests/p0.comm diff --git a/Aster/Tests/p1.comm b/OldCodes/Aster/Tests/p1.comm similarity index 100% rename from Aster/Tests/p1.comm rename to OldCodes/Aster/Tests/p1.comm diff --git a/Aster/Tests/p2.comm b/OldCodes/Aster/Tests/p2.comm similarity index 100% rename from Aster/Tests/p2.comm rename to OldCodes/Aster/Tests/p2.comm diff --git a/Aster/Tests/p3.comm b/OldCodes/Aster/Tests/p3.comm similarity index 100% rename from Aster/Tests/p3.comm rename to OldCodes/Aster/Tests/p3.comm diff --git a/Aster/Tests/perr.comm b/OldCodes/Aster/Tests/perr.comm similarity index 100% rename from Aster/Tests/perr.comm rename to OldCodes/Aster/Tests/perr.comm diff --git a/Aster/Tests/perr2.comm b/OldCodes/Aster/Tests/perr2.comm similarity index 100% rename from Aster/Tests/perr2.comm rename to OldCodes/Aster/Tests/perr2.comm diff --git a/Aster/Tests/pincl.11 b/OldCodes/Aster/Tests/pincl.11 similarity index 100% rename from Aster/Tests/pincl.11 rename to OldCodes/Aster/Tests/pincl.11 diff --git a/Aster/Tests/pp.comm b/OldCodes/Aster/Tests/pp.comm similarity index 100% rename from Aster/Tests/pp.comm rename to OldCodes/Aster/Tests/pp.comm diff --git a/Aster/Tests/princ.comm b/OldCodes/Aster/Tests/princ.comm similarity index 100% rename from Aster/Tests/princ.comm rename to OldCodes/Aster/Tests/princ.comm diff --git a/Aster/Tests/princ.ini b/OldCodes/Aster/Tests/princ.ini similarity index 100% rename from Aster/Tests/princ.ini rename to OldCodes/Aster/Tests/princ.ini diff --git a/Aster/Tests/princl.11 b/OldCodes/Aster/Tests/princl.11 similarity index 100% rename from Aster/Tests/princl.11 rename to OldCodes/Aster/Tests/princl.11 diff --git a/Aster/Tests/princl.12 b/OldCodes/Aster/Tests/princl.12 similarity index 100% rename from Aster/Tests/princl.12 rename to OldCodes/Aster/Tests/princl.12 diff --git a/Aster/Tests/princl.14 b/OldCodes/Aster/Tests/princl.14 similarity index 100% rename from Aster/Tests/princl.14 rename to OldCodes/Aster/Tests/princl.14 diff --git a/Aster/Tests/princl.35 b/OldCodes/Aster/Tests/princl.35 similarity index 100% rename from Aster/Tests/princl.35 rename to OldCodes/Aster/Tests/princl.35 diff --git a/Aster/Tests/qincl.11 b/OldCodes/Aster/Tests/qincl.11 similarity index 100% rename from Aster/Tests/qincl.11 rename to OldCodes/Aster/Tests/qincl.11 diff --git a/Aster/Tests/rincl.11 b/OldCodes/Aster/Tests/rincl.11 similarity index 100% rename from Aster/Tests/rincl.11 rename to OldCodes/Aster/Tests/rincl.11 diff --git a/Aster/Tests/torsion.comm b/OldCodes/Aster/Tests/torsion.comm similarity index 100% rename from Aster/Tests/torsion.comm rename to OldCodes/Aster/Tests/torsion.comm diff --git a/Aster/__init__.py b/OldCodes/Aster/__init__.py similarity index 100% rename from Aster/__init__.py rename to OldCodes/Aster/__init__.py diff --git a/Aster/a.dat b/OldCodes/Aster/a.dat similarity index 100% rename from Aster/a.dat rename to OldCodes/Aster/a.dat diff --git a/Aster/alphasdist.py b/OldCodes/Aster/alphasdist.py similarity index 100% rename from Aster/alphasdist.py rename to OldCodes/Aster/alphasdist.py diff --git a/Aster/configuration_ASTER.py b/OldCodes/Aster/configuration_ASTER.py similarity index 100% rename from Aster/configuration_ASTER.py rename to OldCodes/Aster/configuration_ASTER.py diff --git a/Aster/configuration_Aster.py b/OldCodes/Aster/configuration_Aster.py similarity index 100% rename from Aster/configuration_Aster.py rename to OldCodes/Aster/configuration_Aster.py diff --git a/Aster/eficasManager.py b/OldCodes/Aster/eficasManager.py similarity index 100% rename from Aster/eficasManager.py rename to OldCodes/Aster/eficasManager.py diff --git a/Aster/eficas_aster.py b/OldCodes/Aster/eficas_aster.py similarity index 100% rename from Aster/eficas_aster.py rename to OldCodes/Aster/eficas_aster.py diff --git a/Aster/lance_test.sh b/OldCodes/Aster/lance_test.sh similarity index 100% rename from Aster/lance_test.sh rename to OldCodes/Aster/lance_test.sh diff --git a/Aster/prefs.py b/OldCodes/Aster/prefs.py similarity index 100% rename from Aster/prefs.py rename to OldCodes/Aster/prefs.py diff --git a/Aster/prefs.py.win b/OldCodes/Aster/prefs.py.win similarity index 100% rename from Aster/prefs.py.win rename to OldCodes/Aster/prefs.py.win diff --git a/Aster/prefs_ASTER.py b/OldCodes/Aster/prefs_ASTER.py similarity index 100% rename from Aster/prefs_ASTER.py rename to OldCodes/Aster/prefs_ASTER.py diff --git a/Aster/prefs_Aster.py b/OldCodes/Aster/prefs_Aster.py similarity index 100% rename from Aster/prefs_Aster.py rename to OldCodes/Aster/prefs_Aster.py diff --git a/Aster/properties.py b/OldCodes/Aster/properties.py similarity index 100% rename from Aster/properties.py rename to OldCodes/Aster/properties.py diff --git a/OldCodes/Aster/qtEficas_aster.py b/OldCodes/Aster/qtEficas_aster.py new file mode 100755 index 00000000..f49b9bcb --- /dev/null +++ b/OldCodes/Aster/qtEficas_aster.py @@ -0,0 +1,32 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +# Copyright (C) 2007-2012 EDF R&D +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# +# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +# +""" + Ce module sert a lancer EFICAS configure pour Code_Aster +""" +# Modules Python +# Modules Eficas + +import sys,os +sys.path.append(os.path.join(os.path.abspath(os.path.dirname(__file__)),'..')) + +import prefs +from InterfaceQT4 import eficas_go +eficas_go.lance_eficas(code=prefs.code) diff --git a/Aster/qtGroup.py b/OldCodes/Aster/qtGroup.py similarity index 100% rename from Aster/qtGroup.py rename to OldCodes/Aster/qtGroup.py diff --git a/Aster/reecrit_comm.py b/OldCodes/Aster/reecrit_comm.py similarity index 100% rename from Aster/reecrit_comm.py rename to OldCodes/Aster/reecrit_comm.py diff --git a/Aster/sdist.py b/OldCodes/Aster/sdist.py similarity index 100% rename from Aster/sdist.py rename to OldCodes/Aster/sdist.py diff --git a/Aster/style.py b/OldCodes/Aster/style.py similarity index 100% rename from Aster/style.py rename to OldCodes/Aster/style.py diff --git a/Aster/test_eficas.py b/OldCodes/Aster/test_eficas.py similarity index 100% rename from Aster/test_eficas.py rename to OldCodes/Aster/test_eficas.py diff --git a/CarmelCND/CMakeLists.txt b/OldCodes/CarmelCND/CMakeLists.txt similarity index 100% rename from CarmelCND/CMakeLists.txt rename to OldCodes/CarmelCND/CMakeLists.txt diff --git a/CarmelCND/CarmelCND_Cata.py b/OldCodes/CarmelCND/CarmelCND_Cata.py similarity index 100% rename from CarmelCND/CarmelCND_Cata.py rename to OldCodes/CarmelCND/CarmelCND_Cata.py diff --git a/CarmelCND/PourTraductionCarmel.py b/OldCodes/CarmelCND/PourTraductionCarmel.py similarity index 100% rename from CarmelCND/PourTraductionCarmel.py rename to OldCodes/CarmelCND/PourTraductionCarmel.py diff --git a/CarmelCND/PrepareRunCarmel.py b/OldCodes/CarmelCND/PrepareRunCarmel.py similarity index 100% rename from CarmelCND/PrepareRunCarmel.py rename to OldCodes/CarmelCND/PrepareRunCarmel.py diff --git a/CarmelCND/acquiertGroupes.py b/OldCodes/CarmelCND/acquiertGroupes.py similarity index 100% rename from CarmelCND/acquiertGroupes.py rename to OldCodes/CarmelCND/acquiertGroupes.py diff --git a/CarmelCS/configuration_CARMELCS.py b/OldCodes/CarmelCND/configuration_CARMELCND.py similarity index 100% rename from CarmelCS/configuration_CARMELCS.py rename to OldCodes/CarmelCND/configuration_CARMELCND.py diff --git a/CarmelCND/prefs.py b/OldCodes/CarmelCND/prefs.py similarity index 100% rename from CarmelCND/prefs.py rename to OldCodes/CarmelCND/prefs.py diff --git a/CarmelCND/prefs_CARMELCND.py b/OldCodes/CarmelCND/prefs_CARMELCND.py similarity index 100% rename from CarmelCND/prefs_CARMELCND.py rename to OldCodes/CarmelCND/prefs_CARMELCND.py diff --git a/OldCodes/CarmelCND/qtEficas_CarmelCND.py b/OldCodes/CarmelCND/qtEficas_CarmelCND.py new file mode 100755 index 00000000..f49b9bcb --- /dev/null +++ b/OldCodes/CarmelCND/qtEficas_CarmelCND.py @@ -0,0 +1,32 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +# Copyright (C) 2007-2012 EDF R&D +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# +# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +# +""" + Ce module sert a lancer EFICAS configure pour Code_Aster +""" +# Modules Python +# Modules Eficas + +import sys,os +sys.path.append(os.path.join(os.path.abspath(os.path.dirname(__file__)),'..')) + +import prefs +from InterfaceQT4 import eficas_go +eficas_go.lance_eficas(code=prefs.code) diff --git a/CarmelCS/CMakeLists.txt b/OldCodes/CarmelCS/CMakeLists.txt similarity index 100% rename from CarmelCS/CMakeLists.txt rename to OldCodes/CarmelCS/CMakeLists.txt diff --git a/CarmelCS/CarmelCS_cata.py b/OldCodes/CarmelCS/CarmelCS_cata.py similarity index 100% rename from CarmelCS/CarmelCS_cata.py rename to OldCodes/CarmelCS/CarmelCS_cata.py diff --git a/PSEN_N1/configuration_PSEN_N1.py b/OldCodes/CarmelCS/configuration_CARMELCS.py similarity index 100% rename from PSEN_N1/configuration_PSEN_N1.py rename to OldCodes/CarmelCS/configuration_CARMELCS.py diff --git a/CarmelCS/pilotyacsCS.py b/OldCodes/CarmelCS/pilotyacsCS.py similarity index 100% rename from CarmelCS/pilotyacsCS.py rename to OldCodes/CarmelCS/pilotyacsCS.py diff --git a/CarmelCS/prefs.py b/OldCodes/CarmelCS/prefs.py similarity index 100% rename from CarmelCS/prefs.py rename to OldCodes/CarmelCS/prefs.py diff --git a/CarmelCS/prefs_CARMELCS.py b/OldCodes/CarmelCS/prefs_CARMELCS.py similarity index 100% rename from CarmelCS/prefs_CARMELCS.py rename to OldCodes/CarmelCS/prefs_CARMELCS.py diff --git a/ZCracks/qtEficas_ZCracks.py b/OldCodes/CarmelCS/qtEficas_CarmelCS.py similarity index 100% rename from ZCracks/qtEficas_ZCracks.py rename to OldCodes/CarmelCS/qtEficas_CarmelCS.py diff --git a/Openturns_Study/CMakeLists.txt b/OldCodes/Openturns_Study/CMakeLists.txt similarity index 100% rename from Openturns_Study/CMakeLists.txt rename to OldCodes/Openturns_Study/CMakeLists.txt diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V1.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V1.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V1.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V1.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V10.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V10.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V10.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V10.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V2.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V2.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V2.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V2.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V3.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V3.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V3.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V3.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V4.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V4.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V4.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V4.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V5.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V5.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V5.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V5.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V6.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V6.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V6.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V6.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V7.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V7.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V7.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V7.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V7.py.orig b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V7.py.orig similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V7.py.orig rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V7.py.orig diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V8.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V8.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V8.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V8.py diff --git a/Openturns_Study/OpenTURNS_Cata_Study_V9.py b/OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V9.py similarity index 100% rename from Openturns_Study/OpenTURNS_Cata_Study_V9.py rename to OldCodes/Openturns_Study/OpenTURNS_Cata_Study_V9.py diff --git a/Openturns_Study/configuration_OPENTURNS_STUDY.py b/OldCodes/Openturns_Study/configuration_OPENTURNS_STUDY.py similarity index 100% rename from Openturns_Study/configuration_OPENTURNS_STUDY.py rename to OldCodes/Openturns_Study/configuration_OPENTURNS_STUDY.py diff --git a/Openturns_Study/opsOT.py b/OldCodes/Openturns_Study/opsOT.py similarity index 100% rename from Openturns_Study/opsOT.py rename to OldCodes/Openturns_Study/opsOT.py diff --git a/Openturns_Study/prefs.py b/OldCodes/Openturns_Study/prefs.py similarity index 100% rename from Openturns_Study/prefs.py rename to OldCodes/Openturns_Study/prefs.py diff --git a/Openturns_Study/prefs_OPENTURNS_STUDY.py b/OldCodes/Openturns_Study/prefs_OPENTURNS_STUDY.py similarity index 100% rename from Openturns_Study/prefs_OPENTURNS_STUDY.py rename to OldCodes/Openturns_Study/prefs_OPENTURNS_STUDY.py diff --git a/Openturns_Study/properties.py b/OldCodes/Openturns_Study/properties.py similarity index 100% rename from Openturns_Study/properties.py rename to OldCodes/Openturns_Study/properties.py diff --git a/Openturns_Study/qtEficas_openturns_study.py b/OldCodes/Openturns_Study/qtEficas_openturns_study.py similarity index 100% rename from Openturns_Study/qtEficas_openturns_study.py rename to OldCodes/Openturns_Study/qtEficas_openturns_study.py diff --git a/Openturns_Study/sdistOTqt.py b/OldCodes/Openturns_Study/sdistOTqt.py similarity index 100% rename from Openturns_Study/sdistOTqt.py rename to OldCodes/Openturns_Study/sdistOTqt.py diff --git a/Openturns_Study/style.py b/OldCodes/Openturns_Study/style.py similarity index 100% rename from Openturns_Study/style.py rename to OldCodes/Openturns_Study/style.py diff --git a/Openturns_Study/test/MinMax_ExpPlane.comm b/OldCodes/Openturns_Study/test/MinMax_ExpPlane.comm similarity index 100% rename from Openturns_Study/test/MinMax_ExpPlane.comm rename to OldCodes/Openturns_Study/test/MinMax_ExpPlane.comm diff --git a/Openturns_Study/test/MinMax_ExpPlane.py b/OldCodes/Openturns_Study/test/MinMax_ExpPlane.py similarity index 100% rename from Openturns_Study/test/MinMax_ExpPlane.py rename to OldCodes/Openturns_Study/test/MinMax_ExpPlane.py diff --git a/Openturns_Study/test/MinMax_RandomSampling.comm b/OldCodes/Openturns_Study/test/MinMax_RandomSampling.comm similarity index 100% rename from Openturns_Study/test/MinMax_RandomSampling.comm rename to OldCodes/Openturns_Study/test/MinMax_RandomSampling.comm diff --git a/Openturns_Wrapper/CMakeLists.txt b/OldCodes/Openturns_Wrapper/CMakeLists.txt similarity index 100% rename from Openturns_Wrapper/CMakeLists.txt rename to OldCodes/Openturns_Wrapper/CMakeLists.txt diff --git a/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V1.py b/OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V1.py similarity index 100% rename from Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V1.py rename to OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V1.py diff --git a/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V2.py b/OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V2.py similarity index 100% rename from Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V2.py rename to OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V2.py diff --git a/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V3.py b/OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V3.py similarity index 100% rename from Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V3.py rename to OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V3.py diff --git a/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V4.py b/OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V4.py similarity index 100% rename from Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V4.py rename to OldCodes/Openturns_Wrapper/OpenTURNS_Cata_Wrapper_V4.py diff --git a/Openturns_Wrapper/configuration_OPENTURNS_WRAPPER.py b/OldCodes/Openturns_Wrapper/configuration_OPENTURNS_WRAPPER.py similarity index 100% rename from Openturns_Wrapper/configuration_OPENTURNS_WRAPPER.py rename to OldCodes/Openturns_Wrapper/configuration_OPENTURNS_WRAPPER.py diff --git a/Openturns_Wrapper/prefs.py b/OldCodes/Openturns_Wrapper/prefs.py similarity index 100% rename from Openturns_Wrapper/prefs.py rename to OldCodes/Openturns_Wrapper/prefs.py diff --git a/Openturns_Wrapper/prefs_OPENTURNS_WRAPPER.py b/OldCodes/Openturns_Wrapper/prefs_OPENTURNS_WRAPPER.py similarity index 100% rename from Openturns_Wrapper/prefs_OPENTURNS_WRAPPER.py rename to OldCodes/Openturns_Wrapper/prefs_OPENTURNS_WRAPPER.py diff --git a/Openturns_Wrapper/properties.py b/OldCodes/Openturns_Wrapper/properties.py similarity index 100% rename from Openturns_Wrapper/properties.py rename to OldCodes/Openturns_Wrapper/properties.py diff --git a/Openturns_Wrapper/qtEficas_openturns_wrapper.py b/OldCodes/Openturns_Wrapper/qtEficas_openturns_wrapper.py similarity index 100% rename from Openturns_Wrapper/qtEficas_openturns_wrapper.py rename to OldCodes/Openturns_Wrapper/qtEficas_openturns_wrapper.py diff --git a/Openturns_Wrapper/sdistOTqt.py b/OldCodes/Openturns_Wrapper/sdistOTqt.py similarity index 100% rename from Openturns_Wrapper/sdistOTqt.py rename to OldCodes/Openturns_Wrapper/sdistOTqt.py diff --git a/Openturns_Wrapper/style.py b/OldCodes/Openturns_Wrapper/style.py similarity index 100% rename from Openturns_Wrapper/style.py rename to OldCodes/Openturns_Wrapper/style.py diff --git a/PSEN_N1/PSEN_Cata_N1.py b/OldCodes/PSEN_N1/PSEN_Cata_N1.py similarity index 100% rename from PSEN_N1/PSEN_Cata_N1.py rename to OldCodes/PSEN_N1/PSEN_Cata_N1.py diff --git a/ZCracks/configuration_ZCRACKS.py b/OldCodes/PSEN_N1/configuration_PSEN_N1.py similarity index 100% rename from ZCracks/configuration_ZCRACKS.py rename to OldCodes/PSEN_N1/configuration_PSEN_N1.py diff --git a/PSEN_N1/mesScripts_PSEN_N1.py b/OldCodes/PSEN_N1/mesScripts_PSEN_N1.py similarity index 100% rename from PSEN_N1/mesScripts_PSEN_N1.py rename to OldCodes/PSEN_N1/mesScripts_PSEN_N1.py diff --git a/PSEN_N1/opsPSEN_N1.py b/OldCodes/PSEN_N1/opsPSEN_N1.py similarity index 100% rename from PSEN_N1/opsPSEN_N1.py rename to OldCodes/PSEN_N1/opsPSEN_N1.py diff --git a/PSEN_N1/prefs.py b/OldCodes/PSEN_N1/prefs.py similarity index 100% rename from PSEN_N1/prefs.py rename to OldCodes/PSEN_N1/prefs.py diff --git a/PSEN_N1/prefs_PSEN_N1.py b/OldCodes/PSEN_N1/prefs_PSEN_N1.py similarity index 100% rename from PSEN_N1/prefs_PSEN_N1.py rename to OldCodes/PSEN_N1/prefs_PSEN_N1.py diff --git a/ZCracks/properties.py b/OldCodes/PSEN_N1/properties.py similarity index 100% rename from ZCracks/properties.py rename to OldCodes/PSEN_N1/properties.py diff --git a/PSEN_N1/qtEficas_PSEN_N1.py b/OldCodes/PSEN_N1/qtEficas_PSEN_N1.py similarity index 100% rename from PSEN_N1/qtEficas_PSEN_N1.py rename to OldCodes/PSEN_N1/qtEficas_PSEN_N1.py diff --git a/PSEN_N1/run.py b/OldCodes/PSEN_N1/run.py similarity index 100% rename from PSEN_N1/run.py rename to OldCodes/PSEN_N1/run.py diff --git a/Sep/CMakeLists.txt b/OldCodes/Sep/CMakeLists.txt similarity index 100% rename from Sep/CMakeLists.txt rename to OldCodes/Sep/CMakeLists.txt diff --git a/Sep/SEP_Cata_V0.py b/OldCodes/Sep/SEP_Cata_V0.py similarity index 100% rename from Sep/SEP_Cata_V0.py rename to OldCodes/Sep/SEP_Cata_V0.py diff --git a/Sep/SEP_Cata_V1.py b/OldCodes/Sep/SEP_Cata_V1.py similarity index 100% rename from Sep/SEP_Cata_V1.py rename to OldCodes/Sep/SEP_Cata_V1.py diff --git a/Sep/SEP_Cata_V1_2.py b/OldCodes/Sep/SEP_Cata_V1_2.py similarity index 100% rename from Sep/SEP_Cata_V1_2.py rename to OldCodes/Sep/SEP_Cata_V1_2.py diff --git a/Sep/SEP_Cata_V1_3.py b/OldCodes/Sep/SEP_Cata_V1_3.py similarity index 100% rename from Sep/SEP_Cata_V1_3.py rename to OldCodes/Sep/SEP_Cata_V1_3.py diff --git a/Sep/SEP_Cata_V1_4.py b/OldCodes/Sep/SEP_Cata_V1_4.py similarity index 100% rename from Sep/SEP_Cata_V1_4.py rename to OldCodes/Sep/SEP_Cata_V1_4.py diff --git a/Sep/__init__.py b/OldCodes/Sep/__init__.py similarity index 100% rename from Sep/__init__.py rename to OldCodes/Sep/__init__.py diff --git a/Sep/catalogues_sep.ini b/OldCodes/Sep/catalogues_sep.ini similarity index 100% rename from Sep/catalogues_sep.ini rename to OldCodes/Sep/catalogues_sep.ini diff --git a/Sep/configuration_SEP.py b/OldCodes/Sep/configuration_SEP.py similarity index 100% rename from Sep/configuration_SEP.py rename to OldCodes/Sep/configuration_SEP.py diff --git a/Sep/editeur.ini b/OldCodes/Sep/editeur.ini similarity index 100% rename from Sep/editeur.ini rename to OldCodes/Sep/editeur.ini diff --git a/Sep/prefs.py b/OldCodes/Sep/prefs.py similarity index 100% rename from Sep/prefs.py rename to OldCodes/Sep/prefs.py diff --git a/Sep/prefs_SEP.py b/OldCodes/Sep/prefs_SEP.py similarity index 100% rename from Sep/prefs_SEP.py rename to OldCodes/Sep/prefs_SEP.py diff --git a/Sep/properties.py b/OldCodes/Sep/properties.py similarity index 100% rename from Sep/properties.py rename to OldCodes/Sep/properties.py diff --git a/Sep/qtEficas_SEP.py b/OldCodes/Sep/qtEficas_SEP.py similarity index 100% rename from Sep/qtEficas_SEP.py rename to OldCodes/Sep/qtEficas_SEP.py diff --git a/Sep/sdistSEP.py b/OldCodes/Sep/sdistSEP.py similarity index 100% rename from Sep/sdistSEP.py rename to OldCodes/Sep/sdistSEP.py diff --git a/Sep/style.py b/OldCodes/Sep/style.py similarity index 100% rename from Sep/style.py rename to OldCodes/Sep/style.py diff --git a/UiQT4/CMakeLists.txt b/OldCodes/UiQT4/CMakeLists.txt similarity index 100% rename from UiQT4/CMakeLists.txt rename to OldCodes/UiQT4/CMakeLists.txt diff --git a/UiQT4/Newdoc.tgz b/OldCodes/UiQT4/Newdoc.tgz similarity index 100% rename from UiQT4/Newdoc.tgz rename to OldCodes/UiQT4/Newdoc.tgz diff --git a/UiQT4/Tuple2.ui b/OldCodes/UiQT4/Tuple2.ui similarity index 100% rename from UiQT4/Tuple2.ui rename to OldCodes/UiQT4/Tuple2.ui diff --git a/UiQT4/Tuple3.ui b/OldCodes/UiQT4/Tuple3.ui similarity index 100% rename from UiQT4/Tuple3.ui rename to OldCodes/UiQT4/Tuple3.ui diff --git a/UiQT4/desBaseWidget.ui b/OldCodes/UiQT4/desBaseWidget.ui similarity index 100% rename from UiQT4/desBaseWidget.ui rename to OldCodes/UiQT4/desBaseWidget.ui diff --git a/UiQT4/desChoixCata.ui b/OldCodes/UiQT4/desChoixCata.ui similarity index 100% rename from UiQT4/desChoixCata.ui rename to OldCodes/UiQT4/desChoixCata.ui diff --git a/UiQT4/desChoixCode.ui b/OldCodes/UiQT4/desChoixCode.ui similarity index 100% rename from UiQT4/desChoixCode.ui rename to OldCodes/UiQT4/desChoixCode.ui diff --git a/UiQT4/desChoixCommandes.ui b/OldCodes/UiQT4/desChoixCommandes.ui similarity index 100% rename from UiQT4/desChoixCommandes.ui rename to OldCodes/UiQT4/desChoixCommandes.ui diff --git a/UiQT4/desChoixLangue.ui b/OldCodes/UiQT4/desChoixLangue.ui similarity index 100% rename from UiQT4/desChoixLangue.ui rename to OldCodes/UiQT4/desChoixLangue.ui diff --git a/UiQT4/desGroupeOptionnel.ui b/OldCodes/UiQT4/desGroupeOptionnel.ui similarity index 100% rename from UiQT4/desGroupeOptionnel.ui rename to OldCodes/UiQT4/desGroupeOptionnel.ui diff --git a/UiQT4/desRecherche.ui b/OldCodes/UiQT4/desRecherche.ui similarity index 100% rename from UiQT4/desRecherche.ui rename to OldCodes/UiQT4/desRecherche.ui diff --git a/UiQT4/desRechercheCatalogue.ui b/OldCodes/UiQT4/desRechercheCatalogue.ui similarity index 100% rename from UiQT4/desRechercheCatalogue.ui rename to OldCodes/UiQT4/desRechercheCatalogue.ui diff --git a/UiQT4/desSelectVal.ui b/OldCodes/UiQT4/desSelectVal.ui similarity index 100% rename from UiQT4/desSelectVal.ui rename to OldCodes/UiQT4/desSelectVal.ui diff --git a/UiQT4/desViewRegles.ui b/OldCodes/UiQT4/desViewRegles.ui similarity index 100% rename from UiQT4/desViewRegles.ui rename to OldCodes/UiQT4/desViewRegles.ui diff --git a/UiQT4/desViewTexte.ui b/OldCodes/UiQT4/desViewTexte.ui similarity index 100% rename from UiQT4/desViewTexte.ui rename to OldCodes/UiQT4/desViewTexte.ui diff --git a/UiQT4/desVisu.ui b/OldCodes/UiQT4/desVisu.ui similarity index 100% rename from UiQT4/desVisu.ui rename to OldCodes/UiQT4/desVisu.ui diff --git a/UiQT4/desWidget4a6RadioButton.ui b/OldCodes/UiQT4/desWidget4a6RadioButton.ui similarity index 100% rename from UiQT4/desWidget4a6RadioButton.ui rename to OldCodes/UiQT4/desWidget4a6RadioButton.ui diff --git a/UiQT4/desWidgetBloc.ui b/OldCodes/UiQT4/desWidgetBloc.ui similarity index 100% rename from UiQT4/desWidgetBloc.ui rename to OldCodes/UiQT4/desWidgetBloc.ui diff --git a/UiQT4/desWidgetCB.ui b/OldCodes/UiQT4/desWidgetCB.ui similarity index 100% rename from UiQT4/desWidgetCB.ui rename to OldCodes/UiQT4/desWidgetCB.ui diff --git a/UiQT4/desWidgetCommande.ui b/OldCodes/UiQT4/desWidgetCommande.ui similarity index 100% rename from UiQT4/desWidgetCommande.ui rename to OldCodes/UiQT4/desWidgetCommande.ui diff --git a/UiQT4/desWidgetCommentaire.ui b/OldCodes/UiQT4/desWidgetCommentaire.ui similarity index 100% rename from UiQT4/desWidgetCommentaire.ui rename to OldCodes/UiQT4/desWidgetCommentaire.ui diff --git a/UiQT4/desWidgetCreeParam.ui b/OldCodes/UiQT4/desWidgetCreeParam.ui similarity index 100% rename from UiQT4/desWidgetCreeParam.ui rename to OldCodes/UiQT4/desWidgetCreeParam.ui diff --git a/UiQT4/desWidgetDate.ui b/OldCodes/UiQT4/desWidgetDate.ui similarity index 100% rename from UiQT4/desWidgetDate.ui rename to OldCodes/UiQT4/desWidgetDate.ui diff --git a/UiQT4/desWidgetFact.ui b/OldCodes/UiQT4/desWidgetFact.ui similarity index 100% rename from UiQT4/desWidgetFact.ui rename to OldCodes/UiQT4/desWidgetFact.ui diff --git a/UiQT4/desWidgetFactPlie.ui b/OldCodes/UiQT4/desWidgetFactPlie.ui similarity index 100% rename from UiQT4/desWidgetFactPlie.ui rename to OldCodes/UiQT4/desWidgetFactPlie.ui diff --git a/UiQT4/desWidgetFormule.ui b/OldCodes/UiQT4/desWidgetFormule.ui similarity index 100% rename from UiQT4/desWidgetFormule.ui rename to OldCodes/UiQT4/desWidgetFormule.ui diff --git a/UiQT4/desWidgetHeure.ui b/OldCodes/UiQT4/desWidgetHeure.ui similarity index 100% rename from UiQT4/desWidgetHeure.ui rename to OldCodes/UiQT4/desWidgetHeure.ui diff --git a/UiQT4/desWidgetInactif.ui b/OldCodes/UiQT4/desWidgetInactif.ui similarity index 100% rename from UiQT4/desWidgetInactif.ui rename to OldCodes/UiQT4/desWidgetInactif.ui diff --git a/UiQT4/desWidgetInformation.ui b/OldCodes/UiQT4/desWidgetInformation.ui similarity index 100% rename from UiQT4/desWidgetInformation.ui rename to OldCodes/UiQT4/desWidgetInformation.ui diff --git a/UiQT4/desWidgetMatrice.ui b/OldCodes/UiQT4/desWidgetMatrice.ui similarity index 100% rename from UiQT4/desWidgetMatrice.ui rename to OldCodes/UiQT4/desWidgetMatrice.ui diff --git a/UiQT4/desWidgetOptionnel.ui b/OldCodes/UiQT4/desWidgetOptionnel.ui similarity index 100% rename from UiQT4/desWidgetOptionnel.ui rename to OldCodes/UiQT4/desWidgetOptionnel.ui diff --git a/UiQT4/desWidgetOptionnelMC.ui b/OldCodes/UiQT4/desWidgetOptionnelMC.ui similarity index 100% rename from UiQT4/desWidgetOptionnelMC.ui rename to OldCodes/UiQT4/desWidgetOptionnelMC.ui diff --git a/UiQT4/desWidgetParam.ui b/OldCodes/UiQT4/desWidgetParam.ui similarity index 100% rename from UiQT4/desWidgetParam.ui rename to OldCodes/UiQT4/desWidgetParam.ui diff --git a/UiQT4/desWidgetPlusieursBase.ui b/OldCodes/UiQT4/desWidgetPlusieursBase.ui similarity index 100% rename from UiQT4/desWidgetPlusieursBase.ui rename to OldCodes/UiQT4/desWidgetPlusieursBase.ui diff --git a/UiQT4/desWidgetPlusieursInto.ui b/OldCodes/UiQT4/desWidgetPlusieursInto.ui similarity index 100% rename from UiQT4/desWidgetPlusieursInto.ui rename to OldCodes/UiQT4/desWidgetPlusieursInto.ui diff --git a/UiQT4/desWidgetPlusieursIntoOrdonne.ui b/OldCodes/UiQT4/desWidgetPlusieursIntoOrdonne.ui similarity index 100% rename from UiQT4/desWidgetPlusieursIntoOrdonne.ui rename to OldCodes/UiQT4/desWidgetPlusieursIntoOrdonne.ui diff --git a/UiQT4/desWidgetPlusieursPlie.ui b/OldCodes/UiQT4/desWidgetPlusieursPlie.ui similarity index 100% rename from UiQT4/desWidgetPlusieursPlie.ui rename to OldCodes/UiQT4/desWidgetPlusieursPlie.ui diff --git a/UiQT4/desWidgetPlusieursTuple.ui b/OldCodes/UiQT4/desWidgetPlusieursTuple.ui similarity index 100% rename from UiQT4/desWidgetPlusieursTuple.ui rename to OldCodes/UiQT4/desWidgetPlusieursTuple.ui diff --git a/UiQT4/desWidgetRadioButton.ui b/OldCodes/UiQT4/desWidgetRadioButton.ui similarity index 100% rename from UiQT4/desWidgetRadioButton.ui rename to OldCodes/UiQT4/desWidgetRadioButton.ui diff --git a/UiQT4/desWidgetSDCOInto.ui b/OldCodes/UiQT4/desWidgetSDCOInto.ui similarity index 100% rename from UiQT4/desWidgetSDCOInto.ui rename to OldCodes/UiQT4/desWidgetSDCOInto.ui diff --git a/UiQT4/desWidgetSimpBase.ui b/OldCodes/UiQT4/desWidgetSimpBase.ui similarity index 100% rename from UiQT4/desWidgetSimpBase.ui rename to OldCodes/UiQT4/desWidgetSimpBase.ui diff --git a/UiQT4/desWidgetSimpBool.ui b/OldCodes/UiQT4/desWidgetSimpBool.ui similarity index 100% rename from UiQT4/desWidgetSimpBool.ui rename to OldCodes/UiQT4/desWidgetSimpBool.ui diff --git a/UiQT4/desWidgetSimpComplexe.ui b/OldCodes/UiQT4/desWidgetSimpComplexe.ui similarity index 100% rename from UiQT4/desWidgetSimpComplexe.ui rename to OldCodes/UiQT4/desWidgetSimpComplexe.ui diff --git a/UiQT4/desWidgetSimpFichier.ui b/OldCodes/UiQT4/desWidgetSimpFichier.ui similarity index 100% rename from UiQT4/desWidgetSimpFichier.ui rename to OldCodes/UiQT4/desWidgetSimpFichier.ui diff --git a/UiQT4/desWidgetSimpSalome.ui b/OldCodes/UiQT4/desWidgetSimpSalome.ui similarity index 100% rename from UiQT4/desWidgetSimpSalome.ui rename to OldCodes/UiQT4/desWidgetSimpSalome.ui diff --git a/UiQT4/desWidgetSimpTxt.ui b/OldCodes/UiQT4/desWidgetSimpTxt.ui similarity index 100% rename from UiQT4/desWidgetSimpTxt.ui rename to OldCodes/UiQT4/desWidgetSimpTxt.ui diff --git a/UiQT4/desWidgetTuple2.ui b/OldCodes/UiQT4/desWidgetTuple2.ui similarity index 100% rename from UiQT4/desWidgetTuple2.ui rename to OldCodes/UiQT4/desWidgetTuple2.ui diff --git a/UiQT4/desWidgetTuple3.ui b/OldCodes/UiQT4/desWidgetTuple3.ui similarity index 100% rename from UiQT4/desWidgetTuple3.ui rename to OldCodes/UiQT4/desWidgetTuple3.ui diff --git a/UiQT4/desWidgetUniqueSDCO.ui b/OldCodes/UiQT4/desWidgetUniqueSDCO.ui similarity index 100% rename from UiQT4/desWidgetUniqueSDCO.ui rename to OldCodes/UiQT4/desWidgetUniqueSDCO.ui diff --git a/UiQT4/desWidgetVide.ui b/OldCodes/UiQT4/desWidgetVide.ui similarity index 100% rename from UiQT4/desWidgetVide.ui rename to OldCodes/UiQT4/desWidgetVide.ui diff --git a/UiQT4/eficas_en.0106.ts b/OldCodes/UiQT4/eficas_en.0106.ts similarity index 100% rename from UiQT4/eficas_en.0106.ts rename to OldCodes/UiQT4/eficas_en.0106.ts diff --git a/UiQT4/eficas_en.ts b/OldCodes/UiQT4/eficas_en.ts similarity index 100% rename from UiQT4/eficas_en.ts rename to OldCodes/UiQT4/eficas_en.ts diff --git a/UiQT4/eficas_fr.0106.ts b/OldCodes/UiQT4/eficas_fr.0106.ts similarity index 100% rename from UiQT4/eficas_fr.0106.ts rename to OldCodes/UiQT4/eficas_fr.0106.ts diff --git a/UiQT4/eficas_fr.ts b/OldCodes/UiQT4/eficas_fr.ts similarity index 100% rename from UiQT4/eficas_fr.ts rename to OldCodes/UiQT4/eficas_fr.ts diff --git a/UiQT4/makefile b/OldCodes/UiQT4/makefile similarity index 100% rename from UiQT4/makefile rename to OldCodes/UiQT4/makefile diff --git a/UiQT4/myMain.ui b/OldCodes/UiQT4/myMain.ui similarity index 100% rename from UiQT4/myMain.ui rename to OldCodes/UiQT4/myMain.ui diff --git a/ZCracks/CMakeLists.txt b/OldCodes/ZCracks/CMakeLists.txt similarity index 100% rename from ZCracks/CMakeLists.txt rename to OldCodes/ZCracks/CMakeLists.txt diff --git a/OldCodes/ZCracks/configuration_ZCRACKS.py b/OldCodes/ZCracks/configuration_ZCRACKS.py new file mode 100644 index 00000000..4ab64b85 --- /dev/null +++ b/OldCodes/ZCracks/configuration_ZCRACKS.py @@ -0,0 +1,43 @@ +# -*- coding: utf-8 -*- +# CONFIGURATION MANAGEMENT OF EDF VERSION +# ====================================================================== +# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG +# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY +# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY +# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR +# (AT YOUR OPTION) ANY LATER VERSION. +# +# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT +# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF +# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU +# GENERAL PUBLIC LICENSE FOR MORE DETAILS. +# +# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE +# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER, +# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE. +# +# +# ====================================================================== +""" + Ce module sert pour charger les paramètres de configuration d'EFICAS +""" +# Modules Python +from InterfaceQT4 import configuration +import os + + +class CONFIG(configuration.CONFIG_BASE): + + #----------------------------------- + def __init__(self,appli,repIni): + #----------------------------------- + + self.labels_user=['catalogues','lang'] + self.labels_eficas=['lang','rep_cata','catalogues'] + + configuration.CONFIG_BASE.__init__(self,appli,'.Eficas_monCode') + + +def make_config(appli,rep): + return CONFIG(appli,rep) + diff --git a/ZCracks/mesScripts_ZCRACKS.py b/OldCodes/ZCracks/mesScripts_ZCRACKS.py similarity index 100% rename from ZCracks/mesScripts_ZCRACKS.py rename to OldCodes/ZCracks/mesScripts_ZCRACKS.py diff --git a/ZCracks/monCode_Cata.py b/OldCodes/ZCracks/monCode_Cata.py similarity index 100% rename from ZCracks/monCode_Cata.py rename to OldCodes/ZCracks/monCode_Cata.py diff --git a/ZCracks/monCode_Cata.py.V0 b/OldCodes/ZCracks/monCode_Cata.py.V0 similarity index 100% rename from ZCracks/monCode_Cata.py.V0 rename to OldCodes/ZCracks/monCode_Cata.py.V0 diff --git a/ZCracks/prefs.py b/OldCodes/ZCracks/prefs.py similarity index 100% rename from ZCracks/prefs.py rename to OldCodes/ZCracks/prefs.py diff --git a/ZCracks/prefs_ZCRACKS.py b/OldCodes/ZCracks/prefs_ZCRACKS.py similarity index 100% rename from ZCracks/prefs_ZCRACKS.py rename to OldCodes/ZCracks/prefs_ZCRACKS.py diff --git a/OldCodes/ZCracks/properties.py b/OldCodes/ZCracks/properties.py new file mode 100644 index 00000000..1d328a46 --- /dev/null +++ b/OldCodes/ZCracks/properties.py @@ -0,0 +1,24 @@ +#@ MODIF properties Accas DATE 11/06/2008 AUTEUR aster M.ADMINISTRATEUR +# RESPONSABLE D6BHHHH J-P.LEFEBVRE +# ====================================================================== +# COPYRIGHT (C) 1991 - 2001 EDF R&D WWW.CODE-ASTER.ORG +# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY +# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY +# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR +# (AT YOUR OPTION) ANY LATER VERSION. +# +# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT +# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF +# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU +# GENERAL PUBLIC LICENSE FOR MORE DETAILS. +# +# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE +# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER, +# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE. +# ====================================================================== +# IDENTIFICATION DU GESTIONNAIRE DE COMMANDE ACCAS A PARTIR +# DE LA VERSION DU CODE_ASTER ASSOCIE +#---------------------------------------------------------------------- +version = "1.2" +date = "25/05/2010" +exploit = False diff --git a/OldCodes/ZCracks/qtEficas_ZCracks.py b/OldCodes/ZCracks/qtEficas_ZCracks.py new file mode 100755 index 00000000..b1254f2c --- /dev/null +++ b/OldCodes/ZCracks/qtEficas_ZCracks.py @@ -0,0 +1,33 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +# Copyright (C) 2007-2012 EDF R&D +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License as published by the Free Software Foundation; either +# version 2.1 of the License. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +# +# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com +# +""" + Ce module sert a lancer EFICAS configure pour Code_Aster +""" +# Modules Python +# Modules Eficas + +import sys,os +sys.path.append(os.path.join(os.path.abspath(os.path.dirname(__file__)),'..')) + +from PyQt4.QtCore import * +import prefs +from InterfaceQT4 import eficas_go +eficas_go.lance_eficas(code=prefs.code) diff --git a/ts/Telemac_Cata.py b/OldCodes/ts/Telemac_Cata.py similarity index 100% rename from ts/Telemac_Cata.py rename to OldCodes/ts/Telemac_Cata.py diff --git a/ts/a.py b/OldCodes/ts/a.py similarity index 100% rename from ts/a.py rename to OldCodes/ts/a.py diff --git a/ts/dicoparser.py b/OldCodes/ts/dicoparser.py similarity index 100% rename from ts/dicoparser.py rename to OldCodes/ts/dicoparser.py diff --git a/ts/main.ts b/OldCodes/ts/main.ts similarity index 100% rename from ts/main.ts rename to OldCodes/ts/main.ts diff --git a/ts/prefs.py b/OldCodes/ts/prefs.py similarity index 100% rename from ts/prefs.py rename to OldCodes/ts/prefs.py diff --git a/ts/telemac2dv6p3.dico b/OldCodes/ts/telemac2dv6p3.dico similarity index 100% rename from ts/telemac2dv6p3.dico rename to OldCodes/ts/telemac2dv6p3.dico diff --git a/ts/test_cata.py b/OldCodes/ts/test_cata.py similarity index 100% rename from ts/test_cata.py rename to OldCodes/ts/test_cata.py diff --git a/ts/test_dicoparser.py b/OldCodes/ts/test_dicoparser.py similarity index 100% rename from ts/test_dicoparser.py rename to OldCodes/ts/test_dicoparser.py diff --git a/ts/test_translator.py b/OldCodes/ts/test_translator.py similarity index 100% rename from ts/test_translator.py rename to OldCodes/ts/test_translator.py diff --git a/ts/translator.py b/OldCodes/ts/translator.py similarity index 100% rename from ts/translator.py rename to OldCodes/ts/translator.py diff --git a/ts/tsparser.py b/OldCodes/ts/tsparser.py similarity index 100% rename from ts/tsparser.py rename to OldCodes/ts/tsparser.py diff --git a/ProcessOutputs_Eficas/PSEN_Cata_N1.py b/ProcessOutputs_Eficas/PSEN_Cata_N1.py index f2598161..92d795f4 100644 --- a/ProcessOutputs_Eficas/PSEN_Cata_N1.py +++ b/ProcessOutputs_Eficas/PSEN_Cata_N1.py @@ -25,7 +25,15 @@ #from Accas import ASSD, JDC_CATA, AU_MOINS_UN, PROC, SIMP, FACT, OPER, MACRO, BLOC, A_VALIDATOR from Accas import * import opsPSEN_N1 +import pn # +#class loi ( ASSD ) : pass +#class variable ( ASSD ) : pass +class sd_charge ( ASSD ) : pass +class sd_generateur ( ASSD ) : pass +class sd_ligne ( ASSD ) : pass +class sd_transfo ( ASSD ) : pass +class sd_moteur ( ASSD ) : pass # # import types @@ -34,6 +42,7 @@ class Tuple: self.ntuple=ntuple def __convert__(self,valeur): + import types if type(valeur) == types.StringType: return None if len(valeur) != self.ntuple: @@ -72,15 +81,17 @@ class Tuple: #CONTEXT.debug = 1 JdC = JDC_CATA ( code = 'PSEN', execmodul = None, - regles = ( AU_MOINS_UN ( 'CASE_SELECTION' ), - # AU_MOINS_UN ( 'DIRECTORY' ), - # AU_MOINS_UN ( 'DISTRIBUTION' ), - # AU_MOINS_UN ( 'SIMULATION' ), + regles = ( AU_MOINS_UN ( 'CASE_SELECTION', 'CONTINGENCY_PROCESSING' ), + AU_MOINS_UN ( 'CONTINGENCY_SELECTION','N_PROCESSING_OPTIONS','CONTINGENCY_PROCESSING' ), + PRESENT_PRESENT ( 'CONTINGENCY_SELECTION','CONTINGENCY_OPTIONS' ), + PRESENT_PRESENT ( 'CONTINGENCY_PROCESSING','CONTINGENCY_OPTIONS' ), + AU_MOINS_UN ( 'SIMULATION' ), # AU_PLUS_UN ( 'PSSE_PARAMETERS' ), - # AU_PLUS_UN ( 'DIRECTORY' ), - # AU_PLUS_UN ( 'SIMULATION' ), - # AU_PLUS_UN ( 'CORRELATION' ), - # AU_PLUS_UN ( 'N_1_GENERATORS' ), + AU_PLUS_UN ( 'CASE_SELECTION' ), + AU_PLUS_UN ( 'CONTINGENCY_OPTIONS' ), + AU_PLUS_UN ( 'CONTINGENCY_SELECTION' ), + AU_PLUS_UN ( 'CONTINGENCY_PROCESSING' ), + AU_PLUS_UN ( 'N_PROCESSING_OPTIONS' ), # AU_PLUS_UN ( 'N_1_LINES' ), # AU_PLUS_UN ( 'N_1_LOADS' ), # AU_PLUS_UN ( 'N_1_TRANSFORMERS' ), @@ -88,6 +99,18 @@ JdC = JDC_CATA ( code = 'PSEN', ), ) # Fin JDC_CATA +MODIFICATION_CATALOGUE = MACRO ( nom = "MODIFICATION_CATALOGUE", + sd_prod = pn.modification_catalogue, + op_init= pn.modification_catalogue2, + op=None, + UIinfo={"groupes":("CACHE")}, + Fonction=SIMP(statut='o', typ='TXM', into=['ajoutDefinitionMC']), + Etape=SIMP(statut='o', typ='TXM',), + Genea=SIMP(statut='o', typ='TXM', min=0, max='**'), + NomSIMP=SIMP(statut='o', typ='TXM',), + TypeSIMP=SIMP(statut='o', typ='TXM',), + PhraseArguments=SIMP(statut='o', typ='TXM',),) + # -------------------------------------------------- # fin entete @@ -98,7 +121,7 @@ CASE_SELECTION = MACRO ( nom = "CASE_SELECTION", op_init = opsPSEN_N1.INCLUDE_context, fichier_ini = 1, op = None, - fr = "Sélectionnez les cas à analyser", + fr = "Selectionnez les cas a analyser", ang = 'Select the cases to analyze', PSSE_path = SIMP(statut="o",typ='Repertoire',defaut='C:\Program Files (x86)\PTI\PSSE33\PSSBIN'), output_folder = SIMP(statut="o", typ="Repertoire"), @@ -112,7 +135,7 @@ CASE_SELECTION = MACRO ( nom = "CASE_SELECTION", ) N_PROCESSING_OPTIONS = PROC ( nom = 'N_PROCESSING_OPTIONS', op = None, - ang = "Select whether the program should be displaying data ablout the different categories. The values displayed will be the min, max, and mean of each item, plus a chart.", + ang = "Select whether the program should be displaying data about the different categories.\nThe values displayed will be the min, max, and mean of each item, plus a chart.", Output_bus_values = SIMP(statut = 'o', typ = bool, defaut = True), Output_lines_values = SIMP(statut = 'o', typ = bool, defaut = True), Output_transformer_values = SIMP(statut = 'o', typ = bool, defaut = True), @@ -128,7 +151,7 @@ N_PROCESSING_OPTIONS = PROC ( nom = 'N_PROCESSING_OPTIONS', CONTINGENCY_OPTIONS = PROC (nom = 'CONTINGENCY_OPTIONS', op = None, - + GeneralOptions = FACT(statut='o', Vmin = SIMP(statut = 'o', typ = 'R', defaut = 0.9, val_min = 0), Vmax = SIMP(statut = 'o', typ = 'R', defaut = 1.1, val_min = 0), @@ -139,7 +162,8 @@ CONTINGENCY_OPTIONS = PROC (nom = 'CONTINGENCY_OPTIONS', TripLines = SIMP(statut = 'o', typ = bool, defaut = True), TripTransfos = SIMP(statut = 'o', typ = bool, defaut = True), TripGenerators = SIMP(statut = 'o', typ = bool, defaut = True), - ), + TripBuses = SIMP(statut = 'o', typ = bool, defaut = False), + ), LoadFlowOptions = FACT(statut='o', AdjustTaps = SIMP(statut = 'o', typ = 'TXM', into = ['0 - Lock', '1 - Stepping', '2 - Direct'], defaut = '1 - Stepping'), @@ -150,15 +174,15 @@ CONTINGENCY_OPTIONS = PROC (nom = 'CONTINGENCY_OPTIONS', FlatStart = SIMP(statut = 'o', typ = bool, defaut = False), VarLimits = SIMP(statut = 'o', typ = 'I', defaut = 99,ang = 'if set to -1, var limits will not be applied'), ), - - OutputOptions = FACT(statut='o', - consigne1 = SIMP(statut='o',homo='information',typ = "TXM",defaut = 'Output PSSE multiple contingency report to Shell?'), - MultipleContingencyReport = SIMP(statut = 'o', typ = bool, defaut = True, ang = 'Output PSSE multiple contingency report to Shell?'), - consigne2 = SIMP(statut='o',homo='information',typ = "TXM",defaut = 'Write an Excel file for the results of each case file?'), - WriteIndivExcels = SIMP(statut = 'o', typ = bool, defaut = True), - consigne3 = SIMP(statut='o',homo='information',typ = "TXM",defaut = 'Add a tab in Excel results file for the differences between the max flow rate (MVAR) and the actual flow rate in lines and transformers?'), - WriteFlowDifs = SIMP(statut = 'o', typ = bool, defaut = True), - ), + +# OutputOptions = FACT(statut='o', +# consigne1 = SIMP(statut='o',homo='information',typ = "TXM",defaut = 'Output PSSE multiple contingency report to Shell?'), +# MultipleContingencyReport = SIMP(statut = 'o', typ = bool, defaut = True, ang = 'Output PSSE multiple contingency report to Shell?'), +# consigne2 = SIMP(statut='o',homo='information',typ = "TXM",defaut = 'Write an Excel file for the results of each case file?'), +# WriteIndivExcels = SIMP(statut = 'o', typ = bool, defaut = True), +# consigne3 = SIMP(statut='o',homo='information',typ = "TXM",defaut = 'Add a tab in Excel results file for the differences between the max flow rate (MVAR) and the actual flow rate in lines and transformers?'), +# WriteFlowDifs = SIMP(statut = 'o', typ = bool, defaut = True), +# ), ) @@ -167,17 +191,20 @@ CONTINGENCY_OPTIONS = PROC (nom = 'CONTINGENCY_OPTIONS', CONTINGENCY_SELECTION = PROC(nom='CONTINGENCY_SELECTION',op = None, SelectionMethod = SIMP(statut='o',typ='TXM',into=['CaseSelectionFromFile','SelectAllCases','SelectWorstCases'], ), - + b_file = BLOC(condition="SelectionMethod=='CaseSelectionFromFile'", CaseSelectionFromFiles = FACT( statut = 'o', - regles=(AU_MOINS_UN('branch_cases','transformer_cases','high_voltage_cases','low_voltage_cases',),), - branch_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde'),), - transformer_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde',),), - high_voltage_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde'),), - low_voltage_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde'),), + case = FACT(statut='o',max='**', + case_name=SIMP(statut='o',typ='TXM'), + csv_file= SIMP(statut='o', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)',),),), +# regles=(AU_MOINS_UN('branch_cases','transformer_cases','high_voltage_cases','low_voltage_cases',),), +# branch_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde'),), +# transformer_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde',),), +# high_voltage_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde'),), +# low_voltage_cases = SIMP(statut='o', defaut='', typ = ('Fichier', 'CSV file (*.csv);;All Files (*)','Sauvegarde'),), ), - + # CaseSelectionFromFile = FACT( # statut = 'o', # input_path = SIMP(statut="o",typ='Repertoire'), @@ -186,23 +213,24 @@ CONTINGENCY_SELECTION = PROC(nom='CONTINGENCY_SELECTION',op = None, # high_cases = SIMP(statut='o', typ='TXM'), # low_cases = SIMP(statut='o', typ='TXM'), # ), - + ), - + # b_all = BLOC(condition="SelectionMethod=='SelectAllCases'", # SelectAllCases = FACT( # statut='o', # all_cases = SIMP(statut='o', typ=bool, defaut = True), # ), # ), - + b_worst = BLOC(condition="SelectionMethod=='SelectWorstCases'", SelectWorstCases = FACT( - regles = (UN_PARMI('AvgBranchLoad', 'AvgBranchLoadPercent'), UN_PARMI('AvgTransformerLoad', 'AvgTransformerLoadPercent'), UN_PARMI('AvgHighVoltage', 'AvgHighVoltagePercent'), UN_PARMI('AvgLowVoltage', 'AvgLowVoltagePercent'),), + regles = (AU_MOINS_UN('AvgLineLoad', 'AvgLineLoadPercent','AvgTransformerLoad','AvgTransformerLoadPercent','AvgHighVoltage', 'AvgHighVoltagePercent','AvgLowVoltage', 'AvgLowVoltagePercent'), + EXCLUS('AvgLineLoad', 'AvgLineLoadPercent'),EXCLUS('AvgTransformerLoad','AvgTransformerLoadPercent'),EXCLUS('AvgHighVoltage', 'AvgHighVoltagePercent'),EXCLUS('AvgLowVoltage', 'AvgLowVoltagePercent'),), statut = 'o', consigne = SIMP(statut='o',homo='information',typ = "TXM",defaut = 'Choose at least one of the potential selection criteria from the SelectWorstCases list on the right.'), - AvgBranchLoad = SIMP(statut = 'f', typ = 'I', defaut = 0, val_min = 0), - AvgBranchLoadPercent = SIMP(statut = 'f', typ = 'I', defaut = 0, val_min = 0, val_max = 100), + AvgLineLoad = SIMP(statut = 'f', typ = 'I', defaut = 0, val_min = 0), + AvgLineLoadPercent = SIMP(statut = 'f', typ = 'I', defaut = 0, val_min = 0, val_max = 100), AvgTransformerLoad = SIMP(statut = 'f', typ = 'I', defaut = 0, val_min = 0), AvgTransformerLoadPercent = SIMP(statut = 'f', typ = 'I', defaut = 0, val_min = 0, val_max = 100), AvgHighVoltage = SIMP(statut = 'f', typ = 'I', defaut = 0, val_min = 0), @@ -214,10 +242,10 @@ CONTINGENCY_SELECTION = PROC(nom='CONTINGENCY_SELECTION',op = None, Automatic_N_2_Selection = FACT(statut='f', - + BusesList = SIMP(statut = 'o', typ = 'R', min = 0, max = '**', defaut = (), homo = 'SansOrdreNiDoublon'), LinesList = SIMP(statut = 'o', typ = 'R', min = 0, max = '**', defaut = (), homo = 'SansOrdreNiDoublon'), - TransformersList = SIMP(statut = 'o', typ = 'TXM', min = 0, max = '**', defaut = (), homo = 'SansOrdreNiDoublon'), + TransformersList = SIMP(statut = 'o', typ = 'TXM', min = 0, max = '**', defaut = (), homo = 'SansOrdreNiDoublon'), ), MultipleContingencyList = FACT (statut='f', @@ -230,7 +258,7 @@ CONTINGENCY_SELECTION = PROC(nom='CONTINGENCY_SELECTION',op = None, CONTINGENCY_PROCESSING = MACRO ( nom = 'CONTINGENCY_PROCESSING', sd_prod = opsPSEN_N1.PROCESS, op_init = opsPSEN_N1.PROCESS_context, - + #sd_prod=None, op = None, @@ -238,13 +266,15 @@ CONTINGENCY_PROCESSING = MACRO ( nom = 'CONTINGENCY_PROCESSING', fr = "", ang="", XLS_file = SIMP(statut="o", typ = ('Fichier', 'XLS file (*.xls);;All Files (*)',),), - TabList = SIMP(statut = 'f', typ = 'TXM', min = 0, max = '**', homo = 'SansOrdreNiDoublon'), - + b_TabList = BLOC(condition="XLS_file != None and XLS_file != ''", + TabList = SIMP(statut = 'o', typ = 'TXM', min = 0, max = '**', defaut = (), homo = 'SansOrdreNiDoublon'), ), + # b_highVoltage = BLOC(condition="'High Voltage 0' in TabList", # HighVoltageBuses = SIMP(statut = 'o', typ = 'TXM', min = 0, max = '**', defaut = (), homo = 'SansOrdreNiDoublon'), # HighVoltageContingencies = SIMP(statut = 'o', typ = 'TXM', min = 0, max = '**', defaut = (), homo = 'SansOrdreNiDoublon'), # ), - + ) -Ordre_Des_Commandes = ('CASE_SELECTION' , 'N_PROCESSING_OPTIONS' , 'CONTINGENCY_OPTIONS' , 'CONTINGENCY_SELECTION',) +Ordre_Des_Commandes = ('CASE_SELECTION' , 'N_PROCESSING_OPTIONS' , 'CONTINGENCY_SELECTION', 'CONTINGENCY_OPTIONS' ,'CONTINGENCY_PROCESSING',) +Classement_Commandes_Ds_Arbre = ('CASE_SELECTION' , 'N_PROCESSING_OPTIONS' , 'CONTINGENCY_SELECTION', 'CONTINGENCY_OPTIONS' ,'CONTINGENCY_PROCESSING',) diff --git a/ProcessOutputs_Eficas/configuration_PSEN_N1.py b/ProcessOutputs_Eficas/configuration_PSEN_N1.py index 4ab64b85..9ed5eb53 100644 --- a/ProcessOutputs_Eficas/configuration_PSEN_N1.py +++ b/ProcessOutputs_Eficas/configuration_PSEN_N1.py @@ -33,7 +33,7 @@ class CONFIG(configuration.CONFIG_BASE): #----------------------------------- self.labels_user=['catalogues','lang'] - self.labels_eficas=['lang','rep_cata','catalogues'] + self.labels_eficas=['lang','rep_cata','catalogues','affiche'] configuration.CONFIG_BASE.__init__(self,appli,'.Eficas_monCode') diff --git a/ProcessOutputs_Eficas/mesScripts_PSEN_N1.py b/ProcessOutputs_Eficas/mesScripts_PSEN_N1.py index f3c14732..12bf5db9 100644 --- a/ProcessOutputs_Eficas/mesScripts_PSEN_N1.py +++ b/ProcessOutputs_Eficas/mesScripts_PSEN_N1.py @@ -1,45 +1,13 @@ def EficasProcessXLS(listeparam) : print "dans processXLS" item=listeparam[0] - fileNameObj=item.object.get_child('XLS_file') - if fileNameObj : fileName=fileNameObj.get_valeur() - else : fileName = "" - if fileName == "" : return 0, 'Nom de fichier invalide' + dico=item.process_N1() + print dico - ongletListObj=item.object.get_child('Onglets') - if ongletListObj : ongletList= ongletListObj.get_valeur() - else : ongletList = [] - if ongletList == [] : return 0, 'ongletList invalide' - - busListObj=item.object.get_child('BusList') - if busListObj : busList= busListObj.get_valeur() - else : busList = [] - if busList == [] : return 0, 'BusList invalide' - - contListObj=item.object.get_child('ContList') - if contListObj : contList=contListObj.get_valeur() - else : contList = [] - if contList == [] : return 0, 'ContList invalide' - - dicoBus={} - dicoCont={} - for onglet in ongletList: - recherche=str(" ("+ str(onglet) +" )") - listeBusPourOnglet=[] - listeContPourOnglet=[] - for bus in busList : - nomBusSplit=str(bus).split(recherche) - if len(nomBusSplit) == 2 : listeBusPourOnglet.append(nomBusSplit[0]) - for cont in contList : - nomContSplit=str(cont).split(recherche) - if len(nomContSplit) == 2 : listeContPourOnglet.append(nomContSplit[0]) - if listeBusPourOnglet != [] : dicoBus[onglet]=listeBusPourOnglet - if listeContPourOnglet != [] : dicoCont[onglet]=listeContPourOnglet - - from Processor import processXLS - processXLS(fileName,dicoBus,dicoCont) + print "version pour Pascale --> decommenter les 2 lignes suivantes pour Laura" + #from Processor import processXLS + #processXLS(dico) - #if nouvelleVal != [] : prob.set_valeur(nouvelleVal) # le dictionnaire des commandes a la structure suivante : # la clef est la commande qui va proposer l action @@ -51,7 +19,5 @@ def EficasProcessXLS(listeparam) : # - appelable depuis un item valide uniquement # - toolTip dict_commandes={ - 'CONTINGENCY_PROCESSING': ( - (EficasProcessXLS,"process",('item',),False,True,"process values "), - ), - } + 'CONTINGENCY_PROCESSING': ( (EficasProcessXLS,"process",('editor','item',),False,True,"process values "),), + } diff --git a/ProcessOutputs_Eficas/opsPSEN_N1.py b/ProcessOutputs_Eficas/opsPSEN_N1.py index 55de6fdc..9554556b 100644 --- a/ProcessOutputs_Eficas/opsPSEN_N1.py +++ b/ProcessOutputs_Eficas/opsPSEN_N1.py @@ -19,21 +19,21 @@ # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com # -print "version en dur" -from ExtractGeneratorLoadLineandTransfoDico import * -#from ExtractGeneratorLoadLineandTransfoDico import ExtractGeneratorLoadLineandTransfoDico2 +from ExtractGeneratorLoadLineandTransfoDicoProcess import * +import os -#import Storage +path1 = os.path.abspath(os.path.join(os.path.abspath(__file__), '../','TreatOutputs')) +sys.path.append(path1) +import Options def INCLUDE(self,PSSE_path,**args): """ Fonction sd_prod pour la macro INCLUDE """ CaseFolder = args['output_folder'] - #Storage.MaximumDepth = args['MaxDepth'] - #print('casefolder loaded') - if CaseFolder==None: return - + Options.RecursiveDepth = args['MaxDepth'] + if CaseFolder==None: + return reevalue=0 if hasattr(self,'fichier_ini'): reevalue=1 @@ -57,7 +57,7 @@ def INCLUDE(self,PSSE_path,**args): CaseFile = '' FolderList = os.listdir(CaseFolder) for folder in FolderList: - if folder[0:7] == 'package': + if folder[0:7] == 'package' or folder[0:4]== 'core': # Get BaseCase.sav inside the first package folder we find FolderContents = os.listdir(os.path.join(CaseFolder, folder)) for file in FolderContents: @@ -65,44 +65,42 @@ def INCLUDE(self,PSSE_path,**args): CaseFile = os.path.join(os.path.join(CaseFolder, folder), file) break break - print "ops before try" - try: - #MachineDico,LoadDico,LineDico,TransfoDico,MotorDico,BusDico,BranchesDico,BusNominal = ExtractGeneratorLoadLineandTransfoDico(CaseFile, PSSE_path) - # BusList = getBusNominalkV(CaseFile) + #try: + if 1 : BusList, LinesList, TransfosList = getNominalkV(CaseFile) + #print "version en dur : decommenter la ligne suivante" #getTrueLines(CaseFile) - except Exception, e: - exc_type, exc_obj, exc_tb = sys.exec_info() - print(e) - print(exc_type, exc_tb.tb_lineno) + #except Exception, e: + # exc_type, exc_obj, exc_tb = sys.exec_info() + # print(e) + # print(exc_type, exc_tb.tb_lineno) + for e in self.jdc.etapes: if e.nom == 'CASE_SELECTION' : etape=e break - self.jdc.appli.changeIntoMC(e, 'BusesList', BusList) - self.jdc.appli.changeIntoMC(e, 'LinesList', LinesList) - self.jdc.appli.changeIntoMC(e, 'TransformersList', TransfosList) + self.jdc.editor.changeIntoMC(e, 'BusesList', BusList) + self.jdc.editor.changeIntoMC(e, 'LinesList', LinesList) + self.jdc.editor.changeIntoMC(e, 'TransformersList', TransfosList) - self.jdc.appli.changeIntoDefMC('CONTINGENCY_SELECTION', ('Automatic_N_2_Selection', 'BusesList'), BusList) - self.jdc.appli.changeIntoDefMC('CONTINGENCY_SELECTION', ('Automatic_N_2_Selection', 'LinesList'), LinesList) - self.jdc.appli.changeIntoDefMC('CONTINGENCY_SELECTION', ('Automatic_N_2_Selection', 'TransformersList'), TransfosList) + self.jdc.editor.changeIntoDefMC('CONTINGENCY_SELECTION', ('Automatic_N_2_Selection', 'BusesList'), BusList) + self.jdc.editor.changeIntoDefMC('CONTINGENCY_SELECTION', ('Automatic_N_2_Selection', 'LinesList'), LinesList) + self.jdc.editor.changeIntoDefMC('CONTINGENCY_SELECTION', ('Automatic_N_2_Selection', 'TransformersList'), TransfosList) try: - #updateConts() - #self.jdc.appli.changeIntoDefMC('CONTINGENCY_SELECTION', ('MultipleContingencyList', 'ComponentList'), Storage.ContFullList) - ContFullList=('AAAA','ZER','t__uuu','nkop','iop') - self.jdc.appli.changeIntoDefMC('CONTINGENCY_SELECTION', ('MultipleContingencyList', 'ComponentList'), ContFullList) - except Exception, e: + print "version en dur : decommenter la ligne suivante" + #a = updateConts() + self.jdc.editor.changeIntoDefMC('CONTINGENCY_SELECTION', ('MultipleContingencyList', 'ComponentList'), Options.ContFullList) + except Exception as e: exc_type, exc_obj, exc_tb = sys.exec_info() print(e) print(exc_type, exc_tb.tb_lineno) - #self.jdc.ajoutMC(e,'TransfosList',listeTuple) @@ -113,29 +111,24 @@ def INCLUDE_context(self,d): for k,v in self.g_context.items(): d[k]=v -def getXLS(fileName) : - dico={} - dico['onglet1']=(('bus1','bus2','bus3'),('contin1','contin2','contin3')) - dico['onglet2']=(('bus4','bus5'),('contin4','contin5','contin6')) - dico['onglet3']=(('bus6','bus7'),('contin8',)) - print dico - return dico - def PROCESS_context(self,d): print "dans le init du Process" + if self.get_child('XLS_file').valeur == "" or self.get_child('XLS_file').valeur== None : return + self.OngletsSelectionnes= self.get_child('b_TabList').get_child('TabList').valeur + print "fin de PROCESS_context" def PROCESS(self,XLS_file,**args): - - - print "dans PROCESS" + # self = Accas.A_MACRO_ETAPE.MACRO_ETAPE + self.sauve_args=args if XLS_file == "" or XLS_file == None: return + #print XLS_file #Storage.csvFileName = XLS_file - # c est la premier fois + # c est la premiere fois if not (hasattr(self,'sheets')) : - print "dans if" + #print 'attention en dur' #from Processor_Storage import * #print getSheets #getSheets() @@ -144,20 +137,14 @@ def PROCESS(self,XLS_file,**args): #print ContingencyList #Storage.selectedDoubleRow[Storage.sheets[0]]=['PV MATIMBA'] #Storage.selectedDoubleCol[Storage.sheets[0]]=['MAZENOD_MHDAM_LI1_'] - #self.jdc.appli.changeIntoMC(self,'TabList',Storage.sheets) + #self.jdc.editor.changeIntoMC(self,'TabList',Storage.sheets) #self.sheets=Storage.sheets #self.OngletsValeurs=[] - self.sheets=getXLS(XLS_file) - self.jdc.appli.changeIntoMC(self,'TabList',self.sheets.keys()) - - for k in self.sheets.keys(): - nom='Component_List_For_'+k - monInto=self.sheets[k][0] - self.jdc.appli.ajoutDefinitionMC('CONTINGENCY_PROCESSING',nom,'TXM',min=0, max='**', into=monInto, homo= 'SansOrdreNiDoublon') - nom='Contingency_List_For_'+k - monInto=self.sheets[k][1] - self.jdc.appli.ajoutDefinitionMC('CONTINGENCY_PROCESSING',nom,'TXM',min=0, max='**', into=monInto, homo= 'SansOrdreNiDoublon') + from Processor import getXLSinfo + self.sheets = getXLSinfo(XLS_file) + self.jdc.editor.changeIntoMC(self,'TabList',self.sheets.keys(),('b_TabList',)) + self.MCAjoutes=[] self.OngletsSelectionnes=[] @@ -165,23 +152,28 @@ def PROCESS(self,XLS_file,**args): # On a selectionne un onglet # On teste si on a modifie la liste des onglets - nouveauxOngletsSelectionnes= self.get_child('TabList').getval() + nouveauxOngletsSelectionnes= self.get_child('b_TabList').get_child('TabList').valeur if nouveauxOngletsSelectionnes==self.OngletsSelectionnes : return if nouveauxOngletsSelectionnes==() or nouveauxOngletsSelectionnes == [] : - for MC in self.MCAjoutes : - self.jdc.appli.deleteMC(self,MC) + for MC in self.MCAjoutes : self.jdc.editor.deleteMC(self,MC,('b_TabList',)) self.MCAjoutes=[] self.OngletsSelectionnes=[] + self.jdc.editor.fenetreCentraleAffichee.reaffiche() return for Onglet in nouveauxOngletsSelectionnes: if Onglet in self.OngletsSelectionnes : continue - MCFils='Contingency_List_For_'+Onglet - self.jdc.appli.ajoutMC(self,MCFils,[]) - self.MCAjoutes.append(MCFils) MCFils='Component_List_For_'+Onglet - self.jdc.appli.ajoutMC(self,MCFils,[]) + monInto=self.sheets[Onglet][0] + self.jdc.editor.ajoutDefinitionMC('CONTINGENCY_PROCESSING',('b_TabList',),MCFils,'TXM',min=0, max='**', into=monInto, homo= 'SansOrdreNiDoublon') + self.jdc.editor.ajoutMC(self,MCFils,[],('b_TabList',)) + self.MCAjoutes.append(MCFils) + + MCFils='Contingency_List_For_'+Onglet + monInto=self.sheets[Onglet][1] + self.jdc.editor.ajoutDefinitionMC('CONTINGENCY_PROCESSING',('b_TabList',),MCFils,'TXM',min=0, max='**', into=monInto, homo= 'SansOrdreNiDoublon') + self.jdc.editor.ajoutMC(self,MCFils,[],('b_TabList',)) self.MCAjoutes.append(MCFils) @@ -189,35 +181,15 @@ def PROCESS(self,XLS_file,**args): if Onglet in nouveauxOngletsSelectionnes : continue MCFils='Contingency_List_For_'+Onglet - self.jdc.appli.deleteMC(self,MCFils) + self.jdc.editor.deleteMC(self,MCFils,('b_TabList',)) + self.jdc.editor.deleteDefinitionMC('CONTINGENCY_PROCESSING',('b_TabList',),MCFils) self.MCAjoutes.remove(MCFils) MCFils='Component_List_For_'+Onglet - self.jdc.appli.deleteMC(self,MCFils) + self.jdc.editor.deleteMC(self,MCFils,('b_TabList',)) + self.jdc.editor.deleteDefinitionMC('CONTINGENCY_PROCESSING',('b_TabList',),MCFils) self.MCAjoutes.remove(MCFils) self.OngletsSelectionnes=nouveauxOngletsSelectionnes - - - - # OldBusValeurs= self.get_child('BusList').getval() -# OldContValeurs= self.get_child('ContList').getval() -# if OldBusValeurs == None : OldBusValeurs=[] -# if OldContValeurs == None : OldContValeurs=[] -# -# listeBus=[] -# listeCont=[] -# listeBusCoches=[] -# listeContCoches=[] -# for o in OngletsValeurs : -# for b in self.dico[o][0]: -# texte=b+" ("+ str(o) +" )" -# listeBus.append(str(texte)) -# if texte in OldBusValeurs : listeBusCoches.append(str(texte)) -# for c in self.dico[o][1]: -# texte=c+" ("+ str(o) +" )" -# listeCont.append(str(texte)) -# if texte in OldContValeurs : listeContCoches.append(str(texte)) -# -# self.jdc.appli.changeIntoMCandSet(self,'BusList',listeBus,listeBusCoches) -# self.jdc.appli.changeIntoMCandSet(self,'ContList',listeCont,listeContCoches) + self.jdc.editor.fenetreCentraleAffichee.reaffiche() + diff --git a/ProcessOutputs_Eficas/prefs_PSEN_N1.py b/ProcessOutputs_Eficas/prefs_PSEN_N1.py index 00992868..ffebe865 100644 --- a/ProcessOutputs_Eficas/prefs_PSEN_N1.py +++ b/ProcessOutputs_Eficas/prefs_PSEN_N1.py @@ -34,8 +34,9 @@ lang='en' #'fr' encoding='iso-8859-1' docPath=repIni +affiche='ordre' # catalogues=( - ('PSEN_N1','default',os.path.join(repIni,'PSEN_Cata_N1.py'),'python','python'), + ('PSEN_N1','default',os.path.join(repIni,'PSEN_Cata_N1.py'),'ProcessOutputs','python'), ) diff --git a/ProcessOutputs_Eficas/qtEficas_PSEN_N1.py b/ProcessOutputs_Eficas/qtEficas_PSEN_N1.py index 77173360..948867b5 100755 --- a/ProcessOutputs_Eficas/qtEficas_PSEN_N1.py +++ b/ProcessOutputs_Eficas/qtEficas_PSEN_N1.py @@ -35,6 +35,13 @@ path1 = os.path.abspath(os.path.join(os.path.abspath(__file__),'TreatOutputs')) path1 = 'C:\\Logiciels DER\\PSEN_V15\\Code\\ProcessOutputs_Eficas\TreatOutputs' sys.path.append(path1) +print ('kjlkjlkjkl') +print ('kjlkjlkjkl') +print ('kjlkjlkjkl') +print ('kjlkjlkjkl') +print ('kjlkjlkjkl') +print ('kjlkjlkjkl') +print ('kjlkjlkjkl') from InterfaceQT4 import eficas_go -eficas_go.lance_eficas(code=prefs.code) +if __name__ == '__main__': eficas_go.lance_eficas(code=prefs.code) diff --git a/SPECA/SPECA_Cata_V2_00.py b/SPECA/SPECA_Cata_V2_00.py new file mode 100644 index 00000000..f6c34acf --- /dev/null +++ b/SPECA/SPECA_Cata_V2_00.py @@ -0,0 +1,458 @@ +## -*- coding: utf-8 -*- +# +## -------------------------------------------------- +## debut entete +## -------------------------------------------------- +# +from Accas import * + + +# rend disponible le type tuple (liste) +import types +class Tuple: + def __init__(self,ntuple): + self.ntuple=ntuple + + def __convert__(self,valeur): + if type(valeur) == types.StringType: + return None + if len(valeur) != self.ntuple: + return None + return valeur + + def info(self): + return "Tuple de %s elements" % self.ntuple + + __repr__=info + __str__=info + + + +# +#CONTEXT.debug = 1 + +VERSION_CATALOGUE="2.0.0"; + +JdC = JDC_CATA ( code = 'SPECA', + execmodul = None, + regles=(AU_MOINS_UN('SPECIFICATION_ANALYSE',), + AU_PLUS_UN('SPECIFICATION_ANALYSE',), + ), + )# Fin JDC_CATA + +## ----- SPECIFICATION DE L'ETUDE ----- ## +SPECIFICATION_ANALYSE= MACRO (nom = 'SPECIFICATION_ANALYSE', + op = None, + UIinfo = {"groupes":("Machine tournante",)}, + fr = "Specification des analyses", + TYPE_ANALYSE = SIMP(statut='o', typ='TXM',into=('STATIQUE', 'MODALE', 'HARMONIQUE', 'TRANSITOIRE', 'TRANSITOIRE_ACCIDENTEL','SYNTHESE')), + # pour V1.1 flexion uniquement + #TYPE_COMPORTEMENT = SIMP(statut='o', typ='TXM',into=('FLEXION'),defaut='FLEXION',fr="Renseignement du type de comportement voulu"), + TYPE_COMPORTEMENT = BLOC(condition = "TYPE_ANALYSE in ('MODALE','HARMONIQUE','STATIQUE','TRANSITOIRE','TRANSITOIRE_ACCIDENTEL','SYNTHESE')", + FLEXION = SIMP(statut='o',typ='TXM',into=('OUI',),defaut='OUI',fr="Prise en compte la flexion de la ligne d'arbres: obligatoire"), + TORSION = SIMP(statut='f',typ='TXM',into=('OUI','NON'),defaut='NON',fr="Choix de la prise en compte la torsion de la ligne d'arbres"), + COMPRESSION = SIMP(statut='f',typ='TXM',into=('OUI','NON'),defaut='NON',fr="Choix de la prise en compte la traction/compression de la ligne d'arbres"), + ), + + SURCHARGE=BLOC(condition = "TYPE_ANALYSE in ('MODALE','HARMONIQUE','STATIQUE','TRANSITOIRE','TRANSITOIRE_ACCIDENTEL','SYNTHESE')",statut="f", + TEMPLATE=SIMP( statut="f", + typ=("Fichier","Fichier Template (*.tpl)"), + min=1,max=1, + fr="Utiliser un template d'analyse modifie" + ), + PARAMETRES= FACT(statut='f',min=1,max='**',fr="Definition et renseignement des parametres utilises dans le template surcharge", + CLE=SIMP(statut='o',typ='TXM',defaut=None,fr="Nom du parametre dans le template"), + TYPE=SIMP(statut='o',typ='TXM',into=('ENTIER','REEL','CHAINE','FICHIER','REPERTOIRE'),fr="Nature du parametre a renseigner"), + ENTIER=BLOC(condition="TYPE=='ENTIER'", + VALUE=SIMP(statut='o',typ='I',defaut=0,fr="Renseignement d'un nombre entier"), + ), + REEL=BLOC(condition="TYPE=='REEL'", + VALUE=SIMP(statut='o',typ='R',defaut=0.0,fr="Renseignement d'un nombre reel"), + ), + CHAINE=BLOC(condition="TYPE=='CHAINE'", + VALUE=SIMP(statut='o',typ='TXM',defaut='',fr="Renseignement d'une chaine de caracteres"), + ), + FICHIER=BLOC(condition="TYPE=='FICHIER'", + VALUE=SIMP(statut='o',typ=("Fichier","All files (*.*)"),fr="Renseignement d'un fichier") + ), + REPERTOIRE =BLOC(condition="TYPE=='REPERTOIRE'", + VALUE=SIMP(statut='o',typ="Repertoire",fr="Renseignement d'un repertoire") + ), + + ), + ), + + + +### ----- CALCUL STATIQUE ----- ## + ANALYSE_STATIQUE = BLOC(condition = "TYPE_ANALYSE == 'STATIQUE' ",fr="Analyse statique (vitesse de rotation nulle de la ligne d'arbres)" + + CHARGES= FACT(statut='o',min=1,max='**',fr="Definition et renseignement du chargement applique", + TYPE = SIMP(statut='o',typ='TXM',into=('POIDS','FORCE','MOMENT','DELIGNAGE'),defaut=None,min=1,max=1,fr="Choix du type de chargement a appliquer"), + POIDS = BLOC(condition = "TYPE == 'POIDS' ",fr="Prise en compte du champ de pesanteur", + GRAVITE = SIMP(statut='o',typ='R',defaut=9.81,fr="Renseignement de l'intensite de la gravite (m/s^2)"), + DIRECTION = SIMP(statut='o',typ='R',min=3,max=3,defaut=(1,0,0),fr="Renseignement de la direction de la force de gravite"), + ), # fin POIDS + FORCE = BLOC(condition = "TYPE == 'FORCE' ",fr="Application d'une force ponctuelle", + POSITION = SIMP(statut='o',typ='R',defaut=None,fr="Renseignement de la position axiale ou s'applique la force (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=3,max=3,defaut=None,fr="Renseignement des 3 composantes decrivant la force (N)"), + #FONC_APPLI = SIMP(statut='f',typ='R',min=2,max=2,defaut=None,fr="Renseignement de la fonction appliquee"), + ), # fin FORCE + MOMENT = BLOC(condition = "TYPE == 'MOMENT' ",fr="Application d'un moment ponctuel", + POSITION = SIMP(statut='o',typ='R',defaut=None,fr="Renseignement de la position axiale ou s'applique le moment (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=3,max=3,defaut=None,fr="Renseignement des 3 composantes decrivant le moment (N/m)"), + ), # fin MOMENT + DELIGNAGE = BLOC(condition = "TYPE == 'DELIGNAGE' ",fr="Application d'un delignage sur un ou plusieurs paliers", + NOM_PALIER = SIMP(statut='o',typ='TXM',min=1,max=1,defaut=None,fr="Renseignement du nom du palier deligne"), + DX = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du delignage suivant X du palier (m)"), + DY = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du delignage suivant Y du palier (m)"), + ), # fin Delignage + ), #fin CHARGES + + ## POST-TRAITEMENTS DU CALCUL STATIQUE + POST_TRAITEMENTS = FACT(statut='o',max='**',fr="Definition et renseignement des post-traitements", + TYPE = SIMP(statut='o',typ='TXM',into=('DEPL_ABS','DEPL_RELA','EFFORTS_PAL','REAC_NODA','CONTRAINTES'),defaut=None,fr="Choix du type de post-traitement"), + DEPL = BLOC(condition="TYPE in ('DEPL_ABS','DEPL_RELA') ",fr="Deplacement",regles=UN_PARMI('POSITION','PALIER'), + POSITION = SIMP(statut='f',typ='R',defaut=None,fr="Renseignement de la coordonnee du deplacement"), + PALIER = SIMP(statut='f',max='**',typ='TXM',defaut=None,fr="Renseignement du nom du palier"), + ), # fin DEPL + CONTRAINTES = BLOC(condition="TYPE == 'CONTRAINTES' ",fr="Export des contraintes",regles=UN_PARMI('POSITION','ZONE','TOUT'), + POSITION = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la coordonnee de la contrainte"), + ZONE = SIMP(statut='f',typ='TXM',defaut=None,fr="Renseignement de la zone de la contrainte"), + TOUT = SIMP(statut='f',typ='TXM',into=('OUI'),fr="Export pour tous les noeuds"), + ), # fin CONTRAINTES + REAC_NODA = BLOC(condition="TYPE == 'REAC_NODA' ", fr="Reaction nodale",regles=UN_PARMI('POSITION','PALIER'), + POSITION = SIMP(statut='f',typ='R',max=1,defaut=None,fr="Renseignement de la coordonnee de la reaction"), + #ZONE = SIMP(statut='f',typ='TXM',defaut=None,fr="Renseignement de l'etiquette de la zone de la reaction"), + PALIER = SIMP(statut='f',max='**',typ='TXM',defaut=None,fr="Renseignement du nom du palier"), + ), # fin REAC_NODA + ), # fin POST_TRAITEMENT + ## fin bloc POST_TRAITEMENTS + + ),# fin ANALYSE_STATIQUE + +### ----- CALCUL MODALE ----- ## + ANALYSE_MODALE = BLOC(condition = "TYPE_ANALYSE == 'MODALE' ",fr="Analyse modale de la ligne d'arbres" + BASE_CALCUL = SIMP(statut='o',typ="TXM",into=('MODALE','PHYSIQUE'),defaut=None,fr="Choix du type de resolution de l'analyse modale (sur base physique ou sur base modale)"), + BASE_MODALE = BLOC(condition="BASE_CALCUL=='MODALE'",fr="Resolution sur base modale", + regles=UN_PARMI('NB_MODES','FREQ_MAX'), + NB_MODES=SIMP(statut='f',typ='I',min=1,max=1,defaut=None,fr="Renseignement du nombre de modes constituant la base de projection"), + FREQ_MAX=SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence maximale des modes constituant la base de projection (Hz)"), + ), # fin BASE_MODALE + AMORTISSEMENT = SIMP(statut='o',typ='TXM',min=1,max=1,into=('OUI','NON'),defaut='OUI',fr="Choix de la prise en compte de l'amortissment"), + GYROSCOPIE = SIMP(statut='o',typ='TXM',min=1,max=1,into=('OUI','NON'),defaut='OUI',fr="Choix de la prise en compte de la gyroscopie"), + VITESSE_ROTATION = SIMP(statut='o',typ='R',min=1,max='**',defaut=None,fr="Renseignement de la liste des vitesses de rotation etudiees (tr/min)"), + OPTION_CALCUL = SIMP(statut='o',typ='TXM',min=1,max=1,into=('PLUS_PETITE','CENTRE'),defaut=None,fr="Choix de l'option de calcul"), + PLUS_PETITE = BLOC(condition="OPTION_CALCUL=='PLUS_PETITE'",fr="Option PLUS_PETITE",fr="Calcul des n premieres frequences" + NMAX_FREQ = SIMP(statut='o',typ='I',min=1,max=1,defaut=None,fr="Renseignement du nombre maximal de frequences a calculer"), + ), # fin PLUS_PETITE + CENTRE = BLOC(condition="OPTION_CALCUL=='CENTRE'",fr="Option CENTRE",fr="Calcul d'un nombre n de frequences autour d'une frequence donnee" + FREQ = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence centrale (Hz)"), + NMAX_FREQ = SIMP(statut='o',typ='I',min=1,max=1,defaut=None,fr="Renseignement du nombre maximal de frequences"), + ), # fin CENTRE + METHODE=SIMP(statut='f',typ='TXM',min=1,max=1,into=('QZ','SORENSEN'),defaut='SORENSEN',fr="Choix de la methode de resolution"), + + POST_TRAITEMENTS = FACT(statut='o',max='**',fr="Definition et renseignement des post-traitements", + TYPE = SIMP(statut='o',typ='TXM',defaut=None,into=('TABLEAU_PARAM_MODAUX','DIAG_CAMPBELL'),fr="Choix du type de post-traitement",), + #TABLEAU_PARAM_MODAUX = SIMP(statut='f',typ='TXM',min=1,max=1,defaut=None,into=('SIMPLE','COMPLET'),fr="Choix du type de tableau"), + TABLEAU_PARAM_MODAUX = BLOC(condition = "TYPE == 'TABLEAU_PARAM_MODAUX'",fr="Choix du type de tableau", + TABLEAU = SIMP(statut='o',max=1,typ='TXM',defaut='SIMPLE',into=('SIMPLE','COMPLET'),), + ), # fin TABLEAU_PARAM_MODAUX + DIAG_CAMPBELL = BLOC(condition = "TYPE == 'DIAG_CAMPBELL'", fr = "Choix des options du diagramme de Campbell", + PRECESSION = SIMP(statut='o',typ='TXM',max=1,defaut=None,into=('SOMME','PLUS_GRANDE_ORBITE'),fr="Critere de determination de la precession"), + SUIVI = SIMP(statut='o',typ='TXM',max=1,defaut=None,into=('SANS_TRI','TRI_PREC','TRI_FORM_MOD'),fr="Methode de suivi des modes"), + # 20121018 ajout de NB_MODES a la demande de Ionel Nistor + NB_MODES = SIMP(statut='o',typ='I',max=1,defaut=None,fr="Nombre de modes affiches dans le diagramme, doit etre inferieur au nombre de modes calcules (NMAX_FREQ)"), + ), # fin DIAG_CAMPBELL + #DIAG_CAMPBELL = SIMP(statut='f',typ='TXM',min=1,max=1,defaut=None,into=('OUI','NON'),fr="Choix de calcul du diagramme de Campbell (uniquement si plusieurs vitesses de rotation ont ete renseignees)",), + ), # fin POST_TRAITEMENTS + + + ), # fin ANALYSE_MODALE + +## ----- CALCUL HARMONIQUE ----- ## + ANALYSE_HARMONIQUE = BLOC(condition = "TYPE_ANALYSE == 'HARMONIQUE' ",fr="Analyse harmonique de la ligne d'arbres", + + ## specification calcul harmonique + BASE_CALCUL = SIMP(statut='o',typ='TXM',into=('PHYSIQUE','MODALE'),defaut=None,fr="Choix du type de resolution de l'analyse modale (sur base physique ou sur base modale)"), + BASE_MODALE = BLOC(condition = "BASE_CALCUL == 'MODALE' ", fr="Resolution sur base modale", + #MODALE = FACT(statut='o', + regles=UN_PARMI('NB_MODES','FREQ_MAX'), + NB_MODES = SIMP(statut='f',typ='I',min=1,max=1,defaut=None,fr="Renseignement du nombre de modes constituant la base de projection"), + FREQ_MAX = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence maximale des modes constituant la base de projection (Hz)"), + #),# fin MODALE + ),# fin BASE_MODALE + AMORTISSEMENT_P = BLOC(condition = "BASE_CALCUL == 'PHYSIQUE' ", + AMORTISSEMENT = SIMP(statut='o', typ='TXM',into=('STRUCTUREL'),defaut=None,fr="Choix du type d'amortissement"), + ), # fin AMORTISSEMENT_P + AMORTISSEMENT_M = BLOC(condition = "BASE_CALCUL == 'MODALE' ", + AMORTISSEMENT = SIMP(statut='o', typ='TXM',into=('REDUIT','STRUCTUREL'),defaut=None,fr="Choix du type d'amortissement"), + AMOR_MODAL = BLOC(condition = "AMORTISSEMENT == 'REDUIT' ", + #AMOR_REDUIT = SIMP(statut='o', typ='R', min=1, max=1,defaut=None,fr="Renseignement de l'amortissement modal reduit (en %)"), + AMOR_REDUIT = SIMP(statut='o', typ='R', min=1, max='**',defaut=None,fr="Renseignement de l'amortissement modal reduit (en %), la taille de la liste doit etre egale au nombre de modes constituant la base de projection"), + ),# fin AMOR_MODALE + ), # fin AMORTISSEMENT_M + VITESSE_ROTATION = SIMP(statut='o',typ='R',min=1,max='**',defaut=None,fr="Renseignement de la liste des vitesses de rotation etudiees (tr/min)"), + # 20121018 retrait de defaut_fn a la demande de EDF + CHARGES= FACT(statut='o',min=1,max='**',fr="Definition et renseignement du chargement applique", + TYPE = SIMP(statut='o',typ='TXM',into=('BALOURD','HARMONIQUE'),defaut=None,min=1,max=1,fr="Choix du type de chargement a appliquer"), + BALOURD = BLOC(condition = "TYPE == 'BALOURD' ",fr="Chargement de type balourd", + POSITION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la position axiale ou s'applique le balourd (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de l'amplitude du balourd (kg.m)"), + PHASE_DEG = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du decalage de la phase de la charge balourd (degres)"), + ),# fin BALOURD + HARMONIQUE = BLOC(condition = "TYPE == 'HARMONIQUE' ",fr="Charge harmonique", + POSITION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la position axiale ou s'applique la charge harmonique (m)"), + FREQUENCE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence d'excitation harmonique (Hz)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de l'amplitude de la charge harmonique, (N)"), + FONC_APPLI = SIMP(statut='o',typ='R',min=1,max='**',defaut=None,fr="Renseignement de la liste de coefficients appliques sur la charge harmonique (autant que de vitesses de rotation)"), + PHASE_DEG = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du decalage de la phase de la charge harmonique (degres)"), + TYPE_DDL = SIMP(statut='o',typ='TXM',min=1,max=1,into=('DX','DRX','DY','DRY','DZ','DRZ'),defaut=None,fr="Renseignement du DDL sur lequel s'applique la charge harmonique"), + ), # fin HARMONIQUE + ), #FIN CHARGES + ## POST-TRAITEMENTS DU CALCUL HARMONIQUE + POST_TRAITEMENTS = FACT(statut='o',max='**',fr="Definition et renseignement des post-traitements", + TYPE = SIMP(statut='o',typ='TXM',into=('DEPL_RELA','REAC_NODA','EFFORTS_PAL','CONTRAINTES'),defaut=None,fr="Choix du type de post-traitement"), + DEPL = BLOC(condition = "TYPE in ('DEPL_ABS','DEPL_RELA') ",fr="Deplacement",regles=UN_PARMI('POSITION','PALIER'), + POSITION = SIMP(statut='f',typ='R',defaut=None,fr="Renseignement de la coordonnee du deplacement"), + PALIER = SIMP(statut='f',max='**',typ='TXM',defaut=None,fr="Renseignement du nom du palier"), + ), # fin DEPL + CONTRAINTES = BLOC(condition="TYPE == 'CONTRAINTES' ",fr="Export des contraintes",regles=UN_PARMI('POSITION','ZONE','TOUT'), + POSITION = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la coordonnee de la contrainte"), + ZONE = SIMP(statut='f',typ='TXM',min=1,max=1,defaut=None,fr="Renseignement du nom de la zone de la contrainte"), + TOUT = SIMP(statut='f',typ='TXM',into=('OUI'),min=1,max=1,fr="Export pour tous les noeuds"), + ), # fin CONTRAINTES + ), + ## fin bloc POST_TRAITEMENTS + + ),# fin ANALYSE_HARMONIQUE + +### ----- CALCUL TRANSITOIRE ----- ## + ANALYSE_TRANSISTOIRE = BLOC(condition = "TYPE_ANALYSE == 'TRANSITOIRE' ",fr="Analyse transitoire de la ligne d'arbres", + + VITESSE = SIMP(statut='o',typ='TXM',min=1,max=1,defaut=None,into=('CONSTANTE','VARIABLE'),fr="Renseignement du type de vitesse de rotation consideree"), + BASE_C = BLOC(condition ="VITESSE == 'CONSTANTE'",fr="Analyse transitoire a vitesse constante" + BASE_CALCUL = SIMP(statut='o',typ='TXM',into=('PHYSIQUE','MODALE'),defaut=None,fr="Choix du type de resolution de l'analyse transitoire (sur base physique ou sur base modale)"), + BASE_MODALE = BLOC(condition = "BASE_CALCUL == 'MODALE' ", fr="Resolution sur base modale", + regles=UN_PARMI('NB_MODES','FREQ_MAX'), + NB_MODES = SIMP(statut='f',typ='I',min=1,max=1,defaut=None,fr="Renseignement du nombre de modes constituant la base de projection"), + FREQ_MAX = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence maximale des modes constituant la base de projection (Hz)"), + ),# fin BASE_MODALE + AMORTISSEMENT_M = BLOC(condition = "BASE_CALCUL == 'MODALE' ", + AMORTISSEMENT = SIMP(statut='o', typ='TXM',into=('REDUIT','STRUCTUREL'),defaut=None,fr="Choix du type d'amortissement"), + AMOR_MODAL = BLOC(condition = "AMORTISSEMENT == 'REDUIT' ", + AMOR_REDUIT = SIMP(statut='o', typ='R', min=1, max='**',defaut=None,fr="Renseignement de l'amortissement modal reduit (en %), la taille de la liste doit etre egale au nombre de modes constituant la base de projection"), + ),# fin AMOR_MODALE + ), # fin AMORTISSEMENT_M + ), # fin BASE_C + BASE_V = BLOC(condition ="VITESSE == 'VARIABLE'",fr="Analyse transitoire a vitesse variable" + BASE_CALCUL = SIMP(statut='o',typ='TXM',into=('MODALE'),defaut='MODALE',fr="Choix du type de resolution de l'analyse transitoire (obligatoirement sur base modale)"), + BASE_MODALE = BLOC(condition = "BASE_CALCUL == 'MODALE' ", fr="Resolution sur base modale", + regles=UN_PARMI('NB_MODES','FREQ_MAX'), + NB_MODES = SIMP(statut='f',typ='I',min=1,max=1,defaut=None,fr="Renseignement du nombre de modes constituant la base de projection"), + FREQ_MAX = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence maximale des modes constituant la base de projection (Hz)"), + ),# fin BASE_MODALE + AMORTISSEMENT = SIMP(statut='o', typ='TXM',into=('REDUIT','STRUCTUREL'),defaut=None,fr="Choix du type d'amortissement"), + AMOR_MODAL = BLOC(condition = "AMORTISSEMENT == 'REDUIT' ", + #AMOR_REDUIT = SIMP(statut='o', typ='R', min=1, max=1,defaut=None,fr="Renseignement de l'amortissement modal reduit (en %)"), + AMOR_REDUIT = SIMP(statut='o', typ='R', min=1, max='**',defaut=None,fr="Renseignement de l'amortissement modal reduit (en %), la taille de la liste doit etre egale au nombre de modes constituant la base de projection"), + ),# fin AMOR_MODALE + ), # fin BASE_C + VITESSE_CONSTANTE = BLOC(condition = "VITESSE == 'CONSTANTE' ", fr="Vitesse de rotation constante", + VITESSE_ROTATION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la vitesse de rotation (tr/min)"), + ),# fin VITESSE_CONSTANTE + VITESSE_VARIABLE = BLOC(condition = "VITESSE == 'VARIABLE' ", fr="Vitesse de rotation variable", regles=UN_PARMI('LINEAIRE','EXPONENTIELLE','FORMULE'), + LINEAIRE = FACT(statut='f',min=1,max=1,fr="Variation lineaire de la vitesse de rotation", + VITESSE_INITIALE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la vitesse de rotation initiale (tr/min)",), + VITESSE_FINALE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la vitesse de rotation finale (tr/min)",), + DEPHASAGE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la postion angulaire initiale (degres)"), + PAS_MAJ = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement du pas de mise a jour des matrices des paliers (tr/min)"), + ),# fin LINEAIRE + EXPONENTIELLE = FACT(statut='f',min=1,max=1,fr="Variation exponentielle de la vitesse de rotation", + VITESSE_INITIALE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la vitesse de rotation initiale (tr/min)",), + VITESSE_FINALE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la vitesse de rotation finale (tr/min)",), + DEPHASAGE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la postion angulaire initiale (degres)"), + LAMBDA = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du parametre de la loi exponentielle (Hz)"), + PAS_MAJ = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement du pas de mise a jour des matrices des paliers (tr/min)"), + ),# fin EXPONENTIELLE + FORMULE = FACT(statut='f',min=1,max=1,fr="Fonction personnalisee decrivant la variation de la vitesse de rotation", + FICHIER = SIMP(statut='o',typ=('Fichier','Formule vitesse rotation (*.*)'),min=1,max=1,defaut=None,fr="Renseignement du fichier contenant les fonctions de la vitesse de rotation"), + PHI = SIMP(statut='o',typ='TXM',min=1,max=1,defaut=None,fr="Renseignement du nom de la formule de position angulaire (max 8 caractere)"), + OM = SIMP(statut='o',typ='TXM',min=1,max=1,defaut=None,fr="Renseignement du nom de la formule de vitesse angulaire (max 8 caractere)"), + ACC = SIMP(statut='o',typ='TXM',min=1,max=1,defaut=None,fr="Renseignement du nom de la formule d'acceleration angulaire (max 8 caractere)"), + VITE_MOY = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la moyenne des vitesses balayees (tr/min)"), + PAS_MAJ = SIMP(statut='f',typ='R',min=1,max='**',defaut=None,fr="Renseignement du pas de mise a jour des matrices des paliers (tr/min)"), + ),# fin FORMULE + ),# fin VITESSE_VARIABLE + #POIDS = SIMP(statut='o',typ='TXM',into=('OUI','NON'),defaut='OUI',fr="Choix d'application d'un poids"), + + CHARGES= FACT(statut='o',min=1,max='**',fr="Definition et renseignement du chargement applique", + TYPE = SIMP(statut='o',typ='TXM',into=('POIDS','BALOURD','FORCE','MOMENT','HARMONIQUE'),defaut=None,min=1,max=1,fr="Choix du type de chargement a appliquer"), + BALOURD = BLOC(condition = "TYPE == 'BALOURD' ",fr="Chargement de type balourd", + POSITION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la position axiale ou s'applique le balourd (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de l'amplitude du balourd (kg.m)"), + PHASE_DEG = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du decalage de la phase de la charge balourd (degres)"), + INST_APPLI= SIMP(statut='f',typ='R',min=1,max=1,defaut=0,fr="Renseignement de l'instant d'apparition du balourd (s)"), + TEMPS_MONTEE=SIMP(statut='f',typ='R',min=1,max=1,defaut=0,fr="Renseignement du temps necessaire pour atteindre l'amplitude nominale du balourd (s)"), + ),# fin BALOURD + POIDS = BLOC(condition = "TYPE == 'POIDS' ",fr="Prise en compte du champ de pesanteur", + GRAVITE = SIMP(statut='o',typ='R',defaut=9.81,fr="Renseignement de l'intensite de la gravite (m/s^2)"), + DIRECTION = SIMP(statut='o',typ='R',min=3,max=3,defaut=(1,0,0),fr="Renseignement de la direction de la force de gravite"), + ), # fin POIDS + FORCE = BLOC(condition = "TYPE == 'FORCE' ",fr="Application d'une force ponctuelle", + POSITION = SIMP(statut='o',typ='R',defaut=None,fr="Renseignement de la position axiale ou s'applique la force (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=3,max=3,defaut=None,fr="Renseignement des 3 composantes decrivant la force (N)"), + #FONC_APPLI = SIMP(statut='f',typ='R',min=2,max=2,defaut=None,fr="Renseignement de la fonction appliquee"), + ), # fin FORCE + MOMENT = BLOC(condition = "TYPE == 'MOMENT' ",fr="Application d'un moment ponctuel", + POSITION = SIMP(statut='o',typ='R',defaut=None,fr="Renseignement de la position axiale ou s'applique le moment (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=3,max=3,defaut=None,fr="Renseignement des 3 composantes decrivant le moment (N/m)"), + ), # fin MOMENT + HARMONIQUE = BLOC(condition = "TYPE == 'HARMONIQUE' ",fr="Charge harmonique", + POSITION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la position axiale ou s'applique la charge harmonique (m)"), + FREQUENCE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence d'excitation harmonique (Hz)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de l'amplitude de la charge harmonique, (N)"), + #FONC_APPLI = SIMP(statut='o',typ='R',min=1,max='**',defaut=None,fr="Renseignement de la fonction appliquee de la charge harmonique (autant de valeurs que de vitesses de rotation)"), + PHASE_DEG = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du decalage de la phase de la charge harmonique (degres)"), + TYPE_DDL = SIMP(statut='o',typ='TXM',min=1,max=1,into=('DX','DRX','DY','DRY','DZ','DRZ'),defaut=None,fr="Renseignement du DDL sur lequel s'applique la charge harmonique"), + ), # fin HARMONIQUE + ), #fin CHARGES + + ETAT_INIT = FACT(statut='o',fr="Renseignement de l'etat initial du calcul", + #RESULTAT = SIMP(statut='o',typ=('sd_resultat'),max=1,defaut=None,fr="Choix de la structure de donnees resultat de code aster "), + RESULTAT = SIMP(statut='f',typ='TXM',max=1,defaut=None,fr="Choix de la structure de donnees de type 'resultat' de Code_Aster"), + INST_INIT = SIMP(statut='f',typ='R',max=1,defaut=0.0,fr="Renseignement de l'instant de la structure de donnees a partir duquel il faut lancer le calcul (s)"), + ), # fin ETAT_INIT + PARAM_TEMPS = SIMP(statut='o',typ='TXM',max=1,into=('PAS','LISTE'),defaut=None,fr="Choix du type de discretisation temporelle"), + #PAS = BLOC(condition = "VITESSE == 'VARIABLE'",fr="Renseignement des parametres des pas", + PAS = BLOC(condition = "PARAM_TEMPS == 'PAS'",fr="Renseignement de pas de temps", + TEMPS_PAS = SIMP(statut='o',typ='R',max=1,defaut=None,fr="Renseignement du pas de temps d'integration(en s)"), + INST_INI = SIMP(statut='f',typ='R',max=1,defaut=None,fr="Renseignement de l'instant initial du calcul (s)"), + INST_FIN = SIMP(statut='o',typ='R',max=1,defaut=None,fr="Renseignement de l'instant final du calcul (s)"), + ), # fin TEMPS_PAS + LIST_INST = BLOC(condition = "PARAM_TEMPS == 'LISTE'",fr="Renseignement d'une liste d'instants", + LISTE = SIMP(statut='o',typ='R',min=1,max='**',defaut=None,fr="Renseignement d'une liste d'instants auxquels resoudre le calcul (s)"), + ), # fin LIST_INST + PAS_ARCHIVAGE = SIMP(statut='o',typ='I',max=1,defaut=1,fr="Renseignement du pas d'archivage des resultats (une sauvegarde tous les 'PAS_ARCHIVAGE' instants d'integration)",), + SCHEMA_TEMPS = SIMP(statut='o',typ='TXM',max=1,into=('NEWMARK','EULER','WILSON','ADAPT_ORDRE1','ADAPT_ORDRE2','DIFF_CENTRE'),defaut='NEWMARK',fr="Choix d'un schema d'integration temporelle"), + NEWMARK = BLOC(condition = "SCHEMA_TEMPS == 'NEWMARK' ",fr="Methode de NEWMARK", + BETA = SIMP(statut='f',typ='R',max=1,defaut=0.25,fr="Renseignement de la valeur beta pour la methode de NEWMARK"), + GAMMA = SIMP(statut='f',typ='R',max=1,defaut=0.25,fr="Renseignement de la valeur gamma pour la methode de NEWMARK"), + ),# fin NEWMARK + WILSON = BLOC(condition = "SCHEMA_TEMPS == 'WILSON' ",fr="Methode de WILSON", + THETA = SIMP(statut='f',typ='R',max=1,defaut=1.4,fr="Renseignement de la valeur theta pour la methode de WILSON"), + ), # fin WILSON + + ## POST_TRAITEMENTS de l'analyse transitoire + POST_TRAITEMENTS = FACT(statut='o',max='**',fr="Definition et renseignement des post-traitements", + TYPE = SIMP(statut='o',typ='TXM',into=('DEPL_ABS','DEPL_RELA','EFFORTS_PAL','CONTRAINTES'),defaut=None,fr="Choix du type de post-traitement"), + DEPL = BLOC(condition = "TYPE in ('DEPL_ABS','DEPL_RELA') ",fr="Deplacement",regles=UN_PARMI('POSITION','PALIER'), + #POSITION_DEPL = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la coordonnee du deplacement"), + POSITION = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la coordonnee du deplacement"), + PALIER = SIMP(statut='f',typ='TXM',max=1,defaut=None,fr="Renseignement de l'etiquette du palier"), + ), # fin DEPL + CONTRAINTES = BLOC(condition = "TYPE == 'CONTRAINTES' ",fr="Export des contraintes", + regles=UN_PARMI('POSITION','ZONE','TOUT'), + POSITION = SIMP(statut='f',typ='R',max=1,defaut=None,fr="Renseignement de la coordonnee de la contrainte"), + ZONE = SIMP(statut='f',typ='TXM',max=1,defaut=None,fr="Renseignement de l'etiquette de la zone de la contrainte"), + TOUT = SIMP(statut='f',typ='TXM',into=('OUI'),max=1,fr="Export pour tous les noeuds"), + ), # fin CONTRAINTES + ), # fin POST_TRAITEMENTS + + ), # fin ANALYSE_TRANSISTOIRE + + +### ----- CALCUL COUPLE CODE_ASTER/EYDOS ----- ## + ANALYSE_TRANSITOIRE_ACCIDENTEL = BLOC(condition = "TYPE_ANALYSE == 'TRANSITOIRE_ACCIDENTEL' ",fr="Analyse transitoire accidentelle de la ligne d'arbres", + #BASE_MODALE = FACT(statut='o', fr="Choix des parametres de la base modale", + #POIDS = SIMP(statut='o',typ='TXM',into=('OUI','NON'),defaut='OUI',fr="Choix d'application d'un poids"), + BASE_MODALE = BLOC(condition = "True", fr="Resolution sur base modale", + regles=UN_PARMI('NB_MODES','FREQ_MAX'), + NB_MODES = SIMP(statut='f',typ='I',min=1,max=1,defaut=None,fr="Renseignement du nombre de modes constituant la base de projection"), + FREQ_MAX = SIMP(statut='f',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence maximale des modes constituant la base de projection (Hz)"), + ),# fin BASE_MODALE + # cft 20131217 suppression amortissement reduit + #AMORTISSEMENT = SIMP(statut='o', typ='TXM',into=('STRUCTUREL','REDUIT'),defaut=None,fr="Choix du type d'amortissement"), + AMORTISSEMENT = SIMP(statut='o', typ='TXM',into=('STRUCTUREL'),defaut=None,fr="Choix du type d'amortissement"), + AMOR_REDUIT = BLOC(condition = "AMORTISSEMENT == 'REDUIT' ", + #LIST_AMOR = SIMP(statut='o', typ='R', min=1,max='**',defaut=None,fr="Renseignement de la liste des amortissements"), + LIST_AMOR = SIMP(statut='o', typ='R', min=1,max='**',defaut=None,fr="Renseignement de la liste des amortissements modaux reduits (en %), la taille de la liste doit etre egale au nombre de modes constituant la base de projection"), + ),# fin AMOR_REDUIT + VITESSE_ROTATION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la vitesse de rotation (tr/min)"), + + CHARGES= FACT(statut='o',min=1,max='**',fr="Definition et renseignement du chargement applique", + TYPE = SIMP(statut='o',typ='TXM',into=('POIDS','BALOURD','FORCE','MOMENT','HARMONIQUE'),defaut=None,min=1,max=1,fr="Choix du type de chargement a appliquer"), + BALOURD = BLOC(condition = "TYPE == 'BALOURD' ",fr="Chargement de type balourd", + POSITION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la position axiale ou s'applique le balourd (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de l'amplitude du balourd (kg.m)"), + PHASE_DEG = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du decalage de la phase de la charge balourd (degres)"), + INST_APPLI= SIMP(statut='f',typ='R',min=1,max=1,defaut=0,fr="Renseignement de l'instant d'apparition du balourd (s)"), + TEMPS_MONTEE=SIMP(statut='f',typ='R',min=1,max=1,defaut=0,fr="Renseignement du temps necessaire pour atteindre l'amplitude nominale du balourd (s)"), + ),# fin BALOURD + POIDS = BLOC(condition = "TYPE == 'POIDS' ",fr="Prise en compte du champ de pesanteur", + GRAVITE = SIMP(statut='o',typ='R',defaut=9.81,fr="Renseignement de l'intensite de la gravite (m/s^2)"), + DIRECTION = SIMP(statut='o',typ='R',min=3,max=3,defaut=(1,0,0),fr="Renseignement de la direction de la force de gravite"), + ), # fin POIDS + FORCE = BLOC(condition = "TYPE == 'FORCE' ",fr="Application d'une force ponctuelle", + POSITION = SIMP(statut='o',typ='R',defaut=None,fr="Renseignement de la position axiale ou s'applique le moment (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=3,max=3,defaut=None,fr="Renseignement des 3 composantes decrivant le moment (N/m)"), + #FONC_APPLI = SIMP(statut='f',typ='R',min=2,max=2,defaut=None,fr="Renseignement de la fonction appliquee"), + ), # fin FORCE + MOMENT = BLOC(condition = "TYPE == 'MOMENT' ",fr="Application d'un moment ponctuel", + POSITION = SIMP(statut='o',typ='R',defaut=None,fr="Renseignement de la position axiale ou s'applique le moment (m)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=3,max=3,defaut=None,fr="Renseignement des 3 composantes decrivant le moment (N/m)"), + ), # fin MOMENT + HARMONIQUE = BLOC(condition = "TYPE == 'HARMONIQUE' ",fr="Charge harmonique", + POSITION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la position axiale ou s'applique la charge harmonique (m)"), + FREQUENCE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la frequence d'excitation harmonique (Hz)"), + MAGNITUDE = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de l'amplitude de la charge harmonique, (N)"), + #FONC_APPLI = SIMP(statut='o',typ='R',min=1,max='**',defaut=None,fr="Renseignement de la fonction appliquee de la charge harmonique (autant de valeurs que de vitesses de rotation)"), + PHASE_DEG = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement du decalage de la phase de la charge harmonique (degres)"), + TYPE_DDL = SIMP(statut='o',typ='TXM',min=1,max=1,into=('DX','DRX','DY','DRY','DZ','DRZ'),defaut=None,fr="Renseignement du DDL sur lequel s'applique la charge harmonique"), + ), # fin HARMONIQUE + ), #fin CHARGES + ETAT_INIT = FACT(statut='o',fr="Renseignement de l'etat initial du calcul", + #RESULTAT = SIMP(statut='o',typ=('sd_resultat'),max=1,defaut=None,fr="Choix de la structure de donnees resultat de code aster "), + # 20121126 + #RESULTAT = SIMP(statut='o',typ='TXM',max=1,defaut=None,fr="Choix de la structure de donnees resultat de code aster "), + INST_INIT = SIMP(statut='f',typ='R',max=1,defaut=None,fr="Renseignement de l'instant initial a partir duquel il faut lancer le calcul (s)"), + ), # fin ETAT_INIT + #PARAM_TEMPS = SIMP(statut='o',typ='TXM',max=1,into=('PAS','LIST_INST'),defaut=None,fr="Choix du type de parametrage temporel"), + # 20121126 + PARAM_TEMPS = SIMP(statut='o',typ='TXM',max=1,into=('PAS'),defaut="PAS",fr="Choix du type de discretisation temporelle",), + PAS = BLOC(condition = "PARAM_TEMPS == 'PAS' ",fr="Renseignement de pas de temps", + PAS_ASTER = SIMP(statut='o',typ='R',max=1,defaut=None,fr="Renseignement du pas de temps d'integration Code_Aster (en s)",), + PAS_EDYOS = SIMP(statut='o',typ='R',max=1,defaut=None,fr="Renseignement du pas de temps d'integration Edyos (en s)",), + INST_FIN = SIMP(statut='o',typ='R',max=1,defaut=None,fr="Renseignement de l'instant final du calcul (en s)",), + ), # fin TEMPS_PAS + #LIST_INST = BLOC(condition = "PARAM_TEMPS == 'LIST_INST' ",fr="Renseignement d'une liste de pas", + #LISTE = SIMP(statut='f',typ='R',min=1,max='**',defaut=None,fr="Renseignement d'une liste de pas"), + #), # fin LIST_INST + PAS_ARCHIVAGE = SIMP(statut='o',typ='I',max=1,defaut=1,fr="Renseignement du pas d'archivage des resultats (une sauvegarde tous les 'PAS_ARCHIVAGE' instants d'integration)",), + PARA_MEM = SIMP(statut='f',typ='I',max=1,defaut=6400,fr="Renseigner la taille maximale de la memoire (Mo)",), + PARA_CPU = SIMP(statut='f',typ='I',max=1,defaut=10000,fr="Renseigner le temps CPU maximal (s)",), + SCHEMA_TEMPS = SIMP(statut='o',typ='TXM',max=1,into=('EULER','ADAPT_ORDRE1','ADAPT_ORDRE2'),defaut='ADAPT_ORDRE2',fr="Choix d'un schema d'integration temporelle"), + + ## POST_TRAITEMENTS de l'analyse transitoire + POST_TRAITEMENTS = FACT(statut='o',max='**',fr="Definition et renseignement des post-traitements", + TYPE = SIMP(statut='o',typ='TXM',into=('DEPL_ABS','DEPL_RELA','EFFORTS_PAL','CONTRAINTES'),defaut=None,fr="Choix du type de post-traitement"), + DEPL = BLOC(condition = "TYPE in ('DEPL_ABS','DEPL_RELA') ",fr="Deplacement", + POSITION = SIMP(statut='o',typ='R',min=1,max=1,defaut=None,fr="Renseignement de la coordonnee du deplacement"), + PALIER = SIMP(statut='f',typ='TXM',max=1,defaut=None,fr="Renseignement de l'etiquette du palier"), + ), # fin DEPL + # pas d'info à rentrer pour les efforts palier (post-traitement sur tout les paliers) + #EFFORTS_PAL = BLOC(condition = "TYPE == 'EFFORTS_PAL'", fr = "Efforts paliers", + #PALIER = SIMP(statut='o',typ='TXM',max=1,defaut=None,fr="Renseignement de l'etiquette du palier"), + #), # fin EFFORTS_PAL + CONTRAINTES = BLOC(condition = "TYPE == 'CONTRAINTES' ",fr="Export des contraintes", + regles=UN_PARMI('POSITION','ZONE','TOUT'), + POSITION = SIMP(statut='f',typ='R',max=1,defaut=None,fr="Renseignement de la coordonnee de la contrainte"), + ZONE = SIMP(statut='f',typ='TXM',max=1,defaut=None,fr="Renseignement de l'etiquette de la zone de la contrainte"), + TOUT = SIMP(statut='f',typ='TXM',into=('OUI'),max=1,fr="Export pour tous les noeuds"), + ), # fin CONTRAINTES + ), # fin POST_TRAITEMENTS + + + ), # fin ANALYSE_TRANSITOIRE_ACCIDENTEL + +)# fin SPECIFICATION_ANALYSE diff --git a/Telemac/reecrit_cas_en_comm.py b/Telemac/reecrit_cas_en_comm.py new file mode 100755 index 00000000..4415f8f2 --- /dev/null +++ b/Telemac/reecrit_cas_en_comm.py @@ -0,0 +1,57 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +# CONFIGURATION MANAGEMENT OF EDF VERSION +# ====================================================================== +# COPYRIGHT (C) 1991 - 2002 EDF R&D WWW.CODE-ASTER.ORG +# THIS PROGRAM IS FREE SOFTWARE; YOU CAN REDISTRIBUTE IT AND/OR MODIFY +# IT UNDER THE TERMS OF THE GNU GENERAL PUBLIC LICENSE AS PUBLISHED BY +# THE FREE SOFTWARE FOUNDATION; EITHER VERSION 2 OF THE LICENSE, OR +# (AT YOUR OPTION) ANY LATER VERSION. +# +# THIS PROGRAM IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL, BUT +# WITHOUT ANY WARRANTY; WITHOUT EVEN THE IMPLIED WARRANTY OF +# MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. SEE THE GNU +# GENERAL PUBLIC LICENSE FOR MORE DETAILS. +# +# YOU SHOULD HAVE RECEIVED A COPY OF THE GNU GENERAL PUBLIC LICENSE +# ALONG WITH THIS PROGRAM; IF NOT, WRITE TO EDF R&D CODE_ASTER, +# 1 AVENUE DU GENERAL DE GAULLE, 92141 CLAMART CEDEX, FRANCE. +# +# +# ====================================================================== + +""" +""" +# Modules Python +from __future__ import absolute_import +from __future__ import print_function + +import sys,os + +# Modules Eficas +import prefs +if hasattr(prefs,'encoding'): + # Hack pour changer le codage par defaut des strings + import sys + reload(sys) + sys.setdefaultencoding(prefs.encoding) + del sys.setdefaultencoding + # Fin hack + + +sys.path.append(os.path.join(os.path.abspath(os.path.dirname(__file__)),'..')) +from InterfaceQT4 import eficas_go + +from PyQt5.QtWidgets import QApplication +app = QApplication(sys.argv) +#for badf in ('t2d_bridge.cas','t2d_estu_gir.cas' ): +#for f in ('t2d_bj78.cas',): +for f in ('t2d_weirs.cas',): +#for f in ('t2d_bj78.cas' ,'t2d_bowl_fe.cas' ,'t2d_bowl_vf.cas' ,'t2d_bowl_vf_gb.cas' ,'t2d_breach.cas' ,'t2d_break.cas' ,'t2d_bumpcri.cas' ,'t2d_bumpflu.cas' ,'t2d_cavity.cas' ,'t2d_cinetiques.cas' ,'t2d_clotilde.cas' ,'t2d_cone.cas' ,'t2d_confluence.cas' ,'t2d_culm.cas' ,'t2d_dambreak_v1p0.cas' ,'t2d_dambreak_v2p0.cas' ,'t2d_digue.cas' ,'t2d_donau.cas' ,'t2d_dragforce.cas' ,'t2d_estimation.cas' ,'t2d_flotteurs_v1p0.cas' ,'t2d_flotteurs_v2p0.cas' ,'t2d_friction.cas' ,'t2d_gouttedo.cas' ,'t2d_gouttedo_cin.cas' ,'t2d_gouttedo_qua.cas' ,'t2d_hydraulic_jump_v1p0.cas' ,'t2d_hydraulic_jump_v2p0.cas' ,'t2d_init-1.cas' ,'t2d_init-2.cas' ,'t2d_init-3.cas' ,'t2d_init_cin.cas' ,'t2d_island.cas' ,'t2d_m2wave.cas' ,'t2d_malpasset-large.cas' ,'t2d_malpasset-large_med.cas' ,'t2d_malpasset-small_charac.cas' ,'t2d_malpasset-small_cin.cas' ,'t2d_malpasset-small_ERIA.cas' ,'t2d_malpasset-small_pos.cas' ,'t2d_malpasset-small_prim.cas' ,'t2d_mersey.cas' ,'t2d_monai.cas' ,'t2d_okada.cas' ,'t2d_ondem2.cas' ,'t2d_pildepon.cas' ,'t2d_pildepon_cin.cas' ,'t2d_pildepon_qua.cas' ,'t2d_pluie.cas' ,'t2d_pluie_cn.cas' ,'t2d_pluie_cn_geo_hyetograph.cas' ,'t2d_porosite.cas' ,'t2d_riogrande.cas' ,'t2d_ritter.cas' ,'t2d_riv_art.cas' ,'t2d_ruptmoui.cas' ,'t2d_seccurrents.cas' ,'t2d_seiche.cas' ,'t2d_shoal.cas' ,'t2d_siphon.cas' ,'t2d_swash.cas' ,'t2d_tests_channel.cas' ,'t2d_thacker.cas' ,'t2d_thomson.cas' ,'t2d_tide-ES_real.cas' ,'t2d_tide-jmj_real_gen.cas' ,'t2d_tide-jmj_type.cas' ,'t2d_tide-jmj_type_gen.cas' ,'t2d_tide-jmj_type_med.cas' ,'t2d_tide-NEA_prior_real.cas' ,'t2d_tide-NEA_prior_type.cas' ,'t2d_tracer_decay.cas' ,'t2d_trdec.cas' ,'t2d_triangular_shelf.cas' ,'t2d_vasque.cas' ,'t2d_waq_o2.cas' ,'t2d_waq_thermic.cas' ,'t2d_wave.cas' ,'t2d_weirs.cas' ,'t2d_wesel.cas' ,'t2d_wesel_pos.cas' ,'t2d_wind.cas' ,'t2d_wind_txy_bin.cas' ,'t2d_wind_txy.cas' ,'waq_steer.cas') : + + if f == ' ' : continue + print ("Traitement de : ", 'CasEn/'+f) + + # on veut ouvrir un fichier directement au lancement d'Eficas + eficas_go.lance_eficas_ssIhm_reecrit(code='TELEMAC',fichier = 'CasEn/'+f,ou = 'CasEn_Reecrits',cr=True) + print ("\n") diff --git a/Traducteur/changeValeur.py b/Traducteur/changeValeur.py index 0bd6fd64..f091499e 100644 --- a/Traducteur/changeValeur.py +++ b/Traducteur/changeValeur.py @@ -45,7 +45,7 @@ def ChangementValeur(jdc,command,motcle,DictNouvVal,liste=(),defaut=0): if indexTexteMC > len(liste_ligne_MC)-1 : break MaLigneGlob=jdc.getLines()[indexLigneGlob] MaLigneTexte=liste_ligne_MC[indexTexteMC] - for Valeur in DictNouvVal.keys() : + for Valeur in DictNouvVal : MaLigneTexteDict=lineToDict(MaLigneTexte) trouvecol=MaLigneTexte.find(Valeur) if trouvecol > -1: @@ -97,7 +97,7 @@ def ChangementValeurDsMCF(jdc,command,fact,motcle,DictNouvVal,liste=(),ensemble= if indexTexteMC > len(liste_ligne_MC)-1 : break MaLigneGlob=jdc.getLines()[indexLigneGlob] MaLigneTexte=liste_ligne_MC[indexTexteMC] - for Valeur in DictNouvVal.keys() : + for Valeur in DictNouvVal : MaLigneTexteDict=lineToDict(MaLigneTexte) trouvecol=MaLigneTexte.find(Valeur) if trouvecol > -1: diff --git a/Traducteur/dictErreurs.py b/Traducteur/dictErreurs.py index b3b20fb7..74947840 100644 --- a/Traducteur/dictErreurs.py +++ b/Traducteur/dictErreurs.py @@ -30,7 +30,7 @@ def EcritErreur(listeGena,ligne=None) : #try : if ( 1 == 1) : maClef=maCle[1:] - if maClef in dict_erreurs.keys() : + if maClef in dict_erreurs : if ligne != None : logging.warning("ligne %d : %s ",ligne,dict_erreurs[maClef]) else : @@ -41,7 +41,7 @@ def EcritErreur(listeGena,ligne=None) : maCle=maCle+"_"+Mot maClef=maCle[1:] maClef=maCle+"_"+"VALEUR" - if maClef in dict_erreurs.keys() : + if maClef in dict_erreurs : if ligne != None : logging.warning("ligne %d : %s ",ligne,dict_erreurs[maClef]) else : diff --git a/Traducteur/inseremocle.py b/Traducteur/inseremocle.py index 8e517dbd..f53adf39 100644 --- a/Traducteur/inseremocle.py +++ b/Traducteur/inseremocle.py @@ -21,7 +21,6 @@ import logging from Traducteur.parseur import FactNode from Traducteur.load import jdcSet from Traducteur.dictErreurs import EcritErreur -import string from Traducteur import regles debug=0 diff --git a/Traducteur/utils.py b/Traducteur/utils.py index b666ee79..eabb73fd 100644 --- a/Traducteur/utils.py +++ b/Traducteur/utils.py @@ -40,6 +40,6 @@ def lineToDict(line): def DictToLine(d): """Transformation inverse: à partir d'un dictionnaire retourne une ligne""" - cols = d.keys() + cols = d cols.sort() return "".join([d[colno]for colno in cols]) diff --git a/UiQT5/desWidgetFactHorizon.ui b/UiQT5/desWidgetFactHorizon.ui new file mode 100644 index 00000000..0ccdf54f --- /dev/null +++ b/UiQT5/desWidgetFactHorizon.ui @@ -0,0 +1,428 @@ + + + WidgetFactHorizon + + + + 0 + 0 + 949 + 53 + + + + Qt::StrongFocus + + + Form + + + QGroupBox { + border: 1px solid gray; + border-radius: 5px; + margin-top: 1ex; /* leave space at the top for the title */ + } + + QGroupBox::title { + padding: 0 3px; + } + + + + 0 + + + 0 + + + 2 + + + 0 + + + 0 + + + + + 0 + + + + + Qt::Vertical + + + QSizePolicy::Fixed + + + + 20 + 5 + + + + + + + + + 21 + 15 + + + + + 21 + 21 + + + + border : 0px + + + ... + + + + ../Editeur/icons/minusnode.png../Editeur/icons/minusnode.png + + + + 21 + 21 + + + + + + + + + + Qt::Vertical + + + + + + + + + + + 0 + + + + + + 17 + 25 + + + + + 21 + 25 + + + + border : 0px + + + ... + + + + ../Editeur/icons/ast-green-ball.png../Editeur/icons/ast-green-ball.png + + + + 21 + 25 + + + + + + + + 0 + + + + + + 0 + 0 + + + + + 0 + 25 + + + + + 12121213 + 25 + + + + <html><head/><body><p><span style=" font-style:italic;">TextLabel</span></p></body></html> + + + + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 13 + 20 + + + + + + + + + 0 + 0 + + + + + 200 + 0 + + + + + 1500 + 16 + + + + Qt::Horizontal + + + + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 13 + 20 + + + + + + + + 0 + + + QLayout::SetFixedSize + + + + + + 21 + 31 + + + + + 21 + 31 + + + + Qt::ClickFocus + + + Lance un script associé à la commande + + + border : 0px + + + ... + + + + ../Editeur/icons/roue.png../Editeur/icons/roue.png + + + + 21 + 31 + + + + + + + + + 21 + 25 + + + + + 21 + 25 + + + + border : 0px + + + ... + + + + ../Editeur/icons/point-interrogation30.png../Editeur/icons/point-interrogation30.png + + + + 21 + 25 + + + + + + + + + 21 + 25 + + + + + 21 + 25 + + + + border : 0px + + + ... + + + + ../Editeur/icons/lettreRblanc30.png../Editeur/icons/lettreRblanc30.png + + + + 21 + 25 + + + + + + + + + + Qt::Horizontal + + + QSizePolicy::Fixed + + + + 13 + 20 + + + + + + + + + 21 + 25 + + + + + 21 + 25 + + + + border : 0px + + + ... + + + + ../Editeur/icons/deleteRond.png../Editeur/icons/deleteRond.png + + + + 21 + 25 + + + + + + + + + + 0 + + + 2 + + + + + + + + + + + + MonBoutonValide + QToolButton +
monBoutonValide.h
+
+ + MonLabelClic + QLabel +
monLabelClic.h
+
+
+ + +
diff --git a/UiQT5/desWidgetPlusieursInto.ui b/UiQT5/desWidgetPlusieursInto.ui index b99f222b..fdddf0fa 100644 --- a/UiQT5/desWidgetPlusieursInto.ui +++ b/UiQT5/desWidgetPlusieursInto.ui @@ -292,7 +292,7 @@ - Originel + Original diff --git a/VirtualPolymer/VP b/VirtualPolymer/VP new file mode 100644 index 00000000..983ed055 --- /dev/null +++ b/VirtualPolymer/VP @@ -0,0 +1,5 @@ +[c_pre_polymer_data_management] +gui = True +data_base = local/ +backup = False +folder_output = /tmp diff --git a/VirtualPolymer/VP_Cata_V2.py b/VirtualPolymer/VP_Cata_V2.py index ecc96275..87c03918 100644 --- a/VirtualPolymer/VP_Cata_V2.py +++ b/VirtualPolymer/VP_Cata_V2.py @@ -7,9 +7,29 @@ import listesDB monDico= { 'Equation_Liste' : ('initiation', 'propagation', 'termination', 'stabilization'), 'Modele_TechnicalUse' : ('cable', 'coating', 'pipes'), + 'Aging_Factor' : { 'predefinedSimulationTime' : ('40years BR top', '40years BR bottom')}, + 'Boundary_Conditions' : ('flux_volume','flux_surface','constant_constration','convection_flux'), + 'postTraitement_Typ' : ('chimique','mecanique','physique'), } monModele=listesDB.sModele().monModele +monPost=listesDB.sModele().monPost + +import types +class Tuple: + def __init__(self,ntuple): + self.ntuple=ntuple + + def __convert__(self,valeur): + if type(valeur) == types.StringType: + return None + if len(valeur) != self.ntuple: + return None + return valeur + + def info(self): + return "Tuple de %s elements" % self.ntuple + JdC = JDC_CATA(code='VP', execmodul=None, @@ -21,7 +41,12 @@ Equation = PROC (nom="Equation", op=None, #--------------------------------- Equation_DB=SIMP(statut= 'o',typ= 'TXM', into=("Approved data base", "My data base") ), + #b_suite = BLOC(condition = "Equation_DB == 'My data base' ", Equation_Type = SIMP(statut= 'o',typ= 'TXM', into=("Show equation database", "Equation creation"),), + #), + #b_suite_2 = BLOC(condition = "Equation_DB == 'Approved data base' ", + #Equation_Type = SIMP(statut= 'o',typ= 'TXM', into=("Show equation database", ),), + #), # --------------------------------------------------------------------------- b_type_show = BLOC(condition = " Equation_Type == 'Show equation database'", @@ -37,6 +62,7 @@ Equation = PROC (nom="Equation", ), # Fin b_reaction_type ListeEquation = SIMP(statut='o', typ='TXM', homo='SansOrdreNiDoublon',siValide=lienDB.afficheValeurEquation), + #ListeEquation = SIMP(statut='o', typ='TXM', homo='SansOrdreNiDoublon'), b_modification = BLOC(condition = " ListeEquation != None ", modification = SIMP(typ = bool, statut = 'o',defaut = False, fr='toto', ang='toto en anglais', siValide=lienDB.instancieChemicalFormulation), @@ -55,6 +81,7 @@ Equation = PROC (nom="Equation", ),# fin ConstanteOptionnelle Commentaire = SIMP (statut = 'f', typ = 'TXM', defaut = ' '), + ),# fin b_modif ), # fin b_modification @@ -117,43 +144,160 @@ Modele = PROC (nom="Modele", # --------------------------------------------------------------------------- b_type_creation = BLOC(condition = " Modele_Type == 'Modele creation'", # --------------------------------------------------------------------------- - technicalUse= SIMP(statut= 'o',typ= 'TXM',into=monDico['Modele_TechnicalUse'],defaut=monModele.technical_use ), - modeleName=SIMP(statut='o',typ='TXM',defaut=monModele.nom,), - material=SIMP(statut='o',typ='TXM',defaut=monModele.materiaux[0],), - stabilizer = SIMP(typ = bool, statut = 'o',defaut = monModele.stabilise), - model_developed_by_for_EDF = SIMP(typ = bool, statut = 'o',defaut = monModele.dvt_EDF[0]), - documentation=SIMP(statut='o',typ='TXM',defaut=monModele.reference,), + ID=FACT(statut='o', + technicalUse= SIMP(statut= 'o',typ= 'TXM',into=monDico['Modele_TechnicalUse'],defaut=monModele.technical_use ), + modeleName=SIMP(statut='o',typ='TXM',defaut=monModele.nom,), + material=SIMP(statut='o',typ='TXM',defaut=monModele.materiaux[0],), + agingType=SIMP(statut= 'o',typ='TXM', min=1,max='**', homo='SansOrdreNiDoublon', into=('All', 'thermo', 'radio'), defaut=monModele.type_vieil), + stabilizer = SIMP(typ = bool, statut = 'o',defaut = monModele.stabilise), + material_thickness = SIMP(typ = 'TXM', statut = 'o',defaut = monModele.thickness, into = ['thin','thick']), + # il faudrait que position=global_jdc fonctionne + model_developed_by_for_EDF = SIMP(typ = bool, statut = 'o',defaut = monModele.dvt_EDF[0]), + documentation=SIMP(statut='o',typ='TXM',defaut=monModele.reference,), + ), # fin ID # ajouter la liste des equations et le remove (il faut garder ceux qu on a enlever) + Chemical_Equation = FACT( statut='o', + Initial_Equation_List=SIMP(statut='o',typ='TXM',max="**",homo='SansOrdreNiDoublon',into=[],defaut=[], siValide=lienDB.recupereModeleEquation), AjoutEquation=SIMP(statut= 'o',typ= bool, defaut=False, siValide=lienDB.recupereModeleEquation), b_ajout_equation = BLOC(condition = " AjoutEquation == True", - listeEquation_initiation=SIMP(statut='o', typ='TXM',homo='SansOrdreNiDoublon', max='**', min=0, defaut=[] ), - listeEquation_propagation=SIMP(statut='o', typ='TXM',homo='SansOrdreNiDoublon', max='**', min=0, defaut=[] ), - listeEquation_termination=SIMP(statut='o', typ='TXM',homo='SansOrdreNiDoublon', max='**', min=0, defaut=[] ), - listeEquation_stabilization=SIMP(statut='o',typ='TXM', homo='SansOrdreNiDoublon', max='**', min=0, defaut=[] ), + listeEquation_initiation=SIMP(statut='o', typ='TXM',homo='SansOrdreNiDoublon', max='**', min=0, defaut=[],siValide=lienDB.ajoutDUneEquation ), + listeEquation_propagation=SIMP(statut='o', typ='TXM',homo='SansOrdreNiDoublon', max='**', min=0, defaut=[],siValide=lienDB.ajoutDUneEquation ), + listeEquation_termination=SIMP(statut='o', typ='TXM',homo='SansOrdreNiDoublon', max='**', min=0, defaut=[],siValide=lienDB.ajoutDUneEquation ), + listeEquation_stabilization=SIMP(statut='o',typ='TXM', homo='SansOrdreNiDoublon', max='**', min=0, defaut=[],siValide=lienDB.ajoutDUneEquation ), ),# fin b_ajout_equation + ), # fin Equation # coefficients monModele.coef = liste de dictionnaire mais il faut prendre que le 0 # on enleve ceux qui commence par D, S et B(casse imprtante) # la clef est le coef, puis les valeurs - Aging_Type=SIMP(statut= 'o',typ='TXM', min=1,max='**', homo='SansOrdreNiDoublon', into=('All', 'thermo', 'radio'), defaut=monModele.type_vieil), - Diffusion = SIMP(typ = bool, statut = 'o',defaut = monModele.diffusion,siValide = lienDB.prepareDiffusion), + + #b_material_thickness = BLOC(condition = "material_thickness == 'thick'", + # si position=global fonctionne + Transport = FACT( statut = 'o', + #Diffusion = SIMP(typ = bool, statut = 'o',defaut = monModele.diffusion,siValide = lienDB.prepareDiffusion), + Diffusion = SIMP(typ = bool, statut = 'o',defaut = False ,siValide = lienDB.prepareDiffusion), b_diffusion = BLOC(condition = " Diffusion == True", - #coefficients monModele.coef = liste de dictionnaire mais il faut prendre que le 0 - # on met ceux qui commence par D, S et pas les B ni les aitres( casse imprtante) - listeProduitPourLaDiffusion=SIMP(statut='o', typ='TXM', max='**', min=1,homo='SansOrdreNiDoublon', into = monModele.param_ini.keys(),siValide=lienDB.ajouteDiffusion), - ), # fin b_diffusion + listeProduitPourLaDiffusion=SIMP(statut='o', typ='TXM', max='**', min=1,homo='SansOrdreNiDoublon', into = [],siValide=lienDB.ajouteDiffusion), + ), # fin b_diffusion + + Evaporation = SIMP(typ = bool, statut = 'o',defaut = False ,siValide = lienDB.prepareDiffusion), + b_evaporation = BLOC(condition = " Evaporation == True", + listeProduitPourLEvaporation=SIMP(statut='o', typ='TXM', max='**', min=1,homo='SansOrdreNiDoublon', into = [],siValide=lienDB.ajouteEvaporation), + ), # fin b_evaporation - ), # fin b_type_creation + + ), # fin TRANSPORT + #), # fin b_material_thickness + + Coefficients = FACT( statut = 'o', + Coef_k2 = SIMP (statut ='o', typ='R'), + Coef_ku1 = SIMP (statut ='o', typ=Tuple(2),validators = VerifTypeTuple(('R','R')),), + ), + Parametres_Initiaux = FACT( statut = 'o', + Param_POOH=SIMP (statut ='o', typ='R'), + # La liste est la meme que le INTO des listeProduitsPourlaDiffusion + # la valeur par defaut si elle existe est contenue dans modele.param_ini['POOH'] + ), #AjoutEquation=Fact(statut='f', # Reaction_Type=SIMP(statut= 'o',typ= 'TXM', min=1,into=monDico['Equation_Liste'],siValide=lienDB.recupereModeleEquation), #), # fin AjoutEquation + ), # fin Creation +# --------------------------------------------------------------------------- + b_type_modification = BLOC(condition = " Modele_Type == 'Show modele database'", +# --------------------------------------------------------------------------- + technicalUse= SIMP(statut= 'o',typ= 'TXM',into=monDico['Modele_TechnicalUse'],siValide=lienDB.creeListeMateriauxSelonModele), + b_technicalUse = BLOC (condition = 'technicalUse != None and technicalUse != ""', + material= SIMP (statut ='o', typ='TXM',siValide=lienDB.creeListeModelesPossibles), + modele= SIMP (statut ='o', typ='TXM',siValide=lienDB.choisitModele), + b_modele = BLOC (condition = 'modele != None and modele != ""', + action = SIMP (statut ='o', typ='TXM',into = ['display','use','modify'], siValide=lienDB.choisitActionModele), +# --------------------------------------------------------------------------- + b_type_modify = BLOC(condition = " action == 'modify'", +# --------------------------------------------------------------------------- + ID=FACT(statut='o', + modeleName=SIMP(statut='o',typ='TXM'), + technicalUse= SIMP(statut= 'o',typ= 'TXM', into=monDico['Modele_TechnicalUse'] ), + material=SIMP(statut='o',typ='TXM'), + agingType=SIMP(statut= 'o',typ='TXM', min=1,max='**', homo='SansOrdreNiDoublon', into=('All', 'thermo', 'radio')), + stabilizer = SIMP(typ = bool, statut = 'o',), + material_thickness = SIMP(typ = 'TXM', statut = 'o', into = ['thin','thick']), + # il faudrait que position=global_jdc fonctionne + model_developed_by_for_EDF = SIMP(typ = bool, statut = 'o',), + documentation=SIMP(statut='o',typ='TXM',), + + +# il faut recopier toute la suite en changeant eventuellement le nom du modele +# il faut cocher toutes les equations par defaut + + ), # fin ID + ), # fin b_type_modify +# --------------------------------------------------------------------------- + b_type_use = BLOC(condition = " action == 'use'", +# --------------------------------------------------------------------------- + simulationName=SIMP(statut='o',typ='TXM'), + outputFolder = SIMP(statut="o", typ="Repertoire",siValide=lienDB.creeCoefAModifier), + ), # fin b_type_use +# --------------------------------------------------------------------------- + b_type_use2 = BLOC(condition = " action == 'use'", +# --------------------------------------------------------------------------- + Aging_Factor = FACT(statut='o', + predefinedSimulationTime = SIMP(statut='o',typ='TXM',into=monDico['Aging_Factor']['predefinedSimulationTime'],siValide=lienDB.remplirAgingFactor), + simulationTime=SIMP(statut='o',typ='R',), + numberOfNodes=SIMP(statut='o',typ='I',val_min=3,siValide=lienDB.creeInitialParameter), + sampleThickness=SIMP(statut='o',typ='R',), + #debitOfDose=SIMP(statut='o',typ='R',), + temperature=SIMP(statut='o',typ='R',), + oxygenPressure=SIMP(statut='o',typ='R',), + polymerConcentration=SIMP(statut='o',typ='R',), + ), + Initial_Parameter = FACT(statut='o', + max='**', + ), + Boundary_Conditions_Param = FACT(statut='o', + diffusionSpecies=SIMP(statut='o',typ='TXM',defaut='O2', into=['O2',]), + nodeNumber = SIMP(statut='o',typ='I',defaut=1, into=[1]), # tjours1 + Boundary_Conditions_O2_1 = SIMP(statut='o',typ='TXM',into=monDico['Boundary_Conditions']), + BC_Value_Espece_1=SIMP(statut='o',typ='R'), + nodeNumber_Espece_4 = SIMP(statut='o',typ='I',defaut=4, into=[4]), # numberOfNodes+1 + Boundary_Conditions_Espece_4 = SIMP(statut='o',typ='TXM',into=monDico['Boundary_Conditions']), + BC_Value_Espece_4=SIMP(statut='o',typ='R'), + ), + + ), # fin b_type_use2 + ), # fin b_modele + ), # fin b_technicalUse + ), # fin modification Commentaire = SIMP (statut = 'f', typ = 'TXM'), ) # Fin Modele +#--------------------------------- +PostTraitement = PROC (nom="PostTraitement", + op=None, + postTraitement_DB=SIMP(statut= 'o',typ= 'TXM', into=("Approved data base", "My data base") ), + postTraitement_Type = SIMP(statut= 'o',typ= 'TXM', into=("Show post-traitement database", "post-traitement creation"),), +# --------------------------------------------------------------------------- + b_post_creation = BLOC(condition = " postTraitement_Type == 'post-traitement creation'", + postTraitement_Name=SIMP(statut= 'o',typ= 'TXM',defaut=monPost.nom,), + generic=SIMP(statut= 'o',typ= bool,defaut=monPost.general,), + postTraitement_Typ = SIMP(statut= 'o',typ= 'TXM', into=monDico['postTraitement_Typ'],homo='SansOrdreNiDoublon',max='**',defaut=monPost.type_post), + calculation= FACT(statut='o', + # il faut un fact horizontal + calculation_results=SIMP(statut= 'o',typ= 'TXM', min=0,max='**', intoSug=monPost.calculation_results,defaut=monPost.calculation_results), + results_units=SIMP(statut= 'o',typ= 'TXM', min=0,max='**', intoSug=monPost.results_units,defaut=monPost.results_units), + #integrate=SIMP(statut= 'o',typ= 'TXM', min=0,max='**', intoSug=monPost.results_units,defaut=monPost.results_units), + prerequisite=SIMP(statut= 'o',typ= 'TXM', min=0,max='**', intoSug=monPost.prerequisite,defaut=monPost.prerequisite), + + ), + constituant=SIMP(statut= 'o',typ= 'TXM', min=0,max='**', intoSug=monPost.constituants,defaut=monPost.constituants) + + )# fin b_post_creation +# --------------------------------------------------------------------------- +#--------------------------------- +) #PostTraitement diff --git a/VirtualPolymer/lienDB.py b/VirtualPolymer/lienDB.py index fe97f1d1..b834fc4d 100644 --- a/VirtualPolymer/lienDB.py +++ b/VirtualPolymer/lienDB.py @@ -1,4 +1,5 @@ # coding: utf-8 + import types import sys,os @@ -7,7 +8,28 @@ import listesDB maClasseDelistesDB = listesDB.classeListesDB() monModele=listesDB.sModele().monModele +monPost=listesDB.sModele().monPost + +import types +class Tuple: + def __init__(self,ntuple): + self.ntuple=ntuple + + def __convert__(self,valeur): + if type(valeur) == types.StringType: + return None + if len(valeur) != self.ntuple: + return None + return valeur + def info(self): + return "Tuple de %s elements" % self.ntuple + + __repr__=info + __str__=info + + +dicoAgingFactor={ '40years BR top' : {'temperature' : 50, 'simulationTime' : 350640}} # -------------------------------------- # Fonctions appellees depuis le catalogue @@ -24,6 +46,7 @@ def recupereDicoEquation(monMC): if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return editor=monMC.jdc.editor + monMC.dsMaFunct = True valeurDB=editor.getValeur('Equation','Equation_DB',()) maClasseDelistesDB.metAJour(valeurDB) @@ -60,15 +83,16 @@ def recupereDicoEquation(monMC): def afficheValeurEquation(monMC): # Equation b_modification modification + print (monMC) if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return valeur=monMC.valeur if valeur == None : return maClasseDelistesDB.valeurEquationChoisie=str(valeur) monEquation=maClasseDelistesDB.dicoListAffiche[str(valeur)] - aAfficher='jkljkljk \n je ne sais plus \njfkqsljqfkl\nkfsjqklfjkl\n' + aAfficher=str(monEquation) editor=monMC.jdc.editor - editor._viewText(aAfficher, "Rapport",largeur=30,hauteur=150) + editor._viewText(aAfficher, "Id",largeur=80,hauteur=300) monMC.dsMaFunct = False @@ -82,6 +106,8 @@ def instancieChemicalFormulation(monMC): if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return editor.dsMaFunct = True + for e in monMC.jdc.etapes: + if e.nom == 'Equation' :break print ('ds instancie') v=maClasseDelistesDB.valeurEquationChoisie monEquation=maClasseDelistesDB.dicoListAffiche[v] @@ -101,6 +127,7 @@ def instancieChemicalFormulation(monMC): monMcl2=('Differential_Equation','TXM',{'statut':'o','defaut':valeurEquation}) listeMC=(monMcl1,monMcl2) editor.ajoutDefinitionMCFact ('Equation',('b_type_show','b_modification','b_modif',),valeurConstituant,listeMC,statut='f') + #editor.ajoutMCFact (e,('b_type_show','b_modification','b_modif',),valeurConstituant) print (index,valeurConstituant,valeurEquation) #OptionnelConstituant = FACT ( statut = 'f',max = '**', @@ -115,7 +142,8 @@ def instancieChemicalFormulation(monMC): monMcl2=('ConstanteType','TXM',{'statut':'o','defaut':valeurConstanteType,'into': ('Arrhenius type','non Arrhenius type') }) listeMC=(monMcl1,monMcl2) editor.ajoutDefinitionMCFact ('Equation',('b_type_show','b_modification','b_modif',),valeurConstituant,listeMC,statut='f') - print (index,valeurConstituant,valeurConstanteType) + #editor.ajoutMC(e,MCFils,mesValeurs,('b_type_creation','b_diffusion',)) + change=editor.changeDefautDefMC('Equation', ('b_type_show','b_modification','b_modif','Commentaire'),monEquation.comment ) print (monEquation.comment ) @@ -124,37 +152,50 @@ def instancieChemicalFormulation(monMC): monMC.dsMaFunct = False editor.dsMaFunct = False -# TEMPORAIRE -# TODO TODO TODO -# PNPNPNPNPN def recupereDicoModele(monMC): if monMC.valeur == None: return if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + monMC.dsMaFunct = True print ('je passe dans recupereDicoModele') - listEquation, listModele,listPostTraitement=recupereDicoGenerique(monMC) + editor=monMC.jdc.editor - editor.maClasseVisuEquation = classeVisuEquation({},listEquation, listModele,listPostTraitement) + valeurDB=editor.getValeur('Modele','Modele_DB',()) + maClasseDelistesDB.metAJour(valeurDB) + + print ('fin recupereDicoModele') monMC.dsMaFunct = False def creeListeEquation(monMC): if monMC.valeur == None: return if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return - editor=monMC.jdc.editor -# TEMPORAIRE -# TODO TODO TODO + if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return + editor.dsMaFunct = True + print ('debut de creeListeEquation') + listeEquationsAAfficher=[] listeConstantesAAfficher=[] - for index,equation in enumerate( editor.maClasseVisuEquation.listEquation): + listeInitialEquations=[] + + listEquation=maClasseDelistesDB.getListEquation() + for index,equation in enumerate( listEquation): if index in monModele.equa: listeEquationsAAfficher.append(equation.representation) listeConstantesAAfficher.append(equation.const_cine_nom) + t=equation.representation+'\t\t\t\t '+str(equation.const_cine_nom) + listeInitialEquations.append(t) + change=editor.changeIntoDefMC('Modele', ('b_type_creation','Chemical_Equation','Initial_Equation_List'),listeInitialEquations ) + maClasseDelistesDB.listeEquationsAAfficher = listeEquationsAAfficher + maClasseDelistesDB.listeConstantesAAfficher = listeConstantesAAfficher monMC.dsMaFunct = False + print ('fin de creeListeEquation') + + editor.dsMaFunct = False # listeEquation_stabilization=SIMP(statut='o', homo='SansOrdreNiDoublon', max='**', min=0 ), @@ -163,74 +204,334 @@ def recupereModeleEquation(monMC): if monMC.valeur==False : return editor=monMC.jdc.editor if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return + editor.dsMaFunct = True + print ('je suis dans recupereModeleEquation') editor.dsMaFunct = True dicoListeEquationAAfficher={} + from VP_Cata_V2 import monDico + listEquation=maClasseDelistesDB.getListEquation() for valeurReactionType in monDico['Equation_Liste']: dicoListeEquationAAfficher[valeurReactionType] = [] - for index,equation in enumerate( editor.maClasseVisuEquation.listEquation): + for index,equation in enumerate( listEquation): if equation.type_react==valeurReactionType : dicoListeEquationAAfficher[valeurReactionType].append(equation.representation) - print (dicoListeEquationAAfficher) + maClasseDelistesDB.dictParametresInitiaux[equation.representation]=equation + #print (dicoListeEquationAAfficher) + #print('maClasseDelistesDB.dictParametresInitiaux', maClasseDelistesDB.dictParametresInitiaux) + prepareDiffusionSansMC(editor,monMC.nom) - change=editor.changeIntoDefMC('Modele', ('b_type_creation','b_ajout_equation','listeEquation_initiation'),dicoListeEquationAAfficher['initiation'] ) - change=editor.changeIntoDefMC('Modele', ('b_type_creation','b_ajout_equation','listeEquation_propagation'),dicoListeEquationAAfficher['propagation'] ) - change=editor.changeIntoDefMC('Modele', ('b_type_creation','b_ajout_equation','listeEquation_termination'),dicoListeEquationAAfficher['termination'] ) - change=editor.changeIntoDefMC('Modele', ('b_type_creation','b_ajout_equation','listeEquation_stabilization'),dicoListeEquationAAfficher['stabilization'] ) + change=editor.changeIntoDefMC('Modele', ('b_type_creation','Chemical_Equation','b_ajout_equation','listeEquation_initiation'),dicoListeEquationAAfficher['initiation']) + change=editor.changeIntoDefMC('Modele', ('b_type_creation','Chemical_Equation','b_ajout_equation','listeEquation_propagation'),dicoListeEquationAAfficher['propagation'] ) + change=editor.changeIntoDefMC('Modele', ('b_type_creation','Chemical_Equation','b_ajout_equation','listeEquation_termination'),dicoListeEquationAAfficher['termination'] ) + change=editor.changeIntoDefMC('Modele', ('b_type_creation','Chemical_Equation','b_ajout_equation','listeEquation_stabilization'),dicoListeEquationAAfficher['stabilization'] ) if editor.fenetreCentraleAffichee : editor.fenetreCentraleAffichee.node.affichePanneau() + + print ('fin recupereModeleEquation') + monMC.dsMaFunct = False editor.dsMaFunct = False +def ajoutDUneEquation(monMC): + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + if monMC.valeur==False : return + editor=monMC.jdc.editor + prepareDiffusionSansMC(editor,monMC.nom) + if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return + editor.dsMaFunct = False + monMC.dsMaFunct = False + def prepareDiffusion(monMC): - print ('je suis dans prepareDiffusion') if monMC.valeur==False : return if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return monMC.dsMaFunct=True editor=monMC.jdc.editor if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return editor.dsMaFunct = True - editor.dicoCoefS={} - editor.dicoCoefD={} - for c in monModele.coef[0].keys() : - if c[0]=='S': - clef=c[1:] - valeur= monModele.coef[0][c] - editor.dicoCoefS[clef]=valeur + print ('je suis dans prepareDiffusion', monMC.nom) + prepareDiffusionSansMC(editor,monMC.nom) + print ('fin de prepareDiffusion', monMC.nom) + monMC.dsMaFunct=False + editor.dsMaFunct = False + +def prepareDiffusionSansMC(editor,monMCNom): + lInitialBadCoche=editor.getValeur('Modele', 'Initial_Equation_List',('b_type_creation','Chemical_Equation'),) + lInitialCoche=[] + for equ in lInitialBadCoche: lInitialCoche.append(equ.split('\t')[0]) + lInititiationCoche=editor.getValeur('Modele','listeEquation_initiation', ('b_type_creation','Chemical_Equation',)) + lPropagationCoche =editor.getValeur('Modele', 'listeEquation_propagation',('b_type_creation','Chemical_Equation',)) + lTerminationCoche=editor.getValeur('Modele','listeEquation_termination', ('b_type_creation','Chemical_Equation',)) + lStabilizationCoche=editor.getValeur('Modele','listeEquation_stabilization', ('b_type_creation','Chemical_Equation',)) + + print (lInitialCoche,lInititiationCoche,lPropagationCoche,lTerminationCoche,lStabilizationCoche) + for liste in (lInitialCoche,lInititiationCoche,lPropagationCoche,lTerminationCoche,lStabilizationCoche): + # Il est possible qu'une liste soit vide lors de l initialisation + if liste == None : continue + for equation in liste : + print (equation) + for const in maClasseDelistesDB.dictParametresInitiaux[equation].constituants : + if const not in maClasseDelistesDB.listeParametresInitiaux : maClasseDelistesDB.listeParametresInitiaux.append(const) + #for coef in maClasseDelistesDB.dictParametresInitiaux[equation].const_cine_nom : + # if coef not in maClasseDelistesDB.listeCoefInitiaux : maClasseDelistesDB.listeCoefInitiaux.append(coef) + for num,coef in enumerate(maClasseDelistesDB.dictParametresInitiaux[equation].const_cine_nom ): + maClasseDelistesDB.dicoCoefAffichageArr[coef]=maClasseDelistesDB.dictParametresInitiaux[equation].arrhenius[num] + if coef not in maClasseDelistesDB.listeCoefInitiaux : maClasseDelistesDB.listeCoefInitiaux.append(coef) + + #print('maClasseDelistesDB.dictParametresInitiaux', maClasseDelistesDB.dictParametresInitiaux) + if monMCNom == 'Diffusion' : + change=editor.changeIntoDefMC('Modele', ('b_type_creation','Transport','b_diffusion','listeProduitPourLaDiffusion'), maClasseDelistesDB.listeParametresInitiaux ) + if monMCNom == 'Evaporation' : + change=editor.changeIntoDefMC('Modele', ('b_type_creation','Transport','b_evaporation','listeProduitPourLEvaporation'), maClasseDelistesDB.listeParametresInitiaux ) + + if monMCNom in ('Evaporation','Diffusion') : + for c in list(monModele.coef[0].keys()) : if c[0]=='D': clef=c[1:] - valeur= monModele.coef[0][c] - editor.dicoCoefD[clef]=valeur - print (editor.dicoCoefS,editor.dicoCoefD) + if clef in maClasseDelistesDB.listeParametresInitiaux : + maClasseDelistesDB.listeCoefD.append(clef) + maClasseDelistesDB.listeCoefInitiaux.append('D'+clef) + maClasseDelistesDB.listeCoefInitiaux.append('S'+clef) + else : + maClasseDelistesDB.listeCoefASupprimer.append('S'+clef) + maClasseDelistesDB.listeCoefASupprimer.append('D'+clef) + if c[0]=='B': + clef=c[1:] + if clef in maClasseDelistesDB.listeParametresInitiaux : + maClasseDelistesDB.listeCoefB.append(clef) + maClasseDelistesDB.listeCoefInitiaux.append(c) + else : + maClasseDelistesDB.listeCoefASupprimer.append(c) + print ('aClasseDelistesDB.listeCoefB',maClasseDelistesDB.listeCoefB) + print ('aClasseDelistesDB.listeCoefB',maClasseDelistesDB.listeCoefD) + print ('maClasseDelistesDB.listeCoefInitiaux',maClasseDelistesDB.listeCoefInitiaux) + print ('maClasseDelistesDB.listeCoefASupprimer',maClasseDelistesDB.listeCoefASupprimer) + print ('maClasseDelistesDB.listeParametresInitiaux',maClasseDelistesDB.listeParametresInitiaux) + # au lieu des print il faut mettre a jour le MC Fact Coefficients avec ,maClasseDelistesDB.listeCoefInitiaux et le MC FACT + # Paraetres_initiaux avec maClasseDelistesDB.listeParametresInitiaux + # TO DO TO DO PNPN + # si on arrive avex + # if monMC.nom = Diffusion + if monMCNom == 'Diffusion' : + editor.setValeur('Modele','listeProduitPourLaDiffusion' ,maClasseDelistesDB.listeCoefD, ('b_type_creation','Transport','b_diffusion',)) + #editor.changeValeur(....,'listeProduitPourLaDiffusion',maClasseDelistesDB.listeCoefD') + # if monMCNom == 'Evaporation' : + #editor.changeValeur(....,'listeProduitPourLaDiffusion',maClasseDelistesDB.listeCoefB') + + + +def ajouteEvaporation(monMC): + print ('je suis dans ajouteDiffusion') + if monMC.valeur == None : return + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + editor=monMC.jdc.editor + if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return + + monMC.dsMaFunct=True + for v in monMC.valeur : + clef='B'+v + if clef not in maClasseDelistesDB.listeCoefInitiaux : + maClasseDelistesDB.listeCoefInitiaux.append(clef) + + print ('sortie de ajouteDiffusion' , maClasseDelistesDB.listeCoefInitiaux) monMC.dsMaFunct=False editor.dsMaFunct = False - def ajouteDiffusion(monMC): print ('je suis dans ajouteDiffusion') if monMC.valeur == None : return - print (monMC.valeur) if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + editor=monMC.jdc.editor + if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return + monMC.dsMaFunct=True + for v in monMC.valeur : + clef='D'+v + if clef not in maClasseDelistesDB.listeCoefInitiaux : + maClasseDelistesDB.listeCoefInitiaux.append(clef) + maClasseDelistesDB.listeCoefInitiaux.append('S'+v) + maClasseDelistesDB.dicoCoefAffichageArr[clef] = True + maClasseDelistesDB.dicoCoefAffichageArr['S'+v] = False + #maClasseDelistesDB.dicoCoefAffichageArr['B'+v] = True + + # on affiche dans l interface un mot clef avec clef comme nom et + # 2 reels si ce commence par D soit iniitialise a 0 si pas de valeur + # soit avec comme deifaut nomCoef in monModele.coef[0].keys() + print ('sortie de ajouteDiffusion' , maClasseDelistesDB.listeCoefInitiaux) + + for nomCoef in maClasseDelistesDB.listeCoefInitiaux: + #A jout Ds Coef d'un MC + nomMC='Coef_'+nomCoef + if maClasseDelistesDB.dicoCoefAffichageArr[nomCoef] == True: + print ('2 r'), + if nomCoef in monModele.coef[0].keys() : + print (monModele.coef[0][nomCoef]) + else : + print ((0,0)) + else : + print ('1 r') + if nomCoef in monModele.coef[0].keys() : + print (monModele.coef[0][nomCoef]) + else : + print (0) + + print ('______________________') + #for v in monMC.valeur : + # print (v) + # mesValeurs=editor.dicoCoefS[v] + # MCFils='S'+v + # for e in monMC.jdc.etapes: + # if e.nom == 'Modele' :break + # editor.ajoutDefinitionMC(e,('b_type_creation','b_diffusion'),MCFils,typ='TXM',statut='o' ) + # editor.ajoutMC(e,MCFils,mesValeurs,('b_type_creation','b_diffusion',)) + # print ('______') + #if editor.fenetreCentraleAffichee : editor.fenetreCentraleAffichee.node.affichePanneau() + monMC.dsMaFunct=False + editor.dsMaFunct = False + + +# -------------------------------------------------------------------------------------------- +# pour les modeles en modification ou en utilisation +# -------------------------------------------------------------------------------------------- +def creeListeMateriauxSelonModele(monMC): + if monMC.valeur == None : return + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return editor=monMC.jdc.editor if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return - editor.dsMaFunct = True + valeurDB=editor.getValeur('Modele','Modele_DB',()) + maClasseDelistesDB.metAJour(valeurDB) + listModele=maClasseDelistesDB.getListModele() + listModeleFiltre=[] + listMateriauxFiltre=[] + for modele in listModele : + if modele.technical_use == monMC.valeur : + maClasseDelistesDB.dicoModeleFiltre[modele.nom]=modele + listModeleFiltre.append(modele.nom) + if type(modele.materiaux) not in (list, tuple): modeleATraiter= modele.materiaux + else : modeleATraiter= modele.materiaux[0] + if modeleATraiter not in listMateriauxFiltre : + listMateriauxFiltre.append(modeleATraiter) + maClasseDelistesDB.dicoMateriauxFiltre[modeleATraiter]=[modele.nom,] + else : + maClasseDelistesDB.dicoMateriauxFiltre[modeleATraiter].append(modele.nom) + + + + change=editor.changeIntoDefMC('Modele', ('b_type_modification','b_technicalUse','material'),listMateriauxFiltre ) + + monMC.dsMaFunct=False + editor.dsMaFunct = False + +def creeListeModelesPossibles(monMC): + if monMC.valeur == None : return + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + editor=monMC.jdc.editor + if hasattr(editor,'dsMaFunct') and editor.dsMaFunct== True : return + change=editor.changeIntoDefMC('Modele', ('b_type_modification','b_technicalUse','modele'),maClasseDelistesDB.dicoMateriauxFiltre[monMC.valeur] ) - for v in monMC.valeur : - print (v) - mesValeurs=editor.dicoCoefS[v] - print (editor.dicoCoefS) - print (mesValeurs) - MCFils='S'+v - for e in monMC.jdc.etapes: - if e.nom == Modele :break - - print (e) - editor.ajoutDefinitionMC(e,('b_type_creation','b_diffusion'),MCFils,typ='TXM',statut='o' ) - print ('ggggg') - editor.ajoutMC(e,MCFils,mesValeurs,('b_type_creation','b_diffusion',)) - print ('______') - if editor.fenetreCentraleAffichee : editor.fenetreCentraleAffichee.node.affichePanneau() monMC.dsMaFunct=False editor.dsMaFunct = False +def choisitModele(monMC): + # Equation b_modification modification + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + valeur=monMC.valeur + if valeur == None : return + modele=maClasseDelistesDB.dicoModeleFiltre[monMC.valeur] + maClasseDelistesDB.monModele=modele + monMC.dsMaFunct = False + +def choisitActionModele(monMC): + if monMC.valeur == 'display' : afficheModele(monMC) + if monMC.valeur == 'modify' : changeValeurDefautModele(monMC) + +def afficheModele(monMC): + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + valeur=monMC.valeur + aAfficher=str(maClasseDelistesDB.monModele) + editor=monMC.jdc.editor + editor._viewText(aAfficher, "Id",largeur=700,hauteur=500) + + monMC.dsMaFunct = False + +def changeValeurDefautModele(monMC): + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + monMC.dsMaFunct = True + editor=monMC.jdc.editor + change=editor.changeIntoMCandSet('Modele', ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID','modeleName'),(maClasseDelistesDB.monModele.nom,),maClasseDelistesDB.monModele.nom, ) + editor.setValeur('Modele','technicalUse',maClasseDelistesDB.monModele.technical_use, ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID')) + + editor.setValeur('Modele','material',maClasseDelistesDB.monModele.materiaux, ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID')) + editor.setValeur('Modele','agingType',maClasseDelistesDB.monModele.type_vieil, ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID')) + + if maClasseDelistesDB.monModele.stabilise == 'True' : monBool = True + else : monBool = False + editor.setValeur('Modele','stabilizer',monBool, ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID')) + editor.setValeur('Modele','material_thickness',maClasseDelistesDB.monModele.thickness, ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID')) + + if maClasseDelistesDB.monModele.dvt_EDF == 'True' : monBool = True + else : monBool = False + editor.setValeur('Modele','model_developed_by_for_EDF',monBool, ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID')) + editor.setValeur('Modele','documentation',maClasseDelistesDB.monModele.reference, ('b_type_modification','b_technicalUse','b_modele','b_type_modify','ID')) + if editor.fenetreCentraleAffichee : editor.fenetreCentraleAffichee.node.affichePanneau() + monMC.dsMaFunct = False + + + +def creeCoefAModifier(monMC): + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + if monMC.valeur == None : return + monMC.dsMaFunct = True + editor=monMC.jdc.editor + dicoArr={} + dicoNonArr={} + for coef in maClasseDelistesDB.monModele.coef[0] : + if len (maClasseDelistesDB.monModele.coef[0][coef]) == 1 : + dicoNonArr[coef]=maClasseDelistesDB.monModele.coef[0][coef][0] + else : + dicoArr[coef]=maClasseDelistesDB.monModele.coef[0][coef] + if coef[0] == 'D' : maClasseDelistesDB.listeDiffusion.append(coef[1:]) + print (dicoNonArr) + print (dicoArr) + if 'ri' in dicoNonArr : + print ('ajoutDefinitionMC debitOfDose') + editor.ajoutDefinitionMC('Modele', ('b_type_modification','b_technicalUse','b_modele','b_type_use2','Aging_Factor'), 'debitOfDose',typ='R',statut='o' ) + + for coef in dicoNonArr : + print (coef) + # attention, notation scientifique + editor.ajoutDefinitionMC('Modele',('b_type_modification','b_technicalUse','b_modele','b_type_use',),coef, 'R', statut='o',defaut=dicoNonArr[coef]) + # a faire marcher + # pour les Arr il faut un tuple(2) + + # il fait creer un fact Boundary_Conditions_Param pour chacque espece de listeDiffusion + + if editor.fenetreCentraleAffichee : editor.fenetreCentraleAffichee.node.affichePanneau() + + monMC.dsMaFunct = False + + +def remplirAgingFactor(monMC): + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + if monMC.valeur == None : return + monMC.dsMaFunct = True + editor=monMC.jdc.editor + if monMC.valeur in dicoAgingFactor: + print (monMC.valeur, 'trouve') + for MC in dicoAgingFactor[monMC.valeur]: + print (MC) + print (dicoAgingFactor[monMC.valeur][MC]), + editor.setValeur('Modele',MC,dicoAgingFactor[monMC.valeur][MC],('b_type_modification','b_technicalUse','b_modele','b_type_use2','Aging_Factor')) + monMC.dsMaFunct = False + + +def creeInitialParameter(monMC): + print ('je passe dans creeInitialParameter') + if hasattr(monMC,'dsMaFunct') and monMC.dsMaFunct== True : return + if monMC.valeur == None : return + monMC.dsMaFunct = True + editor=monMC.jdc.editor + for coef in maClasseDelistesDB.monModele.param_ini: + editor.ajoutDefinitionMC('Modele',('b_type_modification','b_technicalUse','b_modele','b_type_use2','Initial_Parameter'),coef, 'R', statut='o',defaut=maClasseDelistesDB.monModele.param_ini[coef][0]) + monMC.dsMaFunct = False + # creer nbdenode = monMC.valeur Initial_Parameter diff --git a/VirtualPolymer/listesDB.py b/VirtualPolymer/listesDB.py index fbef9b46..e95cfa78 100644 --- a/VirtualPolymer/listesDB.py +++ b/VirtualPolymer/listesDB.py @@ -21,6 +21,7 @@ class sModele : def __init__ (self): self.monModele=class_data.Modele() + self.monPost=class_data.Post_traitement() # -------------------------------------- @@ -42,11 +43,28 @@ class classeListesDB : self.listPostTraitement = None self.dicoListAffiche = {} self.valeurEquationChoisie = None - + self.listeConstantesAAfficher = [] + self.listeEquationsAAfficher = [] + self.listeCoefD = [] + self.listeCoefB = [] + self.dictParametresInitiaux = {} + self.listeParametresInitiaux= [] + self.listeCoefInitiaux= [] + self.listeCoefASupprimer= [] + self.dicoCoefAffichageArr = {} + self.dicoModeleFiltre = {} + self.dicoMateriauxFiltre = {} + self.monModele = None + self.listeDiffusion = [] + def metAJour(self,valeur): + print ('metAJour') if valeur == None : return correspond=pckdb.DBRENAME self.listEquation, self.listModele,self.listPostTraitement=pckdb.read_pckdb(correspond[valeur]) + self.dicoListeEquation = {} + for equation in self.listEquation : + self.dicoListeEquation[equation.representation]=equation def getListEquation(self): return self.listEquation diff --git a/VirtualPolymer/opsOT.py b/VirtualPolymer/opsOT.py deleted file mode 100644 index e2af4083..00000000 --- a/VirtualPolymer/opsOT.py +++ /dev/null @@ -1,20 +0,0 @@ -# -*- coding: iso-8859-1 -*- - -def INCLUDE(self,FileName,**args): - """ - Fonction sd_prod pour la macro INCLUDE - """ - if hasattr(self,'change_fichier'): - delattr(self,'change_fichier') - delattr(self,'fichier_ini') - - self.make_include2(fichier=FileName) - -def INCLUDE_context(self,d): - """ - Fonction op_init pour macro INCLUDE - """ - for k,v in self.g_context.items(): - d[k]=v - - diff --git a/boundary_conditions/CMakeLists.txt b/boundary_conditions/CMakeLists.txt new file mode 100644 index 00000000..9d5d3202 --- /dev/null +++ b/boundary_conditions/CMakeLists.txt @@ -0,0 +1,32 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +# --- Python files --- + +SET(PYFILES + __init__.py + configuration_boundary_conditions.py + prefs_boundary_conditions.py + prefs.py + boundary_conditions_cata.py + appli.py + generator_boundary_conditions.py +) + +# --- rules --- + +SALOME_INSTALL_SCRIPTS("${PYFILES}" ${SALOME_INSTALL_PYTHON}/salome/hydro/boundary_conditions/eficas) diff --git a/boundary_conditions/__init__.py b/boundary_conditions/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/boundary_conditions/appli.py b/boundary_conditions/appli.py new file mode 100644 index 00000000..b3783292 --- /dev/null +++ b/boundary_conditions/appli.py @@ -0,0 +1,45 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +import os +import sys + +import SalomePyQt +sgPyQt = SalomePyQt.SalomePyQt() + +import eficasSalome + +class EficasForBoundaryConditionsAppli(eficasSalome.MyEficas): + """ + This class launches Eficas with "boundary_conditions" catalog. + """ + def __init__(self, fichier = None, version = None): + self.codedir = os.path.dirname(__file__) + sys.path[:0] = [self.codedir] + eficasSalome.MyEficas.__init__(self, sgPyQt.getDesktop(), "boundary_conditions", + fichier, version = version) + + def addJdcInSalome(self, jdcPath): + """ + Those files are not added in Salome study tree for now. + """ + pass + + def closeEvent(self, event): + while self.codedir in sys.path: + sys.path.remove(self.codedir) + eficasSalome.MyEficas.closeEvent(self, event) diff --git a/boundary_conditions/boundary_conditions_cata.py b/boundary_conditions/boundary_conditions_cata.py new file mode 100644 index 00000000..f41671c3 --- /dev/null +++ b/boundary_conditions/boundary_conditions_cata.py @@ -0,0 +1,59 @@ +# -*- coding: utf-8 -*- +# +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +from Accas import * + +class grma(GEOM): + """ + Class used to define the group on which the boundary condition is defined. + Method __convert__ is redefined to skip the test on the string length. + """ + def __convert__(cls, valeur): + if isinstance(valeur, (str, unicode)): + return valeur.strip() + raise ValueError('A string is expected') + + __convert__ = classmethod(__convert__) + + +JdC = JDC_CATA(regles = (AU_MOINS_UN('BOUNDARY_CONDITION',)), + ) + +BOUNDARY_CONDITION = PROC( + nom = "BOUNDARY_CONDITION", op = None, + fr = u"Définition d'une condition limite pour Telemac2D", + ang = u"Definition of a boundary condition for Telemac2D", + + GROUP = SIMP(statut = "o", typ = grma, + fr = u"Groupe sur lequel la condition limite est définie", + ang = u"Group on which the boundary condition is defined", + ), + LIHBOR = SIMP(statut = "o", typ = "I", + fr = u"Type de condition limite pour la hauteur d'eau", + ang = u"Boundary condition type for the water height", + ), + LIUBOR = SIMP(statut = "o", typ = "I", + fr = u"Type de condition limite pour la composante U de la vitesse", + ang = u"Boundary condition type for the U component of the water velocity", + ), + LIVBOR = SIMP(statut = "o", typ = "I", + fr = u"Type de condition limite pour la composante V de la vitesse", + ang = u"Boundary condition type for the V component of the water velocity", + ), +) diff --git a/boundary_conditions/configuration_boundary_conditions.py b/boundary_conditions/configuration_boundary_conditions.py new file mode 100644 index 00000000..ffed4a66 --- /dev/null +++ b/boundary_conditions/configuration_boundary_conditions.py @@ -0,0 +1,48 @@ +# -*- coding: utf-8 -*- +# +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +import os + +from Editeur.catadesc import CatalogDescription +from InterfaceQT4.configuration import CONFIG_BASE + +class CONFIG(CONFIG_BASE): + + def __init__(self, appli, repIni): + """ + This class stores the configuration parameters for Eficas + """ + CONFIG_BASE.__init__(self, appli, repIni) + + # Configuration parameters + self.savedir = os.getenv("HOME") + self.catalogues = (CatalogDescription("boundary_conditions", + os.path.join(repIni, "boundary_conditions_cata.py"), + file_format = "boundary_conditions"),) + self.lang = 'fr' + self.generator_module = "generator_boundary_conditions" + + def save_params(self): + pass + +def make_config(appli, rep): + return CONFIG(appli, rep) + +def make_config_style(appli, rep): + return None diff --git a/boundary_conditions/generator_boundary_conditions.py b/boundary_conditions/generator_boundary_conditions.py new file mode 100644 index 00000000..ea7235dd --- /dev/null +++ b/boundary_conditions/generator_boundary_conditions.py @@ -0,0 +1,57 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +import os +from generator.generator_python import PythonGenerator + +def entryPoint(): + return {'name': 'boundary_conditions', + 'factory': BoundaryConditionsGenerator} + +class BoundaryConditionsGenerator(PythonGenerator): + """ + This generator creates files containing associations between groups and + boundary conditions (.bcd files, for Boundary Conditions Definition). + Those files contain one line per group, each line containing four fields + separated by spaces: LIHBOR LIUBOR LIVBOR GROUP. + LIHBOR, LIUBOR and LIVBOR are integer values, GROUP is a string (the name of + the group). + + Example: + + + """ + + def gener(self, obj, format = 'brut', config = None): + self.group_list = [] + self.text = PythonGenerator.gener(self, obj, format) + return self.text + + def generPROC_ETAPE(self, obj): + group_dict = {} + for keyword in obj.mc_liste: + group_dict[keyword.nom] = keyword.valeur + self.group_list.append(group_dict) + return PythonGenerator.generPROC_ETAPE(self, obj) + + def writeDefault(self, basefilename): + output_filename = os.path.splitext(basefilename)[0] + ".bcd" + f = open(output_filename, 'w') + f.write("%d\n" % len(self.group_list)) + for group_dict in self.group_list: + f.write("%(LIHBOR)d %(LIUBOR)d %(LIVBOR)d %(GROUP)s\n" % group_dict) + f.close() diff --git a/boundary_conditions/prefs.py b/boundary_conditions/prefs.py new file mode 100644 index 00000000..8f7d046d --- /dev/null +++ b/boundary_conditions/prefs.py @@ -0,0 +1,18 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +code = "boundary_conditions" diff --git a/boundary_conditions/prefs_boundary_conditions.py b/boundary_conditions/prefs_boundary_conditions.py new file mode 100644 index 00000000..bcf1ef2d --- /dev/null +++ b/boundary_conditions/prefs_boundary_conditions.py @@ -0,0 +1,21 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +import os + +repIni = os.path.dirname(__file__) +INSTALLDIR = os.getenv("EFICAS_ROOT") diff --git a/convert/convert_python.py b/convert/convert_python.py index 1384ee9b..d661a5f1 100644 --- a/convert/convert_python.py +++ b/convert/convert_python.py @@ -114,7 +114,19 @@ class PythonParser(object): def convert(self,outformat,appli=None): if outformat == 'exec': try: - return PARSEUR_PYTHON(self.text).get_texte(appli) + #import cProfile, pstats, StringIO + #pr = cProfile.Profile() + #pr.enable() + l= PARSEUR_PYTHON(self.text).get_texte(appli) + + #pr.disable() + #s = StringIO.StringIO() + #sortby = 'cumulative' + #ps = pstats.Stats(pr, stream=s).sort_stats(sortby) + #ps.print_stats() + #print (s.getvalue()) + + return l except EficasException: # Erreur lors de la conversion l=traceback.format_exception(sys.exc_info()[0],sys.exc_info()[1], diff --git a/generator/generator_python.py b/generator/generator_python.py index b40e6589..bafc218a 100644 --- a/generator/generator_python.py +++ b/generator/generator_python.py @@ -102,6 +102,9 @@ class PythonGenerator(object): Si format vaut 'beautifie', retourne le meme texte beautifie """ import logging + if obj == None : + print ('appel a gener avec None') + return self.appli=obj.get_jdc_root().appli #self.appli=obj.appli liste= self.generator(obj) diff --git a/mascaret/CMakeLists.txt b/mascaret/CMakeLists.txt new file mode 100644 index 00000000..deb3c655 --- /dev/null +++ b/mascaret/CMakeLists.txt @@ -0,0 +1,31 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +# --- Python files --- + +SET(PYFILES + __init__.py + appli.py + configuration_mascaret.py + prefs_mascaret.py + prefs.py + mascaret_V7_cata.py +) + +# --- rules --- + +SALOME_INSTALL_SCRIPTS("${PYFILES}" ${SALOME_INSTALL_PYTHON}/salome/hydro/mascaret/eficas) diff --git a/mascaret/__init__.py b/mascaret/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/mascaret/appli.py b/mascaret/appli.py new file mode 100644 index 00000000..1fd13263 --- /dev/null +++ b/mascaret/appli.py @@ -0,0 +1,76 @@ +# -*- coding: utf-8 -*- +# +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +import os +import sys +import re + +from PyQt5.QtWidgets import QMessageBox + + +import salome +import SalomePyQt +sgPyQt = SalomePyQt.SalomePyQt() + +from salome.kernel.logger import Logger +from salome.kernel import termcolor +logger = Logger("salome.hydro.mascaret.eficas.appli", + color = termcolor.GREEN_FG) + +import eficasSalome + +from salome.hydro.study import HydroStudyEditor + +class EficasForMascaretAppli(eficasSalome.MyEficas): + """ + This class launches Eficas and adds entries for the created files in + MASCARET component in the study tree. The messages in this class are in + french because they are displayed in Eficas interface. + + :type fichier: string + :param fichier: path of an Eficas file to open + + """ + def __init__(self, fichier = None, version = None): + self.ed = HydroStudyEditor() + self.codedir = os.path.dirname(__file__) + sys.path[:0] = [self.codedir] + eficasSalome.MyEficas.__init__(self, sgPyQt.getDesktop(), + "mascaret", + fichier, version = version) + sgPyQt.createView("Eficas Mascaret", self) + + def addJdcInSalome(self, jdcPath): + """ + Add the newly created file in Salome study + """ + try: + self.ed.find_or_create_mascaret_case(jdcPath) + except Exception, exc: + msgError = "Can't add file to Salome study tree" + logger.exception(msgError) + QMessageBox.warning(self, self.tr("Warning"), + self.tr("%s. Reason:\n%s\n\nSee logs for " + "more details." % (msgError, exc))) + salome.sg.updateObjBrowser(0) + + def closeEvent(self, event): + while self.codedir in sys.path: + sys.path.remove(self.codedir) + eficasSalome.MyEficas.closeEvent(self, event) diff --git a/mascaret/configuration_mascaret.py b/mascaret/configuration_mascaret.py new file mode 100644 index 00000000..7695ed41 --- /dev/null +++ b/mascaret/configuration_mascaret.py @@ -0,0 +1,46 @@ +# -*- coding: utf-8 -*- +# +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +import os + +from Editeur.catadesc import CatalogDescription +from InterfaceQT4.configuration import CONFIG_BASE + +class CONFIG(CONFIG_BASE): + + def __init__(self, appli, repIni): + """ + This class stores the configuration parameters for Eficas + """ + CONFIG_BASE.__init__(self, appli, repIni) + + # Configuration parameters + self.savedir = os.getenv("HOME") + self.catalogues = (CatalogDescription("mascaret_V7", + os.path.join(repIni, "mascaret_V7_cata.py")),) + self.lang = 'fr' + + def save_params(self): + pass + +def make_config(appli, rep): + return CONFIG(appli, rep) + +def make_config_style(appli, rep): + return None diff --git a/mascaret/mascaret_V7_cata.py b/mascaret/mascaret_V7_cata.py new file mode 100644 index 00000000..c3a97a34 --- /dev/null +++ b/mascaret/mascaret_V7_cata.py @@ -0,0 +1,107 @@ +# -*- coding: utf-8 -*- +# +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +from Accas import * + +JdC = JDC_CATA(regles = (UN_PARMI('MASCARET',)), + ) + +MASCARET = PROC( + nom = "MASCARET", op = None, + fr = u"Définition d'un cas d'étude Mascaret", + ang = u"Definition of a Mascaret study case", + FICHIER_DICO = SIMP(statut = "o", typ = 'Fichier', + fr = u"Fichier Dictionnaire", + ang = u"Dictionary file"), + FICHIER_MOT_CLE = SIMP(statut = "o", + typ = ('Fichier', 'Fichiers CAS (*.cas);;Tous les fichiers (*)',), + fr = u"Fichier Mot Clé", + ang = u"Keyword file"), + FICHIER_GEOMETRIE = SIMP(statut = "f", + typ = ('Fichier', 'Fichiers GEO (*.geo);;Tous les fichiers (*)',), + fr = u"Fichier de géométrie", + ang = u"Geometry file"), + FICHIER_LOI = FACT(statut = 'f', max = '**', + NOM = SIMP(statut = "o", + typ = ('Fichier', 'Fichiers LOI (*.loi);;Tous les fichiers (*)',), + fr = u"Fichier de lois", + ang = u"Laws file"), + ), + FICHIER_ABAQUES = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)',), + fr = u"Fichier abaques", + ang = u"Abacus file"), + FICHIER_CASIER = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)',), + fr = u"Fichier casier", + ang = u"Compartment file"), + FICHIER_DAMOCLE = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)',), + fr = u"Fichier damocle", + ang = u"Damocle file"), + FICHIER_LIG = SIMP(statut = "o", + typ = ('Fichier', 'Fichiers LIG (*.lig);;Tous les fichiers (*)',), + fr = u"Fichier LIG", + ang = u"LIG file"), + LISTING = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)', "Sauvegarde"), + fr = u"Fichier de listing", + ang = u"Listing file"), + LISTING_CASIER = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)', "Sauvegarde"), + fr = u"Fichier de listing casier", + ang = u"Compartment listing file"), + LISTING_LIAISON = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)', "Sauvegarde"), + fr = u"Fichier de listing liaison", + ang = u"Link listing file"), + RESULTAT = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)', "Sauvegarde"), + fr = u"Fichier de résultat", + ang = u"Result file"), + RESULTAT_CASIER = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)', "Sauvegarde"), + fr = u"Fichier de résultat casier", + ang = u"Compartment result file"), + RESULTAT_LIAISON = SIMP(statut = "f", + typ = ('Fichier', 'Tous les fichiers (*)', "Sauvegarde"), + fr = u"Fichier de résultat liaison", + ang = u"Link result file"), + VARIABLE_SORTIE = FACT(statut = 'f', max = '**', + fr = u"Variable de sortie du calcul", + ang = u"Computation output variable", + NOM = SIMP(statut = "o", typ = 'TXM', + fr = u"Nom de la variable", + ang = u"Variable name"), + VARIABLE_MASCARET = SIMP(statut = "o", typ = 'TXM', + fr = u'Variable Mascaret (ex : "Etat.Z(1,0,0)")', + ang = u'Mascaret variable (ex : "Etat.Z(1,0,0)")'), + ), + VARIABLE_ENTREE = FACT(statut = 'f', max = '**', + fr = u"Variable d'entrée du calcul", + ang = u"Computation input variable", + NOM = SIMP(statut = "o", typ = 'TXM', + fr = u"Nom de la variable", + ang = u"Variable name"), + VARIABLE_MASCARET = SIMP(statut = "o", typ = 'TXM', + fr = u'Variable Mascaret (ex : "Modele.Lois.Debit(1,1-2,0)")', + ang = u'Mascaret variable (ex : "Modele.Lois.Debit(1,1-2,0)")'), + ), +) +TEXTE_NEW_JDC="MASCARET()" diff --git a/mascaret/prefs.py b/mascaret/prefs.py new file mode 100644 index 00000000..d0e8113c --- /dev/null +++ b/mascaret/prefs.py @@ -0,0 +1,18 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +code = "mascaret" diff --git a/mascaret/prefs_mascaret.py b/mascaret/prefs_mascaret.py new file mode 100644 index 00000000..ed30a092 --- /dev/null +++ b/mascaret/prefs_mascaret.py @@ -0,0 +1,28 @@ +# Copyright (C) 2012-2013 EDF +# +# This file is part of SALOME HYDRO module. +# +# SALOME HYDRO module is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# SALOME HYDRO module is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with SALOME HYDRO module. If not, see . + +import os +import sys + +repIni = os.path.dirname(__file__) +INSTALLDIR = os.getenv("EFICAS_ROOT") +closeAutreCommande=True +closeFrameRechercheCommande=True +closeArbre=True +closeCopier=True +suiteTelemac=True + -- 2.39.2