Selecting all merged surfaces [solved]

Topics related to boundary conditions.

Selecting all merged surfaces [solved]

Postby kyrsjo » Fri Mar 10, 2017 11:38 am

Hello,

I have a quite complicated model which I split into a large number of sub-volumes in order to mesh (the mesher seems to be a lot more happy when I give it a bunch of volumes that are topologically simple). I now need to make sidesets for the boundary conditions.

In the past I've always done this using a pattern similar to (usually split over many journals):
Code: Select all
(geometry...)

(meshing...)

sideset 1 surface 123 # Inlet
sideset 2 surface 321 # Outlet
...
sideset 10 surface 4210 4211 4212 4213 4214 ... # Group of internal, merged surfaces

sideset 6 surface all except surface in sideset 1,2,10 # General external surface
delete sideset 10

(blocks and genesis output)


However in this case, the sideset 10 group will be quite large, and I would prefer to not have to select it by hand (error-prone and painful to update if I change something higher up in the script which shifts the IDs).

Is there a way to do this automatically? Something like this pseudocode:
Code: Select all
sideset 10 surface all except merged

or ideally:
Code: Select all
sideset 10 surface all except merged and except surface in sideset 1,2


Best regards,
Kyrre Sjobak
Last edited by kyrsjo on Mon Mar 13, 2017 3:39 am, edited 1 time in total.
kyrsjo
 
Posts: 2
Joined: Fri Mar 10, 2017 11:24 am

Re: Selecting all merged surfaces

Postby csimsoft Moderator » Fri Mar 10, 2017 12:48 pm

One way of doing this is in two steps:

sideset 10 surface all except with is_merged
sideset 10 remove surface in sideset 1 2

Another way of doing it is to put merged surfaces and surfaces in sidesets 1 and 2 into a group and then creating sideset 10 with surface all except in that group.
csimsoft
csimsoft Moderator
 
Posts: 239
Joined: Tue Feb 14, 2012 5:59 pm
Location: American Fork, UT

Re: Selecting all merged surfaces

Postby kyrsjo » Mon Mar 13, 2017 3:39 am

Thank you! That way of automatically creating a sideset for the external / free surfaces worked perfectly!
kyrsjo
 
Posts: 2
Joined: Fri Mar 10, 2017 11:24 am


Return to Boundary Conditions

Who is online

Users browsing this forum: No registered users and 1 guest

cron

Search / Mark

User Control Panel

Login

Who is online

In total there is 1 user online :: 0 registered, 0 hidden and 1 guest (based on users active over the past 5 minutes)
Most users ever online was 58 on Mon Jun 26, 2017 4:19 pm

Users browsing this forum: No registered users and 1 guest