CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > CFX

USRSRC User scalar

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 18, 2004, 04:29
Default USRSRC User scalar
  #1
Andrea
Guest
 
Posts: n/a
I need set a source in a mass fraction equation.

In command file I set

MASS FRACTION1 'HYD'

In usrsrc routine which string I should set like getvar argument?

Thanks

Andrea Musso
  Reply With Quote

Old   May 23, 2004, 00:31
Default Re: USRSRC User scalar
  #2
Jeff
Guest
 
Posts: n/a
Trying hard to recall CFX-4 stuff.....

You need to find the equation index and then check to see if USRSRC is being called for the equation you want. Since HYD is a scalar and is embedded in the SCAL array, you need to get the SCAL index and add the mass fraction index to it (-1).

IPHASE = 1 ! first phase only

CALL GETSCA('HYD',IHYD,CWORK)

CALL GETVAR('USRSRC','SCAL ',ISCAL)

IVAR = ISCAL + IHYD - 1

IF (IEQN.EQ.IVAR) THEN

DO INODE = 1,NNODE ! loop over nodes

SU(INODE,IPHASE) = ............

SP(INODE,IPHASE) = ............

ENDDO

ENDIF

Hope this helps. You really need to switch to CFX-5. It's much easier than this, and fewer and fewer people remember this CFX-4 stuff.

Jeff
  Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
dieselFoam problem!! trying to introduce a new heat transfer model vivek070176 OpenFOAM Programming & Development 10 December 23, 2014 23:48
solving passive scalar by user function in AVLFIRE huyp Main CFD Forum 0 September 4, 2008 10:21
The source of user scalar equation rambol CFX 3 November 14, 2002 07:37
add user scalar in one phase zhu CFX 0 April 27, 2002 03:45
Using user scalar in USRRAT Jakub CFX 0 April 25, 2002 13:18


All times are GMT -4. The time now is 19:14.