public static void write3DArray(float[][][] theta, String thetaFileName) throws IOException {
		// TODO Auto-generated method stub
		BufferedWriter writer = new BufferedWriter(new FileWriter(thetaFileName));
		for(int i = 0; i < theta.length; i++){
			for(int j = 0; j < theta[i].length; j++){
				for(int k = 0; k < theta[i][j].length; k++){
					writer.append(i + "\t" + j + "\t" + k + "\t" +  theta[i][j][k] + "\n");
				}
			}
			writer.flush();
		}
		writer.flush();
		writer.close();
	}