"Source: Text/Geometry/AlgSrf.text";
"Line: 2000";
"Date: Thu Sep 25 14:47:45 2025";
"Main: Fri Sep 26 14:29:19 2025";
// original file: Text/Geometry/AlgSrf.text, line: 2000
// Example: H126E10 ()
print "Example: H126E10";
ei := GetEchoInput();
SetEchoInput(true);
P5<a,b,c,d,e,f> := ProjectiveSpace(Rationals(),5);
S := Surface(P5,[b^2-a*d, b*c-a*f, c^2-b*e, c*d-b*f, d*e-c*f]);
HasOnlySimpleSingularities(S : ReturnList := true); 
dsds := ResolveSingularSurface(S);
#dsds; //one for each singular point
[NumberOfBlowUpDivisors(dsd) : dsd in dsds];
// First dsd corresponds to the A2.
dsd := dsds[1];
SingularPoint(dsd);
Da,Sa,prj := BlowUpDivisor(S, dsd, 1);
Da; Ambient(Da);
Sa; // blow-up surface patch is just A^2!
prj; //typical blow-up map!
// get patch cover of the full blow-up divisor D, which is just P^1
lst := BlowUpDivisorAllPatches(dsd, 1);
#lst; //2 patch cover
D1 := lst[1][1]; D2 := lst[2][1];
mp12 := Restriction(Expand(lst[1][3] * Inverse(lst[2][3])),D1,D2);
A1<x,y> := Ambient(D1); A2<x,y> := Ambient(D2);
// D1 and D2 are both the line x=0 in an affine plane. The rational map
// between them equates to the usual y -> 1/y
D1; D2; mp12;
SetEchoInput(ei);
