CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

dieselFoam problem!! trying to introduce a new heat transfer model

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 29, 2010, 09:05
Default dieselFoam problem!! trying to introduce a new heat transfer model
  #1
Member
 
Vivek Gupta
Join Date: May 2010
Posts: 36
Rep Power: 16
vivek070176 is on a distinguished road
Hey

I am trying to introduce a new heat transfer model in dieselFoam tutorial located in $WM_PROJECT_USER_DIR/src/lagrangian/mydieselSpray/spraySubModels/heatTransferModel/
And in this newheatmodel , there is only one change with respect to RanzMarshall model that I want to calculate the nusselt number by using the formula

Nu = Nuo log (1+Bm)/Bm
where Bm is mass transport number calculated by Bm=(Xs-Xf)/(1-Xs)
and Nu0 is nusselt number as calculated in RanzMarshall.

So, now for this I have to introduce Xs and Xf in newheatmodel.C and newheatmodel.H. I have made the following changes to newheatmodel.C
scalar dieseheatmodel::relaxationTime
(
const scalar liquidDensity,
const scalar diameter,
const scalar liquidcL,
const scalar kappa,
const scalar ReynoldsNumber,
const scalar PrandtlNumber,
const scalar Xs,
const scalar Xf,
const scalar m0[i]
) const
{
scalar lgExpr = 0.0;
scalar Xratio = (Xs - Xf)/max(SMALL, 1.0 - Xs);

if (Xratio > 0.0)
{
lgExpr = log(1.0 + Xratio)/Xratio;
}

scalar time = liquidDensity*pow(diameter, 2.0)*liquidcL/(6.0*kappa*lgExpr*Nu(ReynoldsNumber, PrandtlNumber));

time = max(SMALL, time);

return time;

And the changes to newheatmodel.H are:-
scalar relaxationTime
(
const scalar liquidDensity,
const scalar diameter,
const scalar liquidcL,
const scalar kappa,
const scalar ReynoldsNumber,
const scalar PrandtlNumber,
const scalar Xs,
const scalar Xf,
const scalar m0[i]
)
Also I have made certain changes in heatTransferModel.H located in $WM_PROJECT_USER_DIR/src/lagrangian/mydieselSpray/spraySubModels/heatTransferModel/heatTransferModel/
Virtual scalar relaxationTime
(
const scalar liquidDensity,
const scalar diameter,
const scalar liquidcL,
const scalar kappa,
const scalar ReynoldsNumber,
const scalar PrandtlNumber,
const scalar Xs,
const scalar Xf,
const scalar m0[i]
) const = 0;
And certain changes in setRelaxationTimes.C located in $WM_PROJECT_USER_DIR/src/lagrangian/mydieselSpray/parcel/
And the changes near line 164 are:-
for(label i=0; i<Nf; i++)
{


tauHeatTransfer = sDB.heatTransfer().relaxationTime
(
liquidDensity,
d(),
liquidcL,
kMixture,
Reynolds,
Prandtl,
Xs[i],
Xf[i],
m0[i]
);
}

When I compiled mydieselSpray library , it properly compiled but when I run my case, it showed an error:-
cfd@linux-bw7o:~/OpenFOAM/cfd-1.6/run/decane_heatmodels/decane_6_diese> mpirun -
np 4 mydieselFoam -parallel > log &
[1] 20041
cfd@linux-bw7o:~/OpenFOAM/cfd-1.6/run/decane_heatmodels/decane_6_diese> [2] #0
Foam::error:rintStack(Foam::Ostream&) in "/home/cfd/OpenFOAM/OpenFOAM-1.6/lib/
linux64GccDPOpt/libOpenFOAM.so"
[2] #1 Foam::sigFpe::sigFpeHandler(int) in "/home/cfd/OpenFOAM/OpenFOAM-1.6/lib /linux64GccDPOpt/libOpenFOAM.so"
[2] #2 ?? in "/lib64/libc.so.6"
[2] #3 Foam::dieseheatmodel::relaxationTime(double, double, double, double, dou ble, double, double, double) const in "/home/cfd/OpenFOAM/cfd-1.6/lib/linux64Gcc DPOpt/libmydieselSpray.so"
[2] #4 Uninterpreted:
[linux-bw7o:20047] *** Process received signal ***
[linux-bw7o:20047] Signal: Floating point exception (8)
[linux-bw7o:20047] Signal code: (-6)
[linux-bw7o:20047] Failing at address: 0x3e800004e4f
[linux-bw7o:20047] [ 0] /lib64/libc.so.6 [0x2ba3a6f77bd0]
[linux-bw7o:20047] [ 1] /lib64/libc.so.6(gsignal+0x35) [0x2ba3a6f77b45]
[linux-bw7o:20047] [ 2] /lib64/libc.so.6 [0x2ba3a6f77bd0]
[linux-bw7o:20047] [ 3] /home/cfd/OpenFOAM/cfd-1.6/lib/linux64GccDPOpt/libmydies elSpray.so(_ZNK4Foam14dieseheatmodel14relaxationTi meEdddddddd+0x11b) [0x2ba3a5d3 26ab]
[linux-bw7o:20047] [ 4] [0x7fff07519410]
[linux-bw7o:20047] *** End of error message ***
--------------------------------------------------------------------------
mpirun noticed that process rank 2 with PID 20047 on node linux-bw7o exited on s ignal 8 (Floating point exception).
--------------------------------------------------------------------------
cfd@linux-bw7o:~/OpenFOAM/cfd-1.6/run/decane_heatmodels/decane_6_diese>
[1]+ Exit 136

PLEASE SOMEBODY HELP ME.

Regards
Vivek Gupta
vivek070176 is offline   Reply With Quote

Old   June 29, 2010, 09:39
Default
  #2
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
It looks like you didnt recompile dieselFoam
niklas is offline   Reply With Quote

Old   June 29, 2010, 11:16
Default
  #3
Member
 
Vivek Gupta
Join Date: May 2010
Posts: 36
Rep Power: 16
vivek070176 is on a distinguished road
Quote:
Originally Posted by niklas View Post
It looks like you didnt recompile dieselFoam
I HAVE PROPERLY RECOMPILED MY DieselFoam and done that again but it still doesnot work. The following is the recompilation of DieselFoam::::




cfd@linux-bw7o:~/OpenFOAM/cfd-1.6/applications/solvers/combustion/mydieselFoam> wmake
Making dependency list for source file dieselFoam.C
SOURCE=dieselFoam.C ; g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -We xtra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoReposito ry -ftemplate-depth-40 -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/../applications/sol vers/combustion/dieselEngineFoam -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/finiteVol ume/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/turbulenceModels/compressibl e/turbulenceModel -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/lagrangian/basic/lnInclu de -I/home/cfd/OpenFOAM/cfd-1.6/src/lagrangian/mydieselSpray/lnInclude -I/home/c fd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/liquids/lnInclude -I/home/cfd/ OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/liquidMixture/lnInclude -I/home/c fd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/specie/lnInclude -I/home/cfd/O penFOAM/OpenFOAM-1.6/src/thermophysicalModels/thermophysicalFunctions/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/reactionThermo/lnIncl ude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/basic/lnInclude - I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/laminarFlameSpeed/lnIn clude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/../applications/solvers/reactionTher mo/XiFoam -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/chemistryMo del/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/ODE/lnInclude -IlnInclude -I . -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/cfd/OpenFOAM/ OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude -fPIC -c $SOURCE -o Make/linux64Gc cDPOpt/dieselFoam.o
g++ -m64 -Dlinux64 -DWM_DP -Wall -Wno-strict-aliasing -Wextra -Wno-unused-parameter -Wold-style-cast -Wnon-virtual-dtor -O3 -DNoRepository -ftemplate-depth-40 -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/../applications/solvers/combustion/dieselEngineFoam -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/finiteVolume/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/turbulenceModels/compressible/turbulenceModel -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/lagrangian/basic/lnInclude -I/home/cfd/OpenFOAM/cfd-1.6/src/lagrangian/mydieselSpray/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/liquids/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/liquidMixture/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/specie/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/thermophysicalFunctions/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/reactionThermo/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/basic/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/laminarFlameSpeed/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/../applications/solvers/reactionThermo/XiFoam -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/thermophysicalModels/chemistryModel/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/ODE/lnInclude -IlnInclude -I. -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/OpenFOAM/lnInclude -I/home/cfd/OpenFOAM/OpenFOAM-1.6/src/OSspecific/POSIX/lnInclude -fPIC Make/linux64GccDPOpt/dieselFoam.o -L/home/cfd/OpenFOAM/OpenFOAM-1.6/lib/linux64GccDPOpt \
-lcompressibleRASModels -lcompressibleLESModels -lreactionThermophysicalModels -llagrangian -ldieselSpray -lliquids -lliquidMixture -lthermophysicalFunctions -lspecie -lbasicThermophysicalModels -llaminarFlameSpeedModels -lchemistryModel -lODE -lpdf -L/home/cfd/OpenFOAM/cfd-1.6/lib/linux64GccDPOpt -lmydieselSpray -lOpenFOAM -liberty -ldl -lm -o /home/cfd/OpenFOAM/cfd-1.6/applications/bin/linux64GccDPOpt/mydieselFoam




I THINK IT LOOKS FINE.....WHAT YoU THINK?....


Regards
Vivek Gupta
vivek070176 is offline   Reply With Quote

Old   June 29, 2010, 11:53
Default
  #4
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
I THINK YOU SHOULD STOP USING CAPS!!!

... and then remove the dependency of -ldieselSpray for
dieselFoam in the Make/options-file.

It looks like you are picking up the original dieselSpray library.
niklas is offline   Reply With Quote

Old   June 29, 2010, 12:02
Default
  #5
Member
 
Vivek Gupta
Join Date: May 2010
Posts: 36
Rep Power: 16
vivek070176 is on a distinguished road
Respected niklas

Sorry for caps and yes i have tried after removing the dependency on dieselspray library and it still shoed the same error..Can you please help again??..

Vivek
vivek070176 is offline   Reply With Quote

Old   June 29, 2010, 12:05
Default
  #6
Member
 
Vivek Gupta
Join Date: May 2010
Posts: 36
Rep Power: 16
vivek070176 is on a distinguished road
And when i try my case using RanzMarshall heat transfer model, it is working fine. But when i use newheatmodel, only then it shows the above error.

Regards
Vivek
vivek070176 is offline   Reply With Quote

Old   June 29, 2010, 14:20
Default
  #7
Super Moderator
 
niklas's Avatar
 
Niklas Nordin
Join Date: Mar 2009
Location: Stockholm, Sweden
Posts: 693
Rep Power: 29
niklas will become famous soon enoughniklas will become famous soon enough
Quote:
Originally Posted by vivek070176 View Post
Sorry for caps
Thank you,

Can you pack your dieselSpray-library and mail it to me at
niklas dot nordin at nequam at se

I cant figure out what the problem is from these posts.

N
niklas is offline   Reply With Quote

Old   August 4, 2010, 16:29
Default
  #8
Senior Member
 
n/a
Join Date: Sep 2009
Posts: 199
Rep Power: 17
deji is on a distinguished road
hey there niklas. i have been working on a post-processor to compute the mean nusselt number in a turbulent free convection flow over a vertical hot plate. i am gradually working my way through programming in OpenFOAM, and i am quite unable to find the cause of the bug that i am getting. it is a fairly short code, do you think you can look over the code for me? thanks

deji
deji is offline   Reply With Quote

Old   August 23, 2014, 07:45
Default
  #9
Member
 
Ron
Join Date: Jul 2014
Location: Japan
Posts: 40
Rep Power: 12
ron_OFuser is on a distinguished road
Quote:
Originally Posted by vivek070176 View Post
Hey

I am trying to introduce a new heat transfer model in dieselFoam tutorial located in $WM_PROJECT_USER_DIR/src/lagrangian/mydieselSpray/spraySubModels/heatTransferModel/
And in this newheatmodel , there is only one change with respect to RanzMarshall model that I want to calculate the nusselt number by using the formula

Nu = Nuo log (1+Bm)/Bm
where Bm is mass transport number calculated by Bm=(Xs-Xf)/(1-Xs)
and Nu0 is nusselt number as calculated in RanzMarshall.

So, now for this I have to introduce Xs and Xf in newheatmodel.C and newheatmodel.H. I have made the following changes to newheatmodel.C
scalar dieseheatmodel::relaxationTime
(
const scalar liquidDensity,
const scalar diameter,
const scalar liquidcL,
const scalar kappa,
const scalar ReynoldsNumber,
const scalar PrandtlNumber,
const scalar Xs,
const scalar Xf,
const scalar m0[i]
) const
{
scalar lgExpr = 0.0;
scalar Xratio = (Xs - Xf)/max(SMALL, 1.0 - Xs);

if (Xratio > 0.0)
{
lgExpr = log(1.0 + Xratio)/Xratio;
}

scalar time = liquidDensity*pow(diameter, 2.0)*liquidcL/(6.0*kappa*lgExpr*Nu(ReynoldsNumber, PrandtlNumber));

time = max(SMALL, time);

return time;

And the changes to newheatmodel.H are:-
scalar relaxationTime
(
const scalar liquidDensity,
const scalar diameter,
const scalar liquidcL,
const scalar kappa,
const scalar ReynoldsNumber,
const scalar PrandtlNumber,
const scalar Xs,
const scalar Xf,
const scalar m0[i]
)
Also I have made certain changes in heatTransferModel.H located in $WM_PROJECT_USER_DIR/src/lagrangian/mydieselSpray/spraySubModels/heatTransferModel/heatTransferModel/
Virtual scalar relaxationTime
(
const scalar liquidDensity,
const scalar diameter,
const scalar liquidcL,
const scalar kappa,
const scalar ReynoldsNumber,
const scalar PrandtlNumber,
const scalar Xs,
const scalar Xf,
const scalar m0[i]
) const = 0;
And certain changes in setRelaxationTimes.C located in $WM_PROJECT_USER_DIR/src/lagrangian/mydieselSpray/parcel/
And the changes near line 164 are:-
for(label i=0; i<Nf; i++)
{


tauHeatTransfer = sDB.heatTransfer().relaxationTime
(
liquidDensity,
d(),
liquidcL,
kMixture,
Reynolds,
Prandtl,
Xs[i],
Xf[i],
m0[i]
);
}

When I compiled mydieselSpray library , it properly compiled but when I run my case, it showed an error:-
cfd@linux-bw7o:~/OpenFOAM/cfd-1.6/run/decane_heatmodels/decane_6_diese> mpirun -
np 4 mydieselFoam -parallel > log &
[1] 20041
cfd@linux-bw7o:~/OpenFOAM/cfd-1.6/run/decane_heatmodels/decane_6_diese> [2] #0
Foam::error:rintStack(Foam::Ostream&) in "/home/cfd/OpenFOAM/OpenFOAM-1.6/lib/
linux64GccDPOpt/libOpenFOAM.so"
[2] #1 Foam::sigFpe::sigFpeHandler(int) in "/home/cfd/OpenFOAM/OpenFOAM-1.6/lib /linux64GccDPOpt/libOpenFOAM.so"
[2] #2 ?? in "/lib64/libc.so.6"
[2] #3 Foam::dieseheatmodel::relaxationTime(double, double, double, double, dou ble, double, double, double) const in "/home/cfd/OpenFOAM/cfd-1.6/lib/linux64Gcc DPOpt/libmydieselSpray.so"
[2] #4 Uninterpreted:
[linux-bw7o:20047] *** Process received signal ***
[linux-bw7o:20047] Signal: Floating point exception (8)
[linux-bw7o:20047] Signal code: (-6)
[linux-bw7o:20047] Failing at address: 0x3e800004e4f
[linux-bw7o:20047] [ 0] /lib64/libc.so.6 [0x2ba3a6f77bd0]
[linux-bw7o:20047] [ 1] /lib64/libc.so.6(gsignal+0x35) [0x2ba3a6f77b45]
[linux-bw7o:20047] [ 2] /lib64/libc.so.6 [0x2ba3a6f77bd0]
[linux-bw7o:20047] [ 3] /home/cfd/OpenFOAM/cfd-1.6/lib/linux64GccDPOpt/libmydies elSpray.so(_ZNK4Foam14dieseheatmodel14relaxationTi meEdddddddd+0x11b) [0x2ba3a5d3 26ab]
[linux-bw7o:20047] [ 4] [0x7fff07519410]
[linux-bw7o:20047] *** End of error message ***
--------------------------------------------------------------------------
mpirun noticed that process rank 2 with PID 20047 on node linux-bw7o exited on s ignal 8 (Floating point exception).
--------------------------------------------------------------------------
cfd@linux-bw7o:~/OpenFOAM/cfd-1.6/run/decane_heatmodels/decane_6_diese>
[1]+ Exit 136

PLEASE SOMEBODY HELP ME.

Regards
Vivek Gupta
Hi Vivek,

I am interested in the work which you have reported in your post.
Do you have any reference for the same?

Thanks a million!!!
ron_OFuser is offline   Reply With Quote

Old   August 26, 2014, 04:14
Default
  #10
Member
 
Ron
Join Date: Jul 2014
Location: Japan
Posts: 40
Rep Power: 12
ron_OFuser is on a distinguished road
Any help will be a highly appreciated!!!

Looking forward to any further comment on my previous posting.

Thanks
ron_OFuser is offline   Reply With Quote

Old   December 24, 2014, 00:48
Default
  #11
Member
 
Ron
Join Date: Jul 2014
Location: Japan
Posts: 40
Rep Power: 12
ron_OFuser is on a distinguished road
Any comments on this?
ron_OFuser is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Overflow Error in Multiphase Modelling with Two Continuous Fluids ashtonJ CFX 6 August 11, 2014 15:32
Heat transfer from a heated plate using fins pathakamit FLUENT 1 April 30, 2013 05:07
Heat transfer problem in ansys please help me please...!!!!!!! rm2052 CFX 1 March 14, 2010 18:51
facing problem in heat transfer coefficient dhiraj CFX 1 May 7, 2007 10:08
regarding B.C. of Heat transfer problem Manoj Padmakarrao Raut Siemens 0 March 17, 2005 01:01


All times are GMT -4. The time now is 10:51.