Procedure to identify fluid/solid zone corresponding to an interior surface.
It is unclear when you read the grid which fluid zone corresponds to which interior zone. While the interior zones can be selected individually in the Grid Display panel, the fluid zones cannot. There is a TUI command for this for a 2D case. In 3D however there is no such command. A Scheme file is written which will tell which fluid(or solid) zone corresponds to a particular interio surface. In this way we can get a list of fluid (solid) zones corresponding to an interior surface. The scheme is attached below: ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; ; ; This scheme file gives info about a fluid/solid zone ; ; associated with a particular default-interior. It ; ; works for both 2D and 3D cases. ; ; ; ; To use this scheme file type (getinfo zone-id-var) ; ; where zone-id-var is the zone-id of the interior ; ; zone under consideration. ; ; ; ; Written By: Padmesh Mandloi (pxm@fluent.co.in) ; ; Date: 18/11/2004 ; ; ; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (define Getinfo (lambda (def-int-zone-id) (begin ; (pp def-int-zone-id) (define grab-list) (set! grab-list (inquire-adjacent-threads def-int-zone-id)) ; (pp grab-list) (define first) (define second) (set! first (list-ref grab-list 0)) (set! second (list-ref grab-list 1)) ; (pp first) ; (pp second) (if (eqv? first second) (begin (define fluid-zone-name) (set! fluid-zone-name (thread-name (get-thread first))) (pp fluid-zone-name) ) (pp "No Fluid or Solid zone is associated with this surface") ) ) ) ) A scheme file is written here that returns the fluid (solid) zone name which corresponds to a particular interior surface. The scheme file and its usage is described below : ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; ; ; This scheme file gives info about a fluid/solid zone ; ; associated with a particular default-interior. It ; ; works for both 2D and 3D cases. ; ; ; ; To use this scheme file type (getinfo zone-id-var) ; ; where zone-id-var is the zone-id of the interior ; ; zone under consideration. ; ; ; ; Written By: Padmesh Mandloi (pxm@fluent.co.in) ; ; Date: 18/11/2004 ; ; ; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (define Getinfo (lambda (def-int-zone-id) (begin ; (pp def-int-zone-id) (define grab-list) (set! grab-list (inquire-adjacent-threads def-int-zone-id)) ; (pp grab-list) (define first) (define second) (set! first (list-ref grab-list 0)) (set! second (list-ref grab-list 1)) ; (pp first) ; (pp second) (if (eqv? first second) (begin (define fluid-zone-name) (set! fluid-zone-name (thread-name (get-thread first))) (pp fluid-zone-name) ) (pp "No Fluid or Solid zone is associated with this surface") ) ) ) ) |
||
![]()
|