I am doing research on a new method of optimizing sequence alignment process (Needleman - Wunsch algorithm) but the idea would only work with sequences that have the same length. I am wondering if that will have any real-life utility. Specifically, how often do we have those situations where we are aligning same-length sequences (or at least sub-sequences) and what are those situations?

  • $\begingroup$ Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. $\endgroup$
    – Community Bot
    Nov 15, 2023 at 20:52
  • $\begingroup$ This is an open-ended question that will lead to opinion-based answers, which doesn't fit well with the Stack Exchange format. Could you please change your question to relate to a specific situation or problem? If that can't be done, I recommend instead asking this question on a more discussion-based site like reddit. $\endgroup$
    – gringer
    Nov 16, 2023 at 4:24
  • $\begingroup$ Why do you choose the Needleman-Wunsch algorithm? Are you thinking of using a computer programing/ AI/ML approach to this question and project? When you mention algorithm, I think more of a Python AI/ML approach. $\endgroup$ Nov 16, 2023 at 14:13

2 Answers 2


I see ... the application is if two genes had the same number of indels* at different homologous positions within the gene. This happens but equally one gene might have an indel and another gene might lack it, in which case these genes would be different lengths.

So just to reiterate your method would find genes with an identical number of indels at different homologous positions in a gene. Its application is protein modelling. This is because indels cause a large change in the entropy of a protein, so even if these two genes had identical sequence (barring the indels obviously) they would be structurally different.

Beyond this however the application is limited because apart from the known changes to protein structure, little is understood about quantifying the function of indels. Certainly in phylogenetics we specifically avoid them, because we struggle to fit them into a known model.

*, indel = insertion deletion event. In a protein they occur in triplets.


My 2 cents: Sequence alignment is a well studied problem in bioinformatics with some great existing methods that do handle uneven length sequences (i.e. indels). With tons of genomic data the trend these days is towards faster methods with more heuristics like pseudo-alignment or k-mer based approaches rather than theoretically optimal but slow and unscalable approaches like Needleman Wunsch. There might be some niche applications on DNA motifs or short peptide analyses but I think these are quite limited.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.