mike your working wonders for me here.
what your saying is working but somehow i cannot finaliza things.
(a). All the manipulations with the serial forms can be treated by arithmetical formula's. in this case, the formulas for the creation of the first column inverse could be:
Pm,1 = [(Pm-1,1 + (P1,m-1 - P1,m)]mod12
the subsequent transposition of the original series:
Pm,n = [(P1,n + (Pm,1 - P1,1)]mod12.
so i think that i start on 1 and put in the first formula for the first column, and then create another for loop to loop through the rest of the matrix then??
Here's what i have now:
Code:
#include<stdio.h>
#include<stdlib.h>
int main()
{
int userinput[12][12]; /* declaration of array to hold the row*/
//char temp[2];
int i; /* i is te value to go through the array*/
int j;
printf("Please enter the tone row \n Please note only the first inputted character shall be accepted \n"); /*gets the user to enter tone row*/
for(j = 0 ; j < 12; j++){ //for loop to input the row into the loop
scanf("%d", &userinput[j]);
}
for(j = 0; j < 12; j++){ //for loop to print out the array after input
printf("%d",userinput[j]);
}
printf("\n");
for (i = 1; i < 11; i++){
for (j = 1; j < 11; j++){
//scanf("%d",userinput[i][j]);
userinput[i][j] = (userinput[i][j] + ((userinput[i][j]) - (userinput[i][j+1])))%12;
printf("%d", userinput[i]);
}
}
}