# DNA arrangement problem (ATGC)

Our genetic material, DNA, is formed from a $4$ letter alphabet" of bases: A, T, G, C (adenine, thymine, guanine, and cytosine). The order in which the letters are arranged is important, but because a molecule can move, there is no difference between a sequence and the same sequence reversed. How many distinct DNA sequences of $5$ bases are there?

The only bit I've gotten so far is $4^5$ I have no idea how to start with the palindrome. Can anyone walk me through on the thought process please?

Thank you

• DNA strands are directional, so regardless of rotation they have a start and end. Double-stranded DNA has a start point at both ends, but the nucleotides are complementary, so GC rotated around is actually TA.
– jjrv
Mar 20, 2018 at 7:48
• Because of the directional strands, there are $4^5$ distinct single-strand DNA molecules 5 bases long. For double-strand DNA the answer marked as correct stands, but remember that each non-"palindrome" molecule has 2 different ways to interpret it, depending on orientation. Also, the first and last bases of a "palindrome" are NOT the same.
– jjrv
Mar 20, 2018 at 8:06

There are $4^5=1024$ sequences where $4^3=64$ are palindromic since such a sequence is determined once the first $3$ bases are determined.

Each of the remaining $960$ is the reverse of one of the other $959$ sequences, so there are $$64 + \frac{960}{2} = 544$$

such sequences.

• I don't quite get the 960 divided by 2 part. Shouldn't 1024 - 64 already took care of the "reverse is the same " requirement? Why are you still dividing 960 by 2 and adding 64? Mar 20, 2018 at 4:16
• Consider a non-palindrome "A,T,G,G". Then "G,G,T,A" is considered the same. We need to only count one of these. On the other hand, let's consider a palindrome "A,T,T,A". Then this will only be listed once if write out every single combination of four letter sequences.
– Remy
Mar 20, 2018 at 4:23
• Ahh I get it now, if we divide 1024 by two we unnecessarily divided palindromic cases by 2. That's what we first start off by subtracting out the palindromic cases then adding it back in after we divided out non-palindrome cases. Thank you for elucidating this concept to me! Mar 20, 2018 at 4:33
• Yep, that's correct! Glad I could help.
– Remy
Mar 20, 2018 at 4:34

How many sequences are there that read forward the same as backwards? There are 4 choices for the first base, but only one for the fifth, because it must be the same as the first, then there are 4 choices for the second base ...

• So following that train of thought I got 4 choices for 1st base 4 choices for 2nd base, 4 choice for 3rd base 1 choice for 4th, and 1 choice for 5th? Mar 20, 2018 at 3:48
• That's correct. Mar 20, 2018 at 3:51