update SegmentTree