A sequence alignment places nucleotide sequences or protein sequences in correspondence for comparison. The choice of corresponding positions affects evolutionary inference; matching a short stretch alone does not establish common descent of entire organisms.
Store a maximizing predecessor at each dynamic programming table entry. A diagonal predecessor emits a pair of letters; a vertical or horizontal predecessor emits a letter opposite a gap. Construct the columns in reverse and then reverse the output. For global sequence alignment without mismatches, start at the full-prefix entry and stop at the origin. For local sequence alignment without mismatches, start at any largest entry and stop at a zero entry. Each move decreases a prefix index, so at most moves are needed after the table is built.
Choose one contiguous substring from each string and align them under the same matching and gap rules as global sequence alignment without mismatches. Let maximize the score over aligned suffixes of the two prefixes. Zero permits a fresh empty alignment; the other cases extend one ending at adjacent prefix indices. The answer is the largest table entry, which can occur before either input ends. Starting all boundaries at zero yields time for positive lengths. Alignment traceback stops on reaching zero.
Align two complete strings using matching letters or a letter opposite a gap, with no unequal-letter columns and no double-gap columns. Give each match score one and each gap penalty . The dynamic programming table for prefixes starts with and . Its last-column cases give the displayed recurrence, where the diagonal candidate is omitted on a mismatch. Construction takes time for positive lengths and space with full alignment traceback.
An alignment with matches has gaps and score . Therefore a longest common subsequence determines its optimum. A finite mismatch penalty would solve a different problem.
For an amino acid alignment, this relative entropy measures departure of the nongap empirical distribution in a column from the uniform distribution on the twenty standard amino acids.
The proportion of entries in an alignment column, or columns in a pairwise alignment, that are counted as gaps under a stated convention.
Similarity of aligned sequence positions according to a specified scoring rule. Positive substitution score, chemical similarity and identical characters are different possible criteria.
The fraction of the chosen alignment columns containing identical nongap characters, with the denominator convention stated explicitly.
A fitting sequence alignment aligns all of a short query to a substring of a longer target, leaving target flanks unpenalized. It differs from unrestricted local sequence alignment, which may also omit part of the query.
A local sequence alignment finds the highest-scoring pair of subsequences, allowing unmatched flanks.
The FASTA sequence search algorithm locates promising matching words and diagonals before refining a limited set of alignments. The FASTA format is a separate sequence-file convention.
A global sequence alignment optimizes the correspondence across both complete input sequences, including their ends.
A gap penalty is the score cost of introducing an insertion or deletion into a sequence alignment.
An affine gap penalty charges for the first position of a gap and for each additional position. With , one long gap costs less than several separate gaps of the same total length. Some software instead uses ; numerical settings must be interpreted with their convention.
A substitution matrix assigns a score to aligning each pair of sequence symbols. Scores based on logarithms of observed-to-background pair frequencies turn products of relative support into additive alignment scores.
A sequence alignment that permits gaps corresponding to removed introns when matching processed RNA reads to a genome. Short microexons require particular care because their supporting aligned segments can be very small.

Articles by others on the same topic (2)

Sequence alignment is a bioinformatics method used to arrange sequences of DNA, RNA, or proteins to identify regions of similarity and difference. This process is crucial for understanding evolutionary relationships, functional similarities, and structural characteristics among biological sequences. There are two primary types of sequence alignment: 1. **Global Alignment**: This method aligns sequences from start to finish, ensuring that every residue in the sequences is aligned. It is typically used when comparing sequences that are of similar length and contain many conserved regions.
Sequence alignment by Ciro Santilli 40 Updated 2025-07-16
Sequence alignment is trying to match a DNA or amino acid sequence, even though the sequences might not be exactly the same, otherwise it would be a straight up string-search algorithm.
This is fundamental in bioinformatics for two reasons: