This is an interesting problem - I was wondering if anyone has a creative solution.
So I have a vector of vertices representing atoms in a protein, as well as 6 variables containing the absolute minimum/maximum bound of the set at each direction.
I need to build a grid that surrounds the protein/vertices in a homogeneous layer.
Right now I just loop through every square of the grid bound by the minimum-maximum values and then loop through every vertex to calculate the minimum distance between my point and every atom in the protein, and see if that point is at an acceptable distance. This process is quite expensive.
Do you guys have any creative answers as to how minimize the time?
P.S. the list of atoms in the protein are ordered more according the the amino acid sequence, which means it has almost no relation to the location of the atom in space