butterfly.boundarycondition module

Collection of OpenFOAM boundary conditions (e.g. wall, inlet, outlet).

class butterfly.boundarycondition.BoundaryCondition(bc_type='patch', T=None, U=None, p=None, k=None, epsilon=None, nut=None, alphat=None, p_rgh=None)[source]

Bases: object

Boundary condition base class.

T

T boundary condition.

ToString()[source]

Overwrite .NET ToString.

U

U boundary condition.

alphat

alphat boundary condition.

duplicate()[source]

Duplicate Boundary Condition.

epsilon

epsilon boundary condition.

isBoundaryCondition()[source]

Return True for boundary conditions.

k

k boundary condition.

nut

nut boundary condition.

p

p boundary condition.

p_rgh

p_rgh boundary condition.

static try_get_field(f)[source]

Try getting the field from the input.

The method will return the input if it is an instance of class <Field>, otherwise it tries to create the field from a dictionary and finally tries to create it from the string.

class butterfly.boundarycondition.BoundingBoxBoundaryCondition[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Bounding box boundary condition for bounding box geometry.

It returns a boundary condition of ZeroGradient for all the inputs.

class butterfly.boundarycondition.EmptyBoundaryCondition[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Empty boundary condition.

It returns a boundary condition of Empty for all the inputs.

class butterfly.boundarycondition.FixedInletBoundaryCondition(T=None, U=None, p=None, k=None, epsilon=None, nut=None, alphat=None, p_rgh=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Inlet boundary condition base class.

T

Optional input for Temperature.

U

Air velocity as fixed value (x, y, z).

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.

class butterfly.boundarycondition.FixedOutletBoundaryCondition(T=None, U=None, p=None, k=None, epsilon=None, nut=None, alphat=None, p_rgh=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Outlet boundary condition base class.

pressure

Pressure as a float (default: 0)

T

Optional input for Temperature.

U

OpenFOAM value for U.

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.

class butterfly.boundarycondition.IndoorWallBoundaryCondition(T=None, U=None, p=None, k=None, epsilon=None, nut=None, alphat=None, p_rgh=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Wall boundary condition base class.

T

Optional input for Temperature.

U

OpenFOAM value for U.

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.

class butterfly.boundarycondition.WindTunnelGroundBoundaryCondition(ABLConditions, T=None, U=None, p=None, k=None, epsilon=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Wind tunnel ground boundary condition.

T

Optional input for Temperature.

T

Optional input for Temperature.

U

OpenFOAM value for U.

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.

class butterfly.boundarycondition.WindTunnelInletBoundaryCondition(ABLConditions, T=None, p=None, nut=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Wind tunnel atmBoundaryLayerInletVelocity boundary condition.

T

Optional input for Temperature.

U

OpenFOAM value for U.

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.

class butterfly.boundarycondition.WindTunnelOutletBoundaryCondition(T=None, U=None, p=None, k=None, epsilon=None, nut=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Outlet boundary condition for wind tunnel.

pressure

Pressure as a float (default: 0)

T

Optional input for Temperature.

U

OpenFOAM value for U.

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.

class butterfly.boundarycondition.WindTunnelTopAndSidesBoundaryCondition(T=None, U=None, p=None, k=None, epsilon=None, nut=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Outlet boundary condition for top and sides of wind tunnel.

pressure

Pressure as a float (default: 0)

T

Optional input for Temperature.

U

OpenFOAM value for U.

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.

class butterfly.boundarycondition.WindTunnelWallBoundaryCondition(T=None, U=None, p=None, k=None, epsilon=None, nut=None)[source]

Bases: butterfly.boundarycondition.BoundaryCondition

Wall boundary condition for wall geometrys inside wind tunnel.

T

Optional input for Temperature.

T

Optional input for Temperature.

U

OpenFOAM value for U.

p

OpenFOAM value for p.

k

OpenFOAM value for k.

epsilon

OpenFOAM value for epsilon.

nut

OpenFOAM value for nut.