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

time dependent velocity input by user subroutine

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   December 17, 2007, 16:16
Default time dependent velocity input by user subroutine
  #1
shohel mahmud
Guest
 
Posts: n/a
Hi Everybody I am struggling with a simple transient model. I have a 2-D rectangular channel with one inlet, one outlet, and two walls. At the inlet, V and W velocity are zero. Only U velocity is time dependent. For example, U=U0*sin(2*pi*f*time) where, U0, f, and time are velocity amplitude, frequency, and time or iteration number. How can I set this boundary condition in starcd user subroutine? The existing subrutine only accept spatial variation not temporal.

any help will be greatly appreciated

shohel

university of waterloo
  Reply With Quote

Old   December 17, 2007, 16:56
Default Re: time dependent velocity input by user subrouti
  #2
Pauli
Guest
 
Posts: n/a
The user subroutine bcdefi.f supports time dependant velocity boundary conditions.

Another option is to use a table.

  Reply With Quote

Old   December 17, 2007, 19:56
Default Re: time dependent velocity input by user subrouti
  #3
shohel mahmud
Guest
 
Posts: n/a
Thanks Pauli I don't know how to implement time in the bcdefi.f suroutine. Specially, no idea about variable time or time step. Below I copied a portion of the bcdefi.f subroutine and show an example of time variation of U. lots of question mark, I don't know what to put to consider the time or time step or iteration. Do I need to "include" any new inc file or add new EQUIVALENCE. Your help will be greatly appreciated.

IF(IREG.EQ.2) THEN

TURINT=.FALSE.

U=2.3*sin(2*22/7*??????)

V=0.0

W=0.0

TE=0.0

ED=0.0

T=0

V22=0.0

F22=0.0

SCALAR(1)=0.0

DEN=0

ENDIF

RETURN

END C

  Reply With Quote

Old   December 18, 2007, 07:50
Default Re: time dependent velocity input by user subrouti
  #4
James
Guest
 
Posts: n/a
If you look in nom.inc the variable time should be available (it comes through a common block not the call list)
  Reply With Quote

Old   December 18, 2007, 11:40
Default Re: time dependent velocity input by user subrouti
  #5
Pauli
Guest
 
Posts: n/a
The bcdefi.f template should include the line:

INCLUDE 'usrdat.inc'

This gives you access to a parameter "TIME". So for your example:

U=2.3*sin(2*22/7*TIME)

When you tell Star to write the usubs, it should put usrdat.inc into the ufile subdirectory.

On my system I have to create the ufile subdirectory manually. Otherwise when I try to write the usubs, Star reports the directory doesn't exist.
  Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
time dependent inlet subroutine. HELP!!! jimmer Siemens 4 November 10, 2008 08:49
Time Dependent Temperature Dependent BC Analysis RP Main CFD Forum 1 March 28, 2008 01:22
user subroutine BCDEFW for velocity Abe Siemens 2 December 12, 2003 09:29
CFX5.5 User Subroutine defining velocity B.C. David CFX 7 March 4, 2003 19:02
Modification in a Time Dependent Velocity Guillermo Solano Phoenics 4 April 8, 2002 03:34


All times are GMT -4. The time now is 00:32.