added check for negative edge length, also minor documentation