func blocks(dim, bsize int) int {
	return (dim + bsize - 1) / bsize
}
blocks returns the number of divisions of the dimension length with the given
block size.
package gonum
import "math"
type Implementation struct{}
const (
	negativeN = "blas: n < 0"
	zeroIncX  = "blas: zero x index increment"
	zeroIncY  = "blas: zero y index increment"
	badLenX   = "blas: x index out of range"
	badLenY   = "blas: y index out of range"
	mLT0  = "blas: m < 0"
	nLT0  = "blas: n < 0"
	kLT0  = "blas: k < 0"
	kLLT0 = "blas: kL < 0"
	kULT0 = "blas: kU < 0"
	badUplo      = "blas: illegal triangle"
	badTranspose = "blas: illegal transpose"
	badDiag      = "blas: illegal diagonal"
	badSide      = "blas: illegal side"
	badLdA = "blas: index of a out of range"
	badLdB = "blas: index of b out of range"
	badLdC = "blas: index of c out of range"
	badX = "blas: x index out of range"
	badY = "blas: y index out of range"
)
const (
	blockSize   = 64  
	minParBlock = 4   
	buffMul     = 4   
)
type subMul struct {
	i, j int  
}
func max(a, b int) int {
	if a > b {
		return a
	}
	return b
}
func min(a, b int) int {
	if a > b {
		return b
	}
	return a
}
func checkSMatrix(name byte, m, n int, a []float32, lda int) {
	if m < 0 {
		panic(mLT0)
	}
	if n < 0 {
		panic(nLT0)
	}
	if lda < n {
		panic("blas: illegal stride of " + string(name))
	}
	if len(a) < (m-1)*lda+n {
		panic("blas: index of " + string(name) + " out of range")
	}
}
func checkDMatrix(name byte, m, n int, a []float64, lda int) {
	if m < 0 {
		panic(mLT0)
	}
	if n < 0 {
		panic(nLT0)
	}
	if lda < n {
		panic("blas: illegal stride of " + string(name))
	}
	if len(a) < (m-1)*lda+n {
		panic("blas: index of " + string(name) + " out of range")
	}
}
func checkZMatrix(name byte, m, n int, a []complex128, lda int) {
	if m < 0 {
		panic(mLT0)
	}
	if n < 0 {
		panic(nLT0)
	}
	if lda < max(1, n) {
		panic("blas: illegal stride of " + string(name))
	}
	if len(a) < (m-1)*lda+n {
		panic("blas: insufficient " + string(name) + " matrix slice length")
	}
}
func checkZVector(name byte, n int, x []complex128, incX int) {
	if n < 0 {
		panic(nLT0)
	}
	if incX == 0 {
		panic(zeroIncX)
	}
	if (incX > 0 && (n-1)*incX >= len(x)) || (incX < 0 && (1-n)*incX >= len(x)) {
		panic("blas: insufficient " + string(name) + " vector slice length")
	}
}