quote:
Originally posted by andrey
n(n+1)
2
Wrong.. Close though
(n+2)(n+3)/2
quote:
Originally posted by Bilbo
q=2^(n+2)
sequence starts from 8; so for n=0, I'd want 8. Then further, you said it should be multiplied by 2.
So the answers are..
1) (n+2)*(n+3)/2
2) 2^(n+3)
(sorry for taking this long but my net died
)
EDIT: This is assuming that for n=0, you want the first numbers in the sequence and then go hence forth
If you want those values for n=1, the answers would be..
1) (n+1)*(n+2)/2
2) 2^(n+2)
Explanation for answers... (assuming my initial assumption of first value coming at n=0 which is how it should be imo)
1) 1+2+3+...+n = n*(n+1)/2
for n=0, you have value 3 (which is 1+2)
The sequence hence forth remains the same. So basically for n=0, the sequence will give you the same output as n=2 in the above equation.. so just shift your equation by 2 places!
Hence the answer is
(n+2)*(n+3)/2
2) 8 = 2^3
Hence forth, values are multiples of 2.
So for n=0, you want 2^3. n=1, you want 2^4 ie 2^(n+3). So on and so forth.
The answer is
2^(n+3)