I am writing an API for automatic refinement of planar elements. The idea is to create a group with elements to be refined. By adding also boundary nodes to the group the API refines all elements inside the group and makes a transition for the elements attached to boundary nodes (see picture). This would all work nicely if there was a way to use the MESH->EDITING->INTERACTIVE command in the API. However I am unable to find this method. Is it not included in the API environment or am I looking in the wrong place? If the feature is missing, might there be an other way of doing the transition. (I would like to avoid sharp triangles by all means)
Thanks in advance!
All of the mesh editing commands are available. Look at the API help chapter 3.9.3.
You would use these two methods:
hope this helps
Did not find the actual API method for the MESH->EDITING->INTERACTIVE button but the feMeshRemesh workes fine in my case when sufficiently low aspect ratio is required.
Most annoyingly however the 188.8.131.52 feMeshRemesh command asks the user for the refinment ratio with a pop-up box for each line element. This seems to be a bug!
The API and test-model are attached.
The procedure goes as follows:
1. Choose the elements that should be refined, e.g. a square of 9 plate elements and 12 beam elements.
2. Select the nodes at the boundary of the square.
3. The API now refines the center elements by a factor of 3, leaving the boundary nodes unchanged.
4. The problem occurs when the API ask for the refinement ratio seperately for each beam element: The procedure is not possible to scale up.
PS. Though of lumping beam elements into a Set object and performing feMeshRemesh on this set. Then the box would pop up only once. However then beams must all be of the same property...
Give a try to this attached code and keep me in touch. I mentionned that you used the method for each element and that is why you was asked for renfinement ratio at each loop iteration. I defined a set for bar and plate elements and moved the feMeshRemesh method outside the loop.
Thanks for the help SN, however this workarond has two limitations.
1. Does not work with several different element properties.
2. Does not work when the mesh to be refined is in more than one plane.
Therefore, I limited the script to plate elements only and reported the bug of the pop-up box to Siemens.