Sampling uniformly in a triangular support

There are a couple of ways to do it:

  1. You can use the ordered transformation here.
  2. You can add jacobian correction for the volume change in your case above as well to make it proper.
  3. You can jointly sample from a bivariate standard Gaussian then rotating them by 45 degrees. The rotated sample is transformed into rates that lie in the unit square. See here.
  4. You can add a potential to restrict the order, see here cell [4] for an example