I want to fill the area between an f(x) functions and an f(y) function. This is what I have so far:
\documentclass{article}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{tikz,bm}
\usepackage{pgfplots}
\pgfplotsset{compat=newest}
\usepgfplotslibrary{fillbetween}
\usetikzlibrary{intersections}
\begin{document}
\pgfplotsset{
standard/.style={
axis line style = thick,
grid = major,
trig format=rad,
enlargelimits,
axis x line=middle,
axis y line=middle,
axis line style={latex-latex},
enlarge x limits=0.15,
enlarge y limits=0.15,
every axis x label/.style={at={(current axis.right of origin)},anchor=north west},
every axis y label/.style={at={(current axis.above origin)},anchor=south east},
}
}
\begin{center}
\begin{tikzpicture}
\begin{axis}[standard,
xtick={-4,-3,-2,...,6},
ytick={-3,-2,...,4},
xticklabels={-4, ,-2, ,0, ,2, ,4, ,6},
yticklabels={,-2, , , ,2, ,4},
xlabel={$x$},
ylabel={$y$},
samples=100,
xmin=-3, xmax=5,
ymin=-3, ymax=4]
\addplot[name path=f, smooth, ultra thick, domain={-4:5}] ((x^2/2)-3,x);
\node at (-2,3) {$y^2=2x+6$};
\addplot[name path=g, smooth, ultra thick, domain={-3:6}]{x-1} node[right,pos=0.5] {$y=x-1$};
\addplot[fill=black,fill opacity=0.1]fill between[of=f and g, soft clip={domain=-3:4}];
\node at (0.5,1.5) {$\mathbf{D}$};
\end{axis}
\end{tikzpicture}
\end{center}
\end{document}
I want to only fill the region labeled D. How would I go about doing this?