uxarray.Grid.compute_face_node_angles

uxarray.Grid.compute_face_node_angles#

Grid.compute_face_node_angles(*, degrees=False, as_uxarray=False)#

Compute the angles at each node of each face in the grid. Assumes convex faces and a spherical geometry (consistent with other uxarray methods).

Parameters:
  • degrees (bool, defaults to False) – Whether to return angles in degrees (if True) or radians (if False).

  • as_uxarray (bool, defaults to False) – Whether to return a uxarray.DataArray (if True) instead of an xarray.DataArray (if False). If True, equivalent to uxarray.DataArray(self.compute_face_node_angles(…, as_uxarray=False), uxgrid=self).

Returns:

face_node_angles – The internal angles at each node, for each face in the grid. Has ‘n_face’ and ‘n_max_face_nodes’ dimensions, with same size as in self. For faces with fewer than n_max_face_nodes, fill value is np.nan.

Return type:

xr.DataArray or uxarray.UxDataArray (if as_uxarray=True)