14template <linalg::RnSpace Space>
18template <linalg::RnSpace Space>
22template <linalg::RnSpace Dom, linalg::RnSpace Codom>
34template <
typename Meta,
typename Child>
44 using Mat = linalg::Matrix<T, M, N>;
45 using Bias = linalg::Vector<T, M>;
46 using Space = linalg::Matrix<T, 1, N>;
66 for (std::size_t
i = 0;
i <
M; ++
i)
82 for (std::size_t
i = 0;
i <
M; ++
i) {
86 if (!
half.contains(x,
tol))
return false;
106 template <linalg::SquareMatrix Mat>
107 requires(std::same_as<T, linalg::matrix_scalar_t<Mat>> &&
108 linalg::mat_cols_v<Mat> ==
N)
110 const auto&
U = map.linear_part();
111 const auto&
trans = map.translation();
113 const auto [
U_inv, event] = linalg::MatrixInverse<Mat>()(
U);
114 static_cast<void>(event);
128 template <
typename Other>
130 return other.self().A ==
A &&
other.self().b ==
b;
143 template <AtomType Type, conic::BuilderLike Builder>
151 linalg::mat_cols_v<
decltype(
child_coord.linear_part())>;
153 "Convex set domain does not equal the child coordinate "
154 "linear map's codomain in size");
156 const auto map = affine::AffineMap<decltype(A)>(
T(-1) *
A,
b);
158 const auto cones = std::make_tuple(
rplus);
170template <
typename Mat,
typename Bias,
typename Child>
173 linalg::Matrix<dom_type_t<meta_codom_t<atom_meta_t<Child>>>,
174 1, linalg::mat_rows_v<Mat>>>,
constexpr std::size_t dom_size_v
linalg::remove_cvref_t< T > atom_decay_t
normalize atom-facing types to a stable internal form.
Atom-local canonical emission bundle.
forward decl for nonneg orthant cone
static constexpr std::size_t M
Codomain dimension.
ChildrenT children
Tuple of normalized child atoms.
dom_point_t< Domain > PointT
Point type accepted by the atom domain.
dom_type_t< Domain > T
Scalar field for the atom domain.
static constexpr std::size_t N
Domain dimension.
Domain wrapper with a static sign label.
forward declaration of convex set
forward declaration of halfspace
forward declaration of polyhedron set
constexpr Polyhedron(const Mat &A_in, const Bias &b_in, const Child &child_in)
CTOR for polyhedron set.
constexpr bool is_well_formed() const
is_well_formed implementation
constexpr auto transform_impl(const affine::AffineMap< Mat > &map) const
transform polyhedron by affine map
linalg::Matrix< T, 1, N > Space
Mat A
member variables in the polyhedron
constexpr bool is_equal_impl(const Other &other) const
equality comparison
linalg::Vector< T, M > Bias
constexpr auto canonicalize_set(const Builder &builder) const
canonicalize impl
constexpr bool contains_impl(const PointT &x, T tol) const
check if candidate vector is in the set
linalg::Matrix< T, M, N > Mat
bring into scope type traits from MatA