Files | Admin

Notes:

Release Name: pre-alpha-0.21

Notes:
Version
-------

This version ($Name: PRE_ALPHA_0_21 $) is functionally identical with the
previous pre-alpha-0.20.  Improvements are for speed, because the
convergence acceleration for logarithm is done in a more efficient
way.  This influences methods log2, log10 and power of LongMath.

There are no known bugs and this version can be considered complete in
terms of functionality.  This version is still a pre-alpha-version,
but it is expected to move it to alpha within the next weeks, after
having added some more tests and having fixed potential bugs that
these tests might reveal.  The first alpha version is not expected to
be much different from this version.  This version should already be
usable.  Operations +, -, *, / and sqrt should be working properly.
Even log, exp and power should be fine, but they might have some
issues in terms of precision of the last digits provided or in terms
of speed.  It would be a good idea to do some mathematical analysis on
how many digits are needed internally to guarantee the correctness of
the digits that are provided.  Testing as well as rough analysis
indicate that this might be correct already.

This software development effort is hosted on RubyForge (
http://rubyforge.org/ ) under the project name "long-decimal", to be
found directly with http://rubyforge.org/projects/long-decimal/ .  So
you should feel encouraged to look if there is a newer version, when
you install long-decimal.

Test
----

Some runit tests have been included.  They give some indication of the
correctness of this library and allow changes to be checked in order
to make sure that what was running before would still work afterwards.
Tests for a library as complex as long-decimal can never be
exhaustive, but they give a good indication that methods are working
correctly.  About 90% of the tests that will be eventually needed are
already present.  As a policy a release is not created unless all
tests succeed.  Running the tests can take a few minutes, depending on
your machine.  It is about 15 minutes on my machine (1300 MHz).
Whatever is gained by making the software run faster is used up again
by adding more tests.  This is the result of the test:

Finished in 869.98785 seconds.
102 tests, 44345 assertions, 0 failures, 0 errors

Install
-------

(REMARK: installation has only been successfully tested on Linux with
ruby 1.8.4 and on Windows 2000 with ruby 1.8.2)

1. Using ruby-gems (preferred)
- open a shell window
- become root, unless the current user has the right to install gems
  (which is usually the case on windows)

  su

- uninstall old versions

  gem uninstall long-decimal

- install the newest version

  gem install long-decimal

- Usage from your ruby-programs:

  require "rubygems"
  require_gem "long-decimal"

- documentation will be found in HTML-format in the directory
  $RUBY_DIR/gems/$RUBY_VERSION/doc/long-decimal-$LONG_DECIMAL_VERSION/rdoc/index.html
  where $RUBY_DIR is the directory containing your ruby-installation,
                  usually /usr/lib/ruby or /usr/local/lib/ruby on
                  Linux/Unix-systems.
        $RUBY_VERSION is the major version of your Ruby, like 1.8
        $LONG_DECIMAL_VERSION is the version of long-decimal that you
                              have installed, like 0.00.20
  on my machine that would be
  /usr/local/lib/ruby/gems/1.8/doc/long-decimal-0.00.20/rdoc/index.html

2. Installing from the sources (it is preferred to use the
   gem-installation, but since long-decimal is open-source-software you
   are off course granted the right to download the source and change
   it and install your own version.

- download the newest source-tar.gz-file from long-decimal project at rubyforge
  which can be found by
  http://rubyforge.org/projects/long-decimal/ -> Files
  ( http://rubyforge.org/frs/?group_id=1334 )
- open a shell window
  cd to the directory where you have downloaded the gem-file
  unpack the file using tar
  tar xfzvv long-decimal-pre-alpha-0_17.tar.gz
  cd long-decimal
- now you can use rake for several operations
  - rake test
      runs runit tests.  All tests should succeed.
  - rake doc
      creates the documentation
  - rake gem creates the gem-file in a sub-directory pkg
      recommended for installation, proceed as in 1
  - cd pkg
  - gem install --local long-decimal


3. The documentation can be created from the sources.  It is contained
in the gem-file.  It is not provided as a separate file any more.

License
-------

Ruby's license or LGPL
Find copies of these licenses on http://www.gnu.org/ or http://www.ruby-lang.org/

Warranty
--------

This is a pre-alpha-version.  Do not expect too much!  This is work in progress!
I do not take any responsibility.  Please use it as it is, change it
according to the terms of the license or wait for a more stable
version (for wich I can't take any warranty either...)

Author
------

Karl Brodowsky
http://www.velofahren.de/cgi-bin/mailform.cgi
(no direct mail address because I do not like spam)



Changes: added some more tests improved speed of exp and log and power added caching for sqrt of common values