tm = linspace(0,100,1000);

N0 = 100;
R0 = 0.05;

Nd_smth = N0*exp(R0*tm); 

plot(tm,Nd_smth)
M = length(Nd_smth);

%generate vals from random distr with mean= mn and stdv=stdv
rng('default'); %fix seed for random # generator to matlab startup seed
mn = 0; %mean
stdv = 1000;

r_pb = mn + stdv.*randn(1,M); 

Nd = r_pb+Nd_smth;

plot(tm,Nd,'x')

tmss = tm(1:5:length(tm));
Ndss = Nd(1:5:length(Nd));

plot(tmss,Ndss,'x')
m=length(tmss);

tm = tmss;
Nd = Ndss;

% tm = partition of time interval
% Nd = sampled data values with noise
