Engineering Papers⌕ Search

Engineering topics

Deweese, Kevin

Publications and source records attributed to Deweese, Kevin.

NWGraph: A Library of Generic Graph Algorithms and Data Structures in C++20

The C++ Standard Library is a valuable collection of generic algorithms and data structures that improves the usability and reliability of C++ software. Graph algorithms and data structures are notably absent from the standard library, and previous attempts to fill this gap have not gained widespread adoption. In this paper we show that the richness of graph algorithms and data structures can in fact be captured by straightforward composition of existing C++ mechanisms. Generic programming is algorithm-oriented. Accordingly, we apply a systematic approach to analyzing a broad set of graph algorithms, “lift” unnecessary constraints from them, and organize the resulting set of minimal common type requirements, i.e., concepts, for defining their interfaces. By using the newly available ranges and concepts in C++20, the type requirements for generic graph algorithms can be succinctly expressed. The generic algorithms and data structures resulting from our analysis are realized in NWGraph, in a modern, composable, and extensible C++ library.

graphs and networks, programming language, C++20↗

pnnl/NWGraph

NWGraph aims to fill the role of a reusable library of generic graph algorithms for C++, similar to the algorithms available in the standard template library (STL) in C++. The library draws lessons learned from Boost Graph Library (BGL) and other libraries (PBGL, Galois, Gunrock, GraphX etc.), the evolution of the C++ language, and the evolution of C++ practice over the last 20 years.

Lumsdaine, Andrew↗