1

I'm trying to generate an application that solves the bipartite assignment problem via the auction algorithm with the boost graph library. I found it possible to characterize vertices and edges with multiple properties using the boundle properties. But since the auction algorithm envolve two types of entities, persons and items, I was wondering if there was the possibility of generating more than one characterization of vertices in order to suppor this distinction.

Thanks for the help.

zulle99
  • 51
  • 7

1 Answers1

1

This question is overly broad, but let me try to provide some helpful pointers.

But since the auction algorithm [i]nvolve two types of entities, persons and items, I was wondering if there was the possibility of generating more than one characterization of vertices in order to suppor[t] this distinction.

It think "But" can be dropped.

Answering the question, it seems obvious that you can include a type discriminator, like:

 struct VertexProperties {
      int multiple;
      std::string characterizing, properties;
      // for auction algorithm:
      bool isPersonEntity;
      // or e.g.
      enum {Person, Item} entityType;
 };

Here's several answers that show such classifications in action using BGL:

sehe
  • 374,641
  • 47
  • 450
  • 633
  • Wow I did't expect such huge answer. [Graph with two types of nodes](https://stackoverflow.com/questions/45484144/graph-with-two-types-of-nodes/45504948#45504948) was what I was loocking for, nevertheless thanks a lot also for the others suggestions! – zulle99 Jul 19 '22 at 09:40
  • If you make the question more focused (e.g. including self-contained exanple) answers can be much shorter :) Glad it was of help – sehe Jul 19 '22 at 09:53