TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: HypergraphZ – A Hypergraph Implementation in Zig

65 pointsby yamafaktory9 months ago

5 comments

samatman8 months ago
I see that this is a second implementation, the first being in Rust: <a href="https:&#x2F;&#x2F;github.com&#x2F;yamafaktory&#x2F;hypergraph">https:&#x2F;&#x2F;github.com&#x2F;yamafaktory&#x2F;hypergraph</a><p>I&#x27;ve found that Zig is an excellent tool for implementing data-structure-oriented libraries. Comptime genericity is simple to understand and use, providing a C interface is very easy, and libraries take an allocator, so any memory-safety issues are the consumer&#x27;s problem. If you want to use it from a memory-safe language, well, all of those have C FFIs so far as I know, Rust very much included, so you can.<p>A hypergraph is clearly a data structure which demands a lot of cyclic references, no getting around that, so I&#x27;m curious: can you compare and contrast the experience of implementing this in Rust vs. Zig?
评论 #41513946 未加载
评论 #41515723 未加载
评论 #41516189 未加载
评论 #41513823 未加载
reaanb28 months ago
How does this compare to a relational database, where hyperedges are represented by tables and vertices by values?
评论 #41514077 未加载
bigtuna7118 months ago
Really cool! I would be interested in seeing a hypergraph isomorphism algorithm implemented in Zig.
redbell8 months ago
I don&#x27;t know why, but I feel <i>Zigergraph</i> would be a meaningful name :)
评论 #41518300 未加载
FjordWarden8 months ago
Do you think this can be useful for a computational algebra system?
评论 #41514884 未加载