 	// return zero if all ok
 	return 0;
 
-}+}

	bf  = fopen("b_matlab","w");
	cf  = fopen("c_matlab","w");
	cff = fopen("c","w");
	for(j=0;j<len_a;j++){
		for(k=0;k<len_a;k++){
			fprintf(af,"%10.8E ",a[j*len_a+k]);  //row major

	//open files, get lengths, make sure they are equal
	FILE* af = fopen("a","r");
	FILE* bf = fopen("b","r");
	FILE* cf; 
	FILE* cff;

	fscanf(af,"%u\n",&len_a);
	fscanf(bf,"%u\n",&len_b);
