Skip to main content
Algorithms for Molecular Biology : AMB logoLink to Algorithms for Molecular Biology : AMB
. 2017 Mar 11;12:4. doi: 10.1186/s13015-017-0096-x

Approximating the correction of weighted and unweighted orthology and paralogy relations

Riccardo Dondi 1,, Manuel Lafond 2, Nadia El-Mabrouk 3
PMCID: PMC5346272  PMID: 28293276

Abstract

Background

Given a gene family, the relations between genes (orthology/paralogy), are represented by a relation graph, where edges connect pairs of orthologous genes and “missing” edges represent paralogs. While a gene tree directly induces a relation graph, the converse is not always true. Indeed, a relation graph is not necessarily “satisfiable”, i.e. does not necessarily correspond to a gene tree. And even if that holds, it may not be “consistent”, i.e. the tree may not represent a true history in agreement with a species tree. Previous studies have addressed the problem of correcting a relation graph for satisfiability and consistency. Here we consider the weighted version of the problem, where a degree of confidence is assigned to each orthology or paralogy relation. We also consider a maximization variant of the unweighted version of the problem.

Results

We provide complexity and algorithmic results for the approximation of the considered problems. We show that minimizing the correction of a weighted graph does not admit a constant factor approximation algorithm assuming the unique game conjecture, and we give an n-approximation algorithm, n being the number of vertices in the graph. We also provide polynomial time approximation schemes for the maximization variant for unweighted graphs.

Conclusions

We provided complexity and algorithmic results for variants of the problem of correcting a relation graph for satisfiability and consistency. For the maximization variants we were able to design polynomial time approximation schemes, while for the weighted minimization variants we were able to provide the first inapproximability results.

Keywords: Orthology, Paralogy, Approximation algorithms, Gene tree, Species tree

Background

Genes are the basic molecular units of heredity holding the information for producing all proteins required to build and maintain cells. They are the key for understanding genetic diversity, adaptation to environmental variation, drug resistance, and many other genetic features. Therefore, a first step of most genomic studies is to group genes into families. Gene families are usually inferred from sequence similarity, the underlying idea being that similar sequences reflect homologous genes that have diverged from a common ancestral sequence.

However, homology alone is not sufficient to decipher the properties of genes. Given a gene family, it is important to discriminate between two types of homologs: orthologs being gene copies originating from a speciation event, and paralogs originating from a duplication event. According to the orthology conjecture [1], orthologous genes are expected to be more similar in function than paralogs.

Various methods have been developed to discriminate between orthologous and paralogous genes. Tree-based methods consist in first constructing a phylogenetic tree for the gene family, and then, given a species tree, applying a reconciliation approach for inferring speciation and duplication nodes [2]. On the other hand, tree-free methods are based on gene clustering according to sequence similarity (c.f. for example the COG database [3], OrthoMCL [4], InParanoid [5], Proteinortho [6]), synteny [7, 8] or functional annotation of genes [9]. Results of these methods are pairwise orthology relations, or groups of orthologs, that can be represented as relation graphs, where vertices are genes and edges represent orthology relations between genes. Assuming a full inference of pairwise orthology relations, “missing” edges of the relation graph represent paralogy. In addition, as different inference methods may lead to different predictions, instead of a yes or no orthology assignment, existing methods can rather motivate a way of assigning a score to a given relation [10], leading to a weighted relation graph. For example, orthology predictions with OrthoMCL [4] are based on a weighted graph, where edge weights are related to the sequence similarity score of the adjacent genes, while InParanoid [5] provides a confidence value that shows how closely related a paralog is to its “seed ortholog”. Surprisingly, as far as we know, weighted orthology/paralogy relation graphs have not been formally considered in the literature.

While a gene tree induces a set of relations betwen genes, the converse is not always true, as a set of relations may or may not represent a valid history for the gene family. Two underlying questions are: (1) is the set of relations “satisfiable” i.e. is there a tree, with internal nodes labeled as duplication or speciation, containing them all? (2) is the set of relations “S-consistent” with the known species tree S, i.e. is there a tree containing the relations that is a “valid” gene tree “in agreement” with S? Polynomial-time algorithms exist for deciding satisfiability and S-consistency for a full [1113] or partial [10] set of pairwise gene relations.

In this paper, we address both the weighted and unweighted variants of the full relation graph correction problem. First, for a full weighted relation graph R, we consider two minimization versions for the problem of correcting the graph by minimizing edit operations, i.e. adding or removing edges of minimum total weight, so that it represents a satisfiable or S-consistent set of relations. Then, we consider two maximization versions for the unweighted variant were we are given a full unweighted relation graph that has to be corrected with edit operations, so that the maximum number of relations is not modified.

In the unweighted case, the minimization variant of the satisfiability correction problem reduces to editing a minimum number of edges of R in order to make it P4-free, which is known to be NP-hard [14]. In [13], an integer linear programming formulation is used to correct relation graphs of small size, which is also applicable to weighted graphs. In [15], the authors propose an approximation algorithm of factor 4Δ, where Δ is the maximum degree of the input graph. The algorithm, however, offers no guarantees in the case of weighted graphs, as there are weighted instances on which the correction is arbitrarily far from optimal. It is shown in [16] that the minimum edge editing problem cannot be approximated within an “additive” factor of n2-ϵ, for any ϵ>0. Yet, the authors give a class of polynomial time algorithms that are approximable within an additive factor of ϵn2, for any ϵ>0. This implies a constant factor algorithm for graphs with an edit distance of Ω(n2), but offers no guarantee in the other cases. Moreover, this algorithm only applies to unweighted graphs, and does not consider that two genes from the same species must remain paralogs. Finally in [14], parameterized versions of the algorithm are explored. As for the S-consistency correction problem, we proved in a previous paper [17] that it is NP-hard, which is the only result so far.

We show in, “Hardness of approximation of minimum weighted editing for satisfiability and consistency” section, that the weighted satisfiability and S-consistency problems are not approximable within a constant factor, assuming the unique games conjecture. We complement this result by showing in “A bounded approximation algorithm for minimum weighted editing for satisfiability and consistency” section that they can be approximated within a factor of n (the number of vertices of the relation graph). The maximization variants for unweighted graphs are then considered in “PTASs for maximum CoGraph editing and maximum consistency editing” section. We show that a result in [16] implies a polynomial time approximation scheme (PTAS) for satisfiability. Furthermore, we prove that, by applying more involved arguments, a PTAS also exists for the S-consistency problem. We conclude the paper with some open problems.

Trees and orthology relations

A graph H is denoted H=(VH,EH), where VH is its set of vertices (or nodes if H is a tree) and EH its set of edges. If H is a tree, degree one nodes are leaves.

Trees

All considered trees are rooted and binary. Given a set X, a tree T for X is a tree whose leafset, which we denote by L(T), is in bijection with X. Given an internal node u of T, the subtree rooted at u is denoted Tu and we call the leafset L(Tu) the clade of u. A node u is an ancestor of v if u is on the (inclusive) path between v and the root. If u and v are connected by an edge of T, then v is a direct descendant of u. We denote by ch(u) the set of direct descendants (children) of u. The lowest common ancestor (lca) of u and v, denoted lcaT(u,v), is the ancestor common to both nodes that is the most distant from the root. We define lcaT(U) analogously for a set UV(T).

A species tree S for a species set Σ represents an ordered set of speciation events that have led to Σ: an internal node is an ancestral species at the moment of a speciation event, and its children are the new descendant species.

A gene family Γ is a set of genes accompanied with a function s:ΓΣ mapping each gene to its corresponding species. The evolutionary history of Γ can be represented as a node-labeled gene tree for Γ, where each internal node refers to an ancestral gene at the moment of an event (either speciation or duplication), and is labeled as a speciation (Spec) or duplication (Dup) accordingly. Formally, we call a DS-tree for Γ a pair (G,evG), where G is a tree with L(G)=Γ, and evG:VG\L(G){Dup,Spec} is a function labeling each internal node of G as a duplication or a speciation. We may write ev instead of evG when the context is clear. For example, in Fig. 1, G1 and G2 are two DS-trees.

