File: fec.xml

package info (click to toggle)
scilab 5.2.2-9
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 334,832 kB
  • ctags: 52,586
  • sloc: xml: 526,945; ansic: 223,590; fortran: 163,080; java: 56,934; cpp: 33,840; tcl: 27,936; sh: 20,397; makefile: 9,908; ml: 9,451; perl: 1,323; cs: 614; lisp: 30
file content (170 lines) | stat: -rw-r--r-- 6,737 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
<?xml version="1.0" encoding="UTF-8"?>
<refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" version="5.0-subset Scilab" xml:lang="fr" xml:id="fec">
  <info>
    <pubdate>$LastChangedDate$</pubdate>
  </info>
  <refnamediv>
    <refname>fec</refname>
    <refpurpose>dessin en pseudo-couleurs d'une surface
  définie sur une triangulation</refpurpose>
  </refnamediv>
  <refsynopsisdiv>
    <title>Séquence d'appel</title>
    <synopsis>fec(x,y,triangles,func,[strf,leg,rect,nax,zminmax,colminmax])</synopsis>
  </refsynopsisdiv>
  <refsection>
    <title>Paramètres</title>
    <variablelist>
      <varlistentry>
        <term>x,y</term>
        <listitem>
          <para>deux vecteurs de taille <literal>n</literal>,
          <literal>(x(i),y(i))</literal> donne les coordonnées du sommet
          <literal>i</literal></para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>func</term>
        <listitem>
          <para>un vecteur de taille <literal>n</literal> : <literal>func(i)</literal>
          donne la valeur de la fonction à  représenter</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>triangles</term>
        <listitem>
          <para>une matrice <literal>[Ntr,5]</literal>. Chaque ligne de
          <literal>triangles</literal> représente un triangle du maillage
          <literal>triangle(j) = [number,node1,node2,node3,flag]</literal>.
          <literal>node1,node2,node3</literal> sont les numéros des sommets qui
          constituent le triangle j. number est le numéro du triangle et flag
          est un entier qui n'est pas utilisé par fec.</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>strf,leg,rect,nax</term>
        <listitem>
          <para>voir plot2d</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>zminmax</term>
        <listitem>
          <para>parfait pour faire des animations avec fec. zminmax est un
          vecteur de taille 2 [zmin zmax] qui donne les z associés à  la
          première et la dernière couleur (de la table des couleurs courante).
          Plus exactement si la table des couleurs a nc couleurs et si on note
          dz = (zmax-zmin)/nc, alors la partie de la triangulation où zmin +
          (i-1)dz &lt;= z &lt; zmin + i dz est remplie avec la couleur i). Par
          défaut zmin = min(func) et zmax = max(func). Si vous voulez faire
          une animation avec des valeurs de func changeant en fonction du
          temps, prenez zmin et zmax égaux au minimum et maximum globaux.
          ATTENTION : pour les valeurs de func plus grandes que zmax la
          dernière couleur est utilisée, et pour les valeurs plus petites que
          zmin la première couleur est utilisée (on ne voit donc pas que les
          niveaux de zminmax sont franchis).</para>
        </listitem>
      </varlistentry>
      <varlistentry>
        <term>colminmax</term>
        <listitem>
          <para>un vecteur de 2 entiers positifs colminmax=[colmin colmax]
          avec 1 &lt;= colmin &lt; colmax &lt;= nc (où nc est la taille de la
          table des couleurs). Permet de définir un sous-ensemble de la table
          des couleurs à  utiliser, ici cmap(colmin:colmax). Par défaut toute
          la table des couleurs est utilisée.</para>
        </listitem>
      </varlistentry>
    </variablelist>
  </refsection>
  <refsection>
    <title>Description</title>
    <para>Voir les fonctions de démonstration dans le répertoire
    <literal>demos/fec</literal>.</para>
    <para><literal>fec.ex1</literal> est une simple démo dans laquelle le maillage et
    la fonction sont construits en langage Scilab.</para>
    <para><literal>fec.ex2</literal> est un exemple où le maillage est construit avec
    un mailleur externe (type amdba). Un ensemble de macros
    (<literal>macros.sci</literal>) peut être utilisé pour lire les fichiers de
    données correspondants.</para>
  </refsection>
  <refsection>
    <title>Exemples</title>
    <programlisting role="example"><![CDATA[ 
// define a mini triangulation (4 vertices, 2 triangles)
x = [0 1 0 -1];
y = [0 0 1  1];
T = [1 1 2 3 1;
     2 3 4 1 1];
z = [0 1 0 -1];  // values of the func at each vertices
clf()
xset("colormap",jetcolormap(64))
subplot(1,2,1)
  colorbar(-1,1)
  fec(x,y,T,z,strf="040",mesh=%t)
  xtitle("fec example (with the mesh)")
subplot(1,2,2)
  colorbar(-1,1)
  fec(x,y,T,z,strf="040")  // rmq: mesh=%f by default
  xtitle("fec example (without the mesh)")
xselect()

// this example shows the effect of zminmax and uses the
// previous example datas (you have to execute the it before)
clf()
xset("colormap",jetcolormap(64))
colorbar(-0.5,0.5)  // be careful colorbar must be set by hands !
fec(x,y,T,z,strf="040", zminmax=[-0.5 0.5], mesh=%t)
xtitle("fec example : using zminmax argument")
xselect()

// this example shows the effect of zminmax and colout. It uses
// also the datas of the first example (you have to execute the it before)
clf()
xset("colormap",jetcolormap(64))
subplot(2,2,1)
  colorbar(-0.5,0.5)
  fec(x,y,T,z,strf="040", zminmax=[-0.5 0.5], colout=[0 0], mesh=%t)
  xtitle("fec example : using zminmax and colout =[0 0]")
subplot(2,2,2)
  colorbar(-0.5,0.5)
  fec(x,y,T,z,strf="040", zminmax=[-0.5 0.5], colout=[32 32], mesh=%t)
  xtitle("fec example : using zminmax and colout =[32 32]")
subplot(2,2,3)
  colorbar(-0.5,0.5)
  fec(x,y,T,z,strf="040", zminmax=[-0.5 0.5], colout=[-1 0], mesh=%t)
  xtitle("fec example : using zminmax and colout =[-1 0]")
subplot(2,2,4)
  colorbar(-0.5,0.5)
  fec(x,y,T,z,strf="040", zminmax=[-0.5 0.5], colout=[0 -1], mesh=%t)
  xtitle("fec example : using zminmax and colout =[0 -1]")
xselect()

// this example shows a feature from colminmax:
// playing with 2 colormaps for 2 subplots. It
// uses also the data of the first example.
clf()
xset("colormap",[hotcolormap(64);jetcolormap(64)])
subplot(1,2,1)
  colorbar(-1,1,[1 64])
  fec(x,y,T,z,strf="040", colminmax=[1 64], mesh=%t)
  xtitle("fec using the hot colormap")
subplot(1,2,2)
  colorbar(-1,1,[65 128])
  fec(x,y,T,z,strf="040", colminmax=[65 128], mesh=%t)
  xtitle("fec using the jet colormap")
xselect()
 ]]></programlisting>
  </refsection>
  <refsection>
    <title>Voir Aussi</title>
    <simplelist type="inline">
      <member>
        <link linkend="Sfgrayplot">Sfgrayplot</link>
      </member>
      <member>
        <link linkend="Sgrayplot">Sgrayplot</link>
      </member>
    </simplelist>
  </refsection>
</refentry>