Re: Mathematica 7 compares to other languages

2009-01-30 Thread William James
w_a_x_...@yahoo.com wrote: > On Dec 25, 5:24 am, Xah Lee wrote: > > > The JavaScript example: > > > > // Javascript. By William James > > function normalize( vec ) { > > var div=Math.sqrt(vec.map(function(x) x*x).reduce(function(a,b) > > a+b))   return vec.map(function(x) x/div) > > > > } > >

Re: Mathematica 7 compares to other languages

2009-01-24 Thread Jerry Gerrone
On Jan 21, 1:06 pm, "soul.mirr...@gmail.com" wrote: > On Dec 4 2008, 5:11 am, Andreas Waldenburger > wrote: > > I vaguely remember you plonking [Xah Lee] before. Did you unplonk him in > > the meantime? Or was that just a figure of speech? > > > teasingly yours, > > /W > > Andreas Waldenburger, I

Re: Mathematica 7 compares to other languages

2009-01-21 Thread soul.mirr...@gmail.com
On Dec 4 2008, 5:11 am, Andreas Waldenburger wrote: > On Wed, 03 Dec 2008 20:38:44 -0500 Lew wrote: > > > Xah Lee wrote: > > > enough babble ... > > > Good point.  Plonk.  Guun dun! > > I vaguely remember you plonking the guy before. Did you unplonk him in > the meantime? Or was that just a figur

Re: Mathematica 7 compares to other languages

2008-12-25 Thread MRAB
s...@netherlands.com wrote: On Thu, 25 Dec 2008 21:50:29 +, Jon Harrop wrote: Xah Lee wrote: On Dec 10, 2:47 pm, John W Kennedy wrote: C: #include #include void normal(int dim, float* x, float* a) { float sum = 0.0f; int i; float divisor; for (i = 0; i < dim; ++i) sum

Re: Mathematica 7 compares to other languages

2008-12-25 Thread sln
On Thu, 25 Dec 2008 21:50:29 +, Jon Harrop wrote: >Xah Lee wrote: >>> >On Dec 10, 2:47 pm, John W Kennedy wrote: >>> >> C: >>> >>> >> #include >>> >> #include >>> >>> >> void normal(int dim, float* x, float* a) { >>> >> float sum = 0.0f; >>> >> int i; >>> >> float divisor; >>>

Re: Mathematica 7 compares to other languages

2008-12-25 Thread Jon Harrop
Xah Lee wrote: >> >On Dec 10, 2:47 pm, John W Kennedy wrote: >> >> C: >> >> >> #include >> >> #include >> >> >> void normal(int dim, float* x, float* a) { >> >> float sum = 0.0f; >> >> int i; >> >> float divisor; >> >> for (i = 0; i < dim; ++i) sum += x[i] * x[i]; >> >> divis

Re: Mathematica 7 compares to other languages

2008-12-25 Thread w_a_x_man
On Dec 25, 5:24 am, Xah Lee wrote: > The JavaScript example: > > // Javascript. By William James > function normalize( vec ) { > var div=Math.sqrt(vec.map(function(x) x*x).reduce(function(a,b) a+b)) >   return vec.map(function(x) x/div) > > } > > is also not qualified. (it is syntax error in Spid

Re: Mathematica 7 compares to other languages

2008-12-25 Thread Xah Lee
> >On Dec 10, 2:47 pm, John W Kennedy wrote: > >> C: > > >> #include > >> #include > > >> void normal(int dim, float* x, float* a) { > >> float sum = 0.0f; > >> int i; > >> float divisor; > >> for (i = 0; i < dim; ++i) sum += x[i] * x[i]; > >> divisor = sqrt(sum); > >> fo

Re: Mathematica 7 compares to other languages

