View Issue Details

IDProjectCategoryView StatusLast Update
0000663OpenFOAM[All Projects] Bugpublic2015-01-03 15:44
Reporteruser525Assigned To 
PriorityurgentSeveritymajorReproducibilityalways
Status newResolutionopen 
PlatformLinuxOSUbuntuOS Version12.04.01 64 bit
Product Version 
Fixed in Version 
Summary0000663: AMI corrupts passive scalar
DescriptionThe passive scalar are NOT correctly calculated when using AMI.

Using a simple tutorial case (mixerVesselAMI2D) with fixedvalue uniform T (as example), immediately are shown cells with higher and lower temperature close to one wing (interesting, not all wings....) .
 
Starting form a uniform field, the problem seems related to a Phi divergence that is not null in those cells, increasing or decreasing the total T (passive scalar) in those cells.

The non 0 divergence, may cause of course other issues not yet discovered...
Steps To Reproduceusing tutorial example mixerVesselAMI2D, add passive scalar (e.g Temperature) as described for icoFoam in http://openfoamwiki.net/index.php/How_to_add_temperature_to_icoFoam , acting on mixerVesselAMI2D tutorial.
The same result can be obtained for any passive scalar.


Modify
transportProperties
my_icoFoam.C and createField.H
fvSchemes and fvSolution


In "0" directory, set the boundaryField for stator and rotor in new the T file with fixed uniform temperature, so that *no changes should occur* in temperature when mixer rotating
{
        type fixedValue;
        value uniform 100;
    }


Run the solver.
Open paraFoam, and discover that exist cluster of cells that shows higher themperature and cluster of cells that show lower temp. than 100°C.

See image.

TagsAMI

Activities

user525

2012-10-15 09:23

 

user525

2012-10-15 17:55

  ~0001730

The cells concerned with the problem, are the ones close/around to pRefCell.
Changing the pRefCell Value, makes the problem appear around that new pRefCell.

PIMPLE
{
....
    pRefCell 0;
    pRefValue 100;
}

user525

2012-10-15 18:05

  ~0001731

Commenting out the divergence operator in the passive scalar solver, makes error disappear.
Things seems to show that the problem is concerned with divergence error caused in the very first cell calculated.


        fvScalarMatrix TEqn
        (
            fvm::ddt(T)
            //+ fvm::div(phi, T) < commented out ============
            - fvm::laplacian(DT, T)
        );

        TEqn.solve();
        T.correctBoundaryConditions();

user525

2012-10-15 21:45

  ~0001732

More info...
Before passive scalar solver, dumped out divergence values;

It shows clearly the FIRST Cells have a very HUGE DIVERGENCE,
very different from the other cells

dump and code follow:
--------------------------------------------------
time step continuity errors : sum local = 8.08573e-09, global = -1.18856e-09, cumulative = -1.18467e-09
GAMG: Solving for p, Initial residual = 0.0747711, Final residual = 0.000343049, No Iterations 6
GAMG: Solving for p, Initial residual = 0.000336345, Final residual = 1.99852e-06, No Iterations 6
GAMG: Solving for p, Initial residual = 1.9989e-06, Final residual = 5.45285e-07, No Iterations 2
time step continuity errors : sum local = 3.22009e-09, global = -2.85251e-10, cumulative = -1.46992e-09
Divergence:

3072
(
-0.00377731 <============ here
6.81498e-05
-0.000131197 <============ here
1.04748e-05
-8.13186e-05
9.22288e-06
-2.76134e-05
.....
.....
----------------------------------------------------------------
                turbulence->correct();
            }
        }
Info << "Divergence:" << endl;
Info << scalarField(fvc::div(phi)) << endl;

        fvScalarMatrix TEqn
        (
            fvm::ddt(T)
            + fvm::div(phi, T)
            - fvm::laplacian(DT, T)
        );
--------------------------------------------------

user525

2012-10-16 21:30

  ~0001736

Tutorial case + passive scalar tested also on OF 2.1.x

But with the same result:
-----------------------------------------------------------------------
time step continuity errors : sum local = 8.08573e-09, global = -1.18856e-09, cumulative = -1.18467e-09
GAMG: Solving for p, Initial residual = 0.0747711, Final residual = 0.000343049, No Iterations 6
GAMG: Solving for p, Initial residual = 0.000336345, Final residual = 1.99852e-06, No Iterations 6
GAMG: Solving for p, Initial residual = 1.9989e-06, Final residual = 5.45285e-07, No Iterations 2
time step continuity errors : sum local = 3.22009e-09, global = -2.85251e-10, cumulative = -1.46992e-09
Divergence with OpenFoam 2.1.x:

3072
(
-0.00377731
6.81498e-05
-0.000131197
1.04748e-05
-8.13186e-05

user270

2012-11-20 13:48

  ~0001783

I was experiencing similar issues to the ones described here.
After reproducing mentioned test case, I run into similar results.
Running the test case on 64bit Ubuntu 10.04, OF-2.1.1

Issue History

Date Modified Username Field Change
2012-10-15 09:23 user525 New Issue
2012-10-15 09:23 user525 File Added: Schermata del 2012-10-15 09:59:26.png
2012-10-15 17:55 user525 Note Added: 0001730
2012-10-15 18:05 user525 Note Added: 0001731
2012-10-15 21:45 user525 Note Added: 0001732
2012-10-16 21:30 user525 Note Added: 0001736
2012-11-20 13:48 user270 Note Added: 0001783
2014-12-29 18:42 wyldckat Tag Attached: AMI