How can I shade an region of a graph using the graph function?

1 Answer
Write your answer here...
Start with a one sentence answer
Then teach the underlying concepts
Don't copy without citing sources


Write a one sentence answer...



Explain in detail...


I want someone to double check my answer

Describe your changes (optional) 200

Jan 16, 2018

Let's say I have the inequality #y>=x#. To show the boundary line, I can simply type "graph { x } " (no hashtags needed) and I'll get this:


To work with shading and multiple graphs, you need to change the format of what is graphed - essentially we add #y# terms to the graph, multiply the terms together (using brackets) and have the whole thing set to 0. And so with our example, I can write it as "graph { y-x=0 } " and get the same graph:


To shade, change the equal sign to an inequality. "graph { y-x>0 } " gives:


There are a number of existing answers that give more advanced tips on limiting graphs and shading, creating shaded shapes, and more. Here are a few:

Was this helpful? Let the contributor know!
Trending questions
Impact of this question
28 views around the world
You can reuse this answer
Creative Commons License