ArithProg | R Documentation |
The function generates a sequence of numbers, S_k
, which follow an arithmetic progression as shown below.
S_k = S_1 + (k - 1)d
ArithProg(st=0, n, d)
st |
The term, |
n |
Defines the no. of terms in the progression. |
d |
Denotes the difference term, |
The return type of the function is always a vector containing S_k,\,\,\, \forall k \in [1, n]
Chitran Ghosal
rm(list=ls())
v1 <- ArithProg(n=3,d=3)
v1
v2 <- ArithProg(st=11, n=10,d=3)
v2
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.