# Centralized Task Allocation and Alignment Based on Constraint Table and Alignment Rules
## 3 Scoring Scheme
### Modified Time-Discounted Reward  
The basic time-discounted reward function calculates the reward of agent \(i\) as the maximum reward of each task decreases over time as below [12; 17]:  
\[S_{i}^{p_{i}}=\sum_{j\in p_{i}}\bar{c}_{j}\rho_{i}^{\tau_{i}(\mathbf{p}_{i})} \tag{6}\]  
where \(\bar{c}_{j}\) is time-invariant maximum reward of task \(j\), \(\rho\) is decreasing ratio, and \(\tau_{i}^{j}(\mathbf{p}_{i})\) is arrival time of task \(j\) for agent \(i\) along the sequence of task \(\mathbf{p}_{i}\). If the reward can be obtained when the agent finishes the task, \(\tau_{i}^{j}(\mathbf{p}_{i})\) can be substituted to the end-time of task \(j\). This method can be used in various ways. For example, if the importance of each task is different, a reasonable sequence of tasks can be made by setting \(\bar{c}_{j}\) to the importance level of task \(j\). Additionally, it can be used in food delivery problems if \(\bar{c}_{j}\) is the same for all tasks and \(\rho\) is different for each task. In that case, delivering the food to appropriate places would be tasks, and \(\rho\) differs by the kind of food. If the reward of task is considered as safety level, it can be used in finding the safest sequence of tasks for agent \(i\).  
However, this rewarding scheme needs to be fixed because of two cases: one is that an agent is confirmed to perform a task because they arrive at the task point early, but finishes the task later than other agents; the other is that the agent cannot be confirmed to perform a task based on the rewards when several agents finish the task simultaneously. The second case occurs usually because of temporal constraints. Therefore, a modified time-discounted rewarding scheme has to be applied in TACTAR.  
\[S_{i}^{p_{i}}=\sum_{j\in p_{i}}\bar{c}_{j}\bigg{(}w_{arr}\rho_{i,arr}^{\tau_{ i,arr}(\mathbf{p}_{i})}+w_{e}\rho_{i,arr}^{\tau_{i,arr}(\mathbf{p}_{i})}\bigg{)} \tag{7}\]  
where \(w_{arr}\) and \(w_{e}\) are weights for arrival and end rewards, respectively, and \(\tau_{i,arr}^{j}(\mathbf{p}_{i})\) and \(\tau_{i,end}^{j}(\mathbf{p}_{i})\) are arrival time and end-time of task \(j\) for agent \(i\) based on sequence of tasks \(\mathbf{p}_{i}\).  
\begin{table}
\begin{tabular}{c c} \hline \hline
**Entry (T(\(\mathbf{q}\), \(\mathbf{p}\)))** & **Description** \\ \hline \(0\) &
\begin{tabular}{c} Diagonal component (if task \(p\) and task \(q\) are same) \\ Maximum amount of time at which task \(q\) can start after task \(p\) starts \\ \(\infty\) \\ \end{tabular} \\ \hline \hline \end{tabular}
\end{table}
Table 4: Entry for temporal constraint matrix in CCBBA.  
\begin{table}
\begin{tabular}{c c} \hline \hline
**Entry Code (\(\mathbf{D(q}\), \(\mathbf{p}\)))** & **Description** \\ \hline \(0\) & \
\begin{tabular}{c} Task \(p\) can be allocated independently of task \(q\) \\ Task \(p\) and \(q\) are mutually exclusive \\ \(1\) \\ \end{tabular} \\ \(a>1\) &
\begin{tabular}{c} Task \(p\) depends on task \(q\) \\ Task \(p\) requires either \(q\) or another element with the same code, \(a\) * \\ \end{tabular} \\ \hline \hline \end{tabular}  
* Entries are used sequentially: 3 is not used unless 2 is used.  
\end{table}
Table 3: Entry codes for dependency matrix in CCBBA.