Gabriel Dos Reis | 7 Feb 2012 10:34
Picon
Favicon

Re: [open-axiom-devel] String vs List

Waldek Hebisch <hebisch@...> writes:

| Serge D. Mechveliani wrote:
| > 
| > On Sun, Feb 05, 2012 at 01:56:20AM +0100, Ralf Hemmecke wrote:
| > > On 02/04/2012 06:13 PM, Serge D. Mechveliani wrote:
| > >> [..]
| > >>>>    dropWhile(p: Character ->  Boolean, xs: List Character) :
| > >>>>                                                List Character ==
| > >>>>                              empty? xs   =>  xs
| > >>>>                              p first(xs) =>  dropWhile(p, rest xs)
| > >>>>                              xs
| > >>>> Is this more efficient?

[...]

| Spad compiler will inline "simple enough" functions.  Unfortunately,
| currently this means functions consisting of single operation.
| 
| Your version will generate the following Lisp code:
| 
| (DEFUN |TTT;dropWhile;M2L;1| (|p| |xs| $)
|   (COND ((OR (NULL |xs|) (NULL (SPADCALL (|SPADfirst| |xs|) |p|))) |xs|)
|         ('T (SPADCALL |p| (CDR |xs|) (QREFELT $ 8)))))

OpenAxiom resolves these SPADCALLs within the same package/domain and
produces 

  (DEFUN |SERGEI;dropWhile;M2L;1| (|p| |xs| $)
    (COND ((OR (NULL |xs|) (NOT (SPADCALL (|SPADfirst| |xs|) |p|))) |xs|)
(Continue reading)

Gabriel Dos Reis | 14 Feb 2012 09:54
Picon
Favicon

Re: [open-axiom-devel] record selector

"Serge D. Mechveliani" <mechvel@...> writes:

| In Spad,  rc.foo  
| 
| selects a field named  foo  in a record  rc.
| In Haskell, this is  
|                     foo rc   -- similar as applying any function.
| 
| Indeed,  foo  has type  Record(foo : Foo, ...) -> Foo.
| In particular, it allows, for example,  
|                               map foo (records :: List Record(...)).

Haskell does not really have first class records, Haskell' folks are
agonizing over how to properly define records in Haskell and what to do
with the dot notation.  See the various record and dot proposals and
ongoing discussion on Haskell' list.

  http://hackage.haskell.org/trac/ghc/wiki/Records/DotOperator

  http://www.haskell.org/pipermail/haskell-prime/2012-February/003515.html

  http://www.haskell.org/haskellwiki/TypeDirectedNameResolution

  http://hackage.haskell.org/trac/haskell-prime/wiki/TypeDirectedNameResolution

-- Gaby

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
(Continue reading)

Gabriel Dos Reis | 14 Feb 2012 10:08
Picon
Favicon

Re: [open-axiom-devel] setting a record

"Serge D. Mechveliani" <mechvel@...> writes:

| Another note on the Spad language:
| for a record 
|                         Foo(coef: Integer, exp: Integer, root: Integer),
| its setting syntax by   [1, 3, 2]  :: Foo
| is a bug farm.
| Is not it?
| The syntax like         [coef := 1, exp := 3, root := 2]

the suggested syntax already has a valid meaning: it sets three
variables and return a List Integer.  It does not look like a better
alternative to the current syntax.

| 
| (replace `:=' with something appropriate)
| is much more safe. And here the named fieds can be transposed, the 
| programmer will not need to remember the order of, say, 6 fields.  
| 
| Regards, 
| 
| ------
| Sergei
| mechvel@...

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
(Continue reading)

Gabriel Dos Reis | 18 Feb 2012 02:38
Picon
Favicon

[open-axiom-devel] CICM 2012: Last Call for Papers


         CICM 2012 - Conference on Intelligent Computer Mathematics
           July 9-13, 2012 at Jacobs University, Bremen, Germany

              http://www.informatik.uni-bremen.de/cicm2012/

                             Call for Papers
----------------------------------------------------------------

As computers and communications technology advance, greater
opportunities arise for intelligent mathematical computation. While
computer algebra, automated deduction, mathematical publishing and
novel user interfaces individually have long and successful histories,
we are now seeing increasing opportunities for synergy among these
areas. The Conference on Intelligent Computer Mathematics offers a
venue for discussing these areas and their synergy.

The conference will be organized by Serge Autexier and Michael
Kohlhase at Jacobs University in Bremen and consist of five tracks:

Artificial Intelligence and Symbolic Computation (AISC)
  Co-Chairs: John A. Campbell, Jacques Carette
Calculemus
  Chair: Gabriel Dos Reis
Digital Mathematical Libraries (DML)
  Chair: Petr Sojka
Mathematical Knowledge Management (MKM)
  Chair: Makarius Wenzel
Systems and Projects
  Chair: Volker Sorge
(Continue reading)

Gabriel Dos Reis | 21 Feb 2012 17:40
Picon
Favicon

Re: [open-axiom-devel] record selector

"Serge D. Mechveliani" <mechvel@...> writes:

| On Tue, Feb 14, 2012 at 02:54:17AM -0600, Gabriel Dos Reis wrote:
| > "Serge D. Mechveliani" <mechvel@...> writes:
| > 
| > | In Spad,  rc.foo  
| > | 
| > | selects a field named  foo  in a record  rc.
| > | In Haskell, this is  
| > |                     foo rc   -- similar as applying any function.
| > | 
| > | Indeed,  foo  has type  Record(foo : Foo, ...) -> Foo.
| > | In particular, it allows, for example,  
| > |                               map foo (records :: List Record(...)).
| > 
| > Haskell does not really have first class records, Haskell' folks are
| > agonizing over how to properly define records in Haskell and what to do
| > with the dot notation.  See the various record and dot proposals and
| > ongoing discussion on Haskell' list.
| > 
| >   http://hackage.haskell.org/trac/ghc/wiki/Records/DotOperator
| > [..]
| 
| 
| 1. I think, it has quite good records. For example,
| 
| --------------------------------------------------
| data Gauss r = Gauss {real :: r, im :: r}
|                -- a record
| 
(Continue reading)

Gabriel Dos Reis | 21 Feb 2012 18:33
Picon
Favicon

Re: [open-axiom-devel] record selector

Bill Page <bill.page@...> writes:

| I think your comment is very appropriate.  Since the semantics of
| Record is well represented as a limit (and dually, Union is
| represented as a co-limit), selecting a field is just projection (or
| injection in the case of Union). Axiom should respect this by have
| Record (and Union) export these operations.

I am having hard time understanding what exactly you are saying.  Could
you elaborate?

| It seems to me that the Axiom developers were ambivalent about the use
| of elt (dot), apply, eval and function application. There use could be
| simplified and clarified.

The canonical operator name for `function application' is `elt' in all
AXIOMs and that is what the axiom compilers and interpreters understand.
`eval' isn't application; it is evaluation which is a different notion.
All the rest is just user confusion :-)

-- Gaby

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
Gabriel Dos Reis | 22 Feb 2012 15:32
Picon
Favicon

Re: [open-axiom-devel] record selector

Bill Page <bill.page <at> newsynthesis.org> writes:

| On Feb 21, 2012 12:33 PM, "Gabriel Dos Reis" <gdr <at> cs.tamu.edu> wrote:
| >
| > Bill Page <bill.page <at> newsynthesis.org> writes:
| >
| > | I think your comment is very appropriate.  Since the semantics of
| > | Record is well represented as a limit (and dually, Union is
| > | represented as a co-limit), selecting a field is just projection (or
| > | injection in the case of Union). Axiom should respect this by have
| > | Record (and Union) export these operations.
| >
| > I am having hard time understanding what exactly you are saying.  Could
| > you elaborate?
| >
| 
| Yes but please ask a more specific question.

I thought I did.  I do understand the entire paragraph.

| > | It seems to me that the Axiom developers were ambivalent about the use
| > | of elt (dot), apply, eval and function application. There use could be
| > | simplified and clarified.
| >
| > The canonical operator name for `function application' is `elt' in all
| > AXIOMs and that is what the axiom compilers and interpreters understand.
| > `eval' isn't application; it is evaluation which is a different notion.
| > All the rest is just user confusion :-)
| >
| 
(Continue reading)


Gmane