13.07.2015 Views

T T tr - FKE - UTM

T T tr - FKE - UTM

T T tr - FKE - UTM

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

UNIVERSITI TEKNOTOGI MALAYSIAPSZ 19:l6lPind. l/071DECIARATION OF THESIS / UNDERGRADUATE PROJECT REPORT AND COPYRIGHTAuthor's full nomeDote of BirthTitleHONG WIN SOON2 FEBRUARY I99OHUMAN HEART IMAGE RECONSTRUCTION USING TABVIEWAcodemic Session2012/2013I declore thot this thesis is clossified os:TT<strong>tr</strong>CONFIDENIIAL (Contoins confidentiol informotion under the Officiol Secret Act1972)*RESTRICIED (Contoins res<strong>tr</strong>icted informotion os specified by theorgonizotion where reseorch wos done)*OPEN ACCESS I ogree thot my thesis to be published os online open occess(fulltext)I ocknowledged thot UniversitiTeknologi Moloysio reseryes the right os follows:l. The thesis is the property of UniversitiTeknologi Moloysio2. The Librory of Universiti Teknologi Moloysio hos the right to moke copies for thepurpose of reseorch only.. 9.The Librory hos the right to moke copies of the thesis for ocodemic exchonge.Certified by:SIGNATURE900202-03-s257(NEW rC NO/PASSPORT)DR. YUSMEERAZ YUSOFNAME OF SUPERVISORDote: JULY 2013Dote: JULY 2013-NOTES: *lf the thesis is CONFIDENTAL or RESTRICTED, pleose ottoch with the letter fromthe orgonizotion with period ond reosons for confidentiolity or res<strong>tr</strong>iction.


"I hereby declare that I have read this thesis and in myopinion this thesis is sufficient in tenns of scope and quality for theaward of the degree of Bachelor of Engineering (Elec<strong>tr</strong>ical - Elec<strong>tr</strong>onics)"SignatureName of SupervisorDate. Yusmeeraz Yusof18 June 2013


iiI declare that this thesis entitled "Human Heart Image Recons<strong>tr</strong>uction UsingLab VIEW' is the result of my own research except as cited in the references. Thethesis has not been accepted for any degree and is not concurrentlycandidature of any other degree.submitted inSignatureNameDateHong Win SoonJuly 2013


iiiSpecially dedicated to my family,fellow lecturers and all my friends whogave me the support and confidence to finishthis project.


ivACKNOWLEDGEMENTSI would like to thank everyone who had helped and supported me in finishingthis project. Without your help and support, this project would have been muchharder to be realized. Firstly, I would like to thank my family who gave me thesupport and moral encouragement needed. You all gave me encouragement andadvice when I am down, for that I am very grateful.Secondly, I would like to convey my gratitude towards my supervisor, Dr.Yusmeeraz Yusof. I would like to thank her for her guidance, help and support givento me during this project. Dr Yusmeeraz has been really patient and attentive inguiding me throughout the project, offering various advices and reminding me ofimportant dates while also gave me counsel when required.Thirdly, I am <strong>tr</strong>uly grateful for the help offered by Dr Anita Ahmad in thisproject. As this project was based on her previous work, she had offered me guidanceand explanation on the various topics concerning her project. She had also en<strong>tr</strong>ustedme with her MATLAB programming used in her project and also provided me withthe coordinate data required to recons<strong>tr</strong>uct the image. I would like to also thank DrUsman in providing me a better understanding on image cons<strong>tr</strong>uction techniques. DrUsman had been very kind and attentive, for if it were not for his explanation andhelp I would not have been able to properly grasp the concepts needed.Lastly, I would like to thank all my friends who had offered me helpedthroughout the period of this project. Special thanks goes towards Miss Saw WeiTing, Miss Loo Hui Ru and Mr Jeevan. Your help is greatly appreciated.


vABSTRACTThe human heart is a sensitive organ and very important to the healthy beingof a person. The human heart pumps blood throughout the human body at very highpressures and is protected by a s<strong>tr</strong>ong bone s<strong>tr</strong>ucture called a ribcage. Biopsies intothe human heart are very dangerous and may cause death to the patient. Therefore amuch low risk method has to be devised. This project is aimed at recons<strong>tr</strong>ucting a3D image of the right a<strong>tr</strong>ium, which is one of the human heart chambers, using theLabVIEW software. The project's goal is to utilise and explore the capabilities ofLabVIEW software in data ex<strong>tr</strong>action and recons<strong>tr</strong>uction of the 3D image of ana<strong>tr</strong>ium chamber of the human heart based on coordinate data obtained from theEnSite catheter probe. The LabVIEW software is used to ex<strong>tr</strong>act the coordinate datafrom a text file and then process the data so that it becomes suitable for 3D imagerecons<strong>tr</strong>uction. At the end, a functional program capable of processing thecoordinate data and recons<strong>tr</strong>ucting the complete 3D image of the right a<strong>tr</strong>ium of thehuman heart using the LabVIEW software was successfully developed.


viABSTRAKJantung manusia adalah organ badan yang amat sensitive lagi penting dalammemastikan kesihatan seseorang manusia. Jantung manusia mengepam darah keseluruh tubuh badan manusia pada tekanan yang tinggi dan dilindungi oleh stukturtulang manusia (tulang rusuk) yang amat kuat. Biopsi kepada jantung manusiaadalah amat berbahaya dan boleh melibatkan pesakit tersebut maut. Oleh itu, satukaedah yang lebih berisiko rendah telah dicadangkan. Projek ini adalah untukmembina semula imej 3D salah satu bahagian daripada organ jantung manusia, iaitubilik a<strong>tr</strong>ium, berdasarkan data koordinat yang diperoleh oleh alat probe kepadajantung manusia, dengan menggunakan perisian LabVIEW. Tujuan projek ini adalahuntuk menggunakan dan meneroka kelebihan perisian LabVIEW dalam proseseks<strong>tr</strong>asi data dan pembinaan semula imej 3D bilik a<strong>tr</strong>ium dalam jantung manusuaberdasarkan data koordinat yang diperoleh oleh alat probe ke dalam jantung manusia.Perisian LabVIEW akan mengeks<strong>tr</strong>ak data kordinat daripada “text file” danmemprosesnya supaya ianya sesuai untuk tujuan pembinaan semula imej 3D. Padaakhir projek ini, sebuah program yang berfungsi dengan baik yang boleh memprosesdata kordinat yang diperoleh daripada alat probe dan dengan perisian LabVIEW,membina semula imej 3D bilik a<strong>tr</strong>ium organ jantung manusia telah berjayadibangunkan.


viiTABLE OF CONTENTSCHAPTER TITLE PAGEDECLARATIONDEDICATIONACKNOWLEDGEMENTSABSTRACTABSTRAKTABLE OF CONTENTSLIST OF TABLESLIST OF FIGURESLIST OF ABBREVIATIONSLIST OF SYMBOLSLIST OF APPENDICESiiiiiivvviviixixiixvxvixvii1 INTRODUCTION 11.1 Background of Study 11.2 Problem Statement 31.3 Objectives of Study 31.4 Scope of Study 41.5 Significance of Study 4


