|
[Sponsors] |
[General] get Bounds from different Mesh Regions |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
April 3, 2017, 12:47 |
get Bounds from different Mesh Regions
|
#1 |
New Member
Jonathan Geyer
Join Date: Feb 2017
Posts: 1
Rep Power: 0 |
Dear all,
I would like to write a script in python. Therefore I need some Bounds of different Meshregions. I'm able to get the bounds from the internal mesh, but not from other mesh regions. I think the problem is, that I have to change the active Soure. But how is this possible? The code I tried is here: Code:
#### import the simple module from the paraview from paraview.simple import * #### disable automatic camera reset on 'Show' paraview.simple._DisableFirstRenderCameraReset() # get active source. resultsfoam = GetActiveSource() resultsfoam.MeshRegions = [] # Properties modified on resultsfoam resultsfoam.MeshRegions = ['BLADES'] (x1min,x1max,y1min,y1max,z1min,z1max) = GetActiveSource().GetDataInformation().GetBounds() print (z1max) resultsfoam = GetActiveSource() # Properties modified on resultsfoam resultsfoam.MeshRegions = [] # Properties modified on resultsfoam resultsfoam.MeshRegions = ['INFLOW'] resultsfoam = GetActiveSource() (xmin,xmax,ymin,ymax,zmin,zmax) = GetActiveSource().GetDataInformation().GetBounds() print (zmax) Jonathan |
|
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
pimpleDyMfoam , AMI -- The mesh has multiple regions not connected by any face | coolcrasher | OpenFOAM Running, Solving & CFD | 3 | May 16, 2019 05:58 |
[snappyHexMesh] Creating multiple multiple cell zones with snappyHexMesh - a newbie in deep water! | divergence | OpenFOAM Meshing & Mesh Conversion | 0 | January 23, 2019 04:17 |
[Gmsh] 2D Mesh Generation Tutorial for GMSH | aeroslacker | OpenFOAM Meshing & Mesh Conversion | 12 | January 19, 2012 03:52 |
[snappyHexMesh] external flow with snappyHexMesh | chelvistero | OpenFOAM Meshing & Mesh Conversion | 11 | January 15, 2010 19:43 |
fluent add additional zones for the mesh file | SSL | FLUENT | 2 | January 26, 2008 11:55 |