assignment 5 solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · ee225e/bioe265 spring 2013...

18
EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish reading Nishimura Ch. 5. 2. For the 16 turn spiral trajectory, plotted below, what is the a) Spatial resolution, and b) FOV given that k x,max = k y,max =2.5 cycles/cm. Assume that the sampling rate along the spiral trajectory is not limiting. k y k x 2k x,max 2k y,max Solution: The resolution and FOV are the same in each dimension, so let W k = W kx = W ky , and δ = δ x = δ y , etc. a) The k-space extent is W k 2k max = (2)(2.5 cycles/cm) = 5 cycles/cm This gives a spatial resolution of δ = 1 W k = 1 5 cycles/cm =0.2 cm = 2 mm. b) The FOV is determined by the sampling interval in the radial direction. This is Δk =2k max /(2 * 16) = (5 cycles/cm)/32 = 0.16 cycles/cm where we have used the fact that an N turn spiral crosses (samples) any diameter 2N times. The FOV is then FOV = 1 δ = 1 0.16 cycles/cm =6.4 cm. 1

Upload: others

Post on 20-Apr-2020

19 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

EE225E/BIOE265 Spring 2013 Miki LustigPrinciples of MRI

Assignment 5 Solutions

Due March 6th 2012

1. Finish reading Nishimura Ch. 5.

2. For the 16 turn spiral trajectory, plotted below, what is the

a) Spatial resolution, and

b) FOV

given that kx,max = ky,max = 2.5 cycles/cm. Assume that the sampling rate along the spiral trajectoryis not limiting.

ky

kx

2kx,max

2ky,max

Solution: The resolution and FOV are the same in each dimension, so let Wk = Wkx = Wky, andδ = δx = δy, etc. a) The k-space extent is

Wk2kmax = (2)(2.5 cycles/cm) = 5 cycles/cm

This gives a spatial resolution of

δ =1

Wk=

1

5 cycles/cm= 0.2 cm = 2 mm.

b) The FOV is determined by the sampling interval in the radial direction. This is

∆k = 2kmax/(2 ∗ 16) = (5 cycles/cm)/32 = 0.16 cycles/cm

where we have used the fact that an N turn spiral crosses (samples) any diameter 2N times. TheFOV is then

FOV =1

δ=

1

0.16 cycles/cm= 6.4 cm.

1

Page 2: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

3. Consider the 2DFT pulse sequence, shown below on the left, with the following timing

Gx

Gy

Gz

RF

A/D

2 ms

4 ms

FOV

FOV

The amplitude of the readout gradient is 0.94 G/cm, as is the maximum of the phase encode gradient.Also, 256 samples are acquired during the readout, and 256 phase encode steps are used. The initialmagnetization is fully relaxed for each acquisition. The RF pulse is a +90◦ rotation about +x.

The object being imaged is shown above on the right. It is a triangle that is larger than half theFOV in each dimension. The reconstructed image is the magnitude of the inverse FT of the sampleddata.

(a) What are the resolution and FOV of the pulse sequence? Solution:The k-space extent in thereadout direction is

Wkx =γ

2πGxτx = (4.257 kHz/G)(0.94 G/cm)(4 ms) = 16 cycles/cm

This corresponds to a resolution

δx =1

Wkx=

1

16 cycles cm= 0.0625 cm

The sampling in kx is

∆kx =Wkx

Nr=

16 cycles/cm

256= 0.0625 cycles/cm

and the FOV in x is then

FOVx =1

∆kx=

1

0.0625 cycles/cm= 16 cm.

Along the y axis, the k-space extent is

Wky = 2ky,max =γ

2πGyτy = 2(4.257 kHz/G)(0.94 G/cm)(2 ms) = 16 cycles/cm

which is the same as in the x dimension, so the resolution is again δy = 0.0625 cm Since thenumber of phase encodes is the same as the number of readout samples, the FOV is also thesame in x and y, so FOVy = 16 cm.

2

Page 3: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

(b) Sketch the image that would be produced if we just used the even numbered phase encodes.

Solution: This only effects the y dimension.

If we only use the even numbered phase encodes, the k-space extent remains the same, so theresolution δy stays the same. The spacing of the phase encodes is now twice as large

∆ky,n = 2∆ky