viii2 LITERATURE REVIEW 52.1 In<strong>tr</strong>oduction 52.2 Heart Problems in Malaysia 52.3 3D Medical Imaging Versus 2D Medical Imaging 62.4 Probe Data Acquistion 72.5 Future Integration of FPGA in Medical Imaging 92.6 Overview on LabVIEW 123 RESEARCH METHODOLOGY 133.1 In<strong>tr</strong>oduction 133.2 Design Overview 133.3 Data Ex<strong>tr</strong>action Block 153.4 Primary Data Processing Block 163.5 Secondary Data Processing Block 173.6 3D Image Recons<strong>tr</strong>uction Block 183.7 Software- NI LabVIEW 204 COORDINATE DATA AND MATLAB BENCHMARK 214.1 In<strong>tr</strong>oduction 214.2 Coordinate Data 214.3 Published MATLAB Simulation Image for Benchmarking 235 LabVIEW PROGRAM DESIGN 255.1 In<strong>tr</strong>oduction 25


ix5.2 Design Overview 255.3 Data Ex<strong>tr</strong>action 275.4 Primary Data Processing 295.5 Secondary Data Processing 325.5.1 Array Reshaping 335.5.2 Array Reprocessing 345.5.2.1 X-MOD 355.5.2.2 Y-MOD 365.5.2.3 Z-MOD 375.6 3D Image Recons<strong>tr</strong>uction 385.6.1 3D Scatter Plot 395.6.2 3D Parame<strong>tr</strong>ic Surface Plot 405.6.3 3D Surface Plot Via MathScript Node 416 LabVIEW 3D IMAGE WITH MATLAB BENCHMARK 446.1 In<strong>tr</strong>oduction 446.2 3D Image Benchmark and Comparison 446.3 Comparing Initial and Final Image 517 CONCLUSION & RECCOMENDATIONS ONFUTURE WORKS 547.1 In<strong>tr</strong>oduction 54


x7.2 Conclusion 547.3 Recommended Improvements 557.4 Recommendations on Future Works 56REFERENCES 57Appendices A – C 59


xiLIST OF TABLESTABLE NO. TITLE PAGE1.1 Time Taken to Recons<strong>tr</strong>uct 512x512 images 11


xiiLIST OF FIGURESFIGURE NO. TITLE PAGE2.1 EnSite Catheter Probe Before Expansion 82.2 EnSite Catheter Probe After Expansion 82.3 The Passing of The Probe from the Right A<strong>tr</strong>ium toThe Left A<strong>tr</strong>ium Through The Fossa Ovalis 93.1 Overview of The Program’s Flow 143.2 Flow Chart of Data Ex<strong>tr</strong>action Block 153.3 Flow Chart of Primary Data Processing Block 163.4 Flow Chart of Secondary Data Processing Block 173.5 Flow Chart of Part A of 3D Image Recons<strong>tr</strong>uction Block 183.6 Flow Chart of Part B of 3D Image Recons<strong>tr</strong>uction Block 194.1 Sample of Coordinate Data Obtained From St June Medical,United Kingdom 224.2 3D Image Recons<strong>tr</strong>uction of the Right A<strong>tr</strong>ium, 2048 Points 234.3 3D Image Recons<strong>tr</strong>uction of the Right A<strong>tr</strong>ium, 256 Points 245.1 Part A of the Overview of the Program Design 265.2 Part B of the Overview of the Program Design 265.3 Data Ex<strong>tr</strong>action Block 275.4 Text File of Coordinate Data 29


xiii5.5 Primary Data Processing Block 295.6 Program For Primary Data Processing Block When Case Is“True” 305.7 Program For Primary Data Processing Block When Case Is“False” 315.8 Secondary Data Processing Block 325.9 Array Reshaping Section of the Secondary DataProcessing Block 335.10 Array Reprocessing Section of the Secondary DataProcessing Block 345.11 X-MOD Sub-VI 355.12 Y-MOD Sub-VI 365.13 Z-MOD Sub-VI 375.14 3D Image Recons<strong>tr</strong>uction Block 385.15 3D Scatter Plot VI 395.16 3D Image Scatter Plot 395.17 3D Parame<strong>tr</strong>ic Surface Plot 405.18 MathScript Node Commands 415.19 3D Surface Made Via MathScript Node 426.1 Front View (A) of the 3D Image Generated By LabVIEW 456.2 Front View (A) of the 3D Image Generated By MATLAB 456.3 Front View (B) of the 3D Image Generated By LabVIEW 466.4 Front View (B) of the 3D Image Generated By MATLAB 47


xiv6.5 Left Side View of the 3D Image Generated By LabVIEW 486.6 Left Side View of the 3D Image Generated By MATLAB 486.7 Right Side View of the 3D Image Generated By LabVIEW 496.8 Right Side View Of The 3D Image Generated By MATLAB 506.9 Back View Of 3D Image Without X, Y and Z MOD Sub VI 526.10 Back View Of 3D Image With X, Y and Z MOD Sub VI 52


xvLIST OF ABBREVIATIONS3D - Three Dimension2D - Two DimensionalMRI - Magnetic Resonance ImagingCAT - Computer Aided TomographyNI - National Ins<strong>tr</strong>umentsFPGA - Field Programmable Gate ArrayASIC - Application Specific Integrated CircuitCPU - Cen<strong>tr</strong>al Processing UnitFFT - Fast Fourier TransformsVI - Virtual Ins<strong>tr</strong>umentsSt - Saint<strong>UTM</strong> - Universiti Teknologi MalaysiaFYP - Final Year Project


xviLIST OF SYMBOLSX - Indicate dimension of an array where (row) against (column)


xviiLIST OF APPENDICESAPPENDIX NO. TITLE PAGEA X-Array Before and After Processing 59B Gantt Chart 61C The Star Article Ex<strong>tr</strong>act 63


1CHAPTER 1INTRODUCTION1.1 Background of StudyMedical imaging has always been important in assisting doctors to analysethe cause of their patient's illness. There are many medical imaging devicesavailable in the current market. Examples of popular modern medical imagingdevices in the market are Magnetic Resonance Imaging (MRI) and Computer AidedTomography (CAT) scans. Modern medical imaging devices are capable ofproviding a two-dimensional (2D) image insight of their patient's internal bodyconditions. However, not many of them are capable of providing a threedimensional(3D) image of their patient’s organ.2D image scans are like a picture or a photo of a man under a <strong>tr</strong>ee. As theman is sitting under the <strong>tr</strong>ee, and in front of it, thus from the angle of the photo wastaken, the condition of the <strong>tr</strong>ee which was covered behind him will not be apparent.This is because the images are viewed from a “X-Y” axis perspective, but not in a“X-Y-Z” axis perspective instead.Such is an example of the limitations of 2D images. Unlike a 2D image scan,doctors can use the image generated from a 3D scan to obtain a more thorough view


2of their patient’s condition, and much more accurately diagnose their patients. Theyare able to view what is “behind the boy” and observe the “condition of the <strong>tr</strong>ee”.For example , if a 2D MRI scan from a patient indicates multiple odd growthsin the brain of a patient, a doctor might miss-diagnose the patient as having multiplebrain tumour growth and he or she have not long to live. However the patient mightactually be suffering from multiple fungal growths in the brain, a condition whichdoes not happen commonly but, have a small possibility of occurring. Either way,the doctor is unable to accurately determine the nature of the growth until a brainbiopsy is done to determine the nature of the growth. Such surgery is very taxing tothe patient and might cause various medical complications and even death if notproperly done by a highly <strong>tr</strong>ained and experienced surgeon.However, if the doctor has a 3D view of the growth in the brain, he wouldhave been able to study and view the growth in a much detailed fashion. The doctorwould then be able to accurately diagnose the nature of the growth, and the patientdoes not have to undergo s<strong>tr</strong>enuous surgery.This project is a small step towards such a goal. Using coordinate dataobtained from a probe into the human body, a 3D image of a human heart a<strong>tr</strong>iumchamber will be recons<strong>tr</strong>ucted, with the help of the LabVIEW computer software byNational Ins<strong>tr</strong>uments.LabVIEW is a development software made by National Ins<strong>tr</strong>uments (NI) thatfeatures graphical programing instead of normal programming language such as C,C++, Verilog, VHDL coding and more. As such, users are able to grasp the methodof programming much more quickly without the need to learn various types ofcoding. LabVIEW coding is compatible with almost all National Ins<strong>tr</strong>umentshardware and thus enables a rapid deployment of their respective designs that arebased on LabVIEW without much compatibility issues. LabVIEW is mainly used to


