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

cuttingPlane is creating unwanted surfaces

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 22, 2019, 14:15
Default cuttingPlane is creating unwanted surfaces
  #1
New Member
 
Join Date: Sep 2018
Posts: 20
Rep Power: 2
tecmul is on a distinguished road
Hello everyone, I'm simulating 2D flow in a channel with OpenFOAM 6 and am trying to interpolate some field variables onto a plane and integrate. I do this by including the following function object in my controlDict file.

Code:
cuttingplane
    {
        type            surfaceFieldValue;
        libs            ("libfieldFunctionObjects.so");

        log             true;
        writeControl    timeStep;
	writeInterval	1;
        writeFields     true;

        // Type of source: patch/faceZone/sampledSurface
        surfaceFormat   vtk;
        regionType      sampledSurface;
        name			mySurface;

        sampledSurfaceDict
        {
                type cuttingPlane;
                planeType           pointAndNormal;
                pointAndNormalDict
                {
                        basePoint       (0.01 0 0);  
                        normalVector    (1 0 0);
                }
                source cells; // sample cells or boundaryFaces
                interpolate true;
        }

        // Operation: areaAverage/sum/weightedAverage ...
        operation       areaIntegrate;

        fields
        (
            U
        );
    }
The channel is in the x direction and goes from x = 0 to 1. I want a slice of the channel at x = 0.01. This slice is generated correctly, but for some reason the surface generated by the function object includes tetrahedra at x = 0. I've attached images showing these surfaces. Moving the location of the slice towards increasing x results in smaller tetrahedra, until x = 0.5 where they disappear. Moving further to the right, the tetrahedra appear at x = 1 and increase in size as we move along the channel.
Why is this happening?

channel.jpg

channel2.jpg

cuttingPlane.jpg

cuttingPlane2.jpg

Last edited by tecmul; August 22, 2019 at 16:26.
tecmul is offline   Reply With Quote

Old   August 26, 2019, 12:29
Default
  #2
Senior Member
 
Ehsan Asgari
Join Date: Apr 2010
Posts: 420
Rep Power: 13
syavash is on a distinguished road
Quote:
Originally Posted by tecmul View Post
Hello everyone, I'm simulating 2D flow in a channel with OpenFOAM 6 and am trying to interpolate some field variables onto a plane and integrate. I do this by including the following function object in my controlDict file.

Code:
cuttingplane
    {
        type            surfaceFieldValue;
        libs            ("libfieldFunctionObjects.so");

        log             true;
        writeControl    timeStep;
	writeInterval	1;
        writeFields     true;

        // Type of source: patch/faceZone/sampledSurface
        surfaceFormat   vtk;
        regionType      sampledSurface;
        name			mySurface;

        sampledSurfaceDict
        {
                type cuttingPlane;
                planeType           pointAndNormal;
                pointAndNormalDict
                {
                        basePoint       (0.01 0 0);  
                        normalVector    (1 0 0);
                }
                source cells; // sample cells or boundaryFaces
                interpolate true;
        }

        // Operation: areaAverage/sum/weightedAverage ...
        operation       areaIntegrate;

        fields
        (
            U
        );
    }
The channel is in the x direction and goes from x = 0 to 1. I want a slice of the channel at x = 0.01. This slice is generated correctly, but for some reason the surface generated by the function object includes tetrahedra at x = 0. I've attached images showing these surfaces. Moving the location of the slice towards increasing x results in smaller tetrahedra, until x = 0.5 where they disappear. Moving further to the right, the tetrahedra appear at x = 1 and increase in size as we move along the channel.
Why is this happening?

Attachment 71900

Attachment 71901

Attachment 71902

Attachment 71903
Are you using parallel mode? I had the same problem when I run in parallel.
syavash is online now   Reply With Quote

Old   August 28, 2019, 10:03
Default
  #3
New Member
 
Join Date: Sep 2018
Posts: 20
Rep Power: 2
tecmul is on a distinguished road
Quote:
Originally Posted by syavash View Post
Are you using parallel mode? I had the same problem when I run in parallel.
No my case isn't parallel. I was curious and switched to parallel to see what would happen. The same thing happened. Thanks anyway.
tecmul is offline   Reply With Quote

Reply

Tags
cuttingplane, slice, surfacefieldvalue, wrong surface

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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
export calculated variable with cuttingPlane Eloise OpenFOAM Post-Processing 0 June 16, 2014 10:59
How to plot variable (alpha1) on cuttingPlane (runtime postprocessing) pythag0ra5 OpenFOAM Post-Processing 1 September 26, 2013 08:46
Creating Surfaces in Fluid Body Jenny_W Main CFD Forum 2 June 5, 2012 05:05
Modeling both radiation and convection on surfaces - Ansys Transient Thermal R13 s.mishra ANSYS 0 March 31, 2012 04:12
Problem in running ICEM grid in Openfoam Tarak OpenFOAM 6 September 9, 2011 17:51


All times are GMT -4. The time now is 16:08.