A list of reconstructed values of index constrained curvature measures; the constraints being of the form r<=ind(x)<=r+s.

phi_ind

Format

A list of lists of vectors containing the reconstructed weights; the element names of the outer list are of the form "beta=_,n=", while the the element names of the inner lists are of the form "r=_,s=", the "_" of course replaced by corresponding values.

Source

The values have been computed using the HMC sampler stan and functions from the symconivol package. The code below shows how this data can be generated.

Details

The values have been found by the following steps:

  • sample eigenvalues from the index constrained Gaussian orthogonal/unitary/symplectic ensemble using the HMC sampler Stan,

  • convert the samples samples from the corresponding bivariate chi-bar-squared distribution,

  • reconstruct the weights of the bivariate chi-bar-squared distribution by running the EM algorithm for 100 steps.

See also

constr_eigval, constr_eigval_to_bcbsq, estim_em_cm

Package: symconivol

Examples

# NOT RUN {
library(tidyverse)
library(rstan)

warmup <- 1e3
N <- 1e5
filename_model <- "tmp.stan"

nmin <- 3
nmax <- 10
phi_ind <- list()
for (beta in c(1,2,4)) {
    for (n in nmin:nmax) {
        pat <- pat_bnd(beta,n)
        index_out <- str_c("beta=",beta,",n=",n)
        weights <- list()
        for (r in floor((n+1)/2):(n-1)) {
            for (s in 0:(n-1-r)) {
                index_in <- str_c("r=",r,",s=",s)
                np <- r
                nf <- s
                nn <- n-r-s
                M <- constr_eigval(pos=(np>0), free=(nf>0), neg=(nn>0),
                              filename=filename_model, overwrite=TRUE)
                stan_samp <- stan( file = filename_model, data = M$data,
                                   chains = 1, warmup = warmup, iter = N+warmup,
                                   cores = 2, refresh = 1e4 )
                samp <- list()
                if (np>0) samp$ep <- rstan::extract(stan_samp)$ep
                if (nf>0) samp$ef <- rstan::extract(stan_samp)$ef
                if (nn>0) samp$en <- rstan::extract(stan_samp)$en

                m_samp <- constr_eigval_to_bcbsq(pos=(np>0), free=(nf>0), neg=(nn>0),
                                                 samp=samp)

                em <- estim_em_cm(d=pat$d, low=pat$k_low(r), upp=pat$k_upp(r+s),
                                  m_samp=m_samp, N=100)
                weights[[index_in]] <- em[101,]
            }
        }
        phi_ind[[index_out]] <- weights
    }
}
file.remove(filename_model)
# }