Skip to content

Create an R code only version of tripack functions

Umang Majumder edited this page Apr 5, 2022 · 9 revisions

Background

Delaunay triangulation can be useful in the fitting of bivariate surfaces over non-convex regions, and solving of closest node and shortest path problems in the presence of physical barriers (e.g., the shortest water route from Athens to Liverpool or the optimai path of a robot making its mail delivery route on the floor of a business establishment).

Related work

The R package tripack is used by numerous other packages, but it is based on legacy FORTRAN code. The algorithm is documented in Cline and Rena (1990), and it would be helpful for many other people's work to have it natively coded in R.

Details of your coding project

The task for this project is to write an R package, that implements the constrained Delaunay triangulation, that can be used to substitute for the existing tripack package. The package needs to be CRAN-ready and have its own pkgdown site, with a short vignette.

Expected impact

This package will help the alphahull package to remove the dependency on the FORTRAN code, and thus allow it to have a non-ACM license (which is discouraged by CRAN). The new cassowaryr package, for finding unusual shapes in scatterplots, might then be acceptable for CRAN because it will not require the ACM license.

Mentors

Contributors, please contact mentors below after completing at least one of the tests below.

  • EVALUATING MENTOR: Di Cook [email protected] is a developer of the cassowaryr package, and maintainer/author of numerous R packages. She has also co-mentored approximately 10 GSoC projects.
  • MENTOR: Harriet Mason [email protected] is a developer and maintainer of the cassowaryr package and a current PhD student at Monash University.

Tests

Contributors, please do one or more of the following tests before contacting the mentors above.

  • Easy: Write a function to connect any five points into three triangles. The input should be the points, as a matrix, and the output should be a list with two elements, the points, and the edges connecting the points.
  • Medium: Create a small R package, that contains this function, some sample data, that passes R CRAN checks.
  • Hard: Build a pkgdown site complete with a vignette for the package.

Solutions of tests

Contributors, please post a link to your test results here.