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

[swak4Foam] Track vortices using Swak4FOAM

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By vinz

 
 
LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old   April 11, 2012, 11:16
Default Track vortices using Swak4FOAM
  #1
Senior Member
 
Vincent RIVOLA
Join Date: Mar 2009
Location: France
Posts: 283
Rep Power: 18
vinz is on a distinguished road
Hi all,

I am simulating the propagation in space and time of some vortices.
I would like to be able to trace the center of these vortices into my field and then be able to compute the circulation on a closed surface around this center.

So, first step I need to trace the center of my vortex. It looks like defining some functions in the controlDict and using the libsimpleSwakFunctionObjects could be an option but I am not sure how to do it.
To start easy I was planning to find the center of my vortex by looking for the maximum vorticity in my field.

I wrote those lines in my dictionary:
Code:
functions 
(
    defineFollowVortex {
        type addGlobalVariable;
        outputControl timeStep;
        outputInterval 1;

        globalScope followVortex;
        globalVariables {
            yThres {
                valueType scalar;
                value 0.2;
            }
        }
    };
    createVortexCenter {
        type createSampledSet;
        outputControl timeStep;
        outputInterval 1;
        setName vortexCenter;
        set {
            type cloud;
            axis y;
            points( (0.5 2 0.0) );
        }
    }

    vorticityMax {
	type swakExpression;
	verbose true;
	valueType set;
	setName vorticityMax;
	expression "(pos.y()>yThres) ? magVorticity : 0"; 
	accumulations ( max );
        set {
            type swakRegistryProxy;
            axis y;
            setName vortexCenter;
        }
        interpolate true;
        interpolationType cellPoint;
    }

    vortexHeight {
        type swakExpression;
        verbose true;
        valueType set;
        setName  fillingHeight;
        globalScopes ( "fillDam" );
        expression "(magVorticity >= 0.99*vorticityMax) ? pos().y : 0";
        accumulations (
            max
        );
        set {
            type swakRegistryProxy;
            axis y;
            setName vortexCenter;
        }
        interpolate true;
        interpolationType cellPoint;
    }
);
However I am really not sure it is the way to go and I get the following error message:
Code:
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time

[0] 
[0] 
[0] --> FOAM FATAL IO ERROR: 
[0] "ill defined primitiveEntry starting at keyword 'functions' on line 60 and ending at line 124"
[0] 
[0] file: /CFDBB/vincent/OpenFOAM/vincent-2.1.0/run/tutorials/compressible/rhoPimpleDyMFoamWithSources/LES/AfterMeeting120330/testVortexHeight/processor0/../system/controlDict at line 124.
[0] 
[0]     From function primitiveEntry::readEntry(const dictionary&, Istream&)
[0]     in file lnInclude/IOerror.C at line 132.
[0] 
FOAM parallel run exiting
Any idea?
vinz is offline   Reply With Quote

 


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
Why my track file is 0 K after the simulation is saved calmdown911 STAR-CCM+ 0 December 19, 2017 10:22
Hairpin vortices in turbulent channel flow using DNS Nitin Minocha Main CFD Forum 2 November 21, 2016 17:52
[swak4Foam] Rotating Wall Velocity and Swak4Foam mpanch13114 OpenFOAM Community Contributions 0 September 14, 2016 04:55
[swak4Foam] and twoPhaseEulerFoam mnikku OpenFOAM Community Contributions 1 February 19, 2016 05:21
[swak4Foam] fails in parallel with -otherTime? Phicau OpenFOAM Community Contributions 3 June 26, 2013 13:00


All times are GMT -4. The time now is 15:38.