Baseball Pitching Rotation

kevinh6673

New member
Joined
Jan 26, 2015
Messages
3
I play a fantasy baseball game called APBA. In this game pitchers are only allowed to pitch once they have the specified days rest, which can be 4, 5, 6 or 8 days rest.

My question is, how do I determine the combination of pitchers needed to play 162 games, remembering that no pitcher can start again, until he has reached his days rest. So obviously I could build a rotation around 5 4 game rest pitchers, or 6 5 game rest pitchers. That is easy, but I want to know how to figure out how I can create combinations. So if I have 6 pitchers, i could use 4 4-game rest pitchers and alternate the 2 5-game rest pitchers.

The reason you want to use combinations is because some pitchers are better than others, so you may want to maximize certain pitchers outings per season.

Hopefully that makes sense. Please let me know if you have any questions, and any help will be greatly appreciated.

Kevin
 
I play a fantasy baseball game called APBA. In this game pitchers are only allowed to pitch once they have the specified days rest, which can be 4, 5, 6 or 8 days rest.

My question is, how do I determine the combination of pitchers needed to play 162 games, remembering that no pitcher can start again, until he has reached his days rest. So obviously I could build a rotation around 5 4 game rest pitchers, or 6 5 game rest pitchers. That is easy, but I want to know how to figure out how I can create combinations. So if I have 6 pitchers, i could use 4 4-game rest pitchers and alternate the 2 5-game rest pitchers.

The reason you want to use combinations is because some pitchers are better than others, so you may want to maximize certain pitchers outings per season.

Hopefully that makes sense. Please let me know if you have any questions, and any help will be greatly appreciated.

Kevin
Hi Kevin,
I don't know the rules so I'll just assume a game every day and no double headers to start with so that the days rest is actual days. Other assumptions are being made also such as it doesn't make any difference whether an opposing team knows who is pitching in advance, etc.

I would actually approach it another way: Start with your best pitcher who needs, say 6 days rest to win the most games for you. This will fill [161/7] + 1 = 24 slots equal to 1, 8, 15, ..., i.e. 1 + 7 n1, n1 = 0, 23 and you will have 138 games left to fill. Now assume your next best pitcher needs say 4 days rest. That will fill [160/5] + 1 = 33 slots (at most), 2 + 5 n2, n2 = 0, 27 where that is not equal to 1 + 7 n1. This time, though, you can just slip the next game to the next unfulfilled slot and keep trucking. That is pitcher two pitches days 2, 7, 12, and 17 and the next time (22)would be the same day as pitcher one, so slip pitcher two to day 23, 28, 33, 38, then 44, 49, 54, 59, then ..., then 128, 133, 138, 143, 149, 154, and 159 for 31 games. Continue in that fashion being careful of what you have already filled.
 
Hi Kevin,
I don't know the rules so I'll just assume a game every day and no double headers to start with so that the days rest is actual days. Other assumptions are being made also such as it doesn't make any difference whether an opposing team knows who is pitching in advance, etc.

I would actually approach it another way: Start with your best pitcher who needs, say 6 days rest to win the most games for you. This will fill [161/7] + 1 = 24 slots equal to 1, 8, 15, ..., i.e. 1 + 7 n1, n1 = 0, 23 and you will have 138 games left to fill. Now assume your next best pitcher needs say 4 days rest. That will fill [160/5] + 1 = 33 slots (at most), 2 + 5 n2, n2 = 0, 27 where that is not equal to 1 + 7 n1. This time, though, you can just slip the next game to the next unfulfilled slot and keep trucking. That is pitcher two pitches days 2, 7, 12, and 17 and the next time (22)would be the same day as pitcher one, so slip pitcher two to day 23, 28, 33, 38, then 44, 49, 54, 59, then ..., then 128, 133, 138, 143, 149, 154, and 159 for 31 games. Continue in that fashion being careful of what you have already filled.

Hi Ishuda,

Thank you so much for your help. I am hoping that we can figure this out as it would be incredibly helpful. You are correct, there are no double headers and it is safe to assume, days(games) are 1 thru 162 no breaks between.

So that being said you do get this:
n1 = 4 game rest pitcher can pitch 32.4 games (32 games) = 5 totals day(1 day to pitch, 4 to rest)
n2 = 5 game rest pitcher can pitch 27 games (32 games) = 6 totals day(1 day to pitch, 5 to rest)
n3 = 6 game rest pitcher can pitch 23.14 games (23 games) = 7 totals day(1 day to pitch, 6 to rest)
n4 = 8 game rest pitcher can pitch 18 games (18 games) = 9 totals day(1 day to pitch, 8 to rest)

If you have:

3*n1 = 96 games
1*n2 = 27 games
1*n3 = 23 games
1*n4 = 18 games
---------------------
164 games
this looks like it works, since only 162 games are played BUT.......

in doing what was discussed above:

n1= 1+5 = 1, 6, 11, 16, 21
n2= 2+5 = 2, 7, 12, 17, 22
n3= 3+5 = 3, 8, 13, 18, 23
n4= 4+6 = 4, 10, 16, 22, 28
n5= 5+7 = 5, 12, 19, 26, 33
n6= 6+9 = 6, 15, 23, 32, 41

So here is where it gets really interesting, I think. the first 6 games are fine, actually the first 9 games are fine, but I don't have a pitcher to pitch game 11. So then if we allow the shorter rest guys to always pitch "on schedule", then I don't have anyone to pitch game 15....

I am positive there is a way to figure this out, but it is giving me some troubles.

Thank you so much for the help.

Kevin
 
The example you show of trying to do all at the same time is going to get complicated real quick since, for example you have n1 and n6 pitching on day 6 so n6 (or n1) needs to be shifted which means other will need to be shifted which ...

