A method and system for random sampling of commercial labels based on multi-mode remainder coding

By adopting a commercial tag random sampling method based on multi-mode modulo coding, the problems of high communication overhead and long time delay in random tag selection in large-scale RFID systems are solved, realizing efficient and low-overhead random tag sampling and meeting diverse business needs.

CN122491313APending Publication Date: 2026-07-31HOHAI UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HOHAI UNIV
Filing Date
2026-05-09
Publication Date
2026-07-31

AI Technical Summary

Technical Problem

Existing RFID systems struggle to efficiently select a specified number of tags from a massive number of tags in large-scale commercial scenarios, resulting in high communication overhead, long processing times, and difficulty in achieving precise control over sample size, sampling bias, and system overhead.

Method used

A commercial tag random sampling method based on multi-mode remainder coding is adopted. By generating a multi-mode remainder code corresponding to each tag in the RFID system, the Select command sequence is generated using the multi-mode remainder code. This includes macro-combination optimization, hierarchical block adjustment and precise verification stages, so as to achieve efficient random selection of a specified number of tags.

Benefits of technology

It significantly reduces air interface communication overhead and sampling latency, supports partial on-site tag sets and approximate sampling modes, and realizes efficient and low-overhead random tag sampling in large-scale RFID systems, meeting the needs of warehouse sampling and batch operations.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122491313A_ABST
    Figure CN122491313A_ABST
Patent Text Reader

Abstract

This invention discloses a commercial tag random sampling method and system based on multimodal remainder coding. The method includes: creating a commercial RFID system consisting of a reader and a large number of tags, and defining the random tag sampling problem based on this model; designing a tag identification scheme based on multimodal remainder coding, generating a fixed-length binary code for each tag; and then, based on a given number of tags present and a target sampling number, using a hierarchical adaptive selection algorithm to generate a Select command sequence for selecting the target number of random tags, determining the set of tags to be sampled, thereby completing precise or approximate random sampling. This invention's method can quickly select a specified number of random tags in a large-scale commercial RFID system with minimal communication overhead, without pre-given a target tag set, supporting applications such as random sampling, batch configuration updates, and batch testing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of random tag sampling, and specifically to an efficient random tag sampling method and system based on modulo-remainder encoding for commercial RFID systems. Background Technology

[0002] RFID (Radio Frequency Identification) technology is a non-contact automatic identification technology. Its basic principle is to utilize the spatial coupling and energy transfer characteristics of radio frequency signals to identify target items attached to RFID tags and collect relevant information. Compared to traditional identification technologies, RFID has advantages such as passive sensing, non-line-of-sight operation, multi-target parallel reading, and high-speed identification. Therefore, it has been widely used in industries such as warehousing and inventory management, supply chain management, asset tracking, manufacturing, and retail management, and is gradually becoming an important infrastructure for intelligent management of goods.

[0003] In large-scale commercial RFID systems, the interaction between readers and massive numbers of tags is not only used for complete reading and inventory counting, but also for diverse needs such as sampling inspection, batch segmentation, and rotation testing. Taking warehousing and supply chain scenarios as an example, operators often only need to randomly select a portion of the known total quantity of items for quality inspection or sampling inventory, without caring which specific tags are selected. In another scenario, the system needs to perform configuration updates, energy consumption tests, or functional verifications on a huge number of tags in multiple rounds. Each round only needs to activate a roughly equal subset of tags, and after several rounds, all tags can be covered. This need to randomly select a batch of tags from the entire set and then perform operations on them essentially constitutes the random tag sampling problem.

[0004] Current system designs and instruction sets primarily revolve around full inventory checks or tag selection according to fixed rules. This makes it difficult to randomly select a specified number of tags from a massive dataset with minimal communication overhead, without pre-specifying specific tag IDs. For practical scenarios such as warehouse sampling and batch rotation testing, existing methods often require large-scale interactions over the air interface, resulting in communication costs and execution latency being strongly correlated with the total number of tags present. This makes it impossible to achieve precise control over sample size, sampling bias, and system overhead. In modern IoT environments that prioritize real-time performance, high efficiency, and privacy protection, there is an urgent need for a new protocol and method that can efficiently complete random tag sampling in commercial RFID systems while maintaining lightweight tag-end overhead. This would meet the diverse business needs for fast, low-overhead random operations. Summary of the Invention