2008-12-14 Thread the . brown . dragon . blog
On Dec 12, 12:12 am, Xah Lee wrote: > On Dec 11, 6:50 am, the.brown.dragon.b...@gmail.com wrote: > ;; Chicken Scheme. By the.brown.dragon...@gmail.com > (require 'srfi-1) > (define (normalize vec) >   (map (cute / <> (sqrt (reduce + 0 (map (cute expt <> 2) vec > vec)) > > Is it possible to mak

Re: Mathematica 7 compares to other languages

2008-12-12 Thread Bakul Shah
George Neuner wrote: On Thu, 11 Dec 2008 10:41:59 -0800 (PST), Xah Lee wrote: On Dec 10, 2:47 pm, John W Kennedy wrote: Xah Lee wrote: In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, you'll have 50 or hundreds lines. C: #include #include void normal(int dim, float

Re: Mathematica 7 compares to other languages

2008-12-12 Thread George Neuner
On Mon, 8 Dec 2008 15:14:18 -0800 (PST), Xah Lee wrote: >Dear George Neuner, > >Xah Lee wrote: >> >For example, >> >the level or power of lang can be roughly order as >> >this: >> >> >assembly langs >> >C, pascal >> >C++, java, c# >> >unix shells >> >perl, python, ruby, php >> >lisp >> >Mathemati

Re: Mathematica 7 compares to other languages

2008-12-12 Thread George Neuner
On Thu, 11 Dec 2008 10:41:59 -0800 (PST), Xah Lee wrote: >On Dec 10, 2:47 pm, John W Kennedy wrote: >> Xah Lee wrote: >> > In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, >> > you'll have 50 or hundreds lines. >> >> C: >> >> #include >> #include >> >> void normal(int dim,

Re: Mathematica 7 compares to other languages

2008-12-12 Thread George Neuner
On Wed, 10 Dec 2008 21:37:34 + (UTC), Kaz Kylheku wrote: >Now try writing a device driver for your wireless LAN adapter in Mathematica. Notice how Xah chose not to respond to this. George -- http://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-12 Thread Tom McGlynn
On Dec 11, 6:46 am, "William James" wrote: > John W Kennedy wrote: > > Xah Lee wrote: > > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or > > > Java, you'll have 50 or hundreds lines. > > > Java: > > > static float[] normal(final float[] x) { > >float sum = 0.0f; > >for (

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Jon Harrop
Xah Lee wrote: > On Dec 10, 2:47 pm, John W Kennedy wrote: >> Xah Lee wrote: >> > In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, >> > you'll have 50 or hundreds lines. >> >> C: >> >> #include >> #include >> >> void normal(int dim, float* x, float* a) { >> float sum = 0.0f;

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Jim Gibson
In article <5ebe5a7d-cbdf-4d66-a816-a7d2a0a27...@40g2000prx.googlegroups.com>, Xah Lee wrote: > On Dec 10, 2:47 pm, John W Kennedy wrote: > > Xah Lee wrote: > > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, > > > you'll have 50 or hundreds lines. > > > > C: > > > > #inc

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Brian Blais
On Dec 11, 2008, at 13:41 , Xah Lee wrote: On Dec 10, 2:47 pm, John W Kennedy wrote: Xah Lee wrote: In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, you'll have 50 or hundreds lines. C: #include #include void normal(int dim, float* x, float* a) { float sum = 0

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Xah Lee
On Dec 11, 6:50 am, the.brown.dragon.b...@gmail.com wrote: ;; Chicken Scheme. By the.brown.dragon...@gmail.com (require 'srfi-1) (define (normalize vec) (map (cute / <> (sqrt (reduce + 0 (map (cute expt <> 2) vec vec)) Is it possible to make it work in scsh? (i'm running scsh 0.6.4, and don'

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Xah Lee
On Dec 10, 2:47 pm, John W Kennedy wrote: > Xah Lee wrote: > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, > > you'll have 50 or hundreds lines. > > C: > > #include > #include > > void normal(int dim, float* x, float* a) { >     float sum = 0.0f; >     int i; >     floa

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Xah Lee
Xah Lee wrote: • A Example of Mathematica's Expressiveness http://xahlee.org/UnixResource_dir/writ/Mathematica_expressiveness.html On Dec 11, 3:53 am, "William James" wrote: > function normal( ary ) > { var div = Math.sqrt( > ary.map(function(x) x*x).reduce(function(a,b) a+b) ) > return

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Xah Lee
On Dec 11, 12:32 am, Gerard flanagan <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: > > On Dec 10, 2:47 pm, John W Kennedy <[EMAIL PROTECTED]> wrote: > >> Xah Lee wrote: > >>> In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, > >>> you'll have 50 or hundreds lines. > [...] > > > Th

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Stef Mientki
Andreas Waldenburger wrote: On Thu, 11 Dec 2008 05:40:45 + Paul Rudin <[EMAIL PROTECTED]> wrote: "Dotan Cohen" <[EMAIL PROTECTED]> writes: 2008/12/10 <[EMAIL PROTECTED]>: Ruby: def norm a s = Math.sqrt(a.map{|x|x*x}.inject{|x,y|x+y}) a.map{|x| x/s} end If som

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Andreas Waldenburger
On Thu, 11 Dec 2008 05:40:45 + Paul Rudin <[EMAIL PROTECTED]> wrote: > "Dotan Cohen" <[EMAIL PROTECTED]> writes: > > > 2008/12/10 <[EMAIL PROTECTED]>: > >> Ruby: > >> > >> def norm a > >> s = Math.sqrt(a.map{|x|x*x}.inject{|x,y|x+y}) > >> a.map{|x| x/s} > >> end > > > > If someone doesn't

Re: Mathematica 7 compares to other languages

2008-12-11 Thread William James
William James wrote: > John W Kennedy wrote: > > > Xah Lee wrote: > > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or > > > Java, you'll have 50 or hundreds lines. > > > > > Java: > > > > static float[] normal(final float[] x) { > >float sum = 0.0f; > >for (int i = 0;

Re: Mathematica 7 compares to other languages

2008-12-11 Thread the . brown . dragon . blog
On Dec 11, 7:50 pm, [EMAIL PROTECTED] wrote: > On Dec 11, 4:53 pm, "William James" <[EMAIL PROTECTED]> wrote: > > > > > William James wrote: > > > John W Kennedy wrote: > > > > > Xah Lee wrote: > > > > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or > > > > > Java, you'll have 50

Re: Mathematica 7 compares to other languages

2008-12-11 Thread the . brown . dragon . blog
On Dec 11, 4:53 pm, "William James" <[EMAIL PROTECTED]> wrote: > William James wrote: > > John W Kennedy wrote: > > > > Xah Lee wrote: > > > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or > > > > Java, you'll have 50 or hundreds lines. > > > > Java: > > > > static float[] normal(

Re: Mathematica 7 compares to other languages

2008-12-11 Thread William James
William James wrote: > John W Kennedy wrote: > > > Xah Lee wrote: > > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or > > > Java, you'll have 50 or hundreds lines. > > > > > Java: > > > > static float[] normal(final float[] x) { > >float sum = 0.0f; > >for (int i = 0;

Re: Mathematica 7 compares to other languages

2008-12-11 Thread William James
John W Kennedy wrote: > Xah Lee wrote: > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or > > Java, you'll have 50 or hundreds lines. > > Java: > > static float[] normal(final float[] x) { >float sum = 0.0f; >for (int i = 0; i < x.length; ++i) sum += x[i] * x[i]; >f

Re: Mathematica 7 compares to other languages

2008-12-11 Thread Gerard flanagan
Xah Lee wrote: On Dec 10, 2:47 pm, John W Kennedy <[EMAIL PROTECTED]> wrote: Xah Lee wrote: In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, you'll have 50 or hundreds lines. [...] Thanks to various replies. I've now gather code solutions in ruby, python, C, Java, here:

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Paul Rudin
"Dotan Cohen" <[EMAIL PROTECTED]> writes: > 2008/12/10 <[EMAIL PROTECTED]>: >> On Dec 5, 9:51 am, Xah Lee <[EMAIL PROTECTED]> wrote: >>> >>> For those of you who don't know linear algebra but knows coding, this >>> means, we want a function whose input is a list of 3 elements say >>> {x,y,z}, and

Re: Mathematica 7 compares to other languages

2008-12-10 Thread toby
On Dec 10, 3:37 pm, [EMAIL PROTECTED] wrote: > On Dec 5, 9:51 am, Xah Lee <[EMAIL PROTECTED]> wrote: > > > > > For those of you who don't know linear algebra but knows coding, this > > means, we want a function whose input is a list of 3 elements say > > {x,y,z}, and output is also a list of 3 elem

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Roberto Bonvallet
Arnaud Delobelle wrote: > def unit(v): > return map((sum(map(lambda x:x*x, v))**0.5).__rdiv__, v) > > The hard bit was to make it less readable than the Ruby version ;) I loved the use of __rdiv__ :) I would have proposed the more straightforward: def u(v): return [x/sum(x**2 for

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Juan Pablo Romero Méndez
In R: norm = function(v) v/sqrt(sum(v^2)) :) Juan Pablo 2008/12/10 Arnaud Delobelle <[EMAIL PROTECTED]>: > "Dotan Cohen" <[EMAIL PROTECTED]> writes: > >> 2008/12/10 <[EMAIL PROTECTED]>: >>> On Dec 5, 9:51 am, Xah Lee <[EMAIL PROTECTED]> wrote: For those of you who don't know l

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Chris Rathman
On Dec 10, 6:51 pm, Xah Lee <[EMAIL PROTECTED]> wrote: > I've now gather code solutions in ruby, python, C, Java, here: > > now lacking is perl, elisp, which i can do well in a condensed way. > It'd be interesting also to have javascript... and perhaps erlang, > OCaml/F#, Haskell too. Pay me $6

Re: Mathematica 7 compares to other languages

2008-12-10 Thread William James
Jon Harrop wrote: > Xah Lee wrote: > > On Dec 10, 12:37 pm, [EMAIL PROTECTED] wrote: > >> Ruby: > > > > >> def norm a > >> s = Math.sqrt(a.map{|x|x*x}.inject{|x,y|x+y}) > >> a.map{|x| x/s} > >> end > > > > I don't know ruby, but i tried to run it and it does not work. > > > > #ruby > > def

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Xah Lee
On Dec 10, 2:47 pm, John W Kennedy <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: > > In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, > > you'll have 50 or hundreds lines. > > C: > > #include > #include > > void normal(int dim, float* x, float* a) { >     float sum = 0.0f; >  

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Kaz Kylheku
On 2008-12-10, Xah Lee <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: >> > means, we want a function whose input is a list of 3 elements say ^^ ^^^ > Kaz, pay attention: [ reformatted to 7 bit USASCII ] > Xah wrote: Note, that the norm > o

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Bakul Shah
Bakul Shah wrote: John W Kennedy wrote: Xah Lee wrote: In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, you'll have 50 or hundreds lines. C: #include #include void normal(int dim, float* x, float* a) { float sum = 0.0f; int i; float divisor; for (i = 0; i

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Bakul Shah
John W Kennedy wrote: Xah Lee wrote: In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, you'll have 50 or hundreds lines. C: #include #include void normal(int dim, float* x, float* a) { float sum = 0.0f; int i; float divisor; for (i = 0; i < dim; ++i) sum +=

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Arne Vajhøj
Jon Harrop wrote: Xah Lee wrote: Kaz Kylheku wrote: Really? ``50 or hundreds'' of lines in C? #include /* for sqrt */ void normalize(double *out, double *in) { double denom = sqrt(in[0] * in[0] + in[1] * in[1] + in[2] * in[2]); out[0] = in[0]/denom; out

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Daniel Fetchinson
On 12/10/08, Jon Harrop <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: >> Kaz Kylheku wrote: >>> Really? ``50 or hundreds'' of lines in C? >>> >>> #include /* for sqrt */ >>> >>> void normalize(double *out, double *in) >>> { >>> double denom = sqrt(in[0] * in[0] + in[1] * in[1] + in[2]

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Jon Harrop
Xah Lee wrote: > Kaz Kylheku wrote: >> Really? ``50 or hundreds'' of lines in C? >> >> #include /* for sqrt */ >> >> void normalize(double *out, double *in) >> { >> double denom = sqrt(in[0] * in[0] + in[1] * in[1] + in[2] * >> in[2]); >> >> out[0] = in[0]/denom; >>

Re: Mathematica 7 compares to other languages

2008-12-10 Thread John W Kennedy
Xah Lee wrote: In lisp, python, perl, etc, you'll have 10 or so lines. In C or Java, you'll have 50 or hundreds lines. C: #include #include void normal(int dim, float* x, float* a) { float sum = 0.0f; int i; float divisor; for (i = 0; i < dim; ++i) sum += x[i] * x[i]; divisor

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Jon Harrop
Xah Lee wrote: > On Dec 10, 12:37 pm, [EMAIL PROTECTED] wrote: >> Ruby: >> >> def norm a >> s = Math.sqrt(a.map{|x|x*x}.inject{|x,y|x+y}) >> a.map{|x| x/s} >> end > > I don't know ruby, but i tried to run it and it does not work. > > #ruby > def norm a > s = Math.sqrt(a.map{|x|x*x}.inject{|

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Arnaud Delobelle
"Dotan Cohen" <[EMAIL PROTECTED]> writes: > 2008/12/10 <[EMAIL PROTECTED]>: >> On Dec 5, 9:51 am, Xah Lee <[EMAIL PROTECTED]> wrote: >>> >>> For those of you who don't know linear algebra but knows coding, this >>> means, we want a function whose input is a list of 3 elements say >>> {x,y,z}, and

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Xah Lee
Xah Lee wrote: > > For those of you who don't know linear algebra but knows coding, this > > means, we want a function whose input is a list of 3 elements say > > {x,y,z}, and output is also a list of 3 elements, say {a,b,c}, with > > the condition that > > > > a = x/Sqrt[x^2+y^2+z^2] > > b = y/Sqr

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Xah Lee
Xah Lee wrote: > > Let's say for example, we want to write a function that takes a vector > > (of linear algebra), and return a vector in the same direction but > > with length 1. In linear algebar terminology, the new vector is called > > the “normalized” vector of the original. > > > For those of

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Kaz Kylheku
On 2008-12-05, Xah Lee <[EMAIL PROTECTED]> wrote: > Let's say for example, we want to write a function that takes a vector > (of linear algebra), and return a vector in the same direction but > with length 1. In linear algebar terminology, the new vector is called > the “normalized” vector of the o

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Dotan Cohen
2008/12/10 <[EMAIL PROTECTED]>: > On Dec 5, 9:51 am, Xah Lee <[EMAIL PROTECTED]> wrote: >> >> For those of you who don't know linear algebra but knows coding, this >> means, we want a function whose input is a list of 3 elements say >> {x,y,z}, and output is also a list of 3 elements, say {a,b,c},

Re: Mathematica 7 compares to other languages

2008-12-10 Thread w_a_x_man
On Dec 5, 9:51 am, Xah Lee <[EMAIL PROTECTED]> wrote: > > For those of you who don't know linear algebra but knows coding, this > means, we want a function whose input is a list of 3 elements say > {x,y,z}, and output is also a list of 3 elements, say {a,b,c}, with > the condition that > > a = x/Sq

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Almar Klein
2008/12/10 Xah Lee <[EMAIL PROTECTED]> > Jon Harrop moron wrote: > > Only for trivial input and not for the challenge you were given. > > what challenge? > > > That code is evaluated once to build the scene. There is no point in > > optimizing it. > > The point is optimizing your incompetence. > >

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Jon Harrop
Stef Mientki wrote: > Who said Mathematica was a high level language ? Xah is using what he calls "highlevelness" as an excuse for poor performance. -- Dr Jon D Harrop, Flying Frog Consultancy Ltd. http://www.ffconsultancy.com/?u -- http://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-10 Thread Stef Mientki
On 12/10/08, Xah Lee <[EMAIL PROTECTED]> wrote: > On Dec 8, 5:25 pm, Terry Reedy <[EMAIL PROTECTED]> wrote: >> Lest anyone doubt that problem size is important for comparing program >> run times, consider ... > > just in case there's any doubt: > > Simply change these lines in Jon's program: > > Ma

Re: Mathematica 7 compares to other languages

2008-12-09 Thread Xah Lee
Jon Harrop moron wrote: > Only for trivial input and not for the challenge you were given. what challenge? > That code is evaluated once to build the scene. There is no point in > optimizing it. The point is optimizing your incompetence. > That performance issue only affects trivial problems an

Re: Mathematica 7 compares to other languages

2008-12-09 Thread sln
On Tue, 9 Dec 2008 15:01:11 -0800 (PST), Xah Lee <[EMAIL PROTECTED]> wrote: > >On Dec 8, 4:56 pm, Jon Harrop <[EMAIL PROTECTED]> wrote: >> Xah Lee wrote: >> > A moron, wrote: >> > > You failed the challenge that you were given. >> >> > you didn't give me a challenge. >> >> Thomas gave you the chal

Re: Mathematica 7 compares to other languages

2008-12-09 Thread sln
On Tue, 9 Dec 2008 15:19:47 -0800 (PST), Xah Lee <[EMAIL PROTECTED]> wrote: >On Dec 8, 4:07 am, Jon Harrop <[EMAIL PROTECTED]> wrote: >> [EMAIL PROTECTED] wrote: >> > Well, its past 'tonight' and 6 hours to go till past 'tomorrow'. >> > Where the hell is it Zah Zah? >> >> Note that this program ta

Re: Mathematica 7 compares to other languages

2008-12-09 Thread Jon Harrop
Xah Lee wrote: > On Dec 8, 5:25 pm, Terry Reedy <[EMAIL PROTECTED]> wrote: >> Lest anyone doubt that problem size is important for comparing program >> run times, consider ... > > just in case there's any doubt: > > Simply change these lines in Jon's program: > > Main[9, 512, 4] to Main[9, 512,

Re: Mathematica 7 compares to other languages

2008-12-09 Thread alex23
On Dec 10, 9:19 am, Xah Lee <[EMAIL PROTECTED]> wrote: > I'm not sure he's intentionally making Mathematica look bad or just > sloppiness. Actually, there's only one person here tainting Mathematica by association, and it's not Jon. -- http://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-09 Thread Xah Lee
On Dec 8, 4:07 am, Jon Harrop <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > Well, its past 'tonight' and 6 hours to go till past 'tomorrow'. > > Where the hell is it Zah Zah? > > Note that this program takes several days to compute in Mathematica (even > though it takes under four secon

Re: Mathematica 7 compares to other languages

2008-12-09 Thread Xah Lee
On Dec 8, 5:25 pm, Terry Reedy <[EMAIL PROTECTED]> wrote: > Lest anyone doubt that problem size is important for comparing program > run times, consider ... just in case there's any doubt: Simply change these lines in Jon's program: Main[9, 512, 4] to Main[9, 512, 4.] and it will run faster. A

Re: Mathematica 7 compares to other languages

2008-12-09 Thread Xah Lee
On Dec 8, 4:56 pm, Jon Harrop <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: > > A moron, wrote: > > > You failed the challenge that you were given. > > > you didn't give me a challenge. > > Thomas gave you the challenge: > > "What I want in return is you to execute and time Dr. Harrop's original >

Re: Mathematica 7 compares to other languages

2008-12-09 Thread Xah Lee
On Dec 8, 4:56 pm, Jon Harrop <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: > > A moron, wrote: > > > You failed the challenge that you were given. > > > you didn't give me a challenge. > > Thomas gave you the challenge: > > "What I want in return is you to execute and time Dr. Harrop's original >

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Wesley MacIntosh
A flamer wrote: A moron, wrote: [snip] my machine (PPC Mac, OSX 10.4.x). Well, that explains a great deal. Actually, I suspect all these newsgroups are being trolled. -- http://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Terry Reedy
Jon Harrop wrote: [EMAIL PROTECTED] wrote: For the interested, with MMA 6, on a Pentium 4 3.8Ghz: The code that Jon posted: Timing[Export["image-jon.pgm", [EMAIL PROTECTED]@Main[2, 100, 4]]] {80.565, "image-jon.pgm"} That is not the code I posted: you are using Xah's parameters that generate

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Jon Harrop
[EMAIL PROTECTED] wrote: > For the interested, with MMA 6, on a Pentium 4 3.8Ghz: > > The code that Jon posted: > > Timing[Export["image-jon.pgm", [EMAIL PROTECTED]@Main[2, 100, 4]]] > {80.565, "image-jon.pgm"} That is not the code I posted: you are using Xah's parameters that generate a differe

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Jon Harrop
Xah Lee wrote: > A moron, wrote: > > You failed the challenge that you were given. > > you didn't give me a challenge. Thomas gave you the challenge: "What I want in return is you to execute and time Dr. Harrop's original code, posting the results to this thread... By Dr. Harrop's original cod

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Xah Lee
Dear George Neuner, Xah Lee wrote: > >The phenomenon of creating code that are inefficient is proportional > >to the highlevelness or power of the lang. In general, the higher > >level of the lang, the less possible it is actually to produce a code > >that is as efficient as a lower level lang. G

Re: Mathematica 7 compares to other languages

2008-12-08 Thread George Neuner
On Sun, 7 Dec 2008 14:53:49 -0800 (PST), Xah Lee <[EMAIL PROTECTED]> wrote: >The phenomenon of creating code that are inefficient is proportional >to the highlevelness or power of the lang. In general, the higher >level of the lang, the less possible it is actually to produce a code >that is as ef

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Xah Lee
2008-12-08 Xah Lee wrote: > > Also, in this discussion, thanks to Thomas M Hermann's $20 offered to > > me for my challenge to you, that i have taken the time to show working > > code that demonstrate many problems in your code. A moron, wrote: > You failed the challenge that you were given. yo

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Jon Harrop
Xah Lee wrote: > Also, in this discussion, thanks to Thomas M Hermann's $20 offered to > me for my challenge to you, that i have taken the time to show working > code that demonstrate many problems in your code. You failed the challenge that you were given. Specifically, your code is not measurabl

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Xah Lee
On Dec 8, 5:10 am, Jon Harrop <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: > > For those interested in this Mathematica problem, i've now cleaned up > > the essay with additional comments here: > > > • A Mathematica Optimization Problem > > http://xahlee.org/UnixResource_dir/writ/Mathematica_optimi

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Jon Harrop
Xah Lee wrote: > For those interested in this Mathematica problem, i've now cleaned up > the essay with additional comments here: > > • A Mathematica Optimization Problem > http://xahlee.org/UnixResource_dir/writ/Mathematica_optimization.html In that article you say: > Further, if Intersect is

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Jon Harrop
Xah Lee wrote: > The result and speed up of my code can be verified by anyone who has > Mathematica. You changed the scene that is being rendered => your speedup is bogus! Trace the scene I originally gave and you will see that your program is no faster than mine was. -- Dr Jon D Harrop, Flying

Re: Mathematica 7 compares to other languages

2008-12-08 Thread Jon Harrop
[EMAIL PROTECTED] wrote: > Well, its past 'tonight' and 6 hours to go till past 'tomorrow'. > Where the hell is it Zah Zah? Note that this program takes several days to compute in Mathematica (even though it takes under four seconds in other languages) so don't expect to see a genuinely optimized

Re: Mathematica 7 compares to other languages

2008-12-07 Thread Xah Lee
For those interested in this Mathematica problem, i've now cleaned up the essay with additional comments here: • A Mathematica Optimization Problem http://xahlee.org/UnixResource_dir/writ/Mathematica_optimization.html The result and speed up of my code can be verified by anyone who has Mathema

Re: Mathematica 7 compares to other languages

2008-12-07 Thread Jon Harrop
Xah Lee wrote: > I didn't realize until after a hour, that if Jon simply give numerical > arguments to Main and Create, the result timing by a factor of 0.3 of > original. What a incredible sloppiness! and he intended this to show > Mathematica speed with this code? > > The Main[] function calls Cr

Re: Mathematica 7 compares to other languages

2008-12-05 Thread Xah Lee
On Dec 4, 6:09 pm, [EMAIL PROTECTED] wrote: > For the interested, with MMA 6, on a Pentium 4 3.8Ghz: > > The code that Jon posted: > > Timing[Export["image-jon.pgm", [EMAIL PROTECTED]@Main[2, 100, 4]]] > {80.565, "image-jon.pgm"} > > The code that Xah posted: > > Timing[Export["image-xah.pgm", [EMA

Re: Mathematica 7 compares to other languages

2008-12-04 Thread jason-sage
Xah Lee wrote: alright, here's my improved code, pasted near the bottom. let me say a few things about Jon's code. If we rate that piece of mathematica code on the level of: Beginner Mathematica programer, Intermediate, Advanced, where Beginner is someone who just learned tried to program Mathe

Re: Mathematica 7 compares to other languages

2008-12-04 Thread Xah Lee
alright, here's my improved code, pasted near the bottom. let me say a few things about Jon's code. If we rate that piece of mathematica code on the level of: Beginner Mathematica programer, Intermediate, Advanced, where Beginner is someone who just learned tried to program Mathematica no more t

Re: Mathematica 7 compares to other languages

2008-12-04 Thread sln
On Wed, 3 Dec 2008 16:32:57 -0800 (PST), Xah Lee <[EMAIL PROTECTED]> wrote: >On Dec 3, 4:22 pm, "Thomas M. Hermann" <[EMAIL PROTECTED]> wrote: >> On Dec 3, 5:26 pm, Xah Lee <[EMAIL PROTECTED]> wrote: >> >> >> >> > Agreed. My paypal address is “xah @@@ xahlee.org”. (replace the triple >> > @ to sin

Re: Mathematica 7 compares to other languages

2008-12-04 Thread Dotan Cohen
2008/12/4 Kaz Kylheku <[EMAIL PROTECTED]>: > Really? I will trade you one Xah Lee for three Jon Harrops and I will even > Xah Lee is interesting because he brings up lots of good points. Also, the few times we've seen his skilz he has shown that he really knows how to code. I am willing to put up

Re: Mathematica 7 compares to other languages

2008-12-04 Thread Dimiter "malkia" Stanev
You think the posts are bad... check out his web site... Just don't go to every page on the Xah website - some of his stuff is NSFW (Not Safe For Work). -- http://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-04 Thread Lew
Andreas Waldenburger wrote: On Wed, 03 Dec 2008 20:38:44 -0500 Lew <[EMAIL PROTECTED]> wrote: Xah Lee wrote: enough babble ... Good point. Plonk. Guun dun! I vaguely remember you plonking the guy before. Did you unplonk him in the meantime? Or was that just a figure of speech? I have h

Re: Mathematica 7 compares to other languages

2008-12-04 Thread Andreas Waldenburger
On Wed, 03 Dec 2008 20:38:44 -0500 Lew <[EMAIL PROTECTED]> wrote: > Xah Lee wrote: > > enough babble ... > > Good point. Plonk. Guun dun! > I vaguely remember you plonking the guy before. Did you unplonk him in the meantime? Or was that just a figure of speech? teasingly yours, /W -- My r

Re: Mathematica 7 compares to other languages

2008-12-03 Thread J�rgen Exner
Kaz Kylheku <[EMAIL PROTECTED]> wrote: >On 2008-12-04, Jürgen Exner <[EMAIL PROTECTED]> wrote: >> toby <[EMAIL PROTECTED]> wrote: >>>On Dec 3, 4:15 pm, Xah Lee <[EMAIL PROTECTED]> wrote: On Dec 3, 8:24 am, Jon Harrop <[EMAIL PROTECTED]> wrote: > My example demonstrates several of Ma

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Kaz Kylheku
On 2008-12-04, Jürgen Exner <[EMAIL PROTECTED]> wrote: > toby <[EMAIL PROTECTED]> wrote: >>On Dec 3, 4:15 pm, Xah Lee <[EMAIL PROTECTED]> wrote: >>> On Dec 3, 8:24 am, Jon Harrop <[EMAIL PROTECTED]> wrote: >>> >>> > My example demonstrates several of Mathematica's fundamental limitations. >>> >>>

Re: Mathematica 7 compares to other languages

2008-12-03 Thread J�rgen Exner
toby <[EMAIL PROTECTED]> wrote: >On Dec 3, 4:15 pm, Xah Lee <[EMAIL PROTECTED]> wrote: >> On Dec 3, 8:24 am, Jon Harrop <[EMAIL PROTECTED]> wrote: >> >> > My example demonstrates several of Mathematica's fundamental limitations. >> >> enough babble Jon. >> >> Come flying $5 to my paypal account, an

Re: Mathematica 7 compares to other languages

2008-12-03 Thread toby
On Dec 3, 4:15 pm, Xah Lee <[EMAIL PROTECTED]> wrote: > On Dec 3, 8:24 am, Jon Harrop <[EMAIL PROTECTED]> wrote: > > > My example demonstrates several of Mathematica's fundamental limitations. > > enough babble Jon. > > Come flying $5 to my paypal account, and i'll give you real code, I'll give yo

Re: Mathematica 7 compares to other languages

2008-12-03 Thread toby
On Dec 2, 5:04 pm, Tamas K Papp <[EMAIL PROTECTED]> wrote: > On Tue, 02 Dec 2008 13:57:35 -0800, Lew wrote: > > Xah Lee wrote: > >> If [yo]u would like to learn [the] [E]nglish lang[uage] and writing > >> insights from me, peruse: > > > /Au contraire/, I was suggesting a higher standard for your po

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Hendrik van Rooyen
"Xah Lee" <[EMAIL PROTECTED]> wrote: >Chances are, $10 is not enough for me to take the >trouble of disappearing from the face of this earth. What a pity. It would be cheap at the price. - Hendrik -- http://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Lew
Xah Lee wrote: enough babble ... Good point. Plonk. Guun dun! -- Lew -- http://mail.python.org/mailman/listinfo/python-list

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Xah Lee
On Dec 3, 4:22 pm, "Thomas M. Hermann" <[EMAIL PROTECTED]> wrote: > On Dec 3, 5:26 pm, Xah Lee <[EMAIL PROTECTED]> wrote: > > > > > Agreed. My paypal address is “xah @@@ xahlee.org”. (replace the triple > > @ to single one.) Once you paid thru paypal, you can post receit here > > if you want to, or

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Thomas M. Hermann
On Dec 3, 5:26 pm, Xah Lee <[EMAIL PROTECTED]> wrote: > Agreed. My paypal address is “xah @@@ xahlee.org”. (replace the triple > @ to single one.) Once you paid thru paypal, you can post receit here > if you want to, or i'll surely acknowledge it here. > > Here's what i will do: > > I will give a v

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Xah Lee
> I'll pay $20 to see your improved version of the code. The only > references to PayPal I saw on your website were instructions to direct > the payment to [EMAIL PROTECTED], please let me know if that is correct. > > What I want in return is you to execute and time Dr. Harrop's original > code, po

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Chris Rathman
Xah Lee wrote: > Come flying $5 to my paypal account, and i'll give you real code, > amongest the programing tech geekers here for all to see. That's the problem with Mathematica - it's so expensive that you even have to pay for simple benchmark programs. -- http://mail.python.org/mailman/listinfo

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Thomas M. Hermann
On Dec 3, 3:15 pm, Xah Lee <[EMAIL PROTECTED]> wrote: > On Dec 3, 8:24 am, Jon Harrop <[EMAIL PROTECTED]> wrote: > > > My example demonstrates several of Mathematica's fundamental limitations. > > enough babble Jon. > > Come flying $5 to my paypal account, and i'll give you real code, > amongest th

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Xah Lee
On Dec 3, 8:24 am, Jon Harrop <[EMAIL PROTECTED]> wrote: > My example demonstrates several of Mathematica's fundamental limitations. enough babble Jon. Come flying $5 to my paypal account, and i'll give you real code, amongest the programing tech geekers here for all to see. I'll show, what kind

Re: Mathematica 7 compares to other languages

2008-12-03 Thread jason-sage
[EMAIL PROTECTED] wrote: So when you need an algorithm, you can often find it already inside, for example in the large Combinatorics package. So it has WAY more batteries included, compared to Python. I'd like to see something as complete as that Combinatorics package in Python. Sage (http

Re: Mathematica 7 compares to other languages

2008-12-03 Thread Jon Harrop
Xah Lee wrote: > On Dec 2, 5:13 pm, Jon Harrop <[EMAIL PROTECTED]> wrote: >> The Mathematica code is 700,000x slower so a 50% improvement will be >> uninteresting. Can you make my Mathematica code five orders of magnitude >> faster or not? > > Pay me $10 thru paypal, i'll can increase the speed so

Re: Mathematica 7 compares to other languages

2008-12-02 Thread Lew
George Sakkis wrote: As a Slashdotter would put it... you must be new here ;-) For certain values of "here". I've seen Xah before, and I'm happy to engage if he behaves himself. Some of his initial ideas I actually find engaging. His followups leave a lot to be desired. f/u set to comp.la

  1   2   >