Advantages of Using LabVIEW in Academic Research

Publish Date: Feb 01, 2012 | 14 Ratings | 4.14 out of 5 | Print


Scientists and researchers around the world have applied LabVIEW and National Instruments products successfully for research and development (R&D) in academia. This paper considers some of the advantages of applying the National Instruments platform, including LabVIEW, to build virtual instrumentation and take an effective graphical system design approach that can effectively leverage the opportunities and take on the challenges of modern academic research and development.

Table of Contents

  1. Opportunities and Challenges of Modern Academic Research
  2. Virtual Instrumentation
  3. Graphical System Design in Academic Research
  4. Benefits of Graphical System Design and LabVIEW for Research
  5. Designing and Developing Large, Complex Scientific Instruments
  6. LabVIEW for Experimental Research and Scientific Computing
  7. Data Acquisition
  8. Signal Processing and Analysis
  9. Data Visualization
  10. Connecting External Tools to LabVIEW
  11. Benefits of Using LabVIEW in Scientific Research
  12. Additional Resources

1. Opportunities and Challenges of Modern Academic Research

Academic research and development usually encompasses discovery, innovation, experimentation, and creation; however, in today’s highly competitive and global economy, it also involves patents, licensing, technology transfer, and partnerships with industry. In other words, it is about creating “new knowledge” and building “new bridges” with industry while having a positive impact on the community and society in general. Due to the convergence of technologies and science, multidisciplinary research is required. This means that hardware and software tools must be adaptable to different disciplines. As technology evolves quickly, laboratories must be updated periodically as well as be able to extend the useful life of current and legacy equipment and software. New research may require custom instruments and application programs (software) that are not readily available on the market to be built using commercial off-the-shelf (COTS) technologies.

Scientific research is also evolving. Traditionally, basic scientific principles have posed questions that can be investigated empirically (and experimentally), so that a scientific hypothesis can be viable. The scientific method is commonly built around testable hypotheses for which models (conceptual and theoretical) are developed, and then tested through experiments (and tests).

Figure 1

Figure 1. A common approach to scientific research works to prove an initial hypothesis; models are developed and confirmed with experimental results.

This hypothesize, model, and experiment approach to scientific research complements a new method in which large data sets that are created from a variety of measurements coming from sensors and data acquisition systems are modeled, analyzed, and mined to “discover” knowledge. In this new approach, models and patterns are identified in the data using analysis and data mining techniques; the goal is to “find knowledge” and meaningful information in those large sets of data, leading to new scientific discovery and innovation. This process that starts with measurements and ends with new designs is defined as “designing with measurements.”

Figure 2

Figure 2. With the “designing with measurements” approach to research, sensors and other sources of live signals provide the basis for new discoveries.

Back to Top

2. Virtual Instrumentation

Virtual instrumentation is the combination of user-defined software and modular hardware that implements custom systems (“virtual instruments”) with components for acquisition, processing/analysis and presentation. Virtual instruments commonly leverage mainstream technologies, platforms, and standards such as the PC, Ethernet, GPIB, USB, IEEE 1394, PCI, PCI Express and others. Virtual instrumentation combines such technology with an application-specific selection of modular hardware for signal I/O, instrument control, connectivity and other tasks.

Virtual instrumentation software is user defined and focused on the needs of the application. For instance, researchers can build custom virtual instruments that can apply real-time mathematics for processing, analysis, and control involving online (live) and/or offline (from a file / database) signal I/O. Using the virtual instrumentation approach, applied mathematics is combined with real-time measurements, which helps researchers reduce the time to discovery and, potentially, the time to market and/or time to commercialization of potential products and services that result from research and development (R&D).

Figure 3

Figure 3. Virtual instrumentation includes components for data acquisition (signal I/O), analysis, and presentation.

National Instruments introduced the concept of virtual instrumentation more than 25 years ago and now offers an extensive platform of hardware and software for creating virtual instruments. Since its inception, the virtual instrumentation approach has gained widespread acceptance around the world. For instance, in 2004 National Instruments sold more than 6 million channels of virtual instrumentation in 90 countries. Working with the National Instruments platform, scientists and engineers have employed the virtual instrumentation approach successfully in both industry and academia. The approach is popular in experimental research, finding use in applications such as big physics, automotive, biomedical, communications, consumer electronics, energy, and many others.

Back to Top

3. Graphical System Design in Academic Research