3design and test measurement and con<strong>tr</strong>ol systems however, with upgrades made toLabVIEW over the years, it has become a powerful development tool capable ofeven recons<strong>tr</strong>ucting 3D images.1.2 Problem StatementI. The lack of presence of 3D imaging project for the human heart.II. Malaysians are one of the most prone to heart disease in the world.III. Risky biopsy procedures can cause death to patient during and after surgery.IV. Doctors might misdiagnose patients due to inaccurate interpretation of normal2D image scans.1.3 Objectives of StudyThe objectives of this project are:I. To develop a program that is capable of recons<strong>tr</strong>ucting a 3D image of theright a<strong>tr</strong>ium of the human heart.II. To explore the potential of LabVIEW in heart image recons<strong>tr</strong>uction.III. To validate the recons<strong>tr</strong>ucted image using LabVIEW with the imagedeveloped using MATLAB [5].


41.4 Scope of StudyThe scopes of this project are:I. Cons<strong>tr</strong>uct a 3D image using the coordinate data consisting of 256 points andobtained from real patient of Saint June Medical, United Kingdom.II. Generate a 3D image of the human heart a<strong>tr</strong>ium with assistance of LabVIEWSoftwareIII. Verify the 3D image with MATLAB.1.5 Significance of StudyThe ultimate goal of this research will not only help doctors better diagnose patientswith heart conditions but will also help them better understand their patient’sconditions. Furthermore, patients themselves don’t have to undergo normal biopsyprocedures or risky surgery for doctors to identify their heart condition. As such,patients do not need to undergo long and tiresome recuperation periods.Futhermore, the research will explore the capabilities of LabVIEW software and itspotential in 3D image recons<strong>tr</strong>uction. LabVIEW designs are compatible with almostall hardware made by National Ins<strong>tr</strong>uments, therefore it has potential of becoming aplatform for the development of medical imaging devices. The developers need onlybuild a basic LabVIEW design and assimilate it with other con<strong>tr</strong>ol and processinghardware made by National Ins<strong>tr</strong>uments which will then be connected to varioussensors and measuring devices. LabVIEW software will take in the data from themeasuring devices and sensors, and recons<strong>tr</strong>uct a 3D image of the scanned area.


5CHAPTER 2LITERATURE REVIEW2.1 In<strong>tr</strong>oductionIn this chapter, background of the project, justification of the project, a shortexplanation on how the coordinate data is obtained, and also the futureimplementation of the design on an FPGA system is reviewed.2.2 Heart Problems in MalaysiaHeart diseases are a great concern in Asian coun<strong>tr</strong>ies, and althoughimprovements in health services and facilities were made, the number of cases ofheart disease in increases year after year. K.-H Mak [1] studies the cases ofmyocardial infarction cases among ethnic groups in Singapore and noted that Malayshad the greatest fatality rate among the ethnic groups. The main cause of heartdiseases is due to their unhealthy lifestyle primarily at<strong>tr</strong>ibuted to food intake andsocioeconomic factors. Although the article refers to the Singaporean ethnic group,however due to the similarities of the Malaysian culture and also lifestyle, the studywould apply to Malaysians as well to some extent.A recent article from The Star [2], pinpointed that heart disease is the numberone killer of women in Malaysia. According to the article, the general perception


6was that only older men are prone to heart diseases. However, as the statistics shows,such assumptions are faulty and misleading. In the article, Dr Azhari a consultantcardiologist at the National Heart Institute said the latest 2011 National Health andMorbidity Survey (NHMS IV) had revealed some alarming statistics, including thefact that Malaysian women had the highest body mass index (BMI) in the South-EastAsian region. Furthermore, women formed a 60% majority of Malaysians who hadelevated total cholesterol levels, another factor that con<strong>tr</strong>ibuted to heart disease.With ever increasing cases of heart disease cases among Malaysians, theimportance of advanced scanning techniques in helping doctors conduct theirdiagnosis is evermore justified.2.3 3D Medical Imaging Versus 2D Medical Imaging3D medical imaging enables doctors to view parts of the scanned humanorgans at a much better viewpoint. As one can view the specific organ in “X-Y-Z”axis, doctors can better view the nature of the oddity and the condition of the patient.Most 3D medical imaging devices work on data acquired from 2D scanningtechniques, such as CT scan and MRI scan. The data will then be passed through acomputer to be recons<strong>tr</strong>ucted into an image.In Gergio Sarkas’s work [3], he discussed the various 3D imaging techniquesavailable in the current market, from CT scans to Ul<strong>tr</strong>asound in generating 3Dimages using a computer from 2D image scanning techniques. In his paper, he alsostated the <strong>tr</strong>end of using 3D images in the medical field and s<strong>tr</strong>esses ever increasingcomputer power, falling prices and their general availability to be the proponentfactors behind this <strong>tr</strong>end.


7If one were to compare a 2D image to a 3D image of a human organ in itsanatomical s<strong>tr</strong>ucture, 3D images will no doubt be able to represent the anatomicals<strong>tr</strong>ucture of the organ in a more realistic manner compared to a 2D image. 3Dimages also enable doctors to be more intuitive with their work and are able toprovide a much more accurate image-based diagnosis and <strong>tr</strong>eatments [4]. Thus,patients do not have to undergo s<strong>tr</strong>enuous biopsy procedures and help reduce thetime needed to make a diagnosis.2.4 Probe Data AcquisitionThe coordinate data used in this project is based from probe data collectedfrom 10 real patients of St. June Medical, United Kingdom.Firstly, the patient undergoes a small surgery in which doctors insert a probe,known as the EnSite catheter, which can be seen in Figure 2.1, from the lower thighof the patient and slowly move the probe into the human heart. The probe thenenters the right a<strong>tr</strong>ium of the human heart and through a tiny depression within thewalls of the human heart, known as the Fossa Ovalis, the probe enters the left a<strong>tr</strong>iumof the human heart and expands itself. The expanded probe can be seen in Figure 2.2.The probe once expanded is known as a “balloon” and has multiple tiny elec<strong>tr</strong>odes tocatch ECG <strong>tr</strong>aces. Figure 2.3 shows the way the probe is passed from the righta<strong>tr</strong>ium to the left a<strong>tr</strong>ium. A system will be used to convert the raw data intocoordinate data of 2048 points, which are in [64x32] in dimension, which can be thenused to build an isopotential map [5].


8Figure 2.1 EnSite Catheter Probe Before Expansion [5]Figure 2.2 EnSite Catheter Probe After Expansion [5]


