I think I exagerated a bit with the use of term "consortium". I'm mostly just refering to something like the java.security.SecureRandom SPI (practically Identical but specifically not for encryption grade RNG). This way, if you write an application that uses (lets call it RandomFactory), and there are service providers for a bunch of different Random Number generators out there, then you don't need to "rewrite" your code to test it performance/correlation on different generators.
A RandomGenerator deals in producing 32 bit integers from the uniform distribution, all other stuff belongs into the area of "distributions" and convenience classes. The most minimal interface one needs is something like this (proposal):
/**
* Interface for uniform pseudo-random number generators.
*/
public interface RandomGenerator {/**
* Returns a 32 bit uniformly distributed random number in the closed interval <tt>[Integer.MIN_VALUE,Integer.MAX_VALUE]</tt> (including <tt>Integer.MIN_VALUE</tt> and <tt>Integer.MAX_VALUE</tt>);
*/
public int nextInt();
}
One might want to add a few more convenience methods, although all of these (and others) can be implemented in terms of the interface above:
/**
* Interface for uniform pseudo-random number generators.
*/
public interface RandomGenerator {/**
* Returns a 32 bit uniformly distributed random number in the open unit interval <code>(0.0,1.0)</code> (excluding 0.0 and 1.0).
*/
public double raw();
/**
* Returns a 64 bit uniformly distributed random number in the open unit interval <code>(0.0,1.0)</code> (excluding 0.0 and 1.0).
*/
public double nextDouble();
/**
* Returns a 32 bit uniformly distributed random number in the closed interval <tt>[Integer.MIN_VALUE,Integer.MAX_VALUE]</tt> (including <tt>Integer.MIN_VALUE</tt> and <tt>Integer.MAX_VALUE</tt>);
*/
public int nextInt();
/**
* Returns a 64 bit uniformly distributed random number in the closed interval <tt>[Long.MIN_VALUE,Long.MAX_VALUE]</tt> (including <tt>Long.MIN_VALUE</tt> and <tt>Long.MAX_VALUE</tt>).
*/
public long nextLong();
/**
* Returns a 32 bit uniformly distributed random number in the open unit interval <code>(0.0f,1.0f)</code> (excluding 0.0f and 1.0f).
*/
public float nextFloat();
}
If Paul agrees, perhaps we can all settle on such an interface (or similar). Further, RngPack with BSD license could get back into colt again.
Wolfgang.
Also, can you possibly comment on your position and or interest concerning the possible inclusion of some parts of your codebase into Jakarta Commons Math in the possible future? That is, if our ASF licensing permits.
Overall, I've moved on to other areas (P2P databases). So these days, I'm maintaining colt on a very minimal time budget, and if someone else (like jakarta-commons) picks up the theme, it would be very good and welcome.
Interestingly, I'm becoming involved with some efforts here at Harvard to implement what we're calling the "Crimson Grid Initiative". I may be reviewing your software (Firefish and Spitfire) in the near future :-)
Feel free to include parts of colt into commons and modify as you feel appropriate under the license, which is Apache-style, and requires the copyright to be retained. I gather that this could be the crux for ASF. Unfortunately I myself can't transfer the copyright, since it does not belong to me, but rather my (former) research organisation, CERN. If this should not work for ASF, colt may still be worth looking at when contemplating your design and impl. questions.
I will be consulting with ASF to find out exactly what we can work with while maintaining copyright. Unfortunately, this may be a limitiation. But I'll try to find out more before speculating any further.
Many Thanks, Mark
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
