commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Phil Steitz" <p...@steitz.com>
Subject Re: [math] proposed ordering for task list, scope of initial release
Date Tue, 10 Jun 2003 19:37:27 GMT
Al Chou wrote:
> --- Phil Steitz <phil@steitz.com> wrote:
> 
>>Al Chou wrote:
>>
>>>--- Brent Worden <brent@worden.org> wrote:
>>>
>>>>>-----Original Message-----
>>>>>From: Phil Steitz [mailto:steitzp@yahoo.com]
>>>>>Sent: Friday, June 06, 2003 12:21 PM
>>>>
> [deletia]
> 
>>>>Something similar to JUnit's assertEquals(double expected, double actual,
>>>>double epsilon).
>>>
>>This is a good idea.
>>
>>
>>>Is JUnit's license (http://www.opensource.org/licenses/ibmpl.php) Apache
>>>compatible?
>>>
>>
>>I think that Brent is talking about defining a new function called 
>>something like approximatelyEquals() that returned a boolean.  The 
>>signature, semantics and implementation of this would be different from 
>>JUnit.
> 
> 
> Ah, OK.  That could be useful indeed.
> 
> 
> 
>>>>Simple methods like isPositive, isNegative, etc. can be used to make
>>>
>>boolean
>>
>>>>expressions more human readable.
>>>
>>>
>>>I'm willing to build those two on top of sign (I'm so generous with my
>>
>>coding
>>
>>>time, eh? <g>).  Are those two sufficient?  sign treats 0 as positive,
>>
>>which
>>
>>>may not be desirable.
>>>
>>
>>+1 (especially the part about your time :-)
> 
> 
> OK, I'll TDD those up, hopefully resolving the question of what to do about the
> sign of 0 in the process.
> 
Forgot to weigh in on this.  I would say that 0 is neither positive nor 
negative.  If that is not a happy state, I would prefer to call 
isPositive, "isNonNegative".  I know that is ugly, I have a hard time 
calling 0 a positive number.  So, my first should would be isPositive 
and isNegative both fail for zero, second would be to rename as above.

> 
> 
> Al
> 
> =====
> Albert Davidson Chou
> 
>     Get answers to Mac questions at http://www.Mac-Mgrs.org/ .
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
> http://calendar.yahoo.com
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: commons-dev-help@jakarta.apache.org
> 




---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message