Skip to content

Commit

Permalink
Format .jl files
Browse files Browse the repository at this point in the history
  • Loading branch information
schillic authored and github-actions[bot] committed Aug 24, 2024
1 parent 07ce00a commit 5fe5f72
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion src/ConcreteOperations/issubset.jl
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,7 @@ end
function _issubset_constraints_list(S::LazySet, P::LazySet, witness::Bool=false)
@assert dim(S) == dim(P) "incompatible set dimensions $(dim(S)) and $(dim(P))"
@assert ispolyhedral(P) "this inclusion check requires a polyhedral set " *
"on the right-hand side"
"on the right-hand side"

@inbounds for H in constraints_list(P)
if !_leq(ρ(H.a, S), H.b)
Expand Down
2 changes: 1 addition & 1 deletion src/ConcreteOperations/minkowski_difference.jl
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ of disturbance invariant sets for discrete-time linear systems.*
"""
function minkowski_difference(P::LazySet, Q::LazySet)
@assert ispolyhedral(P) "this implementation requires that the first argument " *
"is polyhedral; try overapproximating with an `HPolyhedron`"
"is polyhedral; try overapproximating with an `HPolyhedron`"
@assert isbounded(Q) "this implementation requires that the second " *
"argument is bounded, but it is not"

Expand Down
4 changes: 2 additions & 2 deletions src/ConcreteOperations/minkowski_sum.jl
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ function minkowski_sum(P::LazySet, Q::LazySet;
"but they are $n and $(dim(Q)) respectively"

@assert ispolyhedral(P) && ispolyhedral(Q) "this function requires " *
"polyhedral sets; try overapproximating with an `HPolytope` or " *
"`HPolyhedron` first"
"polyhedral sets; try overapproximating with an `HPolytope` or " *
"`HPolyhedron` first"

if n == 2 && isboundedtype(typeof(P)) && isboundedtype(typeof(Q))
# use vertex representation
Expand Down
10 changes: 5 additions & 5 deletions src/Interfaces/LazySet.jl
Original file line number Diff line number Diff line change
Expand Up @@ -656,7 +656,7 @@ end
function _plot_recipe_3d_polytope(P::LazySet, N=eltype(P))
require(@__MODULE__, :MiniQhull; fun_name="_plot_recipe_3d_polytope")
@assert ispolyhedral(P) && isboundedtype(typeof(P)) "3D plotting is " *
"only available for polytopes"
"only available for polytopes"

vlist, C = delaunay_vlist_connectivity(P; compute_triangles_3d=true)

Expand Down Expand Up @@ -1416,14 +1416,14 @@ end

function tohrep(X::LazySet)
@assert ispolyhedral(X) "cannot compute the constraint representation " *
"of non-polyhedral sets"
"of non-polyhedral sets"

return HPolyhedron(constraints_list(X))
end

function tovrep(X::LazySet)
@assert ispolyhedral(X) "cannot compute the vertex representation of " *
"non-polyhedral sets"
"non-polyhedral sets"

return VPolytope(vertices_list(X))
end
Expand All @@ -1438,7 +1438,7 @@ function linear_map_inverse(A::AbstractMatrix, P::LazySet)
@assert size(A, 1) == dim(P) "an inverse linear map of size $(size(A)) " *
"cannot be applied to a set of dimension $(dim(P))"
@assert ispolyhedral(P) "cannot compute the inverse linear map of " *
"non-polyhedral sets"
"non-polyhedral sets"
constraints = _affine_map_inverse_hrep(A, P)
if isempty(constraints)
return Universe{eltype(P)}(size(A, 2))
Expand All @@ -1453,7 +1453,7 @@ function affine_map_inverse(A::AbstractMatrix, P::LazySet, b::AbstractVector)
"and $(length(b)) cannot be applied to a " *
"set of dimension $(dim(P))"
@assert ispolyhedral(P) "cannot compute the inverse affine map of " *
"non-polyhedral sets"
"non-polyhedral sets"
constraints = _affine_map_inverse_hrep(A, P, b)
if isempty(constraints)
return Universe{eltype(P)}(size(A, 2))
Expand Down
4 changes: 2 additions & 2 deletions src/LazyOperations/Bloating.jl
Original file line number Diff line number Diff line change
Expand Up @@ -200,8 +200,8 @@ We call `constraints_list` on the lazy Minkowski sum with the bloating ball.
"""
function constraints_list(B::Bloating)
@assert ispolyhedral(B) "the constraints list is only available for " *
"polyhedral bloating (which requires a polyhedral base set and the " *
"1-norm or the infinity norm)"
"polyhedral bloating (which requires a polyhedral base set and the " *
"1-norm or the infinity norm)"
if B.ε < 0
throw(ArgumentError("computing the constraints list of a negatively " *
"bloated set is not supported"))
Expand Down

0 comments on commit 5fe5f72

Please sign in to comment.