so that the new FOVy,n is half of what it was.

FOVy,n =1

∆ky,n=

1

2∆ky= FOVy/2

Since FOVy is now half as big, the image replicas are twice as close, and overlap the originalFOV. If we reconstruct using the acquired even phase encodes, and zero out the odd phaseencodes, we get the image of the left. If we reconstruct using Np/2 phase encodes, the result isthe image on the right.

FOV

FOV/2

FOV

FOV/2

(c) What does the image look like if we doubled the x gradient, and used the original phase encodegradient?

Solution: This only effects the x dimension.

If we double Gx, then

Wkx =γ

2πGxτx

is also doubled. This means that δx = 1Wkx

is halved. The pixels are twice as small in x. Sincewe’ve kept the same number of samples, the FOV in x has also been halved. Since the readoutdirection is the axis where we have the anti-aliasing filter, there is no aliasing.

If we reconstruct the image using a 256x256 2DFT the image looks like the one on the leftbelow. If we compensate for the pixel size, we get the image on the right.

FOV FOV

FOV/2 FOV/2

3

Page 4: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

(d) What does the image look like if we doubled the maximum y gradient, and used the originalreadout gradient?

Solution: This only effects the y dimension.

Doubling Gy doubles Wky, and halves δy. In addition the k-space sample spacing ∆ky,n isdoubled, so the FOVy is halved.

If we reconstruct by doing a 256x256 2DFT, and don’t compensate for pixel size, the result isthe image on the left. If we do compensated for the smaller pixel size in y, we get the image onthe right.

FOV

FOV/2

FOV

FOV/2

(e) Assume that the sign of the RF is alternated every other phase encode, so that it produces a+90◦ rotation about the +x axis on the even phase encodes, and a −90◦ rotation on the oddphase encodes. We reconstruct as usual with an inverse FT. What does the image look like?

Solution: There are many ways to look at this. The alternating RF pulse results in the signalfor every other phase encode being multiplied byt ±1, so that the new acquired data is

Mxy,n(u∆kx, v∆ky) =Mxy(u∆kx, v∆ky)(−1)v

where Mxy(u, v) is the original sampled data, and Mxy,n(u, v) is the new data. The new datais the original data multiplied by (−1)v, where v is the integer index of the phase encode.

One approach is to use the modulation theorem. Multiplication in the spatial frequency domaingoes to convolution in the image domain, so the result will be the original image convolved withthe 2D inverse Fourier transform of (−1)v.

We can also just work through the problem directly, which is what we will do here. As weshowed in class,

Mxy,n(aδx, bδy) =∑u

∑v

Mxy(u∆kx, v∆ky)(−1)vej2π(au/Nr+bv/Np)

where u is summed from −Nr/2 + 1 to Nr/2, and v is summed from −Np/2 + 1 to Np/2. If wewrite (−1)v as eivπ, and collect terms,

Mxy,n(aδx, bδy) =∑u

∑v

Mxy(u∆kx, v∆ky)ejvπe

j2π

(auNr

+ bvNp

)

=∑u

∑v

Mxy(u∆kx, v∆ky)ej2π( v

2)ej2π

(auNr

+ bvNp

)

=∑u

∑v

Mxy(u∆kx, v∆ky)ej2π

(auNr

+

(b

Np+ 1

2

)v

)

4

Page 5: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

=∑u

∑v

Mxy(u∆kx, v∆ky)ej2π

(auNr

+(b+Np/2)v

Np

)= Mxy,n(aδx, (b+Np/2)δy)

The new reconstructed image is the original image shifted by Np/2 pixels in y, or one-half ofthe FOV. Note that since we are sampled in spatial frequency, the image domain is perioidic.As we shift the object out of the FOV in one dimension, the next replicated image comes infrom the opposite direction.

The image that results is shown below:

FOV

FOV

(f) Now consider the case where we are using the original acquisition gradients, but are imagingsodium, which has a γ/2π of 1.126 kHz/G. What is the resolution and FOV? What does theimage now look like?

Solution: Since γ is now small by a factor of 4.257/1.126 = 3.78, almost 4, the same gradientwaveform produces one quarter the spatial frequency encoding. This means that Wkx and Wky

