In the pulmonary system there are only a few variables that the surgeon can affect. State variables are variables which are constrained but can only be manipulated indirectly. In this case there is only one state variable, namely the flow fraction between the left and right pulmonary arteries. For our purpose, the energy loss through the system is what we want to minimize. In this form, the objective function is unconstrained.
Optimization is achieved by finding the local minimum of the unconstrained objective function.
This is accomplished by performing a least squares polynomial curve fit to the data and finding an estimate of the minimum on the resulting equation. This method is good for getting a quick and relatively close estimate of the local minimum. In order to save time, an initial course mesh is used to begin the analysis. Mesh coarseness is determined by accounting for the estimated magnitude of the error and checking it against the magnitude of the results. This is done to make certain the error does not overwhelm the results.