Summary of the invention
Technical matters: the present invention is directed to existing radio frequency identification system computation tag number needs and wanted processing time of a specified duration and energy and use also problem than poor efficiency, propose a kind of in radio frequency identification system the method for computation tag quantity efficiently, make that radio frequency identification system can be on the basis that consumes extremely short time and few energy, calculate the number of labels in the appointed area, and can be applicable to plurality of application scenes.
Technical scheme: the present invention proposes a kind of method of the quantity of computation tag efficiently.This method mainly is divided into two steps: first step is to estimate number of labels fast; Second step is accurate counting.In the practical application, must be accurate if do not require the result, rfid system can only adopt first step, thereby obtains the number of labels result of an estimation in the extremely short time.If the system requirements result must be very accurate, then after carrying out the first step end, carry out the calculating of second step again.Accurately counting is compared with estimation and can be consumed more time and energy, but compares with existing counting technology, and efficient is greatly enhanced.
Estimate the detailed process of (LoF) fast:
We are being had and are only having a rfid interrogator by in the zone of adding up at hypothesis, and the communication range of this read write line can cover whole zone.The label of known each RFID all has an identification number (ID), and ID is a binary number of L position.Therefore, the total quantity of label can not be more than n=2
LIndividual.
At first, rfid interrogator radio request signal.And the answer that begins to monitor label.The method of monitoring is for using the ALOHA time frame: layout when an ALOHA time frame comprises L (the mark preface is 1,2 ..., L), the time layout time length be (as 0.1 second) fixed.Label receives after the request, when needing to select L in the layout one, and answer in this time.In at lattice sometime, read write line is only received the answer of a label, and then read write line can identify the information that label sends; If read write line has been received the message that a plurality of labels are beamed back at lattice in the time, label collision will take place, and what is the need breath is not taken the post as in read write line identification, only can know conflict has taken place.
In the present invention, the RFID label adopts following method to come the select time lattice to answer: each label all uses same geometric distributions hash function H.The character of geometric distributions hash function is: if the overall situation has 2
LIndividual different ID (identity number) then has 2
L-1Layout when individual meeting is mapped to the 1st; Have 2
L-2Layout when individual meeting is mapped to the 2nd; Have 2
L-tLayout when individual meeting is mapped to t.The ID that supposes certain label is i, and H (i)=t, and layout was answered read write line when then this label was chosen in t.As shown in Figure 1.
So read write line create one long be the table of bits of L, and the answer of monitoring label in the ALOHA frame under connecing.Not answering if the some time layout has label, is 0 with bit position corresponding in the table of bits then; If there is 1 to answer or clash, be 1 then with the corresponding bit position.After monitoring end, read write line (or the coupled main frame) value of finding is 1 the highest bit, supposes that it is the R position.The total quantity of label is that available following formula is estimated:
The estimated value of the total quantity of label is
Be the estimated value of number of labels.Its theoretical foundation can be referring to [C.Qian, H-L.Ngan, Y.Liu, " Cardinality Estimation for Large-scale RFID Systems ", in proceedingof IEEE PerCom, 2008.].
We are with this method called after LoF (Lottery Frame) estimation algorithm.
It should be noted that: there is no small error in this kind method of estimation.Only do not need an estimated value in certain error range if do not proceed next step accurate counting, the present invention can adopt and repeatedly repeat estimation approach and can significantly reduce error: be about to above process and repeat to carry out m time, all adopt different hash functions at every turn.As last estimated value, error will reduce m with m time average
1/2Doubly.If repeat 32 times, 15% error then only arranged.
Method of estimation of the present invention is compared with existing method of estimation, is reduced to original about 10% computing time.
Accurately count the detailed process of (PAC):
Among the present invention, accurately counting (PAC, Precise and Anonymous Counting) is made up of two parts, is respectively multidimensional division and counting.
The multidimensional division is (divide-and-conquer) process of dividing and ruling.In the estimation of previous step, read write line and main frame have not only obtained the estimated result of a number of labels, and the label total collection in also should the zone has been divided into the plurality of sub set.As: the label of answering read write line the 1st time in the layout has been formed subclass S
1 The label of answering read write line in the layout in the time of t has been formed subclass S
tMain frame also can be estimated the number of tags that each subclass comprises by following relational expression:
Subclass S
iInclude approximately
Individual label.
If
Greater than a threshold value (we are L in this fixed this threshold value, i.e. the figure place of label ID (identity number)), then subclass S
iNeed divide once more.With the method that is similar to quick estimation: read write line sends request signal, allows layout answer when all labels of layout are selected in ALOHA frame next time when answering i in the estimation fast for the first time.All the other labels are being kept silent in the ALOHA frame next time.So S
iContinuation is split into several littler subclass.This time division is referred to as the two dimension division.If still there is subclass, then proceed three-dimensional division, four-dimensional division greater than L ... till the subclass that does not exist greater than L.As shown in Figure 2.
If the quantity survey (surveying) value of a certain subclass
Less than threshold value L, then read write line and main frame are accurately counted the label in this subclass.When accurately counting, read write line generates and contains
The ALOHA frame of layout when individual, and require subclass S
iIn label when selecting one at random layout answer.If only there is a label to answer in the some time layout, counter is from increasing one; If conflict has taken place the some time layout, then adopt existing tree type conflict solution.
Tree type conflict solution process is as follows: if conflict has taken place the some time layout, layout when then read write line continues to emit two at the label in these lattice allows the label of conflict select an answer at random in the two.If conflict is still arranged, layout when again each conflict lattice being emitted two again.Till this process knows that all time layouts all do not conflict.The logical organization of Sheng Chenging is the one tree shape at last.For all time layouts that an answer is only arranged, counter adds one one by one.As shown in Figure 3.
Last counter has just obtained the number of labels result of ultimate demand with the results added of each piece gained.
Among the present invention, estimate again earlier for label and accurately to count, than directly concerning all labels directly carry out tree type counting, because we have grasped the estimated information of number of labels in advance, therefore will significantly reduce the possibility that conflict takes place, thereby accelerate the speed of counting, and reduce the energy that consumes.
In the accurate counting method of existing tree type, read write line requires each label all to disclose its ID, and this uses for some, exist potential safety hazard, for example the assailant installs the read write line of a malice, can easily obtain label ID by tree type counting method, and then the tracking tags carrier.And, being in the consideration of privacy, a lot of label carrier do not want to disclose the ID of its label yet.Therefore anonymous agreement has bigger using value in radio frequency system.In addition, because the error in the production run has some label to have the ID identical with other labels probably, this label is called as redundant copy.When having redundant copy, just can't use traditional tree type conflict solution, because same ID can continue to cause conflict.
In order to solve above problem; the present invention uses following mode to protect label carrier's privacy also to detect the existence of redundant copy simultaneously: in manufacture process; on the label except that with its ID; also with MD5 (ID); BF1 (MD5 (ID)), BF2 (MD5 (ID)) and 4 numerical value of BF3 (MD5 (ID)).Wherein MD5 (ID) carries out a result after the mapping of MD5 hash function to ID; BF1 (MD5 (ID)), BF2 (MD5 (ID)) and BF3 (MD5 (ID)) are the mapping result of MD5 (ID) being carried out again three Bloom filtrators (Bloom Filter).In accurate counting process, label is beamed back three the Bloom Filter mapping value of oneself to read write line, rather than the ID of oneself.If read write line finds that three Bloom Filter mapping value of certain several label are identical, then can suspect among these labels has redundant copy, and requires they reports MD5 (ID) value separately.If MD5 (ID) value is still identical, then judging among these labels has redundant copy.In whole process, label is not revealed the ID value of oneself, so the accurate counting method of PAC is a kind of method of counting of anonymity.
Need to prove that realization of the present invention need be carried out transformation on the hardware to label, as write hash function etc. in label.Therefore can't realize method of counting of the present invention with existing label, need in producing the label process, carry out special manufacturing.
Beneficial effect:
Label counting method in the radio frequency identification system that the present invention proposes is compared with the method for existing computation tag quantity, has the following advantages:
● the processing time is short.We compare existing UPE label evaluation method and LOF estimation algorithm; And the accurate counting method of existing tree type compared with the accurate counting method of PAC.Through theoretic analysis and emulation testing, if the ID of label is 16, the processing time can be reduced to original 50%.If the ID of label is 64, the processing time can be reduced to original 18.75%.
● energy efficient.We compare the accurate counting method of existing tree type with the accurate counting method of PAC.Through theoretic analysis and emulation testing, if the number of tags that is counted has 1,000, the processing time can be reduced to original 30%.If the number of tags that is counted has 10,000, the processing time can be reduced to original about 10%.
● the accurate counting method of PAC is a kind of method of counting of anonymity, and bigger using value is arranged in rfid system.
● the accurate counting method of PAC can detect the existence of redundant copy.
Embodiment
In the actual motion of agreement, the process of estimation is example with Fig. 1 fast, at first, and the rfid interrogator radio request signal.And the answer that begins to monitor label.Layout when the ALOHA time frame of monitoring comprises 7.Label receives after the request that adopt following method to come the select time lattice to answer: each label all uses same geometric distributions hash function H.The character of H is: if the overall situation has 2
LIndividual different ID (identity number) then has 2
L-1Layout when individual meeting is mapped to the 1st; Have 2
L-2Layout when individual meeting is mapped to the 2nd; Have 2
L-tLayout when individual meeting is mapped to t.The ID that supposes certain label is i, and H (i)=t, and layout was answered read write line when then this label was chosen in t.
After monitoring end, read write line (or the coupled main frame) value of finding is 1 the highest bit, promptly the 4th.The total quantity of label is that available following formula is estimated:
The layout when method of this quick estimation only needs 7, and the result is rather desirable.
The multidimensional division is (divide-and-conquer) process of dividing and ruling as shown in Figure 2.By Fast estimation, read write line and main frame have not only obtained the estimated result of a number of labels, and the label total collection in also should the zone has been divided into some subclass.As: the time layout 0,1,2 all include the set of a unnecessary label.Main frame can be estimated the number of tags that each subclass comprises by following relational expression:
Individual label.
If
Greater than threshold value L (as the time layout 0), subclass S then
iNeed divide once more.Adopt the method that is similar to quick estimation again, this time division is referred to as the two dimension division.If the quantity survey (surveying) value of a certain subclass
Less than threshold value L (as the
time layout 1,2), then read write line and main frame are accurately counted the label in this subclass.As shown in Figure 3, when accurately counting, read write line generates and contains
The ALOHA frame of layout when (being 4 among the figure) is individual, and require subclass S
iIn label when selecting one at random layout answer.If only there is a label to answer in the some time layout, counter is from increasing one; If conflict has taken place the some time layout, then adopt tree type conflict solution (as the rightest lattice among the figure).
Form 1 provides the class C language false code of multidimensional splitting method.Form 2 provides the class C language false code of accurate counting.
(a)Kd-Splitting?algorithm?on?tags (b)Kd-Splitting?algorithm?on?the?reader
Form 1
ALOGRITHM:Couting() PROCEDURE while TRUE wait_for_messages(); if there is a probe message from a reader randomly select a slot k from[0. l-1]; transmit a message in time slot k; end if end while |
ALOGRITHM:Couting(S) INPUT the tag set S PROCEDURE broadcast a request to tags; for i=0 to l-1 wait_for_responses(); end for for i=0 to l-1 if time solt i has a single response counter++; else if time solt i is collision TreeSplit(s
i) end if end for
|
(a)counting?algorithm?on?tags (b)counting?algorithm?on?the?reader
Form 2
Last counter has just obtained the number of labels result of ultimate demand with the results added of each piece gained.