One key element behind the success of the virtual instrumentation approach is LabVIEW, a software development tool originally developed to support the requirements of virtual instrumentation. Researchers can use LabVIEW to design (modeling and simulation), prototype (proof of concept), and deploy (field implementation) new technologies that result from R&D activities. Researchers can implement these activities with a highly interactive process known as graphical system design, an approach that leverages virtual instrumentation (modular, customizable, software-defined instrumentation).

Figure 4

Figure 4. The graphical system design approach addresses activities related to design, prototyping, and deployment. 

The graphical system design approach can improve the productivity of experimental research. To understand how, consider that researchers often have hundreds or thousands of measurements that they use to “feed” their mathematical models. Often, researchers implement data analysis, data visualization, and data mining tasks offline (post processing) using different software tools. High-performance computing (HPC) platforms (clusters, grid computers) and terabyte-/petabyte-sized storage servers are typically used for applications involving large models and data sets. This process can take several hours or even days while models are solved and results are obtained. In most cases, a coarse resolution is used because researchers cannot easily adjust models rapidly to changes or variations, predict results faster, or fine-tune (optimize) their processes due to the limitations or level of complexity of the technologies and tools used.

Researchers can complement and enhance this type of work by taking the graphical system design approach and using tightly integrated software and hardware tools that help them combine data analysis, mining, and visualization with measurements (data acquisition). Some potential benefits include:

  • Reduced time to discovery – get results faster
  • Reduced time to prototype – create a functional prototype in less time
  • Reduced time to market – productize an idea in less time
  • Smoother technology transfer process – use the same tools as industry to help achieve a smoother and more efficient technology transfer process
  • Protection of intellectual property – using embedded, field-programmable gate array (FPGA)-based technology
  • Multidisciplinary development – encourage researchers from different disciplines to contribute to the project using the same development tools
  • Improved simulations – achieve better/faster prototyping, hardware-in-the-loop (HIL) simulations, and proofs of concept (POCs)

Back to Top

4. Benefits of Graphical System Design and LabVIEW for Research

One key benefit of the graphical system design approach is that researchers can use the same technology in the final phase of experimental development, the deployment phase. This phase is mostly related to industry, and, with graphical system design, researchers can easily transfer the technology to market because the same tools and platforms are used in both the research/development phase in the academic environment (labs and research centers at university campuses) and the deployment phase (industry).

Another key benefit of graphical system design with LabVIEW is that it offers easy and seamless integration with legacy and traditional benchtop, stand-alone instruments commonly found in research labs. Most research laboratories still have access to a wide variety of legacy, traditional, or specialized benchtop / rack-mounted instruments (signal generators, gas chromatographs, network analyzers, and so on) that researchers can easily integrate into a virtual instrumentation system. Most of those instruments have one or more serial/parallel communication ports readily available (RS232, RS485, RS422, GPIB, and so on). Most recent instruments may also include an Ethernet and/or USB ports. Researchers can use these digital communication ports as an interface to LabVIEW (drivers are provided at at no cost). Also, some of those instruments may have digital or analog outputs. For example, most legacy gas chromatographs have an analog output that can be used as the input for a virtual integrator implemented in LabVIEW. Researchers also can easily integrate legacy CAMAC and VME-based instruments into a virtual instrumentation system or replace them by using LabVIEW and the appropriate hardware interfaces.

Back to Top

5. Designing and Developing Large, Complex Scientific Instruments

Academic researchers require tools to design and develop new, high-channel-count, high-performance scientific systems that abstract intrinsic hardware complexities and low-level programming so they can focus on the algorithms rather than on system details. Examples of these large, complex systems include the following:

  • Magnetic resonance imaging (MRI) and nuclear magnetic resonance (NMR)
  • Digital, computerized tomography (CT) and optical coherence tomography (OCT)
  • Acoustic cameras and beamformers
  • Real-time oil reservoir management systems, smart wells, gas sequestration
  • Smart power grids
  • Extremely large telescopes (ELTs), very large array telescopes (VLATs), and large area telescopes (LATs)
  • Structural health monitoring of large civil engineering structures (bridges, buildings, and so on)
  • Toroidal magnetic field plasma containment (tokamaks)
  • Particle physics, particle accelerators, and particle colliders (Large Hadron Collider or LHC)
  • Multiple input, multiple output (MIMO), orthogonal frequency division multiplexing (OFDM) RF communication systems
  • Precision instrumentation for nanoscale systems (AFMs, STMs, and so on)
  • High-energy density and ultrafast lasers
  • Large solar panel arrays
  • Environmental monitoring systems
  • Smart bridges and civil engineering structures
  • Ray tracing and radars, adaptive antennas