are both reduced to one quarter of the original, and that the resolution element δx and δy arenow both four times as large. The k-space sampling is also reduce to one quarter the original,so the FOV is now four times as large. The result is an image that looks like this:

3.78×FOV

3.78×FOV

5

Page 6: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

4. Artifacts in 2DFT (From Midterm I 2012)

Consider a conventional 2DFT sequence that produces the image shown below (within the square).

(22%) 1. (a) An ultrasonic system operating at 3 MHz using a single circular transducer is

used to image a leg of thickness 150 mm. What is the minimum time interval

between successive ultrasonic pulses that avoids possible overlap (ambiguities)

of the received echoes?

(b) Consider an ultrasonic system operating at 6 MHz (� = 0.25 mm), and two point

scatterers, one located at (x = 3 mm, y = 0 mm, z = 50 mm) and the other

at (x = 3 mm, y = 0 mm, z = 25 mm). For each of the following transducers

centered at (0, 0, 0), determine if these scatterers will be outside the main lobe

of the beam pattern (i.e., the main lobe is based on the first zero crossings of

the beam pattern). Explain.

- Square D by D transducer with D = 8 mm.

- Square D by D transducer with D = 3 mm.

(16%) 2. Consider a conventional 2DFT sequence that produces the image shown below on the

left (within the square).

x

y

displayed!image!matrix

conventional

x

y

part b)

(a) If the scan is repeated but with all gradient amplitudes scaled by a factor of

1.25 (this is the only change), sketch the resultant image. Note that the dumb

(inflexible) reconstruction computer blindly takes the inverse FFT of the raw

data and displays the image matrix.

(b) Another 2DFT sequence is applied and the image shown above on the right gets

displayed. Explain what might have changed in the pulse sequence as compared

to the conventional sequence.

a) If the scan is repeated but with all gradient amplitudes scaled by a factor of 1.25 (this is the onlychange), sketch the resultant image. Note that the dumb (inflexible) reconstruction computerblindly takes the inverse FFT of the raw data and displays the image matrix.

Solutions:

Since the gradients are scaled by 1.25, the effective FOV is scaled down by 1.25 and the resolutionis increased by 1.25.

The object lies at the edge of the FOV, so aliasing will occur in the phase encode direction. Inthe readout direction, the anti-aliasing filter will crop the image. The result is displayed below:

Draw the resulting image here:

x

y

displayedimagematrix

6

Page 7: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

b) Now, the scan is repeated with the phase encode gradients turned off (this is the only change),sketch the resultant image. Again assume a dumb reconstruction computer.

Solutions:Since the phase encodes are off, all of the readouts will be the same. This means that there isno variation in the y direction and so the reconstruction is going to show signal only on the xaxis. The intensity of the signal on the x axis is going to be the Fourier transform of a singlereadout through the center of k-space. This turns out of course to be a projection through theobject (integrating across y).

The result is shown below:

Draw the resulting image here:

x

y

displayedimagematrix

c) Now, the scan is repeated, but the imaging plane is rotated counterclockwise by 45◦, sketch theresultant image. Again assume a dumb reconstruction computer. Note, that only the imagingplane is rotated, not the sample!.

Solutions:When the imaging plane is rotated, it is like rotating the square box 45 degrees counterclockwise,while keeping the image the same. In that case, part of the object will be outside of the FOVin the readout direction, and will be cropped. The result is below:

Draw the resulting image here:

x

y

x

y

read

out

The imaging plane The displayed reconstructed image

readout

7

Page 8: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

d) Another 2DFT sequence is applied and the image shown below gets displayed. Explain whatmight have changed in the pulse sequence as compared to the conventional sequence.

x

y

displayedimagematrix

Solutions:The image seems to be squeezed in the phase encode direction, or in fact there’s more FOV iny. The image is also squares, so the amount of phase encodes and feequency encodes has notchanged. This means that the gradients in y were scaled by a factor of 1/2. This will result indouble the FOV in y, and half the resolution which will result in the figure above.

Phase encode gradients are scaled by 1/2.

8

Page 9: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

5. The Rings Trajectory (from midterm I 2012) 1

Consider the following pulse sequence :

Each repetition is supposed to trace a single angular ring trajectory in k-space. The trajectory isdesigned by determining the parameters for the outmost ring and then scaling the gradients to tracethe inter rings.

