Project

General

Profile

1
package eu.dnetlib.data.mapreduce;
2

    
3
import org.apache.commons.math.util.MathUtils;
4
import org.junit.Test;
5

    
6
/**
7
 * Created by claudio on 16/11/2016.
8
 */
9
public class AlgorithmsTest {
10

    
11
	@Test
12
	public void testScale() {
13
		final double th = 0.98;
14
		final double lb = th - 0.01;
15

    
16
		System.out.println(MathUtils.round(Algorithms.scale(0.98, lb, 1, 0, 1), 2));
17
	}
18

    
19
}
    (1-1/1)