# Are non-square latin hypercubes viable?

At https://github.com/OpenMDAO/OpenMDAO-Framework/issues/599 it is stated that non-square Latin Hypercube experimental design is not well defined (I assume that for higher dimensions that means hypercube must have the same length in every dimension).

I'm wondering why that is. Would it not be possible to, for example, have a LHC scheme where each row in each dimension had one or more samples, and the sample space was relatively evenly sampled, with no correlation between variables? I guess this is actually making a hypercube out of a hyperrectangle, but is there any reason that wouldn't work?

For example, I have a bunch of parameters that I want to change in a physical model. Some have 4 states, some only two. Could I make a hypercube where the Parameters with only two states just have those states duplicated (so that there are two model runs with each of those two states)? how about doing the same with 4-, 3- and 2-state parameters? Could I make an LHC scheme where each dimension has length equal to the smallest common multiple of the states count for each parameter (ie. 12)?

## 1 Answer

I assume by not well defined, they are not arguing from the point of hyper cube versus hyper rectangle, but on the notion of boundaries of the pdfs.

Remember: The basic idea of LHS sampling is to sample with equi-probabilistically. i.e. split a pdf into a equiprobable areas and take a sample from each one. For hyper cubes or rectangles this is quite easy. Just break your $$U[a,b]$$ uniform distribution into $$N$$ intervals: $$(b-a)/N$$.

However if the pdfs are non-square and in high dimensions it can be difficult to define the joint behaviour of the RVs, where some boundaries may end, the shape of equi-probability.

By the way I just realised this question was asked in 2012!!! I must've sorted my question backwards haha. Anyway I hope someone enjoys my answer! :D

• Hah, yeah, this is a pretty old one. I guess my question with non-square PDFs would be couldn't you just do some kind of quantile mapping to turn it into a square PDF and then map it back again after applying an LHC? – naught101 Mar 16 at 7:51
• Still hard to properly define. You want to map unbound spaces into bound spaces, which may not be so easy in high dimensions. Also if each variable has a different pdf this cam become quite hard, and there are infinite amount of ways to partition a quantile of area in 2D space and above. In 1D its clear, but think about what I mean when i say "50% quantile" in a multivariate case, which area am i cutting off? Should it look like a patch, or a balloon, should the boubdaries be straught or wiggle a bit. This is why OP said not "impossible" but not "well defined" – tisPrimeTime Mar 16 at 10:45
• I guess it depends on whether you can assume that each dimension's PDF is independent? – naught101 Mar 17 at 4:19
• That can help the modeling but not give a complete answer. I can have two RVs, X and Y, and say X ~ N(0,1), Y ~ XiSquare(a), so these are continuous and independent pdfs. It still doesn't solve the problems of "how do I define an area patch of 20% probability" etc. It's quite interpretable how you want to integrate across this space. – tisPrimeTime Mar 17 at 5:57