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

New Force model and C++ syntax

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   January 22, 2014, 18:49
Default New Force model and C++ syntax
  #1
Member
 
India
Join Date: Oct 2012
Posts: 84
Rep Power: 13
mayank.dce2k7 is on a distinguished road
Hi Foamers,

I need some help with C++ syntax. I have a force model which I am trying to implement in OF-2.1.1 and subsequently refine it. My force model is a function of particle x-coordinate and particle y-coordinate.

I am trying to obtain a vector as below:

const vector& r= (p.position.x() p.position.y() 0);

but I guess p.position.x() or p.position.y() is not a valid syntax.

Please can anybody tell me the right syntax or how to access particle xyz coordinate at particle force model level?

Thanks,
Mayank
mayank.dce2k7 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
Is it possible to model natural convection in a 2D horizontal model in fluent caitoc FLUENT 1 May 5, 2014 13:32
About the dimension of Saffman-Mei particle lift force model haakon OpenFOAM Programming & Development 1 April 22, 2013 12:27
Cooling- Heat transfer model Markat FLUENT 9 February 9, 2013 00:22
Problems bout CFD model of biomass gasification, Downdraft gasifier wanglong FLUENT 2 November 25, 2009 23:27
Surface tension - Continuum Surface Force model Robert Main CFD Forum 0 May 2, 2002 07:34


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