Re: 1/2 evaluates to 0

2011-10-12 Thread Aage Andersen
"Laurent Claessens" skrev i en meddelelse news:j73p9s$baa$1...@news.univ-fcomte.fr... > Hi all > > > This is well known : > > >>> 1/2 > 0 > > This is because the division is an "integer division". > > My question is : how can I evaluate 1/2 to 0.5 ? Is there some non integer > division operator

Re: value of pi and 22/7

2011-03-18 Thread Aage Andersen
"peter" Kee Nethery > My favorite approximation is: 355/113 (visualize 113355 split into two 113 355 and then do the division). The first 6 decimal places are the same. > > 3.141592920353982 = 355/113 > vs > 3.1415926535897931 > > Kee Nethery Or (more for fun than any practical application) try

Re: DreamPie - The Python shell you've always dreamed about!

2010-02-21 Thread Aage Andersen
I reinstalled and got this message: Traceback (most recent call last): File "dreampie.py", line 4, () File "dreampielib\gui\__init__.pyc", line 972, main() File "dreampielib\gui\__init__.pyc", line 153, __init__(self=DreamPie(path..."window_main"), pyexec='C:\\Python26\\python.exe') File

Re: DreamPie - The Python shell you've always dreamed about!

2010-02-21 Thread Aage Andersen
I tried to edit the awfully colors, here are the results: Traceback (most recent call last): File "dreampie.py", line 4, () File "dreampielib\gui\__init__.pyc", line 972, main() File "dreampielib\gui\__init__.pyc", line 153, __init__(self=DreamPie(path..."window_main"), pyexec='C:\\Python2

scipy

2006-07-12 Thread Aage Andersen
I am exploring the modules scipy and linalg using python under Win XP and IDLE. Defining m=matrix( .. ) and trying to compute the inverse of m: >>> inverse(m) I get an array: >>>array( .. ) This is unfortunate. I would rather have a matrix returned as the rules for manipulating matrices and