kmallick |
March 28, 2017 11:12 |
Negative torque with PimpleDyMFoam
I am simulating a vertical axis wind turbine (vawt) in OpenFoam using sliding mesh AMI. The turbine is a set of 3 twisted savonius style blades. The axis of rotation is the z axis. The stator domain is 19D x 14D x 14D where D is the turbine diameter. When I run my analysis with stuck rotor using SimpleFoam I get the correct positive torque around the z axis when equilibrium is reached However when I run a dynamic analysis with positive rotation speed around the z axis using PimpleDyMFoam, I consistently get negative torque and negative torque coefficient, even after the analysis has continued past a number of full 360 deg. rotations of the turbine. The only time I get a positive torque is when I run the PimpleDyMFoam analysis at zero or very low rotational speed.
I have checked all my parameters, boundary conditions, mesh quality, fvsolution and fvscheme settings and I just cannot seem to pinpoint what could be causing the negative torque. I have checked the log file and Courant number is always below 1.
I am anxious to seek out some help and suggestions from the forum.
Below are some pictures of my model and the relevant system files.
http://k-mount.com/cfd/model.png
http://k-mount.com/cfd/mesh1.png
http://k-mount.com/cfd/mesh2.png
http://k-mount.com/cfd/mesh3.png
http://k-mount.com/cfd/torque.png
Here is my dynamicMeshDict:
HTML Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: dev |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "constant";
object dynamicMeshDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
dynamicFvMesh dynamicMotionSolverFvMesh;
motionSolverLibs ( "libfvMotionSolvers.so" );
solver solidBody;
solidBodyCoeffs
{
cellZone rotor;
solidBodyMotionFunction rotatingMotion;
rotatingMotionCoeffs
{
origin (0 0 0);
axis (0 0 1);
omega 7; // rad/s
}
}
// ************************************************************************* //
My controlDict:
HTML Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.2.2 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "system";
object controlDict;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
application pimpleDyMFoam;
startFrom latestTime;
//startTime 0;
stopAt endTime;
endTime 20;
deltaT .0025;
writeControl adjustableRunTime;
writeInterval 0.01;
purgeWrite 0;
writeFormat ascii;
writePrecision 6;
writeCompression off;
timeFormat general;
timePrecision 6;
runTimeModifiable true;
adjustTimeStep yes
maxCo 1.0;
libs
(
"libincompressibleTurbulenceModels.so"
);
functions
{
#includeFunc residuals
#includeFunc Q
#include "surfaces"
#include "forces"
#include "wallPressure"
}
// ************************************************************************* //
My forces file:
HTML Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: dev |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
forces
{
type forces;
libs ("libforces.so");
writeControl timeStep;
timeInterval 1;
log yes;
patches ("blades.*");
rho rhoInf; // Indicates incompressible
log true;
rhoInf 1; // Redundant for incompressible
CofR (0 0 0); // Rotation around centre line of turbine
}
forceCoeffs
{
type forceCoeffs;
functionObjectLibs ("libforces.so");
writeControl timeStep;
timeInterval 1;
patches ("blades.*");
rho rhoInf;
rhoInf 1; // Redundant for incompressible
CofR (0 0 0);
pitchAxis (0 0 1);
dragDir (1 0 0);
liftDir (0 1 0);
magUInf 7;
lRef 1.;
Aref 2.44;
}
// ************************************************************************* //
My fvSolution:
HTML Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: dev |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "system";
object fvSolution;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
solvers
{
p
{
solver GAMG;
tolerance 1e-8;
relTol 0.01;
smoother GaussSeidel;
cacheAgglomeration no;
nCellsInCoarsestLevel 10;
agglomerator faceAreaPair;
mergeLevels 1;
maxIter 50;
}
pFinal
{
$p;
tolerance 1e-06;
relTol 0;
}
pcorr
{
$p
tolerance 0.02;
relTol 0;
}
"(U|k|omega)"
{
solver smoothSolver;
smoother symGaussSeidel;
tolerance 1e-06;
relTol 0.1;
maxIter 100;
minIter 1;
}
"(U|k|omega)Final"
{
$U;
tolerance 1e-06;
relTol 0;
maxIter 100;
minIter 1;
}
cellDisplacement
{
solver GAMG;
tolerance 1e-5;
relTol 0;
smoother GaussSeidel;
}
}
PIMPLE
{
correctPhi no; //was no
nOuterCorrectors 1; //was 2
nCorrectors 2;
nNonOrthogonalCorrectors 0;
pRefCell 0;
pRefValue 0;
turbOnFinalIterOnly on;
consistent true;
residualControl
{
"(p|U)"
{
tolerance 1e-4;
relTol 0;
}
"(k|omega)"
{
tolerance 1e-4;
relTol 0;
}
}
}
relaxationFactors
{
fields
{
p 0.3;
}
equations
{
U 0.9;
k 0.7;
omega 0.7;
}
}
// ************************************************************************* //
My fvSchemes:
HTML Code:
/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.2.2 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class dictionary;
location "system";
object fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
ddtSchemes
{
default Euler;
//default CrankNicolson 0.5;
}
wallDist
{
method meshWave;
}
gradSchemes
{
default Gauss linear;
grad(p) Gauss linear;
//grad(U) Gauss linear;
grad(U) cellLimited Gauss linear 1;
}
divSchemes
{
default none;
//div(phi,U) Gauss upwind;
//div(phi,U) Gauss linearUpwindV grad(U);
div(phi,U) Gauss linearUpwind grad(U);
div(phi,k) Gauss upwind;
div(phi,omega) Gauss upwind;
div((nuEff*dev(T(grad(U))))) Gauss linear;
div((nuEff*dev2(T(grad(U))))) Gauss linear;
}
laplacianSchemes
{
// default Gauss linear corrected;
default Gauss linear limited corrected 0.33;
}
interpolationSchemes
{
default linear;
}
snGradSchemes
{
// default corrected;
default limited corrected 0.33;
}
fluxRequired
{
default no;
pcorr ;
p ;
}
wallDist
{
method meshWave;
}
// ************************************************************************* //
|