File: algorithms-transforms.chapt.txt

package info (click to toggle)
yacas 1.3.6-2
  • links: PTS
  • area: main
  • in suites: bullseye, buster, sid, stretch
  • size: 7,176 kB
  • ctags: 3,520
  • sloc: cpp: 13,960; java: 12,602; sh: 11,401; makefile: 552; perl: 517; ansic: 381
file content (82 lines) | stat: -rw-r--r-- 2,829 bytes parent folder | download | duplicates (6)
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

		Transforms

Currently the only tranform defined is {LaplaceTransform},
which has the calling convention:

*	LaplaceTransform(var1,var2,func)

It has been setup much like the integration algorithm. 
If the transformation algorithm cannot perform the transform, the
expression (in theory) is returned unsimplified. Some cases
may still erroneously return {Undefined} or {Infinity}.

	    The {LaplaceTransform} algorithm

This section describes the steps taken in doing a Laplace 
transform.

	    General structure

{LaplaceTransform} is immediately handed off to {LapTran}.
This is done because if the last {LapTran} rule is met, the
Laplace transform couldn't be found and it can then return
{LaplaceTransform} unevaluated.

	    Operational Properties

The first rules that are matched against utilize the various
operational properties of {LaplaceTransform}, such as: 

*	Linearity Properties
*	Shift properties, i.e. multiplying the function by an exponential
*	$ y * x^n = (-1)^n * Deriv(x,n) LaplaceTransform(x,x[2],y) $
*	$ y/x = Integrate(x[2],x[2],Infinity) LapTran(x,x[2],y) $


The last operational property dealing with integration is not
yet fully bug-tested, it sometimes returns {Undefined} or {Infinity}
if the integral returns such. 

	    Transform tables

For elementary functions, Yacas uses transform tables. For instance,
the fact that the Laplace transform of $ Cos(t) $ is $ s/(s^2+1) $ is
declared in a transform table.

For the purpose of setting up the transform table, a few
declaration functions have been defined, which use some
generalized pattern matchers to be more flexible in recognizing
expressions that are transformable.

	    Transforming simple functions 

For functions like $ Sin(t) $ the transform can be declared
with the function {LapTranDef}. 

The calling sequence for {LapTranDef} is

	LapTranDef( in, out )

Currently {in} must be a variable of {_t} and {out} must be a function
of {s}.
For instance, for the function $ Cos(t) $ there is a declaration:

	LapTranDef( Cos(_t),                    s/(s^2+1) );

The fact that the first argument is a pattern means that each
occurrence of the variable to be matched should be referred
to as {_t}, as in the example above.

{LapTranDef} generalizes the transform implicitly, in that it will
set up the system to actually recognize expressions of the form
$ Cos(a*t) $ and $Cos(t/a)$ , and return the appropriate answer.
The way this is done is by three separate rules for case of {t} itself,
{a*t} and {t/a}. This is similar to the {MatchLinear} function that 
{Integrate} uses, except {LaplaceTransforms} must have {b=0}.

	    Further Directions

Currenlty $Sin(t)*Cos(t)$ cannot be transformed, because it requires
a convolution integral. This will be implemented soon. The inverse
laplace transform will be implement soon also.