From d872676e390c9eb813d58475a6a9b2a1219ce627 Mon Sep 17 00:00:00 2001 From: Javi G Date: Tue, 3 Mar 2020 12:21:47 +0100 Subject: [PATCH 1/5] Filter const law by element --- .../apps/PfemFluid/xml/ConstitutiveLaws.xml | 12 +++---- kratos.gid/apps/PfemFluid/xml/Elements.xml | 36 ++++++++++++------- 2 files changed, 30 insertions(+), 18 deletions(-) diff --git a/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml b/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml index 238716ff8..a13003776 100644 --- a/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml +++ b/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml @@ -1,16 +1,16 @@ - + - - + + - + @@ -22,7 +22,7 @@ - + @@ -36,7 +36,7 @@ - + diff --git a/kratos.gid/apps/PfemFluid/xml/Elements.xml b/kratos.gid/apps/PfemFluid/xml/Elements.xml index 4dd668972..c1754c930 100644 --- a/kratos.gid/apps/PfemFluid/xml/Elements.xml +++ b/kratos.gid/apps/PfemFluid/xml/Elements.xml @@ -15,7 +15,8 @@ - + + @@ -41,7 +42,8 @@ - + + @@ -67,7 +69,8 @@ - + + @@ -93,7 +96,8 @@ - + + @@ -120,7 +124,8 @@ - + + @@ -149,7 +154,8 @@ - + + @@ -176,7 +182,8 @@ - + + @@ -205,7 +212,8 @@ - + + @@ -236,7 +244,8 @@ - + + @@ -262,7 +271,8 @@ - + + @@ -289,7 +299,8 @@ - + + @@ -318,7 +329,8 @@ - + + From 9c7e2116a29f057e5a937b407164c1347d141fa3 Mon Sep 17 00:00:00 2001 From: Javi G Date: Tue, 3 Mar 2020 12:25:48 +0100 Subject: [PATCH 2/5] minor --- kratos.gid/apps/PfemFluid/xml/Elements.xml | 36 +++++++++++----------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/kratos.gid/apps/PfemFluid/xml/Elements.xml b/kratos.gid/apps/PfemFluid/xml/Elements.xml index c1754c930..8d3a2ad49 100644 --- a/kratos.gid/apps/PfemFluid/xml/Elements.xml +++ b/kratos.gid/apps/PfemFluid/xml/Elements.xml @@ -63,24 +63,24 @@ help="To be written by..." ElementType="Fluid" Dofs="VELOCITY,PRESSURE"> - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + From 6e87e8870d98f2522bde39f2cb34675dfffb9a91 Mon Sep 17 00:00:00 2001 From: Massimiliano Zecchetto Date: Wed, 4 Mar 2020 11:00:01 +0100 Subject: [PATCH 3/5] Add constitutive laws --- .../apps/PfemFluid/xml/ConstitutiveLaws.xml | 132 +++++++++++++++++- 1 file changed, 127 insertions(+), 5 deletions(-) diff --git a/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml b/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml index a13003776..38bc67b1d 100644 --- a/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml +++ b/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml @@ -1,7 +1,8 @@ - - + + + @@ -10,7 +11,31 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + @@ -22,7 +47,8 @@ - + + @@ -36,7 +62,102 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -45,4 +166,5 @@ + From c31cd3b2e4678efaf357dba5cdae53cdf9df1545 Mon Sep 17 00:00:00 2001 From: Javi G Date: Thu, 30 Apr 2020 13:58:12 +0200 Subject: [PATCH 4/5] Dimension filter in Const laws --- .../apps/PfemFluid/xml/ConstitutiveLaws.xml | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml b/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml index 38bc67b1d..379e3aff1 100644 --- a/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml +++ b/kratos.gid/apps/PfemFluid/xml/ConstitutiveLaws.xml @@ -2,7 +2,7 @@ - + @@ -12,7 +12,7 @@ - + @@ -22,7 +22,7 @@ - + @@ -35,7 +35,7 @@ - + @@ -48,7 +48,7 @@ - + @@ -63,7 +63,7 @@ - + @@ -79,7 +79,7 @@ - + @@ -89,7 +89,7 @@ - + @@ -99,7 +99,7 @@ - + @@ -112,7 +112,7 @@ - + @@ -126,7 +126,7 @@ - + @@ -136,7 +136,7 @@ - + @@ -147,7 +147,7 @@ - + @@ -157,7 +157,7 @@ - + From 73f5e0b4ecf2910ab859bb483d9cc9e36acb66e2 Mon Sep 17 00:00:00 2001 From: Massimiliano Zecchetto Date: Thu, 30 Apr 2020 17:13:09 +0200 Subject: [PATCH 5/5] Write the claw name in material file --- kratos.gid/apps/PfemFluid/write/write.tcl | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/kratos.gid/apps/PfemFluid/write/write.tcl b/kratos.gid/apps/PfemFluid/write/write.tcl index 2e343300a..44cf937de 100644 --- a/kratos.gid/apps/PfemFluid/write/write.tcl +++ b/kratos.gid/apps/PfemFluid/write/write.tcl @@ -13,7 +13,7 @@ proc PfemFluid::write::Init { } { set bodies_list [list ] variable Names set Names [dict create DeltaTime DeltaTime] - + SetAttribute properties_location json SetAttribute model_part_name "PfemFluidModelPart" SetAttribute materials_file "PFEMFluidMaterials.json" @@ -24,17 +24,17 @@ proc PfemFluid::write::Init { } { proc PfemFluid::write::writeModelPartEvent { } { # Init data write::initWriteConfiguration [GetAttributes] - + set parts_un_list [GetPartsUN] foreach part_un $parts_un_list { write::initWriteData $part_un "PFEMFLUID_Materials" } - + write::writeModelPartData write::WriteString "Begin Properties 0" write::WriteString "End Properties" # write::writeMaterials "PfemFluid" - + write::writeNodalCoordinates foreach part_un $parts_un_list { write::initWriteData $part_un "PFEMFLUID_Materials" @@ -44,21 +44,21 @@ proc PfemFluid::write::writeModelPartEvent { } { } proc PfemFluid::write::writeMeshes { } { - + foreach part_un [GetPartsUN] { write::initWriteData $part_un "PFEMFLUID_Materials" write::writePartSubModelPart } # Solo Malla , no en conditions writeNodalConditions "PFEMFLUID_NodalConditions" - + } proc PfemFluid::write::writeNodalConditions { keyword } { write::writeNodalConditions $keyword return "" - + set root [customlib::GetBaseRoot] set xp1 "[spdAux::getRoute $keyword]/container/blockdata" set groups [$root selectNodes $xp1] @@ -98,11 +98,11 @@ proc PfemFluid::write::GetPartsUN { } { # Custom files (Copy python scripts, write materials file...) proc PfemFluid::write::writeCustomFilesEvent { } { # Write the fluid materials json file - PfemFluid::write::WriteMaterialsFile False - + PfemFluid::write::WriteMaterialsFile + write::CopyFileIntoModel "python/RunPFEM.py" write::RenameFileInModel "RunPFEM.py" "MainKratos.py" - + #write::RenameFileInModel "ProjectParameters.json" "ProjectParameters.py" }