added local extremums