I am stuck on a problem that says given for the range [750,1800] (where each element has a spacing of 5 units: [750,755,760,...,1795,1800]), to select 4 elements from this range who are all at least 150 units apart from each other. I don’t need all possible solutions just a decent sample of possible solutions.
The only way I could think to do this was through some numerical/iterative approach in R or MATLAB, but I’m hoping that would be unnecessary and am looking for some suggestions.
Thank you.
Let one value be $750$, then select $750+150=900$, $900+150=1050$ and $1050+150=1200$. In fact we can pick any starting value up to $1350$ and perform the same procedure to get a valid sample. We can also pick elements spaced at different lengths away from each other such as $155,160,...$ to get even more valid samples.