From 0c5f51ebbcb7e22baa913e2012e3dcfcc6cf7897 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 5 Aug 2014 09:54:58 +0200 Subject: java: remove commented out code Change-Id: I44e2043e5da23bc9421c03e550ef1d8b7ebaad36 --- .../src/net/adaptivebox/global/GlobalFile.java | 9 -------- .../net/adaptivebox/global/RandomGenerator.java | 24 ---------------------- 2 files changed, 33 deletions(-) (limited to 'nlpsolver/ThirdParty') diff --git a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/GlobalFile.java b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/GlobalFile.java index b494d462bb6d..ffe03200e4cb 100644 --- a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/GlobalFile.java +++ b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/GlobalFile.java @@ -62,15 +62,6 @@ public class GlobalFile { raFile.seek(raFile.length()); raFile.writeBytes(inStr); raFile.close(); - - -// String oldFileStr = getStringFromFile(fileStr); -// String newFileStr = inStr; -// if (oldFileStr != null) { -// newFileStr = oldFileStr+inStr; -// } -// saveStringToFile(newFileStr,fileStr); - } public static Object loadObjectFromFile(String fileName) throws Exception { diff --git a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/RandomGenerator.java b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/RandomGenerator.java index 45204c44497d..47d03c1256bf 100644 --- a/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/RandomGenerator.java +++ b/nlpsolver/ThirdParty/EvolutionarySolver/src/net/adaptivebox/global/RandomGenerator.java @@ -31,7 +31,6 @@ public class RandomGenerator { * Example: for find [0,1,2] */ public static int intRangeRandom(int lowLimit,int upLimit){ -// int num = (int)Math.rint(doubleRangeRandom(lowLimit,upLimit)); int num = (int)Math.floor(doubleRangeRandom(lowLimit,upLimit+1)-1E-10); return(num); } @@ -75,29 +74,6 @@ public static double doubleRangeRandom(double lowLimit,double upLimit){ return randomSelection(totalIndices, times); } -// public static int[] randomSelection(boolean[] types, int times) { -// int realTimes = times; -// if(realTimes>types.length) realTimes = types.length; -// boolean[] internalTypes = (boolean[])types.clone(); -// int upper = types.length-1; -// int[] indices = new int[realTimes]; -// if(realTimes==types.length) { -// for(int i=0; i