Fig. 1.

Fig. 1

S is the species tree for Σ={a,b,c,d}. The internal nodes, representing ancestral species, are labeled by xy and z. R is a relation graph on gene set Γ={a1,a2,b1,c1,d1}. A gene name corresponds to the species it belongs to (e.g. s(a1)=a). R is not satisfiable as the set of vertices {c1,b1,d1,a2} induces a P4. R is a satisfiable relation graph obtained from R by inserting the edge {c1,d1}, and G1 is a DS-tree displaying every relation of R (each internal node v is labeled by sG1(v)). However, G1 is not consistent with the species tree S. R is another correction of R that is S-consistent, as the tree G2 displays the relations in R and is S-consistent. Dup nodes in DS-trees are marked by a square; all other nodes are speciation nodes

According to the Fitch [18] terminology, we say that two genes xy of Γ are orthologous in G if ev(lcaG(x,y))=Spec, and paralogous in G if ev(lcaG(x,y))=Dup.

A DS-tree G for Γ does not necessarily represent a valid history. For this to hold, any speciation node of G should reflect a clustering of species “in agreement” with S [10]. Formally G should be S -consistent, as defined below, where sG is the LCA-mapping function, mapping each gene, ancestral or extant, to a species as follows: if gL(G), then sG(g)=s(g); otherwise, sG(g)=lcaS({s(g):gL(Gg)}).

Definition 1

Let S be a species tree and G be a DS-tree. Let v be an internal node of G such that ev(v)=Spec. Then the speciation node v, with children v1 and v2, is S -consistent iff none of sG(v1) and sG(v2) is an ancestor of the other. We say that G is S -consistent iff every speciation node of G is S-consistent.

For example, in Fig. 1, G1 is not S-consistent as the root of G1 is not S-consistent.

Relation graphs

For a graph H=(VH,EH), we denote the complementary set of EH by EH¯={{u,v}:u,vVH,{u,v}EH}. Let V be a subset of VH. The subgraph of H induced by V, denoted H[V], is the subgraph of H with vertex-set V having every edge {u,v} of H for u,vV. If I is another graph, we say H is I-free if there is no VVH such that H[V] is isomorphic to I.

A relation graph R on a gene family Γ is a graph with vertex set VR=Γ, in which we interpret each edge {u,v} of ER as an orthology relation between u and v, and each “missing” edge {u,v}ER¯, also called non-edge, as a paralogy relation. Notice that if s(u)=s(v), then {u,v} must be a non-edge (u and v are paralogous). We denote n=|VR|.

A DS-tree G leads to a relation graph, denoted R(G), with vertex set L(G) and edge set corresponding to all gene pairs that are orthologous in G. Conversely, a relation graph R does not necessarily lead to a DS-tree. If this is the case, i.e. if there is a DS-tree G such that R(G)=R, then R is said satisfiable. As shown in [12], a relation graph R is satisfiable if and only if R is P4-free, meaning that, for any four vertices of R, the induced graph is not a path of length 3 (number of edges). The P4-free graphs are sometimes called cographs. See Fig. 1 for an example.

As a DS-tree does not necessarily represent a true history for Γ, satisfiability of a relation graph does not ensure a possible translation in terms of a history for Γ. For this to hold, R should also be consistent with the species tree, according to the following definition.

Definition 2

Let S be a species tree. A relation graph R for Γ is S-consistent if and only if R is satisfiable by a DS-tree G which is itself S-consistent.

Problem statements

We call a weight for a relation graph R=(VR,ER) a function w:VR2R+ on its vertex pairs. Notice that w assigns a weight to both edges (orthologies) and non-edges (paralogies). We shall assume that if s(u)=s(v) for two genes u and v, then {u,v}ER¯ and w({u,v})=. The weight function w is extended to any IRVR2 by defining w(IR)={x,y}IRw({x,y}).

Given a relation graph R=(VR,ER), an edge-editing of R is a pair ER=(ER+,ER-) with ER+ER¯ and ER-ER. We denote by R(ER) the graph R(ER)=(VR,(ERER+)\ER-). In other words, ER+ (respectively ER-) denotes inserted (respec. removed) edges. Given a relation graph R=(VR,ER) computed from R by edge insertion and removal, the set of removed edges is ER-=ER\ER, and the set of inserted edges is ER+=ER\ER. For example, for the graph R of Fig. 1, ER+={{c1,d1}} and ER-=. An edge-editing ER is said P4 -free if R(ER) is itself P4-free.

The problems considered in “Hardness of approximation of minimum weighted editing for satisfiability and consistency” section and “A bounded approximation algorithm for minimum weighted editing for satisfiability and consistency” section are the following. The first problem asks for a satisfiable relation graph, hence no species tree is considered, while the second asks for an S-consistent relation graph, hence the input contains also a species tree.

Minimum weighted editing for satisfiability (MinWES)

Input:

A relation graph R=(VR,ER) and a weight function w;

Output:

A satisfiable relation graph R=(VR,ER), obtained from R by an edge-editing ER=(ER+,ER-) that minimizes w(ER+)+w(ER-).

Minimum weighted editing for consistency (MinWEC)

Input:

A relation graph R=(VR,ER), a weight function w and a species tree S for Σ (the set of species containing the genes represented by R);

Output:

An S-consistent relation graph R=(VR,ER), obtained from R by an edge-editing ER=(ER+,ER-) that minimizes w(ER+)+w(ER-).

Below is a formal statement of the corresponding maximization version of MinWES for unweighted graphs, considered in “PTASs for maximum CoGraph editing and maximum consistency editing” section. Remember that edges represent orthologies, while non-edges are paralogies. Maximizing conservation therefore requires accounting for both edges and non-edges.

Maximum editing for satisfiability (MaxES)

Input:

A relation graph R=(VR,ER);

Output:

A satisfiable relation graph R=(VR,ER) obtained from R by an edge-editing, such that its value |ERER|+|(ER¯ER¯)| is maximized.

Maximum editing for consistency (MaxEC)

Input:

A relation graph R=(VR,ER) for a gene family with genes belonging to genomes in Σ, a species tree S for Σ;

Output:

An S-consistent relation graph R=(VR,ER) obtained from R by an edge-editing, such that its value |ERER|+|(ER¯ER¯)| is maximized.

Hardness of approximation of minimum weighted editing for satisfiability and consistency

We show that MinWES is unlikely to be approximable within a constant factor, by presenting a gap-preserving reduction from Minimum Multi-Cut. First, we consider the variant of MinWES, called Minimum Weighted Removal for Satisfiability (MinWRS), where only edge removal is allowed, then we easily extend the result to MinWES.

Given a graph H=(VH,EH), and a set XVH2 (i.e. a set of pairs), Minimum Multi-Cut asks for a set EH of minimum cardinality such that each pair {vi,vj}X is disconnected in H=(VH,EH\EH).

Given an instance H=(VH,EH,X) of Minimum Multi-Cut, we construct an instance R=(VR,ER,w) of MinWRS as follows. The vertex set VR includes, for each viVH, two vertices vi,R and vi,R. That is, VR={vi,R,vi,R:viVH}.

For any distinct x,yVR, we set s(x)s(y), and hence there are no “forced” paralogs. As for ER, it is defined as follows, where q=|VH|5+1.

  • For each viVH, define an edge {vi,R,vi,R} in ER of weight q=q|EH|+2|VH|2-|EH|;

  • For each {vi,vj}X, define an edge {vi,R,vj,R} in ER with weight q if {vi,vj}EH, and with weight 1 if {vi,vj}EH;

  • For each {vi,vj}X, define the edges {vi,R,vj,R} and {vi,R,vj,R} in ER, each with weight q / 2 if {vi,vj}EH, and with weight 1 if {vi,vj}EH.

