if(!settings.multipleView) settings.batchView=false;
settings.tex="pdflatex";
settings.inlinetex=true;
deletepreamble();
defaultfilename="linear_algebra_I-1";
if(settings.render < 0) settings.render=4;
settings.outformat="";
settings.inlineimage=true;
settings.embed=true;
settings.toolbar=false;
viewportmargin=(2,2);

import graph;
size(200,0);
real f(real x) {return sqrt(1+x);}
pair F(real x) {return (x,f(x));}
real g(real x) {return -sqrt(1+x);}
pair G(real x) {return (x,g(x));}
real h(real x) {return -x/2-1;}
pair H(real x) {return (x,h(x));}
xaxis("$x$",xmin=-2,xmax=2.5,Arrow(HookHead,size=4));
yaxis("$y$",ymin=g(2.5),ymax=f(2.5),Arrow(HookHead,size=4));
draw(graph(f,-1,2.5,operator --),red+2);
draw(graph(g,-1,2.5,operator --),red+2);
draw(graph(h,-1.5,1.5,operator --),blue+2);
label("$y^2=1+x$",(0.2,1),SE);
label("$y=-\frac{1}{2}x-1$",H(-0.5),SW);
dot(G(0),black+5);
label("$(0,-1)$",G(0),NE);
