v <- 2^(1:30)
zapim(v + 1i*exp(-v))
ishpd(matrix(c(1, 0.1i, -0.1i, 1), 2, 2)) # should be TRUE
isHermitian(matrix(c(1, 3i, -3i, 1), 2, 2)) # should be TRUE
ishpd(rcwis(6, 2)) # should be TRUE
Run the code above in your browser using DataLab