For each {uR,vR}ER¯, {uR,vR} has weight q. Notice however, that, since edge insertion is not allowed in Minimum Weighted Co-Graph Deletion, the weight of {uR,vR} never contributes to the cost of a solution of Minimum Weighted Co-Graph Deletion.

We first show that there is a correspondance between solutions to the two problems on our constructed instances.

We first bound the number of edges of weight 1 in R.

Claim 1

Let H=(VH,EH,X) be an instance of Minimum Multi-Cut and let R=(VR,ER,w) be the corresponding instance of Minimum Weighted Co-Graph Deletion . Then, R contains at most 2|V|2-|EH| edges of weight 1.

Proof

Consider the edges connecting vertices vi,R and vj,R; vi,R and vj,R are connected by an edge of weight 1 if and only if {vi,vj}EH and {vi,vj}X.

Consider the edges connecting vertices vi,R and vj,R, vi,R and vj,R. vi,R, vj,R (and vi,R,vj,R) are connected by an edge of weight 1 if {vi,vj}EH and {vi,vj}X.

Any other edge has weight >1, hence the lemma follows.

Now, we present the main results needed to prove the inapproximability of Minimum Weighted Co-Graph Deletion.

Lemma 1

Let H=(VH,EH,X) be an instance of Minimum Multi-Cut and let R=(VR,ER,w) be the corresponding instance of Minimum Weighted Co-Graph Deletion . Given a solution EH of Minimum Multi-Cut , we can compute in polynomial time a solution of Minimum Weighted Co-Graph Deletion of weight at most q|EH|+2|VH|2-|EH|.

Proof

Given a set E that defines a multicut in H, let VH,1,,VH,p be the sets of vertices of the connected components in the graph VH=(VH,EH\EH).

We define a solution of Minimum Weighted Co-Graph Deletion over instance R as follows. We construct the partition VR,1,,VR,p of the vertices of R such that vj,R and vj,R belong to set VR,i if and only if vjVH,i. All edges having their endpoints in two distinct VR,i,VR,j are removed.

We claim that the computed graph R induced by the partition is P4-free. By construction, for each vj,R, vj,R, vh,R, vh,R that belong to VR,i, the edges {vj,R,vh,R} and {vj,R,vh,R} belong to ER (because {vj,vh}X). Moreover, there is no edge between vj,R and vh,R, nor between vj,R and vh,R. Thus any path on four vertices in the graph on vertex set Vi,R must be either of the form vj,Rvh,Rvk,Rv,R, or of the form vj,Rvh,Rvk,Rv,R. In both cases, the endpoints of the path share an edge, and thus cannot induce a P4.

Now, consider the edges {vi,vj}EH. If {vi,vj}X, the corresponding solution of Minimum Weighted Co-Graph Deletion removes an edge of weight q, namely {vi,R,vj,R}. If {vi,vj}X, the corresponding solution of Minimum Weighted Co-Graph Deletion removes two edges of weight q / 2, namely {vi,R,vj,R} and {vi,R,vj,R}. Hence those edges have a total weight q|EH|. Since at most 2|VH|2-|EH| edges of weight 1 are removed (see Claim 1), we can conclude that the lemma holds.

Lemma 2

Let H=(VH,EH,X) be an instance of Minimum Multi-Cut and let R=(VR,ER,w) be the corresponding instance of Minimum Weighted Co-Graph Deletion . Given a solution R of Minimum Weighted Co-Graph Deletion of weight at most qW+2|VH|2-|EH| for some integer W, we can compute in polynomial time a multicut EH of H of size at most W.

Proof

Consider a solution R=(VR,ER,w) of Minimum Weighted Co-Graph Deletion over instance R=(VR,ER,w) of weight at most qW+2|VH|2-|EH|, with W|EH|. First, notice that no edge {vi,R,vi,R}, with 1i|V|, is removed to obtain R, since the weight of such an edge is greater than qW+2|VH|2-|EH|.

Consider now two vertices vi,R, vj,R, such that, given the corresponding vertices vi, vj in H, we have {vi,vj}X. By construction there is a P4 in R, namely vi,R,vi,R,vj,R,vj,R. It follows that the edge {vi,R,vj,R} must be removed in R. Moreover, we claim that in R, the vertices vi,R, vj,R must be disconnected. Assume by contradiction that this does not hold, and that vi,R, vj,R belong to the same connected component of R. Consider the shortest path P that connects vertices vi,R and vj,R in R. Then P has length at least 2. Note that as P is a shortest path, it has no chord, i.e. non-consecutive vertices of P cannot share an edge.

Suppose that P does not include the vertex vi,R. Then we can assume that vi,R is adjacent in P to a vertex vt,R, since if it is adjacent to a vertex vq,R, then the vertices vi,R, vi,R, vq,R, and vq,R would induce a P4. Now, if vt,R is adjacent to vj,R, then vi,R, vi,R, vt,R and vj,R induce a P4. If there is no such vt,R, then P has length at least 3 and it must therefore contain an induced P4.

So suppose instead that P includes the vertex vi,R. Since by construction vi,R is not adjacent to vj,R and it is not adjacent to any vt,R, with ti, while it is adjacent to vi,R, P has length at least 3, and again must have an induced P4.

We can conclude that when {vi,vj}X, the corresponding vertices vi,R, vj,R belong to disconnected connected components of R. Hence we can compute a multi-cut of H as follows:

EH={{vi,vj}:{vi,R,vj,R},of weightq,or{vi,R,vj,R},{vi,R,vj,R}, of weightq2,are removed inR.}

EH is a multi-cut, since each {vi,vj}X is disconnected. Now, recall that R is obtained by removing edges of overall weight at most qW+2|VH|2-|EH|. Since edge edge in EH corresponds to edges of overall weight q in R (an edge {vi,R,vj,R} of weight q if {vi,vj}X, or two edges of weight q / 2, namely {vi,R,vj,R} and {vi,R,vj,R} if {vi,vj}X), we must have |EH|W.

Assuming the unique games conjecture, the proof of inapproximability of Minimum Weighted Co-Graph Deletion is deduced from the inapproximability of Minimum Multi-Cut [19].

Theorem 1

Minimum Weighted Co-Graph Deletion is not approximable within a constant factor assuming the unique games conjecture.

Proof

Given a graph H instance of Minimum Multi-Cut and the corresponding instance R of Minimum Weighted Co-Graph Deletion, denote by OPTM (APM, respectively) the value of an optimal solution (of an approximation solution, respectively) of Minimum Multi-Cut on instance H, and denote by OPTC (APC, respectively) the value of an optimal solution (of an approximation solution, respectively) of Minimum Weighted Co-Graph Deletion on instance R. Define z=2|VH|2-|EH|. By Lemma 2, we assume that APC(R)APM(H)q, as there exists an algorithm that given a solution of Minimum Weighted Co-Graph Deletion of value APC(R) computes in polynomial time a solution of Minimum Multi-Cut having value at most APM(H) with APM(H)qAPM(H)q+zAPC(R). Also, by Lemma 1, we have OPTC(R)OPTM(H)q+z, as for any optimal solution of Minimum Multi-Cut of value OPTM(H)q, there is an algorithm that computes in polynomial time a solution of Minimum Weighted Co-Graph Deletion having value OPTC(R) with OPTC(R)OPTM(H)q+z.

We have that

APC(R)OPTC(R)APM(H)qOPTM(H)q+z=APM(H)q+APM(H)z-APM(H)zOPTM(H)q+z=APM(H)q+APM(H)zOPTM(H)q+z-APM(H)zOPTM(H)q+zAPM(H)q+APM(H)zOPTM(H)q+OPTM(H)z-APM(H)zOPTM(H)q+z=APM(H)(q+z)OPTM(H)(q+z)-APM(H)zOPTM(H)q+z=APM(H)OPTM(H)-APM(H)zOPTM(H)q+z

where we assume OPTM(H)1 for the second inequality (the case OPTM(H)=0 can be checked in polynomial time). Since Minimum Multi-Cut is not approximable within a constant factor assuming the unique games conjecture [19], even on unweighted graphs, it follows that

