Beispiel #1
0
    def mesh2d_compute_orthogonalization(
        self,
        project_to_land_boundary_option: ProjectToLandBoundaryOption,
        orthogonalization_parameters: OrthogonalizationParameters,
        selecting_polygon: GeometryList,
        land_boundaries: GeometryList,
    ) -> None:
        """Orthogonalizes the Mesh2d.
        The function modifies the mesh for achieving orthogonality between the edges
        and the segments connecting the face circumcenters.
        The amount of orthogonality is traded against the mesh smoothing (in this case the equality of face areas).

        Args:
            project_to_land_boundary_option (ProjectToLandBoundaryOption): The option to determine how to snap to
                                                                           land boundaries.
            orthogonalization_parameters (OrthogonalizationParameters): The orthogonalization parameters.
            selecting_polygon (GeometryList): The polygon where to perform the orthogonalization.
            land_boundaries (GeometryList): The land boundaries to account for in the orthogonalization process.
        """

        c_orthogonalization_params = (
            COrthogonalizationParameters.from_orthogonalizationparameters(
                orthogonalization_parameters))
        c_selecting_polygon = CGeometryList.from_geometrylist(
            selecting_polygon)
        c_land_boundaries = CGeometryList.from_geometrylist(land_boundaries)

        self._execute_function(
            self.lib.mkernel_mesh2d_compute_orthogonalization,
            self._meshkernelid,
            c_int(project_to_land_boundary_option),
            byref(c_orthogonalization_params),
            byref(c_selecting_polygon),
            byref(c_land_boundaries),
        )
Beispiel #2
0
    def mesh2d_flip_edges(
        self,
        triangulation_required: bool,
        project_to_land_boundary_required: bool,
        selecting_polygon: GeometryList,
        land_boundaries: GeometryList,
    ):
        """Flips mesh2d edges to optimize the mesh smoothness.
        Nodes that are connected to more than six other nodes are typically enclosed by faces of highly non-uniform
        shape and wildly varying areas.

        Args:
            triangulation_required (bool): Whether to triangulate non-triangular cells.
            project_to_land_boundary_required (bool): Whether projection to land boundaries is required.
            selecting_polygon (GeometryList): The polygon where to perform the edge flipping.
            land_boundaries (GeometryList): The land boundaries to account for when flipping the edges.

        """

        c_selecting_polygon = CGeometryList.from_geometrylist(
            selecting_polygon)
        c_land_boundaries = CGeometryList.from_geometrylist(land_boundaries)

        self._execute_function(
            self.lib.mkernel_mesh2d_flip_edges,
            self._meshkernelid,
            c_int(triangulation_required),
            c_int(project_to_land_boundary_required),
            byref(c_selecting_polygon),
            byref(c_land_boundaries),
        )
Beispiel #3
0
    def polygon_refine(
        self,
        polygon: GeometryList,
        first_node: int,
        second_node: int,
        target_edge_length: float,
    ) -> GeometryList:
        """Refines the polygon perimeter between two nodes. This interval is refined to achieve a target edge length.

        Args:
            polygon (GeometryList): The input polygon to refine.
            first_node (int): The first index of the refinement interval.
            second_node (int): The second index of the refinement interval.
            target_edge_length (float): The target interval edge length.

        Returns:
            int: The refined polygon.
        """
        c_polygon = CGeometryList.from_geometrylist(polygon)
        c_n_polygon_nodes = c_int()

        self._execute_function(
            self.lib.mkernel_polygon_count_refine,
            self._meshkernelid,
            byref(c_polygon),
            c_int(first_node),
            c_int(second_node),
            c_double(target_edge_length),
            byref(c_n_polygon_nodes),
        )

        n_coordinates = c_n_polygon_nodes.value

        x_coordinates = np.empty(n_coordinates, dtype=np.double)
        y_coordinates = np.empty(n_coordinates, dtype=np.double)
        refined_polygon = GeometryList(x_coordinates, y_coordinates)

        c_refined_polygon = CGeometryList.from_geometrylist(refined_polygon)

        self._execute_function(
            self.lib.mkernel_polygon_refine,
            self._meshkernelid,
            byref(c_polygon),
            c_int(first_node),
            c_int(second_node),
            c_double(target_edge_length),
            byref(c_refined_polygon),
        )

        return refined_polygon
