Skip to content

Commit

Permalink
inproved first/last calculation when splitting shaped gradients
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxim Zaitsev committed Mar 16, 2021
1 parent bc5ec84 commit 47d996a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions matlab/+mr/splitGradientAt.m
Expand Up @@ -84,8 +84,8 @@
else
grad1=grad;
grad2=grad;
grad1.last=grad.waveform(timeindex);
grad2.first=grad.waveform(timeindex);
grad1.last=0.5*(grad.waveform(timeindex-1)+grad.waveform(timeindex)); % todo: restore the waveforms on double raster as in plot()
grad2.first=grad1.last;
grad2.delay=grad.delay + grad.t(timeindex);
grad1.t=grad.t(1:(timeindex-1));
grad1.waveform=grad.waveform(1:(timeindex-1));
Expand Down

0 comments on commit 47d996a

Please sign in to comment.