Bioinformatics & Sequence Analysis

Pairwise Sequence Identity and Global Alignment Workbench

Compare equal-position records directly or construct one deterministic optimal global alignment with explicit match, mismatch, gap-open and gap-extension scores.

Biology · experimental measurements

Keep Hamming distance, exact identity, alignment columns and a visitor-entered scoring model distinct from biological homology or statistical significance.

Private calculations in your browser · explicit inputs and model boundaries
Example preview · Equal-length DNAEntered-position relationship
Exact identities6 columns
Substitutions2 columns

Bars partition every entered corresponding position into an exact identity or substitution; no gaps were inserted.

  1. 1EnterProvide the known values
  2. 2CalculateResults update automatically
  3. 3VerifyReview the details and units
Try an example

Calculation result

Enter valid values to see the result.

Your entries are calculated in this browser and are not submitted to 365CALCS.COM.

Feedback

Understand the relationship

The reasoning behind the result

Hamming distance requires corresponding positions

dH = Σ 1[Aᵢ ≠ Bᵢ]

Direct comparison does not insert gaps or search for a better correspondence. Its denominator is the shared entered length.

Identity percentage and Hamming distance are two summaries of the same exact-position ledger.

Global alignment optimizes the whole records

best(i,j) = max of diagonal, gap-in-A and gap-in-B states

Needleman–Wunsch dynamic programming examines the complete pair under one scoring scheme and returns an optimal end-to-end alignment.

The displayed deterministic tie rule selects one alignment when several have the same score; it does not imply that alignment is uniquely supported.

Affine gaps distinguish opening and extending

gap cost(n) = open + (n−1)extension

One run of several missing symbols is treated differently from several separate one-symbol gaps.

All rewards and penalties are visitor-entered and retained with the result.

Similarity is model dependent

Exact identity needs only equality. A broader protein similarity claim requires a named substitution matrix and interpretation; this workflow deliberately uses exact matches plus the entered scalar mismatch model.

An alignment score or identity percentage does not establish homology, function, ancestry or statistical significance.

Follow the numbers

Compare two equal-length DNA records

  1. Confirm both DNA records have eight corresponding positions.
  2. Compare each position without inserting gaps.
  3. Six positions match exactly and two differ.
  4. Hamming distance is 2.
  5. Exact identity is 6 ÷ 8 = 75%.

The result describes these entered positions; it does not test whether the records are homologous.

Quick guide

How to use this calculator

  1. Choose direct position comparison only when the records are already corresponding and equal in length.
  2. For global alignment, enter the complete scoring convention rather than relying on an unstated matrix.
  3. Inspect the alignment columns, gap runs and score components before interpreting the result.

Calculation method

Calculation and interpretation

Keep Hamming distance, exact identity, alignment columns and a visitor-entered scoring model distinct from biological homology or statistical significance.

Position mode: Hamming distance = unequal positions; identity = equal positions ÷ length. Global mode maximizes substitution scores minus gap-open + (length−1)×gap-extension penalties.

Worked example

Compare two equal-length DNA records

The result describes these entered positions; it does not test whether the records are homologous.

Position mode: Hamming distance = unequal positions; identity = equal positions ÷ length. Global mode maximizes substitution scores minus gap-open + (length−1)×gap-extension penalties.

Supported inputs

Precision and limits

Explicit comparison basis

Position mode requires equal lengths; global mode aligns both complete records under the entered score.

Exact alphabets

Canonical DNA/RNA or the 20 standard amino-acid symbols are accepted; ambiguity and pre-existing gap symbols are excluded.

Scalar substitution model

Global mode distinguishes exact matches from mismatches; BLOSUM, PAM and nucleotide ambiguity matrices are not supplied.

One deterministic optimum

Tied optimal alignments may exist; the workbench reports one reproducible traceback and does not enumerate all ties.

No biological inference

Identity and score do not establish homology, function, significance or an evolutionary model.

Computational support

Position mode supports 10,000 symbols per record; global dynamic programming supports 500 per record and at most 1,000 alignment columns.

Continue calculating

Related calculators