Re: [math] UnexpectedNegativeIntegerException

2012-09-03 Thread Ole Ersoy
Hi, I realize I'm a little late to the party here, so if I'm asking or suggesting things that are naive just let me know straight up, and I'll try to educate myself better. I will say that I really enjoy reading these threads because I learn a great deal from them. As a user of commons math

Re: [math] UnexpectedNegativeIntegerException

2012-09-05 Thread Ole Ersoy
Hi Gilles, On 09/04/2012 06:48 PM, Gilles Sadowski wrote: Hello. There are ideas that sound good we experiment with them within a limited framework (like a course on programming, for example); and then become a nightmare when you find yourself constantly trying to get around them. I mean that a

Re: [math] UnexpectedNegativeIntegerException

2012-09-06 Thread Ole Ersoy
to the "Solution". Cheers, - Ole On 09/06/2012 07:02 AM, luc wrote: Le 2012-09-06 00:38, Gilles Sadowski a écrit : On Wed, Sep 05, 2012 at 08:16:34PM +0200, Luc Maisonobe wrote: Le 05/09/2012 19:09, Ole Ersoy a écrit : > Hi Gilles, > > On 09/04/2012 06:48 PM, Gilles Sadows

Re: [Math] About "NullArgumentException"

2012-09-09 Thread Ole Ersoy
Yes. One example is the constructor for EmpiricalDistribution that takes a RandomGenerator as argument. If a null is supplied, the constructor does not complain and the lazy initialization works as though the argumentless constructor had been used and a JDK random generator is created. There

Re: [Math] Java version

2015-01-13 Thread Ole Ersoy
I would love to see Java 8. Ole On 01/13/2015 07:31 PM, Gilles wrote: Raising this issue once again. Are we going to upgrade the requirement for the next major release? [ ] Java 5 [ ] Java 6 [ ] Java 7 [ ] Java 8 [ ] Java 9 Counts up to now: Java 7 -> 2 Java 7 or 8 -> 2 Java 8

Re: [Math] Java version

2015-01-14 Thread Ole Ersoy
Converting an example from the user guide using Lambdas (Not an expert so bear with me - And note that the inputArray > inputStream): BEFORE: // Get a DescriptiveStatistics instance DescriptiveStatistics stats = new DescriptiveStatistics(); // Add the data from the array for( int i = 0; i < in

Re: [Math] Java version

2015-01-15 Thread Ole Ersoy
How many of the mobile developers have to have a 4.0 release? I suspect that 90% would be fine using 3.4, and the remaining 10% can wire the results of the calculation using alternative means such as a REST or Socket service. Cheers, - Ole On 01/15/2015 11:32 AM, venkatesha m wrote: On

Re: [Math] Java version (Was: [MATH] Jenkins build)

2015-01-15 Thread Ole Ersoy
On 01/15/2015 03:24 PM, Thomas Neidhart wrote: On 01/08/2015 12:34 PM, Gilles wrote: Hi. Raising this issue once again. Are we going to upgrade the requirement for the next major release? [ ] Java 5 [x] Java 6 [x] Java 7 [ ] Java 8 [ ] Java 9 A while ago I thought that it wou

Re: [Math] Java version

2015-01-16 Thread Ole Ersoy
On 01/16/2015 03:09 AM, Thomas Neidhart wrote: On 01/16/2015 01:30 AM, Gilles wrote: On Thu, 15 Jan 2015 15:41:11 -0700, Phil Steitz wrote: On 1/15/15 2:24 PM, Thomas Neidhart wrote: On 01/08/2015 12:34 PM, Gilles wrote: Hi. Raising this issue once again. Are we going to upgrade the require

Re: [ALL] Too much traffic on the "dev" ML

2015-01-16 Thread Ole Ersoy
I agree - we're hung up on a clown from the 90s. It's so much simpler click watch on github and get notifications. Also stackoverflow has a much broader Java community and having traffic go through it could benefit this community. Ole On 01/16/2015 10:21 AM, Ben McCann wrote: I find the who

Re: [Math] Java version

2015-01-16 Thread Ole Ersoy
On 01/16/2015 09:08 AM, Gilles wrote: On Fri, 16 Jan 2015 15:16:16 +0100, Emmanuel Bourg wrote: Le 16/01/2015 13:20, Gilles a écrit : I'm interested to know more about this. Where can I find information? Do you have links? Sure, Andrew Haley from Red Hat announced [1] two years ago that Op

Re: [ALL] Too much traffic on the "dev" ML

2015-01-17 Thread Ole Ersoy
inating. Cheers, - Ole On 01/17/2015 08:23 AM, Gilles wrote: On Fri, 16 Jan 2015 16:00:45 -0600, Ole Ersoy wrote: I agree - we're hung up on a clown from the 90s. It's so much simpler click watch on github and get notifications. Also stackoverflow has a much broader Java communit

Re: [ALL] Too much traffic on the "dev" ML

