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

URGENT HELP NEEDED-SPECIES-PLEASE!!

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

Reply
 
LinkBack Thread Tools Display Modes
Old   February 28, 2008, 13:19
Default URGENT HELP NEEDED-SPECIES-PLEASE!!
  #1
Debamoy
Guest
 
Posts: n/a
Hi Let me define the problem first -

I have a 2D rectangular domain.One side I have Cathode, Opposite side I have Anode. Species Wall surface reaction at Cathode is X + e <> Y, and at Anode is Y <> X + e.

Using Fickcian law of diffusion, I know concentration gradient at Cathode/Anode by the formula - > Conc Grad = i_current/(n_noofelec*F_faradayconst*area_ofelectrode*diffus ioncoeff)

Hence knowing concentration gradient of the species at electrodes, and also I know the initial concentration of the species in the medium.

I WANT TO FIND THE CONCENTRATION DISTRIBUTION of the species IN THE WHOLE DOMAIN.

I tried to set it up in Fluent as follows, but I am getting the same concentration in the whole domain.

Procedure followed: [1] I have defined 1 scalar with 'flux function = none'. [2] compiled and loaded the DEFINE_PROFILE udf to calculate the conc gradient at electrode surfaces. [3] Turned on Species panel-wall surface reaction. [4] I have X and Y as 'selected site species', and the medium in the domain as 'selected species'. [5] I have set up 2 reactions in reactions panel - (with wall surface option)

X to Y (for cathode) and Y to X (for anode). [6] I have defined the properties of species X and Y and the medium. [7] In BC panel - a> for UDS tab , I have UDS BC = 'specified flux' and corresponding UDS BV = 'udf'(that I wrote) , for both the cathode and anode wall condition.

Questions-- [1] how do I give the initial conc of the species during Initialization , which will be a value like 'x mol/cubic meter'?? [2] PLEASE tell me all possible points where I am going wrong..

My udf is as follows -

#include"udf.h"

#define Faraday_const 96485 /* value is in coulomb/mole */ #define Diffusion_coeff 2.4e-9 /* diffusion coefficient or diffusivity is in sq.meters/second */

DEFINE_PROFILE(cathode_conc_gradient,t,i) {

face_t f;

real curr_i = 0.05; /* current is in Amperes */

real area_a = 0.0002; /* area of cathode is in sq. meters */

real num_n = 1; /* it is the number of electrons taking part in the reaction : O + ne <> R */

/**

Applying Fick's Law of Diffusion for the electrode reaction O + ne <> R

using the relation :

i/nFA = D[conc gradient @ electrode surface], where

i = current

F = Faraday Constant

A = cross-sectional area of the electrode

D = diffusion coefficient or diffusvity

here we are finding the concentration gradient @ the electrode*/

real value = curr_i/(num_n*Faraday_const*area_a*Diffusion_coeff);

begin_f_loop(f,t)

{

F_PROFILE(f,t,i) = value; /* used to set a boundary condition value in memory for a given face and thread */

}

end_f_loop(f,t) }

DEFINE_PROFILE(anode_conc_gradient,t,i) {

face_t f;

real curr_i = 0.05; /* current is in Amperes */

real area_a = 0.002; /* area of cathode is in sq. meters */

real num_n = 1; /* it is the number of electrons taking part in the reaction : R <> O + ne */

/**

Applying Fick's Law of Diffusion for the electrode reaction R <> O + ne

using the relation :

i/nFA = D[conc gradient @ electrode surface], where

i = current

F = Faraday Constant

A = cross-sectional area of the electrode

D = diffusion coefficient or diffusvity

here we are finding the concentration gradient @ the electrode*/

real value = curr_i/(num_n*Faraday_const*area_a*Diffusion_coeff);

begin_f_loop(f,t)

{

F_PROFILE(f,t,i) = value; /* used to set a boundary condition value in memory for a given face and thread */

}

end_f_loop(f,t) }

THIS SHOULD BE A SIMPLE CASE WHERE KNOWING INITIAL CONCENTRATION IN THE MEDIUM AND THE CONCENTRATION GRADIENT AT THE WALLS, I SHOULD BE ABLE TO FIND THE CONCENTRATION DISTRIBUTION IN THE WHOLE DOMAIN......unfortunately I am failing to do so.

PLEASE, PLEASE -- I NEED GUIDANCE AND HELP.
  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
urgent help needed (rhie-chow interpolation problem) Ardalan Main CFD Forum 2 March 18, 2011 16:22
species transport(need urgent help) sree FLUENT 1 December 18, 2006 03:11
species transport(need urgent help) sree CFX 0 December 14, 2006 02:16
species transport(need urgent help) sree Main CFD Forum 0 December 14, 2006 01:52
Species Transfer !!! Top Top Urgent!!! Mohammed Shamol FLUENT 2 April 27, 2004 03:20


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