CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   adjointShapeOptimizationFoam for In-compressible NS (http://www.cfd-online.com/Forums/openfoam/104405-adjointshapeoptimizationfoam-compressible-ns.html)

smanekshaw July 9, 2012 04:05

adjointShapeOptimizationFoam for In-compressible NS
 
Hi

I would like more details about this solver.
Could i use it to optimize wing/body shape for INS equations?

Does it use a continous or discrete adjoint solver?
Where could i get details/papers about the solver


Thanks
Sam

sylvester July 9, 2012 04:56

Hi Sam,

AdjointShapeOptimizationFoam is a continous adjoint topology optimizer using the incompressible Navier-Stokes equations. It probably can be used for wing/body shape optimization, but in its present form it is more suitable for internal flows.

The code of adjointShapeOptimizationFoam lists this paper as source:
http://pdf.aiaa.org/preview/CDReadyM...V2007_3947.pdf

Best regards,
Sylvester

kjw November 12, 2012 16:32

example
 
2 Attachment(s)
Welcome to all Foamers,
I am trying to proceed the example presented in the paper quoted below.
Quote:

Originally Posted by sylvester (Post 370416)
Hi Sam,

The code of adjointShapeOptimizationFoam lists this paper as source:
http://pdf.aiaa.org/preview/CDReadyM...V2007_3947.pdf

While the case is calculated with simpleFoam, the flow seem to be Ok, the same example computed with adjointShapeOptimizationFoam react a little bit odd.

Below the results of adjoint... and simple.. are presented, respectively.

Attachment 16907Attachment 16908

The code attached comes from adjointShapeOptimizationFoam.

Best Regards

Christopher

Code:

FoamFile
{
    version    2.0;
    format      ascii;
    class      dictionary;
    location    "constant";
    object      RASProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

RASModel        laminar;//kEpsilon;

turbulence      off;//on;

printCoeffs    off;//on;

// ************************************************************************* //
FoamFile
{
    version    2.0;
    format      ascii;
    class      dictionary;
    location    "constant";
    object      transportProperties;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

transportModel  Newtonian;

nu              nu [0 2 -1 0 0 0 0] 2e-4;//1e-5;

lambda          lambda  [0 -2 1 0 0 0 0] 1e5;
alphaMax        alphaMax [0 0 -1 0 0 0 0] 200.0;

// ************************************************************************* //]
FoamFile
{
    version    2.0;
    format      ascii;
    class      dictionary;
    location    "system";
    object      fvSolution;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

solvers
{
    "(p|pa)"
    {
        solver          GAMG;
        tolerance      1e-08;
        relTol          0.001;
        smoother        GaussSeidel;
        nPreSweeps      0;
        nPostSweeps    2;
        cacheAgglomeration true;
        nCellsInCoarsestLevel 10;
        agglomerator    faceAreaPair;
        mergeLevels    1;
    }

    "(U|Ua|k|epsilon)"
    {
        solver          GAMG;
        smoother        GaussSeidel;
        nSweeps        2;
        tolerance      1e-08;
        relTol          0.01;
        nPreSweeps      0;
        nPostSweeps    2;
        cacheAgglomeration true;
        nCellsInCoarsestLevel 10;
        agglomerator    faceAreaPair;
        mergeLevels    1;
    }
}

SIMPLE
{
    nNonOrthogonalCorrectors 0;
    pRefCell 0;
    pRefValue 0;
}

relaxationFactors
{
    fields
    {
        "(p|pa)"        0.2;
        "(alpha)"          0.1;
    }
    equations
    {
        "(U|Ua)"        0.2;
        "(k|epsilon)"  0.7;
    }
}


// ************************************************************************* //
FoamFile
{
    version    2.0;
    format      ascii;
    class      dictionary;
    location    "system";
    object      fvSchemes;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

ddtSchemes
{
    default        steadyState;
}

gradSchemes
{
    default        Gauss linear;

    grad(p)        Gauss linear;
    grad(U)        Gauss linear;
}

divSchemes
{
    default        none;

    div(phi,U)      Gauss upwind;
    div(phi,k)      Gauss upwind;
    div(phi,epsilon) Gauss upwind;
    div((nuEff*dev(T(grad(U))))) Gauss linear;

    div(-phi,Ua)    Gauss upwind;
    div((nuEff*dev(T(grad(Ua))))) Gauss linear;
}

laplacianSchemes
{
    default        Gauss linear corrected;

    laplacian(nuEff,U) Gauss linear corrected;
    laplacian(1,p) Gauss linear corrected;
    laplacian(1|A(U),p) Gauss linear corrected;
    laplacian(DkEff,k) Gauss linear corrected;
    laplacian(DepsilonEff,epsilon) Gauss linear corrected;

    laplacian(nuEff,Ua) Gauss linear corrected;
    laplacian(1|A(Ua),pa) Gauss linear corrected;
}

interpolationSchemes
{
    default        linear;
    interpolate(U)  linear;
}

snGradSchemes
{
    default        corrected;
}

fluxRequired
{
    default        no;
    p;
    pa;
}

// ************************************************************************* //

    object      Ua;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 1 -1 0 0 0 0];

internalField  uniform (0 0 0);

boundaryField
{
    inlet
    {
        type            fixedValue;
        value          uniform (0 1 0);
    }
        walls
    {
        type            fixedValue;
        value          uniform (0 0 0);
    }
    outlet
    {
        type            adjointOutletVelocity;
        value          uniform (1 0 0);
    }

    frontAndBack
    {
        type            empty;
    }
}

// ************************************************************************* //
    object      U;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 1 -1 0 0 0 0];

internalField  uniform (0 0 0);

boundaryField
{
    inlet
    {
        type            fixedValue;
        value          uniform (0 1 0);
    }
    outlet
    {
        type            fixedValue;
        value          uniform (1 0 0);
    }
    walls
    {
        type            fixedValue;
        value          uniform (0 0 0);
    }
    frontAndBack
    {
        type            empty;
    }
}


// ************************************************************************* //
    object      pa;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 2 -2 0 0 0 0];

internalField  uniform 0;

boundaryField
{
    inlet
    {
        type            zeroGradient;
    }
        walls
    {
        type            zeroGradient;
    }
    outlet
    {
        type            adjointOutletPressure;
        value          uniform 0;
    }

    frontAndBack
    {
        type            empty;
    }
}

// ************************************************************************* //
    object      p;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions      [0 2 -2 0 0 0 0];

internalField  uniform 0;

boundaryField
{
    inlet
    {
        type            zeroGradient;
    }
    walls
    {
        type            zeroGradient;
    }
    outlet
    {
        type            fixedValue;
        value          uniform 0;
    }

    frontAndBack
    {
        type            empty;
    }
}

// ************************************************************************* //


samiam1000 December 4, 2012 07:04

Hi all,

pardon the interruption, just a question for you: where can I find the case posted in the last post? Is it in the tutorials?

Thanks a lot,

Samuele

kjw December 4, 2012 17:47

This case is in the paper that has been linked. It has been described and recreated.
It is not in the tutorial.

Regards

Krzysztof

Quote:

Originally Posted by samiam1000 (Post 395665)
Hi all,

pardon the interruption, just a question for you: where can I find the case posted in the last post? Is it in the tutorials?

Thanks a lot,

Samuele


samiam1000 December 4, 2012 18:18

Is it possible to have the case folder?

immortality January 7, 2013 16:42

what's the link of full article paper?

ngj January 7, 2013 16:52

AIAA papers typically costs money - and I guess it also does in this case.

Kind regards,

Niels


All times are GMT -4. The time now is 02:45.