2015-01-17 Thread Ole Ersoy
On 01/17/2015 01:16 PM, Duncan Jones wrote: On 17 January 2015 at 16:59, Ole Ersoy wrote: GIlles, Well said as always. With respect to the goal of growing the community, I think everyone agrees that that's a good goal. So if we pick tools that developers are most likely to be used to,

[Releases] Jitpack

2015-02-19 Thread Ole Ersoy
Just came across this on the Maven users list: https://jitpack.io/ Seems like it would be a great tool for managing releases. Cheers, - Ole - To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org For additional commands,

Re: [math] threading redux

2015-04-17 Thread Ole Ersoy
This is a pretty good read as well: http://stackoverflow.com/questions/21163108/custom-thread-pool-in-java-8-parallel-stream A concern in earlier discussions focused on controlling the number of threads that the job consumes. Theres one example of using a custom thread pool for that. Users co

Re: [math] threading redux

2015-04-22 Thread Ole Ersoy
That is one way to achieve parallelism. The Executor is one way to manage concurrently executing threads in a single process. There are other ways to do this. My challenge is to find a way to make it possible for users to plug in alternatives. Some of the methods on CompletableFuture allow th

Re: [math] threading redux

2015-04-22 Thread Ole Ersoy
On Mon, Apr 20, 2015 at 6:05 PM Phil Steitz wrote: There are lots of ways to allow distributed processes to share common data. Spark has a very nice construct called a Resilient Distributed Dataset (RDD) designed for exactly this purpose. Are there any examples of a class in commons math wher

Re: [math] threading redux

2015-04-23 Thread Ole Ersoy
It's the case for the only example that was mentioned in this thread with sufficient level of details so as to permit concrete statements: it's the SOFM implementation (in package "o.a.c.m.ml.neuralnet.sofm"). The shared structure is the "Network" instance. Can the KohonenTrainingTask be decomp

Re: plot distribution

2015-06-18 Thread Ole Ersoy
Hi Narjes, It's a good idea to prefix your subject with [math], since commons shares multiple projects. Going to take a stab from 50,000 feet. Use the Levenberg Marquardt optimizer to fit the distribution to the data. You could probably use more specific optimizers for certain types of dist

Re: plot distribution

2015-06-18 Thread Ole Ersoy
Narjes, Looking at this a little closer: http://racingtadpole.com/blog/curve-fitting-cdf-js-d3/ They may have solved it for you :). Cheers, - Ole On 06/18/2015 06:47 AM, narjes saraie wrote: Hi All. I am beginner in java and have some data.I want to guess a distribution for my data then calc

Re: [dbutils] Adding fluent api

2015-07-01 Thread Ole Ersoy
Just curious...would this be similar to JOOQ? http://www.jooq.org/ Cheers, - Ole On 07/01/2015 10:21 AM, Adrian Crum wrote: You can make the builder support generic SQL 2003, and provide a way to extend the builder with vendor-specific grammar. Adrian Crum Sandglass Software www.sandglass-so

Re: [dbutils] Adding fluent api

2015-07-01 Thread Ole Ersoy
On 07/01/2015 04:00 PM, Mansour Al Akeel wrote: Hello Kervin, Alot of these libraries, including JPA need to generate beans before you can use the query builder. QueryDSL is one example. I haven't used JOOQ, but I have seen their examples, and it looks a lot like what I thinking of. I am unabl

Re: [math] random boolean arrays

2015-07-11 Thread Ole Ersoy
How about a Randomize utility class? Cheers, - Ole On 07/11/2015 02:40 PM, sebb wrote: On 11 July 2015 at 20:29, Thomas Neidhart wrote: On 07/11/2015 09:08 PM, Phil Steitz wrote: The code implemented in MATH-1242 to improve performance of KS monteCarloP in-lines efficient generation of ran

[Math] Straight Line Problem Jacobian Verification

2015-08-06 Thread Ole Ersoy
Hi Guys, Reviewing the org.apache.commons.math4.fitting.leastsquares.StraightLineProblem (f(x) = ax + b). For the jacobian we have: // Partial derivative wrt "a". jacobian[i][0] = p[0]; // Partial derivative wrt "b". jacobian[i][1] = 1; Should

Re: [Math] Straight Line Problem Jacobian Verification

2015-08-06 Thread Ole Ersoy
Ooops - Never mind - crossed my calculus wires for a sec there - sorry for the noise, Ole On 08/06/2015 05:30 PM, Ole Ersoy wrote: Hi Guys, Reviewing the org.apache.commons.math4.fitting.leastsquares.StraightLineProblem (f(x) = ax + b). For the jacobian we have: // Partial

Re: [math] Negative max in class Incrementor

2015-08-28 Thread Ole Ersoy
This is a side note. In the class Incrementor there's a MaxCountExceededCallback that triggers the MaxCountExceededException. It might make sense to place the code that throws the exception in a static utility method inside the exception, eliminating the cb property, the MaxCountExceededCall

Re: [math] Negative max in class Incrementor

