The most recent bank’s balance is the number of Biobits that can be distributed as rewards among the contributors at the end of each Zarela’s day. on every Zarela’s day, a fixed number of Biobits will be added to the bank balance, and if there are any Biobits left over from the previous days, this would be added to the bank balance as well. The priority is to distribute the older Biobits available in the Bank. After a Zarela’s day, Zarela's Smart Contract computes the number of contributors per day, and if the maximum number of the due rewards which should be distributed to all contributors of the day is less than the bank balance, in this case, the maximum attainable reward on that day will be dedicated to each contributor and a record of reward (to-be-distributed) will be appended to the payment queue and remaining tokens will be added to the Bank’s balance. Otherwise, the bank balance will be divided equally among all contributors.
Figure 3: Daily reward and bank management snapshot
In Zarela there are different halving stages and consequently the maximum reward is vary based on the current halving stage. Additionally, in Zarela’s platform, reward is calculated on the basis of each Zarela’s day. To elaborate more, assuming that in a certain Zarela’s day there have been N number of contributors which have been contributed on the Zarela’s platform. Assuming the balance of the Bank is B on that certain day. Also, maximum number of distributable reward token in a specific halving is M Biobits per contributor per Zarela’s day (M = 50 in the first halving). Hence, the expected reward of each contributor is calculated as following:
if:NM<BMContributorif : N * M < B \xrightarrow{M} Contributor
{if:NM>BMContributorM<MM=BankBalanceN\begin{cases} if : N * M > B \xrightarrow{M'} Contributor \bigm\vert M' < M \\ M' = \dfrac{BankBalance}{N} \end{cases}
Meaning that if the Bank’s balance is more than the number of contributors multiply by the maximum awardable reward in the first halving then, each contributor will receive the maximum reward. Otherwise Biobit rewards shall not be maximum and will be fluctuated depending on the number of contributors. An example of daily reward of each contributor has been presented below:
Figure 4: Daily reward for each contributor
By Proof-of-Contribution made by the Angel or Hub, one of them (they will choose which of them will receive the reward) will be eligible to receive the reward from the Zarela’s reward pool on the next Zarela’s days. The chosen entity therefore will be appended to the payment queue and she will be waiting to receive her reward on the next Zarela’s days. At the end of each Zarela’s day the number of reward tokens for each contributor will be calculated. This calculation is performed to distinguish between contributors of each Zarela’s day.
Noticeably, if N >288 (number of contributors of a day is bigger than 288 on day 0) then, maximum distributable reward that is set to be M = 50 at the beginning of day 0 will not be achievable at the end of day 0. Therefore, M <M ′ for every contributors. Moreover, at the end of each Zarela’s day, there will be a queue of contributors each of which are distinguishable by their day of contribution. Amount of Biobit daily rewards are depended on the total number of contributors of that day and halving stage in which contribution has made. The fact is there might be differentiation between daily rewards of a certain day and consecutive day as explained above.
Algorithm 1 :Reward Distribution
Input: lastRewardableIndex
Output: reward
if (16 ≤ Contributor Not Yet Received Reward ) then
Distribute DailyReward Of Contributor Based On zarelaDifficultyOfDay ;
if (zarelaDifficultyOfDay != 128 & 16 > Contributor Not Yet Received Reward ) then
Distribute Daily Reward Of Contributor AS NORMAL ;

Zarela network difficulty calculation

To elaborate more on the Zarela network difficulty calculation, following algorithm as pseudo code provided for clarification. It is necessary to elucidate on the purpose of using the variable zarelaDifficultyOfDay used bellow.
Algorithm 2 :Zarela’s network difficulty
Input: QueueLenght , ContributionOfLastDay
Output: Distribute DailyReward , zarelaDifficultyOfDay
Data: QueueWaitingRatio = QueueLength / ContributionOfLastDay
if (QueueWaitingRatio < 5) then
zarelaDifficultyOf Day = 2^QueueWaitingRatio ;
Distribute DailyReward Of Contributor Based On zarelaDifficultyOfDay ;
if (MaxNumberOfWaitingDays ≥ 7 & QueueLength ≥ 384) then
zarelaDifficultyOfDay = 128 ;
Distribute DailyReward Of Contributor Based On zarelaDifficultyOf Day ;
zarelaDifficultyOf Day = 32 ;
Distribute DailyReward Of Contributor Based On zarelaDifficultyOfDay ;
This variable controls the order of token reward distribution among the contributors entering the network. After every Zarela’s day, new contributors pay the transaction fee of rewards of those who are in the payment queue based on the difficulty of Zarela’s daily network (zarelaDifficultyOfDay). Now, based on the zarelaDifficultyOfDay, each contributor triggers the execution of reward token transfer zarelaDifficultyOfDay times. The result will be distribution of rewards token from the bank to the contributors who have been awaiting in the payment queue. It is vital to be mentioned that, in this case the transaction fee of the Zarela’s network will be increased. This is an automatic and decentralized mechanism for paying the rewards in Zarela’s platform. Figure below demonstrates a snapshot of daily reward token distribution process.
Figure 5: Daily reward token distribution

Payment queue

Technically speaking, The payment queue is an array of address wallets (Angel’s address wallet or Hub’s address wallet) that are distinct-able by a zero address (0x0 . . . 0) separator in between each day’s addresses.