Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ConvexSet: make σ a required method #3735

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions docs/src/lib/interfaces/ConvexSet.md
Original file line number Diff line number Diff line change
@@ -15,6 +15,18 @@ Every convex set in this library implements this interface.
ConvexSet
```

This interface requires to implement the following function:

```@meta
CurrentModule = LazySets.API
```
```@docs; canonical=false
σ(::AbstractVector, ::LazySet)
```
```@meta
CurrentModule = LazySets
```

This interface defines the following functions (undocumented):

```@meta
6 changes: 6 additions & 0 deletions src/Interfaces/ConvexSet.jl
Original file line number Diff line number Diff line change
@@ -6,6 +6,12 @@ export ConvexSet
Abstract type for convex sets, i.e., sets characterized by a (possibly infinite)
intersection of halfspaces, or equivalently, sets ``S`` such that for any two
elements ``x, y ∈ S`` and ``0 ≤ λ ≤ 1`` it holds that ``λ·x + (1-λ)·y ∈ S``.

### Notes

Every concrete `ConvexSet` must define the following function:

- `σ(::AbstractVector, ::LazySet)` -- return a support vector in the given direction
"""
abstract type ConvexSet{N} <: LazySet{N} end