1 <?xml version="1.0" encoding="UTF-8"?>
3 * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab
4 * Copyright (C) 2008 - INRIA
6 * This file must be used under the terms of the CeCILL.
7 * This source file is licensed as described in the file COPYING, which
8 * you should have received as part of this distribution. The terms
9 * are also available at
10 * http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt
13 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns5="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="linspace" xml:lang="en">
15 <refname>linspace</refname>
16 <refpurpose>linearly spaced vector</refpurpose>
19 <title>Calling Sequence</title>
20 <synopsis>[v]=linspace(x1,x2 [,n])</synopsis>
23 <title>Arguments</title>
28 <para>real or complex scalars or column vectors</para>
34 <para>integer: number of requested values. It must be greater or equal to 2 (default value = 100)</para>
40 <para>real or complex row vector</para>
46 <title>Description</title>
48 Linearly spaced vector. <literal>linspace(x1, x2)</literal>
49 generates a row vector of n (default value=100) linearly equally spaced
50 points between <literal>x1</literal> and <literal>x2</literal>. If
51 <literal>x1</literal> or <literal>x2</literal> are complex then
52 <literal>linspace(x1,x2)</literal> returns a row vector of n complexes,
53 the real (resp. imaginary) parts of the n complexes are linearly equally
54 spaced between the real (resp. imaginary) parts of <literal>x1</literal>
55 and <literal>x2.</literal>
59 <title>Examples</title>
60 <programlisting role="example"><![CDATA[
62 linspace([1:4]',[5:8]',10)
63 linspace(1+%i,2+2*%i,10)
66 <refsection role="see also">
67 <title>See Also</title>
68 <simplelist type="inline">
70 <link linkend="logspace">logspace</link>
75 <title>History</title>
78 <revnumber>5.4.0</revnumber>
81 <listitem>The linspace function accepts column vectors as input argument for the two first input arguments. Thanks to Guillaume AZEMA for the implementation.
83 <listitem>The third input argument (n) must be an integer value.