CFD Online URL
[Sponsors]
Home > Forums > CFX

flux source at particular location(boundary)

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

Reply
 
LinkBack Thread Tools Display Modes
Old   June 1, 2011, 10:16
Unhappy flux source at particular location(boundary)
  #1
New Member
 
Churamani Prasad
Join Date: May 2011
Posts: 16
Rep Power: 5
cprasad111 is on a distinguished road
Hi.
I need to find the derivative of a variale (reactant.molconc) at particular location(x=0.002) which i m able to do it and then specify two sources, NEGATIVE SOURCE at left of the location and POSITIVE SOURCE at the right of the location, where source is some simple function of the gradient of the reactant.molconc .
The geometry is simple reactangle with a boundary at x=0.002
I thougt of a way but don't know(90% sure that it won't work) if it will work
the part of the code i written is :
DO ILOC = 1, NLOC
IF (X(ILOC).GE.0.002 .AND. X(ILOC).LE.0.002 .AND.
& Y(ILOC).GE.0.00 .AND. Y(ILOC).LE.0.001) THEN
SOURCE(ILOC-1) = -(1e-9)*GRAD_PHI(1,ILOC)
SOURCE(ILOC+1) = (1e-9)*GRAD_PHI(1,ILOC)
END IF
END DO
but i m not sure if ILOC-1 will be just left of the location and ILOC+1 at the right of the boundary. The problem is how the vertices are assigned to NLOC..
Plz help on this...Suggest some other and better ways to do the same.
cprasad111 is offline   Reply With Quote

Old   June 1, 2011, 12:59
Default
  #2
New Member
 
A.R. Baserinia
Join Date: Jan 2010
Location: Canada
Posts: 24
Rep Power: 6
baserinia is on a distinguished road
Quote:
Originally Posted by cprasad111 View Post
Hi.
but i m not sure if ILOC-1 will be just left of the location and ILOC+1 at the right of the boundary. The problem is how the vertices are assigned to NLOC..
No, it's not going to work. ILOC has nothing to do with the physical location of a vertex. More importantly, you cannot define a point or line source in the finite volume method. You should add your source like the "User Defined Momentum Source" example in the documentation.
baserinia is offline   Reply With Quote

Old   June 1, 2011, 19:27
Default
  #3
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 9,880
Rep Power: 78
ghorrocks has a spectacular aura aboutghorrocks has a spectacular aura aboutghorrocks has a spectacular aura about
Why can't you use the built in CEL gradient functions?
ghorrocks is offline   Reply With Quote

Old   June 2, 2011, 02:58
Default
  #4
New Member
 
Churamani Prasad
Join Date: May 2011
Posts: 16
Rep Power: 5
cprasad111 is on a distinguished road
@ Baserinia

Yes, I have read the "momentum source" from the documentation. But the unit of momentum source is kg m^-2 s^-2 and the unit i need is kg m^-2 s^-1. So, it is giving some error.

Also there is only option of momentum source, no option of mass flux source which i need.
cprasad111 is offline   Reply With Quote

Old   June 2, 2011, 03:21
Default
  #5
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 9,880
Rep Power: 78
ghorrocks has a spectacular aura aboutghorrocks has a spectacular aura aboutghorrocks has a spectacular aura about
Use a mass source then. And your comment about the momentum source shows your momentum source units are wrong.

.... And why not use the built in CEL gradient functions?
ghorrocks is offline   Reply With Quote

Old   June 2, 2011, 04:22
Default
  #6
New Member
 
Churamani Prasad
Join Date: May 2011
Posts: 16
Rep Power: 5
cprasad111 is on a distinguished road
But even the mass source unit is kg m^3 s^-1, i need mass flux source kg m^2 s^-1

We are also trying other things and going through the built in CEL function too. Thanks
cprasad111 is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
swak4foam building problem GGerber OpenFOAM 45 July 30, 2013 16:08
pisoFoam compiling error with OF 1.7.1 on MAC OSX Greg Givogue OpenFOAM Programming & Development 3 March 4, 2011 18:18
OpenFOAM on MinGW crosscompiler hosted on Linux allenzhao OpenFOAM Installation 127 January 30, 2009 20:08
DxFoam reader update hjasak OpenFOAM Post-Processing 69 April 24, 2008 02:24
DecomposePar links against liblamso0 with OpenMPI jens_klostermann OpenFOAM Bugs 11 June 28, 2007 18:51


All times are GMT -4. The time now is 16:13.