We would like to use it to scan a circular object with a FOV of 25.6cm at a spatial resolution of1mm. For this question assume that the sampling interval is ∆T = 4µs and the maximum gradientamplitude is limited to |Gx|, |Gy| < 4 G/cm.

Recall∫

sin(at)dt = −1a cos(at), and

∫cos(at)dt = 1

asin(at).

a) What are Wk, the extent of the trajectory in k-space, and ∆k, the minimum required spacingbetween samples in k-space?

Solutions:The extent of k-space is determined by the resolution, which is Wk = 1/δ = 1/0.1 = 10 cm−1.the sampling spacing is determined by the FOV and is ∆k = 1/FOV = 10/256 cm−1.

Wk = 10cm−1 ∆k = 10/256 cm−1

1This is a tribute to Holden Wu, who’s PhD thesis was on the ring trajectory

9

Page 10: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

b) For the outmost ring, what are TPE , GPE , GRO, and TRO that result in the fastest scan thatdoes not violate the FOV and gradient amplitude constraints?

Solutions:The outmost ring has a diameter of 10cm−1, therefore its radius is 5cm−1. This is also the areaof the prewinder. Since we do not collect data in the pre winder we can go as fast as possible, sowe can set GPE = 4G/cm. From the area requirement γ

2πGPETPE = 5 we get, TPE = 0.294ms.

From part (a), the maximum sampling distance is ∆k = 10/256cm−1. This puts a restrictionon GRO such that γ

2πGRO∆T < ∆k, which results in GRO = 2.294G/cm.

Recall that the k-space radius of the outmost ring is 5cm−1, and that Gx(t) = −GRO sin( 2πTRO

t′).

Therefore, kx(t′) =∫ t′0 −

γ2πGRO sin( 2π

TROτ)dτ = γ

2πTRO2π GRO cos( 2π

TROt′). From this, we get that

γ2π

TRO2π GRO = 5cm−1 and TRO = 3.217ms

TPE = 0.294ms GPE = 4G/cm GRO = 2.294G/cm TRO = 3.217ms

c) How many rings, N , are required to cover k-space?

Solutions:Short answer: The outermost ring radius is 5cm−1 and the distance between rings should beless than ∆k = 10

256 . This results in N = 5/ 10256 = 128.

Long answer: One problem with this is that the inner most ring will have radius of ∆k andtherefore the inter ring would violate Nyquist. In that case we need to add 1 more sample atDC. This is however quite wasteful, so instead the inter most ring diameter can be set to ∆k.N = 128 would result in the our most ring being 5 −∆k/2. Both N = 128 and N = 129 aregood answers.

N = 128 or, N = 129

10

Page 11: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

d) You scan a point object located at x = 10cm. Unfortunately, due to systematic errors, the startand end of the A/D window is delayed by 10 samples with respect to the gradient waveforms.Assuming a “dumb” reconstruction computer that is not aware of the delay, draw is the imagethat is going to be reconstructed? Comment on the sensitivity of rings to delays.

Solutions:The important thing to notice is that a delay between the A/D window and the gradientwould result in a pure rotation in k-space. Since the A/D window is delayed, the result isa counterclockwise rotation. The angle of rotation is

θ =2π

TRO10∆T

This results in θ = 4.476◦ rotation and the object being displaced to x = 10 cos(θ) = 9.97cmand y = 10 sin(θ) = 0.78cm.

4.476o[9.97,0.78]

Actualreconstructed

11

Page 12: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

6. Matlab Exercise: 2DFT Pulse sequence design.In this assignment we will write functions to design a 2DFT pulse sequence, and then simulate thedesign on a Bloch simulator.

The first step is to design a readout gradient. The readout gradient is composed of a prewinder, anda readout part. In the readout, we are interested in having a portion of the gradient that will scanthe desired k-space length (gradient area) in which the gradient waveform is constant. This will giveus a steady linear scan in k-space. For the prewinder, we are only interested in generating a gradientarea that is half the area of the readout part. This should be as fast as possible to minimize the scantime. In addition, the ramps for the readout part should also be as fast as possible.

a. Write a function genReadoutGradient.m that designs a readout gradient given the sequenceparameters and the system constraints.

