Ultrasound Project Report

Embed Size (px)

DESCRIPTION

Ultrasound Project

Citation preview

  • 7/18/2019 Ultrasound Project Report

    1/24

    Ultrasound Project Report

    Langechuan Liu

    October 2009

    This report has two parts.

    In Part I, the answers to the questions asked in the project will be an-swered. For most of the questions, please refer to the commented Matlabcode attached to this report. In this report I will provide supplementaryexplanations and discussions to the questions.

    In part II, as a sanity check, ultrasound raw data are generated usinga new object comprising of a collection of reflectors located at known posi-tions. (Matlab code for doing so is also provided with comments.) Using thebeam-forming and scan-conversion routine developed in part I, reconstructed

    ultrasound image is obtained, in comparison with the original object.

    The attachment list,

    subroutine discriptionbeamform v1.m beam-forming subroutine

    scancon v1.m scan-conversion subroutinebeamform v2.m alternative way of phase correction

    SM gen.m subroutine for setting up new reflector positionsdata gen.m subroutine for generating ultrasound raw data

    Timeline:October 12, 2009 image reconstruction code finishedOctober 14, 2009 raw data generation code finishedOctober 18-22, 2009 answers sorted and LATEXed

    1

  • 7/18/2019 Ultrasound Project Report

    2/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    1 Part I Answers, explanations & discussions

    Question A The showimage subroutine can be seen as a more powerfulimagesc.

    rawdata wavefield plot

    50 100 150 200 250

    50

    100

    150

    200

    250

    300

    350 0

    0.5

    1

    1.5

    2

    2.5

    3x 10

    3

    Figure 1: Problem A

    Question B Suppose the width of the element is the same as the center-to-center spacing, then citing the equation from lecture notes (A.23), wehave

    2

  • 7/18/2019 Ultrasound Project Report

    3/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    sin = /2D = 2Nd = 2d2Nd = 1N = 165 (1)

    For sector angle 90, [45, 45], thereforesin [2/2,2/2]

    Number of beams=

    2/2 (

    2/2)

    sin = 65

    2 91.9 (2)

    In order to adequately sample angularly and make number of beams anodd number for =0 A-mode scan later, number of beams is chosen to benbeam=93.

    Question C After usingbasebandsubroutine, the real part and imaginarypart of baseband data is shown in Figure 2 using showimagesubroutine.

    baseband Real part wavefield plot

    50 100 150 200 250

    50

    100

    150

    200

    250

    300

    350

    2.5

    2

    1.5

    1

    0.5

    0

    0.5

    1

    1.5

    2

    2.5

    x 103

    (a) Real Part

    baseband Imaginary part wavefield plot

    50 100 150 200 250

    50

    100

    150

    200

    250

    300

    350 3

    2

    1

    0

    1

    2

    x 103

    (b) Imaginary Part

    Figure 2: wavefield plot of baseband dataStrictly speaking, this is not needed since finally interpolations will be perfomed. If

    beam number is odd, the =0 A-mode scan can be obtained directly even before interpo-lation. Refer to Question I for detailed discussion.

    3

  • 7/18/2019 Ultrasound Project Report

    4/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    Then raw data and the absolute value of baseband data are plotted in

    comparison in Figure 3:

    rawdata wavefield plot

    50 100 150 200 250

    50

    100

    150

    200

    250

    300

    350 0

    0.5

    1

    1.5

    2

    2.5

    3x 10

    3

    (a) raw data(real)

    baseband abosolute value wavefield plot

    50 100 150 200 250

    50

    100

    150

    200

    250

    300

    350

    0.5

    1

    1.5

    2

    2.5

    3

    x 103

    (b) baseband data (absolute value)

    Figure 3: raw data and baseband data

    This is in accordance with the theoretical analysis in the lecture noteson Page A10 and A13 baseband data is taking the envelope of the abso-lute values of the original data, turning a fast-varying high frequency sig-nal to a slow-varying low frequency signal. Therefore, when sampling atfs = 16Mhz= 4f0(carrier frequency), i.e. 4 points per period, neighboringpoints in original data can be as different as the local amplitude, leadingto the irregular white spot in gray area. Meanwhile for baseband data,sampling ratefsis adequate for depicting the envelope, therefore it has morerecognizable pattern than the raw data with no white spots, as displayed inFigure 3.

    Question D & E The main equation used for

    R(r, ) =d0dn

    N

    Nn=1

    bn

    d0+dn

    c

    ei2f

    0(d0+dn)/c

    (3)

    4

  • 7/18/2019 Ultrasound Project Report

    5/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    where demodulation frequencyf0 carrier frequencyf0,Nis the total num-ber of elements in the array noted as nelem in Matlab code. The totaldistance the signal traveled is

    dtotn (r, ) d0+dn (4)

    (rsin x0)2 + (rcos)2 +

    (rsin xn)2 + (rcos)2 (5)=

    r2 +x20 2rx0sin+

    r2 +x2n 2rxnsin (6)

    whered0is thetransmit distancefrom transmitter (x0, 0) to reflector (r, ),and dn is the receive distance from reflector back to different elements ofthe transducer array (xn, 0). Thus the total time consumed is

    tn(r, ) =d0+dn

    c (7)

    where c is the sound of ultrasound, vsound in Matlab code.Phase rotation is n(r, ) = 2f0tn(r, ), thus the correction term is

    n(r, ) =ein =ei2f0tn (8)

    Since we have only discrete samples, we need to find the correct timedelay(table lookup) and interpolate,. The time interval between two con-secutive sample points is t = 1/fs, thus ideally number of time clicks

    corresponding to tn is tickn = tn/t = tnfs, which is usually not an inte-ger. Linear interpolation using the weighted sum of two nearest neighborsfloor(tickn) and ceil(tickn) is used in beamform.m (equivalent to inter-polate with a triangular function). Single point interpolation with only thenearest neighbor round(tickn)is also explored, with results of no much dif-ference.

    Another Perspective Interestingly, there is another way to interpret andimplement phase rotation correction term n(r, ). Every row in thematrix of databb(140065 here) is collected at the same time point,e.g. the mth row is collected at the mth tick, i.e. the time point

    mt. This is the time between the sending and receiving of the signalsfor all channels. Note that for different channels, the information col-lected at the same time does not come from the same reflecting point.

    the only slightly observable difference is the trail artifacts discussed later, so picturesare not shown here.

    5

  • 7/18/2019 Ultrasound Project Report

    6/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    More specifically, for a single channel,e.g. the nth channel, the data

    collected at time t are the superposed wavefronts reflected back froma certain collection of points. Thus the distance these signals havetravelled before being collected is mct, the phase rotation at thenthchannel is

    n(r, ) = 2f0tm = 2f0mt (9)

    which is used in the phase correction term of databb(m,n).

    There are two things worth pointing out. First, although one singledata pointdatabb(m,n)has information from a collection of reflectingpoints, they share the same phase rotation because they share the samepropagation time. Second, this phase rotation depends only on time,

    i.e.on which row the data point is it does not depend on the channelnnor the reflecting points (r, ).

    x[mm]

    z[mm]

    scan level 20 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    20

    18

    16

    14

    12

    10

    8

    6

    4

    2

    0

    (a) exact phase correction 20dB

    x[mm]

    z[mm]

    scan level 50 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    50

    45

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (b) alternative phase correction 50dB

    Figure 4: Sector scan images using two ways of phase correction

    These two facts make it possible to make a more sorted phase correc-

    the points on the trajectory of an ellipse with major axisctnand foci located at (x0, 0)and (xn, 0). Discussed in greater detail in Question H

    6

  • 7/18/2019 Ultrasound Project Report

    7/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    tion to the baseband databb(,) before interpolation. The drawbackof this method is that we are not sampling fine enough because thephase factor is changing rapidly. It can be estimated that the largestpossible phase error is 2f0(t/2) = f0/fs = /4. Theoretically, ifthe signal can sampled quasi-continuously in time domain, fs ,this method will produce the same result as the original method em-ployed above.

    Beamforming using this method works, although not good, as shownin Figure 4. Reflectivity values become very small due to unsatisfyingconstructive interference because of phase error. Not until 50 dB doesthe shape of the mystery object become recognizable. Once going over

    80 dB, it is hard to tell the shape any more, thus the observationdB window is narrower than using the method with exact phasecorrection.

    x[mm]

    z[mm]

    scan level 40 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (a) r=0.05mm 40dB

    x[mm]

    z[mm]

    scan level 40 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (b) r=0.5mm 40dB

    Figure 5: Sector scan images using different radial sampling intervals

    Radial sampling Besides a careful choice of angular interval to sample ad-equately, radial interval also need to be determined. Supposedly there

    7

  • 7/18/2019 Ultrasound Project Report

    8/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    are two reflectors very close to each other, (r, ) and (r + r, ). If sig-

    nals reflected by these two reflectors can be distinguished by detectors,2r/c >t, so sampling interval should be

    r ct/2 =c/(2fs) 0.05mm (10)This is the sampling criterion for a single-element A-mode scanner.Two points with a distance apart smaller than r would not be dis-tinguished, limited by finite fs. For B-mode scan, rmight be smallerusing multi-channel data, but it will not make much more significantimprovement of image quality. Larger Sampling using r = 10r0.5mmmakes observable but not severe deterioration of image quality,

    as shown in Figure 5.

    sin(theta)

    r

    [mm]

    scan level 40dB

    0.6 0.4 0.2 0 0.2 0.4 0.6

    10

    20

    30

    40

    50

    6040

    35

    30

    25

    20

    15

    10

    5

    0

    Figure 6: r

    sin buffer

    Question F r sin buffer is plotted in Figure 6. Images usingshowimage(sin theta, r, abs(rsdata), 0, dbscale), axis normal

    can be equally achieved by

    8

  • 7/18/2019 Ultrasound Project Report

    9/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    rsdata = rsdata / max(max(rsdata));

    logrsdata = 20 * log(rsdata) / log(10);logrsdata( find(logrsdata < -dbscale) ) = -dbscale;

    imagesc(sin_theta, r, logrsdata);

    colormap(1-gray(256)); colorbar; axis normal;

    Question G To convert data from one coordinate systems to another,

    1. establish the grid(matrix of spatial position) in the target coordinatesystem(most favorably evenly spaced);

    2. then convert the coordinates in this grid to the original coordinate

    system(where the information of data points are known)

    3. interpolate using Matlab subroutines,e.g. interp, interp2

    In order to display the area out of FOV wedge in the same color as thereflector, then it should be padded with 1, which will turn into 0dB afterbeing mapped into logarithm scale.

    Question H Comparison of 20dB and 40dB level scans are compared sideby side below. In the 20dB image, it is more neat and easy to observe thewhole shape, although some details might be missing.

    Description There are five discrete reflectors altogether, three on/near thez-axis with two of them pretty close to each other, and two othersnear [20, 25] mm. There are also two quasi-continuous groups ofreflectors, forming a square altogether. One group is of a trapezoidshape with a square hole inside, and has higher reflectivities. Theother group is of an isosceles right triangle with lower reflectivities.

    Pixel and real spatial distance should be distinguished. Every data point in a matrixis only one pixel(although can be displayed in a larger single-valued area), or the value ofone point. It does not have information about real spatial positions itself. In order to knowthe coordinates of the pixel, other matrices are needed, as are generated by meshgridor

    ndgrid.First two parameters of subroutine interp2 cannot be changed in order. Both are

    matrices of the same size generated by duplicating particular vector respectively(1-dimmatrices) a row vector in the case of the first matrix parameter and a column vector forthe second.

    9

  • 7/18/2019 Ultrasound Project Report

    10/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    x[mm]

    z[mm]

    scan level 20 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    20

    18

    16

    14

    12

    10

    8

    6

    4

    2

    0

    (a) 20 dB

    x[mm]

    z[mm]

    scan level 40 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (b) 40 dB

    Figure 7: mystery object under different scan levels

    Artifacts In the section scan, the most striking artifacts is the smearing

    in the angular direction with lots of arch trails, like a car rain-wiperwiping through the reflecting body. A closer observation of the discretereflectors nearer to the origin would reveal that there are two arch trailsper reflector.

    A minor feature is that the arch trails are not continuously diminishing;rather they become more like dotted lines after some distance away fromthe reflector points. This is very obvious on both sides of the reflectorblocks in the lower part of the image.

    Initial Explanation, Guesses & TrialsMy initial guess was

    This is not exactly caused by the same mechanism of either sidelobes or grating lobes.Discussed later in Question H.I wrote this part down just for the record of my thinking process. For logical continuity,

    please skip to the next part, Final Explanation. Unless specified, all the numerical valuesof length in this part is in mm

    10

  • 7/18/2019 Ultrasound Project Report

    11/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    Radially, the envelope of the signal determines the radial

    spatial resolution. If the envelope is a Gaussian shaped pulsecontaining 2 or 3 periods, then radial PSF is a shifted Gaus-sian function, rapidly from the location of the reflector withincreasing or decreasing radius. Angularly, it is a slowlymodulated sinc function, with sidelobes and grating lobesstretching very far away compared with radial PSF. Thatcan explain why the trail become dotted or dashed lines somedistance away from the reflector point.

    Actually the far-field criterion is

    r D2/ (65 0.1925)2/(0.1925 2) 406 (11)obviously the object we scan is in the near field because the furthestpoint is only about 70mm away from the origin. Thus we cannot quali-tatively explain why there are two trails per reflector using the far-fieldapproximation PSF derived in lecture notes Page A17.

    Lets take some wild guesses here. Take the point nearest to the originand on z-axis for example. One of the trail is nearly horizontal, theother is more tilted towards right. Parameters known:

    size of the array D = 65

    0.1925

    12.5

    positions of receiving array xn [xmaxn , xmaxn ] = [6.25, 6.25] position of transmitter is [x0, 0] = [10, 0]

    Suppose the two trails of one single reflector are two arc of two circles.The center of the two circle should be around [0, 0] and [7, 0] (estimatedby naked eye). One intuitive guess would be that the two centers ofcircles are [(xmaxn +x0)/2, 0]. Then why just the boarders of the array?One intuitive guess would be

    All the contributions in the middle are somehow cancelled

    out by the contribution from their neighbors, thus leaving thetwo ends uncancelled(more exactly only partially cancelledby its only neighbor on one side).

    To prove the guess, two trials are taken:

    11

  • 7/18/2019 Ultrasound Project Report

    12/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    sin()

    r[mm]

    40 dB rsin()

    0.6 0.4 0.2 0 0.2 0.4 0.6

    10

    20

    30

    40

    50

    60

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (a) only with central element in r sin

    sin()

    r[mm]

    40 dB rsin()

    0.6 0.4 0.2 0 0.2 0.4 0.6

    10

    20

    30

    40

    50

    60

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (b) without central element in r sin

    x[mm]

    z[mm]

    scan level 40 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (c) only with central element in x z

    x[mm]

    z[mm]

    scan level 40 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    40

    35

    30

    25

    20

    15

    10

    5

    0

    (d) without central element in x z

    Figure 8: Results of the several trials. (a) and (b) are in xsincoordinates,(a) being the image reconstructed with only the central(33rd) channel, (b)the image using the full array except the central channel. In (b), a third newtrail appears the same place where the four parallel lines are in (a). Imageconverted to (c) and (d) respectively. In (a) and (c), reflectivity values arenormalized to make the maximum value unity in convenience of display.

    12

  • 7/18/2019 Ultrasound Project Report

    13/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    1. Images of rsin buffer and sector scan using only the datafrom the elements on both ends of the array are plotted. Theyare collections of parallel lines, either image with the uppermosttrail in the same position as the above-mentioned two trails. Thisshows that the two trails are indeed from the contributions of the

    two elements on either side of the array.

    2. One image using all elements except the middle one at the ori-gin(the 33rd one here) and the other using only the middle oneis plotted. The first image now has its characteristic three-trailfeature on the uppermost reflector, and the position of the thirdtrail is in the middle of the previous two, and agrees with the

    position of that trail in the second image obtained only with themiddle element. This shows that the contribution of a certainarray element is indeed cancelled out by other elements, mostly

    arguably neighboring ones because of limited span of radial PSF.

    These two trials altogether prove in a empirical way that the guess isright. The cancel-out between neighboring channels is due to destruc-tive interference results from the difference in phase rotations.

    Another question arises after the image is reconstructed with the datafrom only one channel. Why the image of a single reflector is an arc

    in the sector scan? It means that without constructive inter-channelinterference, one single channel cannot distinguish all the points in that

    arc tail. Then how about magnitude on that trail? A contour imagegenerated by commandcontourshows clearly that all the points in thattrail have the same reflectivity value, showing that it is not diminishingwith angles(now the x-axis). The reason why it is unlike the PSF ofa single-element scanner with a diminishing side-lobe is that the wavesent out is a isotropic spherical wave instead of being laterally limitedby an aperture function.

    All the points on that trail must have a certain same property

    that makes the single channel incapable of telling them apart. Thewave reflected by a single reflector and collected by one channel itselfcontains gives information on the position of the reflector, but onlyabout distance, more exactly the sum of the distances back and forth,dtotn = d0+ dn, as shown in Equation 3. Therefore the points on the

    13

  • 7/18/2019 Ultrasound Project Report

    14/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    sin(theta)

    r[mm]

    scan level 40dB

    0.6 0.4 0.2 0 0.2 0.4 0.6

    10

    20

    30

    40

    50

    6040

    35

    30

    25

    20

    15

    10

    5

    0

    (a) only with first element (left of array)

    sin(theta)

    r[mm]

    scan level 40dB

    0.6 0.4 0.2 0 0.2 0.4 0.6

    10

    20

    30

    40

    50

    6040

    35

    30

    25

    20

    15

    10

    5

    0

    (b) only with last element (right of arrray)

    sin(theta)

    r[mm]

    contour

    0.6 0.4 0.2 0 0.2 0.4 0.6

    10

    20

    30

    40

    50

    60

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1

    (c) contour of (a)

    sin(theta)

    r[mm]

    contour

    0.1 0.2 0.2 0.1

    0.1 0.1

    0.1

    0.1

    0.1

    0.15 0.1 0.05 0 0.05 0.1 0.15 0.2

    32

    34

    36

    38

    40

    42

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1

    (d) locally enlarged contour of (a)

    Figure 9: (a) and (b) are the plot reconstructed with only the element oneither end. In order to see that the reflectivity on the same trail is the same,contours are plotted in (c). To get better view, (d) is the enlarged plot ofthe boxed area in (c)

    14

  • 7/18/2019 Ultrasound Project Report

    15/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    trail should have the same sum of distance to the transmitter and

    receiver channel. This brings everything to light the trail in thesector scan is not an arcfrom a cricle, but part of anellipse. In Figure10,Tis the transmitter [10, 0]mm,R is the receiver of the first channel[D/2, 0] = [6.16, 0]mm

    20 15 10 5 0 5 10 15 20

    0

    10

    20

    30

    40

    50

    60

    70

    x

    z

    a b

    OR T

    Figure 10: the formation of elliptical trail

    Final Explanation The double-trail blur image of a discrete single pointreflector is the total PSF, which can be seen as the superposed singlePSF of every channel (similar to the expression ofR(r, )).

    P SF =Nn=1

    P SFn (12)

    P SFn=d0dn

    N an

    td0+dn

    c

    ei2f

    0(d0+dn)/c (13)

    15

  • 7/18/2019 Ultrasound Project Report

    16/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    For one single reflector, there are two arc-like trails. The trail is not

    exactly arc from a circle, but part of an ellipsewith one focus locatedat the transmitter [x0, 0] and the other located at the element at eitherend of the phased array [xmax, 0]. If the wavepacket of the signalan(t)is an ideal Dirac delta function, then

    P SFidealn =d0dn

    N

    r (d0+dn)

    ei2f

    0(d0+dn)/c (14)

    which is an equation of ellipse. Since the major axis is much largerthan the focal distance, the part of the ellipse can be approximatedby an arc with center of the circle located at the center of the ellipse

    [(xmaxn +x0)/2, 0]. Also the central angle of the arc 1, thus can

    be further approximated by

    r= a+(xmaxn +x0)sin

    2 (15)

    ais the radius of the circle used to approximate the exact ellipse.

    In r sin coordinate system, Equation (11) gives two straight lines,which agree with Figure(9).

    P SF = i P SFi, in other words, every channel would have its owncontribution of the two-trail pattern(PSF), but when added through allthe channels, the contributions(waves, which can have negative value)are added up destructively due to difference of phase rotation term,except the position near the location of the reflector, where all channelsinterfere constructively. The destructive interference mainly happensbetween neighboring channels, because the radial span of PSF is verylimited compared with angular direction. This leaves the two elements

    i.e. the eccentricity e 1.a can be approximated by

    a ct/2 c tickt/2 = c tick/(2fs

    )wheretickis the average of the row number where first none-zero elements appear across

    all channels. For example, from Figure 3(b), tickfor the uppermost point is approximately450, leading to a 21. Then Equation(11) is the equation for those two trails in polarcoordinate systems.

    16

  • 7/18/2019 Ultrasound Project Report

    17/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    at both ends of the array standing out of the group which only have

    neighbor on one side, marking the PSF pattern with two trails.

    Question I There are actually two slightly different ways to do this. Thefirst is cut the central piece located at z-axis out of the sector scan image,plotted in Figure 5(a) below. Since = 0 A-scan is pretty special, it canbe directly obtained fromsin= 0 column of rsdataeven before bilinearinterpolation, as plotted in Figure 5(b). The peak is a slightly a little lowerafter interpolation.

    After interpolation plot(z,image(:,21))

    Before interpolation plot(r,rsdata(:,33))

    0 10 20 30 40 50 60 70 800

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1Ascan image at theta=0

    r [mm]

    Refle

    ctivity

    (a) post-interpolation plot using image

    0 10 20 30 40 50 60 700

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1reflectivity before interpolation

    r [mm]

    Refle

    ctivity

    (b) pre-interpolation plot using rsdata

    Figure 11: A-Mode scan at =0

    The maximum value is 0.92, which is almost 1, representing the reflectorat about [0, 20]mm, nearest to the origin. In Figure 5(a), afterr 60mm,

    before interpolation the maximum is 0.98, even closer to 1

    17

  • 7/18/2019 Ultrasound Project Report

    18/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    the reflectivity goes up to and stays at 1 because of the data padding outside

    the POV wedge.

    Question J After we know the approximate configuration of the reflectorsin the POV field, a post hocexamination of the wavefield plot in Question Acan reveal more information(shame that we are not smart enough to realizeit sooner :-/ ).

    rawdata wavefield plot

    50 100 150 200 250

    50

    100

    150

    200

    250

    300

    350 0

    0.5

    1

    1.5

    2

    2.5

    3x 10

    3

    (a) wavefield plot of raw data

    x[mm]

    z[mm]

    scan level 20 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    20

    18

    16

    14

    12

    10

    8

    6

    4

    2

    0

    (b) 20dB sector scan

    Figure 12: revisit of the wavefield plot

    In both images, left side of the image correspond to the first transducerlocated at [D/2, 0]. There are four obvious stripes before the more messypattern in the wavefield plot. The first stripe is symmetric around the centralelement, indicating the symmetric geometry in the reflectors real position.

    It should be nearest to the origin, namely the reflector located at around[x, z] = [0, 20]mm. As a side-proof or double check, the stripe is around the350 + 100 = 450throw, thus the distance from the origin should be

    r c tickt/2 1.54 450/(2 16) 21.6mm (16)

    18

  • 7/18/2019 Ultrasound Project Report

    19/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    which agrees with the reasoning above. The arc is bent upward in the middle

    part because the reflected sound wave need a little more time to reach the ele-ment in the ends of the array than the middle element. Similar reasoning canapply to the second stripe at around 350 + 150 = 500th row, correspondingto the reflector at about [0, 23]mm.

    The third stripe is tilted toward left, i.e. to the first element, indicatingthat the 65thelement receives the signal earlier than the 1stone. Thereforeit should be nearer to the 65thelement, and the reflector around [13, 24]mmsatisfies this. From another perspective, the second and third stripe almost

    join together for the 65th channel. If we use what we learnt in QuestionH, the relevant two reflectors should sit on one ellipse with center at around

    (13+0)/2 = 6.5mmon x axis. This largely agrees with (x0+ xmax)/2(10 +6.25)/2 8mm. The fourth one can be reasoned in the similar way, mappingto the [14, 22]mmreflector in the sector scan.

    Interestingly, in the sector scan we can see there is a reflector at around[x, z] = [0, 58]mm, leading us to expect one arc-like stripe in the wavefieldplot at around

    tick 2rct

    =2rfs

    c =

    2 58 161.54

    1200throw (17)

    Looking closely at the fourth column of the wavefield plot of either raw dataor baseband data, at around 1200 350 3 = 150throw, which is at the endof the blurring block, there is indeed a barely recognizable arc-like stripe,like the first and second ones discussed above. This seems a little far-fetched,but since the stripe is still recognizable, this little discovery is attributed tothe virtue ofpost hocanalysis.

    Then the first blurring block begins at around 2 350 + 50 = 750throw,corresponding to a distance of around 36mmfrom the origin, agrees with theupper boarder of the first trapezoid reflector group. The blurring is becomingdimmer because further away from the origin, the triangle group has a larger

    proportion of contribution, resulting in a weaker reflection of signals. Theend of the blurring ends almost the same position as the very vague stripecorresponding to the lowermost discrete reflector at [0, 58]mm.

    19

  • 7/18/2019 Ultrasound Project Report

    20/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    2 Part II Generation of ultrasound data

    This part is about the sanity check as recommended by the professor.

    2.1 positioning of reflector points

    Out of curiosity of how good this whole system of data-generation and re-construction works for more complex shapes, I decided to use a traditionalChinese character (yes, my family nameLiu inRegular Script:P ) as thescattering object.

    50 100 150 200 250 300

    50

    100

    150

    200

    250

    300 0

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1

    (a) original picture

    x[mm]

    z[mm]

    original object

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    0

    0.1

    0.2

    0.3

    0.4

    0.5

    0.6

    0.7

    0.8

    0.9

    1

    (b) original reflecting object

    Figure 13: preparation of collection of reflectors

    First one 300300 PNG picture of the character is obtained using graphicsoftware and then loaded it into Matlab, generating one 300300 matrix. Itis then relocated and resized into a 200200 area in the lower-middle part ofa 401

    500 matrix, with value 1 inside the character, and 0 outside. This is

    used to sift randomly generated points inside the big matrix with reflectivityvalues assigned to 1.0 on the left, and 0.5 on the right(as shown in Figure13).

    Finally 3000 random points inside the character shape are generated. Inorder to observe behaviors of single point reflectors, four point reflector are

    20

  • 7/18/2019 Ultrasound Project Report

    21/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    placed at [180, 200], [420, 200], [300, 100] and [350, 300]. As for parameters

    used for generation of wavefield raw data, fs = 4f0 = 16Hz is used here,same as what is used in this project Part I. The signal is sent in Gaussianwavepacket,

    a(t) =e(tf02)2

    (18)

    which contain about three periods of ocillation.

    1 0.5 0 0.5 1 1.5 2

    1

    0.5

    0

    0.5

    1

    t [106

    sec]

    signal

    Figure 14: Gaussian signal wavepacket (dashed line) and modulated signal(solid line). Note that center is not located att = 0.

    2.2 Method used in data generation

    In raw data generation, every t, the data across all channels are collected.Every channel should have the superposition of wave pressure contributionfrom each of the 3000 reflectors, the signal received by the nth channel attimet is

    vn(t) =

    Nre

    i=1

    R

    di

    0din

    a(t

    di0+d

    in

    c

    )cos(2f0(t

    di0+d

    in

    c

    ) +n) (19)

    these are row/column indices, not spatial positons

    21

  • 7/18/2019 Ultrasound Project Report

    22/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    where

    di0(ri, i)

    r2i +x20 2rix0sini (20)

    din(ri, i)

    r2i +x2n 2rixnsini (21)

    are the distance from transmitter to the ith reflector point, and the distancefrom the ith reflector point back to the receiver of the nth channel. Nre isthe total number of reflector point, therefore 3000 in this project, n is setto zero across all channels.

    Then raw data is beam-formed and scan converted to the sector scan, asplotted below:

    x[mm]

    z[mm]

    scan level 30 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    30

    25

    20

    15

    10

    5

    0

    (a) 30 dB scan

    x[mm]

    z[mm]

    scan level 60 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    60

    50

    40

    30

    20

    10

    0

    (b) 60 dB scan

    Figure 15: reconstruction of reflecting object

    Things worked out pretty good, except that generating data for the 3000points takes quite a while(around a minute on my laptop). There are ap-

    proximately

    ntimenelemNre 1500 65 3000 3 108 FLOPs (22)in the whole calculation process, each FLOP being one evaluation of the ex-pression inside the summation of Equation (16).

    22

  • 7/18/2019 Ultrasound Project Report

    23/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    In Equation(19), once the geometry of reflectors and the equipment is

    chosen, the number of transducer elements nelem and number of reflectorsNre is fixed, and

    ntime= 2zmax/(ct) = 2zmaxfs/c (23)

    If sampling rate fs increases, the calculation time needed would increaselinearly.

    2.3 further exploration

    As pointed out in Part I Question D&E, there is an alternative way of

    phase correction, which is not accurate generally, but can lead to sufficientlygood quality once the sampling rate is large enough. Increasing samplingratefs to 2fs and 4fs, raw data are generated again, and then reconstructedimages using these new data are compared with the image using exact phasecorrection under original sampling rate fs as plotted in Figure 16. For (d)where fs = 4fs = 16f0, there is hardly any visible difference from (a), sup-porting the reasoning before.

    23

  • 7/18/2019 Ultrasound Project Report

    24/24

    BIOMEDE 516 ultrasound project Langechuan Liu

    x[mm]

    z[mm]

    scan level 30 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    30

    25

    20

    15

    10

    5

    0

    (a) exact phase correction with fs

    x[mm]

    z[mm]

    scan level 30 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    30

    25

    20

    15

    10

    5

    0

    (b) alternative phase correction with fs

    x[mm]

    z[mm]

    scan level 30 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    30

    25

    20

    15

    10

    5

    0

    (c) alternative phase correction with 2fs

    x[mm]

    z[mm]

    scan level 30 dB

    30 20 10 0 10 20 30

    10

    20

    30

    40

    50

    60

    70

    30

    25

    20

    15

    10

    5

    0

    (d) with alternative phase correction with 4fs

    Figure 16: reconstruction using different ways of phase correction under 30dB

    24