### Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

### Messages - piso

Pages: 
1
##### Fluent / Where do I enter radiation properties such as emissivity/absorptivity etc?
« on: April 25, 2012, 10:36:21 AM »
Where do I enter radiation properties such as emissivity/absorptivity etc.? Are there any recommended values for certain surfaces? How can I find them?

Thank you.

2
##### Fluent / Re: How to calculate volume of particles in each cell using Fluent UDF?
« on: April 25, 2012, 10:04:15 AM »
Thank you.

3
##### Fluent / How to calculate volume of particles in each cell using Fluent UDF?
« on: April 25, 2012, 09:59:26 AM »
I want to calculate the volume occupied by particles in each cell. I know it can be done using UDF, but I can not figure out how to do it. Can any one guide me?

Thanks.

4
##### Fluent / Re: How to create a UDF for mass weighted average function on a surface?
« on: February 06, 2012, 07:10:52 PM »
The following UDF allows you to compute mass weighted average of temperature based on any surface. You just have to provide surface ID.

#include "udf.h"
#include "surf.h"
#include "cxsurf.h"
#include "cxiface.h"

#define SID 9 /*Surface ID to be modified*/

void
facet_area_3D( Surface *s, int i, double area[] )
{
double v[MAX_FACE_NODES];
int k, m;
area=area=area=0.0;

for (k=0; k < s->facets; k++)
{
v[k]=Get_Surface_Point_Coord(&( s->points[s->facets[i+k+1]]),X_DIM);
v[k]=Get_Surface_Point_Coord(&( s->points[s->facets[i+k+1]]),Y_DIM);
v[k]=Get_Surface_Point_Coord(&(s->points[s->facets[i+k+1]]),Z_DIM);
}

for (k=0; k < s->facets; k++)
{
m = (k+1)%(s->facets);
area+= 0.5*((v[m] + v[k]) * (v[m] - v[k]));
area+= 0.5*((v[m] + v[k]) * (v[m] - v[k]));
area+= 0.5*((v[m] + v[k]) * (v[m] - v[k]));
}
}

DEFINE_ON_DEMAND(integrals)
{
Surface *s;
cell_t c ;
real mass_integral=0;
real total_mass=0;
double area[ND_ND],vel[ND_ND];
real avg_surf_temp;
int i,k;

/* s is the surface having data of surface id SID
s->np no of points.
s->nf no of faces.
s->points points to array of np points.
s->ip pointer to interpolation vector of np points.
s->facets facet list of the surface. length of array is nfl.
s->cells pointer to cells of each facet.
s->nfl facet list length.
*/
s = SurfaceList+SID;

for (i=0, k=0; k<s->nf; i+=s->facets+1, k++)
if (s->facets >= 3)
{
facet_area_3D(s, i, area);

/* Cell in which the facet lies */
c = RP_CELL(s->cells+k);

NV_D(vel,=,C_U(c,t),C_V(c,t),C_W(c,t)) ;

mass_integral += C_R(c,t)*C_T(c,t)*fabs(NV_DOT(area,vel));
total_mass += C_R(c,t)*fabs( NV_DOT(area,vel));
}

avg_surf_temp=mass_integral/total_mass;
Message("Mass weighted average of Temperature at Surface ID=%d is %f",SID,avg_surf_temp);
}
#include "udf.h"
#include "surf.h"
#include "cxsurf.h"
#include "cxiface.h"

#define SID 9 /*Surface ID to be modified*/

void
facet_area_3D( Surface *s, int i, double area[] )
{
double v[MAX_FACE_NODES];
int k, m;
area=area=area=0.0;

for (k=0; k < s->facets; k++)
{
v[k]=Get_Surface_Point_Coord(&( s->points[s->facets[i+k+1]]),X_DIM);
v[k]=Get_Surface_Point_Coord(&( s->points[s->facets[i+k+1]]),Y_DIM);
v[k]=Get_Surface_Point_Coord(&(s->points[s->facets[i+k+1]]),Z_DIM);
}

for (k=0; k < s->facets; k++)
{
m = (k+1)%(s->facets);
area+= 0.5*((v[m] + v[k]) * (v[m] - v[k]));
area+= 0.5*((v[m] + v[k]) * (v[m] - v[k]));
area+= 0.5*((v[m] + v[k]) * (v[m] - v[k]));
}
}

