~ubuntu-branches/ubuntu/karmic/maxima/karmic

« back to all changes in this revision

Viewing changes to doc/info/es.utf8/maxima_71.html

  • Committer: Bazaar Package Importer
  • Author(s): Christophe Sauthier
  • Date: 2009-07-13 15:38:41 UTC
  • mfrom: (3.1.3 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090713153841-gtux06oun30kuuo7
Tags: 5.17.1-1ubuntu1
* Merge from debian unstable, remaining changes (LP: #296643, LP: #242243):
   - debian/maxima-doc.doc-base.{tips, plotting}:
    + Use .shtml instead of .html to fix lintian errors.
   - debian/maxima-emacs.emacsen-install:
    + Install symlinks for source files rather than copying them.  This
      makes find-function work.
    + Install symlink for *.lisp so that we don't need to add
      /usr/share/emacs/site-lisp/maxima to load-path.
  - debian/maxima-emacs.emacsen-startup:
    + Remove use of /usr/share/emacs/site-lisp/maxima, since this
      causes load-path shadows and is not needed anymore.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html401/loose.dtd">
2
2
<html>
3
 
<!-- Created on agosto, 25 2007 by texi2html 1.76 -->
 
3
<!-- Created on diciembre, 14 2008 by texi2html 1.76 -->
4
4
<!--
5
5
Written by: Lionel Cons <Lionel.Cons@cern.ch> (original author)
6
6
            Karl Berry  <karl@freefriends.org>
11
11
 
12
12
-->
13
13
<head>
14
 
<title>Manual de Maxima: 71. stirling</title>
 
14
<title>Manual de Maxima: 71. solve_rec</title>
15
15
 
16
 
<meta name="description" content="Manual de Maxima: 71. stirling">
17
 
<meta name="keywords" content="Manual de Maxima: 71. stirling">
 
16
<meta name="description" content="Manual de Maxima: 71. solve_rec">
 
17
<meta name="keywords" content="Manual de Maxima: 71. solve_rec">
18
18
<meta name="resource-type" content="document">
19
19
<meta name="distribution" content="global">
20
20
<meta name="Generator" content="texi2html 1.76">
125
125
div.categorybox
126
126
{
127
127
    border: 1px solid gray;
128
 
    padding-top: 1em;
129
 
    padding-bottom: 1em;
 
128
    padding-top: 0px;
 
129
    padding-bottom: 0px;
130
130
    padding-left: 1em;
131
131
    padding-right: 1em;
132
132
    background: rgb(247,242,220);
141
141
 
142
142
<body lang="es" bgcolor="#FFFFFF" text="#000000" link="#0000FF" vlink="#800080" alink="#FF0000">
143
143
 
144
 
<a name="stirling"></a>
145
 
<a name="SEC270"></a>
 
144
<a name="solve_005frec"></a>
 
145
<a name="SEC277"></a>
146
146
<table cellpadding="1" cellspacing="1" border="0">
147
 
<tr><td valign="middle" align="left">[<a href="maxima_70.html#SEC269" title="Previous section in reading order"> &lt; </a>]</td>
148
 
<td valign="middle" align="left">[<a href="#SEC271" title="Next section in reading order"> &gt; </a>]</td>
 
147
<tr><td valign="middle" align="left">[<a href="maxima_70.html#SEC276" title="Previous section in reading order"> &lt; </a>]</td>
 
148
<td valign="middle" align="left">[<a href="#SEC278" title="Next section in reading order"> &gt; </a>]</td>
149
149
<td valign="middle" align="left"> &nbsp; </td>
150
 
<td valign="middle" align="left">[<a href="maxima_70.html#SEC265" title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 
150
<td valign="middle" align="left">[<a href="maxima_70.html#SEC267" title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
151
151
<td valign="middle" align="left">[<a href="maxima.html#SEC_Top" title="Up section"> Up </a>]</td>
152
 
<td valign="middle" align="left">[<a href="maxima_72.html#SEC272" title="Next chapter"> &gt;&gt; </a>]</td>
 
152
<td valign="middle" align="left">[<a href="maxima_72.html#SEC280" title="Next chapter"> &gt;&gt; </a>]</td>
153
153
<td valign="middle" align="left"> &nbsp; </td>
154
154
<td valign="middle" align="left"> &nbsp; </td>
155
155
<td valign="middle" align="left"> &nbsp; </td>
156
156
<td valign="middle" align="left"> &nbsp; </td>
157
157
<td valign="middle" align="left">[<a href="maxima.html#SEC_Top" title="Cover (top) of document">Top</a>]</td>
158
158
<td valign="middle" align="left">[<a href="maxima_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
159
 
<td valign="middle" align="left">[<a href="maxima_76.html#SEC287" title="Index">Index</a>]</td>
 
159
<td valign="middle" align="left">[<a href="maxima_78.html#SEC302" title="Index">Index</a>]</td>
160
160
<td valign="middle" align="left">[<a href="maxima_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
161
161
</tr></table>
162
 
<h1 class="chapter"> 71. stirling </h1>
 
162
<h1 class="chapter"> 71. solve_rec </h1>
163
163
 
164
164
<table class="menu" border="0" cellspacing="0">
165
 
<tr><td align="left" valign="top"><a href="#SEC271">71.1 Funciones y variables para stirling</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
 
165
<tr><td align="left" valign="top"><a href="#SEC278">71.1 Introducci&oacute;n a solve_rec</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
 
166
</td></tr>
 
167
<tr><td align="left" valign="top"><a href="#SEC279">71.2 Funciones y variables para solve_rec</a></td><td>&nbsp;&nbsp;</td><td align="left" valign="top">
166
168
</td></tr>
167
169
</table>
168
170
 
169
171
<hr size="6">
170
 
<a name="Funciones-y-variables-para-stirling"></a>
171
 
<a name="SEC271"></a>
172
 
<table cellpadding="1" cellspacing="1" border="0">
173
 
<tr><td valign="middle" align="left">[<a href="#SEC270" title="Previous section in reading order"> &lt; </a>]</td>
174
 
<td valign="middle" align="left">[<a href="maxima_72.html#SEC272" title="Next section in reading order"> &gt; </a>]</td>
175
 
<td valign="middle" align="left"> &nbsp; </td>
176
 
<td valign="middle" align="left">[<a href="#SEC270" title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
177
 
<td valign="middle" align="left">[<a href="#SEC270" title="Up section"> Up </a>]</td>
178
 
<td valign="middle" align="left">[<a href="maxima_72.html#SEC272" title="Next chapter"> &gt;&gt; </a>]</td>
179
 
<td valign="middle" align="left"> &nbsp; </td>
180
 
<td valign="middle" align="left"> &nbsp; </td>
181
 
<td valign="middle" align="left"> &nbsp; </td>
182
 
<td valign="middle" align="left"> &nbsp; </td>
183
 
<td valign="middle" align="left">[<a href="maxima.html#SEC_Top" title="Cover (top) of document">Top</a>]</td>
184
 
<td valign="middle" align="left">[<a href="maxima_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
185
 
<td valign="middle" align="left">[<a href="maxima_76.html#SEC287" title="Index">Index</a>]</td>
186
 
<td valign="middle" align="left">[<a href="maxima_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
187
 
</tr></table>
188
 
<h2 class="section"> 71.1 Funciones y variables para stirling </h2>
189
 
 
190
 
 
191
 
<dl>
192
 
<dt><u>Funci&oacute;n:</u> <b>stirling</b><i> (<var>z</var>,<var>n</var>)</i>
193
 
<a name="IDX2090"></a>
194
 
</dt>
195
 
<dd><p>Sustituye <code>gamma(x)</code> por la f&oacute;rmula de Stirling <em>O(1/x^(2n-1))</em>.
196
 
Si <var>n</var> no es un entero no negativo, emite un mensaje de error.
197
 
</p>
198
 
<p>Referencia: Abramowitz &amp; Stegun, &quot; Handbook of mathematical functions&quot;, 6.1.40.
199
 
</p>
200
 
<p>Ejemplos:
201
 
</p><pre class="example">(%i1) load (stirling)$
202
 
 
203
 
(%i2) stirling(gamma(%alpha+x)/gamma(x),1);
204
 
       1/2 - x             x + %alpha - 1/2
205
 
(%o2) x        (x + %alpha)
206
 
                                   1           1
207
 
                            --------------- - ---- - %alpha
208
 
                            12 (x + %alpha)   12 x
209
 
                          %e
210
 
(%i3) taylor(%,x,inf,1);
211
 
                    %alpha       2    %alpha
212
 
          %alpha   x       %alpha  - x       %alpha
213
 
(%o3)/T/ x       + -------------------------------- + . . .
214
 
                                 2 x
215
 
(%i4) map('factor,%);
216
 
                                       %alpha - 1
217
 
         %alpha   (%alpha - 1) %alpha x
218
 
(%o4)   x       + -------------------------------
219
 
                                  2
220
 
</pre>
221
 
<p>La funci&oacute;n <code>stirling</code> conoce la diferencia existente entre
222
 
la variable 'gamma' y la funci&oacute;n gamma:
223
 
</p>
224
 
<pre class="example">(%i5) stirling(gamma + gamma(x),0);
225
 
                                    x - 1/2   - x
226
 
(%o5)    gamma + sqrt(2) sqrt(%pi) x        %e
227
 
(%i6) stirling(gamma(y) + gamma(x),0);
228
 
                         y - 1/2   - y
229
 
(%o6) sqrt(2) sqrt(%pi) y        %e
230
 
                                              x - 1/2   - x
231
 
                         + sqrt(2) sqrt(%pi) x        %e
232
 
</pre>
233
 
<p>Antes de hacer uso de esta funci&oacute;n ejec&uacute;tese  <code>load(&quot;stirling&quot;)</code>.
234
 
</p></dd></dl>
235
 
 
236
 
 
237
 
<hr size="6">
238
 
<table cellpadding="1" cellspacing="1" border="0">
239
 
<tr><td valign="middle" align="left">[<a href="#SEC270" title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
240
 
<td valign="middle" align="left">[<a href="maxima_72.html#SEC272" title="Next chapter"> &gt;&gt; </a>]</td>
241
 
<td valign="middle" align="left"> &nbsp; </td>
242
 
<td valign="middle" align="left"> &nbsp; </td>
243
 
<td valign="middle" align="left"> &nbsp; </td>
244
 
<td valign="middle" align="left"> &nbsp; </td>
245
 
<td valign="middle" align="left"> &nbsp; </td>
246
 
<td valign="middle" align="left">[<a href="maxima.html#SEC_Top" title="Cover (top) of document">Top</a>]</td>
247
 
<td valign="middle" align="left">[<a href="maxima_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
248
 
<td valign="middle" align="left">[<a href="maxima_76.html#SEC287" title="Index">Index</a>]</td>
 
172
<a name="Introducci_00f3n-a-solve_005frec"></a>
 
173
<a name="SEC278"></a>
 
174
<table cellpadding="1" cellspacing="1" border="0">
 
175
<tr><td valign="middle" align="left">[<a href="#SEC277" title="Previous section in reading order"> &lt; </a>]</td>
 
176
<td valign="middle" align="left">[<a href="#SEC279" title="Next section in reading order"> &gt; </a>]</td>
 
177
<td valign="middle" align="left"> &nbsp; </td>
 
178
<td valign="middle" align="left">[<a href="#SEC277" title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 
179
<td valign="middle" align="left">[<a href="#SEC277" title="Up section"> Up </a>]</td>
 
180
<td valign="middle" align="left">[<a href="maxima_72.html#SEC280" title="Next chapter"> &gt;&gt; </a>]</td>
 
181
<td valign="middle" align="left"> &nbsp; </td>
 
182
<td valign="middle" align="left"> &nbsp; </td>
 
183
<td valign="middle" align="left"> &nbsp; </td>
 
184
<td valign="middle" align="left"> &nbsp; </td>
 
185
<td valign="middle" align="left">[<a href="maxima.html#SEC_Top" title="Cover (top) of document">Top</a>]</td>
 
186
<td valign="middle" align="left">[<a href="maxima_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
 
187
<td valign="middle" align="left">[<a href="maxima_78.html#SEC302" title="Index">Index</a>]</td>
 
188
<td valign="middle" align="left">[<a href="maxima_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
 
189
</tr></table>
 
190
<h2 class="section"> 71.1 Introducci&oacute;n a solve_rec </h2>
 
191
 
 
192
<p>El paquete <code>solve_rec</code> resuelve expresiones recurrentes lineales con
 
193
coeficientes polinomiales.
 
194
</p>
 
195
<p>Ejec&uacute;tese <code>demo(solve_rec);</code> para ver una demostraci&oacute;n sobre
 
196
la utilizaci&oacute;n de este paquete.
 
197
</p>
 
198
<p>Ejemplo:
 
199
</p>
 
200
<pre class="example">(%i1) load(&quot;solve_rec&quot;)$
 
201
(%i2) solve_rec((n+4)*s[n+2] + s[n+1] - (n+1)*s[n], s[n]);
 
202
                                    n
 
203
                 %k  (2 n + 3) (- 1)          %k
 
204
                   1                            2
 
205
(%o2)       s  = -------------------- + ---------------
 
206
             n     (n + 1) (n + 2)      (n + 1) (n + 2)
 
207
</pre>
 
208
<hr size="6">
 
209
<a name="Funciones-y-variables-para-solve_005frec"></a>
 
210
<table cellpadding="1" cellspacing="1" border="0">
 
211
<tr><td valign="middle" align="left">[<a href="#SEC278" title="Previous section in reading order"> &lt; </a>]</td>
 
212
<td valign="middle" align="left">[<a href="maxima_72.html#SEC280" title="Next section in reading order"> &gt; </a>]</td>
 
213
<td valign="middle" align="left"> &nbsp; </td>
 
214
<td valign="middle" align="left">[<a href="#SEC277" title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 
215
<td valign="middle" align="left">[<a href="#SEC277" title="Up section"> Up </a>]</td>
 
216
<td valign="middle" align="left">[<a href="maxima_72.html#SEC280" title="Next chapter"> &gt;&gt; </a>]</td>
 
217
<td valign="middle" align="left"> &nbsp; </td>
 
218
<td valign="middle" align="left"> &nbsp; </td>
 
219
<td valign="middle" align="left"> &nbsp; </td>
 
220
<td valign="middle" align="left"> &nbsp; </td>
 
221
<td valign="middle" align="left">[<a href="maxima.html#SEC_Top" title="Cover (top) of document">Top</a>]</td>
 
222
<td valign="middle" align="left">[<a href="maxima_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
 
223
<td valign="middle" align="left">[<a href="maxima_78.html#SEC302" title="Index">Index</a>]</td>
 
224
<td valign="middle" align="left">[<a href="maxima_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
 
225
</tr></table>
 
226
 
 
227
<a name="SEC279"></a>
 
228
<h2 class="section"> 71.2 Funciones y variables para solve_rec </h2>
 
229
 
 
230
 
 
231
<dl>
 
232
<dt><u>Funci&oacute;n:</u> <b>reduce_order</b><i> (<var>rec</var>, <var>sol</var>, <var>var</var>)</i>
 
233
<a name="IDX2297"></a>
 
234
</dt>
 
235
<dd><p>Reduce el orden de la expresi&oacute;n recurrente lineal <var>rec</var> cuando
 
236
se conoce una soluci&oacute;n particular <var>sol</var>. La recurrencia
 
237
reducida puede utilizarse para obterner m&aacute;s soluciones.
 
238
</p>
 
239
<p>Ejemplo:
 
240
</p>
 
241
<pre class="example">(%i3) rec: x[n+2] = x[n+1] + x[n]/n;
 
242
                                      x
 
243
                                       n
 
244
(%o3)               x      = x      + --
 
245
                     n + 2    n + 1   n
 
246
(%i4) solve_rec(rec, x[n]);
 
247
WARNING: found some hypergeometrical solutions! 
 
248
(%o4)                    x  = %k  n
 
249
                          n     1
 
250
(%i5) reduce_order(rec, n, x[n]);
 
251
(%t5)                    x  = n %z
 
252
                          n       n
 
253
 
 
254
                           n - 1
 
255
                           ====
 
256
                           \
 
257
(%t6)                %z  =  &gt;     %u
 
258
                       n   /        %j
 
259
                           ====
 
260
                           %j = 0
 
261
 
 
262
(%o6)             (- n - 2) %u     - %u
 
263
                              n + 1     n
 
264
(%i6) solve_rec((n+2)*%u[n+1] + %u[n], %u[n]);
 
265
                                     n
 
266
                            %k  (- 1)
 
267
                              1
 
268
(%o6)                 %u  = ----------
 
269
                        n    (n + 1)!
 
270
 
 
271
So the general solution is
 
272
 
 
273
             n - 1
 
274
             ====        j
 
275
             \      (- 1)
 
276
       %k  n  &gt;    -------- + %k  n
 
277
         2   /     (j + 1)!     1
 
278
             ====
 
279
             j = 0
 
280
</pre>
 
281
</dd></dl>
 
282
 
 
283
<dl>
 
284
<dt><u>Variable opcional:</u> <b>simplify_products</b>
 
285
<a name="IDX2298"></a>
 
286
</dt>
 
287
<dd><p>Valor por defecto: <code>true</code>
 
288
</p>
 
289
<p>Si <code>simplify_products</code> vale <code>true</code>, <code>solve_rec</code> intentar&aacute;
 
290
simplificar los productos del resultado.
 
291
</p>
 
292
<p>V&eacute;ase tambi&eacute;n <code>solve_rec</code>.
 
293
</p>
 
294
</dd></dl>
 
295
 
 
296
 
 
297
 
 
298
<dl>
 
299
<dt><u>Funci&oacute;n:</u> <b>simplify_sum</b><i> (<var>expr</var>)</i>
 
300
<a name="IDX2299"></a>
 
301
</dt>
 
302
<dd><p>Intenta reducir todas las sumas que aparecen en <var>expr</var> a una forma
 
303
cerrada.
 
304
</p>
 
305
<p>Para utilizar esta funci&oacute;n c&aacute;rguese previamente el paquete <code>simplify_sum</code>
 
306
ejecutando la instrucci&oacute;n <code>load(simplify_sum)</code>.
 
307
</p>
 
308
<p>Ejemplo:
 
309
</p>
 
310
<pre class="example">(%i1) load(&quot;simplify_sum&quot;)$
 
311
(%i2) sum(binom(n+k,k)/2^k, k, 0, n) + 
 
312
          sum(binom(2*n, 2*k), k, 0, n);
 
313
         n                            n
 
314
        ====                         ====
 
315
        \      binomial(n + k, k)    \
 
316
(%o2)    &gt;     ------------------ +   &gt;    binomial(2 n, 2 k)
 
317
        /               k            /
 
318
        ====           2             ====
 
319
        k = 0                        k = 0
 
320
(%i3) simplify_sum(%);
 
321
                               n
 
322
                              4     n
 
323
(%o3)                         -- + 2
 
324
                              2
 
325
</pre>
 
326
</dd></dl>
 
327
 
 
328
 
 
329
<dl>
 
330
<dt><u>Funci&oacute;n:</u> <b>solve_rec</b><i> (<var>eqn</var>, <var>var</var>, [<var>init</var>])</i>
 
331
<a name="IDX2300"></a>
 
332
</dt>
 
333
<dd><p>Obtiene las soluciones hipergeom&eacute;tricas de la expresi&oacute;n recurrente <var>eqn</var>
 
334
con coeficientes lineales en la variable <var>var</var>. Los argumentos opcionales
 
335
<var>init</var> son condiciones iniciales.
 
336
</p>
 
337
<p>La funci&oacute;n <code>solve_rec</code> puede resolver expresiones recurrentes con
 
338
coeficientes constantes, encuentra soluciones hipergeom&eacute;tricas de
 
339
expresiones recurrentes lineales homog&eacute;neas con coeficientes 
 
340
polinomiales, obtiene soluciones racionales de expresiones recurrentes
 
341
lineales con coeficientes lineales y resuelve tambi&eacute;n expresiones
 
342
recurrentes de Ricatti.
 
343
</p>
 
344
<p>N&oacute;tese que el tiempo de ejecuci&oacute;n del algoritmo para encontrar soluciones 
 
345
hipergeom&eacute;tricas es exponencial respecto del grado del coeficiente principal.
 
346
</p>
 
347
<p>Para hacer uso de esta funci&oacute;n ejec&uacute;tese previamente <code>load(solve_rec);</code>.
 
348
</p>
 
349
<p>Ejemplo de recurrencia lineal con coeficientes constantes:
 
350
</p>
 
351
<pre class="example">(%i2) solve_rec(a[n]=a[n-1]+a[n-2]+n/2^n, a[n]);
 
352
                        n          n
 
353
           (sqrt(5) - 1)  %k  (- 1)
 
354
                            1           n
 
355
(%o2) a  = ------------------------- - ----
 
356
       n               n                  n
 
357
                      2                5 2
 
358
                                                n
 
359
                                   (sqrt(5) + 1)  %k
 
360
                                                    2    2
 
361
                                 + ------------------ - ----
 
362
                                            n              n
 
363
                                           2            5 2
 
364
</pre>
 
365
<p>Ejemplo de recurrencia lineal con coeficientes polinomiales:
 
366
</p>
 
367
<pre class="example">(%i7) 2*x*(x+1)*y[x] - (x^2+3*x-2)*y[x+1] + (x-1)*y[x+2];
 
368
                         2
 
369
(%o7) (x - 1) y      - (x  + 3 x - 2) y      + 2 x (x + 1) y
 
370
               x + 2                   x + 1                x
 
371
(%i8) solve_rec(%, y[x], y[1]=1, y[3]=3);
 
372
                              x
 
373
                           3 2    x!
 
374
(%o9)                 y  = ---- - --
 
375
                       x    4     2
 
376
</pre>
 
377
<p>Ejemplo de recurrencia de Ricatti:
 
378
</p>
 
379
<pre class="example">(%i2) x*y[x+1]*y[x] - y[x+1]/(x+2) + y[x]/(x-1) = 0;
 
380
                            y         y
 
381
                             x + 1     x
 
382
(%o2)         x y  y      - ------ + ----- = 0
 
383
                 x  x + 1   x + 2    x - 1
 
384
(%i3) solve_rec(%, y[x], y[3]=5)$
 
385
(%i4) ratsimp(minfactorial(factcomb(%)));
 
386
                                   3
 
387
                               30 x  - 30 x
 
388
(%o4) y  = - -------------------------------------------------
 
389
       x        6      5       4       3       2
 
390
             5 x  - 3 x  - 25 x  + 15 x  + 20 x  - 12 x - 1584
 
391
</pre>
 
392
 
 
393
<p>V&eacute;anse tambi&eacute;n <code>solve_rec_rat</code>, <code>simplify_products</code> y <code>product_use_gamma</code>.
 
394
</p>
 
395
</dd></dl>
 
396
 
 
397
<dl>
 
398
<dt><u>Funci&oacute;n:</u> <b>solve_rec_rat</b><i> (<var>eqn</var>, <var>var</var>, [<var>init</var>])</i>
 
399
<a name="IDX2301"></a>
 
400
</dt>
 
401
<dd><p>Calcula las soluciones racionales de las expresiones recurrentes lineales. 
 
402
V&eacute;ase <code>solve_rec</code> para la descripci&oacute;n de sus argumentos.
 
403
</p>
 
404
<p>Para hacer uso de esta funci&oacute;n ejec&uacute;tese previamente <code>load(solve_rec);</code>.
 
405
</p>
 
406
<p>Ejemplo:
 
407
</p>
 
408
<pre class="example">(%i1) (x+4)*a[x+3] + (x+3)*a[x+2] - x*a[x+1] + (x^2-1)*a[x];
 
409
(%o1)  (x + 4) a      + (x + 3) a      - x a
 
410
                x + 3            x + 2      x + 1
 
411
                                                   2
 
412
                                               + (x  - 1) a
 
413
                                                            x
 
414
(%i2) solve_rec_rat(% = (x+2)/(x+1), a[x]);
 
415
                       1
 
416
(%o2)      a  = ---------------
 
417
            x   (x - 1) (x + 1)
 
418
</pre>
 
419
<p>V&eacute;ase tambi&eacute;n <code>solve_rec</code>.
 
420
</p>
 
421
</dd></dl>
 
422
 
 
423
<dl>
 
424
<dt><u>Variable opcional:</u> <b>product_use_gamma</b>
 
425
<a name="IDX2302"></a>
 
426
</dt>
 
427
<dd><p>Valor por defecto:<code>true</code> 
 
428
</p>
 
429
<p>Si <code>product_use_gamma</code> vale <code>true</code>,  <code>solve_rec</code>
 
430
introduce la funci&oacute;n gamma en la expresi&oacute;n del resultado
 
431
cuando se simplifican productos.
 
432
</p>
 
433
<p>V&eacute;anse tambi&eacute;n <code>simplify_products</code> y <code>solve_rec</code>.
 
434
</p>
 
435
</dd></dl>
 
436
 
 
437
<dl>
 
438
<dt><u>Funci&oacute;n:</u> <b>summand_to_rec</b><i> (<var>summand</var>, <var>k</var>, <var>n</var>)</i>
 
439
<a name="IDX2303"></a>
 
440
</dt>
 
441
<dd><p>Devuelve la expresi&oacute;n recurrente que satisface la suma
 
442
</p>
 
443
<pre class="example">    inf
 
444
    ====
 
445
    \
 
446
     &gt;     sumando
 
447
    /
 
448
    ====
 
449
  k = minf
 
450
</pre>
 
451
<p>donde el sumando es hipergeom&eacute;trico en  <var>k</var> y <var>n</var>.
 
452
</p>
 
453
<p>Para hacer uso de esta funci&oacute;n deben cargarse previamente los paquetes
 
454
<code>zeilberger</code> y <code>solve_rec</code> mediante la ejecuci&oacute;n de las sentencias
 
455
<code>load(solve_rec)</code> y <code>load(zeilberger)</code>.
 
456
</p>
 
457
<pre class="example">(%i17) load(&quot;zeilberger&quot;)$
 
458
(%i18) summand: binom(3*k+1,k)*binom(3*(n-k),n-k)/(3*k+1)$
 
459
(%i19) summand_to_rec(summand, k, n);
 
460
Dependent equations eliminated:  (3 2)
 
461
(%o19) - 4 (n + 2) (2 n + 3) (2 n + 5) sm
 
462
                                         n + 2
 
463
                    2
 
464
 + 12 (2 n + 3) (9 n  + 27 n + 22) sm
 
465
                                     n + 1
 
466
 - 81 (n + 1) (3 n + 2) (3 n + 4) sm
 
467
                                    n
 
468
(%i21) sum(''summand, k, 0, n), n=0;
 
469
(%o21)                       1
 
470
(%i22) sum(''summand, k, 0, n), n=1;
 
471
(%o22)                       4
 
472
(%i23) product_use_gamma: false$
 
473
(%i24) solve_rec(%o19, sm[n], sm[0]=1, sm[1]=4);
 
474
              n - 1               n - 1
 
475
              /===\               /===\
 
476
               ! !                 ! !                n
 
477
             ( ! !   (3 %j + 2)) ( ! !   (3 %j + 4)) 3
 
478
               ! !                 ! !
 
479
              %j = 0              %j = 0
 
480
(%o24) sm  = ------------------------------------------
 
481
         n            n - 1
 
482
                      /===\
 
483
                       ! !                n
 
484
                     ( ! !   (2 %j + 3)) 2  n!
 
485
                       ! !
 
486
                      %j = 0
 
487
</pre>
 
488
</dd></dl>
 
489
 
 
490
<hr size="6">
 
491
<table cellpadding="1" cellspacing="1" border="0">
 
492
<tr><td valign="middle" align="left">[<a href="#SEC277" title="Beginning of this chapter or previous chapter"> &lt;&lt; </a>]</td>
 
493
<td valign="middle" align="left">[<a href="maxima_72.html#SEC280" title="Next chapter"> &gt;&gt; </a>]</td>
 
494
<td valign="middle" align="left"> &nbsp; </td>
 
495
<td valign="middle" align="left"> &nbsp; </td>
 
496
<td valign="middle" align="left"> &nbsp; </td>
 
497
<td valign="middle" align="left"> &nbsp; </td>
 
498
<td valign="middle" align="left"> &nbsp; </td>
 
499
<td valign="middle" align="left">[<a href="maxima.html#SEC_Top" title="Cover (top) of document">Top</a>]</td>
 
500
<td valign="middle" align="left">[<a href="maxima_toc.html#SEC_Contents" title="Table of contents">Contents</a>]</td>
 
501
<td valign="middle" align="left">[<a href="maxima_78.html#SEC302" title="Index">Index</a>]</td>
249
502
<td valign="middle" align="left">[<a href="maxima_abt.html#SEC_About" title="About (help)"> ? </a>]</td>
250
503
</tr></table>
251
504
<p>
252
505
 <font size="-1">
253
 
  This document was generated by <em>Robert Dodier</em> on <em>agosto, 25 2007</em> using <a href="http://texi2html.cvshome.org/"><em>texi2html 1.76</em></a>.
 
506
  This document was generated by <em>Robert Dodier</em> on <em>diciembre, 14 2008</em> using <a href="http://texi2html.cvshome.org/"><em>texi2html 1.76</em></a>.
254
507
 </font>
255
508
 <br>
256
509