1 / 13

CLUSTERS and ARRAYS

CLUSTERS and ARRAYS. Array Functions. Build an array Size an array Form an array from a cluster or a cluster into an array Index an array Find the max an min of an array Insert and delete from an array or reshape Sort a lD array Convert an array to matrix, or a matrix to array.

dinah
Download Presentation

CLUSTERS and ARRAYS

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CLUSTERS and ARRAYS

  2. Array Functions • Build an array • Size an array • Form an array from a cluster or a cluster into an array • Index an array • Find the max an min of an array • Insert and delete from an array or reshape • Sort a lD array • Convert an array to matrix, or a matrix to array

  3. Build and sizing an array • Complies multiple arrays or appends elements to an n-dimensional array. • Sizing an array just shows the number of elements in the array on the front panel.

  4. Index Array Returns the element or sub-array of n-dimensionarray at index. When you wire an array to this function, the function resizes automatically to display index inputs for each dimension in the array you wire to n-dimension array. You also can add additional element or sub-array terminals by resizing it.  

  5. Max and Min of an Array • Returns the maximumand minimum values found in array, along with the indexes for each value. The array can be an n-dimensional array of any type. • Max/min index(es) is the index for the first max/min value. If array is multidimensional, max/min index(es) is an array whose elements are the indexes for the first maximum/min value in array. • Would be good to use if you needed to know when a graph peaked or lowest value

  6. Sorting an Array • Returns a sorted version of array with the elements arranged in ascending order. If array is an array of clusters, the function sorts the elements by comparing the first elements. If the first elements match, the function compares the second and subsequent elements.

  7. Converting an Array to a Matrix • Converts an array to a matrix of elements of the same type as the array elements . • Can make each of the following * to real matrix * to column vector * to complex matrix * to complex column vector

  8. Array => cluster or cluster =>array • Bundles each component input into a cluster and assembles all component clusters into an array of clusters. Each cluster contains a single component. Input components must be of the same type as the value wired to the topmost component terminal. • Array to cluster converts a 1D array to a cluster of elements of the same type as the array elements.

  9. Clusters • Can build a cluster • Can bundle and unbundle clusters • Can also index a cluster

  10. Building a Cluster • Clusters are built by bundling up a collection of inputs and they are complied into a cluster which can then be manipulated to your liking. • They are perfect for organization and complying data in a neatand uniform way that is easily represented in the front panel.

  11. Bundling and Unbundling • Assembles a cluster from individual elements. • can also be use to change the values of individual elements in an existing cluster without having to specify new values for all elements. To do so, wire the cluster you want to change to the middle cluster terminal of this function. When you wire a cluster to this function, the function resizes automatically to display inputs for each element in the cluster. Also when you wire to the middle terminal, all other inputs are optional.

  12. Indexing A Cluster • Indexes a set of arrays and creates a cluster array in which matches the value of each element to a corresponding location. Much like how a matrix is set up, so that element values are easy to locate and decifer.

  13. LABVIEW EXAMPLES! GET EXCITED!!

More Related