[0005] Purpose of the invention: The technical problem to be solved by the present invention is to provide an efficient random tag sampling method and protocol for large-scale RFID systems, which addresses the shortcomings of the prior art. It can randomly select a specified number of tags from a massive number of tags with minimal communication overhead without the need to pre-specify tag IDs, thus meeting the application requirements of warehouse sampling and batch operations.

[0006] To solve the above-mentioned technical problems, the present invention adopts the following technical solution:

[0007] A commercial label random sampling method based on multimodal modulo coding includes the following steps:

[0008] Generation and RFID systems Each label corresponds to a one-to-one modulo modulo encoding, where the selected Modulus of two pairs of coprime numbers , making ,and , No. The multimodal remainder encoding of each label is determined by... remainder The corresponding binary strings are concatenated in order. ;

[0009] Based on the target sampling quantity The multi-modal modulo encoding is used to generate a Select command sequence. The generation process includes: a macro-combinatorial optimization stage, based on... Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command; in the hierarchical block adjustment stage, the intersection characteristics between modulus remainders are used to perform block-level adjustment on the deviation d generated in the macro-combination optimization stage. The block-level adjustment performs selection or removal operations on the tag block formed by the intersection of the tag sets corresponding to the remainders of at least two different moduli, and generates the corresponding append or remove Select command; in the precise verification stage, when the remaining deviation after block-level adjustment... When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the uniqueness information of the multi-modal modulo encoding to adjust the quantity equal to the specified value. Select or remove the tags;

[0010] The generated Select command sequence is sent sequentially to the tags, and an inventory command is sent to obtain a response from the tags that are selected.

[0011] Furthermore, in the macro-combination optimization stage, based on Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command specifically includes:

[0012] The optimization problem is modeled as The discrete search problem in 3D integer space aims to find the optimal combination of remainders. ,in Indicates from the modulus The number of remainders selected from the remainder space. The optimization objective is to minimize the global theoretical cost. This cost consists of two parts: the cost of choosing the remainder and the estimated adjustment cost.

[0013]

[0014] in, This represents the number of Select commands required for macro-level selection. The current combination is estimated based on the principle of inclusion-exclusion. The size of the union of the covered labels is calculated using the following formula:

[0015]

[0016] in, This represents the probability that any tag is not selected in the current combination; the probability that the tag is selected is... Multiply by the total number of tags That is, to obtain the expected value of the number of covered tags;

[0017] Traverse all possible Combination, selection smallest And prioritize the scheme with the smallest absolute value of adjustment in theory; determine Then, based on the modulus configuration, the corresponding specific set of remainders is determined, and a corresponding Select command mask parameter is generated for each selected remainder. For the first remainder... Modulus The starting offset of its corresponding coded segment in the tag user area is: ,in, The Action field of the first command is set to 0, and the subsequent commands are set to 1. These commands are then executed virtually to obtain the initially selected set of tags. Calculate the target value deviation This provides deviation input for subsequent stages.

[0018] Furthermore, in sampling scenarios targeting partially present tags, before the macro-level combination optimization phase begins, a quick inventory is conducted to obtain the current number of present tags. This is used as input in the macroscopic combinatorial optimization stage to calibrate the prediction model; the calibrated prediction model and its corresponding cost function for:

[0019]

[0020]

[0021] By minimizing The calculation yields an optimal combination of remainders that better reflects the current situation. .

[0022] Furthermore, in approximate sampling scenarios, a non-negativity tolerance parameter set by the user is introduced. In the macro-combinatorial optimization stage, the optimal remainder combination is solved according to the original process. Send the corresponding The Select command returns the actual number of selected items. Calculate the actual deviation and tolerance parameter Compare, if The algorithm terminates immediately, and the final sampling result is the one selected in the macroscopic combinatorial optimization stage. One label; if Then continue with the complete hierarchical block adjustment phase and precise verification phase until the number of samples equals the required number of samples. .

[0023] Furthermore, in the hierarchical block adjustment stage, the intersection property between modulus remainders is used to adjust the deviation d generated in the macroscopic combinatorial optimization stage at the block level, specifically including:

[0024] A block is introduced as an adjustment unit. A block is defined as the intersection of the tag sets corresponding to different modulo remainders, and its granularity is smaller than the tag set corresponding to a single remainder.

[0025] like If so, then a supplementary selection operation will be performed from the set of unselected tags; if If the selected label set is not found, a removal operation is performed; in each iteration, all feasible block operations are evaluated, and for each involved... For each candidate block of a label, calculate its estimated cost. Where 1 represents the cost of this operation. Indicates the remaining adjustment cost; iterative selection makes The minimal operation generates the corresponding mask parameters, which simultaneously constrain the encoding bits corresponding to multiple moduli. Different Action field values ​​are set for the complement and elimination operations. Subsequently, the bias is updated. The above process is repeated until the deviation is 0 or no better block operation can be found.

