Feed Plan Fixed Dates
When feed plan is approved, farm managers will plan operations around expected delivery dates. There may be logistical and planning reasons which require the feed mill to commit to the agreed upon dates, one such an example provided is when it snows, and farmers have to plan for plowing services to clear the road for scheduled deliveries. Once something like this has to be coordinated, deliveries optimized by flock performance take a lower priority to showing up at a certain times and dates.
The feed plan fixed date feature will force the regeneration process to lock down specific delivery dates and prioritize creating records with those dates.
Adding Single Fixed Dates
During an in progress feed plan, users may want to fix one or more dates. To fix a single date from the feed plan, right click that date and choose "Set Fixed Delivery Date" from the context menu. This can only be done for records that are not committed or actual deliveries.
If the flock is configured to auto recalculate, the feed plan will regenerate.
This can be done at any point before approval, or during an in-progress feed plan.
Unlike the "Regenerate" option, which will only recalculate records after an updated feed plan record, adding a fixed date will also recalculate records prior to the date being added. The reason, is that planned deliveries in progress that can afford to be edited will need to be re-adjusted to account for feed that we are committing to deliver on a fixed date. Otherwise, we may deliver more than the bins can accommodate on the date we arrive with the schedule delivery.
The record selected, and any others on the same delivery date, will be marked as having a fixed date. Regardless of changes to the feed plan, our goal is to deliver as much as we can on this date.
If the flock is configured to auto recalculate, the feed plan will regenerate.
Fixed delivery dates edited on the main feed plan form will also update the fixed delivery date saved to the database.
Fixed delivery dates can be removed, too. Right click a fixed delivery date (they are distinguishable by icon next to the delivery date) to reveal the context menu option "Remove Fixed Delivery Date". This will remove that date from the list of fixed dates for this flock, and prompt a recalculation for the feed plan.
Fixed dates, and the recalculated feed plan, are not committed to the database until users click "Save".
Adding Fixed Dates During Initial Feed Plan
Before a feed plan has been approved, or while it's in process, all fixed dates can be accessed via the "Fixed Dates" button on the Tools menu.
This screen will allow you to enter many fixed dates at a time, without requiring the feed plan to have already been generated. If we know a set of dates that we must deliver on before even generating the initial feed plan we can enter them here. We can also enter comments for any committed date from this screen- something we can't do when managing them from the feed plan view.
It is important to note, that this list includes any dates that were created or edited from the feed plan view, as well. We can add dates using the context menus, and then manage them and include comments from this dialog.
When the dialog closes, and if the feed plan is configured to regenerate, the whole plan will recalculate to consider the new fixed dates.
Changes to fixed dates and the feed plan will not be committed until we click "Save" from the main form.
Right-clicking any date in the list will allow users to delete that selected date, or clear all dates in the list. Cancelling out of this screen will undo any changes, including deletes. Clicking "Accept" will commit the changes and prompt the user to recalculate, if configured.
While they will not be labeled in the "Approved" feed plan tab, Fixed dates that are created during the approval process will be applied to the in-progress feed plan.
Fixing Every Date in the Initial Feed Plan
You can create Fixed dates by committing every approved delivery as a fixed date when the plan is approved. We are already familiar with the dialog to confirm approval, but after this, we will be prompted with a new option.
Configuration
You can turn on a Fix Date prompt by clicking the checkbox, This will allow Feed Plan to set all created records to fixed dates on Feed Plan approval.
System → Setting →Feed Mill/Scheduling
Initial Approval Prompt
Fixed Date Prompt
The new prompt will ask us if we want to commit every date as a fixed date. This happens after the plan has been saved, but before the in progress records are copied and created.
If the user clicks "Yes", the feed plan will be approved and saved with dates created for each distinct delivery date.
Calculating Fixed Delivery Dates
During the calculation of the feed plan, fixed dates are treated as two things: An inspection criteria and an override for delivery date buffers.
A new delivery cause was added with the creation of this new feature. "Fixed Date Max Delivery Size" is a reason that we might see as we approach an upcoming fixed delivery date. Uncommitted, past deliveries may recalculate to recommend less feed to be delivered, so that more can be scheduled on the fixed date, or so that we do not get a bin return on that date.
This new reason has been added as the lowest priority reason to package and schedule a delivery.
Fulfilled Fixed Dates
Before the feed plan begins to calculate the first step the code performs is to mark all fixed dates behind delivered or committed orders as "fulfilled". Fulfilled dates will still appear in the tool list of dates, and will give the user no indication as to whether a delivery actually occurred at that date or time. When the plan recalculates, these records will not be considered, as we cannot go back and plan orders in the past, behind older orders and deliveries.
If a delivery did not go out at the scheduled, fixed date or time, this can be inferred by comparing the list of fixed dates to the delivery date, or users can add comments to the fixed dates themselves.
Deliveries or committed orders do not have to have been created from the actual fixed date record for the older dates to be marked as fulfilled.
Calculating Delivery Date Every Interval
When each hour of consumption is calculated for the flock, the delivery date for that hour is calculated as well (interval date - configured feed buffers). These delivery dates are now also audited. This is a change from the last version of feed plan, where these dates were calculated once when an order was initialized and then saved in memory.
Now that each hour of the life of the flock has a delivery date, these are compared to each of our fixed dates. If this date meets or exceeds a fixed date by no more than twice the buffer, then this planned delivery that we are calculating must go out on that fixed date. All loads assigned to that order for that day will be assigned that fixed date.
Because delivery date buffers change with overall consumption, and because our logic for rounding will assume past or future hours of consumption to make rounded delivery amounts, we could not code the fixed date logic to look for exact delivery dates. Because of the code above that will wrap up deliveries prior to a fixed date, and because the feed plan process is already designed to optimize delivery sizes without causing overflows or feed returns, the approximation of the dates always results if a difference of hours that should not cause any concerns.
We might want to deliver even more on fixed delivery dates. At present, the code will already attempt this, until a ration or medication goal is met and the "Allow mixed feed" configuration for feed plan is set to false. When this is set, more loads will can be added to other bins on the house, but cannot be dumped on top of current. Turning this configuration off will ignore this constraint, and more feed will go out of fixed dates. Tuning or reducing the size of feed buffers might also improve this, albeit to a small degree.
Fixed Dates Bypass Delivery Optimization
When feed plans are created and their "order object" (the object in the code that attempts to pack up hours of consumption into one or more optimized feed plan loads) has assigned all these records their fixed date, that fixed date is marked in memory as "fulfilled". As we iterate through the hours of consumption on the flock, creating more feed plans, that date cannot be reused.
Rounding
Rounding on fixed date deliveries will only round up, to optimize the amount of rounded feed delivered on the fixed date.
Update to Inspection Criteria
To implement fixed delivery dates, we made them a new check in the inspection criteria. This is the list of reasons that can justify the creation of a feed plan record at any point in the hourly consumption of a flock.
The fixed delivery date criteria is checked only after withdrawal criteria has been checked; because withdrawals are higher priority than fixed dates, deliveries can still be planned when the flock hits a configured withdrawal outside of a fixed delivery date.
Withdrawal Feed
Withdrawal Additives
Feed Profile Condition Met (move to next ration)
Additive Profile Condition Met (move to next mix of additives)
Bin Capacity Reached
Max Delivery Size Achieved
Fixed Delivery Date
Changes to The Audit Detail
A new key can be added to the app.config. This key, "FeedPlanAuditPath" will enable the audit of each feed plan to be written to a file on the local machine.
<add
key="FeedPlanAuditPath"
value="C:\imp\fp\"
/>