9Figure 2.3The Passing of The Probe from the Right A<strong>tr</strong>ium to The Left A<strong>tr</strong>iumThrough The Fossa Ovalis. [6]2.5 Future Integration of FPGA in Medical ImagingAlthough 3D medical images provide a much better view for doctors toconduct their diagnosis, and can be built from 2D imaging data, most 3D medicalimaging algorithms are computationally intensive and this causes real time 3Dimaging to be expensive and not very practical for most clinical applications [4]. JiaChunli proposed that compared to (Application Specific Integrated Circuit) ASICwhich requires a high development cost, (Field Programmable Gate Array) FPGAbased systems offers a good balance between performance and flexibility for suchapplications. Modern FPGAs integrate hard-wired processor cores, SRAM blocks,multipliers, digital clock managers and massive reconfigurable logic resources in asingle chip. Thus, by carefully considering the resources and customize the


10computing architecture within the FPGA to adapt and process different algorithms,the FPGA can be easily reconfigured for different algorithms and thus bypassing theneed to obtain new hardware. Therefore, the same FPGA can be easily used toprocess different data for multiple 3D scanning techniques. This in turn, helps toreduce the costs of 3D imaging equipment.Nikhil [7] noted that for a custom or “niche market” computations tha<strong>tr</strong>equire acceleration, an off-shelf co-processor such as a graphics card, might not beable to provide the desired performance or power efficiency. In his thesis, he notedthat an Application Specific Integrated Circuit (ASIC) would offer a betterperformance for processing such tasks but lack the flexibility of an FPGA andrequire a large amount of resources to fabricate. He also explains that for FPGAsystems, speedup is not achieved by the operations of the design under high clockfrequencies but by exploiting the parallelism in the design of the system. Nikhil dida research and compared FPGA’s performance to respective mid-range processingdevices at his time, which is shown in Table 1. His comparison of data from otherresearch showed that FPGA outperformed both 1GHz Pentium 3 CPU and alsoNVDIA GF7800 graphics card using various FPGA boards. However, ASIC still hasthe highest performance of them all.


11Table 1 Time Taken to Recons<strong>tr</strong>uct 512x512 Images [7]Dr Kohji Ohbayashi [8] used the flexibility of and scalability of PXI platformand also the NI FlexRio to develop the world’s first real-time 3D OCT imagingsystem. National Ins<strong>tr</strong>ument’s LabVIEW software was used to program, integrate,and con<strong>tr</strong>ol different parts of the system and help combine the high-channel-countacquisition with both FPGA and GPU processing to obtain real-time computation,rendering and display. In his work, he and his team used NI FlexRio FPGA systemto compute more than 700,000 512 points (Fast Fourier Transforms) FFT everysecond to achieve 3D imaging while maintaining high channel density for the 320channel system in order to enable real time imaging. His work shows the power ofan FPGA system and its ability to outperform more advanced co-processors intoday’s market.


122.6 Overview on LabVIEWLabVIEW software is developed by National Ins<strong>tr</strong>uments and is usually usedto design con<strong>tr</strong>ol, testing and measurement systems. Yang Ding [9] used acombination of LabVIEW and also MATLAB to build an intelligent fieldbus con<strong>tr</strong>olsystem, which is capable of quick responses and small steady-state error.Singh.P [10] built a cost-effective multi-motion con<strong>tr</strong>ol system with the help ofLabVIEW where the LabVIEW software was used to build the PC-to-Motorinterface. Xiang Xuejun [11] used LabVIEW to simulate a con<strong>tr</strong>ol system – LeverProcess Con<strong>tr</strong>ol System, in real time.With the continuous improvements done to the software, LabVIEW softwarehas been equipped with various advanced functions. One of which is of great interestfor this project, the field of image processing. Li.Ce [12] used LabVIEW to enhancean X-ray image based on fuzzy sure en<strong>tr</strong>opy. The image was partitioned into bothdark and light parts and utilizing then using LabVIEW software, optimal pair isfound via maximum fuzzy en<strong>tr</strong>opy.LabVIEW is also capable of integrating MATLAB based programming viaMathScript Node function. Wuni Xu [13] integrates both MATLAB and LabVIEWsoftware to design a system which utilizes LabVIEW for hardware support and quickconfiguration while MATLAB is used for its complex computing functions.


13CHAPTER 3RESEARCH METHODOLOGY3.1 In<strong>tr</strong>oductionThis chapter describes the design process of the project in two main sections, thehardware FPGA design and also the NI LabVIEW Software design process. It alsogives an overview of the system and design process.3.2 Design OverviewFigure 3.1 shows the overall flow chart of the program. Firstly, X-Y-Zcoordinate data from the probe in the form of a text file is ex<strong>tr</strong>acted and passed on tothe primary data processing. The software will switch on an interface prompting theuser to search for the text file in the computer. The ex<strong>tr</strong>acted data will be in the formof a 2 dimensional array and during the primary data processing. The 2D array willbe appended and split into 3 one dimensional arrays, which are X, Y and Z onedimensional arrays.


14Figure 3.1Overview of The Program’s FlowThe arrays will then undergo secondary data processing where the array willbe modified to be suitable for 3D image recons<strong>tr</strong>uction.After that, the array data will be gathered and a 3D image of the right a<strong>tr</strong>iumwill be built using the array data via LabVIEW’s Virtual Ins<strong>tr</strong>uments (VI).


153.3 Data Ex<strong>tr</strong>action BlockFigure 3.2Flow Chart of Data Ex<strong>tr</strong>action BlockFigure 3.2 shows the flow chart of the data ex<strong>tr</strong>action process. Theapplication will prompt the user for the directory of the text file in the computer forprocessing. Once the program has obtained the directory for the text file, it willbegin reading and ex<strong>tr</strong>acting data from the text file row by row. It will continue todo so until all the data from each row have been processed. A two-dimensional array(2D array) will be formed from the data ex<strong>tr</strong>acted, and passed to the primary dataprocessing block.


163.4 Primary Data Processing BlockFigure 3.3Flow Chart of Primary Data ProcessingIn this block, the 2D array from the Data Ex<strong>tr</strong>action Block will be processedaccording to the process flow shown in Figure 3.3. The program will first check ifall rows of the 2D array have been read and processed. If the all rows have not beenread, then the program will proceed to ex<strong>tr</strong>act data from the next row. The programwill check if the total numerical value of the row total is equal to zero. If the rowtotal is zero, then that means the row is empty and the program will ignore the row.If the row total is not equal to zero, the program will append the row data into a newarray.


17The whole process is repeated until all rows have been read. Once all rowshave been read, the program will then split the newly 2D array into X, Y and Z onedimensional arrays. Each of those X, Y and Z one-dimensional arrays contain thevector coordinate data essential for the image recons<strong>tr</strong>uction. These one-dimensionalarrays will then be further processed in the Secondary Data Processing Block.3.5 Secondary Data Processing BlockFigure 3.4Flow Chart of Secondary Data Processing BlockIn this block, the one-dimensional arrays for X, Y and Z are further processedinto forms that are suited for the 3D image recons<strong>tr</strong>uction by LabVIEW software. Asshown in Figure 3.4, the X, Y and Z one-dimensional arrays will be reshaped into16X16 two-dimensional arrays. Each of these arrays will then be processed by theMOD X, Y and Z sub VI. MOD X will process the X array, MOD Y will process the


