Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Solve the questions below related to this code: Introduction The base code for a pulse sequence program is given below clear % time (in seconds)

Solve the questions below related to this code: Introduction The base code for a pulse sequence program is given below clear % time (in seconds) TR=1; % TE=0.02; % use this line for echo PS dt=0.00001; % increment for plots t=0:dt:TR; % time variable for PS

% time window to plot for PS diagram show_time=[0 0.01];

% pre-allocate empty arrays for each line RF=zeros([1 length(t)]); Gslice=zeros([1 length(t)]); Gphase=zeros([1 length(t)]); Gread=zeros([1 length(t)]);

% base plot flatlines and set axis limits f1=tiledlayout(4,1); nexttile(1) plot(t,RF,'-k') xlim(show_time) axis manual ylabel('RF') nexttile(2) plot(t,Gslice,'-k') xlim(show_time) axis manual ylabel('Gslice') nexttile(3) plot(t,Gphase,'-k') xlim(show_time) axis manual ylabel('Gphase') nexttile(4) plot(t,Gread,'-k') xlim(show_time) axis manual ylabel('Gread')

%%%%%%%%%%%%%%%%%%% RF pulses %%%%%%%%%%%%%%%%%%%%%%%%%% %%% Example using rectangle pulse 1ms duration at t=0 % Create RF pulse 1 RF1_max=1; RF1duration1=0.001; RF1_start_idx=1; RF1_end_idx=round(RF1duration1/dt); RF1_times=t(RF1_start_idx:RF1_end_idx); RF1_amp(RF1_start_idx:RF1_end_idx)=RF1_max; RF1_amp(RF1_start_idx)=0; RF1_amp(RF1_end_idx)=0;

% Update PS plot with RF pulse 1 RFplot=nexttile(1); hold(RFplot,'on') plot(RF1_times,RF1_amp,"Color",'red','LineWidth',2) ylim([-.5*RF1_max 1.2*RF1_max])

%%%%%%%%%%%%%%% Slice Select Gradient %%%%%%%%%%%%%%%%%%%% %%% Example using slice select gradient same time as RF1 pulse % Create Gslice pulse with rewinder that is Gslice_max=30; % mT/m Gslice_start_idx=RF1_start_idx; Gslice_end_idx=round(3*RF1_end_idx/2); % 3/2 times longer to accomodate rewinder Gslice_times=t(Gslice_start_idx:Gslice_end_idx); Gslice_amp(RF1_start_idx:RF1_end_idx)=Gslice_max; % SSG Gslice_amp(RF1_end_idx:Gslice_end_idx)=-1*Gslice_max; % rewinder Gslice_amp(Gslice_start_idx)=0; Gslice_amp(Gslice_end_idx)=0;

% Update PS plot with Gslice pulse Gslice_plot=nexttile(2); hold(Gslice_plot,'on') plot(Gslice_times,Gslice_amp,"Color",'blue','LineWidth',2) ylim([-1.2*Gslice_max 1.2*Gslice_max])

%%%%%%%%%%%%%%% Phase Encode Gradient %%%%%%%%%%%%%%%%%%%% %%% Example of phase-encode gradient pulse with user controlled strength %%% and timings % User settings Gphase_max=50; % mT/m Gphase_start_time=0.0015; % User changes this time to control phase gradient pulse timing Gphase_duration=0.002; % calculate timings Gphase_end_time=Gphase_start_time+Gphase_duration; Gphase_start_idx=find(t==Gphase_start_time); Gphase_end_idx=find(t==Gphase_end_time); Gphase_times=t(Gphase_start_idx:Gphase_end_idx);

% We will use a loop to plot a range of phase gradient strengths Gphase_set=[-Gphase_max, 0, Gphase_max]; for phase_idx=1:length(Gphase_set) Gphase_amp(1:length(Gphase_times))=Gphase_set(phase_idx); % PEG Gphase_amp(1)=0; Gphase_amp(length(Gphase_times))=0; % Update PS plot with Gslice pulse Gphase_plot=nexttile(3); hold(Gphase_plot,'on') plot(Gphase_times,Gphase_amp,'LineWidth',1) end ylim([-1.2*Gphase_max 1.2*Gphase_max])

%%%%%%%%%%%%%%% Readout Gradient %%%%%%%%%%%%%%%%%%%% %%% Example of readout gradient pulse with user controlled strength %%% and timings % User settings Gread_max=20; % mT/m Gread_start_time=0.004; % User changes this time to control phase gradient pulse timing Gread_duration=0.0025; % calculate timings Gread_end_time=Gread_start_time+Gread_duration; Gread_start_idx=find(t==Gread_start_time); Gread_end_idx=find(t==Gread_end_time); Gread_times=t(Gread_start_idx:Gread_end_idx);

Gread_amp(1:length(Gread_times))=Gread_max; % PEG Gread_amp(1)=0; Gread_amp(length(Gread_times))=0; % Update PS plot with Gread pulse Gread_plot=nexttile(4); hold(Gread_plot,'on') plot(Gread_times,Gread_amp,'Color','green','LineWidth',2) ylim([-1.2*Gread_max 1.2*Gread_max])

Q1. RF pulse Copy the base pulse sequence from the introduction section into the code box below and modify it to generate a spin-echo pulse sequence diagram. You will need to generate a second RF pulse and place it at TE/2. You will also need to move the readout gradient to collect the signal during the echo (i.e. should be centered on TE). BONUS: modify the RF pulse shape from rect to sinc in order to equally excite spins in the slice. % Copy the base pulse sequence and modify for Q1

Q2. Fourier Trajectory Draw the Fourier trajectory for this new pulse sequence from Q1 and add a photo/illustration of your drawing (or similar) below.

Q3. Phase encoding Copy the base pulse sequence from the introduction section into the code box below and modify it to collect 64 steps in the phase direction using a maximum gradient of 32 mT/m and a gradient duration of 4 ms. % Copy the base pulse sequence and modify for Q2

Q4. Spatial resolution Assuming that the phase encode is entirely in the y-direction, what is the spatial resolution (i.e. voxel size in y) and field of view (FOV) in that direction. If you increase the number of ky steps from 64 to 256 but leave everything else the same, how will the y-direction spatial resolution and FOV change?

Q5. EPI readout Copy the base pulse sequence from the introduction section into the code box below and modify it to collect a 16x16 grid of k-space using the ecoplanar imaging method. BONUS: Try to modify the readout gradients for spiral acquisition % Copy the base pulse sequence and modify for Q5

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Learning Scientific Programming With Python

Authors: Christian Hill Page

1st Edition

110742822X, 9781107428225

More Books

Students also viewed these Physics questions