SlideShare a Scribd company logo
1 of 21
Dr.(Mrs.) Anjali Potnis
NITTTR,Bhopal
Loop Concept and Array
Session Objective
 Concept of Loops in programing
 Array building and Array operations
 Programming practices using Loop structures.
STRUCTURES
 Structures control the flow of data in a VI.
LabVIEW has four
structures:
 While Loop,
 For Loop,
 Case structure,
 Sequence structure.
Repetition and Loops
• Loops and case statements of text- based
programming are represented as structures in G-
programming.
• For Loop
• While Loop
Other examples of structures are
Case structure, Stacked sequence structure
,Flat sequence structure, Event structure ,
Formula node
Loops
 While Loops
 Have Iteration Terminal
 Always Run Once
 Run According to Continue
Terminal
• For Loops
– Have Iteration Terminal
– Run According to input N count
terminal
While Loop
Three different ways of using a while-loop. The first loop continues forever
because the loop conditional never becomes false. The second loop
continues until a button on the front panel is pressed, sending a value of
true to the loop conditional thereby stopping the loop. The third loop also
continues forever, but also displays the current loop counter value in an
indicator on the front panel. (It is important to note that these three loops
will execute in parallel because their inputs are not dependent on each
other)
Iteration
Terminal
Conditional
Terminal
Loops (cont.)
1. Select the loop 2. Enclose code to be repeated
3. Drop or drag additional nodes and then wire
Use of Structures
 Functions>>programming>>structure palette
from here we can select the For loop or While
For Loop can convert in to While Loop by right
clicking on the boundary of the for loop.
Loops (cont.)
1. Select the loop 2. Enclose code to be repeated
3. Drop or drag additional nodes and then wire
Shift Register and other control on the
loop block diagram
Control Timing of Loop Functions
Arrays
 Array and its Dimension ,Indexing (0 to n-1)
(Length, height ,depth)
 Build arrays manually
 Have LabVIEW build arrays automatically
 Maximun231 – 1 elements per dimension,
memory permitting.
Adding an Array to the Front Panel
From the Controls >> All Controls >> Array and
Cluster subpalette, select the Array Shell
Drop it on the screen.
Adding an Array (cont.)
Place data object into shell (i.e. Numeric Control)
Creating an Array with a Loop
 Loops accumulate arrays at their boundaries
Creating 2D Arrays
 Thanks

More Related Content

Similar to Loop Concept and Array.ppt

Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...
Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...
Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...IJRES Journal
 
Chapter 3 - Flow of Control Part II.pdf
Chapter 3  - Flow of Control Part II.pdfChapter 3  - Flow of Control Part II.pdf
Chapter 3 - Flow of Control Part II.pdfKirubelWondwoson1
 
Software Verification, Validation and Testing
Software Verification, Validation and TestingSoftware Verification, Validation and Testing
Software Verification, Validation and TestingDr Sukhpal Singh Gill
 
Lab7: More Arrays, Strings, Vectors, and Pointers
Lab7: More Arrays, Strings, Vectors, and PointersLab7: More Arrays, Strings, Vectors, and Pointers
Lab7: More Arrays, Strings, Vectors, and Pointersenidcruz
 
Mobile Networking and Mobile Ad Hoc Routing Protocol Modeling
Mobile Networking and Mobile Ad Hoc Routing Protocol ModelingMobile Networking and Mobile Ad Hoc Routing Protocol Modeling
Mobile Networking and Mobile Ad Hoc Routing Protocol ModelingIOSR Journals
 
Simulation analysis of single server queuing model
Simulation  analysis of single server queuing modelSimulation  analysis of single server queuing model
Simulation analysis of single server queuing modelijitjournal
 
Introduction to flowchart
Introduction to flowchartIntroduction to flowchart
Introduction to flowchartJordan Delacruz
 
Pipelining in Computer System Achitecture
Pipelining in Computer System AchitecturePipelining in Computer System Achitecture
Pipelining in Computer System AchitectureYashiUpadhyay3
 
A General Framework for Electronic Circuit Verification
A General Framework for Electronic Circuit VerificationA General Framework for Electronic Circuit Verification
A General Framework for Electronic Circuit VerificationIRJET Journal
 
