Welcome, Guest. Please login or register.

Author Topic: Language shopping  (Read 2425 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline mactoTopic starter

  • Full Member
  • ***
  • Join Date: Apr 2004
  • Posts: 111
    • Show all replies
Language shopping
« on: May 04, 2004, 03:58:16 AM »
So I saw REXX and thought, hey I remember that.  Maybe I can do it for a quick calculation.  (I was an OS/2 user about 10 years ago.)  I quickly rediscovered that that though was brain dead, because REXX doesn't like floats.

So, can anyone suggest a language which is:
(a) at least as common as REXX outside of the Amiga world
(b) interpreted, because I don't want to sit around for a compile and link
(c) can handle floats at least as well as C (which isn't saying much)
(d) is relatively small and fast, because I hate bloated software :pissed:

Have A2000 with 8 MB RAM (reliable).
Have A2000 with 68030 and 25 MB RAM (unreliable).
 

Offline mactoTopic starter

  • Full Member
  • ***
  • Join Date: Apr 2004
  • Posts: 111
    • Show all replies
Re: Language shopping
« Reply #1 on: May 04, 2004, 03:02:14 PM »
But I would be the laughing stock of all my friends.
:smack: <-- I'd be the fellow on the right.  ;-)

If there are no other suggestions, BASIC it will be.
 

Offline mactoTopic starter

  • Full Member
  • ***
  • Join Date: Apr 2004
  • Posts: 111
    • Show all replies
Re: Language shopping
« Reply #2 on: May 05, 2004, 04:44:27 PM »
I took a look at the Aminet and saw the tiny python packages.  I guess they stripped out the libraries.  If so, yippe!  (One of the things which bothers me about Python and Perl are the huge libraries which I would never use.)  I'll take a look at her, on my Amiga, shortly.  Thank-you.
 

Offline mactoTopic starter

  • Full Member
  • ***
  • Join Date: Apr 2004
  • Posts: 111
    • Show all replies
Re: Language shopping
« Reply #3 on: May 06, 2004, 04:10:25 AM »
REXX can handle floats, but it isn't terribly suited to numerical work.  It lacks mildly interesting mathematical functions, may that be trignometric or otherwise.  So I checked out rexxmathlib.

When I downloaded rexxmathlib, there were worrying comments about round-off error in the documentation.  To give you an idea of what this means, I tried solving a simplified version of this problem in DICE.  It was simplified so that I could find an exact solution and compare it to an iterative solution.  The difference between the two solutions was about 1%.  I would expect REXX to be greater.

The rexxmathlib documentation also suggested that floats were stored in 15.9 format.  While it wasn't a problem in this case, I often deal with problems which have very big or very small numbers.  For that, I need floats, and not some sort of fixed precision decimal (assuming I have the right name).

I tried DICE.  It was relatively small (can you tell that I have dealt with GCC too much :pissed: ), and I was impressed with the speed on my 68030, which is actually behaving well for the moment. :-D

But I'll try Python later because I think it has arbitrary precision arithmetic libraries.  Or was that Perl.  I forget.  At any rate, while DICE is fast I have found compilers on other platforms to be sluggish.  Why is beyond me.  So interpreted langages can be nice.