Stochastic frontier production models were first developed by Aigner, Lovell, and Schmidt (1977) and Meeusen and van den Broeck (1977). Specification of these models allow for random shocks of the production or cost but also include a term for technological or cost inefficiency. Assuming that the production function takes a loglinear CobbDouglas form, the stochastic frontier production model can be written as

where . The term represents the stochastic error component and is the nonnegative, technology inefficiency error component. The error component is assumed to be distributed iid normal and independently from . If , the error term, , is negatively skewed and represents technology inefficiency. If , the error term is positively skewed and represents cost inefficiency. PROC QLIM models the error component as a half normal, exponential, or truncated normal distribution.
In case of the normalhalf normal model, is iid , is iid with and independent of each other. Given the independence of error terms, the joint density of and can be written as

Substituting into the preceding equation gives

Integrating out to obtain the marginal density function of results in the following form:









where and .
In the case of a stochastic frontier cost model, and

The loglikelihood function for the production model with producers is written as

Under the normalexponential model, is iid and is iid exponential with scale parameter . Given the independence of error term components and , the joint density of and can be written as

The marginal density function of for the production function is






and the marginal density function for the cost function is equal to

The loglikelihood function for the normalexponential production model with producers is

The normaltruncated normal model is a generalization of the normalhalf normal model by allowing the mean of to differ from zero. Under the normaltruncated normal model, the error term component is iid and is iid . The joint density of and can be written as

The marginal density function of for the production function is









and the marginal density function for the cost function is



The loglikelihood function for the normaltruncated normal production model with producers is






For more detail on normalhalf normal, normalexponential, and normaltruncated models, see Kumbhakar and Knox Lovell (2000) and Coelli, Prasada Rao, and Battese (1998).