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

Sampling surface: invariant option revisited

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 20, 2020, 16:37
Default Sampling surface: invariant option revisited
  #1
New Member
 
Arash
Join Date: May 2017
Posts: 17
Rep Power: 9
arashgmn is on a distinguished road
I'm trying to sample on the surface of a rotating body. The mesh doesn't change during the rotation (part of the mesh is rotating with the body).

I configured the samping postProcessing function in controlDict as follows:

Code:
Surf //folder name
{
	type            surfaces;	
    libs            (sampling);
    writeControl    writeTime;

    surfaceFormat   vtk;
    fields          (p U);

	surfaces 
	{
		surface_pU //file name
		{
			type 				patch;
			patches				("Airfoil");
			interpolate 		true;
			invariant       	true;  // Unaffected by mesh motion
	 		// Optional: whether to leave as faces (=default) or triangulate
			// triangulate false;
			fixedLocations 		false;
			format				ascii;
		}
	}
	    // Optional (inherited) entries
	region          region0;
    enabled         true;
    log             true;
    timeStart       0;
    timeEnd         $endTime;
    executeControl  writeTime;
    executeInterval 1;
    writeControl    timeStep;
    writeInterval   1;
}

and successfully ran it via
Code:
pimpleFoam -postProcess
. Now I have a bunch of files in the subdirectories of Surf folder as vtk. So far So good.

The problem, if there's any, is that despite the movement of the surface, the surface sample files, "seem" fixed in space. Nevertheless, surface values are reasonable. The picture below shows it more clearly:

My airfoil, starts pitching from a horizontal orientation (at time 0) counter clockwise. In paraview, however, the loaded vtk files are still horizontal, despite the fact that the are for time 0.06 in which the airfoil is inclined.



I switched the
Code:
invariant
option true and false. Yet didn't see any difference. So what does this option do really?
arashgmn is offline   Reply With Quote

Old   September 11, 2020, 12:07
Default
  #2
Senior Member
 
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,714
Rep Power: 40
olesen has a spectacular aura aboutolesen has a spectacular aura about
Quote:
Originally Posted by arashgmn View Post

I switched the
Code:
invariant
option true and false. Yet didn't see any difference. So what does this option do really?

Like the comment states
Code:
// Unaffected by mesh motion

This can be useful in some specialized cases. For example, you are sampling a slice in the wake of a vehicle, any you know that the rotating wheels and the fan simply do not affect which cells this slice samples. By specifying invariant, you are saying that you although OpenFOAM may have moved some points around the wheels, you know that this does not affect your sample region so you can save generating irrelevant output geometry for your sampled surface. Currently it is only the ensight writer that can properly benefit from this. VTK output always includes the geometry and doesn't care if it changed or not.


Summary: for your case leave invariant off. Your problem is elsewhere. Having said that, it looks like the sampling mechanism is not being properly expired on the mesh motion. Would suggest providing a small test case on https://develop.openfoam.com/Develop...nfoam/-/issues
olesen is offline   Reply With Quote

Reply

Tags
mesh rotation, sampling


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
Domain Reference Pressure and mass flow inlet boundary AdidaKK CFX 75 August 20, 2018 06:37
Problem with an old Simulation FrankW CFX 3 February 8, 2016 05:28
Waterwheel shaped turbine inside a pipe simulation problem mshahed91 CFX 3 January 10, 2015 12:19
Low Mixing time Problem Mavier CFX 5 April 29, 2013 01:00
RPM in Wind Turbine Pankaj CFX 9 November 23, 2009 05:05


All times are GMT -4. The time now is 10:51.