18Y array and MOD Z will process the Z array. The function of the MOD X, Y and Zsub VI is to edit the array data so that the recons<strong>tr</strong>ucted 3D image looks like a 3Ds<strong>tr</strong>ucture instead of a 3D surface.3.6 3D Image Recons<strong>tr</strong>uction BlockFigure 3.5Flow Chart of Part A of 3D Image Recons<strong>tr</strong>uction BlockThere are three types of plots in this project. The first plot is a 3D scatter plot, whichis formed by taking in one-dimensional array data of X, Y and Z from the PrimaryData Processing block as shown in Figure 3.5. The 3D scatter plot is a plot of X, Yand Z coordinate data onto a 3D environment. The plot is useful for early andpreliminary planning and <strong>tr</strong>ouble-shooting and also for testing.


19Figure 3.6Flow Chart of Part B of 3D Image Recons<strong>tr</strong>uction BlockThe next plot is a 3D parame<strong>tr</strong>ic plot. As shown in Figure 3.6, the 3D parame<strong>tr</strong>icplot takes in X, Y and Z 2D array data that has been processed by the SecondaryData Processing block, and builds a 3D surface from the data.The final plot is a 3D plot using the Mathscript Node. The Mathscript Node is usedto integrate MATLAB based functions and coding in LabVIEW. However, thecoding used in LabVIEW’s Mathscript Node is different from the coding inMATLAB. The Mathscript Node will take in the X, Y and Z 2D array that has beenprocessed by the Secondary Data Processing block and use it to recons<strong>tr</strong>uct the 3Dimage. A 3D plot by Mathscript Node is used as it has a better look, interface andcon<strong>tr</strong>ols over the 3D parame<strong>tr</strong>ic plot.


203.7 Software – NI LabVIEWNI LabVIEW software is used in this project for three main purposes, (1) toex<strong>tr</strong>act the data from the text file, (2) to process the data ex<strong>tr</strong>acted and (3) to act as animage recons<strong>tr</strong>uction software using its respective virtual ins<strong>tr</strong>uments.


21CHAPTER 4COORDINATE DATA AND MATLAB BENCHMARK4.1 In<strong>tr</strong>oductionThis chapter will discuss the nature of the coordinate data obtained from St.June Medical and also the verification of the image recons<strong>tr</strong>uction with theMATLAB image that was done by Dr Anita [5].4.2 Coordinate DataCoordinate data of 10 patients were obtained from St.June Medical. Anexample of the data is shown in Figure 4.1.


22Figure 4.1Sample of Coordinate Data Obtained From St.June Medical, UnitedKingdom [5]From Figure 4.1, it is shown the data from the probe that has been processedinto various coordinate data that are required to recons<strong>tr</strong>uct the 3D image of the a<strong>tr</strong>ialchamber in the form of X-Y-Z coordinates. The data lists some specific points whichact as “markers” for the image recons<strong>tr</strong>uction process.The rest of the data are to be processed accordingly with respect to the“markers”. In Figure 4.1, note that the lower portion of the data is a huge set ofnumbers. The coordinate data which will be used in this project is shown in theFigure 4.1, listed as Coordinate X10, Y10 and Z10 . Each row of these data respectivelyrepresents the X, Y and Z coordinate data used for this project.


234.3 Published MATLAB Simulation Image for BenchmarkingFigure 4.2 3D Image Recons<strong>tr</strong>uction of the Right A<strong>tr</strong>ium, 2048 Points [5]By using the MATLAB coding provided by Dr Anita [5], a 3D image asshown in Figure 4.2 was cons<strong>tr</strong>ucted. The image is made up of 2048 points. The 3Dimage is a spiral along 32 parallel lines from points to points stepping down to thenext parallel after one full turn, with a total of 64 meridian lines from point to point.However, the MATLAB image which will serve as the benchmark for this project isonly using 256 points and showed in Figure 4.3.


24Figure 4.3 3D Image Recons<strong>tr</strong>uction of the Right A<strong>tr</strong>ium, 256 Points [5]This MATLAB image will serve as a reference to the completed 3Drecons<strong>tr</strong>ucted image via LabVIEW. The 3D image recons<strong>tr</strong>ucted using LabVIEW isexpected to bear great resemblance to the 3D image recons<strong>tr</strong>ucted using MATLAB.


25CHAPTER 5LabVIEW PROGRAM DESIGN5.1 In<strong>tr</strong>oductionThis chapter will discuss the design of the program made to ex<strong>tr</strong>act thecoordinate data from the text file and its various processing functions in order tomake the data suitable for 3D image recons<strong>tr</strong>uction. The process and VirtualIns<strong>tr</strong>uments used to recons<strong>tr</strong>uct the 3D image will also be explained and discussedunder this section.5.2 Design OverviewFrom Figure 5.1 and 5.2, the overview of the design using LabVIEW can beseen. The design is too large and as such needed to be split into two parts.LabVIEW uses a graphic based programming, and thus the codes are in the form ofpictures.


26Figure 5.1Part A of the Overview of the Program DesignFigure 5.2Part B of the Overview of the Program Design


27The overall design is divided into four blocks:a) Data Ex<strong>tr</strong>actionb) Primary Data Processingc) Secondary Data Processingd) 3D Image Recons<strong>tr</strong>uctionFigure 5.1 shows the design for (a) Data Ex<strong>tr</strong>action of the coordinate dataand also the sorting of the data into X, Y and Z one-dimensional arrays done in (b)Primary Data Processing. The respective data is then passed to the Part B of thesystem in Figure 5.2 where each of the respective arrays undergoes (c) SecondaryData Processing before being passed to the (d) 3D Image Recons<strong>tr</strong>uction Block.5.3 Data Ex<strong>tr</strong>actionFigure 5.3Data Ex<strong>tr</strong>action BlockFigure 5.3 indicates the Data Ex<strong>tr</strong>action Block of the program. The blockconsists of a single Virtual Ins<strong>tr</strong>ument (VI), called “Read From Spreadsheet File.VI”.The VI will read the text file located on the computer and only ex<strong>tr</strong>act every “Double”value data, leaving out alphabets and other symbols present in the file, from everyrow of the text file, with every value separated by a coma “,”.


28The “,” symbol will indicate when one double value ends and another begins.The VI will continue to ex<strong>tr</strong>act double data from every row until there is no data left,before appending the ex<strong>tr</strong>acted data into a two-dimensional data array. However theVI still assumes an empty row as a “value” and as such rows that are empty will forman “empty array” in the array built.The sample of the text file which will be read by the program is shown inFigure 5.4. The text file begins with a few details about the data sampling processbefore the coordinate data is displayed after the “Begin Data” text. The coordinatedata for the respective X, Y and Z coordinates are indicated by the coloured brackets,with red indicating the X coordinates, green indicating the Y coordinates and finallyblue indicating the Z coordinates. All these data are actually arranged in a row, butdue to the limitations of the Notepad software, the coordinate data appears to beseparated into two rows.When the program starts, the coding in the Data Ex<strong>tr</strong>action Block will causeLabVIEW to prompt the user for the directory of the text file in the computer. Theuser has to locate the text file for the program to begin running, or else, an error willoccur explaining that the program needs to locate the text file in order to run.After the data has been ex<strong>tr</strong>acted by the Data Ex<strong>tr</strong>action Block, the array isthen passed to the Primary Data Processing Block for further process the raw arrayobtained.


29Figure 5.4Text File of Coordinate Data5.4 Primary Data ProcessingFigure 5.5Primary Data Processing Block


