Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Subsequence
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Applications == Subsequences have applications to [[computer science]],<ref name="substrVsSubseq">In computer science, ''[[string (computer science)|string]]'' is often used as a synonym for ''sequence'', but it is important to note that ''[[substring]]'' and ''subsequence'' are not synonyms. Substrings are ''consecutive'' parts of a string, while subsequences need not be. This means that a substring of a string is always a subsequence of the string, but a subsequence of a string is not always a substring of the string, see: {{cite book | last = Gusfield | first = Dan | orig-year = 1997 | year = 1999 | title = Algorithms on Strings, Trees and Sequences: Computer Science and Computational Biology | publisher = Cambridge University Press | location = USA | isbn = 0-521-58519-8 | pages = 4}}</ref> especially in the discipline of [[bioinformatics]], where computers are used to compare, analyze, and store [[DNA]], [[RNA]], and [[protein]] sequences. Take two sequences of DNA containing 37 elements, say: :<samp>SEQ<sub>1</sub> = ACGGTGTCGTGCTATGCTGATGCTGACTTATATGCTA</samp> :<samp>SEQ<sub>2</sub> = CGTTCGGCTATCGTACGTTCTATTCTATGATTTCTAA</samp> The longest common subsequence of sequences 1 and 2 is: :<samp>LCS<sub>(SEQ<sub>1</sub>,SEQ<sub>2</sub>)</sub> = '''CGTTCGGCTATGCTTCTACTTATTCTA'''</samp> This can be illustrated by highlighting the 27 elements of the longest common subsequence into the initial sequences: :<samp>SEQ<sub>1</sub> = A'''{{font color|red|CG}}'''G'''{{font color|red|T}}'''G'''{{font color|red|TCG}}'''T'''{{font color|red|GCTATGCT}}'''GA'''{{font color|red|T}}'''G'''{{font color|red|CT}}'''G'''{{font color|red|ACTTAT}}'''A'''{{font color|red|T}}'''G'''{{font color|red|CTA}}'''</samp> :<samp>SEQ<sub>2</sub> = '''{{font color|red|CGTTCGGCTAT}}'''C'''{{font color|red|G}}'''TA'''{{font color|red|C}}'''G'''{{font color|red|TTCTA}}'''TT'''{{font color|red|CT}}'''A'''{{font color|red|T}}'''G'''{{font color|red|ATT}}'''T'''{{font color|red|CTA}}'''A</samp> Another way to show this is to ''align'' the two sequences, that is, to position elements of the longest common subsequence in a same column (indicated by the vertical bar) and to introduce a special character (here, a dash) for padding of arisen empty subsequences: :<samp>SEQ<sub>1</sub> = ACGGTGTCGTGCTAT-G--C-TGATGCTGA--CT-T-ATATG-CTA-</samp> :<samp> | || ||| ||||| | | | | || | || | || | ||| </samp> :<samp>SEQ<sub>2</sub> = -C-GT-TCG-GCTATCGTACGT--T-CT-ATTCTATGAT-T-TCTAA</samp> Subsequences are used to determine how similar the two strands of DNA are, using the DNA bases: [[adenine]], [[guanine]], [[cytosine]] and [[thymine]].
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)