home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #19 / NN_1992_19.iso / spool / comp / lang / misc / 2920 < prev    next >
Encoding:
Text File  |  1992-09-03  |  3.4 KB  |  70 lines

  1. Newsgroups: comp.lang.misc
  2. Path: sparky!uunet!gatech!usenet.ins.cwru.edu!agate!overload.lbl.gov!dog.ee.lbl.gov!hellgate.utah.edu!lanl!cochiti.lanl.gov!jlg
  3. From: jlg@cochiti.lanl.gov (Jim Giles)
  4. Subject: Re: Scientists as Programmers (was Re: Small Language Wanted)
  5. Message-ID: <1992Sep3.164937.2746@newshost.lanl.gov>
  6. Sender: news@newshost.lanl.gov
  7. Organization: Los Alamos National Laboratory
  8. References: <BEVAN.92Aug31101447@tiger.cs.man.ac.uk> <180ignINN60q@network.ucsd.edu> <BEVAN.92Sep2101315@tiger.cs.man.ac.uk>
  9. Date: Thu, 3 Sep 1992 16:49:37 GMT
  10. Lines: 58
  11.  
  12. In article <BEVAN.92Sep2101315@tiger.cs.man.ac.uk>, bevan@cs.man.ac.uk (Stephen J Bevan) writes:
  13. |> [...]
  14. |> I much more interested in improving the semantics to support higher
  15. |> level concepts (such as those found in APL, Haskell or partly FORTRAN
  16. |> 90), than fussing over syntax.  [...]
  17.  
  18. The problem is that syntax is probably the *most* important aspect of
  19. the language's design with respect to its usability.
  20.  
  21. |> [...]                          One reason for this is to find out
  22. |> what the required concepts are, rather than get lost in irrelevant
  23. |> syntax.  [...]
  24.  
  25. If you get lost in the syntax, it is poorly designed.  And you probably
  26. will not have a well designed language overall - no matter *what* the
  27. semantic features are.
  28.  
  29. |> [...]      For exmple, consider distributed sum and product in maths:
  30. |> each has a separate notation (sigma, capital pi) and there is no
  31. |> general distribution notation.  As APL programmers have found, there
  32. |> are lots of useful things you can do once you have a general notation
  33. |> for distribution, reducing, scanning ... etc.  [...]
  34.  
  35. Yet, APL never became overwhelmingly popular - largely because of
  36. its poorly designed syntax.  Yes, the operations of fold, scan, etc.
  37. (as they are called in the haskell standard prelude) are important.
  38. It is also important that they *not* look like `line noise' when used.
  39.  
  40. |> [...]                                        I therefore advocate
  41. |> getting the semantics right, _then_ you can worry about producing a
  42. |> "nice" syntax.  [...]
  43.  
  44. I recommend doing both concurrently - and backtracking when conflicts
  45. arise.  The "do the semantics first" approach is why APL is so illegible.
  46.  
  47. |> [...]                          So whilst I'll agree that "CS
  48. |> people" could be more flexible and try to accomodate "scientists"
  49. |> syntactic wishes, I also think that "scientists" could do with
  50. |> questioning the notation they come up with and look for underlying
  51. |> concepts rather than producing endless stream of special cases.
  52.  
  53. Yet, when I proposed the same sort of thing about six months ago, the
  54. APL supporters on the net vehemently attacked me because my proposed
  55. *syntax* was different than theirs. 
  56.  
  57. Also, there are *syntactic* distinctions which are important to ease of
  58. use.  For example, in scientific code, one type of reduction dominates
  59. over all others and is usually used in a different way.  Summation is often
  60. used in tensor work in a way that other reductions seldom are: with disjoint
  61. sets of covariant indices (exclusive-or is used in similar ways for coding
  62. work, but it *is* summation - with add restricted to boolean).  Other
  63. reductions are usually the reduction of a single indexed object (which may
  64. be the result of an expression).  Having a unified syntax for all reductions
  65. *and* an extended for specialized for summation would make legibility and
  66. usability easier than having *only* the single, most general reduction.
  67.  
  68. -- 
  69. J. Giles
  70.