Opened 18 months ago
Last modified 4 weeks ago
#30290 new defect
Implement better composition of curves
Reported by: | tscrim | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | sage-9.6 |
Component: | manifolds | Keywords: | |
Cc: | egourgoulhon, gh-mjungmath | Merged in: | |
Authors: | Reviewers: | ||
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description (last modified by )
I would like to reparameterize a curve, but the natural way I wanted to try, I cannot.
sage: E.<x,y,z> = EuclideanSpace(3) sage: R.<t> = RealLine() sage: alpha = E.curve((cos(t), sin(t), t/(2*pi)), (t, 0, 2*pi)) sage: I = alpha.domain() sage: J = R.open_interval(2*pi, 6*pi) sage: h = J.continuous_map(I, ((t-2*pi)/2,), name='h') sage: h.display() # This is trac #30289 h: (2*pi, 6*pi) --> (0, 2*pi) t |--> sage: alpha * h --------------------------------------------------------------------------- ValueError Traceback (most recent call last) <ipython-input-86-2c9a47c13590> in <module>() ----> 1 alpha * h /home/uqtscrim/sage/local/lib/python3.7/site-packages/sage/categories/map.pyx in sage.categories.map.Map.__mul__ (build/cythonized/sage/categories/map.c:7558)() 895 if right.codomain() != self.domain(): 896 raise TypeError("self (=%s) domain must equal right (=%s) codomain" % (self, right)) --> 897 return self._composition(right) 898 899 def _composition(self, right): /home/uqtscrim/sage/local/lib/python3.7/site-packages/sage/categories/map.pyx in sage.categories.map.Map._composition (build/cythonized/sage/categories/map.c:7729)() 935 """ 936 category = self.category_for()._meet_(right.category_for()) --> 937 H = homset.Hom(right.domain(), self._codomain, category) 938 return self._composition_(right, H) 939 /home/uqtscrim/sage/local/lib/python3.7/site-packages/sage/categories/homset.py in Hom(X, Y, category, check) 417 # available for the following error message. It simply 418 # belongs to the wrong category. --> 419 raise ValueError("{} is not in {}".format(O, category)) 420 421 # Construct H ValueError: Euclidean space E^3 is not in Join of Category of subobjects of sets and Category of smooth manifolds over Real Field with 53 bits of precision
I can hack around this by doing
sage: beta = alpha._composition_(h, Hom(J, E)) sage: beta.display() (2*pi, 6*pi) --> E^3 t |--> (x, y, z) = (-cos(1/2*t), sin(1/2*t), 1/4*(2*pi - t)/pi)
but this is less than ideal.
Change History (5)
comment:1 Changed 18 months ago by
- Description modified (diff)
comment:2 Changed 17 months ago by
- Milestone changed from sage-9.2 to sage-9.3
comment:3 Changed 11 months ago by
- Milestone changed from sage-9.3 to sage-9.4
comment:4 Changed 5 months ago by
- Milestone changed from sage-9.4 to sage-9.5
comment:5 Changed 4 weeks ago by
- Milestone changed from sage-9.5 to sage-9.6
Note: See
TracTickets for help on using
tickets.
Setting new milestone based on a cursory review of ticket status, priority, and last modification date.