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

Action at a distance source term

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

Reply
 
LinkBack Thread Tools Display Modes
Old   July 19, 2012, 13:23
Default Action at a distance source term
  #1
New Member
 
Erica
Join Date: Jul 2012
Location: Mountain View, CA
Posts: 14
Rep Power: 5
Magneto is on a distinguished road
Hi! I am trying to write a DEFINE_SOURCE macro that calculates a source for one cell based on the current (or previous time step) value of variables in other cells (not just the cell's neighbors.) An example of this is a fluid with a charge distribution where the fluid in one cell is electrostatically forced by the charge in other cells.

The problem is I don't know how to access the data in other cells within the DEFINE_SOURCE function. I tried a begin_c_loop ... end_c_loop structure, initializing a different cell pointer and a different thread (also tried using the same thread) but that didn't work. Any ideas?

Thanks in advance for your help.
Magneto is offline   Reply With Quote

Reply

Tags
action at a distance, data access macro, source term

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
Problem of SOURCE term gradient in UDS wind Fluent UDF and Scheme Programming 5 June 21, 2013 05:39
GPU Linear Solvers for OpenFOAM gocarts OpenFOAM Announcements from Other Sources 35 March 1, 2012 21:41
UDF source term jerome_ FLUENT 2 July 11, 2011 11:55
How to write source term into scalar Fiel JimKnopf OpenFOAM Programming & Development 0 March 23, 2011 06:59
DxFoam reader update hjasak OpenFOAM Post-Processing 69 April 24, 2008 01:24


All times are GMT -4. The time now is 09:28.