Am i understanidng this right, counting strings

In summary, the conversation discusses the problem of considering the set of all strings of a's, b's, and c's and creating a list of these strings of lengths zero, one, two, and three that do not contain the pattern aa. It also asks for the number of strings of each length that do not contain aa and provides a recurrence relation for finding the number of strings of length k. Finally, it asks to use the previous information to find the number of strings of length four that do not contain aa.
  • #1
mr_coffee
1,629
1
Hello everyone. I'm not sure if I'm doing this right or not. The problem asks:

Consdier the set of all strings of a's, b's, and c's.

a. make a list of all of these strings of lengths zero, one, two, and three that do not contain the pattern aa.

Okay so i have the following:
note e: stands for empty
length 0: e
length 1: a; b; c;
length 2: {a,b}, {a,c}, {b,c}, {b,b}, {c,c}
okay for length 2, I'm confused, do they want all possibe like for instance:
is {a,b} equal to {b,a}? like {1,2} would be equal to {2,1} if we are just talking about sets, order doesn't matter but I'm not sure if they are talking about sets or not...

Length 3: {aba, abb, abc, aca, acb, acc, bab, bac,
bba, bbb, bbc, bca, bcb, bcc, bcab, cac, cba, cbb, cbc,
cca, ccb, ccc}

its also asking in part b:
For each integer n >= 0, let S_n = the number of strings of a's, b'c, and c's of length n that do not contain the pattern aa. Find S_O, S_1, S_2, and S_3

So would S_O = 1; S_1 = 3; S_2 = 5 or would string of length 2, that do not contain aa be more?
length 2: {a,b}, {a,c}, {b,c}, {b,b}, {c,c}
like: length 2: ab,ba,ac,ca,bc,cb,bb,cc
so S_2 = 8
and is S_3 = 22?

for part c its asking:
find a recurrence rleation for s_0, S_1, S_2...
and the answer is: [tex]s_{k} = 2*s_{k-1} + 2*s_{k-2}[/tex]

and for part D:

they are saying to use part b and c to find the number of strings of a's , b's, and c's of length four that do not contian the pattern aa.
But I thought I just foudn this in part a and b didn't i?
Thanks!
 
Last edited:
Physics news on Phys.org
  • #2
n/m i got it:
s_4 = 60

and i shouldn't treat them as sets, {a,b} ! = {b,a} in this case
 

What does it mean to "count strings" in a scientific context?

In a scientific context, "counting strings" refers to the process of determining the number of occurrences of a specific sequence of characters, or "strings", within a larger set of data or information. This can be used to analyze patterns, identify trends, and make predictions in various fields of study.

How is counting strings useful in scientific research?

Counting strings can be useful in scientific research because it allows researchers to identify and quantify patterns and relationships within data. This can help to reveal insights and connections that may not be immediately apparent and can aid in making predictions and drawing conclusions.

What are some common techniques for counting strings?

There are several techniques for counting strings, including manual counting, computer algorithms, and statistical analysis. Manual counting involves physically counting occurrences of a string, while computer algorithms use programming code to automate the process. Statistical analysis involves using mathematical models to calculate the frequency and significance of string occurrences.

What are some challenges associated with counting strings?

One challenge of counting strings is ensuring accuracy and consistency in the counting process. This can be especially difficult when dealing with large or complex datasets. Additionally, depending on the research question, there may be a need to account for variations in string length or account for similar but not identical strings.

How can counting strings be applied in different scientific disciplines?

Counting strings can be applied in a variety of scientific disciplines, including biology, genetics, linguistics, computer science, and psychology. In biology and genetics, counting strings can help identify genetic sequences and patterns. In linguistics, it can be used to analyze language patterns. In computer science, it can aid in data analysis and programming. In psychology, it can help to identify patterns in behavior or thought processes.

Similar threads

  • Precalculus Mathematics Homework Help
Replies
2
Views
1K
  • Engineering and Comp Sci Homework Help
Replies
3
Views
897
  • Special and General Relativity
3
Replies
75
Views
3K
  • Calculus and Beyond Homework Help
Replies
2
Views
1K
Replies
66
Views
4K
  • Introductory Physics Homework Help
Replies
7
Views
622
  • Introductory Physics Homework Help
Replies
6
Views
868
  • Set Theory, Logic, Probability, Statistics
Replies
27
Views
3K
  • Calculus and Beyond Homework Help
Replies
9
Views
1K
Replies
1
Views
491
Back
Top