Description
Uses Newton's method to correct the given solutions so that the resulting approximation has its estimated relative error bounded by min(
ErrorTolerance,2^(-
Bits)). The number of iterations made is at most
Iterations.
i1 : R = CC[x];
|
i2 : F = polySystem {x^2-2};
|
i3 : P := refine(F, point{{1.5+0.001*ii}}, Bits=>1000)
o3 = {1.41421}
o3 : Point
|
i4 : first coordinates P
o4 = 1.4142135623730950488016887242096980785696718753769480731766797379907324
784621070388503875343276415727350138462309122970249248360558507372126441
214970999358314132226659275055927557999505011527820605714701095599716059
702745345968620147285174186408891986095523292304843087143214508397626036
2799525140799
o4 : CC (of precision 1002)
|
i5 : R = CC[x,y];
|
i6 : T = {x^2+y^2-1, x*y};
|
i7 : sols = { {1.1,-0.1}, {0.1,1.2} };
|
i8 : refine(T, sols, Software=>M2, ErrorTolerance=>.001, Iterations=>10)
o8 = {{1, -2.17629e-17}, {7.01931e-15, 1}}
o8 : List
|
In case of a singular (multiplicity>1) solution, while
solveSystem and
track return the end of the homotopy paths marked as a 'failure', it is possible to improve the quality of approximation with
refine. The resulting point will be marked as singular:
i9 : R = CC[x,y];
|
i10 : S = {x^2-1,y^2-1};
|
i11 : T = {x^2+y^2-1, (x-y)^2};
|
i12 : solsS = {(1,1),(-1,-1)};
|
i13 : solsT = track(S,T,solsS)
o13 = {[M,t=.999998], [M,t=.999998]}
o13 : List
|
i14 : solsT / coordinates
o14 = {{.70667, .707543}, {-.70667, -.707543}}
o14 : List
|
i15 : refSols = refine(T, solsT)
o15 = {(.707107, .707107), (-.707107, -.707107)}
o15 : List
|
i16 : refSols / status
o16 = {Singular, Singular}
o16 : List
|
The failure to complete the refinement procedure is indicated by warning messages and the resulting point is displayed as
[R].
i17 : R = CC[x];
|
i18 : F = polySystem {x^2-2};
|
i19 : Q := refine(F, point{{1.5+0.001*ii}}, Bits=>1000, Iterations=>2)
o19 = [RF]
o19 : Point
|
i20 : peek Q
o20 = Point{cache => CacheTable{...4...}}
Coordinates => {1.41422}
|