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

How to compile a new drag force in Lagrangian model

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

Reply
 
LinkBack Thread Tools Display Modes
Old   May 31, 2016, 08:05
Question How to compile a new drag force in Lagrangian model
  #1
New Member
 
Li Linmin
Join Date: Nov 2015
Location: China
Posts: 22
Rep Power: 2
lilinmin is on a distinguished road
Dear Foamers,
I am now working with the gas-particle simulation. I have added a new drag model in the Drag file as the same way as other drag forces. But a don't know how to compile it. Can anyone help me ?
Thank you very much in advance.
Linmin
lilinmin is offline   Reply With Quote

Old   May 31, 2016, 08:56
Default
  #2
New Member
 
Lennart
Join Date: Feb 2016
Posts: 19
Rep Power: 2
elmo555 is on a distinguished road
Hey,

can you be a bit more specific? Which solver are you using, and how did you add the new drag model?
elmo555 is offline   Reply With Quote

Old   May 31, 2016, 09:40
Default
  #3
New Member
 
Li Linmin
Join Date: Nov 2015
Location: China
Posts: 22
Rep Power: 2
lilinmin is on a distinguished road
Quote:
Originally Posted by elmo555 View Post
Hey,

can you be a bit more specific? Which solver are you using, and how did you add the new drag model?
Thank you very much for reply and I am sorry for that. I copied a file of the existed drag model in the file "src/lagrangian/intermediate/submodels/Kinematic/ParticleForces/Drag" and changed the code. Can it been compiled?
lilinmin is offline   Reply With Quote

Old   May 31, 2016, 10:07
Default
  #4
New Member
 
Lennart
Join Date: Feb 2016
Posts: 19
Rep Power: 2
elmo555 is on a distinguished road
Well, you need to re-compile the solver you're using, and you shouldn't modify the original OF solver. There are many tutorials out there explaining how to create a new solver based on an exisiting one, e.g. here.

Basically: copy the original code to your working folder, adjust the name and EXE path, and add your drag model (using #include) where all the other drag models are included. Then compile the solver and you should be able to use your drag model.
elmo555 is offline   Reply With Quote

Old   June 9, 2016, 04:15
Default
  #5
New Member
 
Andreas Weber
Join Date: Jun 2014
Posts: 24
Rep Power: 4
a.weber is on a distinguished road
BTW: The force model list is found in intermediate/parcels/include/MakeParcelForces.C
This is where you have to add it.

regards
Andreas
a.weber is offline   Reply With Quote

Reply

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
FLUENT: how to record drag force at every time step? qiulan FLUENT 3 December 19, 2014 04:43
Compute drag force on a mesh (complete beginner!) matteo.monti Main CFD Forum 0 October 10, 2014 20:07
ActuatorDiskExplicitForce in OF2.1. Help be_inspired OpenFOAM Programming & Development 8 July 3, 2014 10:54
Stability problem due to turbulent dispersion force in a subcooled boiling model Edy OpenFOAM 7 August 10, 2011 12:00
Please help a newbie find the drag on a 3d model David Amer Main CFD Forum 1 March 6, 2002 04:33


All times are GMT -4. The time now is 08:37.