Just how one works the rotation out does depend on who you want to use when. If you do have a 'best' pitcher and 'second best' picture, etx. I would start the way I did until I got down to the 'rest of the pitchers', for example you have say 5 starters two of which are definitely the best and second best with the remaining three being about equal.

The actual process could actually be programmed and might be an interesting piece of work. I'm going to look around and see what I can find.

BTW: The reason for the second pitcher in my example starting on day 2 was that it didn't really matter since pitcher one pitched on the first and last day so that if we started at the end and worked backwards it would have been the same. One would need to keep that in mind for seeing when pitcher number three pitched though.

EDIT: Now that I've had a chance to play with it a bit more, even the way I started gets complicated pretty fast so I'm not sure now what one does. Right now I have to give it up but maybe I'll come back to it.
 
Last edited:
I think the example you give:
...
So that being said you do get this:
n1 = 4 game rest pitcher can pitch 32.4 games (32 games) = 5 totals day(1 day to pitch, 4 to rest)
n2 = 5 game rest pitcher can pitch 27 games (32 games) = 6 totals day(1 day to pitch, 5 to rest)
n3 = 6 game rest pitcher can pitch 23.14 games (23 games) = 7 totals day(1 day to pitch, 6 to rest)
n4 = 8 game rest pitcher can pitch 18 games (18 games) = 9 totals day(1 day to pitch, 8 to rest)

If you have:

3*n1 = 96 games
1*n2 = 27 games
1*n3 = 23 games
1*n4 = 18 games...
has no solution.

First fill the first 9 days: Since you can only use any of the n2-n4 pictures once in that first 9 days, you must fill at least 6 other days and that means you have to use each n1 pitcher twice. Now, using the n1 pictures we have the days
a, a+5, b, b+5, c, c+5
covered where a, b, and c are distinct. If we order them so that a < b < c, then since c+5<10, c < 5, b < 4, a < 3
This gives the games of
(1) 1a, 2b, 3c, _, _, 6a, 7b, 8c, _,
(2) 1a, 2b, _, 4c, _, 6a, 7b, _, 9c,
(3) 1a, _, 3b, 4c, _, 6a, _, 8b, 9c,
(4) _, 2a, 3b, 4c, _, _, 7a, 8b, 9c,

Now, for the second 9 games, if you use (1) then you have to use (4) as your second set since that is the only way for a 4 day rest for those n1 pictures. If you use (2), (3) or (4), you can't use the three n1 pictures twice in that second nine game stretch and thus can't fill the full 18 games.

So, for the first 18 games we must have
1a, 2b, 3c, _, _, 6a, 7b, 8c, _, _, 11a, 12b, 13c, _, _, 16a, 17b, 18c,
But you have a nine game stretch [2-10] where you have 4 empty slots but only 3 pitchers to fill them, i.e. you can't use a, b, or c.

Have to go right now but I think I did that right.
 
I think the example you give:
...

has no solution.

First fill the first 9 days: Since you can only use any of the n2-n4 pictures once in that first 9 days, you must fill at least 6 other days and that means you have to use each n1 pitcher twice. Now, using the n1 pictures we have the days
a, a+5, b, b+5, c, c+5
covered where a, b, and c are distinct. If we order them so that a < b < c, then since c+5<10, c < 5, b < 4, a < 3
This gives the games of
(1) 1a, 2b, 3c, _, _, 6a, 7b, 8c, _,
(2) 1a, 2b, _, 4c, _, 6a, 7b, _, 9c,
(3) 1a, _, 3b, 4c, _, 6a, _, 8b, 9c,
(4) _, 2a, 3b, 4c, _, _, 7a, 8b, 9c,

Now, for the second 9 games, if you use (1) then you have to use (4) as your second set since that is the only way for a 4 day rest for those n1 pictures. If you use (2), (3) or (4), you can't use the three n1 pictures twice in that second nine game stretch and thus can't fill the full 18 games.

So, for the first 18 games we must have
1a, 2b, 3c, _, _, 6a, 7b, 8c, _, _, 11a, 12b, 13c, _, _, 16a, 17b, 18c,
But you have a nine game stretch [2-10] where you have 4 empty slots but only 3 pitchers to fill them, i.e. you can't use a, b, or c.

Have to go right now but I think I did that right.


Okay, so with that I do believe that we solved the issue, can't use an 8 game rest pitcher in this sequence. I could use another 6 game rest pitcher. The only way to use that 8 game rest pitcher is to have another 5 or 4 game rest pitcher.

I think that is what I was looking for. This will allow me to figure out the different types of pitchers that I can have to create 5, 6 or even 7 man pitching rotations.


Kevin
 
Okay, so with that I do believe that we solved the issue, can't use an 8 game rest pitcher in this sequence. I could use another 6 game rest pitcher. The only way to use that 8 game rest pitcher is to have another 5 or 4 game rest pitcher.

I think that is what I was looking for. This will allow me to figure out the different types of pitchers that I can have to create 5, 6 or even 7 man pitching rotations.


Kevin

Just rambling for a moment, this type of designing a rotation, i.e. breaking it up to fill a particular run of number of days should work for any combination, you just have to play around to get the right one. Also, notice that if I got to the point where I could start a sequence with that same 9 day start [or what ever length you decide you can use], you are finished. For example, suppose you had 3 five day rest pitchers in addition to your 3 four day rest pitchers, then set the following rotation for the first 20 games:
1a, 2b, 3c, 4d, 5e, 6a, 7b, 8c, 9f, 10d, 11a, 12b, 13c, 14e, 15f, 16a, 17b, 18c,19d,20e
You can just repeat this 20 starting pitcher lineup indefinitely to cover any number of games.
 
Top