Some of the challenges associated with these applications include:

  • High-channel counts of analog inputs (hundreds, thousands, and even 10,000 channels)
  • Intensive mathematical computations (hundreds of fast Fourier transforms, or FFTs, and so on) in a closed-loop arrangement
  • Sampling rates and resolution (kilohertz and above with 16 bits or more of resolution per channel)

Most of these types of applications are considered “highly parallelizable problems” that, in addition to high-performance data acquisition and a high number of channels, usually require intensive, parallel computations to solve large matrices and complex systems of equations in real time. These sophisticated scientific instruments make indirect measurements that require the complex interpretation, handling, and generation of large amounts of data that need powerful analysis methods. With virtual instrumentation and graphical system design, researchers can develop such applications with less effort, time, and resources while taking advantage of the most recent hardware acceleration technologies such as multicore, FPGA, multiprocessor digital signal processing (DSP), or a combination of these.

Today, researchers prefer LabVIEW to deploy these and many other large and complex applications because its graphical system design methodology transparently integrates hardware and the standard parallel models of computation that are familiar to them.

Back to Top

6. LabVIEW for Experimental Research and Scientific Computing

Using the LabVIEW development environment and programming language, researchers can easily combine mathematical equations and algorithms with online/real-time measurements of real-world signals while taking advantage of the most recent hardware acceleration technologies (multicore, FPGA, DSP) and COTS-based solutions on the market today.

LabVIEW software helps make the complexity of low-level programming and embedded hardware configuration invisible to the user, so the domain expert can focus on the design (algorithms, mathematical models, signal processing routines, and so on) instead of low-level software and hardware issues that are not the key subject matter of the research work. Domain experts can achieve this with a high level of abstraction using different computational models (data flow, statecharts, scripts, and so on).

Figure 5

Figure 5. Researchers can choose among a variety of models of computation as they develop custom software in LabVIEW; applications based on LabVIEW can include a mixture of dataflow programming, textual math (.m file script), statecharts, and other approaches.

LabVIEW, with its G graphical programming language, is ideal for creating flexible, scalable, and sophisticated applications and instruments that meet the specific needs of a research project. Researchers can rapidly and at minimal cost develop applications to interface with real-world signals, analyze and visualize data, develop and prototype new algorithms, interface with external scientific computing libraries and text-based programming languages and scripts, and directly deploy the final application using COTS technology. Regardless of the user’s programming experience, LabVIEW makes development fast and easy in the scientific community. The G graphical programming language in LabVIEW was originally based on the dataflow model of execution, but it now works with different models of computation within the same application.

Figure 6

Figure 6. With LabVIEW dataflow programming, nodes (operations) execute only after data is available on all inputs.

A concept of dataflow programming is that each node is enabled (executes) as soon as data is available in all of its inputs. This intrinsic architecture of LabVIEW and its G programming language is important for scientific computing applications because it helps non programmers and domain experts develop sophisticated, math-intensive applications that take advantage of parallel programming and parallel hardware without the need to know the details of machine-level code and hardware.

LabVIEW provides the following key elements that researchers need in a flexible, problem-solving tool:

  • Data acquisition tools
  • Data analysis tools
  • Data visualization tools

Back to Top

7. Data Acquisition

Data acquisition is the process of gathering or generating information in an automated fashion from analog and digital measurement sources such as sensors and devices under test. Data acquisition systems commonly use a combination of PC-based measurement hardware and software to provide a flexible, user-defined measurement system (Figure 7). Oftentimes, a researcher must condition sensors and signals before a data acquisition device acquires them. Researchers can analyze and visualize data in real time (online) while they are acquiring it. In the context of scientific computing, this concept is expanded to include previously acquired data, available in files, databases, and other forms of storage, from which data can be accessed for offline analysis and visualization.

Figure 7

Figure 7. Data acquisition systems commonly use a combination of PC-based measurement hardware and software to provide a flexible, user-defined measurement system.

