Annotation of OpenXM_contrib/PHC/Ada/Homotopy/homotopy.ads, Revision 1.1
1.1 ! maekawa 1: with Standard_Complex_Numbers; use Standard_Complex_Numbers;
! 2: with Standard_Complex_Vectors; use Standard_Complex_Vectors;
! 3: with Standard_Complex_Matrices; use Standard_Complex_Matrices;
! 4: with Standard_Complex_Poly_Systems; use Standard_Complex_Poly_Systems;
! 5:
! 6: package Homotopy is
! 7:
! 8: -- DESCRIPTION :
! 9: -- This package provides implementation of cheater's homotopy.
! 10:
! 11: -- CONSTRUCTORS :
! 12:
! 13: procedure Create ( p,q : in Poly_Sys; k : in positive;
! 14: a : in Complex_Number );
! 15:
! 16: -- DESCRIPTION :
! 17: -- The following artificial-parameter homotopy is build :
! 18: -- H(x,t) = a * ((1 - t)^k) * q + (t^k) * p.
! 19:
! 20: procedure Create ( p,q : in Poly_Sys; k : in positive; a : in Vector );
! 21:
! 22: -- DESCRIPTION :
! 23: -- This operation is similar to the Create above, except for the fact
! 24: -- that every equation can have a different random constant.
! 25:
! 26: procedure Create ( p,q : in Poly_Sys; k : in positive; a,b : in Vector;
! 27: linear : in boolean );
! 28:
! 29: -- DESCRIPTION :
! 30: -- If linear, then the following artificial-parameter homotopy is build :
! 31: -- H(i)(x,t) = a(i) * ((1 - t)^k) * q(i) + b(i)(t^k) * p(i),
! 32: -- for i in p'range.
! 33: -- Otherwise, if not linear, then
! 34: -- H(i)(x,t)
! 35: -- = (1-[t-t*(1-t)*a(i)])^k * q(i) + (t - t*(1-t)*b(i))^k * p(i),
! 36: -- for i in p'range.
! 37:
! 38: procedure Create ( p : in Poly_Sys; k : in integer );
! 39:
! 40: -- DESCRIPTION :
! 41: -- Given a polynomial system p with dimension n*(n+1) and
! 42: -- k an index, then t = x_k as continuation parameter.
! 43:
! 44: -- SELECTOR :
! 45:
! 46: function Homotopy_System return Poly_Sys;
! 47:
! 48: -- DESCRIPTION :
! 49: -- Returns the homotopy system in the unknowns (x,t).
! 50:
! 51: -- SYMBOLIC ROUTINES :
! 52:
! 53: function Eval ( t : Complex_Number ) return Poly_Sys;
! 54:
! 55: -- DESCRIPTION :
! 56: -- The homotopy is evaluated in t and a polynomial system is returned
! 57:
! 58: function Diff ( t : Complex_Number ) return Poly_Sys;
! 59:
! 60: -- DESCRIPTION :
! 61: -- The homotopy is symbolically differentiated w.r.t. t.
! 62:
! 63: -- NUMERIC ROUTINES :
! 64:
! 65: function Eval ( x : Vector; t : Complex_Number ) return Vector;
! 66:
! 67: -- DESCRIPTION :
! 68: -- The homotopy is evaluated in x and t and a vector is returned.
! 69:
! 70: function Diff ( x : Vector; t : Complex_Number ) return Vector;
! 71:
! 72: -- DESCRIPTION :
! 73: -- The homotopy is differentiated wr.t. t and is evaluated in (x,t).
! 74:
! 75: function Diff ( x : Vector; t : Complex_Number ) return matrix;
! 76:
! 77: -- DESCRIPTION :
! 78: -- The homotopy is differentiated to x and the Jacobi matrix
! 79: -- of H(x,t) is returned.
! 80:
! 81: function Diff ( x : Vector; t : Complex_Number; k : natural ) return Vector;
! 82:
! 83: -- DESCRIPTION :
! 84: -- The returning vector contains all derivatives from the homotopy
! 85: -- to the unknown x_k; note that t = x_n+1.
! 86:
! 87: function Diff ( x : Vector; t : Complex_Number; k : natural ) return matrix;
! 88:
! 89: -- DESCRIPTION :
! 90: -- The Jacobi matrix of the homotopy is returned where the kth
! 91: -- column has been deleted; note that Diff(x,t,n+1) = Diff(x,t).
! 92:
! 93: -- DESTRUCTOR :
! 94:
! 95: procedure Clear;
! 96:
! 97: -- DESCRIPTION :
! 98: -- The homotopy is cleared.
! 99:
! 100: end Homotopy;
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>