Beispiel #4
0
    def contacts_compute_boundary(self, node_mask: ndarray,
                                  polygons: GeometryList,
                                  search_radius: float) -> None:
        """Computes Mesh1d-Mesh2d contacts, where Mesh1d nodes are connected to the closest Mesh2d faces at the boundary

        Args:
            node_mask (ndarray): A boolean array describing whether Mesh1d nodes should or
                                 should not be connected
            points (GeometryList): The points selecting the Mesh2d faces to connect.
            search_radius (float): The radius used for searching neighboring Mesh2d faces. If it is equal to the missing
                                   value double, the search radius will be calculated internally.

        """

        node_mask_int = node_mask.astype(np.int32)
        c_node_mask = as_ctypes(node_mask_int)
        c_polygons = CGeometryList.from_geometrylist(polygons)

        self._execute_function(
            self.lib.mkernel_contacts_compute_boundary,
            self._meshkernelid,
            c_node_mask,
            byref(c_polygons),
            c_double(search_radius),
        )
Beispiel #5
0
    def mesh2d_refine_based_on_samples(
        self,
        samples: GeometryList,
        relative_search_radius: float,
        minimum_num_samples: int,
        mesh_refinement_params: MeshRefinementParameters,
    ) -> None:
        """Refines a mesh2d based on samples. Refinement is achieved by successive splits of the face edges.
        The number of successive splits is indicated by the sample value.
        For example:
        - a value of 0 means no split and hence no refinement;
        - a value of 1 means a single split (a quadrilateral face generates 4 faces);
        - a value of 2 two splits (a quadrilateral face generates 16 faces).

        Args:
            samples (GeometryList): The samples.
            relative_search_radius (float): The relative search radius relative to the face size,
                                            used for some interpolation algorithms.
            minimum_num_samples (int): The minimum number of samples used for some averaging algorithms.
            mesh_refinement_params (MeshRefinementParameters): The mesh refinement parameters.
        """

        c_samples = CGeometryList.from_geometrylist(samples)
        c_refinement_params = CMeshRefinementParameters.from_meshrefinementparameters(
            mesh_refinement_params)

        self._execute_function(
            self.lib.mkernel_mesh2d_refine_based_on_samples,
            self._meshkernelid,
            byref(c_samples),
            c_double(relative_search_radius),
            c_int(minimum_num_samples),
            byref(c_refinement_params),
        )
Beispiel #6
0
    def mesh2d_get_mesh_boundaries_as_polygons(self) -> GeometryList:
        """Retrieves the boundaries of a mesh as a series of separated polygons.

        For example, if a mesh has an single inner hole, two polygons will be generated,
        one for the inner boundary and one for the outer boundary.

        Returns:
            GeometryList: The output network boundary polygon.
        """

        # Get number of polygon nodes
        number_of_polygon_nodes = self._mesh2d_count_mesh_boundaries_as_polygons(
        )

        # Create GeometryList instance
        x_coordinates = np.empty(number_of_polygon_nodes, dtype=np.double)
        y_coordinates = np.empty(number_of_polygon_nodes, dtype=np.double)
        geometry_list_out = GeometryList(x_coordinates, y_coordinates)

        # Get mesh boundary
        c_geometry_list_out = CGeometryList.from_geometrylist(
            geometry_list_out)
        self._execute_function(
            self.lib.mkernel_mesh2d_get_mesh_boundaries_as_polygons,
            self._meshkernelid,
            byref(c_geometry_list_out),
        )

        return geometry_list_out
Beispiel #7
0
    def mesh2d_get_nodes_in_polygons(self, geometry_list: GeometryList,
                                     inside: bool) -> ndarray:
        """Gets the indices of the mesh2d nodes selected with a polygon.

        Args:
            geometry_list (GeometryList): The input polygon.
            inside (bool): Selection of the nodes inside the polygon (True) or outside (False).

        Returns:
            ndarray: The integer array describing the selected nodes indices.
        """

        # Get number of mesh nodes
        number_of_mesh_nodes = self._mesh2d_count_nodes_in_polygons(
            geometry_list, inside)

        selected_nodes = np.empty(number_of_mesh_nodes, dtype=np.int32)
        c_selected_nodes = np.ctypeslib.as_ctypes(selected_nodes)
        c_geometry_list = CGeometryList.from_geometrylist(geometry_list)

        # Get selected nodes
        self._execute_function(
            self.lib.mkernel_mesh2d_get_nodes_in_polygons,
            self._meshkernelid,
            byref(c_geometry_list),
            c_int(inside),
            c_selected_nodes,
        )

        return selected_nodes
