~ubuntu-branches/ubuntu/hoary/scilab/hoary

« back to all changes in this revision

Viewing changes to man/fr/scicos/RAMP.htm

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2005-01-09 22:58:21 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20050109225821-473xr8vhgugxxx5j
Tags: 3.0-12
changed configure.in to build scilab's own malloc.o, closes: #255869

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
 
2
 
 
3
<!--Converted with LaTeX2HTML 2002-2-1 (1.70)
 
4
original version by:  Nikos Drakos, CBLU, University of Leeds
 
5
* revised and updated by:  Marcus Hennecke, Ross Moore, Herb Swan
 
6
* with significant contributions from:
 
7
  Jens Lippmann, Marek Rouchal, Martin Wilck and others -->
 
8
<HTML>
 
9
<HEAD>
 
10
<TITLE>Ramp </TITLE>
 
11
<META NAME="description" CONTENT="Ramp ">
 
12
<META NAME="keywords" CONTENT="main">
 
13
<META NAME="resource-type" CONTENT="document">
 
14
<META NAME="distribution" CONTENT="global">
 
15
 
 
16
<META NAME="Generator" CONTENT="LaTeX2HTML v2002-2-1">
 
17
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
 
18
 
 
19
<LINK REL="STYLESHEET" HREF="main.css">
 
20
 
 
21
</HEAD>
 
22
 
 
23
<BODY bgcolor="#FFFFFF">
 
24
 
 
25
<!--Table of Child-Links-->
 
26
<A NAME="CHILD_LINKS"><STRONG>Subsections</STRONG></A>
 
27
 
 
28
<UL>
 
29
<LI><A NAME="tex2html2788"
 
30
  HREF="RAMP.htm#SECTION00513100000000000000">Library</A>
 
31
<LI><A NAME="tex2html2789"
 
32
  HREF="RAMP.htm#SECTION00513200000000000000">Description</A>
 
33
<LI><A NAME="tex2html2790"
 
34
  HREF="RAMP.htm#SECTION00513300000000000000">Dialog Box</A>
 
35
<LI><A NAME="tex2html2791"
 
36
  HREF="RAMP.htm#SECTION00513400000000000000">Default properties</A>
 
37
<LI><A NAME="tex2html2792"
 
38
  HREF="RAMP.htm#SECTION00513500000000000000">Interfacing function</A>
 
39
<LI><A NAME="tex2html2793"
 
40
  HREF="RAMP.htm#SECTION00513600000000000000">Computational function (type 4)</A>
 
41
</UL>
 
42
<!--End of Table of Child-Links-->
 
43
<HR>
 
44
 
 
45
<H2><A NAME="SECTION00513000000000000000"></A><A NAME="RAMP"></A>
 
46
<BR>
 
47
Ramp 
 
48
</H2>
 
49
<DIV ALIGN="CENTER">
 
50
<!-- MATH
 
51
 $\epsfig{file=RAMP.eps,width=90.00pt}$
 
52
 -->
 
53
<IMG
 
54
 WIDTH="143" HEIGHT="161" ALIGN="BOTTOM" BORDER="0"
 
55
 SRC="img7.gif"
 
56
 ALT="\epsfig{file=RAMP.eps,width=90.00pt}">
 
57
</DIV>
 
58
<H3><font color="blue"><A NAME="SECTION00513100000000000000">
 
59
Library</A>
 
60
</font></H3>
 
61
Sources
 
62
 
 
63
<H3><font color="blue"><A NAME="SECTION00513200000000000000">
 
64
Description</A>
 
65
</font></H3>
 
66
The Ramp block generates a signal that starts at a specified time and
 
67
value and changes by a specified rate. The block's <B>Slope , Start
 
68
  time</B> and <B>Initial output</B> parameters determine the
 
69
characteristics of the output signal. All must have the consistent
 
70
dimensions after scalar expansion.    
 
71
 
 
72
<H3><font color="blue"><A NAME="SECTION00513300000000000000">
 
73
Dialog Box</A>
 
74
</font></H3>
 
75
<DIV ALIGN="CENTER">
 
76
<TABLE CELLPADDING=3 BORDER="1">
 
