As explained in Section 14.4.2,
data needs to of a size that is always representable by
a set of segments from the defined segment set.
Therefore, we need to truncate the data to a multiple
of max_segment_size samples.
We choose max_segment_size, so that all or most segment sizes
are factors. The ideal value is the least common multiple
% find least common multiple
% truncate the data to a multiple of max_segment_size
Note that we store the length of each data sample in variable ntot.