sfepy.terms.terms_adj_navier_stokes module

class sfepy.terms.terms_adj_navier_stokes.AdjConvect1Term(name, arg_str, integral, region, **kwargs)[source]

The first adjoint term to nonlinear convective term dw_convect.

Definition:

\int_{\Omega} ((\ul{v} \cdot \nabla) \ul{u}) \cdot \ul{w}

Call signature:
dw_adj_convect1 (virtual, state, parameter)
Arguments:
  • virtual : \ul{v}
  • state : \ul{w}
  • parameter : \ul{u}
arg_shapes = {‘state’: ‘D’, ‘parameter’: ‘D’, ‘virtual’: (‘D’, ‘state’)}
arg_types = (‘virtual’, ‘state’, ‘parameter’)
static function()
get_fargs(virtual, state, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘dw_adj_convect1’
class sfepy.terms.terms_adj_navier_stokes.AdjConvect2Term(name, arg_str, integral, region, **kwargs)[source]

The second adjoint term to nonlinear convective term dw_convect.

Definition:

\int_{\Omega} ((\ul{u} \cdot \nabla) \ul{v}) \cdot \ul{w}

Call signature:
dw_adj_convect2 (virtual, state, parameter)
Arguments:
  • virtual : \ul{v}
  • state : \ul{w}
  • parameter : \ul{u}
arg_shapes = {‘state’: ‘D’, ‘parameter’: ‘D’, ‘virtual’: (‘D’, ‘state’)}
arg_types = (‘virtual’, ‘state’, ‘parameter’)
static function()
get_fargs(virtual, state, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘dw_adj_convect2’
class sfepy.terms.terms_adj_navier_stokes.AdjDivGradTerm(name, arg_str, integral, region, **kwargs)[source]

Gateaux differential of \Psi(\ul{u}) = \int_{\Omega} \nu\
\nabla \ul{v} : \nabla \ul{u} w.r.t. \ul{u} in the direction \ul{v} or adjoint term to dw_div_grad.

Definition:

w \delta_{u} \Psi(\ul{u}) \circ \ul{v}

Call signature:
dw_adj_div_grad (material_1, material_2, virtual, parameter)
Arguments:
  • material_1 : w (weight)
  • material_2 : \nu (viscosity)
  • virtual : \ul{v}
  • state : \ul{u}
arg_shapes = {‘material_1’: ‘1, 1’, ‘material_2’: ‘1, 1’, ‘parameter’: ‘D’, ‘virtual’: (‘D’, None)}
arg_types = (‘material_1’, ‘material_2’, ‘virtual’, ‘parameter’)
static function()
get_fargs(mat1, mat2, virtual, state, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘dw_adj_div_grad’
class sfepy.terms.terms_adj_navier_stokes.NSOFMinGradTerm(name, arg_str, integral, region, **kwargs)[source]
Call signature:
d_of_ns_min_grad (material_1, material_2, parameter)
arg_shapes = {‘material_1’: ‘1, 1’, ‘material_2’: ‘1, 1’, ‘parameter’: 1}
arg_types = (‘material_1’, ‘material_2’, ‘parameter’)
static function()
get_eval_shape(weight, mat, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(weight, mat, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_of_ns_min_grad’
class sfepy.terms.terms_adj_navier_stokes.NSOFSurfMinDPressDiffTerm(name, arg_str, integral, region, **kwargs)[source]

Gateaux differential of \Psi(p) w.r.t. p in the direction q.

Definition:

w \delta_{p} \Psi(p) \circ q

Call signature:
dw_of_ns_surf_min_d_press_diff (material, virtual)
Arguments:
  • material : w (weight)
  • virtual : q
arg_shapes = {‘material’: 1, ‘virtual’: (1, None)}
arg_types = (‘material’, ‘virtual’)
get_fargs(weight, virtual, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘dw_of_ns_surf_min_d_press_diff’
class sfepy.terms.terms_adj_navier_stokes.NSOFSurfMinDPressTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity of \Psi(p).

Definition:

\delta \Psi(p) = \delta \left( \int_{\Gamma_{in}}p -
\int_{\Gamma_{out}}bpress \right)

Call signature:
d_of_ns_surf_min_d_press (material_1, material_2, parameter)
Arguments:
  • material_1 : w (weight)
  • material_2 : bpress (given pressure)
  • parameter : p
arg_shapes = {‘material_1’: 1, ‘material_2’: 1, ‘parameter’: 1}
arg_types = (‘material_1’, ‘material_2’, ‘parameter’)
static function()
get_eval_shape(weight, bpress, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(weight, bpress, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
integration = ‘surface’
name = ‘d_of_ns_surf_min_d_press’
class sfepy.terms.terms_adj_navier_stokes.SDConvectTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of convective term dw_convect.

Supports the following term modes: 1 (sensitivity) or 0 (original term value).

Definition:

\int_{\Omega} [ u_k \pdiff{u_i}{x_k} w_i (\nabla \cdot \Vcal)
- u_k \pdiff{\Vcal_j}{x_k} \pdiff{u_i}{x_j} w_i ]

Call signature:
d_sd_convect (parameter_u, parameter_w, parameter_mesh_velocity)
Arguments:
  • parameter_u : \ul{u}
  • parameter_w : \ul{w}
  • parameter_mesh_velocity : \ul{\Vcal}
arg_shapes = {‘parameter_mesh_velocity’: ‘D’, ‘parameter_w’: ‘D’, ‘parameter_u’: ‘D’}
arg_types = (‘parameter_u’, ‘parameter_w’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_convect’
class sfepy.terms.terms_adj_navier_stokes.SDDivGradTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of diffusion term dw_div_grad.

Supports the following term modes: 1 (sensitivity) or 0 (original term value).

Definition:

w \nu \int_{\Omega} [ \pdiff{u_i}{x_k} \pdiff{w_i}{x_k}
(\nabla \cdot \ul{\Vcal})
- \pdiff{\Vcal_j}{x_k} \pdiff{u_i}{x_j} \pdiff{w_i}{x_k}
- \pdiff{u_i}{x_k} \pdiff{\Vcal_l}{x_k} \pdiff{w_i}{x_k} ]

Call signature:
d_sd_div_grad (material_1, material_2, parameter_u, parameter_w, parameter_mesh_velocity)
Arguments:
  • material_1 : w (weight)
  • material_2 : \nu (viscosity)
  • parameter_u : \ul{u}
  • parameter_w : \ul{w}
  • parameter_mesh_velocity : \ul{\Vcal}
arg_shapes = {‘parameter_mesh_velocity’: ‘D’, ‘material_1’: ‘1, 1’, ‘material_2’: ‘1, 1’, ‘parameter_w’: ‘D’, ‘parameter_u’: ‘D’}
arg_types = (‘material_1’, ‘material_2’, ‘parameter_u’, ‘parameter_w’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(mat1, mat2, par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(mat1, mat2, par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_div_grad’
class sfepy.terms.terms_adj_navier_stokes.SDDivTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of Stokes term dw_stokes in ‘div’ mode.

Supports the following term modes: 1 (sensitivity) or 0 (original term value).

Definition:

\int_{\Omega} p [ (\nabla \cdot \ul{w}) (\nabla \cdot \ul{\Vcal})
- \pdiff{\Vcal_k}{x_i} \pdiff{w_i}{x_k} ]

Call signature:
d_sd_div (parameter_u, parameter_p, parameter_mesh_velocity)
Arguments:
  • parameter_u : \ul{u}
  • parameter_p : p
  • parameter_mesh_velocity : \ul{\Vcal}
arg_shapes = {‘parameter_mesh_velocity’: ‘D’, ‘parameter_p’: 1, ‘parameter_u’: ‘D’}
arg_types = (‘parameter_u’, ‘parameter_p’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(par_u, par_p, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(par_u, par_p, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_div’
class sfepy.terms.terms_adj_navier_stokes.SDDotVolumeTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of dot product of scalars or vectors.

Definition:

\int_{\Omega} p q (\nabla \cdot \ul{\Vcal}) \mbox{ , }
\int_{\Omega} (\ul{u} \cdot \ul{w}) (\nabla \cdot \ul{\Vcal})

Call signature:
d_sd_volume_dot (parameter_1, parameter_2, parameter_mesh_velocity)
Arguments:
  • parameter_1 : p or \ul{u}
  • parameter_2 : q or \ul{w}
  • parameter_mesh_velocity : \ul{\Vcal}
arg_shapes = [{‘parameter_mesh_velocity’: ‘D’, ‘parameter_2’: ‘D’, ‘parameter_1’: ‘D’}, {‘parameter_2’: 1, ‘parameter_1’: 1}]
arg_types = (‘parameter_1’, ‘parameter_2’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(par1, par2, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(par1, par2, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_volume_dot’
class sfepy.terms.terms_adj_navier_stokes.SDGradDivStabilizationTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of stabilization term dw_st_grad_div.

Definition:

\gamma \int_{\Omega} [ (\nabla \cdot \ul{u}) (\nabla \cdot \ul{w})
(\nabla \cdot \ul{\Vcal})
- \pdiff{u_i}{x_k} \pdiff{\Vcal_k}{x_i} (\nabla \cdot \ul{w})
- (\nabla \cdot \ul{u}) \pdiff{w_i}{x_k} \pdiff{\Vcal_k}{x_i} ]

Call signature:
d_sd_st_grad_div (material, parameter_u, parameter_w, parameter_mesh_velocity)
Arguments:
  • material : \gamma
  • parameter_u : \ul{u}
  • parameter_w : \ul{w}
  • parameter_mesh_velocity : \ul{\Vcal}
  • mode : 1 (sensitivity) or 0 (original term value)
arg_shapes = {‘parameter_mesh_velocity’: ‘D’, ‘material’: ‘1, 1’, ‘parameter_w’: ‘D’, ‘parameter_u’: ‘D’}
arg_types = (‘material’, ‘parameter_u’, ‘parameter_w’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(mat, par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(mat, par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_st_grad_div’
class sfepy.terms.terms_adj_navier_stokes.SDPSPGCStabilizationTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of stabilization terms dw_st_supg_p or dw_st_pspg_c.

Definition:

\sum_{K \in \Ical_h}\int_{T_K} \delta_K\
[ \pdiff{r}{x_i} (\ul{b} \cdot \nabla u_i) (\nabla \cdot \Vcal) -
\pdiff{r}{x_k} \pdiff{\Vcal_k}{x_i} (\ul{b} \cdot \nabla u_i)
- \pdiff{r}{x_k} (\ul{b} \cdot \nabla \Vcal_k) \pdiff{u_i}{x_k} ]

Call signature:
d_sd_st_pspg_c (material, parameter_b, parameter_u, parameter_r, parameter_mesh_velocity)
Arguments:
  • material : \delta_K
  • parameter_b : \ul{b}
  • parameter_u : \ul{u}
  • parameter_r : r
  • parameter_mesh_velocity : \ul{\Vcal}
  • mode : 1 (sensitivity) or 0 (original term value)
arg_shapes = {‘parameter_mesh_velocity’: ‘D’, ‘parameter_b’: ‘D’, ‘material’: ‘1, 1’, ‘parameter_u’: ‘D’, ‘parameter_r’: 1}
arg_types = (‘material’, ‘parameter_b’, ‘parameter_u’, ‘parameter_r’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(mat, par_b, par_u, par_r, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(mat, par_b, par_u, par_r, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_st_pspg_c’
class sfepy.terms.terms_adj_navier_stokes.SDPSPGPStabilizationTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of stabilization term dw_st_pspg_p.

Definition:

\sum_{K \in \Ical_h}\int_{T_K} \tau_K\ [ (\nabla r \cdot \nabla p)
(\nabla \cdot \Vcal) - \pdiff{r}{x_k} (\nabla \Vcal_k \cdot \nabla p) -
(\nabla r \cdot \nabla \Vcal_k) \pdiff{p}{x_k} ]

Call signature:
d_sd_st_pspg_p (material, parameter_r, parameter_p, parameter_mesh_velocity)
Arguments:
  • material : \tau_K
  • parameter_r : r
  • parameter_p : p
  • parameter_mesh_velocity : \ul{\Vcal}
  • mode : 1 (sensitivity) or 0 (original term value)
arg_shapes = {‘parameter_mesh_velocity’: ‘D’, ‘parameter_r’: 1, ‘material’: ‘1, 1’, ‘parameter_p’: 1}
arg_types = (‘material’, ‘parameter_r’, ‘parameter_p’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(mat, par_r, par_p, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(mat, par_r, par_p, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_st_pspg_p’
class sfepy.terms.terms_adj_navier_stokes.SDSUPGCStabilizationTerm(name, arg_str, integral, region, **kwargs)[source]

Sensitivity (shape derivative) of stabilization term dw_st_supg_c.

Definition:

\sum_{K \in \Ical_h}\int_{T_K} \delta_K\ [ (\ul{b} \cdot \nabla u_k)
(\ul{b} \cdot \nabla w_k) (\nabla \cdot \Vcal) -
(\ul{b} \cdot \nabla \Vcal_i) \pdiff{u_k}{x_i}
(\ul{b} \cdot \nabla w_k) - (\ul{u} \cdot \nabla u_k)
(\ul{b} \cdot \nabla \Vcal_i) \pdiff{w_k}{x_i} ]

Call signature:
d_sd_st_supg_c (material, parameter_b, parameter_u, parameter_w, parameter_mesh_velocity)
Arguments:
  • material : \delta_K
  • parameter_b : \ul{b}
  • parameter_u : \ul{u}
  • parameter_w : \ul{w}
  • parameter_mesh_velocity : \ul{\Vcal}
  • mode : 1 (sensitivity) or 0 (original term value)
arg_shapes = {‘parameter_mesh_velocity’: ‘D’, ‘parameter_b’: ‘D’, ‘material’: ‘1, 1’, ‘parameter_w’: ‘D’, ‘parameter_u’: ‘D’}
arg_types = (‘material’, ‘parameter_b’, ‘parameter_u’, ‘parameter_w’, ‘parameter_mesh_velocity’)
static function()
get_eval_shape(mat, par_b, par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
get_fargs(mat, par_b, par_u, par_w, par_mv, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘d_sd_st_supg_c’
class sfepy.terms.terms_adj_navier_stokes.SUPGCAdjStabilizationTerm(name, arg_str, integral, region, **kwargs)[source]

Adjoint term to SUPG stabilization term dw_st_supg_c.

Definition:

\sum_{K \in \Ical_h}\int_{T_K} \delta_K\ [ ((\ul{v} \cdot \nabla)
\ul{u}) ((\ul{u} \cdot \nabla) \ul{w}) + ((\ul{u} \cdot \nabla)
\ul{u}) ((\ul{v} \cdot \nabla) \ul{w}) ]

Call signature:
dw_st_adj_supg_c (material, virtual, parameter, state)
Arguments:
  • material : \delta_K
  • virtual : \ul{v}
  • state : \ul{w}
  • parameter : \ul{u}
arg_shapes = {‘state’: ‘D’, ‘material’: ‘1, 1’, ‘parameter’: ‘D’, ‘virtual’: (‘D’, ‘state’)}
arg_types = (‘material’, ‘virtual’, ‘parameter’, ‘state’)
static function()
get_fargs(mat, virtual, state, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘dw_st_adj_supg_c’
class sfepy.terms.terms_adj_navier_stokes.SUPGPAdj1StabilizationTerm(name, arg_str, integral, region, **kwargs)[source]

The first adjoint term to SUPG stabilization term dw_st_supg_p.

Definition:

\sum_{K \in \Ical_h}\int_{T_K} \delta_K\ \nabla p (\ul{v} \cdot
\nabla \ul{w})

Call signature:
dw_st_adj1_supg_p (material, virtual, state, parameter)
Arguments:
  • material : \delta_K
  • virtual : \ul{v}
  • state : \ul{w}
  • parameter : p
arg_shapes = {‘state’: ‘D’, ‘material’: ‘1, 1’, ‘parameter’: 1, ‘virtual’: (‘D’, ‘state’)}
arg_types = (‘material’, ‘virtual’, ‘state’, ‘parameter’)
static function()
get_fargs(mat, virtual, state, parameter, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘dw_st_adj1_supg_p’
class sfepy.terms.terms_adj_navier_stokes.SUPGPAdj2StabilizationTerm(name, arg_str, integral, region, **kwargs)[source]

The second adjoint term to SUPG stabilization term dw_st_supg_p as well as adjoint term to PSPG stabilization term dw_st_pspg_c.

Definition:

\sum_{K \in \Ical_h}\int_{T_K} \tau_K\ \nabla r (\ul{v} \cdot \nabla
\ul{u})

Call signature:
dw_st_adj2_supg_p (material, virtual, parameter, state)
Arguments:
  • material : \tau_K
  • virtual : \ul{v}
  • parameter : \ul{u}
  • state : r
arg_shapes = {‘state’: 1, ‘material’: ‘1, 1’, ‘parameter’: ‘D’, ‘virtual’: (‘D’, ‘state’)}
arg_types = (‘material’, ‘virtual’, ‘parameter’, ‘state’)
static function()
get_fargs(mat, virtual, parameter, state, mode=None, term_mode=None, diff_var=None, **kwargs)[source]
name = ‘dw_st_adj2_supg_p’
sfepy.terms.terms_adj_navier_stokes.grad_as_vector(grad)[source]