Sponsored links: Algebra eBooks
 

Related

functions

Run Example
(%i1)F(x):=if (x<
=0) then 0 else if (x<
=1) then x^2 else 1;
                                                          2
(%o1)      F(x) := if x <= 0 then 0 else (if x <= 1 then x  else 1)
(%i2) diff(x^2, x);
(%o2)                                 2 x
(%i3) f(x):=if (x<
=0) then 0 else if (x<
=1) then 2*x else 0;
(%o3)      f(x) := if x <= 0 then 0 else (if x <= 1 then 2 x else 0)
(%i4) functions;
(%o4)                            [F(x), f(x)]
(%i5) plot2d(F(x), [x, -1, 2]);
plotplot2d(F(x), [x, -1, 2]);
Run Example
f_1 (x) := x - 100;
(%o1)                          f_1(x) := x - 100
(%i2)  f_2 (x, y) := x / y;
                                             x
(%o2)                           f_2(x, y) := -
                                             y
(%i3)  define (f_3 (x), sqrt (x));
(%o3)                          f_3(x) := sqrt(x)
(%i4)  g_1 [x] := x - 100;
(%o4)                           g_1  := x - 100
                                   x
(%i5)  g_2 [x, y] := x / y;
                                            x
(%o5)                            g_2     := -
                                    x, y    y
(%i6)  define (g_3 [x], sqrt (x));
(%o6)                           g_3  := sqrt(x)
                                   x
(%i7)  h_1 [x] (y) := x^y;
                                             y
(%o7)                            h_1 (y) := x
                                    x
(%i8)  functions;
(%o8)                     [f_1(x), f_2(x, y), f_3(x)]
(%i9)  arrays;
(%o9)                        [g_1, g_2, g_3, h_1]
(%i10) 
Run Example
F(x):=if (x<
=0) then 0 else if (x<
=1) then x^2 else 1;
                                                          2
(%o1)      F(x) := if x <= 0 then 0 else (if x <= 1 then x  else 1)
(%i2) diff(x^2, x);
(%o2)                                 2 x
(%i3) f(x):=if (x<
=0) then 0 else if (x<
=1) then 2*x else 0;
(%o3)      f(x) := if x <= 0 then 0 else (if x <= 1 then 2 x else 0)
(%i4) functions;
(%o4)                            [F(x), f(x)]
(%i5) plot2d(F(x), [x, -1, 2], [box, false]);
plotplot2d(F(x), [x, -1, 2], [box, false]);plot2d(f(x), [x, -1, 2]);
plotplot2d(f(x), [x, -1, 2]);

Related Help

Help for Functions