APM(H)OPTM(H)α

on an infinity of instances of H for any constant α1. As a consequence, for any constant α1, an infinity of instances of R yield:

APC(R)OPTC(R)α-APM(H)zOPTM(H)q+z

Since q=n5+1, APM(H)n2 and zn2, it follows that APM(H)zOPTM(H)q+z1/n. Combining the last two inequalities, we have that

APC(R)OPTC(R)α-1/nβ

for any constant β1, which concludes the proof.

The result of Theorem 1 can be easily extended to Minimum Weighted Co-Graph Editing.

Corollary 1

Minimum Weighted Co-Graph Editing is not approximable within a constant factor assuming the unique games conjecture.

Proof

The result follows by a gap-preserving reduction similar to that for Minimum Weighted Co-Graph Deletion. Recall that for each pair {uR,vR}ER¯, a weight of q is associated with {uR,vR}. Consider a solution R of Minimum Weighted Co-Graph Editing on instance R that has cost not greater than qW+|VH|2-|EH| +|VH|2. It is easy to see that R is obtained without any edge insertion.

The inapproximability result for Minimum Weighted Co-Graph Editing is easily extended to MinWEC. This is achieved by defining a species tree S on VR such that the root of S is connected to two subtrees, one with leafset {vi,R:viVH}, one with leafset {vi,R:viVH}, and showing that any solution to our instance of Minimum Weighted Co-Graph Deletion must agree with this species tree.

Corollary 2

MinWEC is not approximable within a constant factor assuming the unique games conjecture.

Proof

The result follows by a gap-preserving reduction similar to that for Minimum Weighted Co-Graph Deletion and Minimum Weighted Co-Graph Editing. Define a species tree S on VR such that the root of S is connected to two subtrees, one with leafset {vi,R:viVH}, one with leafset {vi,R:viVH}.

Consider the partition VR,1,,VR,p of the vertices of a solution R of Minimum Weighted Co-Graph Deletion and Minimum Weighted Co-Graph Editing. Each connected component VR,t that contains vertices vi,R, vi,R, vj,R, vj,R, contains only edges {vi,R,vi,R}, {vj,R,vj,R}, {vi,R,vj,R}, {vj,R,vi,R}.

For each set VR,i, we construct a tree GR,i by defining two subtrees GR,i1 and GR,i2 such that GR,i1 has leafset {vj,R:vj,RVR,i} and GR,i2 has leafset {vj,R:vj,RVR,i}. Each node of GR,i1 and GR,i2 is associated with a duplication. GR,i is obtained by joining GR,i1 and GR,i2 in a root, associated with a speciation. Finally, the subtrees GR,1,,GR,p are joined in a gene tree G by duplication nodes (with any topology). By construction, G is S-consistent, thus the hardness result can be extended to MinWEC.

A bounded approximation algorithm for minimum weighted editing for satisfiability and consistency

While MinWES and MinWEC are not approximable within a constant factor, we show here that they can be approximated within factor n=|V(R)|, and we give the corresponding algorithms. Despite being a large approximation factor, this is the best known bound so far and shows that the problems have polynomially bounded approximability. We first describe the approximation algorithm for MinWES.

Denote by R¯=(VR,ER¯) the complement of the graph R=(VR,ER). A well-known property of cographs is given by the following lemma.

Lemma 3

 [20] A graph R is P4 -free if and only if for any XVR , one of R[X] or R[X]¯ is disconnected.

This motivates a greedy min-cut approach for MinWES, performing an edge-editing of minimum weight disconnecting the graph or its complement, and iterating recursively on the resulting components. This is the main idea of Algorithm MinCut-Cograph-Editing below. Note that assuming forced paralogs have infinite weight, this algorithm will never make two genes from the same species orthologs.

More formally, let R=(VR,ER) be a relation graph accompanied with a weight function w. Define a cut C={X,Y} as a partition of VR with X and Y being non-empty sets, and denote ER(C)={{x,y}ER:xX,yY}. The weight of C is w(C)=w(ER(C)). The cut C is a minimum cut or MinCut if no other cut has a smaller weight w(C). Applying a cut C to R consists in removing all edges of ER(C) from R.

Complexity: A MinCut of a given graph of n vertices and m edges can be found in time O(nm+n2logn) using the Stoer–Wagner algorithm [21]. In the MinCut-Cograph-Editing algorithm, MinCut is applied to both R and R¯. As at least one of these two graphs has Ω(n2) edges, the required time for MinCut is therefore O(n3). This step is repeated at most n times, hence the overall time complexity of MinCut-Cograph-Editing is O(n4).

The remaining of this section is dedicated to proving Theorem 2, which states that MinCut-Cograph-Editing is an n-approximation algorithm. We denote by σR the minimum weight of a P4-free edge-editing of R. If XVR, we denote σR[X] by σX.

graphic file with name 13015_2017_96_Figa_HTML.jpg

Lemma 4

Let C be a minimum cut of R, and let C^ be a minimum cut of R¯ . Then σRmin{w(C),w(C^)}.

Proof

Let ER be a P4-free edge-editing of R. By Lemma 3, either R(ER) or its complement is disconnected, implying that ER must apply some cut on either R or R¯. This cut is at best a minimum cut.

Lemma 5

Let {X,Y} be a partition of V. Then, σRσX+σY.

Proof

Let ER be a P4-free edge-editing of weight σR, and let R=R(ER). Assume that ER has a weight stricly smaller than σX+σY. Then, since R[X] and R[Y] are P4-free, there must either be an edge-editing of R[X] of weight smaller than σX, or an edge-editing of R[Y] of weight smaller than σY, contradicting the definition of σX and σY.

Theorem 2

MinCut-Cograph-Editing is an n factor approximation algorithm for MinWES.

Proof

Denote by β(R) the weight of the edge-editing found by the algorithm on R. We proceed by induction on n=|VR| to show that β(R)nσR. The statement is trivial for n3 (as there is nothing to correct), so assume that the algorithm finds a solution of weight β(R)kσR for any graph of size at most k<n. The algorithm applies a minimum cut C={X,Y} on R or R¯, and proceeds recursively on X and Y, with |X|,|Y|n-1. By the induction hypothesis, we have

β(R)|X|σX+|Y|σY+w(C)(n-1)(σX+σY)+w(C)(n-1)σR+σR=nσR

where the last inequality holds due to Lemmas 4 and  5.

It is possible to show that the approximation factor of MinCut-Cograph-Editing is tight, as shown in Fig. 2. Suppose all weights are equal to one. Clearly, an optimal solution of weight 1 is obtained by removing the middle edge. However, a minimum cut {X,Y} can be found by taking X as a single vertex of degree one, and Y as the rest. In this manner, the algorithm might remove up to n-3 edges before H becomes P4-free, which is n-3 times worse than optimal.

Fig. 2.

Fig. 2

A graph R with all edges of weight 1

Notice however that a solution of MinCut-Cograph-Editing on the example of Fig. 2 cannot be 2Δ(H) times worse than the optimal solution, where Δ(H) is the degree of H (by putting half the leaves left and the other half right). We do not know whether MinCut-Cograph-Editing offers any guarantee in relation to Δ(H) or Δ(H¯).

By modifying MinCut-Cograph-Editing, it is possible to design an n factor approximation algorithm for MinWEC. The main difference with respect to MinCut-Cograph-Editing, is that the algorithm considers a minimum cut on a subset of R and a cut on a subset of R¯ induced by the species tree S.

