Batch release rules

Batch release rules are the part of a batch definition that specifies by what amount an arriving load increases the forming batch quantity of the batch load to which it is to be accumulated. A batch release function is called by a batch separation function to determine if there is room in a forming batch load for the arriving load. Once a forming batch load has been selected for the arriving load, the batch release function is called again in order to increment the forming batch quantity.

You can create a custom batch release rule and its corresponding function. Your function can have any name that is not a standard system function name. It must accept two arguments in the following order:

  1. A pointer to the arriving load, Type: LOAD*.
  2. A pointer to the batch definition specified on the operation, Type: BATCHDEF*.

Your function should return the amount by which the forming batch load should be incremented (Type: double). Here is an example of a batch release function:


double bqrl (LOAD *ldp, BATCHDEF *batch)
/*-----------------------------------------------------------------
   Function to process quantity rule 1 (1 per part on load).

   ARGS:
    ldp  - pointer to load being added to batch
    batch - batch definition

   RETURNS: load size of ldp
-----------------------------------------------------------------*/
{
   return((double) ldp->losize);
}

To make your custom batch quantity function available to the Scheduler, you must “install” it from the first user-initialization function ucini1 by calling the function sedfbq. The function sedfbq has two arguments in the following order:

  1. The number of the batch release rule for which your function contains tailored logic.
  2. The address of your batch release function.