30Figure 5.5 shows the Primary Data Processing Block of the program. Here,the 2D array obtained from the Data Ex<strong>tr</strong>action Block of the program will beprocessed and separated into X, Y and Z one-dimensional arrays.Firstly, the program will test and see whether each row total of the 2D arrayis equal to zero. The purpose of this step is to check and eliminate empty rows as aresult of the two-dimensional array generated by the Data Ex<strong>tr</strong>action Block.The logic is governed via a “Case” command s<strong>tr</strong>ucture, and the case s<strong>tr</strong>uctureby the “For” loop. For every row, if the row total is equal to zero, the case will be“True” and the programming shown in Figure 5.6 occurs. The program will ignorethe row of data that is equal to 0 as it indicates that the row is empty. As such, therow will not be appended into a new array.Figure 5.6Program For Primary Data Processing Block When Case Is “True”When the row total is not equal to zero, then the following program inFigure 5.7 occurs.


31Figure 5.7Program For Primary Data Processing Block When Case Is “False”Referring to the Figure 5.7, when the row total is not equal to zero, the rowwill be appended into a new array via the “Build Array VI”. The new appended twodimensional array will be freed of empty rows and contain only numbers. Theprocess continues until all the rows have been read.After the new two-dimensional array is built, the array will be passed to a“Array Subset VI” which will read the data from the new array from the 4 th row asthe earlier rows contain junk data, and only the coordinate data is needed. The dataread is then passed to the “Index Array VI” which split each row of the twodimensional array into respective X, Y and Z one-dimensional arrays.The respective X, Y and Z arrays will then be passed to the Secondary DataProcessing block for further processing.


325.5 Secondary Data ProcessingFigure 5.8Secondary Data Processing BlockIn this block, the one-dimensional array representing the X, Y and Zcoordinate data will be further processed such that it is suitable for the imagerecons<strong>tr</strong>uction process as shown in Figure 5.8.The Secondary Data Processing block can be split into 2 parts:a) Array Reshapingb) Array Reprocessing


335.5.1 Array ReshapingFigure 5.9Array Reshaping Section of the Secondary Data Processing BlockAs showed in Figure 5.9, the X, Y and Z one-dimensional arrays will bereshaped into a 16X16 two-dimensional array.The original EnSite catheter probe sampled the 256 points coordinate data interms of a dimension based on 16 longitudinal lines and 16 latitudinal lines, thusgiving a total of 256 points in a 16X16 dimension. Therefore in order to recons<strong>tr</strong>uctthe right a<strong>tr</strong>ium, the array has to be reshaped into the dimension in which the datawas first sampled.


34The reshaped two dimensional arrays are then passed to Array Reprocessingsection of the Secondary Data Processing.5.5.2 Array ReprocessingFigure 5.10Array Reprocessing Section of the Secondary Data Processing BlockFigure 5.10 shows the Array Reprocessing Section of the Secondary Data ProcessingBlock. In this section, each two dimensional X, Y and Z arrays are further processedsuch that it is suitable for 3D recons<strong>tr</strong>uction. The respective arrays are processed by


35the (a) X-MOD, (b) Y-MOD and (c) Z-MOD sub VIs before passing the processedarray to the 3D Image Recons<strong>tr</strong>uction Block.5.5.2.1 X-MODFigure 5.11X-MOD Sub-VIThe reshaped two-dimensional array containing X coordinates is furtherprocessed as Figure 5.11. Zero values are inserted into the first and last column ofthe array, expanding the column dimension from 16 to 18 columns. The values ofthe first row are copied and a 17 th row is made from the values copied from the firs<strong>tr</strong>ow. Lastly, an 18 th row containing zero values is inserted into the array. The totaldimension of the two dimension array is now 18X18.The main reason for this is to form connecting points between the firstcolumn to the last column such that the 3D surface formed would be connected toone another. Another reason is to maintain an equal dimension between the rows andcolumns.


365.5.2.2 Y-MODFigure 5.12Y-MOD Sub-VISimilar to the X-MOD design, the reshaped two-dimensional array containingY coordinates is further processed in Y-MOD design as in Figure 5.12. Zero valuesare inserted into the first and last column of the array, expanding the columndimension from 16 to 18 columns. The values of the first row are copied and a 17 throw is made from the values copied from the first row. Lastly, an 18 th rowcontaining zero values is inserted into the array, bringing the dimension of the twodimension array to 18X18.The data processing in the Y- MOD is similar to the X –MOD sub VI withthe same purpose of forming connecting points between the first column to the lastcolumn such that the 3D surface formed would be connected to one another. Inaddition, like X-MOD, the Y-MOD would maintain an equal dimension between therows and columns.


375.5.2.3 Z-MODFigure 5.13Z-MOD Sub-VIThe design of the Z Sub VI is quite similar to the X and Y Sub VI howeverwith some minor tweaks. As shown in Figure 5.13, the first row will be copied and a17 th row will be formed from the data of the first row. However, in the first columnof the array, a value of 39.4 instead of zero value will be appended to the array. Avalue of -36.7 will be inserted to the 18 th column instead of zero value like X and YMOD Sub VI. Lastly an 18 th row containing zero value will be appended into thearray.The value of 39.4 and -36.7 are the maximum and minimum points obtainedfrom the Z- coordinate data. The reason for filling it is to help form a connectingsurface between the points. The 18 th row containing zero value is added so that an


38equal dimension of row and columns are obtained, and to act as a “buffer” for thesurface formed.5.6 3D Image Recons<strong>tr</strong>uctionFigure 5.143D Image Recons<strong>tr</strong>uction Block


39In this block, shown in Figure 5.14, array data obtained from primary tosecondary data processing will be used to form 3D images. There are 3 types of 3Dplots made in this block:a) 3D Scatter Plotb) 3D Parame<strong>tr</strong>ic Surface Plotc) 3D Surface Plot Via MathScript Node5.6.1 3D Scatter PlotFigure 5.153D Scatter Plot VIFigure 5.163D Image Scatter Plot


40Coordinate data is obtained from the X, Y and Z one-dimensional arrays thathas been processed by the Primary Data Processing block and then passed to the 3Dscatter plot VI shown in Figure 5.15. The 3D scatter plot will plot all 256 coordinatedata based on (X,Y,Z) vector coordinates on a 3D plot as shown in Figure 5.16.The purpose for the 3D scatter plot is to help assess whether the points havebeen ex<strong>tr</strong>acted and plotted properly and to give an overall view for the prototypedesign. The 3D scatter plot can easily be rotated and viewed in the front panel screen.The colours on the plot indicate the Z coordinate’s value with red being thehighest and as the value goes down, it will become darker until it becomes purple,indicating the minimum value.5.6.2 3D Parame<strong>tr</strong>ic Surface PlotFigure 5.173D Parame<strong>tr</strong>ic Surface Plot


41Using the array data obtained from Secondary Data Processing block, a 3Dparame<strong>tr</strong>ic surface plot shown in Figure 5.17 is made via the “3D Parame<strong>tr</strong>ic SurfaceVI” which consists of the plot helper and also the 3D Graph which will show thesurface formed on the front panel.The 3D image of the right a<strong>tr</strong>ium was successfully recons<strong>tr</strong>ucted however as theimage formed from this VI has limited user interface, another 3D image was plottedusing the MathScript Node.5.6.3 3D Surface Plot Via MathScript NodeMathScript node adds a math-oriented and textual style programminginterface to the LabVIEW’s graphical development environment with a nativecompiler for custom .m files. Therefore it can be said that MathScript node isLabVIEW’s equivalent of MATLAB based coding. However, as they are bothfundamentally different from one another, different commands have to be used for asimilar function.Figure 5.18MathScript Node Commands


