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

Plot for 2d diffusion problem

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 29, 2016, 14:37
Default Plot for 2d diffusion problem
  #1
New Member
 
shikhabhuyan
Join Date: Jul 2016
Posts: 2
Rep Power: 0
shikha5 is on a distinguished road
Hi, I have written code for 2d diffusion problem and want to get its isotherm contour and temperature at mid y plane.

/*----------------------output---------------------------*/
fprintf(b,"I=%d\tJ=%d \n",nx+1,ny+1);
for(j=0;j<=ny;j++)
{
for(i=0;i<=nx;i++)
{
fprintf(b,"%f\t%f\t%f\n",x[i],y[j],th[i][j]);
}
}
for(i=0;i<=nx;i++)
{
fprintf(c,"\n%f\t%f",x[i],th[i][ny/2]);
}

Is it a right way to write this part of code to get the output, because I am not getting desired results. Any suggestions plz.
shikha5 is offline   Reply With Quote

Reply


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
pressure plot for a transient problem Arjun Jayakumar FLUENT 3 September 29, 2014 08:22
[General] problem with pvpython when loading state involving Plot Over Lines hadrien51 ParaView 1 October 17, 2012 11:18
Discretization problem of diffusion equation ztdep Main CFD Forum 0 September 9, 2009 10:24
convection diffusion problem ali2108 OpenFOAM 1 May 30, 2009 22:17
FVM for diffusion problem or dispersive problems? Wen Main CFD Forum 0 February 22, 2006 13:34


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