Developing a Humanoid Robot Platform
Developing a Humanoid Robot PlatformDeveloping a Humanoid Robot Platform
Developing a Humanoid Robot PlatformDr. Amarjeet Singh
 
Instrumentation and measurements
Instrumentation and measurementsInstrumentation and measurements
Instrumentation and measurementsTuba Tanveer
 
Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...eSAT Journals
 
Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...eSAT Publishing House
 

Similar to Loop Concept and Array.ppt (20)

Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...
Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...
Application Of The Three-In-One Control Platform Based On OPC In The Lifting-...
 
Chapter 3 - Flow of Control Part II.pdf
Chapter 3  - Flow of Control Part II.pdfChapter 3  - Flow of Control Part II.pdf
Chapter 3 - Flow of Control Part II.pdf
 
Software Verification, Validation and Testing
Software Verification, Validation and TestingSoftware Verification, Validation and Testing
Software Verification, Validation and Testing
 
Lab7: More Arrays, Strings, Vectors, and Pointers
Lab7: More Arrays, Strings, Vectors, and PointersLab7: More Arrays, Strings, Vectors, and Pointers
Lab7: More Arrays, Strings, Vectors, and Pointers
 
Mobile Networking and Mobile Ad Hoc Routing Protocol Modeling
Mobile Networking and Mobile Ad Hoc Routing Protocol ModelingMobile Networking and Mobile Ad Hoc Routing Protocol Modeling
Mobile Networking and Mobile Ad Hoc Routing Protocol Modeling
 
E0463137
E0463137E0463137
E0463137
 
1.My Presentation.pptx
1.My Presentation.pptx1.My Presentation.pptx
1.My Presentation.pptx
 
Simulation analysis of single server queuing model
Simulation  analysis of single server queuing modelSimulation  analysis of single server queuing model
Simulation analysis of single server queuing model
 
ch5.ppt
ch5.pptch5.ppt
ch5.ppt
 
Introduction to flowchart
Introduction to flowchartIntroduction to flowchart
Introduction to flowchart
 
Lect 3-4 Zaheer Abbas
Lect 3-4 Zaheer AbbasLect 3-4 Zaheer Abbas
Lect 3-4 Zaheer Abbas
 
Chap05
Chap05Chap05
Chap05
 
Pipelining in Computer System Achitecture
Pipelining in Computer System AchitecturePipelining in Computer System Achitecture
Pipelining in Computer System Achitecture
 
A General Framework for Electronic Circuit Verification
A General Framework for Electronic Circuit VerificationA General Framework for Electronic Circuit Verification
A General Framework for Electronic Circuit Verification
 
Developing a Humanoid Robot Platform
Developing a Humanoid Robot PlatformDeveloping a Humanoid Robot Platform
Developing a Humanoid Robot Platform
 
Instrumentation and measurements
Instrumentation and measurementsInstrumentation and measurements
Instrumentation and measurements
 
Ppt chapter04
Ppt chapter04Ppt chapter04
Ppt chapter04
 
Pptchapter04
Pptchapter04Pptchapter04
Pptchapter04
 
Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...
 
Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...Available transfer capability computations in the indian southern e.h.v power...
Available transfer capability computations in the indian southern e.h.v power...
 

More from AvinashJain66

Graphs and waveforms.ppt
Graphs and waveforms.pptGraphs and waveforms.ppt
Graphs and waveforms.pptAvinashJain66
 
Image processing tool box.pptx
Image processing tool box.pptxImage processing tool box.pptx
Image processing tool box.pptxAvinashJain66
 
Looping concept.pptx
Looping concept.pptxLooping concept.pptx
Looping concept.pptxAvinashJain66
 
Virtual Instrumentation & LabVIEW-lini.ppt
Virtual Instrumentation & LabVIEW-lini.pptVirtual Instrumentation & LabVIEW-lini.ppt
Virtual Instrumentation & LabVIEW-lini.pptAvinashJain66
 
PIC18F458_Ritula Thakur.pptx.pdf
PIC18F458_Ritula Thakur.pptx.pdfPIC18F458_Ritula Thakur.pptx.pdf
PIC18F458_Ritula Thakur.pptx.pdfAvinashJain66
 
