Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • graph-tool graph-tool
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 54
    • Issues 54
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Artifacts
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar

Admin message

Please use the issue tracker only to report bugs (i.e. errors in the library that need to be fixed) or feature requests.

For questions about how to compile, install or use the library, please use instead the web forum at https://forum.skewed.de/c/graph-tool.


(If unsure, use the forum first.)


IMPORTANT: When opening new issues, please choose the BUG template from the drop-down menu, and fill out the required information.

  • Tiago Peixoto
  • graph-toolgraph-tool
  • Issues
  • #299
Closed
Open
Issue created May 05, 2016 by Pietro Battiston@toobaz

Obtaining the triadic closure of a Graph with graph-tool

From http://stackoverflow.com/questions/37029516/obtaining-the-triadic-closure-of-a-graph-with-graph-tool

graph_tool.topology contains transitive_closure, which is basically the "infinite-th" power of the adjacency matrix: what it would be nice to obtain is the second, or in general the k-th, power.

I think it would be nice to implement this as

graph_tool.topology.transitive_closure(g, k=np.inf)

where not passing k would result in the current behaviour while passing a (positive integer) value of k would yield what I ask (e.g. k=1 would yield g itself).

However I don't think that boost provides a ready solution. Maybe it could be added? It may make sense also for finitek to go through the condensation graph, though I have no idea how much more efficient it is than just taking the k-th power of the (boolean version of) the adjacency matrix.

Assignee
Assign to
Time tracking