CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   CFX (https://www.cfd-online.com/Forums/cfx/)
-   -   User_getvar question (https://www.cfd-online.com/Forums/cfx/20050-user_getvar-question.html)

Jesper December 12, 2003 05:08

User_getvar question
 
I am using user_getvar to obtain velocity gradients for a FORTRAN subroutine.

As far as I have understood, I can only request whole vector and tensor entities from user_getvar, and not components of these. My question is: How do I get the correct gradients out of the tensor?

I can request the gradient tensor successfully, and store it in a stack_point without troubles. But I am not sure I am using the correct notation for getting the components of the gradient tensor. I am currently getting the components with calls like this:

GRAD_W(2,ILOC,1)

Where Grad_W is the requested gradient tensor from user_getvar. Now I suppose that the first number in the brackets express the gradient (i.e. 1 is d/dx, 2 is d/dy, 3 is d/dz), ILOC is refering to the node number (I am doing computations in the whole domain), and that the last number corresponds to the component (i.e. 1 is u, 2 is v, 3 is w). If I follow this notation, the above expression would give me du/dy. Can anybody who have worked with this tell me if this is correct?

Thanks in advance, Jesper.


All times are GMT -4. The time now is 17:15.