We first provide the detailed MinCut-Cograph-Editing-Cons algorithm, and show that it also is a n-factor approximation. Given a species tree S and a set ZVR, let Σ(Z)={s(x):xZ}. Let S|Σ(Z) be the subtree of S restricted to Σ(Z) and let XS, YS be the clades of the left and right child, respectively, of the root of S|Σ(Z). Consider the sets X={x:s(x)XS} and Y={y:s(y)YS}, the cut CS(Z) on R¯[Z] is defined as CS(Z)={XR,YR}. Observe that CS(Z) is the only possible cut on R¯ that maintains S-consistency, as this cut corresponds to a speciation in a DS-tree, and speciations must separate genes according to S. Therefore, it suffices to modify MinCut-Cograph-Editing by forcing the cut C^ to be CS(Z). Call this modified algorithm MinCut-Cograph-Editing-Cons.

graphic file with name 13015_2017_96_Figb_HTML.jpg

Theorem 3

MinCut-Cograph-Editing-Cons is an n factor approximation algorithm for MinWEC.

Proof

Denote by β(R) the weight of the edge-editing found by the algorithm on R. We proceed by induction on n=|VR| to show that β(R)nσR. The statement is trivial for n2 (as there is nothing to correct), so assume that the algorithm finds a solution of weight β(R)kσR for any graph of size at most k<n.

The algorithm applies a cut C={X,Y} which is either a minimum cut on R or it is the cut CS(VR), and proceeds recursively on X and Y, with |X|,|Y|n-1. By the induction hypothesis, we have

β(R)|X|σX+|Y|σY+w(C)(n-1)(σX+σY)+w(C)

Now, similarly to Lemma 4, we have that w(C)σR. First, let G be the gene tree associated with a solution of MinWEC over instance R. If C is a minimum cut on R, it holds due to the proof Lemma 4. If C is CS(VR), then notice that, in order to guarantee the consistency with S, the root of G must induce exactly the cut CS(VR).

Lemma 5 holds also for MinWEC, hence

β(R)|X|σX+|Y|σY+w(C)(n-1)(σX+σY)+w(C)(n-1)σR+σR=nσR

thus concluding the proof.

PTASs for maximum CoGraph editing and maximum consistency editing

In this section, we consider the MaxES and the MaxEC problems. Although sharing the same objectives, the minimization and maximization variants are not equivalent from an approximation point of view.

Given a relation graph R, the value of a solution R for MaxES (MaxEC, respectively) over instance R [over instance (RS), respectively] is called the agreement value of R and it is denoted by A(R,R). Moreover, given a gene tree G, we denote by A(GR) the agreement between the relation graph associated with G and R.

Next, we give a bound on the agreement value returned by an optimal solution of MaxES and MaxEC.

Lemma 6

Given a relation graph R (a relation graph R and a species tree S, respectively), an optimal solution of MaxES over instance R [an optimal solution of MaxEC over instance (R, S), respectively] has an agreement value of at least n28.

Proof

Consider a relation graph R and a species tree S for the MaxEC problem. Let R=(V(R),) and R=V(R),V(R)2 be two solutions for MaxES over instance R [for MaxEC over instance (RS), respectively]. It is easy to see that R and R are both feasible solutions of MaxES and of MaxEC. Since for each {u,v}, with u,vV, uv, either one of R or R agrees with R, it holds

A(R,R)+A(R,R)=n2

Then at least one of R, R must have an agreement value of at least 12n2, hence an optimal solution of MaxES and MaxEC has an agreement value of at least 12n2n28.

Since it possible to compute an optimal solution of MaxES with additive cost εn2, for each ε>0 [16], it follows that MaxES admits a PTAS.

Let OPT(R) be the value of an optimal solution on R, and let c be such that OPT(R)=cn2. The additive εn2 approximation algorithm for cograph editing [16] yields a solution of value (c-ε)n2. As c1/8 by Lemma 6, ε can be adjusted so that, for any 0<ε<1, (c-ε)n2(1-ε)cn2, hence yielding a PTAS. In the more general case, this algorithm does not ensure that genes from the same species remain paralogs. However, the authors of [16] claim that their approximation algorithm applies to any hereditary graph property (i.e. preserved after vertex-deletion), which holds for satisfiability.

A PTAS for MaxEC

The PTAS for MaxES does not guarantee that the returned relation graph R (and its corresponding gene tree G) is S-consistent with the given species tree S. In this section, we present a PTAS for MaxEC based on smooth-polynomial integer programming [22], a technique that has been applied to design PTAS for problems like maximum quartet consistency [23] or maximum consensus clustering [24].

As for maximum quartet consistency, the MaxEC problem is reduced to the assignment of leaves in Γ to a tree, and the resulting tree is then used to to reconstruct a gene tree G that is consistent with S and whose relation graph requires at most εn2 modifications with respect to the original graph. In order to guarantee the S-consistency of the reconstructed gene tree, we need several technical arguments that are not used for maximum quartet consistency. Recall that we are considering binary trees.

Before giving the details, we present an overview of the PTAS. First, in “The compressed tree Gk” section, we show that starting from a gene tree G we can compute a compressed tree Gk that has at most k internal nodes and at most k leaves, where k>0 is a constant. In order to construct such a compressed tree, first in “The unlabeled compressed tree Tk” section we compute an unlabeled compressed tree Tk, and then in “A PTAS of MaxLA by smooth polynomial integer programming” section we compute a compressed tree Gk from Tk by using smooth-polynomial integer programming. Finally, we show in “Building a feasible solution” section how to reconstruct an S-consistent gene tree from Gk.

The compressed tree Gk

First, we will focus on the compressed tree, and we show that, given an optimal solution R of MaxEC, there exists a compressed tree that respects a (large) subset of the speciation/duplication relations for R.

Consider an optimal solution R of MaxEC, and let (G,evG) be a DS-tree, where G is the gene tree corresponding to R. Recall that each internal node of G is associated by evG either with a duplication (Dup) or with a speciation (Spec). We present the formal definition of compressed tree Gk associated with (G,evG) (see Fig. 3).

Fig. 3.

Fig. 3

A compressed tree Gk computed from a gene tree G. Leaf-sets are represented with triangles

Definition 3

Given a constant k>0 and a DS-tree (G,evG), a compressed tree Gk associated with (G,evG) is a tree that has at most k internal nodes and at most k leaves, which are called leaf-sets. An internal node v can be a regular internal node or can belong to a two-set internal node u,v such that vch(u), and both u and v have exactly one leaf-set as a child. The two-set internal nodes of Gk are disjoint, that is u,v and v,w cannot be two-set internal nodes of Gk. Moreover, the following properties hold:

  • the leaf-sets of Gk induce a partition of Γ and each leaf-set contains at most 8n / k elements of Γ

  • each internal node of Gk is associated with two possible events, Dup or Spec, by the function evGk

  • let Iv1, Iv2 be two leaf-sets connected to nodes u1 and u2, respectively, such that u1,u2 is not a two-set internal node, let l1Iv1, l2Iv2, and x=lcaG(l1,l2) and y=evGk(lcaGk(Iv1,Iv2)), then evG(x)=evGk(y).

Note that a leaf-set Iv of Gk is both a set of leaves of G, and a leaf of Gk. It will sometimes be useful to clarify which one we wish to refer to, and so we denote by L(Iv) the set of leaves that belong to Iv.

Now, we provide a constructive proof that shows that, starting from a solution R (whose corresponding gene tree is G) of MaxEC over instance (RS), there exists such a compressed tree Gk.

Consider the following algorithm. First, the algorithm initializes Gk to G and all internal nodes are unmarked. Then, the algorithm traverses G and construct the tree Gk as described in Algorithm Compressed Tree (G).

When the algorithm stops it follows that each leaf-set has size at most 8n / k. Notice that, given a two-set internal node v1,v2, the leaves assigned to the leaf-sets Iz1, Iz2 connected to v1 and v2 are considered as a single leaf-set with reference to the relation between elements in L(Iz1)L(Iz2).

Next, we show that the algorithm returns a compressed tree Gk, with at most k internals node and k leaf-sets.

graphic file with name 13015_2017_96_Figc_HTML.jpg

Lemma 7

Given a gene tree G , Algorithm Algorithm Compressed Tree (G ) returns a tree Gk , with at most k internal nodes and k leaf-sets.

Proof

