Example of referring elements, MATLAB Programming

Example of Referring elements:

the vector can also be extended. For illustration, the following generates a vector which has three elements. And then referring to the fourth element in an assignment statement, the vector is then extended to have four elements.

>> rv = [3 55 11]

rv =

3  55  11

>> rv(4) = 2

rv =

3  55  11  2

If there is a gap between the ends of the vector and the specified element, 0's are filled in. For illustration, the following extend the variable generated former again:

>> rv(6) = 13

rv =

3  55  11  2  0  13

 

 

Posted Date: 10/18/2012 4:17:58 AM | Location : United States







Related Discussions:- Example of referring elements, Assignment Help, Ask Question on Example of referring elements, Get Answer, Expert's Help, Example of referring elements Discussions

Write discussion on Example of referring elements
Your posts are moderated
Related Questions
Format command: The format command can be used to control the spacing between the MATLAB command or expression and the outcome; it can be either compact or loose. >> format

How to make EMG analysis by Matlab?

Scripts to Produce and Customize the Simple Plots: The MATLAB has many graphing capabilities. In most cases, customizing plots are desired and this is the simplest to accompli

using 0de 45 how can i get the anlytical and numerical solutions for an equation,,

Ant Colony Optimization for Optimization of Route path taken Ant Colony Algorithm is a potential candidate for coupled, 3D optimisation. Ant Colony Algorithm enjoys the overall

Q.1: Consider the transmission of a sinusoid x(t) = cos(2f0t) through a channel a ected by multipath and Doppler. Let there be two paths, and assume the sinusoid is being sent fro


An FIR filter has coefficients b = [ 1.0000   -0.6387    1.0214    0.8210   -0.7470    1.0920 ] (a) Find H(z) for the filter and plot its frequency response (magnitude and phase

Appending data to a data File: A text file once exists; the data can be appended to it. The format is similar as formerly, with the addition of the qualifier -append. For illu