Introduction_PIC18F458_Ritula Thakur.pptx
Introduction_PIC18F458_Ritula Thakur.pptxIntroduction_PIC18F458_Ritula Thakur.pptx
Introduction_PIC18F458_Ritula Thakur.pptxAvinashJain66
 
Lecture-6-PIC Programming in C-good.pdf
Lecture-6-PIC Programming in C-good.pdfLecture-6-PIC Programming in C-good.pdf
Lecture-6-PIC Programming in C-good.pdfAvinashJain66
 

More from AvinashJain66 (9)

FACTS.pdf
FACTS.pdfFACTS.pdf
FACTS.pdf
 
Graphs and waveforms.ppt
Graphs and waveforms.pptGraphs and waveforms.ppt
Graphs and waveforms.ppt
 
Image processing tool box.pptx
Image processing tool box.pptxImage processing tool box.pptx
Image processing tool box.pptx
 
Looping concept.pptx
Looping concept.pptxLooping concept.pptx
Looping concept.pptx
 
Virtual Instrumentation & LabVIEW-lini.ppt
Virtual Instrumentation & LabVIEW-lini.pptVirtual Instrumentation & LabVIEW-lini.ppt
Virtual Instrumentation & LabVIEW-lini.ppt
 
PIC18F458_Ritula Thakur.pptx.pdf
PIC18F458_Ritula Thakur.pptx.pdfPIC18F458_Ritula Thakur.pptx.pdf
PIC18F458_Ritula Thakur.pptx.pdf
 
Introduction_PIC18F458_Ritula Thakur.pptx
Introduction_PIC18F458_Ritula Thakur.pptxIntroduction_PIC18F458_Ritula Thakur.pptx
Introduction_PIC18F458_Ritula Thakur.pptx
 
Lecture-6-PIC Programming in C-good.pdf
Lecture-6-PIC Programming in C-good.pdfLecture-6-PIC Programming in C-good.pdf
Lecture-6-PIC Programming in C-good.pdf
 
Relay-ppt.pptx
Relay-ppt.pptxRelay-ppt.pptx
Relay-ppt.pptx
 

Recently uploaded

GA4 Without Cookies [Measure Camp AMS]
GA4 Without Cookies [Measure Camp AMS]GA4 Without Cookies [Measure Camp AMS]
GA4 Without Cookies [Measure Camp AMS]📊 Markus Baersch
 
9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home Service9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home ServiceSapana Sha
 
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptxEMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptxthyngster
 
From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...Florian Roscheck
 
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...soniya singh
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130Suhani Kapoor
 
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024thyngster
 
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Sapana Sha
 
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)jennyeacort
 
Brighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingBrighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingNeil Barnes
 
04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationshipsccctableauusergroup
 
Call Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts ServiceCall Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts ServiceSapana Sha
 
Customer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptxCustomer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptxEmmanuel Dauda
 
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一F sss
 
办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一
办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一
办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一F La
 
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Bookvip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Bookmanojkuma9823
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxStephen266013
 
Call Girls In Mahipalpur O9654467111 Escorts Service
Call Girls In Mahipalpur O9654467111  Escorts ServiceCall Girls In Mahipalpur O9654467111  Escorts Service
Call Girls In Mahipalpur O9654467111 Escorts ServiceSapana Sha
 
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Jack DiGiovanna
 
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Callshivangimorya083
 

Recently uploaded (20)

GA4 Without Cookies [Measure Camp AMS]
GA4 Without Cookies [Measure Camp AMS]GA4 Without Cookies [Measure Camp AMS]
GA4 Without Cookies [Measure Camp AMS]
 
9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home Service9654467111 Call Girls In Munirka Hotel And Home Service
9654467111 Call Girls In Munirka Hotel And Home Service
 
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptxEMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM  TRACKING WITH GOOGLE ANALYTICS.pptx
EMERCE - 2024 - AMSTERDAM - CROSS-PLATFORM TRACKING WITH GOOGLE ANALYTICS.pptx
 
