Im finally running the project that was converted from vba to java unfortunately i'm not receiving the proper output. This is because vba seems alot more tolerant of using '0's in equations than java does. eg
dcr = 1 / (1 + dcrp1 * Exp(dcrp2 * Exp(0.5 * (MAsy(1) - MAsy(0)) / MAsy(0)) _
* diff * mom(s0, s1, g0, g1, 0, 0, serv, l1, l2)))
CONSTANTS.setDcr(1 / (1 + CONSTANTS.getDcrp1() * Math.exp(CONSTANTS.getDcrp2() * Math.exp(0.5 * (ARRAYS.MAsy - ARRAYS.MAsy) / ARRAYS.MAsy)
* CONSTANTS.getDiff() * ARRAYS.momARRAY[s0][s1][g0][g1][serv][l1][l2])));
in both sitautions the array 'mom' for the given indexs is 0, however the vba version assigns a value to dcr whereas the java versions makes dcr 'NaN'
I understand what the problem is but cant (in my situation) think of a solution (except rewriting the whole code which is pretty much a nono because its not my logic and i dont really understand it and there's thousands of lines)
Any suggestions much appreciated