Lattice reduction
We can recognize certain lattice types and produce nice things like special k-points. Some easy lattices are CUB, FCC, BCC. Unfortunately others are quite difficult, and the framework is liable to 'recognize' things as having a lower symmetry than it really has, which is not really good enough for a programmatic framework. It would extremely nice to solve this, but I'm just not an expert in lattices.
I once thought that it was just a question of running Niggli-reduce, but this is not quite so: The lattices returned by Niggli reduction are not equal to those standard forms we know how to recognize.
So: Does anybody know how to properly recognize the bloody lattices?
Here's a plan for bruteforcing the problem:
Take a non-trivial lattice like BCT. It has two parameters (a, c). We generate a representative set of cells for some huge grid of values (a, c). The Niggli algorithm reduces each cell to a particular form, characterized by a linear operation which is a 3x3 integer matrix. Often this operation will be the same, but sometimes it will differ. These operations probably fall into a distinct few buckets, and if we know all those buckets, we can map any Niggli-reduced form back to see if it fits the standard form. So we tabulate each bucket.
In pseudocode:
reduced_cell = niggli(cell)
for lattice in known_lattices:
for inv_op in known_niggli_inv_ops[lattice]: # This is our tabulated set of inverted 3x3 Niggli operations
if (inv_op @ reduced_cell) resembles standard_form[lattice]:
return lattice
Not sure if it'll work well for monoclinic, as there could be an awful lot of those.