by caffeinemachine
Last Updated June 23, 2018 14:23 PM

I want to draw the following image in tikZ

Basically I want to draw the boundary of the unit square, plot the `x^2`

and `\sqrt x`

functions, and shade the area between them.

In my attempt to draw the two curves, I tried this

```
\usepackage{pgfplots}
\pgfplotsset{compat=1.10}
\usepgfplotslibrary{fillbetween}
\usetikzlibrary{patterns}
\pgfplotsset{ticks=none}
\begin{figure}[H]
\centering
\begin{tikzpicture}
\begin{axis}[axis lines=middle,]
\addplot[name path=F,black,domain={0:5}] {sqrt x};
\addplot[name path=G,black,domain={0:5}] {x^2};
\end{axis}
\end{tikzpicture}
\end{figure}
```

But the output I am getting is

Somehow the `\sqrt{x}`

function is getting flattened out.

Also, how to get rid of the arrows I have in the axes and make an enclosing box like I have in the hand-drawn picture.

- ServerfaultXchanger
- SuperuserXchanger
- UbuntuXchanger
- WebappsXchanger
- WebmastersXchanger
- ProgrammersXchanger
- DbaXchanger
- DrupalXchanger
- WordpressXchanger
- MagentoXchanger
- JoomlaXchanger
- AndroidXchanger
- AppleXchanger
- GameXchanger
- GamingXchanger
- BlenderXchanger
- UxXchanger
- CookingXchanger
- PhotoXchanger
- StatsXchanger
- MathXchanger
- DiyXchanger
- GisXchanger
- TexXchanger
- MetaXchanger
- ElectronicsXchanger
- StackoverflowXchanger
- BitcoinXchanger
- EthereumXcanger