Separately creating two parts of an array?

1 view (last 30 days)
Joe
Joe on 17 Mar 2013
I have an array x that is initialized to be of size 1 by n containing random values. The overall length of array x is some value a * some value b. How would I create the elements of x from n+1 to the end?

Answers (2)

Azzi Abdelmalek
Azzi Abdelmalek on 17 Mar 2013
x(n+1:end)

Jan
Jan on 18 Mar 2013
Such problems are discussed exahustively in the documentation. Please read at least the "Getting Started" chapters, because it is impossible to work with such a powerful language as Matlab without reading the manuals. It is not efficient to discuss such basic questions in the forum, when MathWorks spend so much time and knowhow to create this marvelous and exhaustive documentation already in written form.

Categories

Find more on Programming Utilities in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!