Tip:
Highlight text to annotate it
X
In this mathcast we show how to use the GeoGebra function Function to create a function defined
and drawn only a specific interval. That is, we wish to define the restriction of a function.
We are going to use tangent for our function. Let us first define the entire tangent function
tan(x). We click in the Input bar and we type tan(x) and because this is a math function
and not a GeoGebra function we use parenthesis of x and we hit Enter. We get the entire tangent
function defined on its entire domain. Now what we want to do is just get this one
branch of tangent of x. In GeoGebra trigonometric functions are always
radians. So these are radians down here. So why don’t we change them to radian units.
So we right-click in any blank space on the drawing. Select Drawing pad. We have the x-axis
here, we go to Distance and then on the down arrow and select pi/2. Now the tick marks
look like radians. Now what we want to do is find tangent of
x but only between x equal to minus pi halves and plus pi halves.
Let us hide f(x) for a moment ( using right-click and deselect “Show object”).
Go down to the Input bar again and now we type “function”. We can use a capital
or small letter. Automatically GeoGebra will find it. We start typing “fu”, and it’s
found it. We take our arrow keys to get between the brackets. We have three parameters. The
function, the left end of the interval and the right end of the interval. So the function
is again tan(x) and then the left side was minus pi halves. We can use the symbol pi
from here or we can just type pi over 2 and then another comma and then (plus) pi over
2. We hit Enter. We get only the one branch of tangent. And
it automatically gets the next letter in line which is g(x).
So g(x) is the restriction of tangent to the interval minus pi halves, plus pi halves.
Now we mention that if you use g(x) in any calculation it will automatically work on
the entire domain. So if we were to go down here in the input bar again and type h(x)=-g(x),
we are going to get everything. Let us take that away. This is what we have.
So g(x) is tan(x) on the interval minus pi halves to plus pi halves.