 All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars  perplexus dot info  Term Sum Settlement (Posted on 2015-10-29) The sequence S1, S2,S3 ,...... is defined by:

S1 = 211, S2 = 375, S3= 420, S4 = 523, and:
Sn= Sn-1- Sn-2+ Sn-3- Sn-4

Find S531+ S753+ S975

 No Solution Yet Submitted by K Sengupta Rating: 3.0000 (1 votes) Comments: ( Back to comment list | You must be logged in to post comments.) Well, it could have been solved manually, but... | Comment 1 of 3
The values through S(14) show the numbers cycle with a period of 10, so all the S values whose subscripts end with the same digit have the same value. However, I had written the program before finding this out:

```subscript   value
5            2676           -2117           -3758           -4209           -52310          -26711           21112           37513           42014           52315           26716           -21117           -37518           -42019           -523531           211753           420975           267             ----total of 3    898```

Text1.Text = ""
crlf = Chr\$(13) + Chr\$(10)

a = 211: b = 375: c = 420: d = 523
For j = 5 To 975
DoEvents
e = d - c + b - a
a = b: b = c: c = d: d = e
If e > 10000000 Then
x = x
End If
If j < 20 Or j = 531 Or j = 753 Or j = 975 Then
Text1.Text = Text1.Text & j & "     " & e & crlf
If j > 20 Then tot = tot + e
End If
If j = 30 Then Text1.Text = Text1.Text & crlf
Next

Text1.Text = Text1.Text & tot & crlf & " done"

End Sub

 Posted by Charlie on 2015-10-29 14:31:45 Please log in:

 Search: Search body:
Forums (2)