77
<TR><TD ALIGN="CENTER">Set ramp parameters</TD>
 
78
<TD></TD>
 
79
</TR>
 
80
<TR><TD ALIGN="CENTER">Slope</TD>
 
81
<TD ALIGN="CENTER">0</TD>
 
82
</TR>
 
83
<TR><TD ALIGN="CENTER">Start time</TD>
 
84
<TD ALIGN="CENTER">0</TD>
 
85
</TR>
 
86
<TR><TD ALIGN="CENTER">Initial output</TD>
 
87
<TD ALIGN="CENTER">0</TD>
 
88
</TR>
 
89
</TABLE>
 
90
</DIV>
 
91
 
 
92
<UL>
 
93
<LI>Slope: The rate of change of the generated signal. 
 
94
</LI>
 
95
<LI>Start time:The time at which the signal begins to be generated. 
 
96
</LI>
 
97
<LI>Initial output:The initial value of the signal. 
 
98
</LI>
 
99
</UL>
 
100
 
 
101
<H3><font color="blue"><A NAME="SECTION00513400000000000000">
 
102
Default properties</A>
 
103
</font></H3>
 
104
 
 
105
<UL>
 
106
<LI>always active: yes
 
107
</LI>
 
108
<LI>direct-feedthrough: no
 
109
</LI>
 
110
<LI>zero-crossing: yes
 
111
</LI>
 
112
<LI>mode: yes
 
113
</LI>
 
114
<LI>number/sizes of inputs: 0 / 
 
115
</LI>
 
116
<LI>number/sizes of outputs: 1 / 1
 
117
</LI>
 
118
<LI>number/sizes of activation inputs: 0 / 
 
119
</LI>
 
120
<LI>number/sizes of activation outputs: 0 / 
 
121
</LI>
 
122
<LI>continuous-time state: no
 
123
</LI>
 
124
<LI>discrete-time state: no
 
125
</LI>
 
126
<LI>name of computational function: <EM>ramp</EM>
 
127
</LI>
 
128
</UL>
 
129
<H3><font color="blue"><A NAME="SECTION00513500000000000000">
 
130
Interfacing function</A>
 
131
</font></H3>
 
132
<TT>scilab/macros/scicos_blocks/sources/RAMP.sci</TT>
 
133
 
 
134
<H3><font color="blue"><A NAME="SECTION00513600000000000000">
 
135
Computational function (type 4)</A>
 
136
</font></H3>
 
137
<BR>
 
138
<PRE>#include "scicos_block.h"
 
139
#include &lt;math.h&gt;
 
140
 
 
141
void ramp(scicos_block *block,int flag)
 
142
{double dt;
 
143
  if (flag==1){
 
144
    dt=get_scicos_time()-block-&gt;rpar[1];
 
145
    if (get_phase_simulation()==1) {
 
146
      if(dt&gt;0) {
 
147
        block-&gt;outptr[0][0]=block-&gt;rpar[2]+block-&gt;rpar[0]*dt;
 
148
      }else{
 
149
        block-&gt;outptr[0][0]=block-&gt;rpar[2];
 
150
      }
 
151
    }else{
 
152
      if(block-&gt;mode[0]==1) {
 
153
        block-&gt;outptr[0][0]=block-&gt;rpar[2]+block-&gt;rpar[0]*dt;
 
154
      }else {
 
155
        block-&gt;outptr[0][0]=block-&gt;rpar[2];
 
156
      }
 
157
    }
 
158
  } else if (flag==9){
 
159
    block-&gt;g[0]=get_scicos_time()-(block-&gt;rpar[1]);
 
160
    if (get_phase_simulation()==1) {
 
161
      if (block-&gt;g[0]&gt;=0){
 
162
        block-&gt;mode[0]=1;
 
163
      }else{
 
164
        block-&gt;mode[0]=2;
 
165
      }
 
166
    }
 
167
  }
 
168
}
 
169
</PRE>
 
170
<HR>
 
171
<ADDRESS>
 
172
Ramine Nikoukhah
 
173
2004-06-22
 
174
</ADDRESS>
 
175
</BODY>
 
176
</HTML>