Calculated - Boundary Condition | OpenFOAM

Calculated - Boundary Condition   Description

The Calculated boundary condition is one where the boundary value is computed based on other existing primary fields, rather than being explicitly specified by the user.

In other words, it is an artificial boundary condition used in derivative fields that are not directly obtained from solving Partial Differential Equations (PDEs). In OpenFOAM, the format for storing result fields always requires a boundary condition to be specified, so Calculated essentially serves as a placeholder.

Calculated - Boundary Condition   Understanding Calculated

The best way to understand how the Calculated boundary condition works is to consider the physics of the problem at hand. The Calculated boundary condition indicates that the property in question is fully defined by other boundary conditions and specified properties.

One of the most common applications of Calculated is in prescribing turbulent quantities. For example, when using a two-equation turbulence model like \(k-\epsilon\), the user needs to define the turbulent kinetic energy (\(k\)), turbulent dissipation rate (\(\epsilon\)), and kinematic eddy viscosity (\(\nu_t\)).

Since the kinematic eddy viscosity (\(\nu_t\)) is calculated based on \(k\) and \(\epsilon\), the user does not need to specify its value. From a physical standpoint, this additional information does not provide any new insight into the problem. For such situations the Calculated boundary condition should be used on the patches which values depend on other quantities.

Calculated - Boundary Condition   Application & Physical Interpretation

The Calculated boundary condition is used to derive boundary values from the internal field values of the domain or other boundary conditions. It is commonly applied in scenarios where the boundary value depends on other solved properties, rather than being explicitly specified.

Calculated in Aerodynamics applications

Example applications: aircraft aerodynamics

High-speed flows around airplanes can be solved using the sonicFoam (solver). To properly predict drag and lift forces, a turbulence model like \(k-\epsilon\) must be used. At the inlet to the domain, turbulent properties like the turbulent kinetic energy (\(k\)), turbulent dissipation rate (\(\epsilon\)), and kinematic eddy viscosity (\(\nu_t\)) must be specified. However, the kinematic eddy viscosity \(\nu_t\) will be calculated by the solver, based on already specified \(k\) and \(\epsilon\).

Example Boundary Conditions set for Aerodynamics applications
PhysicsPressureVelocity\(k\)\(epsilon\)\(\nu_t\)

Freestream Inlet

Zero Gradient

Freestream

InletOutlet

InletOutlet

Calculated

Calculated in Combustion applications

In a fire simulation, the User might have a field for combustion products (e.g., fuel, oxidizer, or species concentration). When the simulation runs, the concentration of fuel at the boundary will be calculated based on the internal field values.

Example Boundary Conditions set for Combustion applications
PhysicsPressureVelocity\(p_{rhogh}\)\(k\)N2 concentration

Burner

Calculated

Flow Rate Outlet Velocity

Fixed Flux Pressure

Fixed Value

Calculated

Calculated - Boundary Condition   Calculated in SimFlow

In SimFlow the Calculated boundary condition is not defined explicitly by the User. Instead, the software recognizes the proper application of this boundary condition. For example, when defining the problem that involves turbulence, after selection of \(k-\epsilon\) model, the User can only specify \(k\) and \(\epsilon\). \(\nu_t\) is written by the solver in the background - Figure 1

Calculated Boundary Condition SimFlow
Figure 1. Calculated boundary condition is implicitly defined by SimFlow

Calculated - Boundary Condition   Calculated - Alternatives

In this section, we propose boundary conditions that are alternative to Calculated. While they may fulfill similar purposes, they might be better suited for a specific application and provide a better approximation of physical world conditions.

Boundary ConditionDescription

Fixed Value

the boundary condition specifies a constant value at the boundary

Zero Gradient

the boundary condition specifies a constant gradient (rate of change) at the boundary