On Feb 18, 7:31 am, William Stein <wst...@gmail.com> wrote:
> On Thu, Feb 17, 2011 at 9:11 PM, rjf <fate...@gmail.com> wrote:
>
> > On Feb 17, 4:49 pm, Matt Goodman <meawo...@gmail.com> wrote:
> >> MATLAB isn't a tool used outside of academia very often.
>
> > I think you are wrong here.  I don't have any data to point to though.
> > Do you have any data on this?
>
> No data versus no data.
>
> >>  Its licensing makes it hard to redistribute code (like to a third party),
> >> or even run it on a couple different workstations in a HPC sense.
>
> > Huh?  How so?  You write a program, you own it, you can give it to
> > someone else.
> > Did they make that hard to do somehow?
>
> Each copy of MATLAB costs (a lot of) money.  Python is free.  (It's
> simply amazing to me that you don't realize that this is what he is
> talking about! How is it even possible?)

Ah, I see.  My misunderstanding was in taking Matt's statement at
its face.   We agree that it is no problem to (re)distribute code
that you write to anyone else.  The recipient of the code would either
have to have a Matlab licensed system or a system that ran Matlab
code,
like Octave [sort of].  So my assumption is that anyone who was
interested in your own coded Matlab program either had such a setup,
or
was only interested in looking at the code, not running it.  This
latter situation is not that unusual, I think.  I have occasionally
looked at Matlab programs to learn from them.  Usually it is harder
to figure out than I expected, but that's another story.

 I think that if Matt is objecting to the difficulty in giving
someone else a completely working system written in the Matlab
language
including Matlab in a form that it can be redistributed without
restriction, that is another issue.  Of course a program written
using Sage cannot be redistributed without restriction either.  The
GPL is a restriction.  But again that is another story.

Many people using Matlab are, I think, using it within some
organization
such as a college or an engineering lab.  The incremental cost for one
more Matlab user license is small and probably part of the overhead of
the organization, and so there is no apparent cost to the individual
user.  This has the very significant advantage (to me) that it is
free (as in free beer). The problem with Sage by comparison is that
it is free (as in free press) but has significant overhead for the
first person to try to install it somewhere, (apparently still,
especially on Windows...) But again that is another story.



>
> >>  I
> >> would guess the matlab base is about 2x the scientific python community, 
> >> but
> >> the science python people are only 5%-10% of Python users.  The same foes
> >> for LabView etc.
>
> > I think you are way off, and the Matlab community is many times the
> > scientific
> > python community,  but again I have no data.
>
> The TIOBE index also illustrates is that whatever the real data is, it
> is probably constantly changing, and in some cases changing very
> quickly.  See, e.g., the history of Objective-C in TIOBE -- 3 years
> ago it was a very unpopular language, and now it is very popular
> (probably because of Apple's iOS programming).
>
> >  I suspect that the
> > serious scientific computing community is almost all non-python, and
> > that
> > it consists of C/Fortran/Matlab.
>
> I suspect that was a true statement at some point in time.

 I would even speculate that the proportion of
Python users has increased infinitely from some point in time, say
1950.
  What is taught to engineers at UW?
a google search on university washington engineering
python gets 98,000 hits.with matlab it gets 124,000 hits.
At UC Berkeley, 148,000 vs 158,000.  Python IS taught in
some intro classes here

Now if we remove the term "engineering" from the search, there are
more
hits, and at UC, python > matlab.  Some of this is scientific
computing of some sort, but probably most of it is not.


>
>
>
> >> Its easy to forget that science Python is a serious _minority_ in the 
> >> Python
> >> community.  I attend the Enthought monthly Python meetup here in Austin, 
> >> and
> >> of 50 people, maybe 3-5 are science Python programmers.
>
> > I am not surprised that there is a relatively small overlap between
> > scientific
> > computing and Python programming.  Most scientific computing tasks are
> > sensitive
> > to efficiency of resulting code.
>
> This is just FUD, suggesting that one can't use Python for scientific
> computing due to it being too slow.

Well, the issue is not so much the programming language efficiency,
or how much it matters in practice to have some data setup and web
access
and debugging be written in a friendlier languaage, but a perception.

  For the last umpteen years it
was possible to write programs in some convenient interactive --but
possibly
slower than optimized-compiled-Fortran -- language.  Which language
doesn't really matter. It could be Perl, TCL, even Lisp, ....  The
perception
by (some, in the past, almost all) heavy users of scientific
computing,
who tend to be relatively conservative when it comes to computer
"science"...
depending on such activities to produce the next generation of
hardware ...
was that if you really wanted to get the job done, you had to write in
Fortran, or maybe more recently, C, perhaps with touches of
assembler.

 So once you learned to hack Fortran,
why should you ALSO have to learn Python?   Now you and I and other
readers
here may say otherwise -- that you will be much more productive etc if
you learn Python---.  But, at least in the past, the physicists (etc)
found
that they could write the rest of their programs in Fortran also.
  If they want to write
a front-end web thingee, they can hire someone else, who presumably
doesn't need to know physics. Someone who would know
PHP, python, C# whatever.


> Most people doing scientific also
> use C/Fortran-based libraries such as numpy and scipy, and quite a few
> use Cython as well.

Can't those libraries (or something like them)  also be called from C
or Fortran?
So why do we need to use Python?  (I suspect they can be used from
Lisp, having
done so once in the past.)
I'm not arguing that Python can't be used by scientists. I'm not
arguing that
Python shouldn't be used by scientists.  I'm just offering my thoughts
about
why scientists might not be using Python that much.

>    These tools allow you to write code that is as
> fast as code one produces in Matlab or Fortran.

Well, that gives you quite a range. Depending on what you are doing,
it could be that Mathlab, Fortran, Python  might all be calling the
exact same
code, like Lapack.  Oh, that reminds me, what is Lapack written in?
Do you think it would benefit by rewriting in Python or Cython?
What about Scalapack, BLAS, etc.  See
 http://www.netlib.org/scalapack/slug/node16.html#SECTION04140000000000000000
for comments.



If they are not all calling Lapack, usually there are kinds of
programs that
 an optimizing Fortran compiler can compile into code that is
many multiples faster than Matlab code.

According to that web page linked above, it appears that
scientific computing people are still  writing code in Fortran 77
  (yes, 1977).
 So maybe in 40 years those people, or their successors, should
they still be alive and writing programs, might pick up on Python:)

RJF


-- 
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to