Vector

50 views
Skip to first unread message

Xin Chen

unread,
Sep 7, 2021, 9:58:32 AM9/7/21
to JEMRIS
Dear JEMRIS developers,

When using vector in sequence is there a way for JEMRIS to call a MATLAB variable? For example, the following TSE sequence's PE gradient is described by a 32 element vector. My actual sequence has 320 PE lines, and I would like to simulate a pre-defined table of PE gradients. Do I have to insert a 320-element vector in the xml file, or is there a way to call an external MATLAB variable?

Thanks much!
Xin

<?xml version="1.0" encoding="utf-8"?>
<Parameters FOVx="256" FOVy="256" FOVz="3" Name="P" Nx="32" Ny="32" Nz="1" TE="30" TR="500">
   <ConcatSequence Name="TSE">
      <ConcatSequence Name="O" Observe="NY=P.Ny, R=I.Repetitions" Repetitions="NY/R">
         <ATOMICSEQUENCE Name="A1">
            <HARDRFPULSE Duration="0.1" FlipAngle="90" Name="P1" Symmetry="0.5"/>
         </ATOMICSEQUENCE>
         <ATOMICSEQUENCE Name="A2">
            <TRAPGRADPULSE Area="0.5*A" Axis="GX" MaxAmpl="5" Name="P2" Observe="A=P5.Area"/>
         </ATOMICSEQUENCE>
         <DELAYATOMICSEQUENCE Delay="TE/2" DelayType="C2C" Name="D3" Observe="TE=P.TE" StartSeq="A1"
                              StopSeq="A3"/>
         <CONCATSEQUENCE Name="I" Repetitions="8">
            <ATOMICSEQUENCE Name="A3">
               <HARDRFPULSE Duration="0.1" FlipAngle="180" Name="P3" Symmetry="0.5"/>
            </ATOMICSEQUENCE>
            <ATOMICSEQUENCE Name="A4">
               <TRAPGRADPULSE Area="Vector(IC+OC*IR)*DKY" Axis="GY" Name="P4"
                              Observe="KMY=P.KMAXy, DKY=P.DKy, IC=I.Counter, IR=I.Repetitions, OC=O.Counter"
                              Vector="1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32"/>
            </ATOMICSEQUENCE>
            <DELAYATOMICSEQUENCE Delay="TE/2" DelayType="C2C" Name="D2" Observe="TE=P.TE" StartSeq="A3"
                                 StopSeq="A5"/>
            <ATOMICSEQUENCE Name="A5">
               <TRAPGRADPULSE ADCs="NX" Axis="GX" FlatTopArea="-2*KMX" FlatTopTime="3.6" MaxAmpl="2.41"
                              Name="P5"
                              Observe="KMX=P.KMAXx, NX=P.Nx"/>
            </ATOMICSEQUENCE>
            <ATOMICSEQUENCE Name="A6">
               <TRAPGRADPULSE Area="-A" Axis="GY" Name="P6" Observe="A=P4.Area"/>
            </ATOMICSEQUENCE>
            <DELAYATOMICSEQUENCE Delay="TE" DelayType="B2E" Name="D5" Observe="TE=P.TE" StartSeq="A3"/>
         </CONCATSEQUENCE>
         <DELAYATOMICSEQUENCE Delay="TR" DelayType="B2E" Name="D4" Observe="TR=P.TR" StartSeq="A1"/>
      </ConcatSequence>
   </ConcatSequence>
</Parameters>

tony.s...@gmail.com

unread,
Sep 28, 2021, 9:47:29 AM9/28/21
to JEMRIS
Dear Xin,
The functionality you are seeking exists in the Matlab GUI. Here you can input any Matlab expression which evaluates to a vector, e.g. a function call. The result is shown in the GUI and stored to the xml file once you press "write xml".  (Matlab variables are currently not supported but could be easily added.)
Hope this helps,
Tony
Reply all
Reply to author
Forward
0 new messages