First, consider the set of regular nodes of Gk. Consider the set V1k of those nodes of Gk that the algorithm defines because the subtree rooted at one of such nodes contains at least 8n / k unassigned leaves. It follows that at most k / 8 such nodes are chosen.

Consider the set V2k of nodes of Gk defined as internal nodes because they are the least common ancestor of two internal nodes of V1k. Now, if we restrict Gk to V1kV2k, we obtain a tree having at most k / 8 leaves, as the leaves by construction are only nodes in V1k, where each internal node, except for the root, has degree at least three. Hence |V2k||V1k|k/8.

Let v and z be two nodes in V1kV2k, such that z is an ancestor of v in Gk, and there are no other ancestor of v in Gk that belongs to V1kV2k. It follows that, by construction, at most one two-set internal node on the path between v and z is defined in Gk. Hence at most two internal nodes are defined on the path between v and z in Gk, and since |V1kV2k|k/4, it follows that Gk contains at most k / 4 two-set internal nodes. Thus Gk consists of at most k/4+k/2=(3/4)k internal nodes.

Now, consider the defined leaf-sets. For each two-set internal node v1,v2, there exists at most two leaf-sets connected with one of v1,v2, hence at most k / 2 leaf-sets. For each of the k / 4 internal node vV1kV2k, the leaves assigned to leaf-set connected to v are at most two, as G is binary. Hence there exists hence at most k / 2 leaf-sets connected to internal nodes of vV1kV2k. Hence, the number of leaf-set is bounded by k/2+k/2=k.

In order to prove that Gk is a compressed tree, in addition to Lemma 7 we need the following result.

Lemma 8

Given a gene tree G and a species tree S, let Gk be the tree computed by Algorithm Algorithm Compressed Tree (G ). Given two distinct leaf-sets Iu and Iw of Gk connected to the internal nodes z and v, such that z,v is not a two-set internal node, let l1L(Iu) and l2L(Iw) . Let xk=lcaGk(Iu,Iw) and x=lcaG(l1,l2) . Then evGk(xk)=evG(x).

Proof

Let lcaGk(Iu,Iw)=xk. Assume that Iu and Iw are connected to the same internal node of Gk (which must be xk). Then when xk is defined by Algorithm Algorithm Compressed Tree (G), its event is the same as the corresponding node x of G. Assume that Iu and Iw are connected to different internal nodes of Gk, uk and wk, respectively, corresponding to node u and w of G. Consider x=lcaG(u,w) then Algorithm Algorithm Compressed Tree (G) defines a corresponding node xk in Gk such that evGk(xk)=evG(x).

Assume that xk belongs to a two-set internal node z,v. Then, by construction, exactly one of Iu, Iw (w.l.o.g. Iu) must be a leaf-set which is a child of xk, and exactly one of Iu, Iw (w.l.o.g. Iw) is a leaf-set connected to a strict descendant c of xk, such that cz,v. Let y=lcaG(l1,l2), for a leaf l1 in L(Iu) and a leaf l2 in L(Iw). By construction, l1Iu only if evGk(xk)=evG(y), thus concluding the proof.

Lemmas 7 and 8 implies that Algorithm Algorithm Compressed Tree (G) constructs a compressed gene tree Gk, as by construction the leaf-sets induce a partition of Γ.

Next, we show a lower bound on the agreement value of an optimal assignment of leaves to the leaf-sets Iv. We denote by A(Gk,R) (the agreement between R and Gk) as the agreement for each pair of leaves l1,l2Γ that belong to two distinct leaf-sets Iu and Iw of Gk connected to the internal nodes u and v, such that u,v is not a two-set internal node (notice that u and v may be the same node).

Lemma 9

Given an optimal solution G of MaxEC over instance (R, S) and a constant k>0 , let Gk be the compressed tree computed starting from G . Then A(Gk,R)A(G,R)-64n2k.

Proof

Consider an optimal solution G of MaxEC over instance (RS) and the compressed tree Gk constructed from G. From Lemma 8, the pairs of leaves that belong to different leaf-sets (not connected to the same two-set internal node) have the same relations in G and in Gk.

Consider the leaves of a same leaf-set Iv or of two leaf-sets Iw and Iu which are connected to the same two-set internal node. Since |Iv|8nk and |IwIu|8nk, the number of relations between two leaves belonging to a common leaf-set is at most 64n2k2. Since there are at most k leaf-sets, the overall number of relations between pairs of leaves in Gk with respect to G are at most 64n2k, hence A(Gk,R)A(G,R)-64n2k.

The unlabeled compressed tree Tk

The tree Gk described above is of course not known, and it needs to be found. In this subsection we introduce the unlabeled compressed tree Tk that is used to construct the compressed tree Gk. An unlabeled compressed tree Tk is a compressed tree whose leaf-sets are empty. Here we introduce some properties of Tk and we reduce the MaxEC problem to a second problem, called MaxLA (to be defined later). The PTAS iterates through the possible unlabeled compressed trees Tk. In particular, the PTAS iterates through (1) the structure of Tk, (2) the events associated with internal nodes of Tk, and (3) a set of labels that are allowed to be assigned to a leaf-set.

First, consider the structure of Tk. Since by Lemma 7 Gk consists of at most k internal nodes and k leaf-sets, it follows that there are at most 24k2 possible topologies for the unlabeled compressed tree Tk. Indeed, the adjacency matrix of Tk has size 4k2, and the possible adjacency matrices are at most 24k2. Moreover, for each topology, we define in time O(2k) the two-set internal nodes of Tk.

Now, consider the events associated with the internal nodes of Tk. For each unlabeled compressed tree Tk, the events associated with the internal nodes of Tk are at most 2k (two possible cases, Dup or Spec, for each of the k internal nodes). Overall we iterate though O(24k2) possible unlabeled compressed tree Tk.

Consider now an unlabeled compressed tree Tk. In order to ensure that the gene tree G constructed from Tk is S-consistent with the given species tree S, we must ensure that the speciation nodes of G are consistent with S. We define a mapping sTk of the nodes of Tk, except the leaf-nodes connected to two-set internal nodes, to the nodes of S so that the mapping is feasible, that is the following conditions hold:

  • if v is an ancestor of u in Tk, then sTk(v) is an ancestor (not necessarily proper) of sTk(u)

  • if v is an ancestor of u in Tk and evTk(v)=Spec, then sTk(v) is a proper ancestor of sTk(u)

Based on the mapping sTk, define for each leaf-set Iv, the allowed set A(Iv) of labels that can be assigned to a leaf-set Iv. If Iv is a leaf-set not connected to a two-set internal node:

A(Iv)={l:lL(Sx)withx=sTk(Iv)}

If Iv is a leaf-set connected to an internal node u, with u,w a two-set internal node (recall that evTk(u)=Dup):

A(Iv)={l:lL(Sx)withx=sTk(u)}

If Iv is a leaf-set connected to a two-set internal node u, with w,u a two-set internal node (recall that evTk(u)=Spec), such that z is the only child of u in Tk which is an internal node:

A(Iv)={l:lL(Sx)\L(Sy),withx=sTk(u)andy=sTk(z)}

Since Tk contains at most 2k nodes, the set of the feasible mappings sTk are at most O(n2k). Moreover, once the mapping sTk is computed, A(Iv) can be computed in O(nk) time.

Finally, for each set leaf-set Iv, we assign one leaf (denoted by P(Iv)) of A(Iv) to Iv, in time O(nk). These leaves are called preassigned leaves and are assigned such that for each internal node x of Tk, the lca mapping of the preassigned leaves maps x to a node y of S such that y=sTk(x). Notice that, given an optimal solution of MaxEC,there exists a feasible mapping with associated A(Iv) and P(Iv).

Now, we a able to define the MaxLA problem we will solve to compute the PTAS.

Maximum leaf assignment: (MaxLA)

Input:

an unlabeled compressed tree Tk with a feasible mapping sTk, a set of preassigned leaves P(Iv), and a set A(Iv), for each leaf-set Iv, a set Γ, a relation graph R, a specie tree S;

