BitMagic-C++: svsample05.cpp File Reference

BitMagic-C++

Typedefs | Functions
svsample05.cpp File Reference

Example: sparse_vector<> used for set 2 set remapping (theory of groups Image) More...

`#include <iostream>`
`#include <vector>`
`#include "bm.h"`
`#include "bmsparsevec.h"`
`#include "bmsparsevec_algo.h"`
Include dependency graph for svsample05.cpp:

Go to the source code of this file.

## Typedefs
typedef bm::sparse_vector< bm::id_t, bm::bvector<> > | sparse_vector_u32

## Functions
static void | print_svector (const sparse_vector_u32 &sv)
void | print_bvector (const bm::bvector<> &bv)
int | main (void)

## Detailed Description

Example: sparse_vector<> used for set 2 set remapping (theory of groups Image)

Definition in file svsample05.cpp.

## Typedef Documentation

## ◆ sparse_vector_u32

typedef bm::sparse_vector<bm::id_t, bm::bvector<> > sparse_vector_u32

Examples
  svsample05.cpp.

Definition at line 44 of file svsample05.cpp.

## Function Documentation

## ◆ main()

int main | ( | void |  | ) |

Examples
  svsample05.cpp.

Definition at line 86 of file svsample05.cpp.

References print_bvector(), print_svector(), bm::set2set_11_transform< SV >::remap(), bm::set2set_11_transform< SV >::run(), bm::sparse_vector< Val, BV >::set(), and bm::use_null.

## ◆ print_bvector()

void print_bvector | ( | const bm::bvector<> & | bv | ) |
| inline

Examples
  svsample05.cpp.

Definition at line 74 of file svsample05.cpp.

References bm::bvector< Alloc >::count(), bm::bvector< Alloc >::first(), and bm::bvector< Alloc >::iterator_base::valid().

Referenced by main().

## ◆ print_svector()

static void print_svector | ( | const sparse_vector_u32 & | sv | ) |
| static

Definition at line 47 of file svsample05.cpp.

References bm::sparse_vector< Val, BV >::at(), bm::base_sparse_vector< Val, BV, MAX_SIZE >::is_null(), and bm::sparse_vector< Val, BV >::size().

Referenced by main().