2015-08-28 Thread Ole Ersoy
On 08/28/2015 04:29 PM, Gilles wrote: On Fri, 28 Aug 2015 11:48:28 -0500, Ole Ersoy wrote: This is a side note. In the class Incrementor there's a MaxCountExceededCallback that triggers the MaxCountExceededException. It might make sense to place the code that throws the exception in a s

Re: [math] Negative max in class Incrementor

2015-08-29 Thread Ole Ersoy
On 08/29/2015 06:59 AM, Gilles wrote: On Fri, 28 Aug 2015 21:25:12 -0500, Ole Ersoy wrote: On 08/28/2015 04:29 PM, Gilles wrote: On Fri, 28 Aug 2015 11:48:28 -0500, Ole Ersoy wrote: This is a side note. In the class Incrementor there's a MaxCountExceededCallback that trigger

Re: [math] Negative max in class Incrementor

2015-08-29 Thread Ole Ersoy
I'm deleting most of the discussion, because I think I may be throwing too many ingredients on the table. For further context please see the previous thread. I don't get that. Here the main purpose is to set a hard limit that will raise an exception (to avoid that some algo from running forev

Re: [math] Negative max in class Incrementor

2015-08-30 Thread Ole Ersoy
On 08/30/2015 08:18 AM, Gilles wrote: Hi. On Sat, 29 Aug 2015 22:21:55 -0500, Ole Ersoy wrote: I'm deleting most of the discussion, because I think I may be throwing too many ingredients on the table. For further context please see the previous thread. I don't get that. Her

Re: [math] Negative max in class Incrementor

2015-08-30 Thread Ole Ersoy
On 08/30/2015 04:13 PM, Gilles wrote: On Sun, 30 Aug 2015 14:45:19 -0500, Ole Ersoy wrote: On 08/30/2015 08:18 AM, Gilles wrote: Hi. On Sat, 29 Aug 2015 22:21:55 -0500, Ole Ersoy wrote: I'm deleting most of the discussion, because I think I may be throwing too many ingredients on the

Re: [Math] Compile only top-level package and below

2015-09-04 Thread Ole Ersoy
You have left over files in `target` after switching between the branches. For example check out `math4`. Build it. Switch to the `math3` branch. Build it. Now `target` will contain both classes from the math3 branch and the math4 branch. Run clean before switching between branches and yo

Re: [Math] Compile only top-level package and below

2015-09-04 Thread Ole Ersoy
On 09/04/2015 10:26 AM, Gilles wrote: On Fri, 4 Sep 2015 10:11:04 -0500, Ole Ersoy wrote: You have left over files in `target` after switching between the branches. For example check out `math4`. Build it. Switch to the `math3` branch. Build it. Now `target` will contain both classes

Re: [Math] Compile only top-level package and below

2015-09-04 Thread Ole Ersoy
On 09/04/2015 06:06 PM, Gilles wrote: On Fri, 4 Sep 2015 11:03:08 -0500, Ole Ersoy wrote: On 09/04/2015 10:26 AM, Gilles wrote: On Fri, 4 Sep 2015 10:11:04 -0500, Ole Ersoy wrote: You have left over files in `target` after switching between the branches. For example check out `math4

Re: [Math] Compile only top-level package and below

2015-09-04 Thread Ole Ersoy
On 09/04/2015 08:14 PM, sebb wrote: On 5 September 2015 at 01:13, Gilles wrote: On Sat, 5 Sep 2015 00:56:54 +0100, sebb wrote: On 5 September 2015 at 00:55, Ole Ersoy wrote: On 09/04/2015 06:06 PM, Gilles wrote: On Fri, 4 Sep 2015 11:03:08 -0500, Ole Ersoy wrote: On 09/04/2015 10:26

[Math] LeastSquaresOptimizer Javadoc

2015-09-19 Thread Ole Ersoy
Reviewing the math4 leastsquares code ATM, and the class level javadoc for LeastSquaresOptimizer states: == An algorithm that can be applied to a non-linear least squares problem. == How about:

[Math] LeastSquaresOptimizer Design

2015-09-19 Thread Ole Ersoy
Wanted to float some ideas for the LeastSquaresOptimizer (Possibly General Optimizer) design. For example with the LevenbergMarquardtOptimizer we would do: `LevenbergMarquardtOptimizer.optimize(OptimizationContext c);` Rough optimize() outline: public static void optimise() { //perform the opt

Re: [Math] LeastSquaresOptimizer Design

2015-09-20 Thread Ole Ersoy
On 09/20/2015 05:51 AM, Gilles wrote: On Sun, 20 Sep 2015 01:12:49 -0500, Ole Ersoy wrote: Wanted to float some ideas for the LeastSquaresOptimizer (Possibly General Optimizer) design. For example with the LevenbergMarquardtOptimizer we would do: `LevenbergMarquardtOptimizer.optimize

Re: [Math] LeastSquaresOptimizer Design

2015-09-21 Thread Ole Ersoy
Hola, On 09/21/2015 04:15 PM, Gilles wrote: Hi. On Sun, 20 Sep 2015 15:04:08 -0500, Ole Ersoy wrote: On 09/20/2015 05:51 AM, Gilles wrote: On Sun, 20 Sep 2015 01:12:49 -0500, Ole Ersoy wrote: Wanted to float some ideas for the LeastSquaresOptimizer (Possibly General Optimizer) design. For

Re: [Math] LeastSquaresOptimizer Design

2015-09-22 Thread Ole Ersoy
On 09/22/2015 06:46 AM, Gilles wrote: Hi. On Mon, 21 Sep 2015 19:55:15 -0500, Ole Ersoy wrote: Hola, On 09/21/2015 04:15 PM, Gilles wrote: Hi. On Sun, 20 Sep 2015 15:04:08 -0500, Ole Ersoy wrote: On 09/20/2015 05:51 AM, Gilles wrote: On Sun, 20 Sep 2015 01:12:49 -0500, Ole Ersoy wrote

Re: [Math] LeastSquaresOptimizer Design

2015-09-22 Thread Ole Ersoy
ack.notify(). Cheers, - Ole On 09/22/2015 06:46 AM, Gilles wrote: Hi. On Mon, 21 Sep 2015 19:55:15 -0500, Ole Ersoy wrote: Hola, On 09/21/2015 04:15 PM, Gilles wrote: Hi. On Sun, 20 Sep 2015 15:04:08 -0500, Ole Ersoy wrote: On 09/20/2015 05:51 AM, Gilles wrote: On Sun, 20 Sep 2015 01:12:49 -0500,

Re: [Math] LeastSquaresOptimizer Design

2015-09-23 Thread Ole Ersoy
HI Luc, On 09/23/2015 03:02 AM, luc wrote: Hi, Le 2015-09-22 02:55, Ole Ersoy a écrit : Hola, On 09/21/2015 04:15 PM, Gilles wrote: Hi. On Sun, 20 Sep 2015 15:04:08 -0500, Ole Ersoy wrote: On 09/20/2015 05:51 AM, Gilles wrote: On Sun, 20 Sep 2015 01:12:49 -0500, Ole Ersoy wrote: Wanted

Re: [Math] LeastSquaresOptimizer Design

2015-09-23 Thread Ole Ersoy
Ersoy a écrit : Hola, On 09/21/2015 04:15 PM, Gilles wrote: Hi. On Sun, 20 Sep 2015 15:04:08 -0500, Ole Ersoy wrote: On 09/20/2015 05:51 AM, Gilles wrote: On Sun, 20 Sep 2015 01:12:49 -0500, Ole Ersoy wrote: Wanted to float some ideas for the LeastSquaresOptimizer (Possibly General Optimizer

Re: [Math] LeastSquaresOptimizer Design

2015-09-23 Thread Ole Ersoy
On 09/23/2015 03:09 PM, Luc Maisonobe wrote: CM is not intended to be a design pattern people should mimic. We are so bad at this it would be a shame. No one in its right mind would copy or reuse this stuff. It is for internal use only and we don't even have the resources to manage it by ourselves

Re: [Math] LeastSquaresOptimizer Design

2015-09-24 Thread Ole Ersoy
On 09/24/2015 06:31 AM, luc wrote: Le 2015-09-24 04:16, Ole Ersoy a écrit : On 09/23/2015 03:09 PM, Luc Maisonobe wrote: CM is not intended to be a design pattern people should mimic. We are so bad at this it would be a shame. No one in its right mind would copy or reuse this stuff. It is

Re: [Math] LeastSquaresOptimizer Design

2015-09-24 Thread Ole Ersoy
nobe wrote: Le 23/09/2015 19:20, Ole Ersoy a écrit : HI Luc, Hi Ole, On 09/23/2015 03:02 AM, luc wrote: Hi, Le 2015-09-22 02:55, Ole Ersoy a écrit : Hola, On 09/21/2015 04:15 PM, Gilles wrote: Hi. On Sun, 20 Sep 2015 15:04:08 -0500, Ole Ersoy wrote: On 09/20/2015 05:51 AM, Gilles wrote:

Re: [Math] LeastSquaresOptimizer Design

2015-09-24 Thread Ole Ersoy
On 09/24/2015 03:23 PM, Luc Maisonobe wrote: Le 24/09/2015 21:40, Ole Ersoy a écrit : Hi Luc, I gave this some more thought, and I think I may have tapped out to soon, even though you are absolutely right about what an exception does in terms bubbling execution to a point where it stops or

Re: [Math] LeastSquaresOptimizer Design

2015-09-24 Thread Ole Ersoy
On 09/24/2015 04:05 PM, Gilles wrote: On Thu, 24 Sep 2015 08:43:38 -0500, Ole Ersoy wrote: On 09/24/2015 06:31 AM, luc wrote: Le 2015-09-24 04:16, Ole Ersoy a écrit : On 09/23/2015 03:09 PM, Luc Maisonobe wrote: CM is not intended to be a design pattern people should mimic. We are so bad

Re: [Math] LeastSquaresOptimizer Design

2015-09-24 Thread Ole Ersoy
On 09/24/2015 06:01 PM, Gilles wrote: On Thu, 24 Sep 2015 17:02:15 -0500, Ole Ersoy wrote: On 09/24/2015 03:23 PM, Luc Maisonobe wrote: Le 24/09/2015 21:40, Ole Ersoy a écrit : Hi Luc, I gave this some more thought, and I think I may have tapped out to soon, even though you are absolutely

Re: [Math] LeastSquaresOptimizer Design

2015-09-24 Thread Ole Ersoy
Why should the instance throwing the exception hold a field with the information? Separation of concerns: optimizer does the computation, then the exception holds what's needed for a full report of the failure. I would see what makes sense on on case by case basis. For example if the Observer

[Math] Utilitzation of SLF4J?

2015-09-25 Thread Ole Ersoy
Hello, We have been discussing various ways to view what's happening internally with algorithms, and the topic of including SLF4J has come up. I know that this was discussed earlier and it was decided that CM is a low level dependency, therefore it should minimize the transitive dependencies

[Math] Utilization of Lombok

2015-09-25 Thread Ole Ersoy
Hello, I'm going to utilize Lombok in a CM design experiment. Once the experiment is done CM can decide if it likes Lombok. I know that CM tries to stay dependency free, so I just want to make clear that Lombok is compile time only: http://stackoverflow.com/questions/6107197/how-does-lombok-w

Re: [Math] LeastSquaresOptimizer Design

2015-09-25 Thread Ole Ersoy
On 09/25/2015 06:55 AM, Gilles wrote: On Thu, 24 Sep 2015 21:41:10 -0500, Ole Ersoy wrote: On 09/24/2015 06:01 PM, Gilles wrote: On Thu, 24 Sep 2015 17:02:15 -0500, Ole Ersoy wrote: On 09/24/2015 03:23 PM, Luc Maisonobe wrote: Le 24/09/2015 21:40, Ole Ersoy a écrit : Hi Luc, I gave this

Re: [Math] Utilization of Lombok

2015-09-25 Thread Ole Ersoy
Hi Thomas, On 09/25/2015 08:45 AM, Thomas Neidhart wrote: Hi Ole, can you explain why you think that the addition of lombok brings any benefit to our users? Sure - I'm looking at the LevenbergMarquardtOptimizer ATM, and it has the following set of parameters: /* configuration parameters

Re: [Math] Utilitzation of SLF4J?

2015-09-25 Thread Ole Ersoy
the result usually was: do not add logging I think for the reason that commons should not introduce transitive dependencies? This has been solved fairly well (Below). Cheers, - Ole Thomas On Fri, Sep 25, 2015 at 3:17 PM, Ole Ersoy wrote: Hello, We have been discussing various ways to v

Re: [Math] Utilitzation of SLF4J?

2015-09-25 Thread Ole Ersoy
retty sure we have all been here. Cheers, - Ole Gilles [1] No quality or complexity judgment implied. Phil Gilles Thomas On Fri, Sep 25, 2015 at 3:17 PM, Ole Ersoy wrote: Hello, We have been discussing various ways to view what's happening internally with algorithms, and the t

Re: [Math] Utilization of Lombok

2015-09-25 Thread Ole Ersoy
On 09/25/2015 12:55 PM, Thomas Neidhart wrote: On 09/25/2015 05:04 PM, Ole Ersoy wrote: Hi Thomas, On 09/25/2015 08:45 AM, Thomas Neidhart wrote: Hi Ole, can you explain why you think that the addition of lombok brings any benefit to our users? Sure - I'm looking a

Re: [Math] Utilitzation of SLF4J?

2015-09-25 Thread Ole Ersoy
On 09/25/2015 03:06 PM, Phil Steitz wrote: On 9/25/15 11:01 AM, Ole Ersoy wrote: On 09/25/2015 11:34 AM, Phil Steitz wrote: I disagree. Good tests, API contracts, exception management and documentation can and should eliminate the need for cluttering low-level library code with debug

Re: [Math] Utilization of Lombok

2015-09-28 Thread Ole Ersoy
would still future proof by wrapping the solution in a Docker container when possible. Cheers, - Ole On Fri, Sep 25, 2015 at 11:47 PM, Ole Ersoy wrote: On 09/25/2015 12:55 PM, Thomas Neidhart wrote: On 09/25/2015 05:04 PM, Ole Ersoy wrote: Hi Thomas, On 09/25/2015 08:45 AM, Thomas

Re: Proposed Contribution to Apache Commons,

2015-09-30 Thread Ole Ersoy
Hi, On 09/30/2015 01:44 AM, Jochen Wiedmann wrote: Hi, Norman, On Tue, Sep 29, 2015 at 10:06 PM, wrote: My colleague Jeff Rothenberg and I, retirees, have developed an alternative to using regular expressions for searching for (and optionally replacing) patterns in text. Something that is

[math] Smaller Packages / Artifacts / Dependencies

2015-11-06 Thread Ole Ersoy
If math is broken up into smaller artifacts it will make it easier for users to upgrade, even if it it breaks compatibility, as well as speed up the release frequency. So for example: commons-math-optimization (Or even more granular commons-math-optimization-lp, commons-math-optimization-ga, c

Re: [math] Version mgt idea

2015-11-09 Thread Ole Ersoy
If I'm interested in some functionality that is 'beta' then I first have to realize that it's 'beta'...Maybe just tag the branch beta. After that there's probably (Judging from the number of people communicating here) 1/2 people interested. Isn't it easier for them to just just check out the b

Re: [math] Smaller Packages / Artifacts / Dependencies

2015-11-09 Thread Ole Ersoy
On 11/07/2015 04:00 AM, Gilles wrote: On Fri, 6 Nov 2015 15:06:35 -0600, Ole Ersoy wrote: If math is broken up into smaller artifacts it will make it easier for users to upgrade, even if it it breaks compatibility, as well as speed up the release frequency. So for example: commons-math

Re: [math] Version mgt idea

2015-11-16 Thread Ole Ersoy
On 11/13/2015 08:12 AM, Gilles wrote: On Mon, 9 Nov 2015 10:34:43 -0600, Ole Ersoy wrote: If I'm interested in some functionality that is 'beta' then I first have to realize that it's 'beta'...Maybe just tag the branch beta. After that there's probably

Re: [math] additions to MathArrays

2015-11-24 Thread Ole Ersoy
Notes inline... On 11/24/2015 08:28 AM, Gilles wrote: On Tue, 24 Nov 2015 06:52:04 -0700, Phil Steitz wrote: I need the following methods to complete the fix for MATH-1246. I can add them as private methods to the KS class; but they seem generally useful, so I propose adding them to MathArrays

[Math] Precision.roundUnscaled BIG_DECIMAL

2015-12-12 Thread Ole Ersoy
Hi, I'm creating a new utilities module and I'm trying to decide whether to keep the below code block (Contained in the Precision.roundUnscaled() method - BTW it contains a new exception type I'm playing with - see https://github.com/firefly-math/firefly-math-exceptions if interested - the ut

[math] Another Question about Precision.round()

2015-12-12 Thread Ole Ersoy
Hi, In Precision there are these two methods: [1] public static double round(double x, int scale, int roundingMethod) [2] public static float round(float x, int scale, int roundingMethod) The implementations for each are different. For [2] could users just convert float to double and use [1]

[math] Refactored Precision

2015-12-14 Thread Ole Ersoy
Hi, Just a heads up for those of you interested or have nothing better to do at 2 am :). I refactored the Precision class into classes PrecisionAssert and RoundDouble. https://github.com/firefly-numbers/firefly-numbers I created a new github organization for the package, since it deals less

Re: [math] Refactored Precision

2015-12-14 Thread Ole Ersoy
Hi Thomas, On 12/14/2015 06:37 AM, Thomas Neidhart wrote: On Mon, Dec 14, 2015 at 9:17 AM, Ole Ersoy wrote: Hi, Just a heads up for those of you interested or have nothing better to do at 2 am :). I refactored the Precision class into classes PrecisionAssert and RoundDouble. https

[math] AbstractFieldMatrix.checkMultiplicationCompatible() throws exception?

2015-12-16 Thread Ole Ersoy
Hi, I'm working on making the linear package standalone. The methods that perform precondition checks for matrix operations throw exceptions (See below). An option would be return a boolean instead. Obviously I would love it if CM adopts the code at some point, so I want to check whether ch

Re: [math] AbstractFieldMatrix.checkMultiplicationCompatible() throws exception?

2015-12-16 Thread Ole Ersoy
Actually I think I see why bubbling exceptions is better than performing boolean checks...so just ignore, unless there is some merit to it... Cheers, Ole On 12/16/2015 01:08 PM, Ole Ersoy wrote: Hi, I'm working on making the linear package standalone. The methods that perform precond

Re: [math] Updated FieldMatrix exceptions thrown to match javadoc.

2015-12-18 Thread Ole Ersoy
I think it makes sense. If the destination array is too small, throw an IAE. Perhaps the implementations need to be updated. I'm attempting to modularize the linear package ATM so I'll have a closer look. Cheers, - Ole On 12/18/2015 01:31 PM, Phil Steitz wrote: It does not look to me like

Re: [math] Updated FieldMatrix exceptions thrown to match javadoc.

2015-12-18 Thread Ole Ersoy
On 12/18/2015 04:07 PM, Phil Steitz wrote: On 12/18/15 2:59 PM, Ole Ersoy wrote: I think it makes sense. If the destination array is too small, throw an IAE. Right. That is what the implementations do - it is just a specialized IAE. We decided a while back not to throw "raw"

[math] ArithmeticUtils subAndCheck try catch

2015-12-18 Thread Ole Ersoy
The (This is nit picky) ArithmeticUtils subAndCheck uses a message template that is meant for addition. Should it catch and rethrow the exception with a subtraction template? This is how the exception is thrown (Line 470): https://github.com/apache/commons-math/blob/master/src/main/java/org/ap

[math] Arithmetic module

2015-12-18 Thread Ole Ersoy
Hi, I just published an arithmetic module / ArithmeticUtils repackaged. I would love to get some feedback on what you think of the exception design...any improvements...Do you think it could work for CM in general, etc? The exception design strips localization, but it should be very easy to r

[math] Jitpack.io

2015-12-19 Thread Ole Ersoy
In the process of making the firefly modules available for automatic install via maven I came across this: https://jitpack.io/ Thought it might help ease publishing of test artifacts for math. Cheers, - Ole - To unsubscribe, e

[math] Exception Design

2015-12-21 Thread Ole Ersoy
Hi, I was considering jumping into the JDKRandomGenerator exception discussion, but I did not want to hijack it. Not sure if any of you have had a chance to looks at this: https://github.com/firefly-math/firefly-math-exceptions/ https://github.com/firefly-math/firefly-math-exceptions/blob/maste

Re: [math] Updated FieldMatrix exceptions thrown to match javadoc.

2015-12-21 Thread Ole Ersoy
Should look like this, with some typos fixed: /** ... * @throws MatrixDimensionMismatchException if the dimensions of * {@code destination} do not match those of {@code this}. * @throws NumberIsTooSmallException if {@code endRow < startRow} or * {@code endColumn < startCo

Re: [math] Updated FieldMatrix exceptions thrown to match javadoc.

2015-12-21 Thread Ole Ersoy
On 12/21/2015 01:45 PM, Phil Steitz wrote: On 12/21/15 12:26 PM, Ole Ersoy wrote: Should look like this, with some typos fixed: /** ... * @throws MatrixDimensionMismatchException if the dimensions of * {@code destination} do not match those of {@code this}. * @throws

Re: [math] Exception Design

2015-12-21 Thread Ole Ersoy
On 12/21/2015 06:44 PM, Gilles wrote: On Mon, 21 Dec 2015 12:14:16 -0600, Ole Ersoy wrote: Hi, I was considering jumping into the JDKRandomGenerator exception discussion, but I did not want to hijack it. Not sure if any of you have had a chance to looks at this: https://github.com/firefly

Re: [Math] Exceptions from "JDKRandomGenerator"

2015-12-22 Thread Ole Ersoy
. One of the point in having exceptions that extends our own root exception is that users at higher level can catch this top level. Currently, we don't even advertise properly what we throw. We even miss to forward upward some exceptions thrown at low level in the javadoc/signature of out upper

Re: [math] Exception Design

2015-12-22 Thread Ole Ersoy
On 12/22/2015 11:46 AM, Gilles wrote: Hi. On Mon, 21 Dec 2015 22:44:16 -0600, Ole Ersoy wrote: On 12/21/2015 06:44 PM, Gilles wrote: On Mon, 21 Dec 2015 12:14:16 -0600, Ole Ersoy wrote: Hi, I was considering jumping into the JDKRandomGenerator exception discussion, but I did not want to

Re: [math] Exception Design

2015-12-23 Thread Ole Ersoy
[...] Looks good. Where is the code? ;-) So CM clients would: catch(MathException e) { String exceptionTemplate = ResourceBundle.getBundle("cm.exception.templates", new Locale("en", "US")).getString(e.getType()); String i18Nmessage = buildMessage(exceptionTemplate, e.getContext());

Re: [math] Exception Design

2015-12-23 Thread Ole Ersoy
[...] On 12/23/2015 03:38 AM, luc wrote: interface ExceptionLocalizer { /** Localize an exception message. * @param locale locale to use * @param me exception to localize * @return localized message for the exception */ String localize(Locale locale, MathExcept

Re: [Math] Exceptions from "JDKRandomGenerator"

2015-12-23 Thread Ole Ersoy
A few drawbacks to having IAE thrown by CM is that it complicates and blurres things for those designing a handler that catches all CM exceptions. CM advertising a factory that throws each exception 'type' under globally unique conditions minimizes root cause analysis time and indirection. Th

[math] LevenbergMarquardt Lombok Generated Configuration Object

2015-12-23 Thread Ole Ersoy
Hola, I started working on my LevenbergMarquardt optimizer experiment, and figured I'd share the Lombok generated immutable configuration class that I split off from the optimizer. This is only for show...Not trying to restart the lombok inclusion in CM discussion. https://github.com/firefly

Re: [math] Exception Design

2015-12-24 Thread Ole Ersoy
Hi Gilles, It sounds like we're starting to coalesce on this. Hopefully this is not going to come as too much of a shock :). [1] The exception patch will permeate every class that throws an exception. We will have to delete all the other exception and replace them with MathException. Here

[math] MatrixDimensionMismatchException vs. DimensionMismatchException

2015-12-24 Thread Ole Ersoy
So if IUC whenever we are dealing with matrices, a MDME should be thrown? So in this needs an update?: https://github.com/apache/commons-math/blob/master/src/main/java/org/apache/commons/math4/linear/RealMatrix.java#L95 Ole -

Re: [math] MatrixDimensionMismatchException vs. DimensionMismatchException

2015-12-24 Thread Ole Ersoy
Actually - I the Factory is used, then the key signature should determine if it's an MDME or DME. So if 4 keys are used row, column, row, column then MDME otherwise DME...Sound good? Ole On 12/24/2015 06:12 PM, Ole Ersoy wrote: So if IUC whenever we are dealing with matrices, a MDME s

[math] RealVector.isInfinite() mixes in Nan check?

2015-12-26 Thread Ole Ersoy
In RealVector there is an isInfinite() method that checks for isInfinite() and isNan() at the same time. If any coordinate is infinite, it will return true...unless a value is Nan...then it will return false. I'm probably missing something...but it seems like isInfinite() should return true i

Re: [math] RealVector.isInfinite() mixes in Nan check?

2015-12-26 Thread Ole Ersoy
On 12/26/2015 12:12 PM, Gilles wrote: On Sat, 26 Dec 2015 10:21:30 -0600, Ole Ersoy wrote: In RealVector there is an isInfinite() method that checks for isInfinite() and isNan() at the same time. If any coordinate is infinite, it will return true...unless a value is Nan...then it will return

Re: [math] RealVector.isInfinite() mixes in Nan check?

2015-12-26 Thread Ole Ersoy
On 12/26/2015 02:41 PM, Phil Steitz wrote: On 12/26/15 11:12 AM, Gilles wrote: On Sat, 26 Dec 2015 10:21:30 -0600, Ole Ersoy wrote: In RealVector there is an isInfinite() method that checks for isInfinite() and isNan() at the same time. If any coordinate is infinite, it will return true

[math] Thread safe RealVector

2015-12-26 Thread Ole Ersoy
Hi, What do you think of removing iterator(), Entry, and Iterator() from RealVector? ArrayRealVector can replace these with Vector...I think...Still need to attempt it. Vector is synchronized so it makes it easier to make ArrayRealVector thread safe. Cheers, Ole --

Re: [math] Thread safe RealVector

2015-12-26 Thread Ole Ersoy
On 12/26/2015 05:22 PM, Gilles wrote: On Sat, 26 Dec 2015 16:21:04 -0600, Ole Ersoy wrote: Hi, What do you think of removing iterator(), Entry, and Iterator() from RealVector? ArrayRealVector can replace these with Vector...I think...Still need to attempt it. Vector is synchronized so it

[math] Callback interface for Optimizer

2015-12-28 Thread Ole Ersoy
Hi, Just thought I'd share a concrete callback interface that I think this may work well for optimizers in general, even though I'm just working on Levenberg Marquardt ATM. The interface is pasted below, but roughly here's how it works. //Create an instance of an observer implementation. Opti

[math] RealMatrixPreservingVisitor and RealMatrixChangingVisitor the same?

2015-12-29 Thread Ole Ersoy
Hi, RealMatrixPreservingVisitor and RealMatrixChangingVisitor files look identical with the exception of a single @see Default... annotation (Which I think is redundant...same as > All known implementing classes...?). Would it make sense to remove the annotation and have one RealMatrixChangin

Re: [math] RealMatrixPreservingVisitor and RealMatrixChangingVisitor the same?

2015-12-30 Thread Ole Ersoy
Hi Luc, On 12/30/2015 03:55 AM, Luc Maisonobe wrote: Le 30/12/2015 06:18, Ole Ersoy a écrit : Hi, Hi Ole, RealMatrixPreservingVisitor and RealMatrixChangingVisitor files look identical with the exception of a single @see Default... annotation (Which I think is redundant...same as >

Re: [math] RealMatrixPreservingVisitor and RealMatrixChangingVisitor the same?

2015-12-30 Thread Ole Ersoy
On 12/30/2015 03:28 PM, Luc Maisonobe wrote: Le 30/12/2015 20:18, Ole Ersoy a écrit : Hi Luc, On 12/30/2015 03:55 AM, Luc Maisonobe wrote: Le 30/12/2015 06:18, Ole Ersoy a écrit : Hi, Hi Ole, RealMatrixPreservingVisitor and RealMatrixChangingVisitor files look identical with the

[math] RealMatrixFormat.parse()

2015-12-30 Thread Ole Ersoy
Hi, In RealMatrixFormat.parse() MatrixUtils makes the decision on what type of RealMatrix instance to return. Flexibility is gained if it just returns double[][] letting the caller decide what type of RealMatrix instance to create. It's also better for modularity, as is reduces RealMatrixFor

[math] One more reason to add lombok

2015-12-30 Thread Ole Ersoy
Hi, This is a getter from RealMatrixFormat: /** * Get the format prefix. * * @return format prefix. */ public String getRowPrefix() { return rowPrefix; } Within RealMatrixFormat the properties include prefix and rowPrefix. Both have the same documentati

  1   2   >