I want to fill the area cut off from an ellipse by a line segment. I want to fill the upper half. I don't know how to select the upper half.
import contour; import graph; size(7cm);
import patterns;
add("hatch",hatch(2.5mm));
string blank(real x) {return "";}
real labelscalefactor = 0.5; /* changes label-to-point distance */
pen dps = linewidth(0.7) + fontsize(10); defaultpen(dps); /* default pen style */
pen dotstyle = black; /* point style */
real xmin = -5.5, xmax = 6.86, ymin = -3.5, ymax = 3.9; /* image dimensions */
Label laxis; laxis.p = fontsize(10);
xaxis(xmin, xmax, Ticks(laxis,blank, Step = 1, Size = 2, NoZero),EndArrow(6), above = true);
yaxis(ymin, ymax, Ticks(laxis, blank, Step = 1, Size = 2, NoZero),EndArrow(6), above = true); /* draws axes; NoZero hides '0' label */
/* draw figures */
real implicitf1 (real x, real y) { return -1+0.1111111111111111*y^2+0.04000000000000001*x^2; }
guide[][] cf=contour(implicitf1, (xmin,ymin), (xmax,ymax), new real[]{0}, 500);
draw(cf[0][0], linewidth(1));
path p1=(-4,-1.8003469843683073)--(5,0);
draw(p1,linewidth(1));
path p2=buildcycle(p1,cf[0][0]);
/* dots and labels */
fill(p2,pattern("hatch"));
dot((-5,0),linewidth(4pt) + dotstyle);
label("$B$", (-4.960654545454545,0.07629427792915584), NE * labelscalefactor);
dot((5,0),linewidth(4pt) + dotstyle);
label("$C$", (5.039709090909089,0.07629427792915584), NE * labelscalefactor);
dot((0,-3),linewidth(4pt) + dotstyle);
label("$D$", (0.039527272727271814,-2.927792915531334), NE * labelscalefactor);
dot((0,3),linewidth(4pt) + dotstyle);
label("$E$", (0.039527272727271814,3.080381471389646), NE * labelscalefactor);
dot((-3.999566181385855,-1.8003469843683073),dotstyle);
label("$A$", (-3.9493818181818185,-1.7070844686648494), NE * labelscalefactor);
label("$f$", (0.5339272727272717,-1.0395095367847405), NE * labelscalefactor);
clip((xmin,ymin)--(xmin,ymax)--(xmax,ymax)--(xmax,ymin)--cycle);
/* end of picture */
With this code I get a figure with lower portion filled. I want the upper portion filled. How to do this?