Finding a formula for a sequence with recurring digits

In summary, to determine the sequence for a given number, one needs to find the ceiling and round function for that number.
  • #1
spiritzavior
10
0
how do i determine the formula for the sequence below?

1,1,2,2,2,2,3,3,3,3,3,4,4,4,4,4,4,4,4,...,n,n,n,n,n,...,n,...

need some instructions. thanks in advance
 
Physics news on Phys.org
  • #2
Ok, there are subsequences of equal entries (increasing by one) in a row, and the numbers of equal entries in each of them form the following sequence:

2, 4, 5, 8, ...

I can't see any regularity. Sorry.
 
  • #3
I can't see a pattern here: you have two 1s, four 2s, five 3s and eight 4s. Can you confirm that you've written it out correctly?
 
  • #4
spiritzavior said:
how do i determine the formula for the sequence below?

1,1,2,2,2,2,3,3,3,3,3,4,4,4,4,4,4,4,4,...,n,n,n,n,n,...,n,...

need some instructions. thanks in advance
Seems like one too many 2's with n-1 repeated F(n+1) times for n = 2,3,4,5,... .
 
Last edited:
  • #5
haruspex said:
I can't see a pattern here: you have two 1s, four 2s, five 3s and eight 4s. Can you confirm that you've written it out correctly?

sorry, I've typed it incorrectly, it should be:

1,1,2,2,2,2,3,3,3,3,3,3,4,4,4,4,4,4,4,4,...

two 1s, four 2s, six 3s, eight 4s,...
 
  • #6
If you don't mind the use of [] (integer part of) it's [1/2 +√(n-3/4)]
 
  • #7
So, there are [itex]2 n[/itex] n's. The total number of elements no smaller than n is:
[tex]
\sum_{k = 1}^{n}{2 k} = n(n + 1)
[/tex]

Thus, all the elements with an index k that satisfies:
[tex]
(n - 1) n < k \le n (n + 1)
[/tex]
are equal to [itex]x_k = n[/itex] (why?). Can you find n, given k from the above inequalities?
[tex]
n^2 + n - k \ge 0 \Rightarrow n \ge -\frac{1}{2} + \sqrt{k + \frac{1}{4}}
[/tex]
[tex]
n^2 - n - k < 0 \Rightarrow n < \frac{1}{2} + \sqrt{k + \frac{1}{4}}
[/tex]

If you know the [STRIKE]floor[/STRIKE] floor function, which is the same as integer part for positive integers, you should be able to deduce:
[tex]
x_k = \mathrm{Ceiling} \left[ \sqrt{k + \frac{1}{4}} - \frac{1}{2}\right]
[/tex]
 
Last edited:
  • #8
[itex] a(n) = round(\sqrt{n})[/itex] seems to work, not that I could prove it.

This is where a(1) is the first entry in the sequence.
 
  • #9
acabus said:
[itex] a(n) = round(\sqrt{n})[/itex] seems to work, not that I could prove it.

This is where a(1) is the first entry in the sequence.

Good intuition abacus...

A000194 n appears 2n times; also nearest integer to square root of n
http://oeis.org/A000194

If one desires that digits are repeated 2n - 1 times, that's an easy one: floor [sqrt n]
 
  • #10
The definition of ceiling and round functions is:
[tex]
\mathrm{Ceiling}(x) \equiv n, \ n \le x < n + 1
[/tex]
[tex]
\mathrm{Round}(x) \equiv m, \ \vert x - m \vert < 1/2
[/tex]
(the last definition is ambiguous if the argument is half-integer, but there can never happen for acabus's argument)

We want to know for what x, and y, [itex]\mathrm{Ceiling}(x) \stackrel{?}{=} \mathrm{Round}(y) = n[/itex]. From the above definitions, this happens when:
[tex]
n \le x < n + 1, \ n - 1/2 < y < n + 1/2
[/tex]
or, if we rewrite these inequalities for n, we get:
[tex]
x - 1 < n \le x, \ y - 1/2 < n < y + 1/2
[/tex]
Then, a necessary and sufficient (why?) condition is:
[tex]
x - 1 < y + 1/2, \ y - 1/2 < x
[/tex]

In our case, [itex]x = \sqrt{k + 1/4} - 1/2[/itex], and [itex]y= \sqrt{k}[/itex], so we have:
[tex]
\sqrt{k + 1/4} - 1/2 - 1 < \sqrt{k} + 1/2 \Leftrightarrow \sqrt{k + 1/4} - \sqrt{k} < 2
[/tex]
[tex]
\sqrt{k} - 1/2 < \sqrt{k + 1/4} - 1/2 \Leftrightarrow \sqrt{k + 1/4} - \sqrt{k} > 0
[/tex]
The second inequality is surely true, but the first is proven as follows:
[tex]
\begin{array}{l}
\sqrt{k + 1/4} - \sqrt{k} \stackrel{?}{<} 2 \\

0 < \sqrt{k + 1/4} \stackrel{?}{<} \sqrt{k} + 2 \\

k + 1/4 \stackrel{?}{<} k + 4 \sqrt{k} + 4 \\

0 \stackrel{\surd}{<} \sqrt{k} + 15/16
\end{array}
[/tex]
This is surely true. Therefore, both the formulas give the same output for all positive integers.
 
  • #11
Thanks all for your responses.
 

Related to Finding a formula for a sequence with recurring digits

What is a sequence with recurring digits?

A sequence with recurring digits is a mathematical pattern where certain numbers or digits repeat in a specific order. For example, the sequence 1, 4, 7, 1, 4, 7, 1, 4, 7 has the digits 1, 4, and 7 repeating.

Why is finding a formula for a sequence with recurring digits important?

Finding a formula for a sequence with recurring digits can help us predict future terms in the sequence without having to manually find each term. It also allows us to generalize the sequence and apply it to other mathematical problems.

What are some techniques for finding a formula for a sequence with recurring digits?

Some techniques for finding a formula for a sequence with recurring digits include using algebraic manipulation, creating a table of values and looking for patterns, and using mathematical concepts such as arithmetic and geometric sequences.

What if I can't find a formula for a sequence with recurring digits?

If you are unable to find a formula for a sequence with recurring digits, you can try using a different approach or seeking help from a math expert. Sometimes, certain sequences may not have a simple formula and can only be described as a recurring pattern.

How can I apply a formula for a sequence with recurring digits to real-life situations?

A formula for a sequence with recurring digits can be applied to real-life situations in various fields such as finance, physics, and computer science. For example, in finance, a formula for a recurring sequence can be used to calculate compound interest on investments. In physics, it can be used to model the behavior of oscillating systems. In computer science, it can be used to generate random numbers for simulations or encryption algorithms.

Similar threads

Replies
1
Views
959
  • Linear and Abstract Algebra
Replies
2
Views
1K
  • Linear and Abstract Algebra
Replies
2
Views
519
  • Calculus and Beyond Homework Help
Replies
1
Views
321
  • Linear and Abstract Algebra
Replies
9
Views
1K
  • Linear and Abstract Algebra
Replies
25
Views
1K
  • Calculus and Beyond Homework Help
Replies
8
Views
852
  • Linear and Abstract Algebra
Replies
4
Views
1K
  • Calculus and Beyond Homework Help
Replies
8
Views
2K
  • Precalculus Mathematics Homework Help
Replies
5
Views
945
Back
Top