CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > Siemens > STAR-CCM+

Volume averaged-field

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 3, 2016, 11:29
Default Volume averaged-field
  #1
Senior Member
 
acalado's Avatar
 
André
Join Date: Mar 2016
Posts: 133
Rep Power: 10
acalado is on a distinguished road
Hey guys,

suppose I want to create a new field function for velocity or pressure where the local value is a volume average of a sphere around that point.

What is the easiest way to define such a thing?

Thanks in advance!!
__________________
Sapere aude!
acalado is offline   Reply With Quote

Old   October 3, 2016, 12:27
Default
  #2
Member
 
Join Date: Nov 2015
Posts: 38
Rep Power: 11
Schwob77 is on a distinguished road
Hi,
I would create a local spherical coordinate system in the point you want to observe. For that coordinate system you can create a cell set of the type "threshold". Use the r-coordinate as field function and specify a radius that you wnt to use.
Along with that cell set you get a field function e.g. "Cell Set 1" that has a value of 1 for the cells inside the sphere.
Now you create two field functions:

FF1: $FF*$Volume*$CellSetVar1
FF2: $Volume*$CellSetVar1

"$FF" is the Field Function that you want to average inside the sphere, e.g $Pressure or $$Velocity.mag().

Create two sum reports for FF1 and FF2.
Now you create a third Field Function or a expression report that devides the sum report of FF1 by the sum report of FF2. The result should be your searched value.
Schwob77 is offline   Reply With Quote

Old   October 3, 2016, 12:38
Default
  #3
Senior Member
 
acalado's Avatar
 
André
Join Date: Mar 2016
Posts: 133
Rep Power: 10
acalado is on a distinguished road
Quote:
Originally Posted by Schwob77 View Post
Hi,
I would create a local spherical coordinate system in the point you want to observe. For that coordinate system you can create a cell set of the type "threshold". Use the r-coordinate as field function and specify a radius that you wnt to use.
Along with that cell set you get a field function e.g. "Cell Set 1" that has a value of 1 for the cells inside the sphere.
Now you create two field functions:

FF1: $FF*$Volume*$CellSetVar1
FF2: $Volume*$CellSetVar1

"$FF" is the Field Function that you want to average inside the sphere, e.g $Pressure or $$Velocity.mag().

Create two sum reports for FF1 and FF2.
Now you create a third Field Function or a expression report that devides the sum report of FF1 by the sum report of FF2. The result should be your searched value.
Yes, but that would be the average of that point.

I want to do the average for my whole domain.
__________________
Sapere aude!
acalado is offline   Reply With Quote

Old   October 3, 2016, 16:51
Default
  #4
Member
 
Join Date: Nov 2015
Posts: 38
Rep Power: 11
Schwob77 is on a distinguished road
Ok, I haven't understood that you want to get that value in every cell of the domain.
Sorry, but I'm not aware of any easy method outside of user coding to do that.
Schwob77 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
[Other] dynamicTopoFVMesh and pointDisplacement RandomUser OpenFOAM Meshing & Mesh Conversion 6 April 26, 2018 08:30
How to use "translation" in solidBodyMotionFunction in OpenFOAM rupesh_w OpenFOAM Running, Solving & CFD 5 August 16, 2016 05:27
multiphase turbulance case floating error harsha_kulkarni OpenFOAM Running, Solving & CFD 3 February 18, 2016 06:06
Volume averaged continuity and momentum eqns forE-L flow jiejie OpenFOAM Running, Solving & CFD 0 April 10, 2013 06:12
Problem with rhoSimpleFoam matteo_gautero OpenFOAM Running, Solving & CFD 0 February 28, 2008 07:51


All times are GMT -4. The time now is 12:43.