# C_VOLUME

 User Name Remember Me Password
 Register Blogs Members List Search Today's Posts Mark Forums Read

 LinkBack Thread Tools Display Modes
 May 9, 2006, 08:25 C_VOLUME #1 AdN Guest   Posts: n/a Hello I'm trying to get the volume of each cell in my geometry. I am in 2D axisymetrique. I kno that C_VOLUME(cell, thread) give us the volume of each cell, but when I sum all my cell volume I don't have the right volume of my geometry. My geometry is a simple tube: r=0.05m and L=0.15m So the volume will be V=pi*r*r*L=1.17*10^-3 But when I use C_VOLUME I find V=1,87*10^-4!!! I don't understand why??? Could anyone help me please? Thanks

 May 9, 2006, 08:32 Re: C_VOLUME #2 AdN Guest   Posts: n/a I try to use C_VOLUME_2D but it give me the volume as if I wasn't in 2D axisymetric but only in 2D So it give me V=L*r*1=0.0075

 May 9, 2006, 08:38 Re: C_VOLUME #3 Gernot Guest   Posts: n/a One possibility is that you donīt have set the right scale-factor. You can check it there : grid / scale

 May 9, 2006, 08:50 Re: C_VOLUME #4 AdN Guest   Posts: n/a Thank you. But I verify and I set the good scale. C_VOLUME work well when I'm in 2D, so my function seems to be correct. But in axisymetric it does'nt work.

 May 15, 2006, 10:43 Re: C_VOLUME #5 RoM Guest   Posts: n/a C_VOLUME returns cell_volume/(2*PI) for axisymmetric. RoM

 May 15, 2006, 10:47 Re: C_VOLUME #6 AdN Guest   Posts: n/a thank you... It's work

 January 21, 2013, 01:45 #7 Senior Member   Join Date: Nov 2009 Posts: 125 Rep Power: 7 Dear Gernot, where can i check for grid/scale please? __________________ Thank you for your kind attention. Kind regards, mactech001 Currently using: ANSYS v13

January 21, 2013, 02:10
problem in cell volume value for source term
#8
Senior Member

Join Date: Nov 2009
Posts: 125
Rep Power: 7
Dear all,

i may have a problem in using C_VOLUME to calculate the source in my UDF application.

i've the following UDF code that attempts to apply a temperature-dependent source term to a solid cell.

#include "udf.h"
#include "mem.h"

DEFINE_SOURCE(cell_x_source,cell,thread,dS,eqn)
{
real source;
int Ro=12e-3; /*12mOhm at 20C*/
int To=20; /*temperature 20C*/
int Iphase=20; /*Arms*/

source=Iphase*Iphase*Ro*((C_T(cell,thread)-273)/To)/C_VOLUME(cell,thread);
Message("C_T output: %g\n",C_T(cell,thread));
Message("source output: %g\n",source);
Message("C_VOLUME output: %g\n",C_VOLUME(cell,thread));

return source;
}

While running 100 iterations, i observe in the Message output that the C_VOLUME of the solid cell is changing rather than keeping at a constant value as expected. why is this happening please?

The final outcome of the run was:
Error: Divergence detected in AMG solver: temperature
Error Object: #f

Then, i go into the solid cell's 'Parameter' menu (as shown attached), and verified that the volume it calculates in the output parameter is correct: 2.57e-5 [m3]. How can i use this output parameter in UDF please?

Hope to receive any comments/ideas you may have.
__________________
Thank you for your kind attention.

Kind regards,
mactech001
Currently using: ANSYS v13
Attached Images
 cellvolumeopparam.jpg (94.3 KB, 5 views)
__________________
Thank you for your kind attention.

Kind regards,
mactech001
Currently using: ANSYS v13

 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

All times are GMT -4. The time now is 04:45.

 Contact Us - CFD Online - Top