#4637: bug/stupid design of padic_printing.sep print mode stuff
---------------------------+------------------------------------------------
 Reporter:  was            |       Owner:  was       
     Type:  defect         |      Status:  new       
 Priority:  major          |   Milestone:  sage-3.2.1
Component:  number theory  |    Keywords:            
---------------------------+------------------------------------------------
 Consider this session:
 {{{
 bsd:padics was$ sage
 ----------------------------------------------------------------------
 | Sage Version 3.2.1.alpha2, Release Date: 2008-11-26                |
 | Type notebook() for the GUI, and license() for information.        |
 ----------------------------------------------------------------------
 sage: Qp(7, print_mode="digits")(1/3)
 ...44444444444444444445
 sage: padic_printing.sep('][')
 sage: Qp(7, print_mode="digits")(1/3)
 ...44444444444444444445
 sage: Qp(11, print_mode="digits")(1/3)
 ...73737373737373737374
 sage: Qp(17, print_mode="digits")(1/3)
 ...B5B5B5B5B5B5B5B5B5B6
 sage: Qp(97, print_mode="digits")(1/3)
 
...64][64][64][64][64][64][64][64][64][64][64][64][64][64][64][64][64][64][64][65
 sage: Qp(7, print_mode="digits")(1/3)
 ...44444444444444444445
 sage: Qp(389, print_mode="digits")(1/3)
 
...259][129][259][129][259][129][259][129][259][129][259][129][259][129][259][129][259][129][259][130
 sage: padic_printing.sep('|')
 sage: Qp(389, print_mode="digits")(1/3)
 
...259][129][259][129][259][129][259][129][259][129][259][129][259][129][259][129][259][129][259][130
 sage: Qp(997, print_mode="digits")(1/3)
 
...664|664|664|664|664|664|664|664|664|664|664|664|664|664|664|664|664|664|664|665
 sage: Qp(7, print_mode="digits")(1/3)
 ...44444444444444444445
 sage: Qp(3, print_mode="digits")(1/3)
 ....1
 sage: Qp(5, print_mode="digits")(1/3)
 ...31313131313131313132
 }}}

 Basically the print separator for p-adic fields depends on what the global
 padic_printing.sep(...) thing happens to have been set at when that field
 was first created.  There seems to be absolutely no way to change it
 later.  The dependence is also totally baffling?  Why the hell does it
 change for 97 but not 17, 11, 7?  WTF!?!

 Solution -- make the frickin' separator a property of the field that must
 be passed in.  Notice now that isn't even possible.  totally get rid of
 this stupid padic_printing object.

 {{{
 sage: Qp(5, print_mode="digits", sep='|')
 TypeError: Qp() got an unexpected keyword argument 'sep'
 }}}

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/4637>
Sage <http://sagemath.org/>
Sage - Open Source Mathematical Software: Building the Car Instead of 
Reinventing the Wheel
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to