[0026] Furthermore, in the precise verification stage, when the remaining deviation after block-level adjustment... When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the unique information of the multi-modal modulo encoding, specifically including:

[0027] like Then, the exact selection will be made from the unselected tags. One, generate a mask where the Action field has the first value; if Then, it will be precisely removed from the selected tags. One, generate a mask where the Action field is the second value.

[0028] Furthermore, the generated Select command sequence is sent sequentially to the tags, and an inventory command is sent to obtain a response from the selected tags, specifically including:

[0029] Each Select command is sent sequentially to the air interface. After receiving the command, each tag reads the corresponding bit field of the multimodal modulo encoding from its own user storage area and compares it bit by bit with the command mask. When a match is found, the tag updates its own inventory flag to be selected or unselected according to the Action field. When a match is not found, the tag keeps the flag or sets it to unselected. After all Select commands have been executed, an inventory instruction is sent. Only tags with the inventory flag in the selected state participate in the reply.

[0030] A commercial tag random sampling system based on multimodal modulo coding, comprising:

[0031] The encoding generation module is used to generate codes for use in RFID systems. Each label corresponds to a one-to-one modulo modulo encoding, where the selected Modulus of two pairs of coprime numbers , making ,and , No. The multimodal remainder encoding of each label is determined by... remainder The corresponding binary strings are concatenated in order. ;

[0032] The Select command constructor is used to determine the target sampling quantity. The multi-modal modulo encoding is used to generate a Select command sequence. The generation process includes: a macro-combinatorial optimization stage, based on... Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command; in the hierarchical block adjustment stage, the intersection characteristics between modulus remainders are used to perform block-level adjustment on the deviation d generated in the macro-combination optimization stage. The block-level adjustment performs selection or removal operations on the tag block formed by the intersection of the tag sets corresponding to the remainders of at least two different moduli, and generates the corresponding append or remove Select command; in the fingerprint accurate verification stage, when the remaining deviation after block-level adjustment... When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the uniqueness information of the multi-modal modulo encoding to adjust the quantity equal to the specified value. Select or remove the tags;

[0033] The tag sampling module is used to send the generated Select command sequence to the tags in sequence, and send an inventory command to obtain the response of the tags in the selected state.

[0034] The present invention also provides an electronic device, comprising: one or more processors; a memory; and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, wherein when the programs are executed by the processors, they implement the steps of the commercial tag random sampling method based on multimodal modulo coding as described above.

[0035] The present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the commercial tag random sampling method based on multimodal modulo coding as described above.

[0036] Beneficial effects: (1) Based on multi-mode modulo coding and hierarchical adaptive selection algorithm, this invention can efficiently and randomly extract a specified number of tags from a large number of tags in the field without pre-specifying tag IDs. Compared with existing methods, this invention only requires a small number of Select commands to complete sampling, which significantly reduces air interface communication overhead and sampling delay; the tag side only performs fixed-length code comparison and flag bit update, which has low computational complexity and no additional hardware requirements for existing commercial passive RFID tags. (2) This invention supports both partial in-field tag set sampling and approximate sampling modes. It can adaptively adjust parameters according to the current in-field scale and accuracy requirements, and achieve a flexible trade-off between system overhead and sampling accuracy while ensuring that the sampling results are approximately uniform and random. Attached Figure Description

[0037] Figure 1 This is a flowchart of a commercial label random sampling method based on multimodal modulo coding.

[0038] Figure 2 This is a schematic diagram of random label selection based on multimodal modulo coding. Detailed Implementation

[0039] The present invention will be further explained below with reference to the accompanying drawings and specific embodiments.

[0040] This invention provides a commercial tag random sampling method based on multimodal modulo coding, comprising:

[0041] Generation and RFID systems Each label corresponds to a one-to-one modulo modulo encoding, where the selected Modulus of two pairs of coprime numbers , making ,and , No. The multimodal remainder encoding of each label is determined by... remainder The corresponding binary strings are concatenated in order. ;

[0042] Based on the target sampling quantity The multi-modal modulo encoding is used to generate a Select command sequence. The generation process includes: a macro-combinatorial optimization stage, based on... Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command; in the hierarchical block adjustment stage, the intersection characteristics between modulus remainders are used to perform block-level adjustment on the deviation d generated in the macro-combination optimization stage. The block-level adjustment performs selection or removal operations on the tag block formed by the intersection of the tag sets corresponding to the remainders of at least two different moduli, and generates the corresponding append or remove Select command; in the precise verification stage, when the remaining deviation after block-level adjustment... When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the uniqueness information of the multi-modal modulo encoding to adjust the quantity equal to the specified value. Select or remove the tags;

[0043] The generated Select command sequence is sent sequentially to the tags, and an inventory command is sent to obtain a response from the tags that are selected.

[0044] This invention designs a multi-modal modulo encoding for tags. By searching and generating a set of Select command sequences with the minimum communication cost, the execution of this sequence can accurately cover the specified values. The proposed random sampling method requires no additional complex computation on the tag side. Each tag only needs to store a fixed-length multimodal modulo code in its user memory. After receiving the Select command, it performs an equality comparison with the command mask and bit matching operations to update the inventory flag bit.

[0045] In one specific embodiment, the method of the present invention is described in detail from the entire process of system modeling, problem definition, and solution, referring to... Figure 1 The method includes the following steps:

[0046] Step 1: Create a commercial RFID system consisting of a reader and a large number of tags. Each tag has a unique tag ID to identify its associated object. The reader communicates with the tags via an air interface and connects to the backend server via a wired link. The server is responsible for parameter calculation, multi-modal modulo encoding construction, and execution of the hierarchical adaptive selection algorithm. The reader is responsible for issuing air interface commands such as Select and Query and receiving tag responses. The current system tag set is represented as follows: ,in This represents the total number of labels, and the target sampling label count is expressed as... ;

[0047] Step 2: Based on the commercial RFID system created in Step 1, the random tag sampling problem is defined as: given the current system tag set... and target sampling quantity Without specifying any particular tag ID, randomly select from the system One tag;

[0048] Step 3: Based on the random label sampling problem defined in Step 2, design a label identification scheme based on multimodal modulo coding to generate a globally unique multimodal modulo code for each label in the system.

[0049] According to an embodiment of the present invention, step 3 specifically includes the following steps:

[0050] Step 3-1: Given the total number of tags in the system ,choose ( ) moduli that are pairwise coprime And ensure that their product satisfies ;

[0051] Step 3-2: For the first in the system Each label has a modulo-modulo encoding determined by the following: The binary strings corresponding to the remainders are concatenated in order:

[0052]

[0053] Next, with Figure 2 Taking this as an example, we will further illustrate the design principle of multimodal modulo coding. Figure 2 In the system, the total number of tags Select the number of modulo values And using two coprime moduli ,satisfy The encoding requirements. For any tag Its encoding is composed of two parts, namely binary representation and The binary representation of . Therefore, the total encoding length required for each tag is . Bits. The first 3 bits are stored... The last two bits are used to store the value. The value. (Using the label) For example, its corresponding remainder pair is Converting these to binary yields 010 and 00 respectively. Therefore, the label... The complete multimodal modulo encoding is 01000.

[0054] Step 4: Using the multimodal modulo encoding of the tags from Step 3, search for and generate a set of Select command sequences with the lowest communication cost, so that the execution of this sequence can accurately cover the specified commands. Target labels.

[0055] This invention provides a hierarchical adaptive selection algorithm, comprising three stages: macroscopic combination, block adjustment, and final precise single-label verification. According to an embodiment of this invention, step 4 specifically includes the following steps:

[0056] Step 4-1: Phase 1: Macro-level combinatorial optimization. Based on the probability prediction model, combinatorial optimization is performed in the modulus remainder space to approximate the target sample size with the minimum theoretical overhead. ;

[0057] Specifically, it includes:

[0058] Step 4-1-1: Model the optimization problem as The discrete search problem in 3D integer space aims to find the optimal combination of remainders. ,in ( ) indicates from the modulus The number of remainders selected from the remainder space. The optimization objective is to minimize the global theoretical cost. The cost consists of two parts: the remainder selection cost and the estimated adjustment cost.

[0059]

[0060] in, This represents the number of Select commands required for macro-level selection. The current combination is estimated based on the principle of inclusion-exclusion. The size of the union of the covered labels is calculated using the following formula:

[0061]

[0062] in, This represents the probability that any tag is not selected in the current combination; the probability that the tag is selected is... Multiply by the total number of tags This gives the expected number of covered tags.