Beispiel #8
0
    def mesh2d_get_small_flow_edge_centers(
            self, small_flow_edges_length_threshold: float) -> GeometryList:
        """Gets the small mesh2d flow edges centers.
        The flow edges are the edges connecting face circumcenters.

        Args:
            small_flow_edges_length_threshold (float): The configurable length for detecting a small flow edge.

        Returns:
            int: The geometry list with the small flow edge center coordinates.
        """

        n_small_flow_edge_centers = self._mesh2d_count_small_flow_edge_centers(
            small_flow_edges_length_threshold)

        x_coordinates = np.empty(n_small_flow_edge_centers, dtype=np.double)
        y_coordinates = np.empty(n_small_flow_edge_centers, dtype=np.double)
        geometry_list = GeometryList(x_coordinates, y_coordinates)

        c_geometry_list = CGeometryList.from_geometrylist(geometry_list)

        self._execute_function(
            self.lib.mkernel_mesh2d_get_small_flow_edge_centers,
            self._meshkernelid,
            c_double(small_flow_edges_length_threshold),
            byref(c_geometry_list),
        )

        return geometry_list
def test_cgeometrylist_from_geometrylist():
    """Tests `from_geometrylist` of the `CGeometryList` class."""

    x_coordinates = np.array([0.0, 1.0, 2.0, 3.0, 4.0], dtype=np.double)
    y_coordinates = np.array([5.0, 6.0, 7.0, 8.0, 9.0], dtype=np.double)
    values = np.array([10.0, 11.0, 12.0, 13.0, 14.0], dtype=np.double)
    geometry_separator = 15.0
    inner_outer_separator = 16.0

    geometry_list = GeometryList(x_coordinates, y_coordinates)
    geometry_list.values = values
    geometry_list.geometry_separator = geometry_separator
    geometry_list.inner_outer_separator = inner_outer_separator

    c_geometry_list = CGeometryList.from_geometrylist(geometry_list)

    # Get the numpy arrays from the ctypes object
    c_geometry_list_x_coordinates = as_array(c_geometry_list.x_coordinates,
                                             (5, ))
    c_geometry_list_y_coordinates = as_array(c_geometry_list.y_coordinates,
                                             (5, ))
    c_geometry_list_values = as_array(c_geometry_list.values, (5, ))

    assert_array_equal(c_geometry_list_x_coordinates, x_coordinates)
    assert_array_equal(c_geometry_list_y_coordinates, y_coordinates)
    assert_array_equal(c_geometry_list_values, values)

    assert c_geometry_list.geometry_separator == geometry_separator
    assert c_geometry_list.inner_outer_separator == inner_outer_separator
    assert c_geometry_list.n_coordinates == x_coordinates.size
Beispiel #10
0
    def mesh2d_averaging_interpolation(
        self,
        samples: GeometryList,
        location_type: Mesh2dLocation,
        averaging_method: AveragingMethod,
        relative_search_size: float,
        min_samples: int,
    ) -> GeometryList:
        """Performs averaging interpolation of samples.

        Args:
            samples (GeometryList): The samples to interpolate.
            location_type (Mesh2dLocation): The location type on which to interpolate.
            averaging_method (AveragingMethod): The averaging method.
            relative_search_size (float): The relative search size.
            min_samples (int): The minimum number of samples used for some interpolation algorithms to perform
                               a valid interpolation.

        Returns:
            GeometryList: The interpolated samples.
        """
        c_samples = CGeometryList.from_geometrylist(samples)

        number_of_coordinates = c_samples.n_coordinates

        x_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        y_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        values = np.empty(number_of_coordinates, dtype=np.double)
        interpolated_samples = GeometryList(x_coordinates, y_coordinates,
                                            values)

        c_interpolated_samples = CGeometryList.from_geometrylist(
            interpolated_samples)

        self._execute_function(
            self.lib.mkernel_mesh2d_averaging_interpolation,
            self._meshkernelid,
            byref(c_samples),
            c_int(location_type),
            c_int(averaging_method),
            c_double(relative_search_size),
            c_size_t(min_samples),
            byref(c_interpolated_samples),
        )

        return interpolated_samples
