//Callback function responsible for determining the value of the order //parameter D_{to,from}c_{to}c_{from} where to and from are indices of the form //(x, y, spin). complex<double> fD(Index to, Index from) { //Obtain indices int x = from.at(0); int y = from.at(1); int s = from.at(2); //Return appropriate amplitude switch(s) { case 0: return conj(D[dCounter][x][y]); case 1: return -conj(D[dCounter][x][y]); case 2: return -D[dCounter][x][y]; case 3: return D[dCounter][x][y]; default://Never happens return 0; } }
const T& at(const math::vec3& position) const { return _index.at(position); }