Output:

a compressed tree Gk obtained from Tk by assigning leaves of Γ to the leaf-set of Tk, where for each leaf-set Iv only leaves of A(Iv) are assigned to Iv, such that, A(Gk,R) is maximized and each speciation node of Gk is S-consistent.

By Lemma 9, it follows that an optimal solution of MaxLA has a an agreement value of at least A(G,R)-64n2k, where G is the optimal solution of MaxEC.

A PTAS of MaxLA by smooth polynomial integer programming

Now, we present a PTAS for MaxLA. Consider an unlabeled compressed tree Tk, with the corresponding allowed sets A(Iv) and preassigned leaves P(Iv). We start by introducing the smooth polynomial integer programming technique [22].

A polynomial having degree c is called q-smooth, for a constant q>0, if the coefficients of each degree- monomial belongs to the interval [-qnc-,qnc-], for each with 1c.

First, we define some constants:

  • given a leaf-set Iv of Tk and Γ, a(Iv,l)=1 if lA(Iv) and 0 otherwise

  • given two leaf-sets Iv, Iw of Tk, r(Iv,Iw) is equal to 1 if lcaTk(Iv,Iw) is a speciation, else (if lcaTk(Iv,Iw) is a duplication) r(Iv,Iw) is equal to 0

  • given two leaf-sets Iv, Iw of Tk, t(Iv,Iw) is a constant equal to 0 if Iv and Iw are connected to the same two-set internal node, else it is equal to 1

  • given l1,l2Γ, e(l1,l2)=1 if l1l2E(R) and e(l1,l2)=0 otherwise

For each leaf-set Iv of Tk and each leaf lΓ, define a variable xIv,l that has value 1 if l is assigned to Iv, else is 0 (notice that xIv,l=1 if l is a leaf preassigned to Iv). Given l1,l2Γ, define

p(l1,l2)=IvIwxIv,l1a(Iv,l1)xIw,l2a(Iw,l2)r(Iv,Iw)e(l1,l2)t(Iv,Iw)+xIv,l1a(Iv,l)xIw,l2a(Iw,l2)(1-r(Iv,Iw))(1-e(l1,l2))t(Iv,Iw)

Now, assume that xIv,l1=1 and xIw,l2=1, where l1A(Iv), l2A(Iw), l1, l2 do not belong to the same two-set internal node and t(Iv,Iw)=1; it holds that p(l1,l2)=1 if and only if (1) the lca of Iv and Iw is a speciation (hence r(Iv,Iw)=1) and l1 and l2 are connected by an edge in R (hence e(l1,l2)=1) or (2) the lca of Iv and Iw is a duplication (hence r(Iv,Iw)=0) and there is no edge between l1 and l2 in R (hence e(l1,l2)=0).

Finally define p(x) as follows:

p(x)=l1,l2Lp(l1,l2)

The polynomial integer programming is defined as follows

p(x)is maximixed
vxIv,l=1lL
lxIv,l8n/k

The polynomial p(x) is 1-smooth.

Consider a solution for the smooth polynomial integer programming, given the correct unlabeled compressed tree Tk, the correct allowed sets A(Iv) and the correct sets of preassigned leaves P(Iv). For each ε, there is a polynomial time algorithm that produces a 0–1 assignment x to the leafset of Tk (hence a compressed tree Gk), such that p(x)OPT-εn2, where OPT is the maximum value of the smooth polynomial integer programming [22, 23].

Now, consider the labels assigned to different sets Iv. By Lemma 9, we have that the agreement between Gk and R is at least n28-64n2k. By Lemma 6, A(G,R)n28, where G is an optimal solution of MaxEC, hence it holds

A(Gk,R)A(G,R)-εn2-64n2k=A(G,R)1-εc-1ck

for a constant c0. By choosing ε sufficiently small, and k sufficiently large, the PTAS for MaxLA follows.

Now, what we have to show is that, starting from a solution Gk of MaxLA, it is possible to construct in polynomial time a gene tree G such that G is S-consistent and it has an agreement value not smaller than that of Gk.

Building a feasible solution

Consider a compressed tree Gk returned by the smooth polynomial integer programming. Next we show how to reconstruct a gene tree G which is consistent with S.

First, we consider only the set Γ of leaves lΓ that are assigned to a leaf-set Iv, with lA(Iv). Notice indeed that if a leaf is assigned to a leaf-set Iv with lA(Iv), then it will give a contribution 0 in the smooth polynomial integer program, as a(Iv,l1)=0, hence p(l1,l2)=0, for each other leaf in l2Γ. In this case, we construct a gene tree G only for the set of leaves Γ, then we construct a new gene tree G by joining G and a subtree G over leafset Γ\Γ such that the internal nodes of G and the root of G are all associated with a duplication.

We focus now on the set of labels Γ and assume that no leaf l is assigned to a leaf-set Iv such that lA(Iv). Starting from Gk we construct in polynomial time the corresponding gene tree G. G is computed by replacing each leaf-set Iv of Gk with a subtree labeled by the set L(Iv) of leaves that belong to Iv (see Fig. 4).

Fig. 4.

Fig. 4

A compressed tree Gk and the gene tree G computed starting from Gk

Consider the tree Gk, a leaf set Iz of Gk connected to a node u of Gk and the set L(Iz) of leaves assigned to Iz. We replace Iz by a subtree T isomorphic to S|L(Iz); each internal node of T is labeled as Dup. Notice that the root of T is connected to u.

As a last step, if d>1 copies of a label l belongs to a leaf set Iv, then we construct a subtree with d leaves all labeled by l, whose internal nodes are all associated with duplications.

We prove that the gene tree G constructed is S-consistent.

Lemma 10

The tree G computed starting from Gk is S-consistent.

Proof

In order to ensure the S-consistency of G, we must prove that for each node v of G with evG(v)=Spec, each child of v is mapped to a proper descendant of sG(v).

Consider a node v of G corresponding to an internal node v of Gk such that evG(v)=Spec and evGk(v)=Spec and v is not part of a two-set internal node. We claim that v represents a speciation with respect to the species tree S. Let ch(v) be the set of children of v. Assume that sG(v)=x, and that sG(w)=x, for some wch(v). We show that x is a proper descendant of x. Assume to the contrary that x and x are the same node. We claim that there exists a leaf l that is assigned to Iz, with lA(Iz), for some leaf-set of Gwk, where w is the node of Gk corresponding to w. If the claim holds, then by construction a(Iz,l)=0 and this would contradict our earlier remark on such nodes not belonging to Γ.

Hence, we must prove the claim: if x and x are the same node of S, then there exists a leaf lΓ and a leaf-set Iz in Gwk, such that l is assigned to Iz, with lA(Iz). Assume that this is not the case. Since v is a speciation in Gk, it follows that the preassigned leaves define a mapping sGk of v and w in two different nodes of S. Let sGk(w)=y, where y is a proper descendant of x. Since sG(v)=sG(w), it follows that there exists a leaf l of Γ not in L(Sz) that is assigned to a leaf-set Iz in Gwk, otherwise w would be mapped in y. Hence the claim holds.

Consider now the case that v belongs to a two-set internal node u,v. Since u,v is a two-set internal node, evGk(v)=Spec and evGk(u)=Dup. Moreover, let Iz be the leafset connected to v. Let z be the root of the subtree of G isomorphic to S|L(Iz) that replaced the Iz leaf-set. Note that z is a child of v. Let q be the other child of v, and let q be the node of Gk corresponding to q.

Similarly to the previous case if sG(v)=sG(z) or sG(v)=sG(q), then we claim that there exists a leaf l that is assigned to Iw with lA(Iw) for either Iw=Iz or for some leaf-set Iw in Gqk. In order to prove the claim, first notice that, by definition, the set A(Iz) contains only leaves of L(Sx)\L(Sy), where x and y are the nodes of S where v and q are mapped by sGk. Therefore, if sG(z) is not a proper descendant of x, there must be a leaf lA(Iz) assigned to Iz. Similarly, if sG(q) is not a proper descendant of x, because sGk(q)=y is a proper descendant of x, there must be a leaf l assigned to Iw in Gqk such that lA(Iw) (otherwise, q would be mapped to y). We can conclude that the lemma holds.