Beispiel #11
0
    def get_splines(self, geometry_list: GeometryList,
                    number_of_points_between_nodes: int) -> GeometryList:
        """Get the computed spline points between two corner nodes.

        Args:
            geometry_list (GeometryList): The input corner nodes of the splines.
            number_of_points_between_nodes (int): The number of spline points to generate between two corner nodes.

        Returns:
            GeometryList: The output spline.
        """

        # Allocate space for output
        original_number_of_coordinates = geometry_list.x_coordinates.size
        number_of_coordinates = (
            original_number_of_coordinates * number_of_points_between_nodes -
            number_of_points_between_nodes + original_number_of_coordinates +
            1)
        x_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        y_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        values = np.empty(number_of_coordinates, dtype=np.double)
        geometry_list_out = GeometryList(x_coordinates, y_coordinates, values)

        # Convert to CGeometryList
        c_geometry_list_in = CGeometryList.from_geometrylist(geometry_list)
        c_geometry_list_out = CGeometryList.from_geometrylist(
            geometry_list_out)

        self._execute_function(
            self.lib.mkernel_get_splines,
            byref(c_geometry_list_in),
            byref(c_geometry_list_out),
            c_int(number_of_points_between_nodes),
        )

        return geometry_list_out
Beispiel #12
0
    def polygon_get_included_points(
            self, selecting_polygon: GeometryList,
            selected_polygon: GeometryList) -> GeometryList:
        """Selects the polygon points within another polygon.

        Args:
            selecting_polygon (GeometryList): The selection polygon.
            selected_polygon (GeometryList): The polygon of which to get the selected points.

        Returns:
            GeometryList: The selection result. The selected points are contained in the values array of the returned
                          GeometryList (0.0 not selected, 1.0 selected).
        """

        c_selecting_polygon = CGeometryList.from_geometrylist(
            selecting_polygon)
        c_selected_polygon = CGeometryList.from_geometrylist(selected_polygon)

        n_coordinates = selected_polygon.x_coordinates.size

        x_coordinates = np.empty(n_coordinates, dtype=np.double)
        y_coordinates = np.empty(n_coordinates, dtype=np.double)
        values = np.empty(n_coordinates, dtype=np.double)
        selection = GeometryList(x_coordinates, y_coordinates, values)

        c_selection = CGeometryList.from_geometrylist(selection)

        self._execute_function(
            self.lib.mkernel_polygon_get_included_points,
            self._meshkernelid,
            byref(c_selecting_polygon),
            byref(c_selected_polygon),
            byref(c_selection),
        )

        return selection
Beispiel #13
0
    def mesh2d_make_mesh_from_samples(self,
                                      sample_points: GeometryList) -> None:
        """Makes a triangular mesh from a set of samples, triangulating the sample points.

        Args:
            sample_points (GeometryList): The sample points.
        """

        c_geometry_list = CGeometryList.from_geometrylist(sample_points)

        self._execute_function(
            self.lib.mkernel_mesh2d_make_mesh_from_samples,
            self._meshkernelid,
            byref(c_geometry_list),
        )
Beispiel #14
0
    def mesh2d_make_mesh_from_polygon(self, polygon: GeometryList) -> None:
        """Generates a triangular mesh2d within a polygon. The size of the triangles is determined from the length of
        the polygon edges.

        Args:
            polygon (GeometryList): The polygon.
        """

        c_geometry_list = CGeometryList.from_geometrylist(polygon)

        self._execute_function(
            self.lib.mkernel_mesh2d_make_mesh_from_polygon,
            self._meshkernelid,
            byref(c_geometry_list),
        )
Beispiel #15
0
    def mesh2d_triangulation_interpolation(
        self,
        samples: GeometryList,
        location_type: Mesh2dLocation,
    ) -> GeometryList:
        """Performs triangulation interpolation of samples.

        Args:
            samples (GeometryList): The samples to interpolate.
            location_type (Mesh2dLocation): The location type on which to interpolate.

        Returns:
            GeometryList: The interpolated samples.
        """
        c_samples = CGeometryList.from_geometrylist(samples)

        number_of_coordinates = c_samples.n_coordinates

        x_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        y_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        values = np.empty(number_of_coordinates, dtype=np.double)
        interpolated_samples = GeometryList(x_coordinates, y_coordinates,
                                            values)

        c_interpolated_samples = CGeometryList.from_geometrylist(
            interpolated_samples)

        self._execute_function(
            self.lib.mkernel_mesh2d_triangulation_interpolation,
            self._meshkernelid,
            byref(c_samples),
            c_int(location_type),
            byref(c_interpolated_samples),
        )

        return interpolated_samples
