Recurrence Relation for Two Consecutive 0s in Ternary Strings

Click For Summary
SUMMARY

The discussion focuses on deriving a recurrence relation for the number of ternary strings of length n that contain two consecutive 0s. The proposed relation is a_n = 2a_{n-1} + 2a_{n-2} + 3^{n-2}, which is debated against the book's answer of a_n = 2a_{n-1} + 2a_{n-2} + 2^{n-2}. The key point of contention is whether the definition includes multiple instances of consecutive 0s or just one instance. The correct interpretation hinges on the inclusion of isolated 0s in the string.

PREREQUISITES
  • Understanding of recurrence relations in combinatorics
  • Familiarity with ternary strings and their properties
  • Basic knowledge of exponential functions and their applications
  • Ability to analyze and interpret mathematical proofs
NEXT STEPS
  • Study combinatorial proofs related to recurrence relations
  • Explore the properties of ternary strings and their enumeration
  • Learn about generating functions and their application in combinatorial problems
  • Investigate variations of recurrence relations involving constraints on string patterns
USEFUL FOR

Mathematics students, combinatorial theorists, and anyone interested in string theory or recurrence relations in discrete mathematics.

Mr Davis 97
Messages
1,461
Reaction score
44

Homework Statement


Find a recurrence relation for the number of ternary strings of length n that contain two consecutive 0s.

Homework Equations

The Attempt at a Solution


Let ##a_n## count the number of ternary stings of length n that contain two consecutive 0s. Then, we can split the total number into mutually exclusive cases. If we start with 1 or 2, then we have ##a_{n-1}## in both cases. If we start with 01 or 02, then we have ##a_{n-2}## in both cases. If we start with 00, then we have ##3^{n-2}## possibilities for the other strings, since we already have two consecutive zeroes. Thus ##a_n = 2a_{n-1} + 2a_{n-2} + 3^{n-2}##.

However, apparently the solution is ##a_n = 2a_{n-1} + 2a_{n-2} + 2^{n-2}##. Is this correct or is mine correct?
 
Physics news on Phys.org
Perhaps they mean exactly one instance of 00, rather than one or more instances of 00. Under the latter (former) interpretation you (they) are correct.
 
  • Like
Likes   Reactions: Mr Davis 97
andrewkirk said:
Perhaps they mean exactly one instance of 00, rather than one or more instances of 00. Under the latter (former) interpretation you (they) are correct.
No, it still doesn't make the book answer correct. Even though there must be no more pairs of consecutive zeroes, there can still be isolated ones.
 

Similar threads

  • · Replies 11 ·
Replies
11
Views
4K
  • · Replies 2 ·
Replies
2
Views
2K
Replies
12
Views
4K
Replies
1
Views
2K
Replies
14
Views
5K
Replies
5
Views
2K
  • · Replies 19 ·
Replies
19
Views
4K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
Replies
3
Views
2K