CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Pre-Processing

Using .stl - Surface for Average Pressure / Mass Flux / ...

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 3, 2016, 10:52
Default Using .stl - Surface for Average Pressure / Mass Flux / ...
  #1
Member
 
Join Date: Apr 2016
Posts: 91
Rep Power: 10
CellZone is on a distinguished road
Dear Reader,

I made a pipe with blockMesh where I want to implement some .stl - surfaces , where I can analyze for example the average pressure , mass flux, mean temperature etc. during my calculations (not in post-processing).

I tried to use the tutorial snappyMultiRegionHeater as help:

First I created a .stl -surface in Ansa. Then I created a dictionary in the constant dictionary called triSurface, where I have put my .stl file

Questions

1) Overall: Do I have to use snappyhexmesh or is it possible to do it without snappy . That means: Do I have to mesh my .stl surface file or is it enough just to create a directory with the .stl file?

2) Since it is only used for analyzing: do I have to create a dictionary in the constant directory with files for turbulenceproperties, RasProperties, ... for the .stl surface? Actually I would not know what kind of entries I should add in those files, because it's just for analyzing data.

3) I am trying to implement the analyzing of the surface in the ControlDict using swak4Foam :

Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.4.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "system";
object controlDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
//"libtabulatedHeatTransferMassFlow.so"
libs (
//"libtabulatedHeatTransferMassFlow.so"
"libfieldFunctionObjects.so"
"libsimpleSwakFunctionObjects.so"
"libswakFunctionObjects.so"
"libgroovyBC.so"
);
application rhoPorousSimpleFoam;
startFrom startTime;
startTime 0;
stopAt endTime;
endTime 500;
deltaT 1;
writeControl timeStep;
writeInterval 100;
purgeWrite 0;
writeFormat binary;
writePrecision 6;
writeCompression off;
timeFormat general;
timePrecision 6;
graphFormat raw;
runTimeModifiable true;
 
// ************************************************************************* //
functions
(
PressureBefore
{
type swakExpression;
outputControlMode timeStep;
outputInterval 1;
valueType surface;
surfaceName ControlSurfaceHWTEinlass;
surface {
type sampledTriSurfaceMesh;
surface ControlSurfaceHWTEinlass.stl;
source cells; // What to sample: cells (nearest cell)

interpolate false;
}
expression "p";
accumulations (average);
verbose true;
} 
);
Could this work like this?

Thank you in advance
CellZone is offline   Reply With Quote

Old   May 4, 2016, 02:14
Default
  #2
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 30
akidess will become famous soon enough
Quote:
Originally Posted by CellZone View Post
Could this work like this?
Begs the question that if you worked it out so far, why didn't you just try it?

It is possible to use the STL sampling surface without changes to your mesh (it wouldn't be as useful IMO otherwise). Think of it as giving OF a list of points to probe. You don't need any dictionaries or such for the STL file apart from the sampling command. I haven't used triSurfaceSampling with swak, but your code looks reasonable.
__________________
*On twitter @akidTwit
*Spend as much time formulating your questions as you expect people to spend on their answer.
akidess is offline   Reply With Quote

Old   May 4, 2016, 03:25
Default
  #3
Member
 
Join Date: Apr 2016
Posts: 91
Rep Power: 10
CellZone is on a distinguished road
It's working :-) Thank you for your background information!
CellZone 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
Wind tunnel Boundary Conditions in Fluent metmet FLUENT 6 October 30, 2019 13:23
mass flow in is not equal to mass flow out saii CFX 12 March 19, 2018 06:21
static vs. total pressure auf dem feld FLUENT 17 February 26, 2016 14:04
mass flux averaged pressure Joern Beilke Siemens 3 November 28, 2003 22:05
CFX4.3 -build analysis form Chie Min CFX 5 July 13, 2001 00:19


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