# Filling graph between lines and plots

I would like to create a filling delineated by the plots and lines as specified below:

f[x_] := x

f2[x_] := x - (1/6)

f3[x_] := x + (1/6)

line1 = Line[{{10, 0}, {10, 10}}];

line2 = Line[{{0, 10}, {10, 10}}];

line3 = Line[{{9, 9}, {10, 9}}];

lineStyle = {Thick, Black, Dashed};

Plot[{f[x], f2[x], f3[x]}, {x, 9, 10},
Epilog -> {Directive[lineStyle], line1, line2, line3}]


I suppose a better way would probably be to transform the vertical lines into actual plots somehow. Any help?

Thanks.

## 2 Answers

It is not clear how you want the filling done. Here is one filling.

f[x_] := x
f2[x_] := x - (1/6)
f3[x_] := x + (1/6)

line1 = Line[{{10, 0}, {10, 10}}];
line2 = Line[{{0, 10}, {10, 10}}];
line3 = Line[{{9, 9}, {10, 9}}];

lineStyle = {Thick, Black, Dashed};

Plot[{f[x], f2[x], f3[x]}, {x, 9, 10},
Epilog -> {Directive[lineStyle], line1, line2, line3},
Filling -> {
3 -> {10, {LightGreen, Darker[Green]}},
2 -> {9, {Darker[Orange], LightOrange}}}] Also

Plot[{9, 10, f1[x], f2[x], f3[x]}, {x, 9, 10},
Epilog -> {Directive[lineStyle], line1, line2, line3},
Filling -> {{5 -> {{2}, {Blue, Green}}}, {4 -> {{1}, {Red, Orange}}}},
BaseStyle -> Thick] 