calling methode with array

Hi,

I must rewrite a FORTRAN code to Java code.

Then I got problem with these:

Code:

if (IB == 1){

CFSP1D(N,XN,FN,W,ALPHA,BETA,1,A,B,C,D,AUXF[1],AUXF[N+1],AUXF[2*N+1],AUXF[3*N+1],AUXF[4*N],AUXF[5*N-1],AUXF[6*N-2],IERR);

}

and

Code:

private void CFSP1D(int N, double[] XN, double[] FN, double[] W, double ALPHA, double BETA, int MREP, double[] A, double[] B, double[] C, double[] D, double H[], double H1[], double H2[], double DM[], double DU1[], double DU2[], double RS[], int IERR) {

Actually I have declared all variables at the class. Then the code will call the CFSP1D-Method.

But then here comes the problem.

At the CPSP1D-Method, double RS[] is actually AUXF[6*N-2]. That means, the double RS[] should be just a double and not array.

But inside this method, the array RS[] will be used, like example:

RS[N-1] = RS[N-1] - (SF[4]/SF[6]*DUMMY4);

Do you have any idea, how to rewrite this code?

Or should I just made an CFSP1D()-Method, then I initiate the variables, that will be used in this method, according to the calling?

thank you very much