tinycodinglm / math /math-0163.jsonl
winapiadmin's picture
Upload folder using huggingface_hub (part 16)
d517dc9 verified
|
Raw History Blame
805 Bytes
{"type": "session", "harness": "opencode", "id": "math-0163", "name": "Network Flow Algorithms"}
{"type": "message", "message": {"role": "system", "content": "You are an expert mathematician and programmer."}}
{"type": "message", "message": {"role": "user", "content": "Explain max flow algorithms"}}
{"type": "message", "message": {"role": "assistant", "content": "Ford-Fulkerson: augmenting paths in residual graph. O(E*|max_flow|).\nEdmonds-Karp: BFS shortest augmenting path. O(VE^2).\nDinic's: blocking flow with BFS level graph + DFS. O(V^2*E), O(V*E) unit capacities.\nPush-relabel: O(V^2*E) worst, often faster. Preflow + push + relabel.\nMin-cut = max-flow theorem.\nApplications: bipartite matching (source->left, right->sink, cap=1), vertex cover, project selection, image segmentation."}}