Selecting internal faces of a pressure vessel

About the development of the FEM module/workbench.
Serchu
Posts: 87
Joined: Tue Feb 10, 2015 12:33 pm
Location: Tigre (Buenos Aires) - Argentina
Contact:

Selecting internal faces of a pressure vessel

Postby Serchu » Mon Sep 07, 2015 4:54 pm

Hi, I want to apply an internal pressure to a vessel, but I'm struggled trying to select the internal faces of the part (is a closed cilinder). I have tryied using the cliping plane, but when is active is not possible to follow with the boundary condition definition.

Any advice?

Regards.
fandaL
Posts: 218
Joined: Thu Jul 24, 2014 8:29 am

Re: Selecting internal faces of a pressure vessel

Postby fandaL » Mon Sep 07, 2015 6:59 pm

Make a backup of your file and try this:
1) create a mesh of your vessel
2) create a material
3) in the Draft module use Downgrade to get faces from volume (volume is lost and I think connection of mesh to it)
4) create constraints on this faces - fix and pressure
5) run analysis

This worked to me at sphere cut by smaller sphere, but when using a clipping plane, I don't see the inner elements of the mesh, only surfaces are visible.
sphere_in_sphere_cut.png
sphere_in_sphere_cut.png (83.89 KiB) Viewed 654 times
DeepSOIC
Posts: 4505
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Re: Selecting internal faces of a pressure vessel

Postby DeepSOIC » Mon Sep 07, 2015 7:15 pm

Hi!
Option 1 is to use Draft Section, which can cut the view in "real time".
Option 2 is to get inside by switching to perspective view and doing some navigation. But in FreeCAD, it is very uncomfortable to be inside objects, navigation styles are really not made for the purpose..
HoWil
Posts: 384
Joined: Sun Jun 14, 2015 7:31 pm
Location: Austria

Re: Selecting internal faces of a pressure vessel

Postby HoWil » Mon Dec 05, 2016 4:22 pm

DeepSOIC wrote:Hi!
Option 1 is to use Draft Section, which can cut the view in "real time".

Can you please explain a bit more where to find this real time cutted view.
Thanks in advance,
Howil
HoWil
Posts: 384
Joined: Sun Jun 14, 2015 7:31 pm
Location: Austria

Re: Selecting internal faces of a pressure vessel

Postby HoWil » Thu Jan 05, 2017 7:42 pm

Hi,
I wrote a script/FC-Macro which enables the selection of hidden or inner faces or edges.
Attached you find the script and a screencast introducing the interface on the standard part-design example-part after creating a inner cut.

Hints: To get best results on positioning your selection-click, set the element to 'Selectable=False' (see screencast).
This script does work all elements of the Part- and Part-Design-Next- workbenches except the 'Part'-element of PDN. The reason for this is until now unknown.

Hope it is helpful, and maybe it can be integrated into the selection dialog for FEM conditions and Mesh-regions.
BR,
HoWil

FC_element_selector_v1p0.py
First version of the (inner/hidden) element selector.
(5.56 KiB) Downloaded 12 times

sreenfc3.webm.zip
Screencast starting from the std. part-design-next example using a body and a subtractive sphere. Finally the inner face of the sub. sphere is selected for FEM.
(609.77 KiB) Downloaded 19 times

Screenshot from 2017-01-05 20-39-34_cut.png
Selection of the inner face for a fixed-boundary-condition in FEM-wb.
Screenshot from 2017-01-05 20-39-34_cut.png (202.12 KiB) Viewed 353 times
User avatar
bernd
Posts: 3876
Joined: Sun Sep 08, 2013 8:07 pm
Location: Zürich, Switzerland

Re: Selecting internal faces of a pressure vessel

Postby bernd » Fri Jan 06, 2017 5:55 am

It is a very useful tool. I had to remove the trailing white spaces to get it running in FreeCAD. Works great here. The face of a spere is added twice to the list I assume this because it is twice under the mouse. It would be cool if we would not need to change the select ability of the object around. Ah the window should stay on top over the FreeCAD main window even if the user clicks in FreeCAD main window.

We would need it on any constraint. I need to think how we could add it to the FEM WB.
HoWil
Posts: 384
Joined: Sun Jun 14, 2015 7:31 pm
Location: Austria

Re: Selecting internal faces of a pressure vessel

Postby HoWil » Fri Jan 06, 2017 7:48 am

Disabling of "selectable" is because otherwise the first face below the mouse is highlighted (in yellow) hiding everything below.
Maybe it can be done automatically (disabling for each element under mouse and store it in an list ; restore it afterwards).
bernd wrote: Ah the window should stay on top over the FreeCAD main window even if the user clicks in FreeCAD main window.

Have no clue about this yet. Any suggestions about this?
A switch to use it also for domains is also needed to fully use it in Fem-wb.
Br
Howil
makkemal
Posts: 320
Joined: Wed Apr 29, 2015 12:41 pm

Re: Selecting internal faces of a pressure vessel

Postby makkemal » Fri Jan 06, 2017 7:53 am

Very usefull tool !
It should be incorporated into master :D
HoWil
Posts: 384
Joined: Sun Jun 14, 2015 7:31 pm
Location: Austria

Re: Selecting internal faces of a pressure vessel

Postby HoWil » Mon Jan 09, 2017 9:14 pm

bernd wrote:I had to remove the trailing white spaces to get it running in FreeCAD.

Interesting... had nothing like that on my Ubuntu16.04.1 but will look into your 'Python coding standard' maybe I can identify the problem.

I want to post a updated version of the above discussed script.
Now it is no more necessary to disable 'selectable' for bodies and found bodies are also listed in the combobox.
A small flaw is that the first element (first found body) has to be selected again to have it highlighted.

FC_element_selector_v1p1p1.py
(6.95 KiB) Downloaded 7 times
mario52
Posts: 1845
Joined: Wed May 16, 2012 2:13 pm

Re: Selecting internal faces of a pressure vessel

Postby mario52 » Fri Mar 17, 2017 6:50 pm

hi
i add this line before self.dialog.show() and the window StaysOnTopHint

Code: Select all

        self.dialog.setWindowFlags(QtCore.Qt.WindowStaysOnTopHint)    #

        self.dialog.show()
        self.dialog.exec_()


mario
Windows 10
Maybe you need a special feature, go into Macros_recipes and Code_snippets. My macros on Gist.github