The wording I chose was a purposefully vague description of the elevator-motor-motorController-roboRIO-human group of parts as simply a “system”.
At the end of the day, your goal is to design the mechanical parts, electrical parts, and software to accomplish certan things. In this case, get a cube to a certan height. The “optimal solution” to this is just the best-case result of design criteria that specify this system must act quickly, accurately, safely, simply, etc.
For the software side, you’ve chosen a PID algorithm for the controller. We chose a modified bang-bang algorithm. Both perform the same task, but in different ways. Either could be the “optimal solution”, but only if they fit the design criteria.
In my statement, “injecting info about gravity” simply means designing some part of your system to incorporate the fact that it will have to fight gravity in one direction, and will work with it in the other. It doesn’t matter exactly what your elevator looks like, what motors you used, what control algortihm you picked - the presence of gravity remains. One possible mechanical answer is to use a counterweight or spring. One possible software answer is to add some constant offset to your PID feedforward term. Both should accomplish the same goal when properly designed.
“Trivial to do” will likely be relative per team, but the software answer is pretty straightforward I think. Adding the constant term or gain scheduling is the impelmentation answer.
The key is that totally ignoring the effect of gravity on the system may simplify your work, but also will create a system that has a varying disturbance on it over time. Feedback can help correct for this, but why rely on feedback when you know in advance the distrubance will be present?
Note 254 hit on this a bit - the presence of a cube is an additional disturbance which changes the design criteria for what’s the “optimal solution”. Most folks would just design a software controller that’s “good enough” to account for it. You could also do better installing a sensor to tell you when the cube’s there or not, and doing additional gain scheduling. Again, you’re injecting info about the forces acting on robot into the system in an effort to correct for them.