I am trying to formulate a maximization problem using Google's OR-Tools package. The basis of the optimization is a Fantasy MLB Auction draft.
The problem involves the following constraints:
1) Salary Cap of $260
2) 23 total players
2a) At least 1: Catcher, First Baseman, Second Baseman, Third Baseman, Shortstop
2b) At least 2: Starting Pitchers, Relief Pitchers, Utility Players (any batter)
2c) At least 3: Outfielders, Pitchers (any pitcher)
2d) Exactly 6: Bench players (any pitcher or any batter)
My Fantasy MLB league is composed of 6 batting categories and 6 pitching categories. Ideally, I am looking to maximize a lineup that maximizes each of these statistical categories while respecting the aforementioned constraints. My approach is very similar to this NBA Optimizer.
Similarly to the NBA Optimizer example, I've organized player projections/values for each of the 12 statistical categories for the upcoming season.
Then I pass all of those statistics into Google's OR-Tools package:
solver.Maximize(
CatcherHomeRuns + FirstBasemanHomeRuns + SecondBasemenHomeRuns...
StartingPitcherStrikeouts + ReliefPitcherStrikeouts...)
The solver.Maximize function is a huge block containing all the player position types and their associated metrics.
My primary concern right now is that I've formulated this objective function incorrectly (perhaps, based on the constraints of the problem). My intuition is telling me that I ought to be providing coefficients or weights in the solver.Maximize objective function for each of the parts to "balance" the function so that each of the 12 statistical categories is individually maximized.
I'm happy to clarify further on my approach but would be grateful for any feedback on how I am going about formulating my objective function.