Skip to content

Add possibility of providing triangles while plotting tricontour #12

@thibaultDrt

Description

@thibaultDrt

Hello there,

I revive a ProPlot issue that is quite limiting in my field.

Context

In Matplotlib, it is possible to plot contours or filled contours using unstructured grid with triangles, using tricontour and tricontourf.
The documentation shows that several ways of providing arguments are available :

ax.tricontourf(x, y, z, ...)
ax.tricontourf(x, y, triangles, z, ...)
ax.tricontourf(triangulation, z, ...)
  1. In the first case, no connectivity is provided and a Delaunay triangulation algorithm is used internally to create triangles. When dealing with concave geometries, this algorithm fills the empty spaces with undesired triangles, and therefore requires to provide the connectivities.
  2. In the second case, an array of connectivity is provided, allowing to deal with concave geometries for example.
  3. In the 3rd case, an object Triangulation is provided, which mainly consists of coordinates and connectivities.

The management of the arguments (with or without the triangles connectivities array) is dealt here in matplotlib.

Anomaly in UltraPlot

However, in pro-ultraplot, tricontour and its filled counterpart only considers (x, y) arguments, and forces the Delaunay triangulation algorithm to be used.
It would be great to modify this behaviour and allow to provide the triangles array or triangulation object as argument of the function.

Thanks a lot for the help :)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions