Hi , i can help.
here is a little previous code
void equation7(float theta,float gamma, float omega_g,double c[3][3])
{
double c1[3][3],c2[3][3],c3[3][3],temp[3][3];
c1[0][0]=cos(gamma); c1[0][1]=0; c1[0][2]=(-sin(gamma));
c1[1][0]=0; c1[1][1]=1; c1[1][2]=0;
c1[2][0]= sin(gamma); c1[2][1]=0; c1[2][2]=cos(gamma);
c2[0][0]=1; c2[0][1]=0; c2[0][2]=0;
c2[1][0]=0; c2[1][1]=cos(theta); c2[1][2]=sin(theta);
c2[2][0]= 0; c2[2][1]=-sin(theta); c2[2][2]=cos(theta);
c3[0][0]=cos(omega_g); c3[0][1]=sin(omega_g); c3[0][2]=0;
c3[1][0]=-sin(omega_g); c3[1][1]=cos(omega_g); c3[1][2]=0;
c3[2][0]= 0; c3[2][1]=0; c3[2][2]=1;
/*
printf("\n c1 IS : -\n");
for(int I=0;I<=2;I++)
{
for(int J=0;J<=2;J++)
{
printf(" %f", c1[I][J]);
}
printf("\n");
}
printf("\n c2 IS : -\n");
for(int I=0;I<=2;I++)
{
for(int J=0;J<=2;J++)
{
printf(" %f", c2[I][J]);
}
printf("\n");
}
printf("\n c3 IS : -\n");
for(int I=0;I<=2;I++)
{
for(int J=0;J<=2;J++)
{
printf(" %f",c3[I][J]);
}
printf("\n");
}
*/
matrix_mul(c1,c2,temp,3,3,3,3);
matrix_mul(temp,c3,c,3,3,3,3);
/*printf("\n c1c2c2 IS : -\n");
for(int I=0;I<=2;I++)
{
for(int J=0;J<=2;J++)
{
printf(" %f",result[I][J]);
}
printf("\n");
}*/
}