Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
halungge committed Nov 21, 2024
1 parent b73c7bf commit c50ec6a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion model/common/src/icon4py/model/common/math/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,7 @@ def dot_product_on_edges(
"""Compute dot product of cartesian vectors (x1, y1, z1) * (x2, y2, z2)"""
return x1 * x2 + y1 * y2 + z1 * z2


@gtx.field_operator
def dot_product_on_cells(
x1: fa.CellField[ta.wpfloat],
Expand All @@ -211,7 +212,6 @@ def dot_product_on_cells(
return x1 * x2 + y1 * y2 + z1 * z2



@gtx.field_operator
def cross_product_on_edges(
x1: fa.EdgeField[ta.wpfloat],
Expand Down Expand Up @@ -263,6 +263,7 @@ def norm2_on_cells(
"""
return sqrt(dot_product_on_cells(x, x, y, y, z, z))


@gtx.field_operator
def normalize_cartesian_vector_on_edges(
v_x: fa.EdgeField[ta.wpfloat], v_y: fa.EdgeField[ta.wpfloat], v_z: fa.EdgeField[ta.wpfloat]
Expand Down Expand Up @@ -444,6 +445,7 @@ def compute_cartesian_coordinates_from_zonal_and_meridional_components_on_edges(
domain={dims.EdgeDim: (horizontal_start, horizontal_end)},
)


@gtx.field_operator
def cartesian_coordinates_from_zonal_and_meridional_components_on_cells(
lat: fa.CellField[ta.wpfloat],
Expand Down

0 comments on commit c50ec6a

Please sign in to comment.