Researchers can choose from several data acquisition options featuring different form factors, characteristics, and specifications. National Instruments offers a complete family of data acquisition hardware devices for desktop, portable, industrial, and embedded applications on several buses, including PCI/PCI Express, CompactPCI, PXI/PXI Express, PCMCIA, USB, Ethernet, and IEEE 1394, and for many operating systems, including Windows, Linux, Mac OS X, Pocket PC/Windows CE, and real-time OSs (Figure 8).

Figure 8

Figure 8. National Instruments offers a variety of alternatives for data acquisition and signal generation. Alternatives are available for a variety of PC-based interfaces, including USB, Ethernet, PCI, PCI Express, CompactPCI, PXI, and others.

Some data acquisition devices are designed to be plugged into a PCI, PCI Express, or PCMCIA slot of a PC, while others are external devices that can be connected to a PC via a USB, serial, or Ethernet port. Some of the external options are stand-alone because they have their own CPU/memory and can execute code (EXEs) in real time (NI CompactRIO, PXI, and Compact FieldPoint modules).

Signal conditioning is another key element of data acquisition systems such as those depicted in Figure 7.  Signal conditioning involves amplification, linearization, isolation, attenuation, level shifting, filtering and other operations that are applied to a signal prior to acquisition. Signal conditioning can also prepare output signals created by signal generation hardware.

In most cases, some form of signal conditioning is required between the data acquisition hardware and the sensors/actuators. Some data acquisition devices already include built-in signal conditioning; however, in those cases where the built-in functionality already incorporated in the data acquisition device may not be sufficient or when it is simply absent, some type of external signal conditioning is required. For this purpose, researchers can choose from several options, including external signal conditioning devices that they can add to the data acquisition device (SCC, SCXI) and build in where the data acquisition device and the SC circuitry are integrated in the same device (NI C Series, SC Series, and Compact FieldPoint devices).

Figure 9

Figure 9. Researchers can choose from a variety of alternatives for external and built-in signal conditioning.

Some specialized hardware such as dynamic signal acquisition (DSA) sound and vibration measurement hardware also includes built-in signal conditioning capabilities such as simultaneous sampling, precision current supply for sensors, and antialiasing filters.

Back to Top

8. Signal Processing and Analysis

LabVIEW features an extensive library of tools for signal processing, analysis and visualization, so scientists and engineers can use one common set of software tools that supports a wide variety of COTS-based hardware to develop scientific computing applications in less time and with less effort. These tools are included with the LabVIEW Full, Professional, and Student Edition development systems. Highlights of the included functionality include:

  • Curve fitting
  • Interpolation and extrapolation
  • Optimization
  • Linear algebra
  • Probability and statistics
  • Differential equation solvers
  • Signal processing
  • Integration and differentiation

Figure 10

Figure 10. LabVIEW includes extensive built-in capability for signal processing, analysis, and mathematics. Examples of included mathematics capabilities include numerical operations, elementary (special) functions, linear algebra, curve fitting/optimization, interpolation/extrapolation, differential equations, and geometry.

To see how you can apply LabVIEW for mathematics, consider the following example. Working with LabVIEW, you can easily solve a system of ordinary differential equations (ODEs) using one of the VIs or functions in the mathematics library. For instance, with the following system of ODEs, you can use the “right sides” of the differential equations and initial conditions to find the solutions for x using the Runge Kutta method of 4th Order with a step size h = .1.

  • Time start: 0.00
  • Time end: 50.00
  • X: [x, y, z]
  • X0: [1, 1, 1]
  • F(X,t): [10*(y - x), x*(28 - z) - y, x*y - (8/3)*z]

The LabVIEW Analysis Library includes a Runge Kutta method of 4th Order solver (Figure 11), which can be applied (Figure 12) to solve this system (Figure 13).

Figure 11. The Runge Kutta 4th Order VI from the LabVIEW Analysis Library is among the ODE solvers available in LabVIEW.

Figure 12

Figure 12. This LabVIEW application shows the graphical (G) program for solving the equation system using the Runge Kutta method of 4th Order.

Figure 13

Figure 13. You can graph the solution for x using the Runge Kutta method of 4th Order on the front panel of your applications based on LabVIEW.

One interesting feature is that the values of x, y, and z in the code above can come directly from measurements captured online through the use of a data acquisition device, which brings live, real-world signals to mathematics.

Figure 14

Figure 14. Real-time mathematics bring “live” data and signals to mathematics.