Beispiel #16
0
    def mesh2d_merge_nodes(self, geometry_list: GeometryList,
                           merging_distance: float) -> None:
        """Merges the mesh2d nodes, effectively removing all small edges.

        Args:
            geometry_list (GeometryList): The polygon defining the area where the operation will be performed.
            geometry_list (float): The distance below which two nodes will be merged.
        """
        c_geometry_list = CGeometryList.from_geometrylist(geometry_list)
        self._execute_function(
            self.lib.mkernel_mesh2d_merge_nodes,
            self._meshkernelid,
            byref(c_geometry_list),
            c_double(merging_distance),
        )
Beispiel #17
0
    def contacts_compute_with_points(self, node_mask: ndarray,
                                     points: GeometryList) -> None:
        """Computes Mesh1d-Mesh2d contacts, where Mesh1d nodes are connected to the Mesh2d face mass centers containing
        the input point.

        Args:
            node_mask (ndarray): A boolean array describing whether Mesh1d nodes should or
                                 should not be connected
            points (GeometryList): The points selecting the Mesh2d faces to connect.

        """
        node_mask_int = node_mask.astype(np.int32)
        c_node_mask = as_ctypes(node_mask_int)
        c_points = CGeometryList.from_geometrylist(points)

        self._execute_function(
            self.lib.mkernel_contacts_compute_with_points,
            self._meshkernelid,
            c_node_mask,
            byref(c_points),
        )
Beispiel #18
0
    def contacts_compute_single(self, node_mask: ndarray,
                                polygons: GeometryList) -> None:
        """Computes Mesh1d-Mesh2d contacts, where each single Mesh1d node is connected to one Mesh2d face circumcenter.
        The boundary nodes of Mesh1d (those sharing only one Mesh1d edge) are not connected to any Mesh2d face.

        Args:
            node_mask (ndarray): A boolean array describing whether Mesh1d nodes should or
                                 should not be connected
            polygons (GeometryList): The polygons selecting the area where the contacts will be be generated.
        """

        node_mask_int = node_mask.astype(np.int32)
        c_node_mask = as_ctypes(node_mask_int)
        c_polygons = CGeometryList.from_geometrylist(polygons)

        self._execute_function(
            self.lib.mkernel_contacts_compute_single,
            self._meshkernelid,
            c_node_mask,
            byref(c_polygons),
        )
Beispiel #19
0
    def contacts_compute_with_polygons(self, node_mask: ndarray,
                                       polygons: GeometryList) -> None:
        """Computes Mesh1d-Mesh2d contacts, where a Mesh2d face per polygon is connected to the closest Mesh1d node.

        Args:
            node_mask (ndarray): A boolean array describing whether Mesh1d nodes should or
                                 should not be connected
            polygons (GeometryList): The polygons in which the closest Mesh2d face to a Mesh1d node will be connected.

        """

        node_mask_int = node_mask.astype(np.int32)
        c_node_mask = as_ctypes(node_mask_int)
        c_polygons = CGeometryList.from_geometrylist(polygons)

        self._execute_function(
            self.lib.mkernel_contacts_compute_with_polygons,
            self._meshkernelid,
            c_node_mask,
            byref(c_polygons),
        )
Beispiel #20
0
    def mesh2d_refine_based_on_polygon(
        self,
        polygon: GeometryList,
        mesh_refinement_params: MeshRefinementParameters,
    ) -> None:
        """Refines a mesh2d within a polygon. Refinement is achieved by splitting the edges contained in the polygon in two.

        Args:
            samples (GeometryList): The closed polygon.
            mesh_refinement_params (MeshRefinementParameters): The mesh refinement parameters.
        """

        c_polygon = CGeometryList.from_geometrylist(polygon)
        c_refinement_params = CMeshRefinementParameters.from_meshrefinementparameters(
            mesh_refinement_params)

        self._execute_function(
            self.lib.mkernel_mesh2d_refine_based_on_polygon,
            self._meshkernelid,
            byref(c_polygon),
            byref(c_refinement_params),
        )