>> [gro,rowin] = genReadoutGradient(Nf, FOVr, bwpp, Gmax, Smax, dt);

The inputs to the function are :Nf is the number of frequency encodes.FOVr (in cm) is the desired field-of-view.bwpp (in Hz/pixel) is the desired bandwidth per pixelGmax (in Gauss/cm) is the maximum gradient.Smax (in Gauss/cm/s) is the maximum slew-rate.dt (in s) is the duration for each sample.

The outputs of the function are:gro - an array containing the gradient waveform.rowin - an array containing the indexes in gro that correspond to the readout portion of thegradient. This will be used to crop the interesting part of k-space for reconstruction.

bwpp is something we have not discussed before. It basically defines the gradient amplitude weare going to use during the flat portion of the readout gradient. In essence, bwpp = γ

2πGFOVNf .

Now, the A/D has a sampling bandwidth of 1/dt. So, the effective number of digital readoutsamples may be higher than our desired Nf frequency encodes. This is OK, since after we get allthe samples, we will filter them to a bandwidth of Nf*bwpp and subsample to get Nf samples.

(Hint: You should first design a trapezoid that meets the criteria and then use the minimum-time-gradient function you wrote in previous homework to deign the prewinder. Remember tocompensate for the ramp of the readout in the prewinder!!!!)

12

Page 13: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

Solutions:

There are many ways of implementing this. Here’s one:

function [gro,rowin] = genReadoutGradient(Nf, FOVr, bwpp, Gmax, Smax, dt);

%[gro,rowin] = genReadoutGradient(Nf, FOVr, bwpp, Gmax, Smax, dt);

gamma = 4257;

res = FOVr/Nf;

Wkx = 1/res;

area = Wkx/gamma;

G = bwpp/res/gamma;

Tro = Wkx/gamma/G;

Tramp = G/Smax;

t1 = Tramp;

t2 = t1+Tro;

T = Tramp*2+Tro;

N = floor(T/dt);

t = [1:N]’*dt;

idx1 = find(t < t1);

idx2 = find((t>=t1) & (t < t2));

idx3 = find(t>=t2);

gro = zeros(N,1);

gro(idx1) = Smax*t(idx1);

gro(idx2) = G;

gro(idx3) = T*Smax - Smax*t(idx3);

areaTrapz = (T+Tro)*G/2; % area of readout trapezoid

gpre = minTimeGradientArea(areaTrapz/2, Gmax, Smax, dt);

rowin = length(gpre) + 1 + idx2;

gro = [-gpre(:);0;gro(:)];

13

Page 14: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

b. To design a phase encode gradient, we only need to design the gradient for the largest phase-encode and then scale it accordingly for the others.Write a function genPEGradient.m that designs the gradient phase encode gradient for thelargest phase encode and a phase encode table to scale it.

>> [grpe, petable] = genPEGradient(Np, FOVp, Gmax, Smax, dt);

The inputs to the function are :Np is the number of phase encodes.FOVp (in cm) is the desired phase-encode field-of-view.Gmax (in Gauss/cm) is the maximum gradient.Smax (in Gauss/cm/s) is the maximum slew-rate.dt (in s) is the duration for each sample.

The outputs of the function are:grpe - an array containing the gradient waveform.petable - Npe x 1 array containing the phase encode table to scale the phase-encode gradientfor each phase-encode. The array entries should be bounded between [-1 : 1]

Solutions:

There are several choices how to distribute the phase encodes. In this case, I chose to distributethem such that there isn’t a phase encode with amplitude zero. This way, k-space is sampledaround the DC line and kx=ky=0 is not sampled. This is often done in practice to improve thedynamic range, since the DC point has a very high amplitude.

The code uses the minTimeGradientArea function from previous homework. Here’s the code:

function [grpe, petable] = genPEGradient(Np, FOVp, Gmax, Smax, dt)

gamma=4257;

kmax = 1/(FOVp/Np)/2;

area = kmax/gamma;

grpe = minTimeGradientArea(area, Gmax, Smax, dt);

petable = [Np/2-0.5:-1:-Np/2+0.5].’/(Np/2);

14

Page 15: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

