Get the corresponding matrix and create it.

@param size Size of the matrix to be created
@return     the matrix with the permutations
179667
private int[][] getMatrix(int size) {
        logger.info("Creating matrix for isotopes combination");
        int lengthM = (int) Math.pow(2, size);
        lengthM--;// less 1 because the matrix 00000 we don't need

        int[][] matrix = new int[lengthM][size];

        int[] combi = new int[size];
        for (int j = 0; j < size; j++) {
            combi[j] = 0;
        }
        int posChang = size - 1;
        int posRemov = size - 1;
        for (int i = 0; i < lengthM; i++) {
            // cleaning to zeros
            for (int j = posRemov; j < size; j++) {
                combi[j] = 0;
            }

            combi[posChang] = 1;

            for (int j = 0; j < size; j++)
                matrix[i][j] = combi[j];

            if (posChang == size - 1) {
                //find where is zero position, place to change
                for (int j = posChang; j >= 0; j--) {
                    if (combi[j] == 0) {
                        posChang = j;
                        posRemov = j + 1;
                        break;
                    }
                }
            } else {
                //look for the last zero
                for (int j = posChang; j < size; j++) {
                    if (combi[j] == 0) {
                        posChang = j;
                    }
                }
            }
        }

        return matrix;
    }
889351
public int[] get(int size) {
        if (array == null || size > array.length)
            return array = new int[size];

        return array;
    }
12119
public int[] getTopSentence(int size)
    {
        Collection<Integer> values = top.values();
        size = Math.min(size, values.size());
        int[] indexArray = new int[size];
        Iterator<Integer> it = values.iterator();
        for (int i = 0; i < size; ++i)
        {
            indexArray[i] = it.next();
        }
        return indexArray;
    }
611735
public static SparseMatrix randomSymmetric(int size, double density, Random random) {
        return CRSMatrix.randomSymmetric(size, density, random);
    }
1282141
@VisibleForTesting
  public static TagKey[] createTagKeys(int size, String name) {
    TagKey[] keys = new TagKey[size];
    for (int i = 0; i < size; i++) {
      keys[i] = TagKey.create(name + i);
    }
    return keys;
  }
1322847
public static Partition unit(int size) {
        Partition unit = new Partition();
        unit.cells.add(new TreeSet<Integer>());
        for (int i = 0; i < size; i++) {
            unit.cells.get(0).add(i);
        }
        return unit;
    }
858303
public Matrix times(final Matrix B)
    {
        final Matrix A = this;

        if (A.m_columns != B.m_rows)
        {
            throw new GeometryException("Illegal matrix dimensions");
        }
        final Matrix C = new Matrix(A.m_rows, B.m_columns);

        for (int i = 0; i < C.m_rows; i++)
        {
            for (int j = 0; j < C.m_columns; j++)
            {
                for (int k = 0; k < A.m_columns; k++)
                {
                    C.m_data[i][j] += (A.m_data[i][k] * B.m_data[k][j]);
                }
            }
        }
        return C;
    }
1202813
function(sbmA, sbmB) {
    // if not the same sizes
    if (sbmA.x != sbmB.x || sbmA.y != sbmB.y) {
      return
    }
    // create the matrix
    var mat = {}
    mat.x = sbmA.x
    mat.y = sbmA.y
    mat.data = []
    // populate
    for (var i = 0; i < mat.x; i++) {
      mat.data[i] = _.intersection(sbmA.data[i], sbmB.data[i])
    }
    // return matrix
    return mat
  }
1312366
public static <K, V> HashMap<K, V> newHashMap(int size, boolean isOrder) {
		int initialCapacity = (int) (size / DEFAULT_LOAD_FACTOR);
		return isOrder ? new LinkedHashMap<K, V>(initialCapacity) : new HashMap<K, V>(initialCapacity);
	}
21143
public static <K, V> Map<K, V> newLinkedHashMap(int size) {
    return new LinkedHashMap<K, V>(size);
  }
301651
public static function getSize( $size )
    {
        $dim = [];
        if( is_array( $size ) )
        {
            $dim[ 'w' ] = $size[0];
            $dim[ 'h' ] = isset( $size[1] ) ? $size[1] : $size[0];
        }
        else
        {
            $dim[ 'w' ] = $size;
            $dim[ 'h' ] = null;
        }

        return $dim;
    }
277697
public Matrix getIminus() {
        Matrix Iminus = new Matrix(size, size);
        int i, j;
        for (i = 0; i < size; i++)
            for (j = 0; j < size; j++)
                Iminus.matrix[i][j] = 0d;
        for (i = 1; i < size; i++)
            Iminus.matrix[i][i - 1] = Math.sqrt(J * J + J - (J - i) * (J - i) - (J - i));
        return Iminus;
    }
480593
public static Text createText(int size)
    {
        return factoryGraphic.createText(Constant.FONT_SANS_SERIF, size, TextStyle.NORMAL);
    }
1053775
public static AreaBD area(final AreaSizeBD size)
  {
    Objects.requireNonNull(size, "Size");
    return AreaBD.of(
      BigDecimal.ZERO,
      size.sizeX(),
      BigDecimal.ZERO,
      size.sizeY());
  }
91828
public static ColumnMajorSparseMatrix randomSymmetric(int size, double density, Random random) {
        return CCSMatrix.randomSymmetric(size, density, random);
    }
510008
public static byte[] getByteArray(int size)
    {
        byte[][] pool = (byte[][])__pools.get();
        boolean full=true;
        for (int i=pool.length;i-->0;)
        {
            if (pool[i]!=null && pool[i].length==size)
            {
                byte[]b = pool[i];
                pool[i]=null;
                return b;
            }
            else
                full=false;
        }

        if (full)
            for (int i=pool.length;i-->0;)
                pool[i]=null;
        
        return new byte[size];
    }
441841
public static <T> T[] createArray(int size, T defaultValue) {
		T[] result = (T[]) GenericReflection.newArray(defaultValue.getClass(), size);
		for (int i = 0; i < result.length; i++) {
			result[i] = defaultValue;
		}
		return result;
	}