-
Mar 26th, 2020, 05:01 AM
#1
Pattern: 1 2 6 14 27 46 72
What could be the formula for the following sequence of numbers: 1 2 6 14 27 46 72
-
Mar 26th, 2020, 07:48 AM
#2
Re: Pattern: 1 2 6 14 27 46 72
What do you think the formula should look like?
My initial stab at generating the series with code would be (using VB6):
Code:
Option Explicit
Private Sub Command1_Click()
Dim a As Integer, b As Integer, c As Integer, d As Integer
a = 1
b = 2
Debug.Print a
Debug.Print b
For c = 3 To 7
d = (b - a) + c
a = b
b = b + d
Debug.Print b
Next
End Sub
I don't know if that helps with determining a formula, or whether the above code could be simplified.
"Anyone can do any amount of work, provided it isn't the work he is supposed to be doing at that moment" Robert Benchley, 1930
-
Mar 26th, 2020, 09:15 AM
#3
Re: Pattern: 1 2 6 14 27 46 72
First step is to see if the differences of terms gives any insight into any formula used to generate the terms:
1 2 6 14 27 46 72
1st differences: 1 4 8 13 19 26
2nd differences: 3 4 5 6 7
3rd differences: 1 1 1 1
Since the 3rd differences are all equal, that means the formula used to generate the terms is of 3rd degree in the form of:
A(x) = a*x^3 + b*x^2 + c*x + d
You have been given A(1) = 1, A(2) = 2, A(3) = 6, A(4) = 14, ...
Using those given values, you can build a series of simultaneous equations that allow you to solve for the values of the coefficients a, b, c, and d.
a + b + c + d = 1
8*a + 4*b + 2*c + d = 2
27*a + 9*b + 3*c + d = 6
64*a + 16*b + 4*c + d = 14
That's as far as I'll go for now. Good luck!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|