Examples of XorShiftRandom


Examples of com.carrotsearch.hppc.XorShiftRandom

     * order of 0xf0-masked integers should be preserved from the input.
     */
    @Test
    public void testMergeSortIsStable()
    {
        final Random rnd = new XorShiftRandom(0xdeadbeef);
        final int [] data = new int [10000];

        for (int i = 0; i < data.length; i++)
            data[i] = rnd.nextInt(0x100);

        int [] order = IndirectSort.mergesort(0, data.length, new IndirectComparator()
        {
            public int compare(int indexA, int indexB)
            {
View Full Code Here

Examples of com.carrotsearch.hppc.XorShiftRandom

    protected void setUp() throws Exception
    {
        switch (distribution)
        {
            case RANDOM:
                keys = prepareData(size, new XorShiftRandom(0x11223344));
                break;
            case LINEAR:
                keys = prepareLinear(size);
                break;
            case HIGHBITS:
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.