Now that we have a way to generate the waveforms of a 2DFT sequence, we will simulate such asequence for a distribution of spins. Download the file hw5 img.mat from the class website. Thisfile contains the arrays dp [7715x2], mx [7715x1], my[7715x1], and mz[7715x1],. These arrayrepresents the positions of 7715 spins in space and their magnetization. We will now imagethem!

c. Design a 2DFT sequence with readout/phase-encode FOV of 14/7 cm, Nf/Np of 64/32 (givinga resolution of ≈ 2.2mm. Use a bandwidth per pixel of about 1.8624 Khz/cm. Use dt = 4µs,Gmax=4G/cm and Smax=15000G/cm/s. Design a hard-pulse RF with 90 degree excitation touse with the gradient sequence. Plot k-space by integrating the gradient waveforms. Make sureit makes sense!

Solutions:

Here’s the code:

Nf = 64;

Np = 32;

Nrf = 92;

FOVr = 14;

FOVp = 7;

Gmax = 4;

Smax = 15000;

dt = 4e-6;

bwpp = 1862.4;

gamma = 4257;

flip = 90;

[gx,rowin] = genReadoutGradient(Nf, FOVr, bwpp, Gmax, Smax, dt);

[gpe,petable] = genPEGradient(Np, FOVp, Gmax, Smax, dt);

RF90 = ones(Nrf,1)*(flip/360)/(Nrf*dt*gamma);

gy = zeros(length(gx),1);

gy(1:length(gpe)) = gpe;

load hw5_img.mat

G = [];

res = zeros(Np,length(rowin));

for n=1:Np

g = [gx(:),gy(:)*(-petable(n))];

G(:,n) = g*[1;i];

% simulate Excitation first

[mx1,my1,mz1] = bloch(RF90,RF90*0,dt,100,100,0,dp,0,mx,my,mz);

% simulate Readout

[mx1,my1,mz1] = bloch(gx*0,g,dt,100,100,0,dp,2,mx1,my1,mz1);

mxy = sum(mx1,2) + i*sum(my1,2);

res(n,:) = mxy(rowin);

end

figure, plot(cumsum(G*dt*gamma));

15

Page 16: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

figure, plot(real(G),’b’); hold on, plot(imag(G),’r’);

im = crop(ifft2c(res),[Np,Nf]);

figure, imshow(abs(im),[]);

Here’s the resulting gradient waveform:

And the k-space trajectory:

DC line is not sampled

Samling the DC line is also fine.

16

Page 17: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

d. Simulation: Simulate the sequence acquisition using the Bloch simulator one phase encode ata time (The simulation takes about 1-2sec per phase encode). Use T1=T2=100. The outputof the simulator needs to be integrated across all the spins to get the signal. The code for thesimulation part should look like:

>> ....

>> g = [gro, gpe*phtable(n)];

>> [mx,my,mz] = bloch(rf,g,4e-6,100,100,0,dp,2,mx,my,mz);

>> mxy = sum(mx,2) + sqrt(-1)*sum(my,2);

>> ...

You will find that the number of readout samples is bigger than Nr because we sampled at250Khz (dt = 4µs). Scanners also sample at that rate and then apply a digital filter to get thedesired number of readout points. There are two options, to do the filtering and subsamplingof k-space or cropping the image. For simplicity, we will take the 2nd approach.

take a 2D centered IFFT of the resulting k-space data. Crop the image to the desired FOV.You should be able to read something. If you can’t, .... then something is wrong. Submit a plotof the gradient waveforms and the image.

Enjoy!

Solutions:

The resulting image is:

17

Page 18: Assignment 5 Solutions kee225e/sp13/hw/hw5_soln.pdf · 2013-03-09 · EE225E/BIOE265 Spring 2013 Miki Lustig Principles of MRI Assignment 5 Solutions Due March 6th 2012 1. Finish

e. Reduce the FOV by a factor of 1.5 in the phase encode and repeat the scan. What do you get?submit the image.

Solutions:

In this case, the gradient area for the phase encode is twice as big. We need to make sure thatthe it does not overlap with the readout portion. Fortunately it doesn’t.

The resulting image is aliased. The polarity or the phase of the alias depends on the exactphase encode scheme ( if the DC line is sampled or not). If the DC line is sampled, the alias ispositive. If it is not, then it is negative. Here it is negative, so some of the signal cancels.

And here’s when DC line is sampled:

18