Skip to content

Commit

Permalink
FEM: 1DFlow, object modules
Browse files Browse the repository at this point in the history
  • Loading branch information
kgoao authored and wwmayer committed Feb 28, 2017
1 parent f087a65 commit 5c0660d
Show file tree
Hide file tree
Showing 8 changed files with 1,505 additions and 1 deletion.
4 changes: 4 additions & 0 deletions src/Mod/Fem/App/CMakeLists.txt
Expand Up @@ -89,6 +89,7 @@ SET(FemObjectsScripts_SRCS
PyObjects/__init__.py
PyObjects/_FemBeamSection.py
PyObjects/_FemConstraintSelfWeight.py
PyObjects/_FemFluidSection.py
PyObjects/_FemMaterialMechanicalNonlinear.py
PyObjects/_FemMeshGmsh.py
PyObjects/_FemMeshGroup.py
Expand Down Expand Up @@ -124,6 +125,7 @@ SET(FemGuiScripts_SRCS
PyGui/_CommandSolverCalculix.py
PyGui/_CommandSolverZ88.py
PyGui/_TaskPanelFemBeamSection.py
PyGui/_TaskPanelFemFluidSection.py
PyGui/_TaskPanelFemMeshGmsh.py
PyGui/_TaskPanelFemMeshGroup.py
PyGui/_TaskPanelFemMeshRegion.py
Expand All @@ -133,6 +135,7 @@ SET(FemGuiScripts_SRCS
PyGui/_TaskPanelShowResult.py
PyGui/_ViewProviderFemBeamSection.py
PyGui/_ViewProviderFemConstraintSelfWeight.py
PyGui/_ViewProviderFemFluidSection.py
PyGui/_ViewProviderFemMaterialMechanicalNonlinear.py
PyGui/_ViewProviderFemMeshGmsh.py
PyGui/_ViewProviderFemMeshGroup.py
Expand All @@ -143,6 +146,7 @@ SET(FemGuiScripts_SRCS
PyGui/_ViewProviderFemSolverZ88.py
PyGui/_ViewProviderFemMaterial.py
PyGui/TaskPanelFemBeamSection.ui
PyGui/TaskPanelFemFluidSection.ui
PyGui/TaskPanelFemMeshGmsh.ui
PyGui/TaskPanelFemMeshGroup.ui
PyGui/TaskPanelFemMeshRegion.ui
Expand Down
6 changes: 5 additions & 1 deletion src/Mod/Fem/CMakeLists.txt
Expand Up @@ -47,6 +47,7 @@ INSTALL(
PyObjects/__init__.py
PyObjects/_FemBeamSection.py
PyObjects/_FemConstraintSelfWeight.py
PyObjects/_FemFluidSection.py
PyObjects/_FemMaterialMechanicalNonlinear.py
PyObjects/_FemMeshGmsh.py
PyObjects/_FemMeshGroup.py
Expand Down Expand Up @@ -85,6 +86,7 @@ INSTALL(
PyGui/_CommandSolverCalculix.py
PyGui/_CommandSolverZ88.py
PyGui/_TaskPanelFemBeamSection.py
PyGui/_TaskPanelFemFluidSection.py
PyGui/_TaskPanelFemMeshGmsh.py
PyGui/_TaskPanelFemMeshGroup.py
PyGui/_TaskPanelFemMeshRegion.py
Expand All @@ -94,6 +96,7 @@ INSTALL(
PyGui/_TaskPanelShowResult.py
PyGui/_ViewProviderFemBeamSection.py
PyGui/_ViewProviderFemConstraintSelfWeight.py
PyGui/_ViewProviderFemFluidSection.py
PyGui/_ViewProviderFemMaterialMechanicalNonlinear.py
PyGui/_ViewProviderFemMeshGmsh.py
PyGui/_ViewProviderFemMeshGroup.py
Expand All @@ -104,12 +107,13 @@ INSTALL(
PyGui/_ViewProviderFemSolverZ88.py
PyGui/_ViewProviderFemMaterial.py
PyGui/TaskPanelFemBeamSection.ui
PyGui/TaskPanelFemFluidSection.ui
PyGui/TaskPanelFemMaterial.ui
PyGui/TaskPanelFemMeshGmsh.ui
PyGui/TaskPanelFemMeshGroup.ui
PyGui/TaskPanelFemMeshRegion.ui
PyGui/TaskPanelFemShellThickness.ui
PyGui/TaskPanelFemSolverCalculix.ui
PyGui/TaskPanelFemMaterial.ui
PyGui/TaskPanelShowResult.ui
DESTINATION
Mod/Fem/PyGui
Expand Down
11 changes: 11 additions & 0 deletions src/Mod/Fem/ObjectsFem.py
Expand Up @@ -83,6 +83,17 @@ def makeBeamSection(sectiontype='Rectangular', width=10.0, height=25.0, name="Be
return obj


def makeFemFluidSection(name="FluidSection"):
'''makeFemFluidSection([name]): creates an Fluid section object to define 1D flow'''
obj = FreeCAD.ActiveDocument.addObject("Fem::FeaturePython", name)
import PyObjects._FemFluidSection
PyObjects._FemFluidSection._FemFluidSection(obj)
if FreeCAD.GuiUp:
import PyGui._ViewProviderFemFluidSection
PyGui._ViewProviderFemFluidSection._ViewProviderFemFluidSection(obj.ViewObject)
return obj


def makeShellThickness(thickness=20.0, name="ShellThickness"):
'''makeShellThickness([thickness], [name]): creates an shellthickness object to define a plate thickness'''
obj = FreeCAD.ActiveDocument.addObject("Fem::FeaturePython", name)
Expand Down

0 comments on commit 5c0660d

Please sign in to comment.