distance framework