code: private final float[] align(final int sResidue, final int dIndex) {
  	int dResidue, r;
  	float maxScore = -1000000;
  	float rho1 = 0;
  	int maxIdx = 0;
  	float rho0 = 0;
  	short[] dbAARow = model.dbAA[dIndex];
  	int numOfIterations = model.Length[dIndex] - ORonnModel.AA_ALPHABET;
  	for (dResidue = 0; dResidue <= numOfIterations; dResidue++) {
  		// go though the database sequence for maximised alignment
  		rho1 = 0.0f;
  		for (r = 0; r < ORonnModel.AA_ALPHABET; r++) {
  		// go through the query sequence for one alignment
  		rho1 += RonnConstraint.Blosum62[seqAA[sResidue + r]][dbAARow[dResidue
  			+ r]];
  		}
  		if (rho1 > maxScore) {
  		maxScore = rho1;
  		maxIdx = dResidue;
  		}
  	}
  	for (r = 0; r < ORonnModel.AA_ALPHABET; r++) {
  		rho0 += RonnConstraint.Blosum62[dbAARow[maxIdx + r]][dbAARow[maxIdx
  			+ r]];
  	}
  	return new float[] { rho0, maxScore };
  	}
docs: sResidue query sequence index and dIndex database sequence index