
PDF Publication Title:
Text from PDF Page: 159
dfs dfs Figure 6.2 – MatlabBGL architecture. MatlabBGL consists of four compo- nents: m-files, mex-files, libmbgl, and Boost graph library functions. See the text for a description of how data flows through these compo- nents. 6.3 ⋅ matlabbgl 137 bfs mst bfs primmst M code Sparse Matrix Matlab libmbgl get the graph stored by out-edges in the Matlab data structure, and forwards the information to the dfs_mex.c mex-file. By providing an optional argu- ment to the function, both the check and the transpose can be eliminated for the fastest performance. The mex-file extracts the compressed sparse column arrays for the sparse matrix, which corresponds to a compressed out-edge list representation of the graph, and sends the information to the libmbgl function depth_first_search. The libmbgl functions implement wrappers around Boost functions on compressed sparse row arrays and expose them via a C calling convention. This library is further described in section 6.3.3. For the depth_first_search function, the wrapper takes the compressed sparse row arrays and instantiates a csr_graph type that implements the Ver- texListGraph, IncidenceGraph, EdgeListGraph, and AdjacencyGraph concepts directly on the compressed sparse row arrays. With the csr_graph object, the libmbgl wrapper calls a Boost graph library function. Throughout this entire process, the only copy of the data occurs when the initial sparse matrix is transposed to store the data by out-edges (rows) instead of in-edges (columns).6 Thus far, the interface between the libraries is only complicated by the layers of abstraction. Although maintaining three layers (m-files, mex-files, and libmbgl) may seem unnecessary, it simplifies calling conventions across multiple platforms. The m-files call mex-files, which Matlab always supports. The mex-files call functions in libmbgl with a C calling convention, which is also extremely portable. And the C functions interface with the Boost graph library. We discuss other reasons to keep libmbgl separate from the mex files in the next section. The most complicated piece of the interface is the csr_graph object. This object is itself a generic object because it must support both 64-bit and 32-bit index types on the compressed sparse row arrays. Furthermore, it supports 6 Some Boost graph functions make a copy of the graph inside the algo- rithm. We can do nothing about these copies without modifying the BGL itself. extern c code CSR Graph mex code c++ code CSR Graph BoostPDF Image | Instagram Cheat Sheet
PDF Search Title:
Instagram Cheat SheetOriginal File Name Searched:
pagerank-sensitivity-thesis-online.pdfDIY PDF Search: Google It | Yahoo | Bing
Cruise Ship Reviews | Luxury Resort | Jet | Yacht | and Travel Tech More Info
Cruising Review Topics and Articles More Info
Software based on Filemaker for the travel industry More Info
The Burgenstock Resort: Reviews on CruisingReview website... More Info
Resort Reviews: World Class resorts... More Info
The Riffelalp Resort: Reviews on CruisingReview website... More Info
| CONTACT TEL: 608-238-6001 Email: greg@cruisingreview.com | RSS | AMP |