Domain and range of functions

Heikki Höijer shared this question 2 years ago
Answered

Example:

f(x)=x+1, if x<0

f(x)=x+2, if x>=1

The domain of f is: "x<0 or x>=1"

The range of f is: "y<1 or y>=2"

What is the simplest way to draw the domain (on x-axis) and range (on y-axis)?

Command

if(-inf<f(x)<inf,0)

seems to work always, on all functions (domain on x-axis).

But command (for range on y-axis),

f(t)*(0,1)

At first it seems to work fine (after changing the values of t, if necessary). But later it will create error messages on some situations. After these erros, command a:X=f(t)*(0,1) was successful. This is very strange!

(By the way, here is again a letter, now X, with a special property - it cannot be replaced - it is like x, y, z and t!)

Here is my main problem: Reliable and easy way to draw the set: A = { (0,y) | y=f(x) for some x }

Comments (1)

photo
1

best way is locus

Files: foro.ggb
© 2020 International GeoGebra Institute