From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...From idea to production in a day – Leveraging Azure ML and Streamlit to build...
From idea to production in a day – Leveraging Azure ML and Streamlit to build...
 
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
High Class Call Girls Noida Sector 39 Aarushi 🔝8264348440🔝 Independent Escort...
 
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
VIP Call Girls Service Miyapur Hyderabad Call +91-8250192130
 
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
Consent & Privacy Signals on Google *Pixels* - MeasureCamp Amsterdam 2024
 
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
Saket, (-DELHI )+91-9654467111-(=)CHEAP Call Girls in Escorts Service Saket C...
 
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
Call Us ➥97111√47426🤳Call Girls in Aerocity (Delhi NCR)
 
Brighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data StorytellingBrighton SEO | April 2024 | Data Storytelling
Brighton SEO | April 2024 | Data Storytelling
 
04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships04242024_CCC TUG_Joins and Relationships
04242024_CCC TUG_Joins and Relationships
 
Call Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts ServiceCall Girls In Dwarka 9654467111 Escorts Service
Call Girls In Dwarka 9654467111 Escorts Service
 
Customer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptxCustomer Service Analytics - Make Sense of All Your Data.pptx
Customer Service Analytics - Make Sense of All Your Data.pptx
 
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
办理学位证中佛罗里达大学毕业证,UCF成绩单原版一比一
 
办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一
办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一
办理(Vancouver毕业证书)加拿大温哥华岛大学毕业证成绩单原版一比一
 
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Bookvip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
vip Sarai Rohilla Call Girls 9999965857 Call or WhatsApp Now Book
 
B2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docxB2 Creative Industry Response Evaluation.docx
B2 Creative Industry Response Evaluation.docx
 
Call Girls In Mahipalpur O9654467111 Escorts Service
Call Girls In Mahipalpur O9654467111  Escorts ServiceCall Girls In Mahipalpur O9654467111  Escorts Service
Call Girls In Mahipalpur O9654467111 Escorts Service
 
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
Building on a FAIRly Strong Foundation to Connect Academic Research to Transl...
 
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
꧁❤ Greater Noida Call Girls Delhi ❤꧂ 9711199171 ☎️ Hard And Sexy Vip Call
 

Loop Concept and Array.ppt

  • 2. Session Objective  Concept of Loops in programing  Array building and Array operations  Programming practices using Loop structures.
  • 3. STRUCTURES  Structures control the flow of data in a VI. LabVIEW has four structures:  While Loop,  For Loop,  Case structure,  Sequence structure.
  • 4. Repetition and Loops • Loops and case statements of text- based programming are represented as structures in G- programming. • For Loop • While Loop Other examples of structures are Case structure, Stacked sequence structure ,Flat sequence structure, Event structure , Formula node
  • 5. Loops  While Loops  Have Iteration Terminal  Always Run Once  Run According to Continue Terminal • For Loops – Have Iteration Terminal – Run According to input N count terminal
  • 6. While Loop Three different ways of using a while-loop. The first loop continues forever because the loop conditional never becomes false. The second loop continues until a button on the front panel is pressed, sending a value of true to the loop conditional thereby stopping the loop. The third loop also continues forever, but also displays the current loop counter value in an indicator on the front panel. (It is important to note that these three loops will execute in parallel because their inputs are not dependent on each other) Iteration Terminal Conditional Terminal
  • 7.
  • 8. Loops (cont.) 1. Select the loop 2. Enclose code to be repeated 3. Drop or drag additional nodes and then wire
  • 9. Use of Structures  Functions>>programming>>structure palette from here we can select the For loop or While For Loop can convert in to While Loop by right clicking on the boundary of the for loop.
  • 10. Loops (cont.) 1. Select the loop 2. Enclose code to be repeated 3. Drop or drag additional nodes and then wire
  • 11. Shift Register and other control on the loop block diagram
  • 12. Control Timing of Loop Functions
  • 13.
  • 14. Arrays  Array and its Dimension ,Indexing (0 to n-1) (Length, height ,depth)  Build arrays manually  Have LabVIEW build arrays automatically  Maximun231 – 1 elements per dimension, memory permitting.
  • 15.
  • 16. Adding an Array to the Front Panel From the Controls >> All Controls >> Array and Cluster subpalette, select the Array Shell Drop it on the screen.
  • 17. Adding an Array (cont.) Place data object into shell (i.e. Numeric Control)
  • 18. Creating an Array with a Loop  Loops accumulate arrays at their boundaries
  • 19.