Search the web
Sign In
New User? Sign Up
frink
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Message search is now enhanced, find messages faster. Take it for a spin.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Frink single interval question   Message List  
Reply | Forward Message #248 of 257 |
Re: [Frink] Frink single interval question

On 08/04/2009 01:48 AM, Alan Eliasen wrote:
> On 08/04/2009 01:15 AM, Alan Eliasen wrote:
>> Please note again that there have been changes in the 2009-07-19
>> release of Frink that affect this behavior. Since this update, some
>> expressions (notably x/x and sometimes x-x) will be symbolically
>> simplified, which may change your results and give you tighter bounds.
>> Note that the programmer is still always encouraged to pre-simplify
>> symbolic expressions when it makes sense.
>
> When thinking about this issue, I noticed that x-x can be simplified
> a bit more aggressively than it was before; the current (2009-08-04)
> release of Frink has this simplification. Thanks for the comments and
> questions!

This change turned out to be overly aggressive, and the changes were
removed. If you downloaded Frink earlier today, I'd recommend getting
the current version.

===========================

Technical Explanation: Many normal algebraic simplifications
*cannot* be performed on many of the data types used in Frink. For example:

* Intervals are not distributive. That is a(b+c) does not
necessarily equal (ab + ac)!

* If you want to preserve and check units of measure through all
calculations, you *cannot* perform some mathematical simplifications like
0 * x = 0
or
x + 0 = x

As these transformations will lose information about the units of
measure that may someday be contained in the variable x, or cause units
with different units of measure to be added to each other.

* Date/Time math cannot use some of these transformations. For
example, when subtracting dates, one normally obtains the duration
between those dates (say, in seconds.) However, if doing a
transformation like:

x - x = 0

the result comes out dimensionless, and *not* a duration. (This
case caused obvious errors in the change I checked in last night.)

--
Alan Eliasen
eliasen@...
http://futureboy.us/



Tue Aug 4, 2009 11:09 pm

aeliasen
Offline Offline
Send Email Send Email

Forward
Message #248 of 257 |
Expand Messages Author Sort by Date

Consider this frink program: x = new interval[-1,1] y = new interval[-1,1] println[x-y] println[x-x] The results are: [-2, 2] [-2, 2] The first one makes...
Kelly Jones
kelly.terry.jones@...
Send Email
Aug 4, 2009
5:21 am

... Kelly, This is addressed (in some detail) in the FAQ: http://futureboy.us/frinkdocs/faq.html#WhenXIsAnInterval Please note again that there have been...
Alan Eliasen
aeliasen
Offline Send Email
Aug 4, 2009
7:15 am

... When thinking about this issue, I noticed that x-x can be simplified a bit more aggressively than it was before; the current (2009-08-04) release of Frink...
Alan Eliasen
aeliasen
Offline Send Email
Aug 4, 2009
7:48 am

... This change turned out to be overly aggressive, and the changes were removed. If you downloaded Frink earlier today, I'd recommend getting the current...
Alan Eliasen
aeliasen
Offline Send Email
Aug 4, 2009
11:09 pm
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help