yog/dag/algorithms
⚠️ Deprecated Module
This module has been renamed to yog/dag/algorithm (singular).
Please update your imports to use yog/dag/algorithm instead.
This module will be removed in a future version.
Types
pub type Direction =
algorithm.Direction
Values
pub fn count_reachability(
dag: model.Dag(n, e),
direction: algorithm.Direction,
) -> dict.Dict(Int, Int)
Deprecated: Use yog/dag/algorithm.count_reachability instead
Counts the number of ancestors or descendants for every node.
@deprecated Use yog/dag/algorithm.count_reachability instead
pub fn longest_path(dag: model.Dag(n, Int)) -> List(Int)
Deprecated: Use yog/dag/algorithm.longest_path instead
Finds the longest path (critical path) in a weighted DAG.
@deprecated Use yog/dag/algorithm.longest_path instead
pub fn lowest_common_ancestors(
dag: model.Dag(n, e),
node_a: Int,
node_b: Int,
) -> List(Int)
Deprecated: Use yog/dag/algorithm.lowest_common_ancestors instead
Finds the lowest common ancestors (LCAs) of two nodes.
@deprecated Use yog/dag/algorithm.lowest_common_ancestors instead
pub fn shortest_path(
dag: model.Dag(n, Int),
from start: Int,
to goal: Int,
) -> option.Option(utils.Path(Int))
Deprecated: Use yog/dag/algorithm.shortest_path instead
Finds the shortest path between two specific nodes in a weighted DAG.
@deprecated Use yog/dag/algorithm.shortest_path instead
pub fn topological_sort(dag: model.Dag(n, e)) -> List(Int)
Deprecated: Use yog/dag/algorithm.topological_sort instead
Returns a topological ordering of all nodes in the DAG.
@deprecated Use yog/dag/algorithm.topological_sort instead
pub fn transitive_closure(
dag: model.Dag(n, e),
with merge_fn: fn(e, e) -> e,
) -> model.Dag(n, e)
Deprecated: Use yog/dag/algorithm.transitive_closure instead
Computes the transitive closure of a DAG.
@deprecated Use yog/dag/algorithm.transitive_closure instead