* Bug 16005 fixed [doc]: intdec() example was biased & not robust
[scilab.git] / scilab / modules / signal_processing / help / ja_JP / intdec.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"
3           xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML"
4           xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org"
5           xml:lang="ja" xml:id="intdec">
6     <refnamediv>
7         <refname>intdec</refname>
8         <refpurpose>信号のサンプリングレートを変更</refpurpose>
9     </refnamediv>
10     <refsynopsisdiv>
11         <title>呼び出し手順</title>
12         <synopsis>[y]=intdec(x,lom)</synopsis>
13     </refsynopsisdiv>
14     <refsection>
15         <title>引数</title>
16         <variablelist>
17             <varlistentry>
18                 <term>x</term>
19                 <listitem>
20                     <para>入力標本信号</para>
21                 </listitem>
22             </varlistentry>
23             <varlistentry>
24                 <term>lom</term>
25                 <listitem>
26                     <para>1次元信号の場合, 変更するレートを指定するスカラー値です.
27                         2次元信号の場合,
28                         変更する
29                         サンプリングレートのベクトル(要素数:2)
30                         <literal>lom</literal>=(列方向の変更レート,行方向の変更レート) です.
31                     </para>
32                 </listitem>
33             </varlistentry>
34             <varlistentry>
35                 <term>y</term>
36                 <listitem>
37                     <para>出力標本信号</para>
38                 </listitem>
39             </varlistentry>
40         </variablelist>
41     </refsection>
42     <refsection>
43         <title>説明</title>
44         <para>
45             1次元または2次元信号のサンプリングレートをlomで指定された
46             レートに変更します.
47         </para>
48     </refsection>
49     <refsection>
50         <title>例</title>
51         <programlisting role="example"><![CDATA[
52 Fs1 = 1000;               // initial sampling frequency
53 Fs2 = 1400;               // targeted resampling frequency
54 t1 = linspace(0, 5-1/Fs1, Fs1*5)';
55 t2 = linspace(0, 5-1/Fs2, Fs2*5)';
56 F0 = 2;                    // Signal frequency
57 u1 = sin(2*%pi*F0*t1);
58 u2 = sin(2*%pi*F0*t2);     // Direct sampling at targeted frequency (as reference)
59 u2b = intdec(u1, Fs2/Fs1); // Resampled signal
60 clf
61 plot(t2,u2,"b", t2,(u2b-u2)*1e13, "m");
62 legend("Direct highly sampled u2","Resampling_error x 1e13","in_upper_left");
63  ]]></programlisting>
64         <scilab:image>
65             Fs1 = 1000;               // initial sampling frequency
66             Fs2 = 1400;               // targeted resampling frequency
67             t1 = linspace(0, 5-1/Fs1, Fs1*5)';
68             t2 = linspace(0, 5-1/Fs2, Fs2*5)';
69             F0 = 2;                    // Signal frequency
70             u1 = sin(2*%pi*F0*t1);
71             u2 = sin(2*%pi*F0*t2);     // Direct sampling at targeted frequency (as reference)
72             u2b = intdec(u1, Fs2/Fs1); // Resampled signal
73             clf
74             plot(t2,u2,"b", t2,(u2b-u2)*1e13, "m");
75             legend("Direct highly sampled u2","Resampling_error x 1e13","in_upper_left");
76         </scilab:image>
77     </refsection>
78 </refentry>