The application relates generally to the field of data processing, and in one example embodiment to methods and systems to obtain a relative frequency distribution describing a distribution of counts over a plurality of intervals, and to a machine-readable medium comprising instructions to perform this method.
Automatic Call Distribution (ACD) centers often use forecasting models to forecast contacts, or calls, during certain periods of time. The forecasting models may be useful in determining adequate and efficient staff scheduling, for instance.
According to an aspect of the invention there is provided a computer-implemented method and system to obtain relative frequency distributions to forecast counts used in worker scheduling are described herein. The computer-implemented method includes calculating a plurality of square roots of count data associated with a sequence of a plurality of intervals; extracting a number of amplitudes associated with a plurality of count distributions from the calculated plurality of square roots; calculating a number of counts associated with each amplitude over the plurality of intervals; and squaring the extracted number of amplitudes to obtain a corresponding plurality of estimates of relative frequency distributions describing the distribution of the calculated number of counts over the plurality of intervals.
This patent or application file contains at least one drawing executed in color. Copies of this patent or patent application publication with color drawings will be provided by the Office upon request and payment of the necessary fee.
An example embodiment of the present invention is illustrated by way of example and not limitation in the figures of the accompanying drawings, in which like references indicate similar elements and in which:
According to an aspect of the invention there is provided a method and system to obtain relative frequency distributions to forecast counts used in worker scheduling are described herein. The method includes calculating a plurality of square roots of count data associated with a sequence of a plurality of intervals; extracting a number of amplitudes associated with a plurality of count distributions from the calculated plurality of square roots; calculating a number of counts associated with each amplitude over the plurality of intervals; and squaring the extracted number of amplitudes to obtain a corresponding plurality of estimates of relative frequency distributions describing the distribution of the calculated number of counts over the plurality of intervals.
In an implementation, contacts may include calls or other electronic contacts. In the implementation, a method estimates a probability distribution describing the conditional probability that a call (or other electronic contact) may arrive on a given day (or 1st time period) of a week (or 2nd time period), given the call arrives some day in the particular week. The estimate may be based on a month (or 3rd time period) or several weeks of data for call counts for each day of the month, and the single estimate is to reflect a pattern of distribution, which is common to each week of the month.
The probability distribution describing the conditional probability that a call (or other electronic contact) may arrive on a given day of a week, for instance, given the call arrives some day in the particular week may also be known as a forecasting model, which may be useful in determining adequate and efficient staff scheduling during that week, for instance.
Architecture
The probability distribution module 110 receives normalized contact count data 116 from the database 104 regarding count or contact data over a period of time, for example days, for a particular interval, for example, a week. For each valid data entry in the interval, the data may be a non-negative number. The probability distribution module 110 may receive data 116 associated with a plurality of intervals.
The worker scheduling module 114 may determine staff scheduling during a time interval associated with the forecast data.
At block 210, contact count data 116 may be received as input of a plurality of normalized counts, for example, daily values, for a plurality of intervals, for example, weeks. The contact count data may be represented in a first matrix. The counts may be selected from a group including events, transactions, requests for service, contacts arriving at a system for handling contacts, and arriving customers. The plurality of intervals may be selected from a group including intervals of time, intervals of space, intervals of cyber-space, business abstractions that can be formulated as measurable subsets in a measured space, and subsets in a space of business abstractions, which abstractions are used to at least one of describe, define, and classify different types of counts. The plurality of intervals may be mathematically ordered pairs of any two from the group, or more generally, an ordered n-tuple of any number of types of intervals of the group.
The plurality of intervals may be associated with intervals of time and each time interval may be of substantially constant duration, wherein each time interval is organized into a same number of blocks. The numbers of the amplitude may be squared for each interval of a block to give the relative frequency with which counts assigned to that amplitude occur on that interval of a block. Each time interval may be selected from a period of a day, a day, a period of a week, a week, a period of a month, and a month. The sequence of the plurality of intervals may include a Cartesian product of two selected from a group including a set of time intervals, a set of locations, and a set of locations in cyber-space, a type of count, a set of types that defines a classification of different kinds of counts, a measurable set in a first measure space and a measurable set in a second measure space. Measurable sets and measure spaces are general and abstract mathematical settings for the situation where each cell in a rectangular table at some row and column position corresponds to an ordered pair of (measurable) sets. The first member of the pair is from the first measure space (corresponding to the row) and the second member of the pair is from a second measure space (corresponding to a column.) Measurable sets in a measure space are sets that may have magnitudes (counts, for example) associated with them, and where these magnitudes follow the natural laws of addition for sets.
At block 220, a square root of contact count data associated with a sequence of intervals may be calculated. The sequence may be finite. The square root may be taken of each of the data entries of the contact count data of block 210 and may be represented in a second matrix.
At block 230, amplitudes for count distributions may be extracted from the calculated square root. In an implementation, the transpose of the second matrix may be multiplied by the second matrix to represent a third matrix. In an implementation, a type of eigenvalue/eigenvector mathematical problem is solved for eigenvectors (e.g., amplitudes) and corresponding eigenvalues, which may be considered the number of counts associated with respective amplitudes.
At block 240, a number of counts (e.g., eigenvalues) associated with each amplitude over the sequence of generalized intervals may be calculated. Each of the calculated counts of the number of calculated counts includes a total number of counts, due to the respective amplitude, summed over the sequence.
At block 250, the extracted number of amplitudes (e.g., eigenvectors) may be squared to obtain a corresponding plurality of estimates of relative frequency distributions describing the distribution of the calculated number of counts over the plurality of intervals.
Further, the plurality of estimates of the relative frequency distributions may be normalized to obtain estimates of probability distributions describing distribution of the calculated number of counts over the plurality of intervals. Normalizing the relative frequency distributions may include dividing each of the numbers of the amplitude by a positive constant to obtain another set of numbers, wherein the numbers of the probability distribution sum to one. The amplitude may be selected to render normalization as substantially dispensable.
Example Computation of Probability Distribution
Let mij be the input data on the jth day of the ith week. In this example, there are 7 days in this week. Let M denote the matrix formed from elements mij. In this embodiment, mij>0 for each i and j . aij may be defined by the rule aij=√{square root over (mij)}, and A may denote the matrix formed from the elements aij. The matrix, A, is called the amplitude of the month. AT is the transpose of A.
The computational heart of the extraction of the dominant day of week distribution is solving the mathematical eigenvalue-eigenvector problem: ATAνi=λiνi. The numerical technique sometimes known as “the power method” may be sufficient and appropriate in this implementation to solve the mathematical eigenvalue-eigenvector problem.
The eigenvector(s) and corresponding eigenvalue(s) are solved for, and the components of the dominant day of week distribution, dj, are then given by dj=(ν1j)2 for j=1, 2, . . . , 7, for each eigenvector, as appropriate.
Example Extraction Distribution
The matrix AT A may be a real, symmetric, 7 by 7 matrix. Each eigenvalue of matrix AT A may be real and non-negative. Matrix AT A may have a set of seven orthonormal eigenvectors. There are seven numbers, λ1, λ2, . . . , λ7, (the eigenvalues) which can be ordered so that λi≧λj whenever i≦j. There is a set of seven vectors, {ν1,ν2, . . . ,ν7} in R7, (containing the eigenvectors), which is both orthogonal, in that νi·νj=0 whenever i≠j, and normalized, in that vi·νi=1. The corresponding eigenvalues and eigenvectors are related in that AT Aνi=λiνi.
Each eigenvector in the set corresponds to a different (and independent) day of week distribution. The associated eigenvalue measures the volume of contacts (e.g., calls) that follow that distribution. In particular,
The total monthly call volume may be substantially equal to the sum of the eigenvalues of AT A .
In an implementation, the eigenvalue λ1 may be called the dominant eigenvalue because it is the largest eigenvalue and the greatest number of calls follow the distribution of its eigenvector. The eigenvector ν1 may then be called the dominant eigenvector. Let λ1j denote the jth component of the vector ν1. The components of the dominant day of week distribution, dj, are then given by dj=(ν1j)2for j=1,2, . . . , 7. By comparing the dominant eigenvalue to the total monthly call volume, one can determine how well a particular month of normalized data is represented by a single day of week pattern. Similar comparisons can be made with two and three amplitudes, etc., as described herein.
A technique to solve the eigenvalue-eigenvector problem: AT Aνi=λiνi is based on the following: z1,z2, . . . ,zn, . . . may be assumed to be a sequence of vectors in R7 defined by the recursion:
where ∥zn∥=√{square root over (zn·zn)} and where z1 is a random vector in R7 such that ∥z∥=1. In other words, let z1 be a random variable that is uniformly distributed over the unit sphere in R7. Then the probability is 1 that
converges to a dominant eigenvector of AT A.
Therefore, for large n,
is almost certainly an approximation to a dominant eigenvector of AT A and the corresponding eigenvalue is approximated by ∥zn+1∥.
A dominant eigenvector of AT A is a vector, ν, that (globally) maximizes Aν·Aν subject to the constraint that ν·ν=1. When the monthly call volume matrix, M, actually has the simple form of different weekly call volumes weighted by a single day of week distribution, then the dominant eigenvector recovers that day of week distribution, the dominant eigenvalue equals the monthly call volume, and each of the other eigenvalues are 0. When M is not of that simple form, the dominant eigenvector recovers a day of week distribution that accounts for the largest number of calls that can be attributed to a single day of week distribution and the dominant eigenvalue is that number of calls.
Example Extraction of Dominant Modes
The dominant modes of intraday distribution may be extracted, given valid intraday data for the days in a list of “comparable” dates and an intraday distribution. Some number of days of intraday data, organized by date and time-period, may be received, where the data is valid for every date and time-period. The data may be non-negative.
A maximum number may bind the number of modes (eigenvectors) that may be computed. A tolerance may be used to bind a sum of eigenvalues.
In another implementation, a list of eigenvalue, eigenvector pairs may be generated as follows, which may be a slight modification and generalization of that described in the Example Extraction Distribution above:
Let the input data comprise n days with p time-periods in each day. Let (i,j) refer to the jth time-period of the ith day. Let uij be the input data for the jth time-period of the ith day. For each day, i, let mij denote the distribution for that day. That is, let
so that
Let the intraday distribution matrix, M, be the n by p matrix with elements mij. As in the Example Extraction Distribution, define aij by the rule aij=√{square root over (mij)} and let the intraday amplitude matrix, A, be the n by p matrix with elements aij. The analysis may now proceed as in the Example Extraction Distribution with the results: (1) AT A has p non-negative eigenvalues that the can be ordered by decreasing magnitude, λ1,λ2, . . . ,λp, (2) there is a corresponding set of p orthonormal eigenvectors, {ν1,ν2, . . . ,νp} and (3) AT Aνi=λiνi. Each eigenvector in the set corresponds to a different (and independent) intraday distribution or mode of distribution. The associated eigenvalue may measure the prevalence of that mode in the intraday distribution matrix, M. In particular,
The modes with the largest eigenvalues may be called the dominant modes.
The parameters of the extraction dominant modes may limit the number of dominant modes that may be extracted from the intraday distribution matrix and that may be returned in the output. The described algorithm for extracting the dominant modes is an extension of the power method, which can extract eigenvalue, eigenvector pairs from AT A, one pair at a time, in order of decreasing magnitude of eigenvalue. Let q be the number of pairs that have been extracted at some step of the algorithm. The extraction of pairs may cease under any of four conditions:
Again, the output is the ordered list of the extracted eigenvalue, eigenvector pairs. In the extended power method, the first eigenvalue, eigenvector pair is obtained from a sequence of vectors z1,z2, . . . ,zn, . . . defined by the recursion:
as described in the Example Extraction Distribution.
q eigenvalue, eigenvalue pairs {(λ1,ν1),(λ2,ν2), . . . , (λq,νq)} are found, where νi·νi=1 for i=1, . . . , q. The q+1 eigenvalue, eigenvector pair may be obtained from another sequence of vectors z1,z2, . . . ,zn, . . . , defined by the recursion:
For large n, νq+1 is approximated by
and λq+1 is approximated by ∥zn+1∥.
Example Theory
A “month” (e.g., a block of 7-day weeks) of daily call volume data may be expressed as a product of week and day-of-week factors. That is, let mij denote the volume of calls on the jth day of the ith week and
mij=wjdj, (1.1)
where wi and dj are not negative and some dj is not 0.
M is the matrix formed from the mij so that
M=wdT, (1.2)
where
and n is the number of weeks in the month.
Without loss of generality, it may be assumed that:
For suppose that
then
where ŵ=Dw, {circumflex over (d)}=1/D d , and
Define the n×7 matrix, A={aij}, by the rule
aij=√{square root over (mij)} (1.7)
and let {tilde over (w)}i=√{square root over (wi)} and √{square root over (d)}j=√{square root over (dj)} so that
A={tilde over (w)}{tilde over (d)}T (1.8)
Again, the matrix, A, may be called the “amplitude” of the monthly call volume. Interpret A as a matrix that maps R7 into Rn, so that for any x in R7, Ax is in Rn.
Let (x,y) denote the usual inner product that equips either R7 or Rn with its usual Euclidean norm, denoted ∥*∥.
In particular, note that
so
∥{tilde over (d)}∥=1 (1.9)
The following is a significant property of {tilde over (d)} stated as a theorem, theorem I.
Theorem I: Suppose A={tilde over (w)}{tilde over (d)}T where ∥{tilde over (d)}∥=1. For each x in R7 such that ∥x∥=1, ∥Ax∥ is a maximum when x={tilde over (d)}.
Proof I:
∥Ax∥=∥{tilde over (w)}{tilde over (d)}Tx∥=∥{tilde over (w)}({tilde over (d)},x)∥=|({tilde over (d)},x)|∥{tilde over (w)}∥=∥{tilde over (d)}∥∥x∥∥{tilde over (w)}∥|cos(θ)|=∥{tilde over (w)}∥|cos(θ)| (1.10)
where θ is the angle between x and {tilde over (d)}. But |cos(θ)| is a maximum when θ is an integral multiple of π, in which case x=±{tilde over (d)}. Therefore, ∥Ax∥ is a maximum when x={tilde over (d)}.
When M=wdT and
there are simple ways to determine the values of the dj. However, when a matrix is not of the form wdT for any choices of w and d, both the meaning and values of the day-of-week factors are ambiguous. In particular, if call volumes are approximated using a pattern the calls do not actually follow, then some theory of the error in the approximations may be useful in selecting “better” (e.g. sufficient) approximations. Some absolute measure that indicates when the approximations are good (e.g. sufficient) and when they are bad (e.g. insufficient) may be useful. For example, sometimes the “best” approximation is not good enough and sometimes the “worst” approximation is sufficient. Disambiguating the concept of day-of-week factors for the case of months that do not follow the simple pattern where M=wdT may be attempted.
Observe that Theorem I characterizes the day of week factors as a solution to a mathematical optimization problem. This mathematical optimization problem may include solutions even when the matrix is not of the form M=wdT. Solutions to a closely related, but slightly generalized, mathematical optimization problem may be used herein to define week and day-of-week factors for general months that do not necessarily follow the simple pattern. Vectors, x, may be sought such that ∥Ax∥2 is stationary, subject to the constraint that ∥x∥2=1. Note, at any vector where (subject to the constraint) ∥Ax∥2 has a local maximum, has a local minimum, has a saddle point, and/or is locally constant, ∥Ax∥2 may be stationary. More formally, a real-valued function, F, is said to be stationary at x subject to the constraint that ∥x∥=1 whenever
It turns out, when there are less than 8 weeks in a plurality of intervals or a “month”, these optimal vectors may be used to exactly express both A and M in terms of products of week and day-of-week factors. As well, they may provide simple approximations of A and M with known error.
Analysis and interpretation of these optimal vectors, x, are discussed below:
Let M be an n×7 real matrix with elements mij≧0 for i=1, 2, . . . , n and j=1, 2, . . . , 7. n≦7 may be assumed. Let A be the amplitude of M, so that A is an n×7 real matrix with elements aij>0, where aij=√{square root over (mij)} for i=1,2, . . . , n and j=1,2, . . . , 7.
Vectors, x in R7 that make ∥Ax∥2 stationary may be sought, subject to the constraint that ∥x∥=1 Using the technique of Lagrange multipliers, this mathematical problem involving a constraint may be solved upon introduction of a new, auxiliary variable, λ, used to define a related mathematical problem that does not involve any constraints. An auxiliary function H may be defined by:
H=∥Ax∥2−λ(∥x∥2−1). (1.12)
In an embodiment, from calculus, the values of x and λ for which H is stationary, give exactly the values of x for which ∥Ax∥2 is stationary, subject to the constraint that ∥x∥=1. Let x be expressed in components as
A condition that H is stationary is given by the following system of 8 equations:
Expressing H in components includes:
Enforcing the first 7 conditions in (1.14), the following is determined:
or simply:
AT Ax=λx (1.19)
Enforcing the last condition in (1.14) by differentiating (1.15) with respect to λ and setting the result to 0 gives:
∥x∥2=1 (1.20)
Equations (1.19) and (1.20) define a kind of eigenvector-eigenvalue mathematical problem. An eigenvector of (1.19) is any x such that x≠0 and AT Ax=λx for some number, λ.
An eigenvalue of (1.19) is any number, λ, such that AT Ax=λx for some x≠0. Note that when ν is an eigenvector of (1.19), so is ν/∥ν∥, and ν/∥ν∥ also satisfies equation (1.20). The “stationary” vectors for the mathematical optimization problem may be found if the eigenvectors of (1.19) may be found.
A matrix, B, is symmetric if B=BT. A set of vectors, {ν1,ν2, . . . ,νk} in Rm is orthogonal if (νi,νj)=0, whenever is j and (νi,νj)≠0 whenever i=j. A set of vectors, {ν1,ν2, . . . ,νk} in Rm is orthonormal if it is orthogonal and (νi, νi)=1 for i=1, 2, . . . , k.
The matrix, AT A, is a 7×7 real matrix and is “symmetric” in that (ATA)T=((A)T(AT)T)=ATA. In other words, the matrix equals its own transpose.
From the theory of linear algebra, it is asserted that:
Theorem II: The eigenvalues of the matrix AT A are not negative.
Proof II: Let ν be an eigenvector of AT A corresponding to the eigenvalue, λ. Let y be defined by the rule: y=Aν. Then:
0≦(y,y)=(Aν,Aν)=(ν, AT Aν)=(ν,λν)=λ(ν,ν) (2.1)
but (ν,ν)>0 so λ≧0.
Let {ν1,ν2, . . . ν7} be a set of orthonormal eigenvectors for AT A. The indices may be assumed to have been arranged in order by the decreasing magnitude of the eigenvalues. That is, when AT Aνi=λiνi, then λi≧λj whenever i<j.
Each of the first p eigenvalues in this ordering may be assumed as positive, but any other eigenvalues may be 0.
Define {tilde over (y)}i by the rule {tilde over (y)}i=Aνi for i=1, 2, . . . , p . Let
for i=1,2, . . . ,p.
Theorem III: ∥{tilde over (y)}∥=√{square root over (λi)}, for i=1,2, . . . , p.
Proof III: ∥yi∥2=({tilde over (y)}i,{tilde over (y)}i)=(Aνi,Aνi)=λi(νi,νi)=λi.
Theorem IV: {y1,y2, . . . yp} is orthonormal.
Proof IV:
so the yi is normalized.
On the other hand,
But since {ν1,ν2, . . . ν7} is orthonormal so is {ν1,ν2, . . . νp}. Therefore, (νi,νj)=0 and the equality (2.2) forces (yi,yj)=0 whenever i≠j. But then the elements of {y1,y2, . . . yp} are both normal and orthogonal. Therefore, {y1,y2, . . . yp} is orthonormal.
Theorem V: The amplitude, A, of a month, M, decomposes into a sum of matrices each of which is the product of week and day-of-week factors and where both the set of week factors and the set of day-of-week factors are orthonormal. That is,
where {y1,y2, . . . yp} and {ν1,ν2, . . . νp} are both orthonormal.
Proof V: Let
and let x be any vector in R7 . Let ci=(x,νi) for i=1,2, . . . ,7. But then
because {ν1,ν2, . . . ν7} spans R7 and
for each j=1,2, . . . ,7. Therefore,
In an embodiment, because x is arbitrary,
Define Ak by the rule Ak=ykνkT and αk by the rule αk=√{square root over (λk)} for k=1, 2, . . . , p. Then A may be expressed as:
This shows that A is a weighted sum of “simple” amplitudes, the Ak, each of the forms given in (1.8). Each such amplitude is an n×7 matrix. Let ak;ij denote the coefficient in the ith row and jth column of Ak. For each k let yk;i denote the ith component of yk and let νk;j denote the jth component of νk. Therefore, ak;ij=yk;iνk;j. The coefficients of any amplitude may also be considered to be a vector in R7n, with its usual norm and inner product. In this case, ∥Ak∥2 may be defined as
and (Ak,Aq) may be defined as
For each k, define a corresponding call-volume matrix, Mk, by the rule mk;ij=λkak;ij2.
The amplitudes, Ak, may enjoy a number of significant properties. For example see Theorem VI.
Theorem VI:
AkTAr=0 and AkArT=0 when k≠r.
AkTAk=νkνkT= and AkAkT=ykykT.
(Ak,Ak)=∥Ak∥2=1.
(Ak,Aq)=0 when k≠q.
There are also significant properties of M expressed in terms of the eigenvalues as shown in Theorem VII.
Theorem VII:
In other words, the total monthly call volume equals the sum of the call volumes due to each of the k patterns.
A call may be assumed to have a state indexed by k. Each amplitude matrix, Ak, may be an amplitude describing the week˜day-of-week distribution of a call that is in the kth state. When a call is in the kth state, the probability, Pk;ij, that the call may arrive on the jth day of the ith week may be defined to be ak;ij2=yk;i2νk;j2. That is, pk;ij may be defined by the rule pk;ij=ak;ij2. Note that the probability that a call in the kth state arrives on some day is
that it arrives on the jth day of some week is
and that it arrives on some day during the ith week is
Therefore, when in the kth state, the weekday-of-week joint probability distribution is the product of two independent probability distributions, one for the week and one for the day-of-week.
In an implementation, a call may be in a blend (or superposition) of states. The blend may be described by defining amplitudes, βk, for the call to be, in each of the k states. In an implementation,
so that βk2 is the probability that the call may be in the kth state. The amplitude for the week-day-of-week distribution of the blended call is
The probability that the blended call may arrive on the jth day of the ith week is
In this formulation, the probability for a given day of the month is the result of interference of the weighted amplitudes of each of the states on that day. It may be shown that
and similarly,
The former asserts that the probability a blended call arrives on the jth day of some week is just the sum, over all states, of the probability the call is in the kth state times the probability the call arrives on the jth day of some week given the call is in the kth state. The latter asserts that the probability a blended call arrives on some day during the ith week is just the sum, over all states, of the probability the call is in the kth state times the probability the call arrives on some day during the ith week given the call is in the kth state. In other words, νk;j2 is the conditional probability that a call arrives on the jth day of the week, given the call is in state k, and yk;i2 is the conditional probability that a call arrives on ith week, given the call is in state k.
The probability amplitude, γk, may be defined by the rule:
so that
N may be defined to be the total number of calls in the month. That is,
In this case, M may be interpreted as giving the expected number of calls on each day of the month when N calls arrive that month and each call has a probability amplitude given by:
Furthermore,
Finally, this analysis suggests two alternate ways to think about the day-of-week distribution for a month:
The second alternative above may suggest the following: any given call is most likely of the kind where k=1. This is because the eigenvalues discussed above are ordered in such a way that γ1≧γk. for each k, γk2 is greatest when k=1. Therefore, k=1 is a most probable kind of call; when the largest eigenvalue is unique, k=1 is the most probable kind of call. Therefore, for any given call, a most likely day-of-week probability distribution is given by ν1;j2.
Averaging over each calls, the expected value of the day-of-week probability distribution may be
Example Implementation
In an example embodiment, there are seven weeks of a calendar is considered a kind of “long” month and there is a “count” of events or contacts associated with each day of the seven week period, as shown in Matrix 1, where M denotes the matrix 1 formed from elements mij. It is assumed that mij≧0 for each i and j. Elements mij correspond to the number of contacts (e.g., call counts) during the particular period i of j. Seven weeks is chosen in this example, however, any number of weeks may be used. Further, i is chosen in this example to correspond to a day, however, any time period may be used. In addition, j is chosen in this example to correspond to a week, however, any time period may be used.
Each column corresponds to a day of the week and each row corresponds to a week of the long month. The counts in Matrix 1 were generated by a stochastic process. This matrix (table) of counts might also be visualized graphically as either a sequence of weeks as shown in
The amplitude A of the counts of the month is obtained by taking the square root of the counts mij on each day, as shown in Matrix 2, A. A denotes the matrix formed from the elements aij. aij is defined by the rule aij=√{square root over (mij)}.
The graph associated with the amplitude of the counts of the month is illustrated at
This amplitude matrix (Matrix 2, A) is multiplied (using matrix multiplication) on the left by its own transpose to obtain a symmetric day-of-week by day-of week matrix, which can be thought of as the “inner-square” of the count amplitude matrix as shown in Matrix 3. Let AT be the transpose of A.
The eigenvalues λ and a set of orthonormal eigenvectors ν for the inner-square of the amplitude can be found by any method known to those of skill in the art, solving the mathematical eigenvalue-eigenvector problem:
AT Aνi=λiνi.
Matrix 4 illustrates the eigenvalues λ1 of the inner-square of the count amplitude in this example.
MATRIX 4, λi:
1627.355 51.22686 3.521141 1.6047 0.874811 0.395056 0.022026
In this example, each of the eigenvalues λ1 are non-negative and the sum of the eigenvalues λ1 is 1685. The sum of the eigenvalues λ1 equals the total number of counts mij in the long month, in this example.
Matrix 5 illustrates the eigenvectors νij.
In Matrix 5 of eigenvectors, each row gives the components of an eigenvector. The first row is an eigenvector for the first eigenvalue, the second row is an eigenvector for the second eigenvalue, and so on. These particular eigenvectors form an orthonormal set.
Each eigenvector ν describes a pattern of distribution of counts across the days of the week. The corresponding eigenvalue gives the count of events or contacts that follow that pattern.
The sum of the squares of the components of each eigenvector equals one (1). Therefore, the squares of the components of each eigenvector may be interpreted as a probability distribution. In this situation, each eigenvector may be thought of as the “amplitude” of a day-of-week probability distribution. Matrix 6 illustrates the probability distributions obtained from their amplitudes by squaring components as follows: νij2.
The components of the dominant day of week distribution, dj, are given by dj=(νij)2 for j=1,2, . . . , 7.
The count amplitude of any week in the long month may be expressed as a linear combination of the day-of-week amplitudes. Matrix 7 illustrates coefficients that can be used to express each week of the count amplitude of the long month as a linear combination of the day-of-week amplitudes. In one of many possible implementations, Matrix 7 may be calculated by the dot product of Matrix 2 and Matrix 5: aij·νij. In Matrix 7, the columns correspond to the different weeks of the month and the rows correspond to the different day-of-week amplitudes.
That is to say, for example, the count amplitude of the first week of the long month equals 15.38732 times the first eigenvector plus 3.799734 times the second eigenvector . . . plus 0.032158 times the seventh eigenvector.
Matrix 8 includes a table of the two dominant day-of-week amplitude's coefficients in the count amplitude of the month. Matrix 8 is the same as the first two rows of Matrix 7.
The count distribution may be approximated from the dominant day-of-week amplitudes. First, the count amplitude of the first week may be approximated as 15.38732*Amp1+3.799743*Amp2, and the count amplitude of the second week may be approximated as 15.58701*Amp1+2.54287*Amp2, and so on, to approximate the count amplitude of the seventh week as 14.52813*Amp1+−4.05528*Amp2.
Matrix 9 and
The component of the count amplitude on any day of the month may be squared to obtain the approximate number of counts for that day. Matrix 10 and
The total number of counts in this approximation is 1678.582 and that is just the sum of the first two eigenvalues. When two or more amplitudes are used in such an approximation, the act of squaring that converts a count amplitude to a count, results in “interaction” or “interference” among the amplitudes.
If the first three amplitudes are used, then a better approximation of actual counts may be obtained in this instance, as compared to using the first two amplitudes. Matrix 1 1 and
Matrix 11 and
One use of the automated algorithms described herein is to update the probability distributions used in a model to forecast future counts. These automated algorithms may make consistent judgments about enormous quantities of numerical data, and may reduce the risk that clerical errors associated with manual update activities may deform the forecast model. Automated introduction of the new data may avoid inappropriate changes in the day of week patterns that are extracted from the data, which may reduce deformation of the forecast model.
Output for this method includes a day of week distribution, in an embodiment. In the case of call-volume, the output is a single (conditional) probability distribution used to describe the probability that a call arrives on a particular day of the week, given that the call arrives sometime that week.
There may be multiple day of week distributions, one corresponding to each week. In an additional embodiment, the extraction of this distribution may take into account that a single day-of-week distribution may be used to represent each week of the month, even though the data may follow different distributions for each week. In some embodiments, an accurate representative distribution may not be a simple average of the day of week data or the distribution for any particular week of the month. Rather, it may depend on co-variation (or correlation) in the data due to the week of the month and the day of the week interactions. For this reason, a kind of singular value decomposition may be used to extract a dominant day-of-week distribution for a month of data.
Computer Architecture
The example computer system 600 includes a processor 602 (e.g., a central processing unit (CPU), a graphics processing unit (GPU) or both), a main memory 604 and a static memory 606, which communicate with each other via a bus 608. The computer system 600 may further include a video display unit 610 (e.g., a liquid crystal display (LCD) or a cathode ray tube (CRT)). The computer system 600 also includes an alphanumeric input device 612 (e.g., a keyboard), a user interface (UI) navigation device 614 (e.g., a mouse), a disk drive unit 616, a signal generation device 618 (e.g., a speaker) and a network interface device 620.
The disk drive unit 616 includes a machine-readable medium 622 on which is stored one or more sets of instructions and data structures (e.g., software 624) embodying or utilized by any one or more of the methodologies or functions described herein. The software 624 may also reside, completely or at least partially, within the main memory 604 and/or within the processor 602 during execution thereof by the computer system 600, the main memory 604 and the processor 602 also constituting machine-readable media.
The software 624 may further be transmitted or received over a network 626 via the network interface device 620 utilizing any one of a number of well-known transfer protocols (e.g., HTTP).
While the machine-readable medium 622 is shown in an example embodiment to be a single medium, the term “machine-readable medium” may be taken to include a single medium or multiple media (e.g., a centralized or distributed database, and/or associated caches and servers) that store the one or more sets of instructions. The term “machine-readable medium” may also be taken to include any medium that is capable of storing, encoding or carrying a set of instructions for execution by the machine and that cause the machine to perform any one or more of the methodologies of the present invention, or that is capable of storing, encoding or carrying data structures utilized by or associated with such a set of instructions. The term “machine-readable medium” may accordingly be taken to include, but not be limited to, solid-state memories, optical and magnetic media, and carrier wave signals. Although an embodiment of the present invention has been described with reference to specific example embodiments, it will be evident that various modifications and changes may be made to these embodiments without departing from the broader spirit and scope of the invention. Accordingly, the specification and drawings are to be regarded in an illustrative rather than a restrictive sense.