[0063] Step 4-1-2: Iterate through all possible... Combination, selection smallest And prioritize the option that theoretically has the smallest absolute value of adjustment. Then, in each modular dimension Randomly select from the remainder space For each specific remainder, the corresponding set of remainders is represented as: Then, for each selected remainder, a corresponding Select command parameter is generated. Target: Specifies the session to be operated on by this Select command. Action: There are 8 actions, each defining how the inventory flags should change for matching and non-matching tags. MemBank: Selects the tag's memory area, extracts data from it, and compares it with the Mask. Pointer: Specifies from which bit in the tag's memory to start the matching. Length: Specifies the number of bits involved in the matching. Mask: Specifies the target bit string used for comparison with the tag's memory content. Specifically, for the... Modulus The starting offset of its corresponding coded segment in the tag user area is: ,in, Therefore, for each selected remainder The corresponding Select command can be represented as:

[0064]

[0065] This invention fixes the value of Target to 2, indicating that tag state control is performed under the S2 session, and fixes the value of MemBank to 3, indicating that the Select command operates in the tag user area. The aforementioned Select command will select from the tag user area's... Starting from the digit, the comparison length is... Does the binary substring have a remainder of the mask value? The binary bit string is matched. For the first command, let the value of Action be... Set the matching tag to A and the non-matching tag to B; subsequent commands use an incremental approach to set the value of Action. The newly matched tags are added to the selected set, while the already selected tags remain unchanged. Subsequently, these commands are virtually executed on the server side to obtain the initially selected tag set. And calculate the difference between this value and the target value. deviation This provides accurate input for subsequent stages.

[0066] Step 4-2: Stage Two: Layered Block Adjustment, using the intersection characteristics between modulus remainders to quickly correct the deviation d generated in the macro-combinatorial optimization stage;

[0067] Specifically, it includes:

[0068] Step 4-2-1: Introduce "blocks" as adjustment units. A block is defined as the intersection of the tag sets corresponding to different modulo remainders, and its granularity is smaller than the tag set corresponding to a single remainder.

[0069] Step 4-2-2: Iterative fine-tuning based on a greedy strategy: If Perform a supplementary selection operation from the set of unselected tags; if If the selected tag set is not found, a removal operation is performed. In each iteration, all feasible block operations are evaluated. This invention only considers the intersection of consecutive modulo remainders to ensure the continuity of the mask in the tag memory. Specifically, consecutive modulo remainders refer to the bits corresponding to the selected remainders in the encoding being physically consecutive in the tag memory, and the intersection of the corresponding consecutive modulo remainders refers to the set of tags covered by the consecutive modulo remainder encoding. For each involved... For each candidate block of a label, calculate its estimated cost. Where 1 represents the cost of this operation. This represents the remaining adjustment cost. Iterative selection makes... The minimal operation generates the corresponding mask parameters, which simultaneously constrain the coding bits corresponding to multiple moduli. If it's a complement operation, Action is set to 1; if it's a rejection operation, Action is set to 5. Then, the bias is updated. The above process is repeated until the deviation is 0 or no better block operation can be found.

[0070] Step 4-3: Phase Three: Single-Label Accurate Verification, when the remaining deviation When the granularity is smaller than the minimum block size, layered block adjustment cannot further eliminate the remaining minute deviations, and the process enters the final precision calibration stage. Regarding the remaining deviations... The algorithm utilizes the uniqueness of multi-modal modulo encoding to perform point-to-point operations. If Then, the exact selection will be made from the unselected tags. Generate a mask with Action = 1. If Then, it will be precisely removed from the selected tags. Generate a mask with Action = 5.

[0071] The following is based on Figure 2 shown Taking the dual-modulus model as an example, this paper elaborates on the complete execution flow of the hierarchical adaptive selection algorithm. Scenario 1: This invention considers the target sample... In this scenario, the hierarchical adaptive selection algorithm first initiates its theoretical optimization engine to find the optimal remainder combination. To minimize global theoretical cost

[0072]

[0073] in Calculations show that the selected combination... At this point, the theoretical cost is minimized:

[0074]

[0075] At this point, only two Select commands are needed and the theoretical deviation is 0, so the algorithm directly executes this scheme. Next, the algorithm starts from the modulus... remainder set Random selection For example, if the remainder is 1, which corresponds to binary 001, the mask parameter is... At the same time, from the modulus remainder set Random selection The reader selects a remainder, for example, a remainder of 0, which corresponds to binary 00. Therefore, the reader sends the following two Select commands in sequence:

[0076]

[0077]

[0078] After sending, all tags that satisfy the condition that the first three bits are 001 ( The inventory label for the item marked 'A' is set to 'A', and the inventory labels for the remaining items are set to 'B'. Next... All tags that satisfy the condition that the 4th and 5th bits are 00 ( The inventory marker for ) is also set to A. Ultimately, the union of these two sets of labels is selected, totaling... 8 tags, related to the actual goal Completely consistent, deviation Therefore, in this scenario, the hierarchical adaptive selection algorithm completes sampling only in stage one, without the need for subsequent adjustments.

[0079] Scenario 2, the present invention considers when In complex scenarios, the hierarchical adaptive selection algorithm runs the optimization process again, and the optimal combination is still... The corresponding theoretical cost is

[0080]

[0081] This result indicates that the task can be completed with two selection operations and one adjustment operation. In phase one, the algorithm randomly selects... If the remainders are the same in Scenario 1, the reader sends two Select commands. and Selecting the union of the labels corresponding to these two sets of remainders actually selects 8 labels, resulting in a discrepancy. Since the deviation is not zero, the algorithm enters phase two. In phase two, the algorithm needs to remove one label from the eight selected labels to achieve the final goal of 7. The algorithm searches for the most efficient adjustment strategy and finally locks the label. As the target to be eliminated, its full multimodal modulo encoding is 00100. Based on this, the reader generates and sends a Select command with Action 5:

[0082]

[0083] This command is only used with A perfect match was achieved, and its inventory marker was flipped from A to B, successfully removing it from the selected set. The remaining 7 selected tags remained unchanged due to a mismatch. At this point, the final number of selected tags became 7, consistent with the target, with a deviation of [missing information]. The reader then sends a query command to read these tags to complete the sampling task, without needing to proceed to stage three. The entire process takes a total of [time period missing]. The Select command is consistent with the theoretically optimal cost of Phase 1.

[0084] Step 4-4: In the sampling scenario targeting partially present tags, before the start of phase one, a quick inventory can be conducted to obtain the current number of present tags. This is then used as input to calibrate the prediction model. The calibrated prediction model... and its corresponding cost function for:

[0085]

[0086]

[0087] By minimizing The algorithm can calculate an optimal remainder combination that better reflects the current situation. Once Phase One is completed, the execution process for Phases Two and Three will not require any changes.

[0088] Steps 4-5: In approximate sampling scenarios, if the actual deviation generated after the end of stage one is within the user's acceptable range, then skip the subsequent adjustment stage directly;

[0089] Specifically, it includes:

[0090] Step 4-5-1: Introduce a user-defined non-negativity tolerance parameter. Depending on the specific application requirements, It can be defined in two ways: absolute deviation tolerance. Requirement for the final number of samples satisfy Relative deviation tolerance Requirement for the final number of samples satisfy ;

[0091] Step 4-5-2: For stage one, the algorithm solves for the optimal remainder combination according to the original process. Send the corresponding The Select command returns the actual number of selected items. Calculate the actual deviation. and according to or Calculated tolerance threshold Compare. If If the deviation is deemed acceptable, the algorithm terminates immediately, and stages two and three are not executed. The final sampling result is the one selected in stage one. A tag. If Then continue with the complete Phase Two and Phase Three processes, making precise adjustments until the number of samples equals... This mechanism ensures that the deviation of the final result will never exceed the preset range.

[0092] Step 5: The reader selects and inventories tags according to the Select command sequence generated by the hierarchical adaptive selection algorithm and subsequent Query-type instructions. The reader sends each Select command sequentially to the air interface. After receiving the command, each tag reads the corresponding bit field of the multimodal modulo encoding from its own user storage area and compares it bit by bit with the command mask; if a match is found, it updates its own inventory flag to selected or unselected according to the Action field; if a mismatch is found, it keeps or sets it to unselected. After all Select commands have been executed, the reader sends an inventory instruction, and only tags with the inventory flag in the selected state participate in the response.

[0093] It should be noted that the methods and steps described above are merely illustrative and do not constitute a strict limitation of the present invention. Those skilled in the art should understand that the order of the above steps can be adjusted without departing from the core idea of ​​the present invention; for example, some steps can be executed in parallel, their execution order exchanged, or they can be combined, or some steps can be omitted depending on the actual situation. Furthermore, the stages described in this invention are not necessarily executed sequentially as described above; they can be flexibly arranged according to the system environment, application scenario, or user needs during specific implementation.

[0094] Based on the same technical concept, the present invention also provides a commercial tag random sampling system based on multimodal modulo coding, comprising:

[0095] The encoding generation module is used to generate codes for use in RFID systems. Each label corresponds to a one-to-one modulo modulo encoding, where the selected Modulus of two pairs of coprime numbers , making ,and , No. The multimodal remainder encoding of each label is determined by... remainder The corresponding binary strings are concatenated in order. ;

[0096] The Select command constructor is used to determine the target sampling quantity. The multi-modal modulo encoding is used to generate a Select command sequence. The generation process includes: a macro-combinatorial optimization stage, based on... Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command; in the hierarchical block adjustment stage, the intersection characteristics between modulus remainders are used to perform block-level adjustment on the deviation d generated in the macro-combination optimization stage. The block-level adjustment performs selection or removal operations on the tag block formed by the intersection of the tag sets corresponding to the remainders of at least two different moduli, and generates the corresponding append or remove Select command; in the fingerprint accurate verification stage, when the remaining deviation after block-level adjustment... When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the uniqueness information of the multi-modal modulo encoding to adjust the quantity equal to the specified value. Select or remove the tags;

[0097] The tag sampling module is used to send the generated Select command sequence to the tags in sequence, and send an inventory command to obtain the response of the tags in the selected state.

[0098] The present invention also provides an electronic device, comprising: one or more processors; a memory; and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, wherein when the programs are executed by the processors, they implement the steps of the commercial tag random sampling method based on multimodal modulo coding as described above.

[0099] The present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the commercial tag random sampling method based on multimodal modulo coding as described above.

[0100] This invention provides a commercial tag random sampling method and system based on multimodal modulo coding. Many methods and approaches exist for implementing this technical solution; the above description is merely a preferred embodiment of the invention. It should be noted that those skilled in the art can make various improvements and modifications without departing from the principles of this invention, and these improvements and modifications should also be considered within the scope of protection of this invention. All components not explicitly stated in this embodiment can be implemented using existing technologies.

Claims

1. A method for random sampling of commercial labels based on multi-mode remainder coding, characterized in that, The method includes: Generating a multi-modulus residue code corresponding to each tag in an RFID system wherein two-by-two co-prime moduli are selected such that , and the multi-modulus residue code of the th tag is formed by concatenating residues corresponding binary strings in order, ; Based on the target sampling quantity The multi-modal modulo encoding is used to generate a Select command sequence. The generation process includes: a macro-combinatorial optimization stage, based on... Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command; in the hierarchical block adjustment stage, the intersection characteristics between modulus remainders are used to perform block-level adjustment on the deviation d generated in the macro-combination optimization stage. The block-level adjustment performs selection or removal operations on the tag block formed by the intersection of the tag sets corresponding to the remainders of at least two different moduli, and generates the corresponding append or remove Select command; in the precise verification stage, when the remaining deviation after block-level adjustment... When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the uniqueness information of the multi-modal modulo encoding to adjust the quantity equal to the specified value. Select or remove the tags; The generated Select command sequence is sent sequentially to the tags, and an inventory command is sent to obtain a response from the tags that are selected.

2. The method according to claim 1, characterized in that, In the macro-combinatorial optimization stage, based on Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command specifically includes: The optimization problem is modeled as The discrete search problem in 3D integer space aims to find the optimal combination of remainders. ,in Indicates from the modulus The number of remainders selected from the remainder space. The optimization objective is to minimize the global theoretical cost. This cost consists of two parts: the cost of choosing the remainder and the estimated adjustment cost. in, This represents the number of Select commands required for macro-level selection. The current combination is estimated based on the principle of inclusion-exclusion. The size of the union of the covered labels is calculated using the following formula: in, This represents the probability that any tag is not selected in the current combination; the probability that the tag is selected is... Multiply by the total number of tags That is, to obtain the expected value of the number of covered tags; Traverse all possible Combination, selection smallest And prioritize the scheme with the smallest absolute value of adjustment in theory; determine Then, based on the modulus configuration, the corresponding specific set of remainders is determined, and a corresponding Select command mask parameter is generated for each selected remainder. For the first remainder... Modulus The starting offset of its corresponding coded segment in the tag user area is: ,in, The Action field of the first command is set to 0, and the subsequent commands are set to 1. These commands are then executed virtually to obtain the initially selected set of tags. Calculate the target value deviation This provides deviation input for subsequent stages.

3. The method according to claim 2, characterized in that, In sampling scenarios targeting a subset of present tags, a quick inventory is conducted to determine the current number of present tags before the macro-level combination optimization phase begins. This is used as input in the macroscopic combinatorial optimization stage to calibrate the prediction model; the calibrated prediction model and its corresponding cost function for: By minimizing The calculation yields an optimal combination of remainders that better reflects the current situation. .

4. The method according to claim 2, characterized in that, In approximate sampling scenarios, a non-negativity tolerance parameter set by the user is introduced. In the macro-combinatorial optimization stage, the optimal remainder combination is solved according to the original process. Send the corresponding The Select command returns the actual number of selected items. Calculate the actual deviation and tolerance parameter Compare, if The algorithm terminates immediately, and the final sampling result is the one selected in the macroscopic combinatorial optimization stage. One label; if Then continue with the complete hierarchical block adjustment phase and precise verification phase until the number of samples equals the required number of samples. .

5. The method according to claim 1, characterized in that, In the hierarchical block adjustment stage, the intersection property between modulus remainders is used to adjust the deviation d generated in the macroscopic combinatorial optimization stage at the block level, specifically including: A block is introduced as an adjustment unit. A block is defined as the intersection of the tag sets corresponding to different modulo remainders, and its granularity is smaller than the tag set corresponding to a single remainder. like If so, then a supplementary selection operation will be performed from the set of unselected tags; if If the selected label set is not found, a removal operation is performed; in each iteration, all feasible block operations are evaluated, and for each involved... For each candidate block of a label, calculate its estimated cost. Where 1 represents the cost of this operation. Indicates the remaining adjustment cost; iterative selection makes The minimal operation generates the corresponding mask parameters, which simultaneously constrain the encoding bits corresponding to multiple moduli. Different Action field values ​​are set for the complement and elimination operations. Subsequently, the bias is updated. The above process is repeated until the deviation is 0 or no better block operation can be found.

6. The method according to claim 1, characterized in that, During the precise verification phase, when the remaining deviation after block-level adjustment When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the unique information of the multi-modal modulo encoding, specifically including: like Then, the exact selection will be made from the unselected tags. One, generate a mask where the Action field has the first value; if Then, it will be precisely removed from the selected tags. One, generate a mask where the Action field is the second value.

7. The method according to claim 1, characterized in that, The generated Select command sequence is sent sequentially to the tags, and an inventory command is sent to obtain a response from the selected tags. Specifically, this includes: Each Select command is sent sequentially to the air interface. After receiving the command, each tag reads the corresponding bit field of the multimodal modulo encoding from its own user storage area and compares it bit by bit with the command mask. When a match is found, the tag updates its own inventory flag to selected or unselected according to the Action field. When a match is not found, the tag keeps the flag or sets it to unselected. After all Select commands have been executed, an inventory instruction is sent. Only tags with the inventory flag in the selected state participate in the reply.

8. A commercial tag random sampling system based on multimodal modulo coding, characterized in that, include: The encoding generation module is used to generate codes for use in RFID systems. Each label corresponds to a one-to-one modulo modulo encoding, where the selected Modulus of two pairs of coprime numbers , making ,and , No. The multimodal remainder encoding of each label is determined by... remainder The corresponding binary strings are concatenated in order. ; The Select command constructor is used to determine the target sampling quantity. The multi-modal modulo encoding is used to generate a Select command sequence. The generation process includes: a macro-combinatorial optimization stage, based on... Optimize the modulus by combining remainders to generate a coverage number that approximates the target sampling number. The initial Select command; in the hierarchical block adjustment stage, the intersection characteristics between modulus remainders are used to perform block-level adjustment on the deviation d generated in the macro-combination optimization stage. The block-level adjustment performs selection or removal operations on the tag block formed by the intersection of the tag sets corresponding to the remainders of at least two different moduli, and generates the corresponding append or remove Select command; in the fingerprint accurate verification stage, when the remaining deviation after block-level adjustment... When the absolute value is not zero and is less than the preset block granularity, a precise adjustment Select command is generated based on the uniqueness information of the multi-modal modulo encoding to adjust the quantity equal to the specified value. Select or remove the tags; The tag sampling module is used to send the generated Select command sequence to the tags in sequence, and send an inventory command to obtain the response of the tags in the selected state.

9. An electronic device, characterized in that, include: One or more processors; Memory; And one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, wherein when the programs are executed by the processors, they implement the steps of the commercial tag random sampling method based on multimodal modulo coding as described in any one of claims 1-7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the commercial tag random sampling method based on multimodal modulo coding as described in any one of claims 1-7.