added "preceding"- and "succeeding"-function