Skip to content

Sequence Alignmnet algorithm with dynamic programming approach and a more space efficient Divide and conquer plus DP approach.

Notifications You must be signed in to change notification settings

Aditi-hande/Sequence-Alignment-Algo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Sequence-Alignment-Algo

Sequence Alignmnet algorithm with dynamic programming approach and a more space efficient Divide and conquer plus DP approach.

A. Algorithm Description Suppose we are given two strings 𝑋 and π‘Œ, where 𝑋 consists of the sequence of symbols π‘₯ and consists of the sequence of symbols . 1, π‘₯2 , ... , π‘₯π‘š π‘Œ 𝑦1, 𝑦2 , ... , 𝑦𝑛 Consider the sets {1, 2, ... ,π‘š} and {1, 2, ... , 𝑛} as representing the different positions in the strings 𝑋 and π‘Œ, and consider a matching of these sets; Recall that a matching is a set of ordered pairs with the property that each item occurs in at most one pair. We say that a matching 𝑀 of these two sets is an alignment if there are no β€œcrossing” pairs: if (𝑖, 𝑗), (𝑖', 𝑗') Ο΅ 𝑀 and 𝑖 < 𝑖' , then 𝑗 < 𝑗'. Intuitively, an alignment gives a way of lining up the two strings, by telling us which pairs of positions will be lined up with one another. Our definition of similarity will be based on finding the optimal alignment between 𝑋 and π‘Œ, according to the following criteria. Suppose 𝑀 is a given alignment between 𝑋 and π‘Œ:

  1. First, there is a parameter Ξ΄ that defines a gap penalty. For each 𝑒 > 0 position of 𝑋or π‘Œ that is not matched in 𝑀 β€” it is a gap β€” we incur a cost of Ξ΄.
  2. Second, for each pair of letters 𝑝, π‘ž in our alphabet, there is a mismatch cost of Ξ± for lining up with . Thus, for each , we pay the π‘π‘ž 𝑝 π‘ž (𝑖, 𝑗) Ο΅ 𝑀 appropriate mismatch cost Ξ± for lining up with . One generally π‘₯𝑖𝑦𝑗 π‘₯𝑖 𝑦𝑗 assumes that Ξ± = 0 for each letter β€”there is no mismatch cost to line up 𝑝𝑝 𝑝 a letter with another copy of itselfβ€”although this will not be necessary in anything that follows.
  3. The cost of 𝑀 is the sum of its gap and mismatch costs, and we seek an alignment of minimum cost.

About

Sequence Alignmnet algorithm with dynamic programming approach and a more space efficient Divide and conquer plus DP approach.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages