CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   CFX (http://www.cfd-online.com/Forums/cfx/)
-   -   Realizing algorithm in CFX (http://www.cfd-online.com/Forums/cfx/24746-realizing-algorithm-cfx.html)

 Bloshchitsyn Vladimir October 29, 2007 04:06

Realizing algorithm in CFX

Hello! I want realize algorithm for computing source term ( x, y, z) in CYLINDER region (subdomain):

1) Calculate inegral for specified Z section ( to determine ~ E electric field by current ) ... Intergal will be dounle summ of Temperature ( Function of temperature ) by x and y

2) Calculate source term using resuls of step 1)

AFAIK, for this procedure I should use functions like described there http://www.cfd-online.com/Forum/cfx_...cgi?read=21401

<QUOTE>---------------------- 1 - USER_CALC_INFO to determine the LOCALE and ENTITY for step 3

2 - USER_GETVAR to get the "vector variable"

3 - USER_GET_MESHDATA to get the Normal Area Vector. Here you must use WHAT='Normal Area Vector", WHERE=Faces|Integration Points depending if ENTITY=CENTRE|IP

4 - USER_GET_MESHDATA to get the Volume Sector using WHAT='Volume', and WHERE='Sectors'

Then, pass the stack pointers into a local routine that will compute something like (be careful with indexing and array shapes).

DO I = 1, N

VAR(I) = (VECTOR(1,I)*AREA(1,I) +VECTOR(2,I)*AREA(2,I) +VECTOR(3,I)*AREA(3,I)) / VOLSEC(I) ENDDO

<QUOTE>-----------------------------------------------

Can you present, this algorithm more detailed?

 All times are GMT -4. The time now is 21:30.