set up of volume fraction of the thrid phase in VOF

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

 April 27, 2012, 17:22 set up of volume fraction of the thrid phase in VOF #1 Member   Fer Villa Join Date: Apr 2012 Posts: 35 Rep Power: 7 Sponsored Links Hi, I need help. I have three phase: water (first phase, ID=2), air (second phase, ID=3) and CO2 (second phase, ID=4). I can not set up of the volume fraction initial of CO2. The air phase I set up through a UDF, but for the CO2 phase I try with a UDF and Adapt Region, but not work. //UDF volume fraction initial of air #include "udf.h" #define Xc 0.0 #define Yc 0.09 #define r 0.0085 #define ls 0.06 DEFINE_INIT(vol_fraction_bala,mixture_domain) { int phase_domain_index; cell_t c; Thread *ct; Domain *sd; real X[ND_ND]; sub_domain_loop(sd,mixture_domain,phase_domain_ind ex) { if (DOMAIN_ID(sd) == 3) thread_loop_c(ct,sd) { begin_c_loop_all(c,ct) { C_CENTROID(X,c,ct); if (X[1]>=ls && X[1]<=Yc && X[0]>=-r && X[0]<=r) C_VOF(c,ct)=1.; else if (X[1]>Yc && sqrt(ND_SUM(pow(X[0]-Xc,2),pow(X[1]-Yc,2)))=0.001 && X[1]=-r && X[0]<=r) C_VOF(c,ct)=0.25; else C_VOF(c,ct)=0.; } end_c_loop_all(c,ct) } } }

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post Virtual-iCFD OpenFOAM Running, Solving & CFD 8 June 12, 2015 18:15 anand_30 OpenFOAM Meshing & Mesh Conversion 12 December 12, 2011 05:16 F S CFX 1 April 11, 2011 21:08 paean OpenFOAM Running, Solving & CFD 0 November 14, 2008 22:14 Rasmus Gjesing (Gjesing) OpenFOAM Native Meshers: blockMesh 10 April 2, 2007 14:00