I'm extremely new to DSP, so I apologise if it's a very basic question.
I'm having issues understanding the following exercise:
"Create an array of 201 samples containing a sin wave with a frequency , f, of 2 Hz, i.e. the period is 0.5 seconds. Use a sampling rate, fs of 100 Hz, i.e 100 samples per second. Use the numpy method arange to generate the array. The first step is to declare the variables for f and fs and then create an array of times for the samples in a 2 second range, i.e.
t = np.arange(−1,1+1/fs,1/fs)
which gives a array starting at -1 and ending at 1.01."
I get how you create a range in Python, and I get that the parameters are the starting value, the end value, and the steps. However, I'm not quite sure what this is doing: why does it start at -1? Why does it end at 1+1/fs? Why are the time steps 1/fs? And lastly, what exactly is this giving me? Just the times at which the wave is sampled?
I've tried Googling, but I don't really know what I should be looking for. Even a pointer to the right keyword to Google to answer those questions would be greatly appreciated.