[GitHub] [commons-text] coveralls commented on pull request #134: [TEXT-184] simplify if in CaseUtils

2020-07-20 Thread GitBox


coveralls commented on pull request #134:
URL: https://github.com/apache/commons-text/pull/134#issuecomment-661651604


   
   [![Coverage 
Status](https://coveralls.io/builds/32213146/badge)](https://coveralls.io/builds/32213146)
   
   Coverage decreased (-0.0005%) to 98.672% when pulling 
**14d1a5d3f0b222dfff3c77146208ab5a19d721c4 on 
XenoAmess:simplify_if_in_CaseUtils** into 
**d36a5faf0560fce4f0d23ded7db8c915c68def91 on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-text] coveralls commented on pull request #135: [TEXT-181] fix javadocs

2020-07-20 Thread GitBox


coveralls commented on pull request #135:
URL: https://github.com/apache/commons-text/pull/135#issuecomment-661651175


   
   [![Coverage 
Status](https://coveralls.io/builds/32213172/badge)](https://coveralls.io/builds/32213172)
   
   Coverage remained the same at 98.672% when pulling 
**88d6408a765434be3a46418a9fe0c751e49db5b2 on XenoAmess:fix_javadocs** into 
**d36a5faf0560fce4f0d23ded7db8c915c68def91 on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Work logged] (TEXT-181) fix javadocs

2020-07-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/TEXT-181?focusedWorklogId=461419=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-461419
 ]

ASF GitHub Bot logged work on TEXT-181:
---

Author: ASF GitHub Bot
Created on: 21/Jul/20 05:57
Start Date: 21/Jul/20 05:57
Worklog Time Spent: 10m 
  Work Description: coveralls commented on pull request #135:
URL: https://github.com/apache/commons-text/pull/135#issuecomment-661651175


   
   [![Coverage 
Status](https://coveralls.io/builds/32213172/badge)](https://coveralls.io/builds/32213172)
   
   Coverage remained the same at 98.672% when pulling 
**88d6408a765434be3a46418a9fe0c751e49db5b2 on XenoAmess:fix_javadocs** into 
**d36a5faf0560fce4f0d23ded7db8c915c68def91 on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 461419)
Remaining Estimate: 0h
Time Spent: 10m

> fix javadocs
> 
>
> Key: TEXT-181
> URL: https://issues.apache.org/jira/browse/TEXT-181
> Project: Commons Text
>  Issue Type: Sub-task
>Reporter: Jin Xu
>Priority: Major
>  Time Spent: 10m
>  Remaining Estimate: 0h
>
> [https://github.com/apache/commons-text/pull/135]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (TEXT-183) add final to ConstantStringLookup.constantCache

2020-07-20 Thread Jin Xu (Jira)
Jin Xu created TEXT-183:
---

 Summary: add final to ConstantStringLookup.constantCache
 Key: TEXT-183
 URL: https://issues.apache.org/jira/browse/TEXT-183
 Project: Commons Text
  Issue Type: Sub-task
Reporter: Jin Xu


[https://github.com/apache/commons-text/pull/136]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (TEXT-184) simplify if in CaseUtils

2020-07-20 Thread Jin Xu (Jira)
Jin Xu created TEXT-184:
---

 Summary: simplify if in CaseUtils
 Key: TEXT-184
 URL: https://issues.apache.org/jira/browse/TEXT-184
 Project: Commons Text
  Issue Type: Sub-task
Reporter: Jin Xu


[https://github.com/apache/commons-text/pull/134]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (TEXT-182) fix typos

2020-07-20 Thread Jin Xu (Jira)
Jin Xu created TEXT-182:
---

 Summary: fix typos
 Key: TEXT-182
 URL: https://issues.apache.org/jira/browse/TEXT-182
 Project: Commons Text
  Issue Type: Sub-task
Reporter: Jin Xu


https://github.com/apache/commons-text/pull/137



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (TEXT-181) fix javadocs

2020-07-20 Thread Jin Xu (Jira)
Jin Xu created TEXT-181:
---

 Summary: fix javadocs
 Key: TEXT-181
 URL: https://issues.apache.org/jira/browse/TEXT-181
 Project: Commons Text
  Issue Type: Sub-task
Reporter: Jin Xu


[https://github.com/apache/commons-text/pull/135]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (TEXT-180) Minor improvements

2020-07-20 Thread Jin Xu (Jira)


 [ 
https://issues.apache.org/jira/browse/TEXT-180?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jin Xu updated TEXT-180:

Issue Type: Improvement  (was: Bug)

> Minor improvements
> --
>
> Key: TEXT-180
> URL: https://issues.apache.org/jira/browse/TEXT-180
> Project: Commons Text
>  Issue Type: Improvement
>Reporter: Jin Xu
>Priority: Minor
>
> Minor improvements to Commons Text



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (TEXT-180) Minor improvements

2020-07-20 Thread Jin Xu (Jira)
Jin Xu created TEXT-180:
---

 Summary: Minor improvements
 Key: TEXT-180
 URL: https://issues.apache.org/jira/browse/TEXT-180
 Project: Commons Text
  Issue Type: Bug
Reporter: Jin Xu


Minor improvements to Commons Text



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Closed] (LANG-1547) Minor improvements

2020-07-20 Thread Jin Xu (Jira)


 [ 
https://issues.apache.org/jira/browse/LANG-1547?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jin Xu closed LANG-1547.


closed as completed. thanks.

> Minor improvements
> --
>
> Key: LANG-1547
> URL: https://issues.apache.org/jira/browse/LANG-1547
> Project: Commons Lang
>  Issue Type: Improvement
>Reporter: Jin Xu
>Priority: Minor
>  Time Spent: 2h 20m
>  Remaining Estimate: 0h
>
> original pr :
> [https://github.com/apache/commons-lang/pull/533|https://github.com/apache/commons-lang/pull/536]
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [commons-text] XenoAmess opened a new pull request #137: fix typos

2020-07-20 Thread GitBox


XenoAmess opened a new pull request #137:
URL: https://github.com/apache/commons-text/pull/137


   as title



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-text] XenoAmess opened a new pull request #135: fix javadocs

2020-07-20 Thread GitBox


XenoAmess opened a new pull request #135:
URL: https://github.com/apache/commons-text/pull/135


   as title



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-text] XenoAmess opened a new pull request #136: add final to ConstantStringLookup.constantCache

2020-07-20 Thread GitBox


XenoAmess opened a new pull request #136:
URL: https://github.com/apache/commons-text/pull/136


   as title



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-text] XenoAmess opened a new pull request #134: simplify if in CaseUtils

2020-07-20 Thread GitBox


XenoAmess opened a new pull request #134:
URL: https://github.com/apache/commons-text/pull/134


   as title



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (MATH-1550) SimplexTableau (linear programming)

2020-07-20 Thread Gilles Sadowski (Jira)


[ 
https://issues.apache.org/jira/browse/MATH-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17161617#comment-17161617
 ] 

Gilles Sadowski commented on MATH-1550:
---

{quote}For this class, none of this matters because it's not a public class and 
it's only ever instantiated in a method
{quote}
Perhaps you could clarify the documentation in another PR (?).
{quote}[...] how sparse the testing for SimplexSolver is. [...] first implement 
[...] tests for both correctness and performance.
{quote}
Sure; more tests are welcome.
{quote}if you really want to explore making the matrix immutable
{quote}
*Me* not really. ;)
 We are looking for knowledgeable people to help maintain the various areas of 
this large project. Several chunks have already been extracted from "Commons 
Math" into more manageable (more focused) components:
 * [Commons RNG|https://commons.apache.org/proper/commons-rng/]
 * [Commons Numbers|https://commons.apache.org/proper/commons-numbers/]
 * [Commons Geometry|https://commons.apache.org/proper/commons-geometry/]

For all of them, the move entailed many improvements, including enhanced 
performance and higher test coverage.

> SimplexTableau (linear programming)
> ---
>
> Key: MATH-1550
> URL: https://issues.apache.org/jira/browse/MATH-1550
> Project: Commons Math
>  Issue Type: Improvement
>Affects Versions: 3.6.1
>Reporter: Gilles Sadowski
>Priority: Minor
>  Labels: design
> Fix For: 4.0, 4.X
>
>
> Class {{SimplexTableau}} is package private and does not seem designed for 
> inheritance, but it contains "protected" methods.
> There are several instance fields that should preferably be made "final" (for 
> thread safety). It seems that to do this, some design changes are necessary 
> (a.o. the relationship with {{SimplexSolver}} should be clarified).
>  
> {{SimplexSolver}} also contains a protected method ({{solvePhase1}}) that is 
> not documented for inheritance.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Work logged] (MATH-1549) Simplex solver report unbounded solution when solvable constraints scaling up

2020-07-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/MATH-1549?focusedWorklogId=461252=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-461252
 ]

ASF GitHub Bot logged work on MATH-1549:


Author: ASF GitHub Bot
Created on: 20/Jul/20 20:16
Start Date: 20/Jul/20 20:16
Worklog Time Spent: 10m 
  Work Description: coveralls edited a comment on pull request #155:
URL: https://github.com/apache/commons-math/pull/155#issuecomment-659771586


   
   [![Coverage 
Status](https://coveralls.io/builds/32202785/badge)](https://coveralls.io/builds/32202785)
   
   Coverage increased (+0.02%) to 90.956% when pulling 
**d23485fb15a8545d27b339709e5a6c1290465abf on mohrezaei:master** into 
**4108f5f35e22db3401a11fbbf93f85be21394f5c on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 461252)
Time Spent: 50m  (was: 40m)

> Simplex solver report unbounded solution when solvable constraints scaling up
> -
>
> Key: MATH-1549
> URL: https://issues.apache.org/jira/browse/MATH-1549
> Project: Commons Math
>  Issue Type: Bug
>Affects Versions: 3.6.1
> Environment: macOS catalina
>Reporter: Fan Zhang
>Priority: Major
> Attachments: CommonsMathSimplexSolverTest.java
>
>  Time Spent: 50m
>  Remaining Estimate: 0h
>
> *scenario 1:*
> {code:java}
> min: x + y
> x, y >= 0
> 9000x + y >= 0
> 1x + y >= 2000
> x >= 2{code}
> *scenario 2:*
> {code:java}
> min: x + y
> x, y >= 0
> 9.0E15x + 1.0E12y >= 0
> 1.1e16x + 1.0e12y >= 2.0e15
> 1.0e12x >= 2e12{code}
> for scenario 1, it works out. but for scenario 2 whose constrains are just 
> scaled up by 1e12, the solver reports unbounded solution.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [commons-math] coveralls edited a comment on pull request #155: Standardize constants before running simplex algorithm. Fixes MATH-1549.

2020-07-20 Thread GitBox


coveralls edited a comment on pull request #155:
URL: https://github.com/apache/commons-math/pull/155#issuecomment-659771586


   
   [![Coverage 
Status](https://coveralls.io/builds/32202785/badge)](https://coveralls.io/builds/32202785)
   
   Coverage increased (+0.02%) to 90.956% when pulling 
**d23485fb15a8545d27b339709e5a6c1290465abf on mohrezaei:master** into 
**4108f5f35e22db3401a11fbbf93f85be21394f5c on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (MATH-1550) SimplexTableau (linear programming)

2020-07-20 Thread Mohammad Rezaei (Jira)


[ 
https://issues.apache.org/jira/browse/MATH-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17161452#comment-17161452
 ] 

Mohammad Rezaei commented on MATH-1550:
---

May I suggest we keep the immutability topic in this thread and leave 1549 for 
the fix?
{quote} over the long haul, we've been trying to modify all the library's codes 
towards immutability
{quote}
Some of the core data structures provided by the math library are mutable by 
design. These include the vectors that are also used in Simplex. Unlike 
SimplexTableau, those classes are meant for public usage and there is 
essentially no hope to make them immutable any more. I don't think that's a bad 
thing. There are many algorithms that benefit from mutable data structures, 
especially when said data structures are bulky and algorithms rely on changing 
selected members.
  
{quote} There is a balance to be found (copying in Java is not nearly as bad as 
in C and sometimes an extra copy even provides a performance boost!).
{quote}
I agree. The point, however, is *_balance_*. All immutable is just as bad as 
all mutable. There are many things that immutability can't do. Did you know, no 
one has ever invented an immutable O(1) hash structure? On the other hand, O(1) 
mutable hash structures have been in use for over 40 years in real production 
code.

Sorry about the long philosophizing. Let's get back to the issue at hand.

Adding a final decorator to the tableau field doesn't really do much, because 
the matrix is internally modified (see the performRowOperation method). For 
this class, none of this matters because it's not a public class and it's only 
ever instantiated in a method (so it's effectively thread local).

When I was researching this issue, I found out that there are standard suites 
of tests for linear solvers. These are used to compare various implementations, 
including commercial offerings. I was honestly surprised to see how sparse the 
testing for SimplexSolver is. So here is what I suggest: if you really want to 
explore making the matrix immutable, first implement these tests for both 
correctness and performance.

Here are some standard tests (these are encoded in 
[https://en.wikipedia.org/wiki/MPS_(format]) ):
 [http://www.numerical.rl.ac.uk/cute/netlib.html] or 
[https://www.netlib.org/lp/data/index.html]
 [https://www.netlib.org/lp/infeas/index.html]
 
[http://www.gamsworld.org/performance/plib/credits.htm#Mittelmann%20H.%20-%20LP%20Models]

and there is more (see anything labeled "LP" here: 
[http://www.gamsworld.org/performance/plib/credits.htm]). It might look like a 
lot, but it's actually just a matter of writing a single parser and looping 
through all the test cases.

 

 

 

> SimplexTableau (linear programming)
> ---
>
> Key: MATH-1550
> URL: https://issues.apache.org/jira/browse/MATH-1550
> Project: Commons Math
>  Issue Type: Improvement
>Affects Versions: 3.6.1
>Reporter: Gilles Sadowski
>Priority: Minor
>  Labels: design
> Fix For: 4.0, 4.X
>
>
> Class {{SimplexTableau}} is package private and does not seem designed for 
> inheritance, but it contains "protected" methods.
> There are several instance fields that should preferably be made "final" (for 
> thread safety). It seems that to do this, some design changes are necessary 
> (a.o. the relationship with {{SimplexSolver}} should be clarified).
>  
> {{SimplexSolver}} also contains a protected method ({{solvePhase1}}) that is 
> not documented for inheritance.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Work logged] (LANG-1544) MethodUtils.invokeMethod NullPointerException in case of null in args list

2020-07-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/LANG-1544?focusedWorklogId=461191=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-461191
 ]

ASF GitHub Bot logged work on LANG-1544:


Author: ASF GitHub Bot
Created on: 20/Jul/20 17:54
Start Date: 20/Jul/20 17:54
Worklog Time Spent: 10m 
  Work Description: garydgregory commented on pull request #583:
URL: https://github.com/apache/commons-lang/pull/583#issuecomment-661241475


   Hi @pixelr 
   
   After looking again, I'm not sure this PR makes sense. The test you patched 
calls a private method, and this private method is not going to be called with 
just any value. In this case, the private method `distance` is only called from 
`MethodUtils.getMatchingMethod(Class, String, Class...)` where our 
`getMatchingMethod` calls `java.lang.reflect.Method.getParameterTypes()`. 
   
   Do you have a case where 
`java.lang.reflect.Method.getParameterTypes()`returns an array containing a 
null? Can you show this by calling a public method like 
`org.apache.commons.lang3.reflect.MethodUtils.getMatchingMethod(Class, 
String, Class...)`?
   
   Otherwise, this PR just make the `distance` method more complicated than it 
has to be, granted not by much, but there would then be no sense if making the 
whole code base more NPE proof where it does not need to be.
   
   Let us know your findings.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 461191)
Time Spent: 1h 10m  (was: 1h)

> MethodUtils.invokeMethod NullPointerException in case of null in args list
> --
>
> Key: LANG-1544
> URL: https://issues.apache.org/jira/browse/LANG-1544
> Project: Commons Lang
>  Issue Type: Bug
>  Components: lang.reflect.*
>Affects Versions: 3.10
>Reporter: Peter Nagy
>Priority: Critical
>  Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> MethodUtils:774
>  
> if (classArray[offset].equals(toClassArray[offset])) {
>  continue;
> } else if (ClassUtils.isAssignable(classArray[offset], toClassArray[offset], 
> true)
>  
> cause NPE if classArray[offset] is null. Can you please extend the if 
> condition with a null check, like this?
>  
> if (classArray[offset] != null && 
> classArray[offset].equals(toClassArray[offset]))



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [commons-lang] garydgregory commented on pull request #583: LANG-1544: Fixes null pointer exception in distance method in MethodUtils

2020-07-20 Thread GitBox


garydgregory commented on pull request #583:
URL: https://github.com/apache/commons-lang/pull/583#issuecomment-661241475


   Hi @pixelr 
   
   After looking again, I'm not sure this PR makes sense. The test you patched 
calls a private method, and this private method is not going to be called with 
just any value. In this case, the private method `distance` is only called from 
`MethodUtils.getMatchingMethod(Class, String, Class...)` where our 
`getMatchingMethod` calls `java.lang.reflect.Method.getParameterTypes()`. 
   
   Do you have a case where 
`java.lang.reflect.Method.getParameterTypes()`returns an array containing a 
null? Can you show this by calling a public method like 
`org.apache.commons.lang3.reflect.MethodUtils.getMatchingMethod(Class, 
String, Class...)`?
   
   Otherwise, this PR just make the `distance` method more complicated than it 
has to be, granted not by much, but there would then be no sense if making the 
whole code base more NPE proof where it does not need to be.
   
   Let us know your findings.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-io] namannigam edited a comment on pull request #125: Simplify expression

2020-07-20 Thread GitBox


namannigam edited a comment on pull request #125:
URL: https://github.com/apache/commons-io/pull/125#issuecomment-661232480


   Looks more like formatting changes. If not, can you revert all such 
formatting differences to specifically point out which expression is simplified?



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-io] namannigam commented on pull request #125: Simplify expression

2020-07-20 Thread GitBox


namannigam commented on pull request #125:
URL: https://github.com/apache/commons-io/pull/125#issuecomment-661232480


   Looks more like formatting changes. If not, can you revert all such 
formatting differences to specifically point out which expression is simplified.



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Work logged] (MATH-1549) Simplex solver report unbounded solution when solvable constraints scaling up

2020-07-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/MATH-1549?focusedWorklogId=461171=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-461171
 ]

ASF GitHub Bot logged work on MATH-1549:


Author: ASF GitHub Bot
Created on: 20/Jul/20 17:11
Start Date: 20/Jul/20 17:11
Worklog Time Spent: 10m 
  Work Description: coveralls edited a comment on pull request #155:
URL: https://github.com/apache/commons-math/pull/155#issuecomment-659771586


   
   [![Coverage 
Status](https://coveralls.io/builds/32198404/badge)](https://coveralls.io/builds/32198404)
   
   Coverage increased (+0.02%) to 90.956% when pulling 
**74428b9f141db5e4838ca3a8a0660ea06db4360a on mohrezaei:master** into 
**4108f5f35e22db3401a11fbbf93f85be21394f5c on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 461171)
Time Spent: 40m  (was: 0.5h)

> Simplex solver report unbounded solution when solvable constraints scaling up
> -
>
> Key: MATH-1549
> URL: https://issues.apache.org/jira/browse/MATH-1549
> Project: Commons Math
>  Issue Type: Bug
>Affects Versions: 3.6.1
> Environment: macOS catalina
>Reporter: Fan Zhang
>Priority: Major
> Attachments: CommonsMathSimplexSolverTest.java
>
>  Time Spent: 40m
>  Remaining Estimate: 0h
>
> *scenario 1:*
> {code:java}
> min: x + y
> x, y >= 0
> 9000x + y >= 0
> 1x + y >= 2000
> x >= 2{code}
> *scenario 2:*
> {code:java}
> min: x + y
> x, y >= 0
> 9.0E15x + 1.0E12y >= 0
> 1.1e16x + 1.0e12y >= 2.0e15
> 1.0e12x >= 2e12{code}
> for scenario 1, it works out. but for scenario 2 whose constrains are just 
> scaled up by 1e12, the solver reports unbounded solution.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [commons-math] coveralls edited a comment on pull request #155: Standardize constants before running simplex algorithm. Fixes MATH-1549.

2020-07-20 Thread GitBox


coveralls edited a comment on pull request #155:
URL: https://github.com/apache/commons-math/pull/155#issuecomment-659771586


   
   [![Coverage 
Status](https://coveralls.io/builds/32198404/badge)](https://coveralls.io/builds/32198404)
   
   Coverage increased (+0.02%) to 90.956% when pulling 
**74428b9f141db5e4838ca3a8a0660ea06db4360a on mohrezaei:master** into 
**4108f5f35e22db3401a11fbbf93f85be21394f5c on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (MATH-1549) Simplex solver report unbounded solution when solvable constraints scaling up

2020-07-20 Thread Mohammad Rezaei (Jira)


[ 
https://issues.apache.org/jira/browse/MATH-1549?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17161378#comment-17161378
 ] 

Mohammad Rezaei commented on MATH-1549:
---

Thanks for the feedback. I've pushed a commit with the requested changes. 
Please let me know if there is more that you'd like to see.

I added a simple note about the tableau usage in the javadoc. The current code 
design looks sound to me from both a safety and efficacy perspective. I'll 
comment more in 1550.

 

> Simplex solver report unbounded solution when solvable constraints scaling up
> -
>
> Key: MATH-1549
> URL: https://issues.apache.org/jira/browse/MATH-1549
> Project: Commons Math
>  Issue Type: Bug
>Affects Versions: 3.6.1
> Environment: macOS catalina
>Reporter: Fan Zhang
>Priority: Major
> Attachments: CommonsMathSimplexSolverTest.java
>
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> *scenario 1:*
> {code:java}
> min: x + y
> x, y >= 0
> 9000x + y >= 0
> 1x + y >= 2000
> x >= 2{code}
> *scenario 2:*
> {code:java}
> min: x + y
> x, y >= 0
> 9.0E15x + 1.0E12y >= 0
> 1.1e16x + 1.0e12y >= 2.0e15
> 1.0e12x >= 2e12{code}
> for scenario 1, it works out. but for scenario 2 whose constrains are just 
> scaled up by 1e12, the solver reports unbounded solution.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [commons-io] coveralls commented on pull request #125: Simplify expression

2020-07-20 Thread GitBox


coveralls commented on pull request #125:
URL: https://github.com/apache/commons-io/pull/125#issuecomment-661161537


   
   [![Coverage 
Status](https://coveralls.io/builds/32197697/badge)](https://coveralls.io/builds/32197697)
   
   Coverage remained the same at 89.72% when pulling 
**29965a727b1fa79b7e8abf1747750b366f878852 on bhawna94:simplify-expression** 
into **28a1de480c8c0a45500f754f07a2e88fa94c on apache:master**.
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-io] bhawna94 opened a new pull request #125: Simplify expression

2020-07-20 Thread GitBox


bhawna94 opened a new pull request #125:
URL: https://github.com/apache/commons-io/pull/125


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Commented] (MATH-1549) Simplex solver report unbounded solution when solvable constraints scaling up

2020-07-20 Thread Gilles Sadowski (Jira)


[ 
https://issues.apache.org/jira/browse/MATH-1549?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17161119#comment-17161119
 ] 

Gilles Sadowski commented on MATH-1549:
---

bq. If there is anything I can do to the PR to make it acceptable, I'll be 
happy to do it.

Thanks a lot for fixing the issue.
Could you please add the missing Javadoc: All methods (including "private" 
ones) must be fully documented.  [Unless I'm mistaken, I think that newer 
"Commons" components would even fail the build when that's not the case.]
There are also a few nits with the code style:
* space after "for" (in "for" loops),
* one condition per line (in condition checks),
* no "magic" numbers within the methods: "1023" and "1" must be declared as 
"final static" fields,
* opening brace (of method body) on the same line (as the closing parenthesis 
of the argument list).

Also the new {{standardize}} method should probably be renamed to better 
reflect what it is doing: {{scale}} (?).

> Simplex solver report unbounded solution when solvable constraints scaling up
> -
>
> Key: MATH-1549
> URL: https://issues.apache.org/jira/browse/MATH-1549
> Project: Commons Math
>  Issue Type: Bug
>Affects Versions: 3.6.1
> Environment: macOS catalina
>Reporter: Fan Zhang
>Priority: Major
> Attachments: CommonsMathSimplexSolverTest.java
>
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> *scenario 1:*
> {code:java}
> min: x + y
> x, y >= 0
> 9000x + y >= 0
> 1x + y >= 2000
> x >= 2{code}
> *scenario 2:*
> {code:java}
> min: x + y
> x, y >= 0
> 9.0E15x + 1.0E12y >= 0
> 1.1e16x + 1.0e12y >= 2.0e15
> 1.0e12x >= 2e12{code}
> for scenario 1, it works out. but for scenario 2 whose constrains are just 
> scaled up by 1e12, the solver reports unbounded solution.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (MATH-1549) Simplex solver report unbounded solution when solvable constraints scaling up

2020-07-20 Thread Gilles Sadowski (Jira)


[ 
https://issues.apache.org/jira/browse/MATH-1549?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17161106#comment-17161106
 ] 

Gilles Sadowski commented on MATH-1549:
---

{quote}My personal impression is that these vectors are hard to work with.
{quote}
Could you elaborate? [Maybe that's something we could/should fix.]
{quote}I figured I'd rather not add another copy into that.
{quote}
I understand. However, in-place changes should be especially well documented 
and, IMO, we should avoid them by default (i.e. until proven necessary).
{quote}copying all this stuff around is not good for anything.
{quote}
Sure. There is a balance to be found (copying in Java is not nearly as bad as 
in C and sometimes an extra copy even provides a performance boost!).
{quote}I'm not quite sure how you see SimplexTableau changing.
{quote}
The basic idea would be to perform the tasks that need mutability within the 
constructor (or in private methods that return the final values to be assigned 
to the instance fields).
 If/when the tableau must be changed, a new instance would be created (e.g. as 
is done at [this 
line|https://gitbox.apache.org/repos/asf?p=commons-math.git;a=blob;f=src/main/java/org/apache/commons/math4/optim/linear/SimplexTableau.java;h=15a84819b2eb8ede0914d939d89c2f79bdb7caf3;hb=HEAD#l433]
 anyways), from current input. IMHO, this would greatly simplify the code, 
allowing further improvements to be safely implemented.

> Simplex solver report unbounded solution when solvable constraints scaling up
> -
>
> Key: MATH-1549
> URL: https://issues.apache.org/jira/browse/MATH-1549
> Project: Commons Math
>  Issue Type: Bug
>Affects Versions: 3.6.1
> Environment: macOS catalina
>Reporter: Fan Zhang
>Priority: Major
> Attachments: CommonsMathSimplexSolverTest.java
>
>  Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> *scenario 1:*
> {code:java}
> min: x + y
> x, y >= 0
> 9000x + y >= 0
> 1x + y >= 2000
> x >= 2{code}
> *scenario 2:*
> {code:java}
> min: x + y
> x, y >= 0
> 9.0E15x + 1.0E12y >= 0
> 1.1e16x + 1.0e12y >= 2.0e15
> 1.0e12x >= 2e12{code}
> for scenario 1, it works out. but for scenario 2 whose constrains are just 
> scaled up by 1e12, the solver reports unbounded solution.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (MATH-1550) SimplexTableau (linear programming)

2020-07-20 Thread Gilles Sadowski (Jira)


[ 
https://issues.apache.org/jira/browse/MATH-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17161083#comment-17161083
 ] 

Gilles Sadowski commented on MATH-1550:
---

bq. I think you mean the class SimplexTableau

Right; I fixed the issue's description. :-)

bq. core data structures are mutable [...] meant to be that way.

IMHO, if that's indeed the case that they are *meant* to be mutable, it lacks 
code documentation on the design.  Indeed, over the long haul, we've been 
trying to modify all the library's codes towards _immutability_ (foremost to 
ensure thread safety).
I wonder whether the class could be redesigned for more clarity, safety and 
flexibility.  For example, if my impression is right, we should be able to write
{code}
final SimplexTableau t = new SimplexTableau(...).scale();
{code}
(i.e. letting the user decide whether/how to handle potential issues with the 
input data).

> SimplexTableau (linear programming)
> ---
>
> Key: MATH-1550
> URL: https://issues.apache.org/jira/browse/MATH-1550
> Project: Commons Math
>  Issue Type: Improvement
>Affects Versions: 3.6.1
>Reporter: Gilles Sadowski
>Priority: Minor
>  Labels: design
> Fix For: 4.0, 4.X
>
>
> Class {{SimplexTableau}} is package private and does not seem designed for 
> inheritance, but it contains "protected" methods.
> There are several instance fields that should preferably be made "final" (for 
> thread safety). It seems that to do this, some design changes are necessary 
> (a.o. the relationship with {{SimplexSolver}} should be clarified).
>  
> {{SimplexSolver}} also contains a protected method ({{solvePhase1}}) that is 
> not documented for inheritance.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Resolved] (LANG-1591) Remove redudant argument from substring call

2020-07-20 Thread Bruno P. Kinoshita (Jira)


 [ 
https://issues.apache.org/jira/browse/LANG-1591?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Bruno P. Kinoshita resolved LANG-1591.
--
Resolution: Fixed

> Remove redudant argument from substring call
> 
>
> Key: LANG-1591
> URL: https://issues.apache.org/jira/browse/LANG-1591
> Project: Commons Lang
>  Issue Type: Improvement
>  Components: lang.math.*
>Affects Versions: 3.11
>Reporter: Bruno P. Kinoshita
>Assignee: Bruno P. Kinoshita
>Priority: Minor
> Fix For: 3.12
>
>
> Placeholder for https://github.com/apache/commons-lang/pull/585



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Updated] (MATH-1550) SimplexTableau (linear programming)

2020-07-20 Thread Gilles Sadowski (Jira)


 [ 
https://issues.apache.org/jira/browse/MATH-1550?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Gilles Sadowski updated MATH-1550:
--
Description: 
Class {{SimplexTableau}} is package private and does not seem designed for 
inheritance, but it contains "protected" methods.

There are several instance fields that should preferably be made "final" (for 
thread safety). It seems that to do this, some design changes are necessary 
(a.o. the relationship with {{SimplexSolver}} should be clarified).

 
{{SimplexSolver}} also contains a protected method ({{solvePhase1}}) that is 
not documented for inheritance.
 

  was:
Class {{SimplexSolver}} is package private and does not seem designed for 
inheritance, but it contains "protected" methods.

There are several instance fields that should preferably be made "final" (for 
thread safety).  It seems that to do this, some design changes are necessary 
(a.o. the relationship with {{SimplexSolver}} should be clarified).



> SimplexTableau (linear programming)
> ---
>
> Key: MATH-1550
> URL: https://issues.apache.org/jira/browse/MATH-1550
> Project: Commons Math
>  Issue Type: Improvement
>Affects Versions: 3.6.1
>Reporter: Gilles Sadowski
>Priority: Minor
>  Labels: design
> Fix For: 4.0, 4.X
>
>
> Class {{SimplexTableau}} is package private and does not seem designed for 
> inheritance, but it contains "protected" methods.
> There are several instance fields that should preferably be made "final" (for 
> thread safety). It seems that to do this, some design changes are necessary 
> (a.o. the relationship with {{SimplexSolver}} should be clarified).
>  
> {{SimplexSolver}} also contains a protected method ({{solvePhase1}}) that is 
> not documented for inheritance.
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Created] (LANG-1591) Remove redudant argument from substring call

2020-07-20 Thread Bruno P. Kinoshita (Jira)
Bruno P. Kinoshita created LANG-1591:


 Summary: Remove redudant argument from substring call
 Key: LANG-1591
 URL: https://issues.apache.org/jira/browse/LANG-1591
 Project: Commons Lang
  Issue Type: Improvement
  Components: lang.math.*
Affects Versions: 3.11
Reporter: Bruno P. Kinoshita
Assignee: Bruno P. Kinoshita
 Fix For: 3.12


Placeholder for https://github.com/apache/commons-lang/pull/585



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [commons-lang] kinow closed pull request #585: Remove redudant argument from substring call

2020-07-20 Thread GitBox


kinow closed pull request #585:
URL: https://github.com/apache/commons-lang/pull/585


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-lang] kinow commented on pull request #585: Remove redudant argument from substring call

2020-07-20 Thread GitBox


kinow commented on pull request #585:
URL: https://github.com/apache/commons-lang/pull/585#issuecomment-660906186


   Merged. Thanks @bhawna94 !



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-lang] kinow merged pull request #585: Remove redudant argument from substring call

2020-07-20 Thread GitBox


kinow merged pull request #585:
URL: https://github.com/apache/commons-lang/pull/585


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[jira] [Work logged] (LANG-1544) MethodUtils.invokeMethod NullPointerException in case of null in args list

2020-07-20 Thread ASF GitHub Bot (Jira)


 [ 
https://issues.apache.org/jira/browse/LANG-1544?focusedWorklogId=460971=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-460971
 ]

ASF GitHub Bot logged work on LANG-1544:


Author: ASF GitHub Bot
Created on: 20/Jul/20 09:06
Start Date: 20/Jul/20 09:06
Worklog Time Spent: 10m 
  Work Description: pixelr commented on a change in pull request #583:
URL: https://github.com/apache/commons-lang/pull/583#discussion_r457201283



##
File path: src/main/java/org/apache/commons/lang3/reflect/MethodUtils.java
##
@@ -782,7 +782,7 @@ private static int distance(final Class[] classArray, 
final Class[] toClas
 }
 for (int offset = 0; offset < classArray.length; offset++) {
 // Note InheritanceUtils.distance() uses different scoring system.
-if (classArray[offset].equals(toClassArray[offset])) {
+if (Objects.isNull(classArray[offset]) || 
classArray[offset].equals(toClassArray[offset])) {

Review comment:
   @garydgregory Please review and merge if changes are correct





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
---

Worklog Id: (was: 460971)
Time Spent: 1h  (was: 50m)

> MethodUtils.invokeMethod NullPointerException in case of null in args list
> --
>
> Key: LANG-1544
> URL: https://issues.apache.org/jira/browse/LANG-1544
> Project: Commons Lang
>  Issue Type: Bug
>  Components: lang.reflect.*
>Affects Versions: 3.10
>Reporter: Peter Nagy
>Priority: Critical
>  Time Spent: 1h
>  Remaining Estimate: 0h
>
> MethodUtils:774
>  
> if (classArray[offset].equals(toClassArray[offset])) {
>  continue;
> } else if (ClassUtils.isAssignable(classArray[offset], toClassArray[offset], 
> true)
>  
> cause NPE if classArray[offset] is null. Can you please extend the if 
> condition with a null check, like this?
>  
> if (classArray[offset] != null && 
> classArray[offset].equals(toClassArray[offset]))



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[GitHub] [commons-lang] pixelr commented on a change in pull request #583: LANG-1544: Fixes null pointer exception in distance method in MethodUtils

2020-07-20 Thread GitBox


pixelr commented on a change in pull request #583:
URL: https://github.com/apache/commons-lang/pull/583#discussion_r457201283



##
File path: src/main/java/org/apache/commons/lang3/reflect/MethodUtils.java
##
@@ -782,7 +782,7 @@ private static int distance(final Class[] classArray, 
final Class[] toClas
 }
 for (int offset = 0; offset < classArray.length; offset++) {
 // Note InheritanceUtils.distance() uses different scoring system.
-if (classArray[offset].equals(toClassArray[offset])) {
+if (Objects.isNull(classArray[offset]) || 
classArray[offset].equals(toClassArray[offset])) {

Review comment:
   @garydgregory Please review and merge if changes are correct





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-lang] bhawna94 commented on pull request #585: Remove redudant argument from substring call

2020-07-20 Thread GitBox


bhawna94 commented on pull request #585:
URL: https://github.com/apache/commons-lang/pull/585#issuecomment-660897873


   Thanks for the update @kinow 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-lang] kinow commented on pull request #585: Remove redudant argument from substring call

2020-07-20 Thread GitBox


kinow commented on pull request #585:
URL: https://github.com/apache/commons-lang/pull/585#issuecomment-660893568


   Not a problem @bhawna94 , I think it should be ready to be merged, I'm just 
looking at other PR's at the moment, but can probably merge in some moments 
:+1: 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-cli] britter closed pull request #29: Try to fix problem on Travis CI with JDK6

2020-07-20 Thread GitBox


britter closed pull request #29:
URL: https://github.com/apache/commons-cli/pull/29


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-collections] britter closed pull request #54: Replace Clirr with japicmp, since clirr does not handle Java 8 defaul…

2020-07-20 Thread GitBox


britter closed pull request #54:
URL: https://github.com/apache/commons-collections/pull/54


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-lang] bhawna94 edited a comment on pull request #585: Remove redudant argument from substring call

2020-07-20 Thread GitBox


bhawna94 edited a comment on pull request #585:
URL: https://github.com/apache/commons-lang/pull/585#issuecomment-660887669


   Thanks @kinow . Are we good to merge this or waiting for other approvals?



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [commons-lang] bhawna94 commented on pull request #585: Remove redudant argument from substring call

2020-07-20 Thread GitBox


bhawna94 commented on pull request #585:
URL: https://github.com/apache/commons-lang/pull/585#issuecomment-660887669


   Thanks @kinow . Are we good to merge this or waiting for other approvals



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org