Results 1 to 5 of 5
Like Tree1Thanks
  • 1 Post By Plato

Math Help - How many possibilities are there for dividing a string to substrings, of any length?

  1. #1
    Member
    Joined
    Nov 2012
    From
    israel
    Posts
    164
    Thanks
    2

    How many possibilities are there for dividing a string to substrings, of any length?

    Hi.
    I just can wrap my head around this.

    Let S be a string of length n:

    S=\sigma_1\sigma_2... \sigma_n

    how many possibilities are there for dividing it to substrings?
    for example:
    S_1=\sigma_1\sigma_2\hspace{12pt} S_2=\sigma_3...\sigma_i\hspace{12pt} S_3=\sigma_{i+1}...\sigma_n
    is one division, and:
    S_1=\sigma_1 \hspace{12pt}S_2=\sigma_2...\sigma_n
    is another.
    how many like that are there?

    I can't think of anything and could really use some help here.
    Thanks in anvanced!
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Member
    Joined
    Nov 2012
    From
    israel
    Posts
    164
    Thanks
    2

    Re: How many possibilities are there for dividing a string to substrings, of any leng

    Never mind...
    found it.
    It's 2^{n-1}
    Follow Math Help Forum on Facebook and Google+

  3. #3
    MHF Contributor

    Joined
    Aug 2006
    Posts
    18,969
    Thanks
    1788
    Awards
    1

    Re: How many possibilities are there for dividing a string to substrings, of any leng

    Quote Originally Posted by Stormey View Post
    Let S be a string of length n:
    S=\sigma_1\sigma_2... \sigma_n
    how many possibilities are there for dividing it to substrings?
    for example:
    S_1=\sigma_1\sigma_2\hspace{12pt} S_2=\sigma_3...\sigma_i\hspace{12pt} S_3=\sigma_{i+1}...\sigma_n
    is one division, and: S_1=\sigma_1 \hspace{12pt}S_2=\sigma_2...\sigma_n
    is another. how many like that are there?
    Here is one string S=\sigma_1\sigma_2... \sigma_n.

    You gave another: S_1=\sigma_1{\color{red}|}~S_2=\sigma_2... \sigma_n

    We can "move" the {\color{red}|} to n-2 positions on the original string to get a total of n-1 decompositions of into two strings.

    Now put two {\color{red}|,~|} to \binom{n-1}{2} positions on the original string to get a total of \binom{n-1}{2} decompositions of into three strings.

    In fact you can put as many as n-1 of those red bars into the original string. Add them up.
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Member
    Joined
    Nov 2012
    From
    israel
    Posts
    164
    Thanks
    2

    Re: How many possibilities are there for dividing a string to substrings, of any leng

    Hi Plato, thanks for the help.

    according to what you're saying, it's \sum_{k=0}^{n-1}\binom{n-1}{k}, which is 2^{n-1}.
    Last edited by Stormey; November 14th 2013 at 09:28 AM.
    Follow Math Help Forum on Facebook and Google+

  5. #5
    MHF Contributor

    Joined
    Aug 2006
    Posts
    18,969
    Thanks
    1788
    Awards
    1

    Re: How many possibilities are there for dividing a string to substrings, of any leng

    Quote Originally Posted by Stormey View Post
    according to what you're saying, it's \sum_{k=0}^{n-1}\binom{n-1}{k}, which is 2^{n-1}.
    Yes exactly.
    It is well known that \sum_{k=0}^{N}\binom{N}{k}=2^{N}.
    That is the number of subsets of a set of N elements.
    Thanks from Stormey
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Replies: 13
    Last Post: May 12th 2011, 05:32 AM
  2. Bit String Length
    Posted in the Discrete Math Forum
    Replies: 1
    Last Post: December 3rd 2009, 12:19 PM
  3. How many different possibilities?
    Posted in the Statistics Forum
    Replies: 0
    Last Post: November 16th 2009, 03:37 PM
  4. possibilities
    Posted in the Statistics Forum
    Replies: 2
    Last Post: September 20th 2009, 05:09 AM
  5. Length of string around circular rod
    Posted in the Geometry Forum
    Replies: 8
    Last Post: December 15th 2008, 11:13 AM

Search Tags


/mathhelpforum @mathhelpforum