class DiagonalMatrix extends AbstractRealMatrix implements Serializable {

    @Override
    public RealMatrix createMatrix(final int rowDimension,
                                   final int columnDimension)
        throws NotStrictlyPositiveException,
               DimensionMismatchException {
        if (rowDimension != columnDimension) {
            throw new DimensionMismatchException(rowDimension, columnDimension);
        }

        return new DiagonalMatrix(rowDimension);
    }

    public  DiagonalMatrix(final int dimension);
    public  DiagonalMatrix(final double[] d);
    public  DiagonalMatrix(final double[] d, final boolean copyArray);

}