is_feasible_point: Determine If A Point Is In Ellipse Overlap

Description Usage Arguments Details Value See Also Examples

View source: R/feasible_point.R

Description

is_feasible_point will determine if a given point is in the interior of the intersection of one or more fully specified ellipes.

Usage

1
is_feasible_point(point, ell)

Arguments

point

a numeric of length equal to the dimensions of the ellipses in ell.

ell

a list of at least one ellipse; see wrangle_ellipse.

Details

Given a point is_feasible_point will check if this point is in the intersection of the list of ellipses ell. Note that this function will not check if the intersection is non-empty.

Value

is_feasible_point returns an object of class "is_feasible_point". This object is a list containing the following components:

point

the inputted point.

fasible

logical; is TRUE when the point x is in the interior of all ellipses.

distance

a data.frame with the distance from x to the center of each ellipse, the radius of each ellipse and a logical indicator, which is TRUE when x is an element in the ellipse.

call

the match call.

See Also

wrangle_ellipse for detailed on ellipse parameterization.

Examples

1
2
3
4
5
e1 <- list("c" = c(1,1), "P" = matrix(c(3,1,1,2), ncol = 2), "r" = 2)
e2 <- list("c" = c(0,2), "S" = matrix(c(4,1,1,1), ncol = 2), "r" = 3)

is_feasible_point(c(1.1,0.9), e1)
is_feasible_point(c(1,0), list(e1, e2))

fellov documentation built on Feb. 21, 2020, 5:07 p.m.