From a1a70270f0a93737fa161d212fc66f50eb9fc89a Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Sat, 28 Jan 2017 18:05:41 +0000 Subject: [PATCH] functionObjects::streamLine,wallBoundedStreamLine: Removed outdated check for 'UName' Patch contributed by Bruno Santos Resolves patch request https://bugs.openfoam.org/view.php?id=2444 --- .../field/streamLine/streamLine.C | 19 ++--------------- .../field/streamLine/streamLine.H | 6 +++++- .../wallBoundedStreamLine.C | 21 ++----------------- 3 files changed, 9 insertions(+), 37 deletions(-) diff --git a/src/functionObjects/field/streamLine/streamLine.C b/src/functionObjects/field/streamLine/streamLine.C index 0908a5b7a..99d1d3e7c 100644 --- a/src/functionObjects/field/streamLine/streamLine.C +++ b/src/functionObjects/field/streamLine/streamLine.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -324,22 +324,7 @@ bool Foam::functionObjects::streamLine::read(const dictionary& dict) Info<< type() << " " << name() << ":" << nl; dict.lookup("fields") >> fields_; - if (dict.found("U")) - { - dict.lookup("U") >> UName_; - } - else - { - UName_ = "U"; - if (dict.found("U")) - { - IOWarningInFunction(dict) - << "Using deprecated entry \"U\"." - << " Please use \"UName\" instead." - << endl; - dict.lookup("U") >> UName_; - } - } + dict.lookup("U") >> UName_; if (findIndex(fields_, UName_) == -1) { diff --git a/src/functionObjects/field/streamLine/streamLine.H b/src/functionObjects/field/streamLine/streamLine.H index d6b215776..873fed628 100644 --- a/src/functionObjects/field/streamLine/streamLine.H +++ b/src/functionObjects/field/streamLine/streamLine.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -40,16 +40,20 @@ Description libs ("libfieldFunctionObjects.so"); ... setFormat vtk; + U U; trackForward yes; + fields ( U p ); + lifeTime 10000; trackLength 1e-3; nSubCycle 5; cloudName particleTracks; + seedSampleSet uniform; uniformCoeffs { diff --git a/src/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.C b/src/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.C index 41966402d..b929c5e5d 100644 --- a/src/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.C +++ b/src/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2017 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -441,24 +441,7 @@ bool Foam::functionObjects::wallBoundedStreamLine::read(const dictionary& dict) { //dict_ = dict; dict.lookup("fields") >> fields_; - if (dict.found("U")) - { - dict.lookup("U") >> UName_; - } - else - { - UName_ = "U"; - if (dict.found("U")) - { - IOWarningInFunction - ( - dict - ) << "Using deprecated entry \"U\"." - << " Please use \"UName\" instead." - << endl; - dict.lookup("U") >> UName_; - } - } + dict.lookup("U") >> UName_; if (findIndex(fields_, UName_) == -1) {