@@ -311,7 +311,7 @@ def _an_element_(self):
311311        return  self .element_class (self , self ._A .an_element ())
312312
313313    @cached_method  
314-     def  basis (self ):
314+     def  basis (self )  ->   Family :
315315        """ 
316316        Return the basis of ``self``. 
317317
@@ -323,12 +323,13 @@ def basis(self):
323323            Lazy family (Term map(i))_{i in Free monoid on 3 generators (x, y, z)} 
324324        """ 
325325        B  =  self ._A .basis ()
326-         return  Family (B .keys (), lambda  x : self .element_class (self , B [x ]), name = "Term map" )
326+         return  Family (B .keys (),
327+                       lambda  x : self .element_class (self , B [x ]), name = "Term map" )
327328
328329    algebra_generators  =  basis 
329330
330331    # TODO: Keep this until we can better handle R.<...> shorthand 
331-     def  gens (self ) ->  tuple :
332+     def  gens (self ) ->  Family :
332333        """ 
333334        Return the generators of ``self``. 
334335
@@ -338,16 +339,16 @@ def gens(self) -> tuple:
338339            sage: C = CombinatorialFreeModule(QQ, ['x','y','z'], category=cat) 
339340            sage: J = JordanAlgebra(C) 
340341            sage: J.gens() 
341-             ( B['x'], B['y'], B['z'])  
342+             Finite family {'x':  B['x'], 'y':  B['y'], 'z':  B['z']}  
342343
343344            sage: F.<x,y,z> = FreeAlgebra(QQ) 
344345            sage: J = JordanAlgebra(F) 
345346            sage: J.gens() 
346347            Traceback (most recent call last): 
347348            ... 
348-             NotImplementedError: infinite set  
349+             Lazy family (Term map(i))_{i in Free monoid on 3 generators (x, y, z)}  
349350        """ 
350-         return  tuple ( self .algebra_generators () )
351+         return  self .algebra_generators ()
351352
352353    @cached_method  
353354    def  zero (self ):
@@ -741,7 +742,7 @@ def _coerce_map_from_base_ring(self):
741742        return  self ._generic_coerce_map (self .base_ring ())
742743
743744    @cached_method  
744-     def  basis (self ):
745+     def  basis (self )  ->   Family :
745746        """ 
746747        Return a basis of ``self``. 
747748
@@ -763,7 +764,7 @@ def basis(self):
763764
764765    algebra_generators  =  basis 
765766
766-     def  gens (self ) ->  tuple :
767+     def  gens (self ) ->  Family :
767768        """ 
768769        Return the generators of ``self``. 
769770
@@ -772,9 +773,9 @@ def gens(self) -> tuple:
772773            sage: m = matrix([[0,1],[1,1]]) 
773774            sage: J = JordanAlgebra(m) 
774775            sage: J.gens() 
775-             (1 + (0, 0), 0 + (1, 0), 0 + (0, 1)) 
776+             Family  (1 + (0, 0), 0 + (1, 0), 0 + (0, 1)) 
776777        """ 
777-         return  tuple ( self .algebra_generators () )
778+         return  self .algebra_generators ()
778779
779780    @cached_method  
780781    def  zero (self ):
@@ -1270,7 +1271,7 @@ def _test_multiplication_self_adjoint(self, **options):
12701271                    tester .assertEqual (val .imag_part (), zerO )
12711272
12721273    @cached_method  
1273-     def  basis (self ):
1274+     def  basis (self )  ->   Family :
12741275        r""" 
12751276        Return a basis of ``self``. 
12761277
@@ -1315,7 +1316,7 @@ def basis(self):
13151316
13161317    algebra_generators  =  basis 
13171318
1318-     def  gens (self ) ->  tuple :
1319+     def  gens (self ) ->  Family :
13191320        """ 
13201321        Return the generators of ``self``. 
13211322
@@ -1337,7 +1338,7 @@ def gens(self) -> tuple:
13371338            [ 0  0  k] 
13381339            [ 0 -k  0] 
13391340        """ 
1340-         return  tuple ( self .algebra_generators () )
1341+         return  self .basis ( )
13411342
13421343    @cached_method  
13431344    def  zero (self ):
0 commit comments