library(pliman)
# approximation of the third leaf's perimeter
# 4 harmonics
image_pliman("potato_leaves.jpg", plot = TRUE)
efourier_shape(an = c(-7.34, 1.81, -1.32, 0.50),
bn = c(-113.88, 21.90, -0.31, -6.14),
cn = c(-147.51, -20.89, 0.66, -14.06),
dn = c(-0.48, 2.36, -4.36, 3.03))
Run the code above in your browser using DataLab