A method for determining modular inverse element, chip, terminal and storage medium
By adopting the method of looking up tables and iterative in the communication system, only part of the modular inverse elements is pre-stored, which solves the problems of large storage resource occupation and low computing efficiency in the modular inverse element calculation, and improves the processing performance of the communication chip.
Patent Information
- Application Number
- CN202210792485.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-05
- Publication Date
- 2025-05-23
- Estimated Expiration
- 2042-07-05
AI Technical Summary
The prior art has problems such as excessive storage resource usage and low computing efficiency in modular inverse calculations, especially in communication systems, which are difficult to achieve improvement in processing performance.
The modular inverse elements of the sequence number are determined by checking tables and iterating. Only the modular inverse elements of the sequence number are pre-stored, and the modular inverse elements of other sequence numbers are iteratively obtained by pre-stored modular inverse elements.
The pre-memory inverse elements consumes storage resources, while improving the computing efficiency of non-memory inverse elements, significantly improving the overall processing performance of communication chips.
Smart Images

Figure CN115208420B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to but is not limited to the field of wireless communications, and specifically to a method for determining a modular inverse element, a communication chip, a mobile terminal, and a storage medium. Background Art
[0002] In number theory, for any element a of a group G, there is a unique element b in G that satisfies a×b=b×a=e, where e is the identity element of the group. Then the element b is called the multiplicative inverse of the element a, denoted by a -1 In modular arithmetic (modulo p, where p is an integer greater than 0), the identity element is 1, and the multiplicative inverse of a positive integer a is the smallest positive integer b that satisfies a·b≡1(mod p). The multiplicative inverse of modular arithmetic is also often called modular inverse. The calculation of modular inverse is widely used in fields such as cryptography and digital communications.
[0003] Continuously improving the modular inverse element calculation method and the related modular inverse element determination scheme are very important links for effectively improving the processing performance of communication systems. Summary of the invention
[0004] The disclosed embodiments provide a method for determining a modular inverse element, a communication chip, a mobile terminal, and a storage medium, which determine the modular inverse element of a sequence number used for transmitter preamble sequence generation by table lookup or iteration based on the modular inverse element of a part of the sequence number calculated and stored in advance. The modular inverse element of the sequence number is determined by table lookup combined with iteration, which not only reduces the occupation of storage resources by pre-stored modular inverse elements, but also takes into account the improvement of the calculation efficiency of non-stored modular inverse elements.
[0005] The present disclosure provides a method for determining a modular inverse element, including:
[0006] Calculating a lookup table address according to a logical index number and a sequence length for generating a transmitter preamble sequence, wherein the lookup table addresses corresponding to a plurality of logical index numbers are the same;
[0007] Obtaining an initial modular inverse element based on a search result of the lookup table address in a modular inverse element storage table;
[0008] According to the logical index number, the initial modular inverse element and the sequence length, a target modular inverse element corresponding to the logical index number is determined.
[0009] An embodiment of the present disclosure further provides a communication chip, comprising a processor, wherein the processor is configured to execute the modular inverse element determination method as described in any embodiment of the present disclosure.
[0010] An embodiment of the present disclosure further provides a mobile terminal, comprising a communication chip, wherein the communication chip is configured to execute the modular inverse element determination method as described in any embodiment of the present disclosure.
[0011] An embodiment of the present disclosure further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the modular inverse element determination method described in any embodiment of the present disclosure.
[0012] The modular inverse element determination scheme provided in the embodiment of the present disclosure only pre-stores the modular inverse elements of a part of the serial numbers used for generating the transmitter preamble sequence, while the modular inverse elements of other serial numbers are obtained through an iterative method based on the pre-stored modular inverse elements. This not only reduces the storage space occupied by the pre-stored modular inverse elements, but also moderately reduces the complexity of iterative operations, and can significantly improve the overall processing performance of the communication chip.
[0013] Other aspects will be apparent upon reading and understanding the drawings and detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the solutions of the present application. For ordinary technicians in this field, other drawings can be obtained based on the structures shown in these drawings without paying any creative work.
[0015] Figure 1 A schematic diagram of the transceiver function module of the PRACH channel in an implementable solution;
[0016] Figure 2 A flow chart of a method for determining a modular inverse element in an embodiment of the present disclosure;
[0017] Figure 3 This is a flow chart of another method for determining a modular inverse element in an embodiment of the present disclosure;
[0018] Figure 4 This is a flow chart of another method for determining a modular inverse element in an embodiment of the present disclosure;
[0019] Figure 5 This is a flow chart of another method for determining a modular inverse element in an embodiment of the present disclosure;
[0020] Figure 6 This is a flow chart of another method for determining a modular inverse element in an embodiment of the present disclosure;
[0021] Figure 7 This is a flow chart of another method for determining a modular inverse element in an embodiment of the present disclosure;
[0022] Figure 8 This is a flow chart of another method for determining a modular inverse element in an embodiment of the present disclosure.
[0023] The realization of the purpose, functional features and advantages of the present application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0024] The following will be combined with the drawings in the embodiments of the present disclosure to clearly and completely describe the technical solutions in the embodiments of the present disclosure. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0025] It should be noted that all directional indications in the embodiments of the present disclosure (such as up, down, left, right, front, back, etc.) are only used to explain the relative position relationship, movement status, etc. between the components under a certain specific posture (as shown in the accompanying drawings). If the specific posture changes, the directional indication will also change accordingly.
[0026] In addition, in the present disclosure, the descriptions of "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying their relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" or "second" may explicitly or implicitly include at least one of the features. In the description of the present disclosure, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0027] In the present disclosure, unless otherwise clearly specified and limited, the terms "connection", "fixation", etc. should be understood in a broad sense. For example, "fixation" can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements, unless otherwise clearly defined. For ordinary technicians in this field, the specific meanings of the above terms in the present application scheme can be understood according to specific circumstances.
[0028] In addition, the technical solutions between the various embodiments of the present disclosure can be combined with each other, but it must be based on the fact that ordinary technicians in the field can implement it. When the combination of technical solutions is contradictory or cannot be implemented, it should be deemed that such combination of technical solutions does not exist and is not within the scope of protection required by this application.
[0029] Before describing the specific embodiments, the abbreviations of the relevant terms involved in the present disclosure are explained as follows:
[0030]
[0031]
[0032] In the field of wireless communication technology, the process of sending and receiving signals between a transmitter and a receiver, such as Figure 1 As shown, the preamble generation module of the transmitter generates the preamble sequence, which is processed by the DFT module, subcarrier mapping module, IFFT module, signal repetition and cyclic prefix insertion module, and then sent to the receiver through the transmitter's RF module; the receiver performs the inverse process to complete the reception of the preamble sequence code. Among them, in the transmitter preamble generation module, the time domain sequence generation formula is:
[0033] x u,v (n) = x u ((n+C v )mod L RA )
[0034]
[0035] Where, L RA Indicates the sequence length, which is determined by the leading sequence format, u is the sequence number, v is the cyclic shift number, C v is the circular shift value corresponding to v.
[0036] After passing through the DFT module, it becomes the frequency domain form:
[0037]
[0038] The above formula includes time domain sequence generation and DFT operation, which has high computational complexity. According to the properties of ZC sequence, time domain sequence generation and DFT operation can be combined, and the calculation formula can be simplified to:
[0039]
[0040]
[0041] Among them, u -1 is the modular inverse of the sequence number u, that is, satisfies uu -1 ≡1(mod L RA ).
[0042] It can be seen that the simplified formula avoids the high complexity of DFT calculation, but it is necessary to calculate the modular inverse of the sequence number u. The sequence number u is determined by the logical index number i, and the logical index number i is obtained according to the upper layer configuration parameters. Therefore, the problem is reduced to calculating the modular inverse of the corresponding sequence number u according to the logical index number i, also called the modular inverse of the logical index number i, or the target modular inverse of the logical index number i.
[0043] Taking the 5G system as an example, the relationship between the logical index number i and the sequence number u is defined by the 5G standard. For example, the sequence length L RA =139, the mapping relationship between the logical index number i and the sequence number u is shown in Table 1.
[0044] Table 1 Mapping relationship table between logical index number i and sequence number u (L RA =139)
[0045]
[0046] For example, the sequence length L RA =839, the mapping relationship between the logical index number i and the sequence number u (excerpt) is shown in Table 2.
[0047] Table 2 Mapping relationship table of logical index number i and sequence number u (excerpt) (L RA =839)
[0048]
[0049] Some feasible methods for determining modular inverse elements mainly include direct calculation method and table lookup method.
[0050] Direct calculation methods mainly include modular exponentiation algorithm, extended Euclidean algorithm, binary right shift algorithm, binary left shift algorithm and binary extended Euclidean algorithm. The modular exponentiation algorithm is based on Fermat's little theorem and converts modular inverse operations into modular exponentiation operations. It requires modular multiplication units, and the amount of calculation is large and relatively complex. The extended Euclidean algorithm calculates the greatest common factor through the Euclidean algorithm to solve the modular inverse element. It requires a divider and the implementation is also relatively complex. The binary right shift algorithm, binary left shift algorithm and binary extended Euclidean algorithm all convert the Euclidean algorithm or the Euclidean algorithm into simple shift operations and addition operations, which are very suitable for hardware circuit implementation, but the calculation process has a large number of loop iterations and a large calculation delay.
[0051] When the modulus is not too large, another method is to pre-calculate and store the modular inverses corresponding to all elements, and then directly obtain them by looking up the table when using them. This method is very efficient, but it requires a certain amount of storage resources. For example, the sequence length L RA =139, the required storage resource size is 138×8bit=1104bit. RA =839, the required storage resource size is 838×10bit=8380bit. RA =571, the required storage resource size is 570×10bit=5700bit. RA =1151, the required storage resource size is 1150×11bit=12650bit. A total of 27834 bits are required to store the modular inverse elements of the four sequence lengths.
[0052] It can be seen that the direct calculation method has more loop iterations, greater complexity, longer calculation time, and higher hardware power consumption. The method of pre-calculating and storing modular inverse elements has high calculation efficiency, but requires certain storage resources and increases hardware costs.
[0053] The disclosed embodiment provides a method for determining modular inverse elements, which adopts a storage table combined with calculation, and only pre-calculates and stores modular inverse elements of some elements. The modular inverse elements of other elements can be obtained through simple calculation based on the pre-stored modular inverse elements.
[0054] The present disclosure provides a method for determining a modular inverse element. Figure 2 As shown, including:
[0055] Step 210: generate a preamble sequence according to the logical index number i and the sequence length L RA Calculate and obtain a lookup table address m, wherein the lookup table address m corresponding to a plurality of logical index numbers i is the same;
[0056] Step 220, obtaining an initial modular inverse element based on the search result of the lookup table address m in the modular inverse element storage table;
[0057] Step 230: according to the logical index number i, the initial module inverse element and the sequence length L RA , determine the target modular inverse element corresponding to the logical index number.
[0058] It should be noted that the target module inverse element corresponding to the logical index number i in the embodiment of the present disclosure is the module inverse element to be used for generating the leading sequence, and the target module inverse element is the sequence number u corresponding to the logical index number i. i The modular inverse element; other modular inverse elements, such as the initial modular inverse element and the first modular inverse element are all modular inverse elements corresponding to the intermediate data involved in the relevant embodiment scheme of the present disclosure.
[0059] In some exemplary embodiments, the sequence length L RA The logical index number i is obtained through the upper layer configuration parameters.
[0060] It can be understood that in the present application, the lookup table addresses m corresponding to multiple logical index numbers i are the same, so the number of modular inverse elements in the modular inverse element storage table is less than the number of logical index numbers i, which is beneficial to reducing the storage resources occupied by the modular inverse element storage table.
[0061] Furthermore, in the present application, the lookup table addresses m corresponding to the multiple logical index numbers i are the same, that is, different logical index numbers i may correspond to the same initial modular inverse element. RAThe target modular inverse is calculated, so the multiple logical index numbers i corresponding to the same initial modular inverse can correspond to different target modular inverses. Therefore, although the number of modular inverses stored in the modular inverse storage table is reduced compared to the number of logical index numbers, combined with the subsequent calculation steps, the target modular inverse corresponding to each logical index number can still be obtained, that is, the modular inverse of the sequence number corresponding to each logical index number can be obtained.
[0062] It can be seen that the embodiment of the present disclosure provides a modular inverse element determination scheme, which adopts a storage table lookup combined with a calculation mode to determine the modular inverse element of the sequence number corresponding to the logical index number used to generate the transmitter preamble sequence, which effectively saves storage table space and improves computing efficiency.
[0063] For example, different sequence lengths L RA It can indicate different correspondences between the logical index number i and the lookup table address m, for example, in the sequence length L RA If the sequence length is within the first sequence length range, the logical index number i1 corresponds to the determined lookup table address m, denoted as m1. For example, if the sequence length is L RA When it is within the second sequence length range, the logical index number i1 corresponds to the determined lookup table address m, which is recorded as m2.
[0064] In some exemplary embodiments, the modular inverse element storage table includes a first modular inverse element storage table; accordingly, step 210 includes:
[0065] Step 2101, when the sequence length falls within the first sequence length range, determine the modular inverse element calculation sequence number u′ corresponding to the logic index number i according to the first sequence number generation algorithm;
[0066] Step 2102, determining the lookup table address in the first modular inverse element storage table corresponding to the modular inverse element calculation sequence number u′ according to the first table address generation algorithm;
[0067] The first sequence number generation algorithm is used to map one or more logical index numbers to the same modular inverse element calculation sequence number, and each modular inverse element calculation sequence number is within the sequence number range used for transmitter preamble sequence generation;
[0068] The first table address generation algorithm is used to map one or more modular inverse element calculation serial numbers to the same lookup table address, wherein the modular inverse element of the modular inverse element calculation serial number before mapping can be calculated based on the modular inverse element stored in the first modular inverse element storage table corresponding to each lookup table address.
[0069] It can be understood that when the sequence length falls within the range of the first sequence length, a convergence is performed according to the first sequence number generation algorithm, and one or more logical index numbers are mapped to the same modular inverse element calculation sequence number u′, and then one or more modular inverse element calculation sequence numbers are further mapped to the same lookup table address m according to the first table address generation algorithm. This can further converge the number of modular inverse elements stored in the first modular inverse element storage table, effectively reducing the system storage resources occupied by the first modular inverse element storage table.
[0070] Exemplarily, logical index numbers i1 and i2 are mapped to the same modular inverse element calculation sequence number u1′, logical index numbers i3 and i4 are mapped to the same modular inverse element calculation sequence number u2′, and modular inverse element calculation sequence numbers u1′ and u2′ are mapped to the same lookup table address m1. Then, steps 210-220 are executed, and the logical index numbers i1, i2, i3, and i4 can be searched based on the lookup table address m1 to obtain a search result, and further, the initial modular inverse element can be obtained based on the search result. In this example, the four logical index numbers only occupy one storage table record space. Depending on the first sequence number generation algorithm and / or the first table address generation algorithm, the specific convergence ratio is different.
[0071] It should be noted that the sequence number u used to generate the transmitter preamble sequence i Corresponding to the logical index number i, each logical index number i corresponds to a sequence number u i ,u i It can also be collectively referred to as serial number u. i It is a recording method adopted from the perspective corresponding to the logical index number i (for example, the mapping relationship reflected in Table 1 or Table 2), and u is a recording method adopted from the perspective of the overall solution. The modular inverse element calculation sequence number u′ recorded in the embodiments of the present disclosure is an intermediate quantity used to calculate the target modular inverse element in the embodiments of the present application, and the value of the modular inverse element calculation sequence number u′ is within the value range of the sequence number u; it can be understood that the modular inverse element calculation sequence number u′ corresponding to the logical index number i can be the same as or different from the sequence number u corresponding to the logical index number i defined in the relevant specifications.
[0072] Research has found that the modular inverse of a positive integer a under the modulo p operation is the smallest positive integer b that satisfies a·b≡1(mod p), denoted by a -1 This scheme mainly considers calculating the modular inverse of an integer a when p is an odd prime number, where the range of a is 1≤a≤p-1, and p is an integer greater than 0.
[0073] If the modular inverse of an integer a is known to be a -1 , that is, satisfying aa -1 ≡1(mod p), then according to the properties of modular operations, the modular inverse of an integer pa is equal to pa -1, verified as follows:
[0074] (pa)(pa -1 )mod p
[0075] =(p 2 -ap-a -1 p+aa -1 )mod p
[0076] =aa -1 mod p
[0077] =1
[0078] Therefore, if the range is known The modular inverses of all integers in the range The modular inverse element corresponding to the inner integer can be found by a single subtraction operation.
[0079] Furthermore, for the range Any integer within can be factored into an odd number and a power of 2, expressed as a = c 2 n In the form of , where c is an odd number and n is a non-negative integer. It is easy to see that the modular inverse of 2 is Thus, the modular inverse of a can be derived as:
[0080]
[0081] It can be seen that the modular inverse of a can be calculated by n iterations, where the initial value of the iteration is r 0 =c -1 , the result of the jth (1≤j≤n) iteration is
[0082]
[0083] When j-1 When is an even number,
[0084]
[0085] When j-1 When is an odd number,
[0086]
[0087] The iterative calculation formula is
[0088]
[0089] When n=0, that is, a=c is an odd number, the corresponding modular inverse element c can be stored in advance -1 , directly look up the table to find out. When n = 1, that is, a = 2c, look up the table to get c -1After one iteration through the above method, the result can be obtained. When n ≥ 2, the table is used to obtain c -1 After n iterations, the final modular inverse element a can be obtained. -1 =r b .
[0090] In order to reduce the number of iterations, when n ≥ 2, the merge iteration method can be used to merge two iterations into one. The merge iteration formula is as follows:
[0091]
[0092] After iterative merging, the number of iterations is reduced to This is about half the number of iterations required for a single step. Can be calculated So the maximum number of iterations is
[0093] When n is an even number, the final result can be obtained only through the merge iteration method; when n is an odd number, the final result can be obtained through the merge iteration and a single-step iteration.
[0094] It can be seen that if the modular inverse of all numbers in the range 1≤a≤p-1 is stored, the storage resource size is In this solution, only the pre-stored range is required. The modular inverse element corresponding to the odd number in the range occupies a storage resource size of bit, saving about 75% of storage resources.
[0095] In some exemplary embodiments, the method is applied in a 5G NR system, and the first sequence length range includes: sequence length L RA =139, L RA =571 or L RA =1151.
[0096] In some exemplary embodiments, the first sequence number generation algorithm is as follows:
[0097]
[0098] Among them, u′ is the modular inverse calculation sequence number, i is the logical index number, Express Round down.
[0099] It can be seen that according to the above-mentioned first sequence number generation algorithm, about 50% of the sequence numbers are converged, and the sequence numbers corresponding to 2n or 2n-1 logical index numbers are converged to n modular inverse element calculation sequence numbers. Optionally, other first sequence number generation algorithms can also be used to perform sequence number convergence, which is not limited to the aspects of the embodiments of the present disclosure.
[0100] In some exemplary embodiments, determining, according to a first table address generation algorithm, that the modular inverse element calculation sequence number u′ corresponds to the lookup table address m in the first modular inverse element storage table includes:
[0101] Determine, according to the first index generation algorithm, a modular inverse element search number c corresponding to the modular inverse element calculation sequence number u′;
[0102] According to the modular inverse element search number c, determine to search the modular inverse element c corresponding to the modular inverse element search number c in the first modular inverse element storage table -1 The lookup table address is the lookup table address;
[0103] The first index generation algorithm is used to map one or more modular inverse element calculation sequence numbers u′ to the same modular inverse element search number c, wherein the modular inverse element c of the same modular inverse element search number c is -1 The modular inverse element u′ before the mapping can be calculated. -1 .
[0104] It can be understood that the first table address generation algorithm realizes further convergence of the modular inverse element calculation sequence number based on the first index generation algorithm, and the first modular inverse element storage table stores the modular inverse element c corresponding to the modular inverse element search number c. -1 .
[0105] In some exemplary embodiments, the first index generation algorithm is as follows:
[0106] u′=c·2 n
[0107] Wherein, u′ is the modular inverse element calculation sequence number, c is the modular inverse element search number, c is an odd number, and n is an integer greater than or equal to 0.
[0108] It can be understood that according to the first index generation algorithm described above, when n is different, multiple modular inverse element calculation sequence numbers u′ can be mapped to the same modular inverse element search number c. According to the same modular inverse element search number c, the modular inverse element calculation sequence number u′ before mapping can be calculated. Accordingly, according to the modular inverse element c of the same modular inverse element search number c, -1 It is also possible to calculate the modular inverse element before mapping and calculate the modular inverse element u′ of the sequence number u′ -1 Optionally, other first index generation algorithms may be used to perform modular inverse element calculation sequence number convergence, which is not limited to the aspects of the embodiments of the present disclosure.
[0109] In some exemplary embodiments, according to the modular inverse element search number c, it is determined to search the first modular inverse element storage table for the modular inverse element c corresponding to the modular inverse element search number c. -1The lookup table address is the lookup table address, including:
[0110] The lookup table address m is determined according to the following algorithm:
[0111]
[0112] Among them, m is the lookup table address, and c is the modular inverse element lookup number.
[0113] In some exemplary embodiments, m in this embodiment is a lookup table address in the first modular inverse element storage table, also referred to as the first lookup table address. It can be seen that the first modular inverse element storage table stores a plurality of modular inverse element lookup numbers c and corresponding modular inverse elements c. -1 , c -1 The modular inverse element with the modular inverse element search number is called the modular inverse element. According to the determined lookup table address m, the modular inverse element c corresponding to the modular inverse element search number c can be obtained. -1 .
[0114] It should be noted that the specific storage method in the first modular inverse element storage table can be flexibly determined, and the corresponding relationship between the modular inverse element search number c and the lookup table address m can be flexibly determined. Accordingly, the specific scheme for determining the lookup table address m according to the modular inverse element search number c in the first modular inverse element storage table can also be determined accordingly, and is not limited to the aspects illustrated in the embodiments of the present disclosure.
[0115] In some exemplary embodiments, step 220 includes:
[0116] Step 2201, obtaining the modular inverse element stored corresponding to the address m in the lookup table from the first modular inverse element storage table as the first modular inverse element;
[0117] Step 2202: Based on the first modular inverse element, calculate and obtain the initial modular inverse element.
[0118] It can be understood that in the above embodiment, the first modular inverse element obtained from the first modular inverse element storage table according to the lookup table address m is the modular inverse element c corresponding to the modular inverse element lookup number c. -1 , which is the modular inverse element of the modular inverse element search number. When the sequence length falls within the first sequence length range, the initial modular inverse element calculated based on the first modular inverse element is the modular inverse element u′ corresponding to the modular inverse element calculation sequence number u′ -1 .
[0119] In some exemplary embodiments, the first index generation algorithm is as follows:
[0120] u′=c·2 n
[0121] Wherein, u′ is the modular inverse calculation sequence number, the modular inverse search number c is an odd number, and n is an integer greater than or equal to 0;
[0122] Accordingly, the calculating and obtaining the initial modular inverse element based on the first modular inverse element includes at least one of the following situations:
[0123] When n is equal to a first threshold, determining the first modular inverse element as the initial modular inverse element;
[0124] When n is greater than or equal to a second threshold, performing n single-step iterations according to the first modular inverse element to obtain the initial modular inverse element;
[0125] When n is greater than a second threshold and is an even number, performing merging and iteration according to the first modular inverse element to obtain the initial modular inverse element;
[0126] When n is greater than a second threshold and is an odd number, performing a merging iteration and a single-step iteration according to the first modular inverse element to obtain the initial modular inverse element;
[0127] The second threshold is greater than the first threshold.
[0128] In some exemplary embodiments, the first threshold is 0, the second threshold is 1, and the initial module inverse element u′ -1 Determined by the following method:
[0129]
[0130] in,
[0131]
[0132] r 0 =c -1 , c -1 is the first modular inverse, is the modular inverse corresponding to the modular inverse search number c, L RA is the sequence length;
[0133] It can be seen that in the above embodiment, when n=0, the first inverse modulus c is -1 is the initial module inverse u′ -1 ; When n = 1, perform one single-step iteration to obtain the initial modular inverse element u′ -1 ; When n is greater than 1, multiple single-step iterations are performed to obtain the initial modular inverse element u′ -1 .
[0134] In some exemplary embodiments, the first threshold is 0, the second threshold is 1, and the initial module inverse element u′ -1 Determined by the following method:
[0135] When n=0, that is, a=c is an odd number, u′ -1 =c -1 ;
[0136] When n=1, that is, a=2c is an even number, we can get c by looking up the table. -1 After a single-step iteration, we get u′ -1 , where: u′ -1 =r n ,
[0137]
[0138] r 0 =c -1 , c -1 is the first modular inverse, is the modular inverse corresponding to the modular inverse search number c, L RA is the sequence length;
[0139] When n>1, the merge iteration method is used to merge two iterations into one. The merge iteration formula is as follows:
[0140]
[0141] Among them, r 0 =c -1 , c -1 is the first modular inverse, is the modular inverse corresponding to the modular inverse search number c, L RA is the sequence length;
[0142] It can be seen that in the above embodiment, when n=0, the first inverse modulus c is -1 is the initial module inverse u′ -1 ; When n = 1, perform one single-step iteration to obtain the initial modular inverse element u′ -1 ; When n is greater than 1 and is an even number, perform a merge iteration to obtain the initial modular inverse element u′ -1 ; When n is greater than 1 and is an odd number, perform a combined iteration and a single-step iteration to obtain the initial modular inverse element u′ -1 .
[0143] In some exemplary embodiments, the first index generation algorithm is as follows:
[0144] u′=c·2 n
[0145] Wherein, u′ is the modular inverse element calculation sequence number, the modular inverse element search number c is an odd number, and n is an integer greater than or equal to 0;
[0146] The modular inverse element storage table includes a third modular inverse element storage table;
[0147] When n is greater than or equal to a third threshold, the method further includes:
[0148] Find the modular inverse element u′ corresponding to the modular inverse element calculation sequence number u′ from the third modular inverse element storage table -1 , as the initial modular inverse element.
[0149] In some exemplary embodiments, the third threshold is greater than the second threshold.
[0150] In some exemplary embodiments, the third threshold is a value greater than or equal to 3. For example, the third threshold is 3. In some exemplary embodiments, when n>=3, it is necessary to find the first modular inverse element storage table and iterate at least twice to find the initial modular inverse element. Considering that the number corresponding to n>=3 is relatively small, considering the overall computing performance, the modular inverse element u′ corresponding to the modular inverse element calculation sequence number u′ of n>=3 is calculated. -1 Stored in the third modular inverse element storage table, when n>=3, the corresponding modular inverse element is obtained as the initial modular inverse element by directly searching the third modular inverse element storage table without iterative calculation.
[0151] It can be seen that the third threshold value can also be set to other values as needed, and by searching the third modular inverse element storage table, the computational complexity caused by too many iterations can be reduced. In some exemplary embodiments, when some initial modular inverse elements are obtained by searching the third modular inverse element storage table, the lookup table address is the lookup table address of the stored modular inverse elements obtained from the third modular inverse element storage table. It can be seen that for the case where n>=the third threshold value, each modular inverse element calculation sequence number u′ is stored in the third modular inverse element storage table in a corresponding modular inverse element u′. -1 The correspondence between the lookup table address and the modular inverse element calculation sequence number u′ can be determined according to the correspondence between the addresses in the third table, and is not limited to a specific correspondence method. More specific examples are not listed here one by one.
[0152] In some exemplary embodiments, the modular inverse element storage table includes a second modular inverse element storage table; accordingly, step 210 includes:
[0153] Step 2111, when the sequence length falls within the second sequence length range, determine the lookup table address corresponding to the logical index number i in the second modular inverse element storage table according to the second table address generation algorithm.
[0154] Accordingly, in some exemplary embodiments, obtaining the initial modular inverse element based on the lookup result of the lookup table address in the modular inverse element storage table includes:
[0155] Searching from the second modular inverse element storage table to obtain the modular inverse element stored corresponding to the address in the lookup table as the initial modular inverse element;
[0156] Among them, the second table address generation algorithm is used to map one or two logical index numbers to the same lookup table address, wherein, according to the modular inverse element stored in the second modular inverse element storage table corresponding to each lookup table address, the modular inverse element of the sequence number used for transmitter preamble sequence generation corresponding to the logical index number before mapping can be directly obtained or calculated.
[0157] It can be understood that when the length of the leading sequence i falls within the range of the second sequence length, according to the second table address generation algorithm, a convergence is performed to map one or two logical index numbers to the same lookup table address m, which can converge the number of modular inverse elements stored in the second modular inverse element storage table, effectively reducing the system storage resources occupied by the second modular inverse element storage table. That is, the modular inverse elements stored in the second modular inverse element storage table are modular inverse elements u of sequence number u corresponding to some logical index numbers. -1 , the modular inverse element of the sequence number used for transmitter preamble sequence generation corresponding to these logical index numbers before mapping can be directly obtained by looking up the table, and the modular inverse element u of the sequence number u corresponding to other unstored logical index numbers -1 , it needs to be calculated based on these stored modular inverse elements. That is, in this case, the initial modular inverse element u′ corresponding to the logical index number is obtained -1 =u -1 .
[0158] It should be noted that the first, second, and third modular inverse element storage tables recorded in the embodiments of the present disclosure represent that the characteristics of the modular inverse elements stored are different, and they can be stored separately or combined, and are not limited to a specific method. When combining and storing, a unified lookup table address m can be determined accordingly.
[0159] In some exemplary embodiments, the second sequence length range includes: sequence length L RA =839.
[0160] In some exemplary embodiments, the second table address generation algorithm is as follows:
[0161]
[0162] Where m is the lookup table address, i is the logical index number, Express Round down.
[0163] It can be seen that the number of modular inverse elements a1 stored in the second modular inverse element storage table is less than the number of logical index numbers a2, and a1 is approximately 50% of a2, that is, the storage capacity of the target modular inverse elements corresponding to 50% of the sequence numbers is approximately converged by the second table address generation algorithm. Optionally, other second table address generation algorithms can also be used to perform sequence number convergence, which is not limited to the aspects of the embodiments of the present disclosure.
[0164] In some exemplary embodiments, step 230 includes:
[0165] When the logical index number i is an even number,
[0166] and / or,
[0167] When the logical index number i is an odd number,
[0168] Where i is the logical index number, u′ -1 is the initial module inverse element, L RA is the sequence length, is the target modular inverse element corresponding to the logical index number i.
[0169] The present disclosure provides a method for determining a modular inverse element. Figure 3 As shown, including:
[0170] Step 310, according to the logical index number i used for transmitter preamble sequence generation, determine the modular inverse element calculation sequence number u′ corresponding to the logical index number i according to the first sequence number generation algorithm;
[0171] Step 320, determining the modular inverse element search number c corresponding to the modular inverse element calculation sequence number u′ according to the first index generation algorithm;
[0172] Step 330: search the preset first modular inverse element storage table to obtain the modular inverse element c corresponding to the modular inverse element search number c -1 ;
[0173] Step 340: search for the modular inverse element c corresponding to the modular inverse element number c according to the modular inverse element -1 According to the first iterative algorithm, determine the modular inverse element u′ corresponding to the modular inverse element calculation sequence number u′ -1 ;
[0174] Step 350: According to the logical index number i, the modular inverse element calculates the modular inverse element u′ corresponding to the sequence number u′ -1 and the sequence length L used for transmitter preamble generation RA , determine the sequence number u corresponding to the logical index number i for transmitter preamble sequence generation i The modular inverse
[0175] Among them, the modular inverse element search numbers determined corresponding to the multiple logical index numbers are the same.
[0176] It can be understood that the modular inverse element c obtained from the first modular inverse element storage table according to the lookup table address m -1is the first modular inverse element, and the modular inverse element u′ is further calculated based on the first modular inverse element -1 That is the initial module inverse element.
[0177] In some exemplary embodiments, the sequence length L RA The logical index number i is obtained through the upper layer configuration parameters.
[0178] In some exemplary embodiments, the first sequence number generation algorithm is as follows:
[0179]
[0180] Among them, u′ is the modular inverse calculation sequence number, i is the logical index number, Express Round down.
[0181] In some exemplary embodiments, the first index generation algorithm is as follows:
[0182] u′=c·2 n
[0183] Among them, u′ is the modular inverse calculation sequence number, the modular inverse search number c is an odd number, and n is an integer greater than or equal to 0.
[0184] In some exemplary embodiments, step 330 includes:
[0185] Determine the lookup table address m corresponding to the modular inverse element lookup number c according to the first table address generation algorithm;
[0186] Search the first modular inverse element storage table to obtain the modular inverse element c stored in the address m of the lookup table -1 .
[0187] In some exemplary embodiments, the first table address generation algorithm is as follows:
[0188]
[0189] Among them, m is the lookup table address, and c is the modular inverse element lookup number.
[0190] According to the above analysis, we can see that the integer It is expressed as the product of an odd number and a power of 2, i.e. a = c·2 n In the form of, when n ≥ 3, it is necessary to find the modular inverse by table lookup and at least two iterative calculations. Since the number corresponding to n ≥ 3 is relatively small, all the corresponding modular inverses can also be pre-stored in the lookup table, and these modular inverses can be directly obtained by table lookup during calculation.
[0191] Accordingly, in some exemplary embodiments, Figure 4As shown, the method also includes:
[0192] Step 320-1, determine whether n is less than a third threshold, if yes, execute step 330, if n is greater than or equal to, execute step 360;
[0193] Step 360, searching the preset third module inverse element storage table, the sequence number u corresponding to the logical index number i for the transmitter preamble sequence generation i The modular inverse
[0194] In some exemplary embodiments, the third threshold is 3.
[0195] In some exemplary embodiments, the first iterative algorithm is as follows:
[0196]
[0197] Among them, u′ -1 Calculate the modular inverse element corresponding to the serial number u′ for the modular inverse element,
[0198]
[0199] c -1 The modular inverse element corresponding to the modular inverse element search number c, r 0 =c -1 , L RA is the length of the sequence.
[0200] In some exemplary embodiments, when n≥2,
[0201]
[0202] In some exemplary embodiments, step 350 includes:
[0203] When the logical index number i is an even number,
[0204] When the logical index number i is an odd number,
[0205] The present disclosure also provides a method for determining a modular inverse element. Figure 5 As shown, including:
[0206] Step 510, according to the logical index number i used for transmitter preamble sequence generation, determine the lookup table address m corresponding to the logical index number i according to the second table address generation algorithm;
[0207] Step 520: Look up the preset second modular inverse element storage table to obtain the modular inverse element u′ stored in the lookup table address m. -1 ;
[0208] Step 530: According to the logic index number i, the module inverse element u′ -1 and the sequence length L used for transmitter preamble generation RA , determine the sequence number u corresponding to the logical index number i for transmitter preamble sequence generation i The modular inverse
[0209] The lookup table addresses m corresponding to the multiple logic index numbers are the same.
[0210] It can be understood that the modular inverse element u′ obtained from the second modular inverse element storage table according to the lookup table address m -1 That is the initial module inverse element.
[0211] In some exemplary embodiments, the second table address generation algorithm is as follows:
[0212]
[0213] Where m is the lookup table address, i is the logical index number, Express Round down.
[0214] In some exemplary embodiments, step 530 includes:
[0215] When the logical index number i is an even number,
[0216] When the logical index number i is an odd number,
[0217] It can be seen that when the logical index number i and the sequence number u i There is no simple conversion relationship, only the relationship u 2k+1 =L RA -u 2k When , it is necessary to store the modular inverse elements of the serial numbers corresponding to all even logical index numbers, and the modular inverse elements of the serial numbers corresponding to odd logical index numbers are stored through the relationship Find out.
[0218] In some exemplary embodiments, taking the preamble sequence generation process of the PRACH of the 5G NR system as an example, when L RA =139, L RA =571 or L RA =1151, the sequence number u i The relationship between the logical index number i can be expressed as
[0219]
[0220] When the logical index number i is an even number, let i = 2k, there is u i =u 2k = k + 1, where Then u 2k The range is The sequence number corresponding to the next logical index number i+1 is u i+1 =u 2k+1 =L RA -k-1=L RA -u 2k , whose range is According to the properties of modular operation, u 2k and u 2k+1 The modular inverse element satisfies the relation Therefore, the modular inverse element of the sequence number corresponding to the odd logical index number (i=2k+1) can be obtained by subtracting the modular inverse element of the sequence number corresponding to the previous even logical index number (i=2k).
[0221] Therefore, the sequence number corresponding to the modular inverse element that needs to be stored in the first modular inverse element storage table is The corresponding logical index number is i=0,4,8,…,L RA -3, that is, i = 4m, where m corresponds to the address of the pre-stored modular inverse element lookup table, and the range is
[0222] In some exemplary embodiments, the sequence length L RA =139 as an example, the correspondence between the modular inverse elements pre-stored in the first modular inverse element storage table and the lookup table address m, the logical index number i and the serial number is shown in Table 3.
[0223] Table 3 Pre-stored module inverse element and table address, logical index number and sequence number correspondence table (L RA =139)
[0224]
[0225] It should be noted that the calculated modular inverse element search number (odd number) c is within the value range of the sequence number u corresponding to the logical index number used to generate the transmitter preamble sequence. Accordingly, the modular inverse element c of the pre-stored search number c is -1 Also in sequence number u modulo inverse element u -1 Therefore, the serial number u in Table 3 is actually the search number c, modulo inverse element u -1 It is the modular inverse element c of the search number -1 As can be seen, Table 3 only needs to store the modular inverse element c of the search number corresponding to some logical index numbers. -1 .
[0226] Accordingly, the modular inverse element determination method is as follows: Figure 6 As shown, including:
[0227] Step 610, obtaining a logic index number i through upper layer parameter configuration;
[0228] Step 620, if the logical index number i is an even number, then
[0229] Step 630, if the logical index number i is an odd number, then
[0230] Step 640, according to u′=c·2 n , calculate the modular inverse element search number (odd number) c;
[0231] Step 650, according to Calculate the table address m;
[0232] Step 660: According to the table address m, search the first modular inverse element storage table (Table 3) to obtain the modular inverse element c. -1 ;
[0233] Step 670: Determine the modular inverse element u′ according to the first iterative algorithm. -1 ;
[0234] Step 680, if the logical index number i is an even number, determine
[0235] Step 690, if the logical index number i is an odd number, determine
[0236] If the logical index number i is an odd number in step 630, the sequence number corresponding to the previous even logical index number is calculated. The calculation formulas of steps 620 and 630 can be unified as follows:
[0237] In some exemplary embodiments, L RA =571 and L RA =1151 and L RA =139, the same method can be used to pre-store and calculate the modular inverse.
[0238] In some exemplary embodiments, taking the preamble sequence generation process of the PRACH of the 5G NR system as an example, when L RA =839, there is no simple conversion relationship between the logical index number and the serial number, and only the relationship u 2k+1 =L RA -u 2k, so it is necessary to store the modular inverse elements of the serial numbers corresponding to all even logical index numbers, and the modular inverse elements of the serial numbers corresponding to odd logical index numbers are stored through the relationship Find the sequence length L RA =839, the correspondence between the modular inverse elements pre-stored in the second modular inverse element storage table and the lookup table address m, the logical index number i and the serial number u (excerpt) is shown in Table 4.
[0239] Table 4 Pre-stored modular inverse element and table address, logical index number and sequence number correspondence table (excerpt) (L RA =839)
[0240]
[0241] It can be seen that Table 4 stores the modular inverse u of the sequence number u corresponding to about half of the logical index numbers. -1 That is, according to the lookup table address, the target modular inverse elements corresponding to the stored logical index numbers can be directly determined by looking up the table, and the target modular inverse elements corresponding to the other part of the unstored logical index numbers can be obtained by further calculation.
[0242] In some exemplary embodiments, the third threshold value = 3, with L RA =139 as an example, the pre-stored third module inverse element storage table is shown in Table 5.
[0243] Table 5 Pre-stored modular inverse table of integers u with n≥3 (L RA =139)
[0244] Table address m′ u <![CDATA[Modular inverse u -1 > 0 8 87 1 16 113 2 24 29 3 32 126 4 40 73 5 48 84 6 56 72 7 64 63
[0245] As can be seen, Table 5 stores the modular inverse element u′ of the modular inverse element calculation sequence number u′ with n ≥ 3. -1 That is, according to the lookup table address, the modular inverse element u′ of the stored modular inverse element calculation sequence number u′ can be directly determined by looking up the table. -1 (initial modular inverse), no need to perform multiple iterations to calculate. It can be understood that the modular inverse calculation sequence number u′ for n ≥ 3 is relatively small. The scheme can use a small amount of storage space cost in exchange for the calculation cost of multiple iterations.
[0246] The present disclosure also provides a method for determining a modular inverse element. Figure 7 As shown, including:
[0247] Step 710, in the sequence length L used for transmitter preamble sequence generation RA If it falls within the first sequence length range, execute steps 310-350 to determine the modular inverse element;
[0248] Step 720, the sequence length L used for generating the transmitter preamble sequence RA When the length falls within the second sequence length range, steps 510-530 are executed to determine the modular inverse element.
[0249] In some exemplary embodiments, the method is applied in a 5G NR system, and the first sequence length range includes: sequence length L RA =139, L RA =571 or L RA =1151; the second sequence length range includes: sequence length L RA =839.
[0250] It can be seen that the sequence length L RA =139, the required storage resource size is 35×8bit=280bit. RA =571, the required storage resource size is 143×10bit=1430bit. RA =1151, the required storage resource size is 288×11bit=3168bit. RA =839, the required storage resource size is 419×10 bits=4190 bits. A total of 9068 bits are required to store the modular inverse elements of the four sequence lengths, which only accounts for 32.58% of the 27834 bits required to store all modular inverse elements.
[0251] When the sequence length L RA =139, L RA =571 or L RA =1151, the modular inverse calculation sequence number u′=c·2 n The number of iterations for calculating the modular inverse is and So the maximum number of iterations is Sequence length L RA =139, a maximum of 3 iterations are required; the sequence length L RA =571, a maximum of 4 iterations are required; the sequence length L RA =1151, a maximum of 5 iterations are required.
[0252] When the sequence length L RA =839, no iteration is required.
[0253] The present disclosure also provides a method for determining a modular inverse element. Figure 8 As shown, including:
[0254] Step 810, obtain the sequence length L through upper layer parameter configuration RA and logical index number i; when LRA =139, L RA =571 or L RA =1151, execute 820, when L RA =839, execute 860;
[0255] Step 820, calculate the modular inverse element to calculate the sequence number u′;
[0256] Step 830, calculating the modular inverse element search number c;
[0257] Step 840: search the first modular inverse element storage table to obtain the modular inverse element c -1 ;
[0258] Step 850, based on c -1 Calculate u′ -1 ;
[0259] Step 860, search the second modular inverse element storage table according to the logical index number to obtain u -1 As the initial modular inverse element u′ -1 ;
[0260] Step 870, determine whether the logic index number i is an even number, if yes, execute 880, otherwise execute 890;
[0261] Step 880, determine
[0262] Step 890, determine
[0263] Among them, in step 820, if the logical index number i is an even number, according to the logical index number i and the sequence number u i The relational formula is used to calculate the modular inverse element calculation sequence number. If the logical index number i is an odd number, then calculate the modular inverse element calculation sequence number corresponding to the previous even logical index number The calculation formulas for the two cases can be unified as
[0264] In steps 830 and 840, the modular inverse calculation sequence number u′ is expressed as u′=c·2 n , calculate the table address corresponding to the odd number c And according to the address, check the first modular inverse element storage table to get the modular inverse element c of c -1 .
[0265] In step 850, when n=0, u′ -1 =c -1 ; When n = 1, u′ is obtained through a single-step iteration -1 ; When n>1 and is an even number, u′ is obtained by the combined iteration method -1; When n>1 and is an odd number, u′ is obtained by combining the iteration method and a single-step iteration -1 .
[0266] In step 860, the table address is calculated according to the logical index number i And according to the table address, check the second modular inverse element storage table to obtain the modular inverse element u′ -1 .
[0267] The present disclosure also provides a modular inverse element determination device, including:
[0268] An address determination module, configured to calculate a lookup table address according to a logical index number and a sequence length used for generating a transmitter preamble sequence, wherein the lookup table addresses corresponding to a plurality of logical index numbers are the same;
[0269] An initial modular inverse element determination module is configured to obtain an initial modular inverse element based on a search result of the lookup table address in a modular inverse element storage table;
[0270] The target modular inverse element determination module is configured to determine the target modular inverse element corresponding to the logical index number according to the logical index number, the initial modular inverse element and the sequence length.
[0271] The present disclosure also provides a modular inverse element determination device, including:
[0272] A sequence number calculation module, configured to determine, according to a logic index number i used for transmitter preamble sequence generation, a modular inverse element calculation sequence number u corresponding to the logic index number i in accordance with a first sequence number generation algorithm;
[0273] A search number calculation module, configured to determine the modular inverse element search number c corresponding to the modular inverse element calculation sequence number u according to a first index generation algorithm;
[0274] A search module is configured to search a preset first modular inverse element storage table to obtain a modular inverse element c corresponding to the modular inverse element search number c. -1 ;
[0275] A modular inverse element determination module is configured to determine a modular inverse element c corresponding to the modular inverse element search number c. -1 According to the first iterative algorithm, determine the modular inverse element u′ corresponding to the modular inverse element calculation sequence number u′ -1 ;
[0276] The modular inverse element determination module is further configured to: determine the modular inverse element u′ according to the logical index number i. -1 and the sequence length L used for transmitter preamble generation RA , determine the sequence number u corresponding to the logical index number i for transmitter preamble sequence generation i The modular inverse
[0277] Among them, the modular inverse element search numbers determined corresponding to the multiple logical index numbers are the same.
[0278] The present disclosure also provides a modular inverse element determination device, including:
[0279] A search module, configured to determine, according to a logic index number i used for transmitter preamble sequence generation, a lookup table address m corresponding to the logic index number i according to a second table address generation algorithm;
[0280] The search module is further configured to search a preset second modular inverse element storage table to obtain the modular inverse element u′ stored in the address m of the search table. -1 ;
[0281] The module for determining the modular inverse element is configured to determine the modular inverse element u′ according to the logical index number i. -1 and the sequence length L used for transmitter preamble generation RA , determine the sequence number u corresponding to the logical index number i for transmitter preamble sequence generation i The modular inverse
[0282] The lookup table addresses m corresponding to the multiple logic index numbers are the same.
[0283] The embodiment of the present disclosure also provides a modular inverse element determination device, comprising: a judgment module, a first modular inverse element determination module, and a second modular inverse element determination module;
[0284] The judgment module is configured to generate a sequence length L for the transmitter preamble sequence according to RA , determine the sequence length L RA Falling within the first sequence length range or the second sequence length range;
[0285] The first module inverse element determination module is set to, in the sequence length L RA When the length of the first sequence falls within the range, the following steps are performed to determine the modular inverse element:
[0286] According to the logical index number i used for generating the transmitter preamble sequence, determine the modular inverse element calculation sequence number u′ corresponding to the logical index number i according to the first sequence number generation algorithm;
[0287] Determine the modular inverse element search number c corresponding to the modular inverse element calculation sequence number u′ according to the first index generation algorithm;
[0288] Search the preset first modular inverse element storage table to obtain the modular inverse element c corresponding to the modular inverse element search number c -1 ;
[0289] According to the modular inverse element, find the modular inverse element c corresponding to the number c. -1 According to the first iterative algorithm, determine the modular inverse element u′ corresponding to the modular inverse element calculation sequence number u′ -1 ;
[0290] According to the logical index number i, the modular inverse element u′ -1 and the sequence length L used for transmitter preamble generation RA , determine the sequence number u corresponding to the logical index number i for transmitter preamble sequence generation i The modular inverse
[0291] Wherein, the modular inverse element search numbers corresponding to the multiple logical index numbers are the same;
[0292] The second module inverse element determination module is set to, in the sequence length L RA When the length of the first sequence falls within the range, the following steps are performed to determine the modular inverse element:
[0293] According to the logical index number i used for transmitter preamble sequence generation, determine the lookup table address m corresponding to the logical index number i according to the second table address generation algorithm;
[0294] Search the preset second modular inverse element storage table to obtain the modular inverse element u′ stored in the address m of the lookup table -1 ;
[0295] According to the logical index number i, the modular inverse element u′ -1 and the sequence length L used for transmitter preamble generation RA , determine the sequence number u corresponding to the logical index number i for transmitter preamble sequence generation i The modular inverse
[0296] The lookup table addresses m corresponding to the multiple logic index numbers are the same.
[0297] An embodiment of the present disclosure further provides a communication chip, comprising a processor, wherein the processor is configured to execute the modular inverse element determination method as described in any embodiment of the present disclosure.
[0298] An embodiment of the present disclosure further provides a mobile terminal, comprising a communication chip, wherein the communication chip is configured to execute the modular inverse element determination method as described in any embodiment of the present disclosure.
[0299] An embodiment of the present disclosure further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method for determining a modular inverse element as described in any embodiment of the present disclosure.
[0300] The modular inverse element determination scheme provided by the embodiments of the present disclosure only pre-stores the modular inverse elements of some sequence numbers, while the modular inverse elements of other sequence numbers are obtained through an iterative method based on the pre-stored modular inverse elements. In some exemplary embodiments, in the iterative method, the integer a is represented as the product of an odd number and a power of 2, that is, a=c·2 n When n=0, the result is obtained by directly looking up the pre-stored modular inverse table; when n=1, the result is obtained by looking up the table and a single-step iteration; when n>1 and it is an even number, the final result is obtained by looking up the table and combining the iteration method; when n>1 and it is an odd number, the final result is obtained by looking up the table, combining the iteration method and a single-step iteration.
[0301] It can be seen that, compared with the method of storing all modular inverse elements, the modular inverse element determination scheme provided by the embodiment of the present disclosure only pre-stores part of the modular inverse elements, which can reduce a large amount of storage resources and reduce implementation costs. Compared with the method of directly calculating modular inverse elements online, the modular inverse element determination scheme provided by the embodiment of the present disclosure has fewer calculation iterations, less calculation delay, and higher calculation efficiency.
[0302] It will be appreciated by those skilled in the art that all or some of the steps, systems, and functional modules / units in the methods disclosed above may be implemented as software, firmware, hardware, and appropriate combinations thereof. In hardware implementations, the division between the functional modules / units mentioned in the above description does not necessarily correspond to the division of physical components; for example, a physical component may have multiple functions, or a function or step may be performed by several physical components in cooperation. Some or all components may be implemented as software executed by a processor, such as a digital signal processor or a microprocessor, or implemented as hardware, or implemented as an integrated circuit, such as an application-specific integrated circuit. Such software may be distributed on a computer-readable medium, which may include a computer storage medium (or non-transitory medium) and a communication medium (or temporary medium). As known to those skilled in the art, the term computer storage medium includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media include, but are not limited to, RAM, ROM, EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tapes, magnetic disk storage or other magnetic storage devices, or any other medium that can be used to store the desired information and can be accessed by a computer. In addition, it is well known to those of ordinary skill in the art that communication media typically contain computer-readable instructions, data structures, program modules, or other data in a modulated data signal such as a carrier wave or other transport mechanism, and may include any information delivery media.
[0303] The above description is only a preferred embodiment of the present application scheme, and does not limit the patent scope of the present application. All equivalent structural changes made based on the concept of the present application scheme and the contents of the present application specification and drawings, or direct / indirect application in other related technical fields are included in the patent protection scope of the present application.
Claims
1. A method for determining modular inverse elements, It is characterized in that include: Calculating a lookup table address according to a logical index number and a sequence length for generating a transmitter preamble sequence, wherein the lookup table addresses corresponding to a plurality of logical index numbers are the same; Obtaining an initial modular inverse element based on a search result of the lookup table address in a modular inverse element storage table; According to the logical index number, the initial modular inverse element and the sequence length, a target modular inverse element corresponding to the logical index number is determined.
2. The method for determining a modular inverse element according to claim 1, It is characterized in that The modular inverse element storage table includes a first modular inverse element storage table; The step of calculating the lookup table address according to the logical index number and the sequence length used for generating the transmitter preamble sequence comprises: When the sequence length falls within the first sequence length range, determining the modular inverse element calculation sequence number corresponding to the logical index number according to the first sequence number generation algorithm; Determine, according to a first table address generation algorithm, the lookup table address in the first modular inverse element storage table corresponding to the modular inverse element calculation sequence number; The first sequence number generation algorithm is used to map one or more logical index numbers to the same modular inverse element calculation sequence number, and each modular inverse element calculation sequence number is within the sequence number range used for transmitter preamble sequence generation; The first table address generation algorithm is used to map one or more modular inverse element calculation serial numbers to the same lookup table address, wherein the modular inverse element of the modular inverse element calculation serial number before mapping can be calculated based on the modular inverse element stored in the first modular inverse element storage table corresponding to each lookup table address.
3. The method for determining a modular inverse element according to claim 2, It is characterized in that The determining, according to the first table address generation algorithm, the lookup table address in the first modular inverse element storage table corresponding to the modular inverse element calculation sequence number comprises: Determine, according to the first index generation algorithm, a modular inverse element search number corresponding to the modular inverse element calculation sequence number; According to the modular inverse element search number, determining that a lookup table address for searching the modular inverse element corresponding to the modular inverse element search number in the first modular inverse element storage table is the lookup table address; Among them, the first index generation algorithm is used to map one or more modular inverse element calculation serial numbers to the same modular inverse element search number, wherein the modular inverse element of the modular inverse element calculation serial number before mapping can be calculated based on the modular inverse element of the same modular inverse element search number.
4. The method for determining a modular inverse element according to claim 3, It is characterized in that The step of obtaining an initial modular inverse element based on the search result of the lookup table address in the modular inverse element storage table comprises: Acquire the modular inverse element stored corresponding to the address in the lookup table from the first modular inverse element storage table as the first modular inverse element; Based on the first modular inverse element, the initial modular inverse element is calculated.
5. The method for determining a modular inverse element according to claim 4, It is characterized in that The first index generation algorithm is as follows: u′=c·2 n Wherein, u′ is the modular inverse element calculation sequence number, the modular inverse element search number c is an odd number, and n is an integer greater than or equal to 0; The calculating the initial modular inverse element based on the first modular inverse element includes at least one of the following situations: When n is equal to a first threshold, determining the first modular inverse element as the initial modular inverse element; When n is greater than or equal to a second threshold, performing n single-step iterations according to the first modular inverse element to obtain the initial modular inverse element; When n is greater than a second threshold and is an even number, performing merging and iteration according to the first modular inverse element to obtain the initial modular inverse element; When n is greater than a second threshold and is an odd number, performing a merging iteration and a single-step iteration according to the first modular inverse element to obtain the initial modular inverse element; The second threshold is greater than the first threshold.
6. The method for determining a modular inverse element according to claim 3, It is characterized in that The first index generation algorithm is as follows: u′=c·2 n Wherein, u′ is the modular inverse element calculation sequence number, the modular inverse element search number c is an odd number, and n is an integer greater than or equal to 0; The modular inverse element storage table includes a third modular inverse element storage table; When n is greater than or equal to a third threshold, the method further includes: Look up the modular inverse u' corresponding to the modular inverse calculation serial number u' from the third modular inverse storage table -1 , as the initial modular inverse.
7. The method for determining a modular inverse element according to claim 1, It is characterized in that The modular inverse element storage table includes a second modular inverse element storage table; The step of calculating the lookup table address according to the logical index number and the sequence length used for generating the transmitter preamble sequence comprises: In the case where the sequence length falls within the second sequence length range, determining, according to a second table address generation algorithm, the lookup table address in the second modular inverse element storage table corresponding to the logical index number; Among them, the second table address generation algorithm is used to map one or two logical index numbers to the same lookup table address, wherein, according to the modular inverse element stored in the second modular inverse element storage table corresponding to each lookup table address, the modular inverse element of the sequence number used for transmitter preamble sequence generation corresponding to the logical index number before mapping can be directly obtained or calculated.
8. The method for determining a modular inverse element according to any one of claims 1 to 7, It is characterized in that The step of determining the target modular inverse element corresponding to the logical index number according to the logical index number, the initial modular inverse element and the sequence length includes: When the logical index number is an even number, and / or, When the logical index number is an odd number, Where i is the logical index number, u′ -1 is the initial module inverse element, L RA is the sequence length, is the target modular inverse element corresponding to the logical index number i.
9. A communication chip, It is characterized in that The method comprises a processor configured to execute the modular inverse element determination method according to any one of claims 1 to 8.
10. A mobile terminal, It is characterized in that It comprises a communication chip, wherein the communication chip is configured to execute the modular inverse element determination method as described in any one of claims 1-8.
11. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the program is executed by a processor, the method for determining a modular inverse element as described in any one of claims 1 to 8 is implemented.
Citation Information
Patent Citations
Domain element inverting method in BCH decoding algorithm and circuit thereof
CN101453291A
Method and device for generating random access preambles
CN103124438A