DEFINE_ON_DEMAND(integrals)
{
Surface *s;
cell_t c ;
real mass_integral=0;
real total_mass=0;
double area[ND_ND],vel[ND_ND];
real avg_surf_temp;
int i,k;

/* s is the surface having data of surface id SID
s->np no of points.
s->nf no of faces.
s->points points to array of np points.
s->ip pointer to interpolation vector of np points.
s->facets facet list of the surface. length of array is nfl.
s->cells pointer to cells of each facet.
s->nfl facet list length.
*/
s = SurfaceList+SID;

for (i=0, k=0; k<s->nf; i+=s->facets+1, k++)
if (s->facets >= 3)
{
facet_area_3D(s, i, area);

/* Cell in which the facet lies */
c = RP_CELL(s->cells+k);

NV_D(vel,=,C_U(c,t),C_V(c,t),C_W(c,t)) ;

mass_integral += C_R(c,t)*C_T(c,t)*fabs(NV_DOT(area,vel));
total_mass += C_R(c,t)*fabs( NV_DOT(area,vel));
}

avg_surf_temp=mass_integral/total_mass;
Message("Mass weighted average of Temperature at Surface ID=%d is %f",SID,avg_surf_temp);
}

5
##### Fluent / Problem of over-predicting tangential velocity near the wall in swirling flow
« on: February 04, 2012, 06:54:51 PM »
Hi,

I am getting a very high tangential velocity profile magnitude in Fluent. The flow is highly swirling flow. I can not understand why this is happening. I am using RSM with second order upwind scheme for turbulence.

I would appreciate any help in this matter.

Thank you in advance.

6
##### Fluent / How do I create animation of particle tracks in steady simulation in Fluent
« on: February 04, 2012, 06:08:38 PM »
Hi,

For a steady state flow simulation, how do I create an animation of particle tracks?
In FLUENT I can display the particle tracks in pulse mode. However, FLUENT doesn't have an inbuilt function to save the animation of particle tracks which you see in pulse mode. Is there any way I can create an animation of the particle tracks?

Thank you.

7
##### Fluent / Re: Coordinates of discrete phase in lagrangian approach using UDF
« on: February 02, 2012, 04:46:14 PM »
You can use:

Code: [Select]
`Tracked_Particle *p;int x,y,z;x=p->state.pos;    // x component of the particle positiony=p->state.pos;   //y component of the particle positionz=p->state.pos;   //z component of the particle position`

p is the pointer to the tracked particle.

8
##### Fluent / Re: How do I calculate concentration of water in a cell?
« on: February 02, 2012, 04:31:00 PM »
You can get concentration in the cell using the following code:

C_YI(c,t,0)*C_R(c,t)

C_YI(c,t,0) will give you mass fraction of the component. C_R(c,t) will give you density of the phases in the cell. Hence multiplication of the two gives you the concentration of the component (whose ID is 0) in the cell.

where:
c is the cell identifier
t is the thread identifier
0 is the ID of the component. If it is first in your Materials > mixture-template > Mixture Species > names Edit list then its ID is 0. If it is second in the list then its ID is 1.

9
##### Fluent / Re: Need a UDF for averaged properties at the outlet
« on: January 25, 2012, 09:30:33 AM »
You will need to use:

DEFINE_ON_DEMAND macro.

You will also need DEFINE_DPM_BC to get the average of properties. Hook this macro to the boundary condition where you want the averaged properties.

At the end of simulation run, execute DEFINE_ON_DEMAND macro using execute_on_demand to display the averaged properties on the window.

I hope this helps.

10
##### Meshing / Help in meshing using GAMBIT!
« on: January 23, 2012, 08:53:49 PM »
Hi all,

I am trying to make a mesh file of the geometry shown in the attachment. When I export the mesh file and open it in Fluent, it makes a wall at the face shown in the attachment. How can I make it hollow so that fluid can pass through it

Thank you.

11
##### Fluent / UDF at wick/vapor interface
« on: January 21, 2012, 12:16:48 PM »
Hello,

I am trying to solve a heat transfer problem at the surface of a wick. In that, I wanted to apply the boundary condition at the wick/vapour interface (considered as spherical boundary) as given in the attachment. Can anybody help me in this?

Thank you.

12
##### Fluent / Solution here to UDF compiling Error - nmake
« on: January 20, 2012, 09:35:38 AM »
Hi,
I just want to share my experience in compiling UDF on windows platform. Many users find it very difficult to compile UDF on Fluent. The first error they get is that:

''nmake' is not recognized as an internal or external command, operable program or batch file. 'nmake' is not recognized as an internal or external command, operable program or batch file.'

I am sharing a PDF that shows how to compile UDF.

Another issue most users get is:
"Error: open_udf_library: The operation completed successfully."

This error happens when you are compiling a .c udf file which is not in the same directory where you have the case and data files of Fluent. It may also occur when you have a - or space in the filename of the UDF or the Fluent case and data file or you have a space or - in the directory where you have these files. So make sure that filenames and directory names do not contain spaces and dashes.

13
##### Matlab / How do I export MATLAB results to MS excel
« on: January 17, 2012, 08:03:50 PM »
How do I export the results of MATLAB to excel? I have time, temperature and velocity values in three columns. I want to export the values to Excel. Can anyone help me in this?

Thanks.

Pages: