New Casio fx-9860 GIII model
|
10-04-2020, 04:53 PM
Post: #40
|
|||
|
|||
RE: New Casio fx-9860 GIII model
Has anyone else noticed how damn fast this thing is using python?
I ran some benchmarks on this thing using both the built-in Casio Basic language and Python. First, I get it to calculate \(\sum_{k=1}^n \sqrt[3]{e^{sin(atan(k))}} \) (a function with no intrinsic value other than it gets the calculator to chew through a bunch of transcendental functions) for various values of \(n\). Using the built-in \(\sum \) function it gets through this in roughly (because timed with a stopwatch) 25 seconds for \(n=10^3\) or 220 seconds for \(n=10^4\). Using a Casio Basic program it does it in about 16 seconds for \(n=10^3\), 164 seconds for \(n=10^4\) or 1650 seconds for \(n=10^5\). Using a python program it does it in only 2 seconds for \(n=10^3\), 18 seconds for \(n=10^4\) or 184 seconds for \(n=10^5\). That's 10× faster than using Casio Basic, BUT with what appears to be greatly reduced precision. Another test I do is to get a machine to solve the "N Queens" problem, not just for the first layout it finds but for all layouts. The kind of results I get are Casio basic: 6×6 board 32 seconds, 7×7 board 139 seconds, 8×8 board 670 seconds Python: 6×6 board 1 second, 7×7 board 3 seconds, 8×8 board 15 seconds, 9×9 board 76 seconds Here, manipulating integers instead of floating point numbers, it's over 40× faster. There are only 10 types of people in this world. Those who understand binary and those who don't. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)