If you add another nutrient, you must add another equation. You cannot have more feeds in unknown amounts. Using matrix algebra gives us a very powerful method of solving simultaneous equations with the aid of a computer. The computer programs easily invert the matrix and multiply matrices. This method, just as all simultaneous equations methods, gives exact solutions mathematically, without regard to practicality.
Negative numbers are possible, even though they make no sense nutritionally.
It is not a complicated additional step from setting up simultaneous equations to set up the equations for least-cost solutions. Solving the equation set is harder, we'll let a computer program do that. Another difference is that now we could have a great number of feeds, not just exactly the same number as 'non-trivial equations' that we have. And the solution would use just the feeds that make up the least-cost solution, in the correct amounts. Start by estimating the feed intake of the animal.