SOLUTION: 1) can you graph: f(x)= abs(2x-5) for 0<=x<=5 2) can you graph: f(x)= {x if x<=0 x+1 if x>0

Algebra ->  Absolute-value -> SOLUTION: 1) can you graph: f(x)= abs(2x-5) for 0<=x<=5 2) can you graph: f(x)= {x if x<=0 x+1 if x>0       Log On


   



Question 936735: 1) can you graph: f(x)= abs(2x-5) for 0<=x<=5
2) can you graph: f(x)= {x if x<=0
x+1 if x>0

Answer by Edwin McCravy(20056) About Me  (Show Source):
You can put this solution on YOUR website!
matrix%281%2C5%2C++%22f%28x%29%22%2C%22%22=%22%22%2Cabs%282x-5%29%2C+for%2C+0%3C=x%3C=5%29
To find the x-coordinate of the vertex, (the sharp point),
we set what's between the bars | | equal to 0. What's
between the bars is 2x-5, so we set that = 0

          2x-5 = 0
            2x = 5
             x = 2.5

To find the y-coordinate of the vertex (sharp point) we 
substitute that in the equation:

matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%282x-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%282%282.5%29-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%285-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%280%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2C0%29%29

So the vertex is (2.5,0)

Get two more points one on each side of the vertex,
May as well pick the endpoints of the domain  
0%3C=x%3C=5 using x = 0 on the left and x = 5
on the right:

matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%282x-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%282%280%29-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%280-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%28-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2C5%29%29

That's the point (0,5)

matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%282x-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%282%285%29-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%2810-5%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2Cabs%285%29%29
matrix%281%2C3%2C%22f%28x%29%22%2C%22%22=%22%22%2C5%29%29

That's the point (5,5)

So we plot the vertex (2.5,0), and endpoints (0,0) and (5,5)

The graph stops at (0,0) on the left and at (5,5) on the right

Since f(x) includes both endpoints, we draw a darkened circle
at each endpoint:



---------
f(x)= {x if x<=0 
x+1 if x>0

%22f%28x%29%22%22%22=%22%22system%28matrix%282%2C3%2C+x%2Cif%2Cx%3C=0%2Cx%2B1%2Cif%2Cx%3E0%29%29

Get a couple of points on the part where f(x) = y = x, say 
(-2,-2) and (-4,-4) and the endpoint (0,0)
and draw the line but stop it at 0 and draw a darkened circle to show
that it includes that since the "if" part is x%3C=0



But thats only half the graph.

Get a couple of points on the part where f(x) = y = x+1, say 
(1,2) and (2,3).  The right part of the graph will not include
the endpoint since the "if" part is x%3E0. However, we find 
what the endpoint would have been if it had been included
anyway, and draw an open circle there to indicate that it is 
not included.

If the right part had included the endpoint where x=0, it would have 
been at y=1+1 or y=2. So we draw an open circle at (0,2) and continue
the line to the right.  Here is the final graph. 







Edwin