Skip to content

Commit

Permalink
FEM: udate 3D FEM example file and add 2D FEM example file
Browse files Browse the repository at this point in the history
  • Loading branch information
berndhahnebach committed Jun 3, 2016
1 parent adebabe commit 108fe75
Show file tree
Hide file tree
Showing 7 changed files with 33 additions and 3 deletions.
1 change: 1 addition & 0 deletions data/examples/CMakeLists.txt
Expand Up @@ -6,6 +6,7 @@ SET(Examples_Files
PartDesignExample.FCStd
RobotExample.FCStd
ArchDetail.FCStd
FemCalculixCantilever2D.FCStd
FemCalculixCantilever3D.FCStd
)

Expand Down
Binary file added data/examples/FemCalculixCantilever2D.FCStd
Binary file not shown.
Binary file modified data/examples/FemCalculixCantilever3D.FCStd
Binary file not shown.
3 changes: 2 additions & 1 deletion src/Mod/Start/CMakeLists.txt
Expand Up @@ -17,7 +17,8 @@ if(BUILD_GUI)
LoadMRU1.py
LoadMRU2.py
LoadArchExample.py
LoadFemExample.py
LoadFemExample2D.py
LoadFemExample3D.py
Mesh.py
PartDesign.py
Background.jpg
Expand Down
26 changes: 26 additions & 0 deletions src/Mod/Start/StartPage/LoadFemExample2D.py
@@ -0,0 +1,26 @@
#***************************************************************************
#* *
#* Copyright (c) 2016 *
#* Bernd Hahnebach <bernd@bimstatik.org> *
#* *
#* This program is free software; you can redistribute it and/or modify *
#* it under the terms of the GNU Lesser General Public License (LGPL) *
#* as published by the Free Software Foundation; either version 2 of *
#* the License, or (at your option) any later version. *
#* for detail see the LICENCE text file. *
#* *
#* 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 Library General Public License for more details. *
#* *
#* You should have received a copy of the GNU Library General Public *
#* License along with this program; if not, write to the Free Software *
#* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 *
#* USA *
#* *
#***************************************************************************

import FreeCAD,FreeCADGui
FreeCAD.open(FreeCAD.getResourceDir()+"examples/FemCalculixCantilever2D.FCStd")
FreeCADGui.activeDocument().sendMsgToViews("ViewFit")
File renamed without changes.
6 changes: 4 additions & 2 deletions src/Mod/Start/StartPage/StartPage.py
Expand Up @@ -106,10 +106,11 @@ def translate(context,text):
text57 = translate("StartPage","http://www.freecadweb.org/wiki/index.php?title=Power_users_hub")
text58 = translate("StartPage","Your version of FreeCAD is up to date.")
text59 = translate("StartPage","There is a new release of FreeCAD available.")
text60 = translate("StartPage","Load an FEM example analysis")
text60 = translate("StartPage","Load an FEM 3D example analysis")
text61 = translate("StartPage","Obtain a development version")
text62 = translate("StartPage","<b>Development versions</b> are made available by community members from time to time and usually contain the latest changes, but are more likely to contain bugs.")
text63 = translate("StartPage","See all commits")
text64 = translate("StartPage","Load an FEM 2D example analysis")

# get FreeCAD version

Expand Down Expand Up @@ -434,7 +435,8 @@ def getExamples():
<li><img src="FreeCAD.png" style="width: 16px">&nbsp;<a href="LoadDrawingExample.py">""" + text12 + """</a></li>
<li><img src="FreeCAD.png" style="width: 16px">&nbsp;<a href="LoadRobotExample.py">""" + text13 + """</a></li>
<li><img src="FreeCAD.png" style="width: 16px">&nbsp;<a href="LoadArchExample.py">""" + text55 + """</a></li>
<li><img src="FreeCAD.png" style="width: 16px">&nbsp;<a href="LoadFemExample.py">""" + text60 + """</a></li>
<li><img src="FreeCAD.png" style="width: 16px">&nbsp;<a href="LoadFemExample2D.py">""" + text64 + """</a></li>
<li><img src="FreeCAD.png" style="width: 16px">&nbsp;<a href="LoadFemExample3D.py">""" + text60 + """</a></li>
</ul>"""

def getLinks():
Expand Down

0 comments on commit 108fe75

Please sign in to comment.