42Figure 5.18 shows the code used in the MathScript node. The “surface”function which is LabVIEW’s equivalent of MATLAB’s “surf” function; plots a 3Dsurface based on the 2D arrays obtained from the Secondary Data Processing block,while using ActiveX con<strong>tr</strong>ols in the plotting process. As such, the plotting takesmuch more time than the 3D parame<strong>tr</strong>ic plot.The resultant image is better looking compared to the 3D parame<strong>tr</strong>ic plot andhas better user interface. The colour can be tweaked and the surface lines can beviewed. The resultant image is shown in Figure 5.19.Figure 5.193D Surface Made Via MathScript NodeThe colour on the image indicates the depth, with red being the largestpositive value and purple indicating the largest negative value.


43Surface lines and colours can be easily shown and tweaked via the userinterface console.As compared to the 3D image generated from the “Parama<strong>tr</strong>ic Surface Plot.VI”, the image generated by the MathScript Node has a greater quality and also has acon<strong>tr</strong>ol panel for us to interface with. The easy interface and the better generatedimage is the reason why images generated by the MathScript Node will be used tocompare with the image generated by MATLAB for benchmarking purposes.


44CHAPTER 6LabVIEW 3D IMAGE WITH MATLAB BENCHMARK6.1 In<strong>tr</strong>oductionThis chapter will compare and discuss the images generated from LabVIEWand the benchmark image made using MATLAB [5]. It will also show and justifythe need for the data processing and array editing done by X, Y and Z MOD sub VI.6.2 3D Image Benchmark and ComparisonFor the 3D image benchmark, the image generated by LabVIEW’sMathScript node shall be used to compare the image generated by MATLAB. Thisis because the 3D image generated by MathScript node has a better look and easier tocon<strong>tr</strong>ol and modify. Surface lines are also included in the LabVIEW image. Bothimages are generated from 256 points coordinate data.


45Figure 6.1Front View (A) of the 3D Image Generated By LabVIEWFigure 6.2 Front View (A) of the 3D Image Generated By MATLAB [5]


46Comparing Figure 6.1 and 6.2, it can see that both images are very muchsimilar to one another. Unique points and surface grooves present in the imagegenerated by MATLAB are also present in the image generated by LabVIEW.The differences between these two images are that the top of the axis of theimage generated by MATLAB is close with a cone, while LabVIEW’s image has agap in it. Although both coordinate data are the same or equivalent to one another,the differences might be due to how differently LabVIEW processes the coordinatedata compared to MATLAB, and thus resulting in these slight differences.Figure 6.3Front View (B) of the 3D Image Generated By LabVIEW


47Figure 6.4 Front View (B) of the 3D Image Generated By MATLAB [5]Again, comparing Figure 6.3 and 6.4, note that both images are quite similarto one another with only minor differences. They both have similar shapes, and if wewere to compare their surface lines, we would see that the surface lines are similar toone another. Unique points and curves present in Figure 6.3 are also present inFigure 6.4.Therefore, the frontal view of the 3D image generated by LabVIEW issuccessful as the LabVIEW image generated is almost similar to the MATLABimage with only minor differences.


48Figure 6.5Left Side View of the 3D Image Generated By LabVIEWFigure 6.6 Left Side View of the 3D Image Generated By MATLAB [5]


49Comparing Figure 6.5 to Figure 6.6, it can be seen that both 3D images arevery similar to each other with almost no noticeable differences. Both images havethe same unique points and grooves at the surfaces. They also have the same shapeand the surface lines look very similar to each other.Thus, the left side view of the 3D image is a success.Figure 6.7Right Side View of the 3D Image Generated By LabVIEW


50Figure 6.8 Right Side View of the 3D Image Generated By MATLAB [5]Looking at Figure 6.7 and Figure 6.8, both 3D images are very similar to eachother with some differences. Both images have the same unique points and groovesat the surfaces and also have the same shape and the surface lines.However, at the top of the axis it can see that the LabVIEW image has a gapbut the MATLAB image is sealed. As discussed earlier, the differences might be dueto the different way LabVIEW process the data compared to MATLAB.As the differences are minor and the surface formed is almost similar to eachother, thus the right side view of the 3D image is a success.Overall, the benchmark shows that the 3D image generated by LabVIEW issimilar to the image generated by MATLAB with only small differences. Also notethat gaps are present in the image generated by LabVIEW even though the array data


51used is similar to the array data used in MATLAB. In <strong>tr</strong>uth, the gap can be fixedeasily, however in order to show how differently the two software interpret theirarray data, it was decided that the image should be left the way it is.6.3 Comparing Initial and Final ImageIn the Secondary Data Processing block, although a 3D image can becons<strong>tr</strong>ucted directly with the array data obtained immediately after the reshapingprocess, the array has to undergo further processing by their respective MOD X, Yand Z sub VIs. The reason for so is to form a connecting point between the surfaces.In LabVIEW, the surface generated is like a single piece of paper folded intoa shape. If there are no points connecting one end to the other end of the paper, a gapis formed. Therefore it is important for us to form a connecting surface such that theimage form looks more like a single 3D surface and giving off the illusion of a 3Dobject.Figure 6.9 shows the back view of the 3D image generated without goingthrough further processing while Figure 6.10 shows the back view of the 3D imagegenerated after going through further processing.


52Figure 6.9Back View of 3D Image Without X, Y and Z MOD Sub VIFigure 6.10Back View of 3D Image With X, Y and Z MOD Sub VI


53In Figure 6.9, note can see a gap in the 3D image. The gap will give peoplethe impression that the image is of a surface instead of a 3D object. To give peoplethe impression that the object is a 3D object, the array data is modified so that thedata contains “connecting points” between the first and last columns and rows. Thusthe surface will connect to one another like in Figure 6.10.Although the gap still exists, it is “sealed” thanks to the connecting pointsmade with X, Y and Z MOD sub VI. Note that the surface formed isn’t affected bythe process, and it provides a better cosmetic look to the 3D image generated.


54CHAPTER 7CONCLUSION & RECCOMENDATIONS ON FUTURE WORKS7.1 In<strong>tr</strong>oductionThis chapter will conclude the overall of the project and give out recommendationson future works and further improvements that could be done.7.2 ConclusionThe project has accomplished all of its objectives, which are to develop a programcapable of recons<strong>tr</strong>ucting a 3D image of the right a<strong>tr</strong>ium of the human heart,exploring the potential of LabVIEW software in heart image recons<strong>tr</strong>uction andvalidate the recons<strong>tr</strong>ucted image using LabVIEW, to the image recons<strong>tr</strong>ucted usingMATLABThe program has successfully recons<strong>tr</strong>ucted the 3D image of the right a<strong>tr</strong>ium ofthe human heart via LabVIEW from 256 points vector XYZ vector coordinates. TheLabVIEW software was found to be a highly potential tool in human heart image


55recons<strong>tr</strong>uction on par with MATLAB. Lastly, the image cons<strong>tr</strong>ucted by LabVIEW issimilar to the image cons<strong>tr</strong>ucted by MATLAB software with only some minordifferences.Compared to the image generated by MATLAB, the image generated byLabVIEW has a small hole on the top of the axis of the 3D image, and a gap in therear view. This is due to how differently LabVIEW cons<strong>tr</strong>ucts the image from thecoordinate data compared to MATLAB software, and thus causing the differenceseven though the array data fed into the program are similar. However the shape,s<strong>tr</strong>ucture and unique points on the 3D image were similar to one another with almostno major differences except for the existence of some gaps in the image.7.3 Recommended ImprovementsThere are a few recommendations that I think will help to improve thisproject. First of all, it is suggested to increase the image resolution by using a 2048data source file which will give us a 2D array of 32X64 dimensions. By increasingthe resolution, the image will be much more detailed, and certain curves and uniquepoints that did not appear in the 256 points 3D image might be present in the 2048points 3D image.Secondly, the gaps in the 3D image generated by LabVIEW should be filledand fixed. Although in this project the gaps were not fixed in order to compare howdifferently these two software cons<strong>tr</strong>uct their 3D image, however in lieu of perfectingthe image, such action is deemed necessary.


