#include <iostream>
#include <cla3p/perms.hpp>
{
cla3p::int_t n = P.
size();
for(cla3p::int_t i = 0; i < n; i++)
ret[i * n + P(i)] = 1;
return ret;
}
int main()
{
std::cout << P.
info(
"P") << P;
cla3p::int_t *P4x4 = permToDense(P);
std::cout << "As a dense matrix:\n";
return 0;
}
std::string info(const std::string &header="") const
Get information about the vector.
static PxMatrix< int_t > random(int_t n)
void i_free(void *ptr)
Default deallocator for cla3p allocations.
T_Elem * i_calloc_t(std::size_t nmemb)
Type-safe allocator for zero-initialized storage.
Definition imalloc.hpp:80
@ Full
Definition enums.hpp:55
PxMatrix< int_t > PiMatrix
Integer Permutation Matrix.
Definition perms.hpp:29