alphahull (version 2.2)

rkoch: Random generation on a Koch snowflake curve

Description

This function generates ramdom points from a uniform distribution on a Koch snowflake.

Usage

rkoch(n, side = 3, niter = 5)

Arguments

n

Number of observations.

side

Side length of the initial equilateral triangle of the Koch snowflake curve.

niter

Number of iterations in the development of the snowflake curve.

Value

A 2-column matrix with the coordinates of generated points.

See Also

koch.

Examples

Run this code
# NOT RUN {
unifkoch <- rkoch(2000, side = 1, niter = 3)
plot(unifkoch, asp = TRUE)
# }

Run the code above in your browser using DataLab