sierpinski_overlay: Overlay a Raster with a Sierpinski Mask

Description Usage Arguments Value

Description

This constructs a "middle-ninths" Sierpinski gasket of depth n, starting from a given Raster*.

Usage

1
2
sierpinski_overlay(layer, box = sp::bbox(layer),
  n = floor(log(max(nrow(layer), ncol(layer))/log(3))), random = FALSE)

Arguments

layer

A Raster* object.

box

The bounding box to Cantor-ize.

n

The number of iterations.

random

Choose edges randomly or at (1/3,2/3)?

Value

A Raster* of the same form as the input.


petrelharp/landsim documentation built on May 25, 2019, 2:53 a.m.