def from_time(self, z, t): """ tv = from_time(zv, t) zv, tv are grid coordinates; t is an actual time value. """ return((t - self.start - slice_time(self.z_to_slice(z), self.tr_slices, self.slice_order))/self.tr)
def to_time(self, z, t): """ t = to_time(zv, tv) zv, tv are grid coordinates; t is an actual time value. """ return(self.start + self.tr*t + slice_time(self.z_to_slice(z), self.tr_slices, self.slice_order))