Researchers can use a similar approach with partial differential equations (PDEs); for example, they can implement numerical solutions to the heat, wave, or Poisson equations using real-time data for controlling complex, multiphysics systems such as fusion nuclear reactors (tokamaks). Figure 15 shows a 3D surface plot of the solution for a 128-by-128-point Poisson equation using data captured directly from sensors.

Figure 15. LabVIEW includes 3D graphing capability, which you can apply to visualize the online solution (and visualization) to the Poisson equation.

Back to Top

9. Data Visualization

For data visualization, LabVIEW offers a wide variety of options including the following:

  • 3D numeral, text, and Boolean indicators/controls
  • 3D surface graphs
  • Charts, graphs, XY graphs, and intensity graphs
  • Bode, Nichols, Nyquist, Smith, radar, and polar plots
  • Image, video, and picture controls/indicators
  • Tables and matrix indicators/controls
  • Digital waveform and mixed-signal indicators
  • Line, column, and bar graphs
  • Time-frequency (spectrograms) and waterfall graphs

Figure 16

Figure 16. LabVIEW includes an extensive set of tools for user-interface development and visualization in LabVIEW.

LabVIEW provides a wide selection of options to present data. Another example of the visualization capabilities of LabVIEW is shown in Figure 17. In this case, researchers can use the OpenGL-based code to create, import, and control 3D graphics for the realistic presentation of real-world objects.

Figure 17

Figure 17. 3D Image Rendering with LabVIEW; Color Gradients Reflect Variations in Surface Temperature

In this example (available at NI Labs,, researchers can connect real-world signals to the image via a data acquisition device. The color gradients in the image change with the sensor readings.

Back to Top

10. Connecting External Tools to LabVIEW

Researchers can easily expand both analysis and visualization functions by creating their own functions in the G language, adding new toolkits to LabVIEW, using MathScript commands, or interfacing with third-party tools such as The MathWorks, Inc. MATLAB® software, Maple, Mathcad, Mathematica, Scilab, GNU Octave, Microsoft Excel, Avizo, and many others.

Connectivity with these third-party tools is usually achieved through a LabVIEW Script Node; special API; or standard interface mechanism such as ActiveX, .NET, OPC, TCP/IP, or specific VIs created for this purpose. Researchers can use links and interfaces to dynamically exchange data between LabVIEW and these or other commercial packages, tools, and scientific computing libraries.

More experienced programmers can call external scientific libraries from LabVIEW in the form of C code (*.h, *.c), DLLs, and code interface nodes (CINs), which are C code compiled into LabVIEW nodes. Researchers can access popular scientific libraries such as LAPACK, FFTW, NAG, and others via external links or function library calls from/to LabVIEW.

Back to Top

11. Benefits of Using LabVIEW in Scientific Research

The many benefits of using an integrated development environment and programming language such as LabVIEW in academic research and scientific computing applications include the following:

  • Compiled code speed and ability to create distributable EXEs and DLLs
  • Powerful, flexible, and scalable design (open, connects to external libraries and third-party tools)
  • Easy to learn, use, maintain, and upgrade (intuitive graphical programming, using graphical constructs)
  • One tool for design, prototyping and deployment
  • Multidisciplinary use (same easy graphical programming language for different applications and domain experts in different disciplines in science and engineering)
  • Tight software-hardware integration (supports wide variety of data acquisition and embedded control devices)
  • Multicore-ready design (intrinsic parallelism) and support for different hardware acceleration technologies (DSPs, FPGAs, and GPUs as coprocessors)
  • Multiplatform (Windows, Mac OS, Linux, RTOSs)
  • Easy integration with legacy and traditional instruments (serial, GPIB, CAMAC, VME, and so on)
  • Longevity (COTS-based, more than 20 years of evolution)
  • Ability to solve and execute complex algorithms in real time (ODEs, PDEs, BLAS-based linear algebra, signal processing and analysis, optimization, and so on) using real-world signals (A/D)
  • Bridge to industry – same tools used in academia and industry (academic-to-industry transition easier, technology transfer more transparent)
  • Shorter time to prototype, time to discovery, time to deployment, and potentially time to market
  • Help to develop better, faster algorithms (algorithm engineering)

Back to Top

12. Additional Resources

MATLAB® is a registered trademark of The MathWorks, Inc.

Back to Top

Bookmark & Share


Rate this document

Answered Your Question?
Yes No