Create a new segment on the same interval, with a new value derived from this segment.
In most cases using withNewValue will result in simpler-looking code.
a function that takes this as argument and produces a new value.
this