56Lastly, the Primary and Secondary Data Processing blocks should be brokendown and simplified into smaller blocks and the coding broken down so that thedesign can be fitted into an FPGA embedded system.7.4 Recommendations on Future WorksThere are a few recommendations that can be made for future works based onthis system. Firstly, it is suggested to analyse the sin-wave signals of the humanheart so that the damaged tissue in the a<strong>tr</strong>ium will be highlighted on the 3D image.Secondly, the design of the project can be integrated onto an FPGA boardmade by National Ins<strong>tr</strong>uments due to their compatibility of the design environment.The FPGA will serve as a hub for the sensors and will receive the signals from theprobes directly and process them in real time; producing a 3D real time image of theright a<strong>tr</strong>ium.


57REFERENCES1. K.-H. Mak, K.-S. Chia, J.D.Kark, T.Chua,C.Tan,B.-H.Foong,Y.-L Lim, S.-K.Chew.Ethnic Differences In Acute Myocardial Infarction In Singapore.European Heart Journal. 2003, 24:151-169.2. Isabelle Lai. (2012, September 21).Heart Disease Is The Number One KillerAmong Women. The Star, Re<strong>tr</strong>ieved 23 March 2013, fromhttp://www.thestar.com.my.3. Georgios Sakas. Trends In Medical Imaging: From 2D to 3D.Computers &Graphics.2002, 26: 577-587.4. Jianchun Li, Christos Papachristou and Raj Shekhar. An FPGA-basedComputing Platform for Real-time 3D Medical Imaging and its Applicationto Cone-beam CT Recons<strong>tr</strong>uction. Ph.D. thesis. University of Maryland.5. Ahmad.A (2012). Adaptive Power Threshold for Dominant FrequencyEstimation in A<strong>tr</strong>ial Fibrillation. Ph.D, University of Leicester, UK.6. Tortora,G.j and Derrickson, B.H. (2009). Principles of Anatomy andPhysiology. John Wiley and Sons, Inc.7. Nikhil Subramanian (2009). A C-to-FPGA Solution for AcceleratingTomographic Recons<strong>tr</strong>uction. Master of Science In Elec<strong>tr</strong>ical Engineering,University of Washington, Washington.8. Dr Kohji Ohbayashi, D.Choi, H.Hiro-Oka, A.Kubota, T.Ohno, R.Ikeda,K.Shimizu. Developing the World’s First Real-Time 3D OCT MedicalImaging System With LabVIEW and NI FlexRio, National Ins<strong>tr</strong>uments CaseStudy, Re<strong>tr</strong>ieved 20 April 2013, from www.ni.com.9. Yang Ding, Bin Sun, Yongmei Huang, Weiwei Lin and Fei Qian (2010).Hybrid MATLAB and LABVIEW to Implement an Intelligent FoundationFieldbus Con<strong>tr</strong>ol System. Intelligent Con<strong>tr</strong>ol and Automation (WCICA) 20108 th World Congress.7-9 July. Jinan, 4539 - 4543.


5810. Singh.P, Singh.C and Singh R.R (2011). LabVIEW-based Cost EffectiveMulti-Axis Motion Con<strong>tr</strong>ol System. India Conference (INDICON) 2011Annual IEEE. 16-18 December. Hyderabad, 1 – 5.11. Xiang Xuejun, Xia Ping, Yang Sheng and Liu Ping (2007). Real-time DigitalSimulation of Con<strong>tr</strong>ol System with LabVIEW Simulation Interface Toolkit.Con<strong>tr</strong>ol Conference, CCC 2007. June 26 – July 31. Hunan, 318 – 322.12. Li.Ce, Zhou. Yannan, Ouyang. Chengsu and Tian. Lihua (2012). X-ray ImageEnhnancement Based on Fuzzy Sure En<strong>tr</strong>opy in LabVIEW. BiomedicalEngineering and Informatics 5 th International Conference. 16 – 18 October.Chongqing, China, 395-398.13. Wuni Xu, Zhong Lanxiang and Dingyuan Wang (2010). Image ProcessingBased on Seamless Integration Technology Between LabVIEW andMATLAB. Information Networking and Automation (ICINA) 2010International Conference. 18-19 October. Kunming, V1-219 – V1-223.


59APPENDIX AX-Array Before and After ProcessingX- Array Before Processed by MOD X


X- Array After Processed by MOD X60


61APPENDIX BGantt ChartGantt Chart For FYP 1


Gantt Chart For FYP 262


63APPENDIX CThe Star Article Ex<strong>tr</strong>act[2]The Star Online > NationFriday September 21, 2012Heart disease is number one killer among womenBy ISABELLE LAIisabellelai@thestar.com.myKUALA LUMPUR: Heart disease is the number one killer among Malaysian womenand is two and a half times as common than dying from all cancers combined,warned the National Heart Association of Malaysia.Its president Datuk Dr Azhari Rosman dispelled the common perception that onlyolder men were prone to heart diseases and s<strong>tr</strong>okes.“Women must maintain a high index of suspicion,” he said here yesterday.“Cancer does not take as many lives as cardiovascular diseases. Women also tend todismiss pain more easily than men and generally have a higher pain threshold.”Dr Azhari said the latest 2011 National Health and Morbidity Survey (NHMS IV)had revealed some alarming statistics, including the fact that Malaysian women hadthe highest body mass index (BMI) in the South-East Asian region.“Obesity is the harbinger of many conditions,” he said. “The NHMS IV study reportsthat out of 17,000 women surveyed, 29.4% were overweight while 15% were obese.”Dr Azhari, a consultant cardiologist at the National Heart Institute, said thatMalaysian women also had one of the highest prevalence of hypertension in South-East Asia, even more than men.He said women also formed a 60% majority of Malaysians who had elevated totalcholesterol levels, another factor that con<strong>tr</strong>ibuted to heart disease.Dr Azhari said that data also showed that most Malaysians were admitted to thehospital for Acute Coronary Syndrome around the age of 59 years.“This is seven years below the average in other coun<strong>tr</strong>ies which is around 66 years.“We have also <strong>tr</strong>eated a 19-year-old for heart disease and done a heart bypass on a21-year-old,” he revealed.Dr Azhari s<strong>tr</strong>essed that creating awareness among the public was critical as heartdisease was “completely preventable” if detected early.


64To this end, he said the Women's Heart Health Organisation (WH2O) was created toeducate the public and healthcare providers that women were susceptible to heartdiseases and s<strong>tr</strong>okes too.In line with National Heart Day on Sept 29, NHAM, in collaboration with theMalaysian Heart Foundation, has organised a “Walk A Mile” activity at Taman TasikTitiwangsa on Sept 30.They will also have other physical activities and health screenings.For details on other activities planned in the next few weeks, visitwww.malaysianheart.org© 1995-2013 Star Publications (Malaysia) Bhd (Co No 10894-D)

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!