@@ -656,6 +656,8 @@ def _mul_(self, other_dynamical_semigroup):
656
656
...
657
657
TypeError: can only multiply dynamical semigroups with other dynamical semigroups of the same type
658
658
659
+ ::
660
+
659
661
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
660
662
sage: A.<z> = AffineSpace(QQ, 1)
661
663
sage: f1 = DynamicalSystem_projective([x, y], P)
@@ -1011,6 +1013,21 @@ def dehomogenize(self, n):
1011
1013
Defn: Defined on coordinates by sending (y) to
1012
1014
(y^2)
1013
1015
1016
+ ::
1017
+
1018
+ sage: P.<x,y> = ProjectiveSpace(QQ, 1)
1019
+ sage: f = DynamicalSystem([x, y], P)
1020
+ sage: g = DynamicalSystem([x^2, y^2], P)
1021
+ sage: d = DynamicalSemigroup((f, g))
1022
+ sage: d.dehomogenize(1)
1023
+ Dynamical semigroup over Affine Space of dimension 1 over Rational Field defined by 2 dynamical systems:
1024
+ Dynamical System of Affine Space of dimension 1 over Rational Field
1025
+ Defn: Defined on coordinates by sending (x) to
1026
+ (x)
1027
+ Dynamical System of Affine Space of dimension 1 over Rational Field
1028
+ Defn: Defined on coordinates by sending (x) to
1029
+ (x^2)
1030
+
1014
1031
TESTS::
1015
1032
1016
1033
sage: P.<x,y> = ProjectiveSpace(QQ, 1)
@@ -1020,15 +1037,17 @@ def dehomogenize(self, n):
1020
1037
sage: d.dehomogenize((1, 0))
1021
1038
Traceback (most recent call last):
1022
1039
...
1023
- ValueError: Dynamical System of Projective Space of dimension 1 over Rational Field
1024
- Defn: Defined on coordinates by sending (x : y) to
1025
- (x : y) dehomogenized at (1, 0) is not a `DynamicalSystem_affine` object
1040
+ ValueError: Scheme morphism:
1041
+ From: Affine Space of dimension 1 over Rational Field
1042
+ To: Affine Space of dimension 1 over Rational Field
1043
+ Defn: Defined on coordinates by sending (x) to
1044
+ (1/x) is not a `DynamicalSystem_affine` object
1026
1045
"""
1027
1046
new_systems = []
1028
1047
for ds in self .defining_systems ():
1029
1048
new_system = ds .dehomogenize (n )
1030
1049
if not isinstance (new_system , DynamicalSystem_affine ):
1031
- raise ValueError (str (ds ) + " dehomogenized at " + str ( n ) + " is not a `DynamicalSystem_affine` object" )
1050
+ raise ValueError (str (new_system ) + " is not a `DynamicalSystem_affine` object" )
1032
1051
new_systems .append (new_system )
1033
1052
return DynamicalSemigroup_affine (new_systems )
1034
1053
@@ -1134,12 +1153,20 @@ def homogenize(self, n):
1134
1153
Dynamical System of Projective Space of dimension 1 over Rational Field
1135
1154
Defn: Defined on coordinates by sending (x0 : x1) to
1136
1155
(x1^2 : x0^2)
1156
+
1157
+ TESTS::
1158
+
1159
+ sage: A.<x,y,z> = AffineSpace(QQ, 3)
1160
+ sage: f = DynamicalSystem([y^2, z^3, x^6], A)
1161
+ sage: g = DynamicalSystem([1 + x^7, y + z^2, x + 9], A)
1162
+ sage: d = DynamicalSemigroup((f, g))
1163
+ sage: d.homogenize((0, 1))
1137
1164
"""
1138
1165
new_systems = []
1139
1166
for ds in self .defining_systems ():
1140
1167
new_system = ds .homogenize (n )
1141
1168
if not isinstance (new_system , DynamicalSystem_projective ):
1142
- raise ValueError (str (ds ) + " homogenized at " + str ( n ) + " is not a `DynamicalSystem_projective` object" )
1169
+ raise ValueError (str (new_system ) + " is not a `DynamicalSystem_projective` object" )
1143
1170
new_systems .append (new_system )
1144
1171
return DynamicalSemigroup_projective (new_systems )
1145
1172
0 commit comments