Conclusion

We considered the minimization weighted and maximization unweighted variants of the problems of editing a relation graph for satisfiability and consistency. We provided complexity and algorithmic results for these variants. We showed that the problems that ask for the minimization of corrections on a weighted graph do not admit a constant factor approximation algorithm assuming the unique game conjecture and we gave an n-approximation algorithm, n being the number of vertices in the graph. We then provided polynomial time approximation schemes for the maximization variants of for unweighted graphs.

For future investigations, there are several interesting problems both from a theoretical and experimental point of view. First, from a theoretical point of view, it is open whether the minimization variant on unweighted graphs is approximable within constant factor or not. Moreover, another interesting direction would be to study whether it is possible to close the gap between the inapproximability result we have proved and the n-approximation algorithm.

From an experimental point of view, the main open problem is to test our approach to weighted graphs, and in particular to give a definition of weights that integrate those defined in different methods for orthology detection.

Authors’ contributions

RD, ML and NE modeled the problems presented, designed the algorithms and the hardness proofs and wrote the papers. All authors read and approved the final manuscript.

Acknowledgements

Not applicable.

This paper is a full version of the extended abstract published in the proceedings of the WABI2016 conference.

Competing interests

The authors declare that they have no competing interests.

Funding

Publication of this work is funded by the Natural Sciences and Engineering Research Council of Canada (NSERC) and the Fonds de Recherche Nature et Technologies of Quebec (FRQNT).

Contributor Information

Riccardo Dondi, Email: riccardo.dondi@unibg.it.

Manuel Lafond, Email: lafonman@iro.umontreal.ca.

Nadia El-Mabrouk, Email: mabrouk@iro.umontreal.ca.

References

  • 1.Ohno S. Evolution by gene duplication. Berlin: Springer; 1970. [Google Scholar]
  • 2.Goodman M, Czelusniak J, Moore GW, Romero-Herrera AE, Matsuda G. Fitting the gene lineage into its species lineage, a parsimony strategy illustrated by cladograms constructed from globin sequences. Syst Zool. 1979;28:132–163. doi: 10.2307/2412519. [DOI] [Google Scholar]
  • 3.Tatusov RL, Galperin MY, Natale DA, Koonin EV. The COG database: a tool for genome-scale analysis of protein functions. Nucl Acids Res. 2000;28:33–36. doi: 10.1093/nar/28.1.33. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 4.Li L, Stoeckert CJJ, Roos DS. OrthoMCL: identification of ortholog groups for eukaryotic genomes. Genome Res. 2003;13:2178–2189. doi: 10.1101/gr.1224503. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 5.Berglund AC, Sjolund E, Ostlund G, Sonnhammer EL. InParanoid 6: eukaryotic ortholog clusters with inparalogs. Nucl Acids Res. 2008;36:D263–D266. doi: 10.1093/nar/gkm1020. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 6.Lechner M, Findeiß S, Steiner L, Marz M, Stadler PF, Prohaska SJ. Proteinortho: detection of co-orthologs in large-scale analysis. BMC Bioinf. 2011;12(1):1. doi: 10.1186/1471-2105-12-124. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 7.Lafond M, Semeria M, Swenson KM, Tannier E, El-Mabrouk N. Gene tree correction guided by orthology. BMC Bioinf. 2013;14(supp 15):S5. doi: 10.1186/1471-2105-14-S15-S5. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 8.Lafond M, Swenson K, El-Mabrouk N. Error detection and correction of gene trees. In: Chauve C, El Mabrouk N, Tannier E, editors. Models and algorithms for genome evolution. London: Springer; 2013. [Google Scholar]
  • 9.Consortium TGO. Gene ontology: tool for the unification of biology. Nat Genet. 2000;25(1):25–29. doi: 10.1038/75556. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 10.Lafond M, El-Mabrouk N. Orthology and paralogy constraints: satisfiability and consistency. BMC Genomics. 2014;15(Suppl 6):12. doi: 10.1186/1471-2164-15-S6-S12. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 11.Hernandez-Rosales M, Hellmuth M, Wieseke N, Huber KT, Moulton V, Stadler PF. From event-labeled gene trees to species trees. BMC Bioinf. 2012;13(Suppl 19):6. [Google Scholar]
  • 12.Hellmuth M, Hernandez-Rosales M, Huber K, Moulton V, Stadler P, Wieseke N. Orthology relations, symbolic ultrametrics, and cographs. J Math Biol. 2013;66(1–2):399–420. doi: 10.1007/s00285-012-0525-x. [DOI] [PubMed] [Google Scholar]
  • 13.Hellmuth M, Wieseke N, Lechner M, Lenhof H-P, Middendorf M, Stadler PF. Phylogenomics with paralogs. Proc Natl Acad Sci. 2014;112(7):2058–2063. doi: 10.1073/pnas.1412770112. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 14.Liu Y, Wang J, Guo J, Chen J. Complexity and parameterized algorithms for cograph editing. Theor Comput Sci. 2012;461:45–54. doi: 10.1016/j.tcs.2011.11.040. [DOI] [Google Scholar]
  • 15.Natanzon A, Shamir R, Sharan R. Complexity classification of some edge modification problems. Discret Appl Math. 2001;113(1):109–128. doi: 10.1016/S0166-218X(00)00391-7. [DOI] [Google Scholar]
  • 16.Alon N, Stav U. Hardness of edge-modification problems. Theor Comput Sci. 2009;410(47–49):4920–4927. doi: 10.1016/j.tcs.2009.07.002. [DOI] [Google Scholar]
  • 17.Lafond M, Dondi R, El-Mabrouk N. The link between orthology relations and gene trees: a correction perspective. Algorithms Mol Biol. 2016;11(1):1. doi: 10.1186/s13015-016-0067-7. [DOI] [PMC free article] [PubMed] [Google Scholar]
  • 18.Fitch WM. Homology: a personal view on some of the problems. Trends Genet. 2000;16(5):227–231. doi: 10.1016/S0168-9525(00)02005-9. [DOI] [PubMed] [Google Scholar]
  • 19.Chawla S, Krauthgamer R, Kumar R, Rabani Y, Sivakumar D. On the hardness of approximating multicut and sparsest-cut. Comput Complex. 2006;15(2):94–114. doi: 10.1007/s00037-006-0210-9. [DOI] [Google Scholar]
  • 20.Corneil DG, Perl Y, Stewart LK. A linear recognition algorithm for cographs. SIAM J Comput. 1985;14(4):926–934. doi: 10.1137/0214065. [DOI] [Google Scholar]
  • 21.Stoer M, Wagner F. A simple min-cut algorithm. J ACM. 1997;44(4):585–591. doi: 10.1145/263867.263872. [DOI] [Google Scholar]
  • 22.Arora S, Frieze AM, Kaplan H. A new rounding procedure for the assignment problem with applications to dense graph arrangement problems. Math Program. 2002;92(1):1–36. doi: 10.1007/s101070100271. [DOI] [Google Scholar]
  • 23.Jiang T, Kearney PE, Li M. A polynomial time approximation scheme for inferring evolutionary trees from quartet topologies and its application. SIAM J Comput. 2000;30(6):1942–1961. doi: 10.1137/S0097539799361683. [DOI] [Google Scholar]
  • 24.Bonizzoni P, Vedova GD, Dondi R, Jiang T. On the approximation of correlation clustering and consensus clustering. J Comput Syst Sci. 2008;74(5):671–696. doi: 10.1016/j.jcss.2007.06.024. [DOI] [Google Scholar]

Articles from Algorithms for Molecular Biology : AMB are provided here courtesy of BMC

RESOURCES