Updated 2001/06/06 |
Sun WorkShop[tm] 6 update 2 Interval Arithmetic Readme |
Contents
- Introduction
- About Sun WorkShop 6 update 2 Interval Arithmetic
- New Features
- Software Corrections
- Problems and Workarounds
- Limitations and Incompatibilities
- Documentation Errata
A. Introduction
This document contains last-minute information about this release of interval arithmetic. This document describes the software corrections addressed by this release and lists known problems, limitations, and incompatibilities.
For installation-related and late-breaking information about this release, see the Sun WorkShop 6 update 2 Release Notes. Information in the release notes overrides information in all readme files.
To access the release notes and the full Forte[tm] Developer/Sun WorkShop[tm] documentation set, point your Netscape[tm] Communicator 4.0 or compatible browser to the documentation index (file:/opt/SUNWspro/docs/index.html).
To view the text version of this readme, type the following at a command prompt:
example% more /opt/SUNWspro/READMEs/interval_arithmeticTo access the HTML version of this readme, point your Netscape Communicator 4.0 or compatible browser to:
file:/opt/SUNWspro/docs/index.htmlNote - If your Sun WorkShop software is not installed in the /opt directory, ask your system administrator for the equivalent path on your system.
B. About Sun WorkShop 6 update 2 Interval Arithmetic
This release of interval arithmetic runs on SPARC[tm] processors running Solaris[tm] SPARC Platform Edition versions 2.6, 7 and 8, and is a second update to the Sun WorkShop 6 release.
Support for intrinsic INTERVAL data types is a feature in the Sun WorkShop 6 Fortran 95 compiler. Two new compiler flags, -xia and -xinterval, tell the compiler to recognize interval-specific language extensions and to generate executable interval code.
The Sun WorkShop 6 C++ compiler provides a C++ interface to the C++ interval arithmetic library. To use the C++ interval arithmetic features, add the #include <suninterval.h> header file to the code, and then compile the code using the -xia command-line option.
What Is Interval Arithmetic?
Interval arithmetic is used to evaluate arithmetic expressions over sets of numbers contained in intervals. An interval is the set of all real numbers between and including the lower and upper bound of the interval. Any interval arithmetic result is a new interval that is guaranteed to contain the set of all possible resulting values.
With Sun WorkShop 6 Fortran 95, it is a simple matter to write interval programs to compute rigorous bounds on the value of arithmetic expressions:
- Declare variables to be type INTERVAL.
- Write normal Fortran code including the intrinsic INTERVAL functions and operators, relational operators, and format edit descriptors.
- Compile the code using the -xia command-line option.
To achieve the best results, use existing interval algorithms that compute narrow-width interval results. Devising algorithms to compute narrow interval results is the topic of interval analysis. For information on interval algorithms, see "Where Can I Get More Information?".
Why Is Interval Arithmetic Important?
Interval arithmetic is important for the following reasons:
- Interval arithmetic can be used to perform machine computations with guaranteed bounds on errors from all sources, including input data errors, machine rounding errors, and their interactions.
- Interval algorithms can be used to solve nonlinear problems, such as the solution to nonlinear systems of equations and nonlinear programming (the nonlinear extension to linear programming).
As intervals become more widely used, libraries of interval solvers will be used routinely to compute sharp (narrow width) interval solutions to linear and nonlinear problems, while taking into account all sources of error. With these libraries, scientists, engineers, and developers of commercial applications will be able to write programs to solve problems that are currently beyond reach.
Where Can I Get More Information?
An introduction to interval arithmetic can be viewed at:
http://www.sun.com/forte/info/features/intervals.htmlFor information on the interval features added to Fortran 95, see the Interval Arithmetic Programming Reference available from http://docs.sun.com in the Forte for High Performance Computing 6 update 2/ Sun WorkShop 6 update 2 Compilers for Fortran 77/95 Collection. For information on C++ interval arithmetic support, see the C++ Interval Arithmetic Programming Reference available from http://docs.sun.com in the Forte Developer 6 update 2/Sun WorkShop 6 update 2 Collection.
Additional sources of interval information can be viewed at:
These web sites contain links to the following information:http://www.sun.com/forte/fortran/intervalor
http://www.sun.com/forte/cplusplus/interval
- A detailed bibliography
- An interval FAQ for Fortran 95 and C++
- Instructions for subscribing to an email list for discussing interval arithmetic topics
- Instructions for reporting a suspected interval error
- Information on interval code development
- Information on past cooperative research projects
C. New Features
New Features
This section describes the new and changed features for Sun WorkShop 6 update 2 Interval Arithmetic.
There are no new features in this release. This release does include the bug fix listed in Software Corrections.
Features in the Sun WorkShop 6 update 1 Release
The Sun WorkShop 6 update 1 release of interval arithmetic introduced the following features:
- C++ Support
Sun WorkShop 6 update 1 Compilers C++ (5.2) provides a C++ interface to the C++ interval arithmetic library. For more information, see the C++ Interval Arithmetic Programming Reference available from
http://docs.sun.com(in the Forte Developer 6 update 1/Sun WorkShop 6 update 1 Collection) or
http://www.sun.com/forte/cplusplus/intervalFor information about related compiler options, see the following entries in the CC(1) man page:
- -xia
- -library=[no%]interval
The C++ interval arithmetic library is compatible with interval arithmetic as implemented in the Fortran compiler.
To use the C++ interval arithmetic features, add the following header file to the code.
#include <suninterval.h>
An example of compiling code using the -xia command-line option is shown here.
example% CC -o filename -xia filename.cc
- Dependent Subtraction Operator Added to Fortran 95 Interval Arithmetic
The dependent subtraction operator .DSUB. can be used to recover either operand of a previous interval addition.
Two interval variables are dependent when one interval variable is a result of an interval arithmetic operation applied to the other interval variable. For example, if X = A + B, then X depends on both A and B. Dependent interval subtraction produces narrower interval results when recovering A or B from X.
Dependent operations cannot be applied to interval constants because constants are independent. Applying dependent operations to interval constants produces a compile-time error.
The result of X.DSUB.A contains the solution for B of the interval equation X = A + B. The result is [-inf,inf] if there is no solution.
- Random Number Subroutine Added to Fortran 95 Interval Arithmetic
RANDOM_NUMBER(HARVEST) returns through the interval variable HARVEST one pseudorandom interval [a, b], or an array of pseudorandom intervals from uniform distributions over the ranges 0 <= a <= 1, and a <= b <= 1.
- Division With Intersection Function Added to Fortran 95 Interval Arithmetic
The function DIVIX returns the interval enclosure of the result of the interval division operation (A/B) intersected with the interval C.
In the case when A contains zero, the mathematical result of the interval division operation (A/B) is the union of two disjoint intervals. Each interval in the union can be represented in the currently implemented interval arithmetic system. The DIVIX function is a convenient way to compute one or both of these intervals.
D. Software Corrections
Compilation Time With -xia Option (Interval Arithmetic) on V9 Platforms
The following bug has been corrected in this release of interval arithmetic.
A bug in peephole optimization (4361621) has been fixed so that compiling with the combined options -xia -04 -xarch=v9 or v9b no longer takes an excessive amount of time. It is no longer necessary to compile code with an optimization level lower than -04 or limit the use of -xia to only those program units that actually contain interval arithmetic syntax in the source.
Using -xia and -xinterval With -fsimple or -fns Command-Line Options
The following bug was reported in the Sun WorkShop 6 version of interval arithmetic.
-xinterval={widestneed|strict} and -xia={widestneed|strict} command line options cannot be used with either -fsimple or -fns options set to any value other than -fsimple=0 and -fns=no.
This restriction is not always enforced when the -xia option is used in combination with other options (for example -fast) that can set either -fsimple or -fns. For this reason, specify the -xia option last on the command line.
The Sun WorkShop 6 update 1 version of interval arithmetic was changed so that the following applies.
When using the -xia={widestneed|strict} or -xinterval={widestneed|strict} command line option with the -fsimple and -fns options set to any values other than -fsimple=0 and -fns=no, make sure that -xia or -xinterval occurs after -fsimple or -fns on the command line.
-xia expands into -fsimple=0 -fns=no, which suppresses any previous values for -fsimple and -fns. After setting -xinterval, an error occurs if -fsimple is set to a value other than 0 or -fns is set to a value other than no.
E. Problems and Workarounds
This section discusses software bugs that could not be fixed in time for this release. (For updates, check Forte Developer Hot Product News, http://www.sun.com/forte/developer/hotnews.html)
There is no new information at this time.
F. Limitations and Incompatibilities
There is no new information at this time.
G. Documentation Errata
The interval-specific function is_empty is incorrectly listed in the C++ Interval Arithmetic Programming Reference as isempty. The correct name of the interval-specific function is is_empty.
Copyright 2001 Sun Microsystems, Inc., 901 San Antonio Road, Palo Alto, CA 94303, U.S.A. All rights reserved.
Sun, Sun Microsystems, the Sun logo, docs.sun.com, and Solaris are trademarks, registered trademarks, or service marks of Sun Microsystems, Inc. in the U.S. and other countries.