Beispiel #21
0
    def mesh2d_get_obtuse_triangles_mass_centers(self) -> GeometryList:
        """Gets the mass centers of obtuse mesh2d triangles.
        Obtuse triangles are those having one angle larger than 90°.

        Returns:
            GeometryList: The geometry list with the mass center coordinates.
        """
        n_obtuse_triangles = self._mesh2d_count_obtuse_triangles()

        x_coordinates = np.empty(n_obtuse_triangles, dtype=np.double)
        y_coordinates = np.empty(n_obtuse_triangles, dtype=np.double)
        geometry_list = GeometryList(x_coordinates, y_coordinates)

        c_geometry_list = CGeometryList.from_geometrylist(geometry_list)

        self._execute_function(
            self.lib.mkernel_mesh2d_get_obtuse_triangles_mass_centers,
            self._meshkernelid,
            byref(c_geometry_list),
        )

        return geometry_list
Beispiel #22
0
    def _mesh2d_count_nodes_in_polygons(self, geometry_list: GeometryList,
                                        inside: int) -> int:
        """For internal use only.

        Counts the number of selected mesh node indices.
        This function should be used by clients before `mesh2d_get_nodes_in_polygons`
        for allocating an integer array storing the selection results.

        Returns:
            int: The number of selected nodes
        """
        c_number_of_mesh_nodes = c_int()
        c_geometry_list = CGeometryList.from_geometrylist(geometry_list)

        # Get number of mesh nodes
        self._execute_function(
            self.lib.mkernel_mesh2d_count_nodes_in_polygons,
            self._meshkernelid,
            byref(c_geometry_list),
            c_int(inside),
            byref(c_number_of_mesh_nodes),
        )
        return c_number_of_mesh_nodes.value
Beispiel #23
0
    def mesh2d_get_smoothness(self):
        """Gets the smoothness, expressed as the ratio between the values of two neighboring faces areas.

        Returns:
            GeometryList: The geometry list with the smoothness values of each edge.
        """

        number_of_coordinates = self._mesh2d_get_dimensions().num_edges

        x_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        y_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        values = np.empty(number_of_coordinates, dtype=np.double)
        geometry_list_out = GeometryList(x_coordinates, y_coordinates, values)

        c_geometry_list_out = CGeometryList.from_geometrylist(
            geometry_list_out)
        self._execute_function(
            self.lib.mkernel_mesh2d_get_smoothness,
            self._meshkernelid,
            byref(c_geometry_list_out),
        )

        return geometry_list_out
Beispiel #24
0
    def mesh2d_delete(
        self,
        geometry_list: GeometryList,
        delete_option: DeleteMeshOption,
        invert_deletion: bool,
    ) -> None:
        """Deletes a mesh in a polygon using several options.

        Args:
            geometry_list (GeometryList): The GeometryList describing the polygon where to perform the operation.
            delete_option (DeleteMeshOption): The option describing the strategy to delete the mesh.
            invert_deletion (bool): Whether or not to invert the deletion.
        """

        c_geometry_list = CGeometryList.from_geometrylist(geometry_list)

        self._execute_function(
            self.lib.mkernel_mesh2d_delete,
            self._meshkernelid,
            byref(c_geometry_list),
            c_int(delete_option),
            c_int(invert_deletion),
        )
Beispiel #25
0
    def mesh2d_get_orthogonality(self) -> GeometryList:
        """Gets the mesh orthogonality, expressed as the ratio between the edges and
        the segments connecting the face circumcenters.

        Returns:
            GeometryList: The geometry list with the orthogonality values of each edge.
        """

        number_of_coordinates = self._mesh2d_get_dimensions().num_edges

        x_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        y_coordinates = np.empty(number_of_coordinates, dtype=np.double)
        values = np.empty(number_of_coordinates, dtype=np.double)
        geometry_list_out = GeometryList(x_coordinates, y_coordinates, values)

        c_geometry_list_out = CGeometryList.from_geometrylist(
            geometry_list_out)
        self._execute_function(
            self.lib.mkernel_mesh2d_get_orthogonality,
            self._meshkernelid,
            byref(c_geometry_list_out),
        )

        return geometry_list_out