$*$-separation
star_separation — Method
star_separation(H::Graph{Directed}, i::Vertex, j::Vertex, K::Vector{Vertex})Tests whether node i is $\star$-separated from j in H given the nodes in K and returns an appropriate boolean.
$C^*$-separation
Let $(G, C)$ be a weighted DAG with vertex set~$V$ and (L \subseteq V). The critical DAG $G^\ast_{C,L}$ is the DAG on $V$ such that $i \to j$ whenever $i$ and $j$ are connected via a directed path, and no critical path from $i$ to $j$ in $G$ intersects $L$.
Two nodes $i$ and $j$ are $C^\ast$-connected given $L$ if there exists a path from $i$ to $j$ in $G^\ast_{C, L}$ of the following form
where an orange node is called a collider and must belong to $L$. If no such path exists, then $i$ and $j$ are $C^\ast$-separated given $L$ which is denoted $[i\perp_{C^*} j \mid L$.
cstar_separation — Method
cstar_separation(G::Graph{Directed}, C, i::Vertex, j::Vertex, K::Vector{Vertex})Tests whether i is $C^\star$-separated from j in G given the nodes in K and weights C on G.
cstar_separation — Method
cstar_separation(G::Graph{Directed}, W::AbstractVector{<:RingElement}, i::Vertex, j::Vertex, K::Vector{Vertex})Tests whether i is $C^\star$-separated from j in G given the nodes in K and weights W on G.
cstar_separation — Method
cstar_separation(G::Graph{Directed}, i::Vertex, j::Vertex, K::Vector{Vertex})Tests whether i is $C^\star$-separated from j in G given the nodes in K and constant weights on G.
Maxoids
For a directed graph $G$ on $d$ nodes with weights given by a vector $W\in\mathbb{R}^E$ or by a matrix $C\in\mathbb{T}^{d\times d}$, we call the collection of $C^*$-separation statements the maxoid of $(G,C)$.
maxoid — Method
maxoid(G::Graph{Directed}, C)Computes the maxoid of G given the weights C.
Examples
julia> G = complete_DAG(3)
Directed graph with 3 nodes and the following edges:
(1, 2)(1, 3)(2, 3)
julia> C = weights_to_tropical_matrix(G,[0,-1,0])
[-infty (0) (-1)]
[-infty -infty (0)]
[-infty -infty -infty]
julia> maxoid(G,C)
1-element Vector{CIStmt}:
[1 _||_ 3 | 2]
There is also function to output a maxoid in a compact representation suitable for processing with a SMT solvers or the likes.
ci_string — Method
ci_string(G::Graph{Directed}, C)Prints the gaussoids.de-compatible binary string representing the maxoid for G with weights C.
We also provide functions to list all maxoids arising from a graph or a family of graphs.
all_maxoids — Method
all_maxoids(G; generic_only = false)Returns all maxoids that can arise from weights on G. If generic_only is true, then returns only the generic maxoids for G.
Examples
julia> G = graph_from_edges(Directed, [[1,2],[2,3]])
Directed graph with 3 nodes and the following edges:
(1, 2)(2, 3)
julia> all_maxoids(G)
2-element Vector{Vector{CIStmt}}}:
[[1 _||_ 3 | 2]]
[]
all_maxoids — Method
all_maxoids(G::AbstractVector{Graph{Directed}}; generic_only = false)Returns all maxoids that can arise from any graph in G. If generic_only is true, then returns only the generic maxoids.
These functions also exist for the same type of output from ci_string.
all_maxoids_as_ci_string — Method
all_maxoids_as_ci_string(G; generic_only = false)Returns all maxoids that can arise from weights on G as gaussoids.de-compatible binary string. If generic_only is true, then returns only the generic maxoids for G.
all_maxoids_as_ci_string — Method
all_maxoids_as_ci_string(G::AbstractVector{Graph{Directed}}; generic_only = false)Returns all maxoids that can arise from weights on any graph in G as gaussoids.de-compatible binary string. If generic_only is true, then returns only the generic maxoids for G.