Ask Your Question
0

unicode in sage terminal

asked 2013-04-26 05:02:58 -0500

Moataz Elmasry gravatar image

updated 2013-04-26 06:16:31 -0500

fidbc gravatar image

Hello

when I type

sage: "ä"
'\xc3\xa4' #latin1
sage: u"ä"
u'\xe4' #utf-8

I was actually hoping to display the actual character ä. I'm aware of issues #13296 and patch 1176c4b I have sage 5.8 installed through ubuntu 12.04 repository Still though I can't seem to print a german umlaut 'ä' neither in a sage terminal nor in a notebook

Anyone has the same problem in sage 5.8?

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
2

answered 2013-04-26 06:19:44 -0500

fidbc gravatar image

updated 2013-04-26 06:53:20 -0500

kcrisman gravatar image

Here is a related question in stackoverflow.

This seems to work for me

sage: print u"ä".encode('utf-8')
ä
edit flag offensive delete link more

Comments

1

[This SO question](http://stackoverflow.com/questions/2260815/weird-problem-with-input-encoding-in-ipython) specifically addresses the Ipython issue - or, rather, that Ipython has issues.

kcrisman gravatar imagekcrisman ( 2013-04-26 06:53:57 -0500 )edit

thnx it works great!!

Moataz Elmasry gravatar imageMoataz Elmasry ( 2013-04-28 03:30:07 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2013-04-26 05:02:58 -0500

Seen: 336 times

Last updated: Apr 26 '13