Problem

Normalization Technique. There are a number of ways to normalize, or scale, a set of value...

Normalization Technique. There are a number of ways to normalize, or scale, a set of values. One common normalization technique scales the values such that the minimum value goes to 0, the maximum value goes to 1, and other values are scaled accordingly. For example, using this normalization, we can normalize the values in the following array:

Array values

-2

-1

2

0

Normalized array values

0.0

0.25

1.0

0.5

The equation that computes the normalized value from a value xkin the array is

where minx and maxx represent the minimum and maximum values in the array x, respectively. If you substitute the minimum value for xk in this equation, the numerator is zero, and thus the normalized value for the minimum is zero. If you substitute the maximum value for xk in this equation, the numerator and denominator are the same value, and hence the normalized value for the maximum is 1.0.

Write a function that has a two-dimensional double array as an argument. Normalize the values in the array using the technique presented. Assume that symbolic contants NROWS and NCOLS specify the size of the array and that these are available to the function. Assume that the corresponding function prototype is

void norm_2D(double x[NROWS][NCOLS]);

Step-by-Step Solution

Request Professional Solution

Request Solution!

We need at least 10 more requests to produce the solution.

0 / 10 have requested this problem solution

The more requests, the faster the answer.

Request! (Login Required)


All students who have requested the solution will be notified once they are available.
Add your Solution
Textbook Solutions and Answers Search