Template Struct BatchQP

Struct Documentation

template<typename T, typename I>
struct BatchQP

Public Functions

inline BatchQP(long unsigned int batchSize)
BatchQP(const BatchQP&) = delete
BatchQP &operator=(const BatchQP&) = delete
BatchQP(BatchQP&&) = default
BatchQP &operator=(BatchQP&&) = default
inline QP<T, I> &init_qp_in_place(sparse::isize dim, sparse::isize n_eq, sparse::isize n_in)

Init a QP in place and return a reference to it

inline void insert(QP<T, I> &qp)

    Init a QP in place and return a reference to it
   &zwj;/
QP<T, I>& init_qp_in_place(const sparse::SparseMat<bool, I>& H, const sparse::SparseMat<bool, I>& A, const sparse::SparseMat<bool, I>& C) { qp_vector.emplace_back(H.rows(), A.rows(), C.rows()); auto& qp = qp_vector.back(); m_size++; return qp; };

/*! Inserts a qp to the end of qp_vector

inline QP<T, I> &get(isize i)

Access QP at position i

inline const QP<T, I> &get(isize i) const

Access QP at position i

inline QP<T, I> &operator[](isize i)

Access QP at position i

inline const QP<T, I> &operator[](isize i) const

Access QP at position i

inline sparse::isize size()

Public Members

std::vector<QP<T, I>> qp_vector

A vector of QP aligned of size BatchSize specified by the user.

sparse::isize m_size