Re: [TYPES] The type/object distinction and possible synthesis of OOP and imperative programming languages

2013-04-19 Thread Jason Wilkins
I don't quite think I understand what you are saying.  Are you saying that
mathematical models are not a good foundation for computer science because
computers are really made out of electronic gates?

All I need to do is show that my model reduces to some basic physical
implementation (with perhaps some allowances for infinity) and then I can
promptly forget about that messy business and proceed to use my
clean mathematical model.

The reason any model of computation exists is that it is easier to think
about a problem in some terms than in others.  By showing how to transform
one model to another you make it possible to choose exactly how you wish to
solve a problem.

The reason we do not work directly in what are called von Neumann
machines is that they are not convenient for all kinds of problems.
 However we can build a compiler to translate anything to anything else so
we I don't see why anybody would care.


On Thu, Apr 18, 2013 at 5:53 PM, Mark Janssen dreamingforw...@gmail.comwrote:

 [ The Types Forum, http://lists.seas.upenn.edu/mailman/listinfo/types-list]

 On Mon, Apr 15, 2013 at 2:53 AM, Moez AbdelGawad moeza...@outlook.com
 wrote:
  I'm not quite sure I understand your question, but I'll give it a shot.
  :-)
 
  I'm in this same camp too :)

 I am very thankful for the references given by everyone.
 Unfortunately my library does not have the titles and it will be some
 time before I can acquire them.  I hope it not too intrusive to offer
 a few points that I've garnered from this conversation until I can
 study the history further.

 The main thing that I notice is that there is a heavy bias in
 academia towards mathematical models.  I understand that Turing
 Machines, for example, were originally abstract computational concepts
 before there was an implementation in hardware, so I have some
 sympathies with that view, yet, should not the Science of Computer
 Science concern itself with how to map these abstract computational
 concepts into actual computational hardware?  Otherwise, why not keep
 the field within mathematics and philosophy (where Logic traditionally
 has been)?   I find it remarkable, for example, that the simple
 continued application of And/Or/Not gates can perform all the
 computation that C.S. concerns itself with and these form the basis
 for computer science in my mind, along with Boolean logic.  (The
 implementation of digital logic into physical hardware is where C.S.
 stops and Engineering begins, I would argue.)

 But still, it seems that there are two ends, two poles, to the whole
 computer science enterprise that haven't been sufficiently *separated*
 so that they can be appreciated:  logic gates vs. logical calculus
 and symbols.   There is very little crossover as I can see.  Perhaps
 the problem is the common use of the Greek root logikos; in the
 former, it pertains to binary arithmetic, where in the latter, it
 retains it's original Greek pertaining to *speech* and symbols,
 logos).  Further, one can notice that in the former, the progression
 has been towards more sophisticated Data Structures (hence the
 evolution towards Object-Orientation), where in the latter (I'm
 guessing, since it's not my area of expertise) the progression has
 been towards function sophistication (where recursion seems to be
 paramount).

 In any case, I look forward to diving into the books and references
 you've all offered so generously so that I can appreciate the field
 and its history better.

 Mark Janssen
 Pacific Lutheran University
 Tacoma, Washington

-- 
http://mail.python.org/mailman/listinfo/python-list


Re: [TYPES] The type/object distinction and possible synthesis of OOP and imperative programming languages

2013-04-18 Thread Jason Wilkins
Warning, this is a bit of a rant.

That paragraph from Wikipedia seems to be confused.  It gives the fourth
paradigm as declarative but then says first order logic for logic
programming.  It seems somebody did an incomplete replacement of
declarative for logic.  Wikipedia is often schizophrenic like that.

Personally, I think that object oriented and logical programming only
became official paradigms because there was a certain level of hype for
them in the 1980s and nobody has thought to strike them off the list after
the hype died down.

Object-oriented, as constituted today, is just a layer of abstraction over
imperative programming (or imperative style programming in functional
languages, because objects require side-effects).  What object-oriented
language actually in use now isn't just an imperative language with fancy
abstraction mechanisms?

The problem with having declarative languages as a paradigm (which logical
languages would be a part) is that it feels like it should be a
miscellaneous category.  Being declarative doesn't tell you much except
that some machine is going to turn your descriptions of something into some
kind of action.  In logical programming it is a set of predicates, but it
could just as easily be almost anything else.  In a way all languages are
declarative, it is just that we have some standard interpretations of
what is declared that are very common (imperative and functional).

My wish is that the idea of there being four paradigms would be abandoned
the same we the idea of four food groups has been abandoned (which may
surprise some of you).  We have more than four different modes of thinking
when programming and some are much more important than others and some are
subsets of others.  We should teach students a more sophisticated view.

Ironically Wikipedia also shows us this complexity.  The
programming language paradigm side bar actually reveals the wealth
of different styles that are available.  There is simply no clean and
useful way to overlay the four paradigms over what we see there, so it
should be abandoned because it gives students a false idea.


On Wed, Apr 17, 2013 at 9:42 AM, Andreas Abel andreas.a...@ifi.lmu.dewrote:

 [ The Types Forum, http://lists.seas.upenn.edu/**
 mailman/listinfo/types-listhttp://lists.seas.upenn.edu/mailman/listinfo/types-list]

 On 17.04.2013 11:30, Uday S Reddy wrote:

 Mark Janssen writes:

  From:  en.wikipedia.org: Programming_paradigm:

 A programming paradigm is a fundamental style of computer
 programming. There are four main paradigms: object-oriented,
 imperative, functional and declarative. Their foundations are distinct
 models of computation: Turing machine for object-oriented and
 imperative programming, lambda calculus for functional programming,
 and first order logic for logic programming.


 I removed the second sentence relating paradigms to computation models
 and put it on the talk page instead.  It does not make sense to connect
 imperative programming to Turing machines like functional programming to
 lambda calculus.  A better match would be random access machines, but the
 whole idea of a connection between a programming paradigm and a computation
 model is misleading.


  While I understand the interest in purely theoretical models, I wonder
 two things:  1)  Are these distinct models of computation valid?  And,
 2) If so, shouldn't a theory of types announce what model of
 computation they are working from?


 These distinctions are not fully valid.

 - Functional programming, logic programming and imperative programming are
 three different *computational mechanisms*.

 - Object-orientation and abstract data types are two different ways of
 building higher-level *abstractions*.

 The authors of this paragraph did not understand that computational
 mechanisms and higher-level abstractions are separate, orthogonal
 dimensions
 in programming language design.  All six combinations, obtained by
 picking a
 computational mechanism from the first bullet and an abstraction mechanism
 from the second bullet, are possible.  It is a mistake to put
 object-orientation in the first bullet.  Their idea of paradigm is vague
 and ill-defined.

 Cheers,
 Uday Reddy



 --
 Andreas AbelDu bist der geliebte Mensch.

 Theoretical Computer Science, University of Munich
 Oettingenstr. 67, D-80538 Munich, GERMANY

 andreas.a...@ifi.lmu.de
 http://www2.tcs.ifi.lmu.de/~**abel/ http://www2.tcs.ifi.lmu.de/~abel/

-- 
http://mail.python.org/mailman/listinfo/python-list