Thanks for the help. I have made the change.
The program now runs, where as it didn't before but it comes up with an error when I try to use the scaling function.
Any suggestions?
Code:
void scaling (double line[][3])
{
double s;
double new_line2[2][3];
printf("\nHow much would you like to scale the line by?\nEnter a value between 0 and 1:");
scanf("%lf", &s);
double scaling_matrix[3][3] = { {s, 0, 0}, {0, s, 0}, {0, 0, s} };
scaling_multiplication(line, scaling_matrix, new_line2);
printf("\nThe new start coordinates are: (%lf,%lf,%lf)", new_line2[0][0], new_line2[0][1], new_line2[0][2]);
printf("\nThe new end coordinates are: (%lf,%lf,%lf)", new_line2[1][0], new_line2[1][1], new_line2[1][2]);
}
void scaling_multiplication (double a[][3], double b[][3], double F[][3])
{
int i, j, k;
for(i=0; i<3; i++)
{
for(j=0; j<3; j++)
{
for(k=0; k<3; k++)
{
F[i][j] = a[i][k] + b[k][j];
}
}
}
}