TWI694338B - System of grouping for interrupted continuous serial and method thereof - Google Patents

System of grouping for interrupted continuous serial and method thereof Download PDF

Info

Publication number
TWI694338B
TWI694338B TW108101197A TW108101197A TWI694338B TW I694338 B TWI694338 B TW I694338B TW 108101197 A TW108101197 A TW 108101197A TW 108101197 A TW108101197 A TW 108101197A TW I694338 B TWI694338 B TW I694338B
Authority
TW
Taiwan
Prior art keywords
complement
elements
continuous sequence
sequence
continuous
Prior art date
Application number
TW108101197A
Other languages
Chinese (zh)
Other versions
TW202026906A (en
Inventor
周旭震
Original Assignee
關貿網路股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 關貿網路股份有限公司 filed Critical 關貿網路股份有限公司
Priority to TW108101197A priority Critical patent/TWI694338B/en
Application granted granted Critical
Publication of TWI694338B publication Critical patent/TWI694338B/en
Publication of TW202026906A publication Critical patent/TW202026906A/en

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

A system of grouping for interrupted continuous serial and method thereof, including: a first computing module subtracts at least one first serial set from a first continuous serial set to obtain a first complement set; a sorting serial module generates a continuous serial number set based on the first complement set; a second computing module subtracts the continuous serial number set from the first complement set to obtain a second complement set; and a grouping module groups the first complement set according to the second complement set.

Description

中斷連續序列分群之系統與其方法 System and method for interrupting continuous sequence grouping

本發明係有關一種分群技術,尤指一種中斷連續序列分群之系統與其方法。 The invention relates to a grouping technology, especially a system and method for interrupting continuous sequence grouping.

大量數字序列,如電子發票的字軌資料量是以『億』為單位來循環的(兩位英文字+八位數字),營業人在向財政部申請電子發票字軌後,財務人員可能會因為管理需要,將這些發票字軌拆成小的發票簿(字軌區段)來使用,或因業務流程需要,將字軌拆段,分配給各事業別/單位去使用。 A large number of digital sequences, such as the amount of track data of electronic invoices is circulated in units of "100 million" (two English words + eight digits). After the business operator applies to the Ministry of Finance for the track of electronic invoices, financial personnel may Because of management needs, these invoice tracks are split into small invoice books (track sections) for use, or because of business process needs, the track segments are split and allocated to various business units/units for use.

在每個發票期別結束後,財政部規定營業人需要計算出空白未使用字軌,彙整成統計資料傳送給財政部大平台,並同步於媒體申報檔檔案中供報稅使用,對於大型電子發票加值中心來說,若存在於多家大型加盟直營體系的公司,通常會集中由總公司向財政部申請電子發票的全部字軌,再分配給各個門市,而單一門市又會有多個POS機台,假設某公司有500家門市,每家門市平均有10個POS機台,表示這家公司至少有5000個發票字軌區段,但實際情況向財政部所領取的發票字軌區段往往遠超過上述的5000個好幾倍。 After the end of each invoice period, the Ministry of Finance stipulates that business operators need to calculate blank unused character tracks, aggregate them into statistical data, and send them to the Ministry of Finance platform, and synchronize them with media filing files for tax reporting. For large electronic invoices, add For the value center, if it exists in many large franchise companies, it will usually concentrate all the application of the electronic invoice from the head office to the Ministry of Finance, and then distribute it to each store, and a single store will have multiple POS Machines, assuming that a company has 500 stores, and each store has an average of 10 POS machines, indicating that this company has at least 5000 invoice track sections, but the actual situation of the invoice track sections received from the Ministry of Finance It is often many times more than the above 5000.

同樣地,在其他具有大量數字序列的情況中,也存在類似問題。因此,如何正確且快速的計算出大量數字序列中空白未使用的部分,例如如何每期正確且在期限內快速的計算出電子發票的空白未使用字軌,即為本發明所要解決之技術問題。 Similarly, there are similar problems in other cases with a large number of digital sequences. Therefore, how to calculate blank and unused parts in a large number of sequences correctly and quickly, for example, how to calculate blank and unused tracks of electronic invoices correctly and quickly within each period is the technical problem to be solved by the present invention .

為解決上述問題,本案發明提供一種中斷連續序列分群之系統,係包括:接收模組,係接收一第一連續序列集合及至少一第一序列集合;第一計算模組,係用以將該第一連續序列集合減掉該至少一第一序列集合,以得到第一補集合;排序序號模組,係產生以該第一補集合為排序依據的連續序號集合;第二計算模組,係用以將該第一補集合減掉該連續序號集合,以得到第二補集合;以及分群模組,係依據該第二補集合,將該第一補集合進行分群。 In order to solve the above problems, the present invention provides a system for interrupting continuous sequence grouping, which includes: a receiving module that receives a first continuous sequence set and at least one first sequence set; a first calculation module is used to The first continuous sequence set is subtracted from the at least one first sequence set to obtain a first supplementary set; the sequence number module generates a continuous sequence number set based on the first supplementary set; the second calculation module is a system It is used to subtract the continuous sequence number set from the first supplementary set to obtain a second supplementary set; and the grouping module is to group the first supplementary set according to the second supplementary set.

於一實施例中,該第一序列集合係為該第一連續序列集合中的子集合。 In an embodiment, the first sequence set is a subset of the first continuous sequence set.

於一實施例中,該第一補集合係為該第一連續序列集合的中斷連續序列集合。 In an embodiment, the first complement set is an interrupted continuous sequence set of the first continuous sequence set.

於一實施例中,該第一序列集合中的元素係為單一元素或連續序列元素。 In one embodiment, the elements in the first sequence set are single elements or continuous sequence elements.

於一實施例中,該第一補集合的元素係依序對應該第二補集合中的元素,以令該分群模組將該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群。 In an embodiment, the elements of the first complement set correspond to the elements in the second complement set in order, so that the grouping module sequentially sequence the elements of the first complement set according to the corresponding second complement set Group repeating elements in.

本發明另提供一種中斷連續序列分群之方法,係包括下列步驟:接收一第一連續序列集合及至少一第一序列集合;將該第一連續序列集合減掉該至少一第一序列集合,以得到第一補集合;產生以該第一補集合為排序依據的連續序號集合;將該第一補集合減掉該連續序號集合,以得到第二補集合;以及依據該第二補集合,令該第一補集合進行分群。 The present invention also provides a method for interrupting continuous sequence grouping, which includes the following steps: receiving a first continuous sequence set and at least one first sequence set; subtracting the at least one first sequence set from the first continuous sequence set, to Obtain a first complement set; generate a continuous sequence number set based on the first supplement set; subtract the continuous sequence number set from the first supplement set to obtain a second supplement set; and based on the second supplement set, make The first complement set is grouped.

於一實施例中,該第一序列集合係為該第一連續序列集合中的子集合。 In an embodiment, the first sequence set is a subset of the first continuous sequence set.

於一實施例中,該第一補集合係為該第一連續序列集合的中斷連續序列集合。 In an embodiment, the first complement set is an interrupted continuous sequence set of the first continuous sequence set.

於一實施例中,該第一序列集合中的元素係為單一元素或連續序列元素。 In one embodiment, the elements in the first sequence set are single elements or continuous sequence elements.

於一實施例中,該第一補集合的元素係依序對應該第二補集合中的元素,以令該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群。 In an embodiment, the elements of the first complement set correspond to the elements in the second complement set in order, so that the elements of the first complement set are sequentially performed according to the repeated elements in the corresponding second complement set Grouping.

由上述可知,本發明藉由產生與第一補集合對應的連續序號集合,再使該第一補集合減掉該連續序號集合,以得到第二補集合,並透過該第一補集合的元素依序對應的第二補集合的元素之關係,使該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群。 As can be seen from the above, the present invention generates a second complement set by generating a continuous sequence number set corresponding to the first complement set, and then subtracting the continuous sequence number set from the first complement set, and passing the elements of the first complement set The relationship between the elements of the second complementary set corresponding to the sequence makes the elements of the first complementary set be grouped sequentially according to the repeated elements in the corresponding second complementary set.

11‧‧‧接收模組 11‧‧‧Receiving module

12‧‧‧第一計算模組 12‧‧‧ First computing module

13‧‧‧排序序號模組 13‧‧‧Sequence number module

14‧‧‧第二計算模組 14‧‧‧Second computing module

15‧‧‧分群模組 15‧‧‧ Group module

S1~S5‧‧‧步驟 S1~S5‧‧‧Step

第1圖係本發明之中斷連續序列分群之系統之示意圖;以及第2圖係本發明之中斷連續序列分群之方法之流程示意圖。 Figure 1 is a schematic diagram of the system for interrupting continuous sequence grouping of the present invention; and Figure 2 is a schematic flowchart of the method for interrupting continuous sequence grouping of the present invention.

以下藉由特定的具體實施例說明本發明之實施方式,熟悉此技藝之人士可由本說明書所揭示之內容輕易地瞭解本發明之其他優點及功效。 The following describes the implementation of the present invention by specific specific examples. Those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification.

須知,本說明書所附圖式所繪示之結構、比例、大小等,均僅用以配合說明書所揭示之內容,以供熟悉此技藝之人士之瞭解與閱讀,並非用以限定本發明可實施之限定條件,故不具技術上之實質意義,任何結構之修飾、比例關係之改變或大小之調整,在不影響本發明所能產生之功效及所能達成之目的下,均應仍落在本發明所揭示之技術內容得能涵蓋之範圍內。同時,本說明書中所引用之如「第一」及「第二」等之用語,亦僅為便於敘述之明瞭,而非用以限定本發明可實施之範圍,其相對關係之改變或調整,在無實質變更技術內容下,當視為本發明可實施之範疇。 It should be noted that the structure, ratio, size, etc. shown in the drawings of this specification are only used to match the content disclosed in the specification, for those who are familiar with this skill to understand and read, not to limit the implementation of the present invention The limited conditions do not have technical significance. Any modification of structure, change of proportional relationship or adjustment of size should still fall within the scope of the invention without affecting the efficacy and the purpose of the invention. The technical content disclosed by the invention can be covered. At the same time, the terms such as "first" and "second" quoted in this specification are only for the convenience of description, not to limit the scope of the invention, and to change or adjust the relative relationship. Without substantial changes in the technical content, it should be regarded as the scope of the invention.

第1圖係本發明之中斷連續序列分群之系統之示意圖。如圖所示,該系統係包括:接收模組11、第一計算模組12、排序序號模組13、第二計算模組14以及分群模組15,其中,中斷連續序列分群之系統係為一雲端、遠端或本地端之伺服器(如處理大量數字序列或電子發票的計算機系統),且中斷連續序列分群之系統中的各個模組11~15係為應用程式並儲存在該伺服器的儲存裝置中,以供該伺服器的處理器執行各該模組中的應用程式,但不以此為限。 Figure 1 is a schematic diagram of the system for interrupting continuous sequence grouping of the present invention. As shown in the figure, the system includes: a receiving module 11, a first computing module 12, a sequence number module 13, a second computing module 14, and a grouping module 15, wherein the system for interrupting the continuous sequence grouping is A cloud, remote, or local server (such as a computer system that processes a large number of digital sequences or electronic invoices), and each module 11~15 in the system that interrupts the continuous sequence grouping is an application program and stored in the server In the storage device of the server, the processor of the server executes the application program in each module, but not limited to this.

接收模組11,係接收一第一連續序列集合及至少一第一序列集合。舉例而言,該第一連續序列集合例如為{1~30}的連續序列元素,而該第一序列集合例如可為{3,4,5}或{22},但不以此為限。需理解的是,連續序列集合的意 思表示為集合內的元素從頭連續到尾且沒有中斷,如該第一連續序列集合所舉例的{1~30}。 The receiving module 11 receives a first continuous sequence set and at least a first sequence set. For example, the first continuous sequence set is, for example, {1~30} continuous sequence elements, and the first sequence set may be, for example, {3, 4, 5} or {22}, but not limited thereto. It should be understood that the meaning of continuous sequence set Si means that the elements in the set are continuous from beginning to end without interruption, as in the example of the first continuous sequence set {1~30}.

第一計算模組12,係與接收模組11連接,以取得接收模組11所接收到的第一連續序列集合及至少一第一序列集合,並將該第一連續序列集合減掉該至少一第一序列集合,以得到第一補集合。 The first computing module 12 is connected to the receiving module 11 to obtain the first continuous sequence set and at least one first sequence set received by the receiving module 11 and subtract the first continuous sequence set from the at least one A first sequence set to obtain a first complement set.

於一實施例中,該第一序列集合係為該第一連續序列集合中的子集合,而該第一補集合係為該第一連續序列集合的中斷連續序列集合。需理解的是,中斷連續序列集合的意思為集合內的元素沒有從頭連號到尾,例如{1,2,3,7,8,9}之集合中缺少了4~6的元素則表示{1,2,3,7,8,9}之集合為中斷連續序列集合。 In an embodiment, the first sequence set is a subset of the first continuous sequence set, and the first complement set is an interrupted continuous sequence set of the first continuous sequence set. It should be understood that interrupting a continuous sequence set means that the elements in the set are not serially numbered from the beginning to the end. For example, the elements of {1,2,3,7,8,9} lacking 4~6 means { The set of 1,2,3,7,8,9} is an interrupted continuous sequence set.

於一實施例中,該第一序列集合中的元素係為單一元素或連續序列元素。 In one embodiment, the elements in the first sequence set are single elements or continuous sequence elements.

排序序號模組13,係與第一計算模組12連接,以取得該第一補集合,並產生以該第一補集合為排序依據的連續序號集合。例如,當該第一補集合為{1,3,5,6}時,由於{1,3,5,6}中有四個元素,因此,該連續序號集合為{1,2,3,4},換言之,該連續序號集合中的元素即為相對應該第一補集合中的元素數量之排序的連續序號的元素。 The sequence number module 13 is connected to the first calculation module 12 to obtain the first complement set and generate a continuous sequence number set based on the first supplement set. For example, when the first complement set is {1,3,5,6}, since there are four elements in {1,3,5,6}, the continuous sequence number set is {1,2,3, 4} In other words, the elements in the set of consecutive numbers are the elements of consecutive numbers corresponding to the number of elements in the first complement set.

第二計算模組14,係與第一計算模組12及排序序號模組13連接,以從第一計算模組12取得該第一補集合以及從排序序號模組13取得該連續序號集合,並將該第一補集合減掉該連續序號集合,以得到第二補集合。 The second calculation module 14 is connected to the first calculation module 12 and the sequence number module 13 to obtain the first supplementary set from the first calculation module 12 and the continuous sequence number set from the sequence number module 13, And subtract the continuous sequence number set from the first supplementary set to obtain a second supplementary set.

分群模組15,係與第一計算模組12及第二計算模組14連接,以從第一計算模組12取得該第一補集合以及從第二計算模組14取得該第二補集合,以依據該第二補集合,將該第一補集合進行分群。 The grouping module 15 is connected to the first computing module 12 and the second computing module 14 to obtain the first complement set from the first computing module 12 and the second complement set from the second computing module 14 To group the first supplementary set according to the second supplementary set.

於一實施例中,該第一補集合的元素係依序對應該第二補集合中的元素,以令該分群模組將該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群。 In an embodiment, the elements of the first complement set correspond to the elements in the second complement set in order, so that the grouping module sequentially sequence the elements of the first complement set according to the corresponding second complement set Group repeating elements in.

第2圖係本發明之中斷連續序列分群之方法之流程示意圖。如圖所示,該方法係包括下列步驟: FIG. 2 is a schematic flowchart of the method for interrupting continuous sequence grouping of the present invention. As shown in the figure, the method includes the following steps:

在步驟S1中,接收一第一連續序列集合及至少一第一序列集合,其中,利用接收模組11接收該第一連續序列集合及該至少一第一序列集合。 In step S1, a first continuous sequence set and at least one first sequence set are received, wherein the first continuous sequence set and the at least one first sequence set are received by the receiving module 11.

在步驟S2中,將該第一連續序列集合減掉該至少一第一序列集合,以得到第一補集合,其中,利用第一計算模組12將該第一連續序列集合減掉該至少一第一序列集合。 In step S2, the first continuous sequence set is subtracted from the at least one first sequence set to obtain a first complement set, wherein the first continuous sequence set is subtracted from the at least one first set by the first calculation module 12 The first sequence set.

在步驟S3中,產生以該第一補集合為排序依據的連續序號集合,其中,利用排序序號模組13產生以該第一補集合為排序依據的連續序號集合。 In step S3, a continuous sequence number set based on the first complement set is generated, wherein the sequential sequence number module 13 is used to generate a continuous sequence number set based on the first supplement set.

在步驟S4中,將該第一補集合減掉該連續序號集合,以得到第二補集合,其中,利用第二計算模組14將該第一補集合減掉該連續序號集合,以得到該第二補集合。 In step S4, the first supplementary set is subtracted from the continuous sequence number set to obtain a second supplementary set, wherein the first supplementary set is subtracted from the continuous sequence number set by the second calculation module 14 to obtain the The second supplement collection.

在步驟S5中,依據該第二補集合中的重複元素,令該第一補集合進行分群,其中,利用分群模組15依據該第二補集合,令該第一補集合進行分群。 In step S5, the first complement set is grouped according to the repeated elements in the second complement set, and the first complement set is grouped according to the second complement set by the grouping module 15.

於一實施例中,該第一序列集合係為該第一連續序列集合中的子集合,而該第一補集合係為該第一連續序列集合的中斷連續序列集合。 In an embodiment, the first sequence set is a subset of the first continuous sequence set, and the first complement set is an interrupted continuous sequence set of the first continuous sequence set.

於一實施例中,該第一序列集合中的元素係為單一元素或連續序列元素。 In one embodiment, the elements in the first sequence set are single elements or continuous sequence elements.

於一實施例中,該第一補集合的元素係依序對應該第二補集合中的元素,以令該步驟S5將該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群。 In an embodiment, the elements of the first complement set correspond to the elements in the second complement set in order, so that step S5 sequentially sorts the elements of the first complement set according to the corresponding ones in the second complement set Group the repeated elements.

本發明之中斷連續序列分群之系統與方法適用於電子發票未使用之字軌之分群統計,下列提供一情境實例來呈現實際用作方式: The system and method for interrupting continuous sequence grouping of the present invention are applicable to the grouping statistics of unused character tracks of electronic invoices. The following provides an example of a scenario to show the actual use method:

在步驟S1中,接收原始空白發票集合ALLINVS(即該第一連續序列集合)及已使用的發票集合USED(即該至少一第一序列集合),其中,該已使用的發票集合係為該原始空白原始發票集合中已被使用的發票集合。 In step S1, the original blank invoice set ALLINVS (ie the first continuous sequence set) and the used invoice set USED (ie the at least one first sequence set) are received, wherein the used invoice set is the original A collection of invoices that have been used in the blank original invoice collection.

該原始空白發票集合ALLINVS之定義為:ALLINVS={n

Figure 108101197-A0101-12-0007-6
N 0 |n<10 10 }={0,1,2,...,9999999999};例如:ALLINVS={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30}。 The definition of the original blank invoice set ALLINVS is: ALLINVS={ n
Figure 108101197-A0101-12-0007-6
N 0 | n <10 10 }={0,1,2,...,9999999999} ; For example: ALLINVS={1,2,3,4,5,6,7,8,9,10,11, 12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30}.

該已使用的發票集合USED之定義為:

Figure 108101197-A0101-12-0007-1
例如:USED={3,4,5,6}1 ∪{10,11,12}2 ∪{15,16,17}3 ∪{22}4 ∪{26}5={3,4,5,6,10,11,12,15,16,17,22,26}。 The USED definition of the used invoice set is:
Figure 108101197-A0101-12-0007-1
For example: USED={3,4,5,6} 1 ∪{10,11,12} 2 ∪{15,16,17} 3 ∪{22} 4 ∪{26} 5 ={3,4,5, 6,10,11,12,15,16,17,22,26}.

在步驟S2中,將該原始空白發票集合ALLINVS減掉該已使用的發票集合USED,以得到該原始空白發票集合ALLINVS中的未被使用的空白發票集合BLANK(即該第一補集合),如:BLANK=ALLINVS-USED={1,2,7,8,9,13,14,18,19,20,21,23,24,25,27,28,29,30}。 In step S2, subtract the used invoice set USED from the original blank invoice set ALLINVS to obtain the unused blank invoice set BLANK (that is, the first supplementary set) in the original blank invoice set ALLINVS, such as : BLANK=ALLINVS-USED={1,2,7,8,9,13,14,18,19,20,21,23,24,25,27,28,29,30}.

在步驟S3中,產生一組以該未被使用的空白發票集合BLANK為排序依據的連續序號集合Serial,該連續序號集合Serial之定義為:Serial={1,2,3...,n|n

Figure 108101197-A0101-12-0008-9
N0,n
Figure 108101197-A0101-12-0008-10
Size(BLANK)};例如:Serial={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18}。 In step S3, a set of consecutive serial number sets Serial based on the unused blank invoice set BLANK is generated. The definition of the serial number set Serial is: Serial={1,2,3...,n| n
Figure 108101197-A0101-12-0008-9
N0,n
Figure 108101197-A0101-12-0008-10
Size(BLANK)}; for example: Serial={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18}.

在步驟S4中,將該未被使用的空白發票集合BLANK減掉該連續序號集合Serial,以得到第二補集合G,該第二補集合G之定義為:G={Bi-Si|1

Figure 108101197-A0101-12-0008-11
i
Figure 108101197-A0101-12-0008-12
Size(BLANK)},其中,Bi為該未被使用的空白發票集合BLANK中的元素,Si為該連續序號集合Serial中的元素;例如:G={0,0,4,4,4,7,7,10,10,10,10,11,11,11,12,12,12,12}。 In step S4, the unused blank invoice set BLANK is subtracted from the continuous serial number set Serial to obtain a second supplementary set G, which is defined as: G={B i -S i | 1
Figure 108101197-A0101-12-0008-11
i
Figure 108101197-A0101-12-0008-12
Size(BLANK)}, where B i is the element in the unused blank invoice set BLANK, and S i is the element in the serial number set Serial; for example: G={0,0,4,4,4 ,7,7,10,10,10,10,11,11,11,12,12,12,12}.

在步驟S5中,令該未被使用的空白發票集合BLANK的元素依序根據所對應該第二補集合G中的重複元素進行分群,以得到分群集合Agg。例如:Agg={{1~2}1,{7~9}2,{13~14}3,{18~21}4,{23~25}5,{27~30}6}。 In step S5, the elements of the unused blank invoice set BLANK are sequentially grouped according to the repeated elements in the corresponding second supplementary set G to obtain the grouping set Agg. For example: Agg={{1~2} 1 ,{7~9} 2 ,{13~14} 3 ,{18~21} 4 ,{23~25} 5 ,{27~30} 6 }.

於本實施例中,該步驟S5係包括步驟A~步驟B。 In this embodiment, the step S5 includes steps A to B.

在步驟A中,令TrimG為該第二補集合G去除重複元素後的集合,其TrimG之定義為:TrimG={Trim(Gi)|1

Figure 108101197-A0101-12-0008-13
i
Figure 108101197-A0101-12-0008-14
Size(G),例如:TrimG={0,4,7,10,11,12}。 In step A, let TrimG be the set of the second complement set G after removing duplicate elements. The definition of TrimG is: TrimG={Trim(G i )|1
Figure 108101197-A0101-12-0008-13
i
Figure 108101197-A0101-12-0008-14
Size(G), for example: TrimG={0,4,7,10,11,12}.

在步驟B中,將該未被使用的空白發票集合BLANK的元素及該第二補集合G的元素一對一合併,已得到BG集合,該BG集合之定義為:BG={{BLANKi,Seriali}j|1

Figure 108101197-A0101-12-0009-15
i
Figure 108101197-A0101-12-0009-16
Size(BLANK),1
Figure 108101197-A0101-12-0009-17
j
Figure 108101197-A0101-12-0009-18
Size(TrimG)};例如:
Figure 108101197-A0101-12-0009-2
In step B, the elements of the unused blank invoice set BLANK and the elements of the second supplementary set G are merged one-to-one to obtain the BG set. The definition of the BG set is: BG={{BLANK i , Serial i } j |1
Figure 108101197-A0101-12-0009-15
i
Figure 108101197-A0101-12-0009-16
Size(BLANK), 1
Figure 108101197-A0101-12-0009-17
j
Figure 108101197-A0101-12-0009-18
Size(TrimG)}; for example:
Figure 108101197-A0101-12-0009-2

在步驟C中,對BG集合中資料進行彙整,以得到該分群集合Agg,該分群集合Agg之定義為:

Figure 108101197-A0101-12-0009-3
例如:Agg={{1~2}1,{7~9}2,{13~14}3,{18~21}4,{23~25}5,{27~30}6}。 In step C, the data in the BG set is aggregated to obtain the group set Agg, which is defined as:
Figure 108101197-A0101-12-0009-3
For example: Agg={{1~2} 1 ,{7~9} 2 ,{13~14} 3 ,{18~21} 4 ,{23~25} 5 ,{27~30} 6 }.

該步驟S5亦不限於該步驟A~C,只要該未被使用的空白發票集合BLANK的元素能夠依序根據所對應該第二補集合G中的重複元素進行分群即為本發明的精神所在。 The step S5 is not limited to the steps A~C, as long as the elements of the unused blank invoice set BLANK can be grouped sequentially according to the repeated elements in the corresponding second supplementary set G, this is the spirit of the present invention.

由上述可知,本發明透過產生與第一補集合對應的連續序號集合,再使該第一補集合減掉該連續序號集合,以得到第二補集合,並透過該第一補集合的元素依序對應的第二補集合的元素之關係,使該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群,其次,將本發明之中斷連續序列分群之系統與方法應用於電子發票未使用之字軌之分群統計上,即能 利用空白發票集合BLANK的元素依序對應第二補集合G的元素之關係,從以『億』為單位的電子發票的字軌資料中,快速地找出電子發票未使用之字軌。同樣地,在其他具有大量數字序列的情況中,也可正確且快速的計算出大量數字序列中空白未使用的部分。 As can be seen from the above, the present invention generates a second complement set by generating a continuous sequence number set corresponding to the first complement set, and then subtracting the continuous sequence number set from the first complement set, and through the elements of the first supplement set The relationship between the elements of the second complement set corresponding to the order, so that the elements of the first complement set are grouped sequentially according to the repeated elements in the corresponding second complement set, and secondly, the system of grouping interrupted continuous sequences of the present invention and The method is applied to the grouping statistics of unused word tracks of electronic invoices, that is, it can Using the elements of the blank invoice set BLANK to sequentially correspond to the elements of the second supplementary set G, the unused word tracks of electronic invoices can be quickly found from the track data of electronic invoices in units of "100 million". Similarly, in other cases with a large number of digital sequences, the blank and unused parts of the large number of digital sequences can also be calculated correctly and quickly.

上述實施例係用以例示性說明本發明之原理及其功效,而非用於限制本發明。任何熟習此項技藝之人士均可在不違背本發明之精神及範疇下,對上述實施例進行修改。因此本發明之權利保護範圍,應如後述之申請專利範圍所列。 The above embodiments are used to exemplify the principles and effects of the present invention, rather than to limit the present invention. Anyone who is familiar with this skill can modify the above embodiments without departing from the spirit and scope of the present invention. Therefore, the scope of protection of the rights of the present invention should be as listed in the scope of patent application mentioned later.

11‧‧‧接收模組 11‧‧‧Receiving module

12‧‧‧第一計算模組 12‧‧‧ First computing module

13‧‧‧排序序號模組 13‧‧‧Sequence number module

14‧‧‧第二計算模組 14‧‧‧Second computing module

15‧‧‧分群模組 15‧‧‧ Group module

Claims (8)

一種中斷連續序列分群之系統,係包括:接收模組,係接收一第一連續序列集合及至少一第一序列集合;第一計算模組,係用以將該第一連續序列集合減掉該至少一第一序列集合,以得到第一補集合;排序序號模組,係產生以該第一補集合為排序依據的連續序號集合;第二計算模組,係用以將該第一補集合減掉該連續序號集合,以得到第二補集合;以及分群模組,係依據該第二補集合,將該第一補集合進行分群;其中,該第一補集合的元素係依序對應該第二補集合中的元素,以令該分群模組將該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群。 A system for interrupting continuous sequence grouping includes: a receiving module to receive a first continuous sequence set and at least a first sequence set; a first calculation module to subtract the first continuous sequence set from the At least one first sequence set to obtain a first complement set; a sorting sequence number module, which generates a continuous sequence number set based on the first complement set as a sorting basis; a second calculation module, which is used to collect the first complement set Subtract the continuous sequence number set to obtain a second complement set; and a grouping module, group the first complement set according to the second complement set; wherein, the elements of the first complement set correspond in sequence The elements in the second complement set, so that the grouping module groups the elements in the first complement set according to the repeated elements in the second complement set in sequence. 如申請專利範圍第1項所述之系統,其中,該第一序列集合係為該第一連續序列集合中的子集合。 The system as described in item 1 of the patent application scope, wherein the first sequence set is a subset of the first continuous sequence set. 如申請專利範圍第2項所述之系統,其中,該第一補集合係為該第一連續序列集合的中斷連續序列集合。 The system as described in item 2 of the patent application scope, wherein the first complement set is an interrupted continuous sequence set of the first continuous sequence set. 如申請專利範圍第1項所述之系統,其中,該第一序列集合中的元素係為單一元素或連續序列元素。 The system as described in item 1 of the patent application scope, wherein the elements in the first sequence set are single elements or continuous sequence elements. 一種中斷連續序列分群之方法,係包括下列步驟:接收一第一連續序列集合及至少一第一序列集合;將該第一連續序列集合減掉該至少一第一序列集合,以得到第一補集合;產生以該第一補集合為排序依據的連續序號集合; 將該第一補集合減掉該連續序號集合,以得到第二補集合;以及依據該第二補集合,令該第一補集合進行分群;其中,該第一補集合的元素係依序對應該第二補集合中的元素,以令該第一補集合的元素依序根據所對應該第二補集合中的重複元素進行分群。 A method for interrupting continuous sequence grouping includes the following steps: receiving a first continuous sequence set and at least one first sequence set; subtracting the at least one first sequence set from the first continuous sequence set to obtain a first complement Set; generate a set of consecutive numbers based on the first supplementary set; Subtracting the serial number set from the first complement set to obtain a second complement set; and grouping the first complement set according to the second complement set; wherein the elements of the first complement set are paired in order The elements in the second complement set should be grouped according to the repeated elements in the second complement set in sequence. 如申請專利範圍第5項所述之方法,其中,該第一序列集合係為該第一連續序列集合中的子集合。 The method as described in item 5 of the patent application scope, wherein the first sequence set is a subset of the first continuous sequence set. 如申請專利範圍第6項所述之方法,其中,該第一補集合係為該第一連續序列集合的中斷連續序列集合。 The method according to item 6 of the patent application scope, wherein the first complement set is an interrupted continuous sequence set of the first continuous sequence set. 如申請專利範圍第5項所述之方法,其中,該第一序列集合中的元素係為單一元素或連續序列元素。 The method as described in item 5 of the patent application scope, wherein the elements in the first sequence set are single elements or continuous sequence elements.
TW108101197A 2019-01-11 2019-01-11 System of grouping for interrupted continuous serial and method thereof TWI694338B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
TW108101197A TWI694338B (en) 2019-01-11 2019-01-11 System of grouping for interrupted continuous serial and method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
TW108101197A TWI694338B (en) 2019-01-11 2019-01-11 System of grouping for interrupted continuous serial and method thereof

Publications (2)

Publication Number Publication Date
TWI694338B true TWI694338B (en) 2020-05-21
TW202026906A TW202026906A (en) 2020-07-16

Family

ID=71895928

Family Applications (1)

Application Number Title Priority Date Filing Date
TW108101197A TWI694338B (en) 2019-01-11 2019-01-11 System of grouping for interrupted continuous serial and method thereof

Country Status (1)

Country Link
TW (1) TWI694338B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050021426A1 (en) * 2003-07-25 2005-01-27 Fabien Leroux Invoice tracking
CN103870983A (en) * 2014-02-28 2014-06-18 浪潮软件集团有限公司 Electronic invoice safety management service system based on cloud computing and cryptographic technology
TWI447664B (en) * 2011-05-12 2014-08-01
US8924272B2 (en) * 2004-11-01 2014-12-30 Sap Se System and method for management and verification of invoices

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050021426A1 (en) * 2003-07-25 2005-01-27 Fabien Leroux Invoice tracking
US8924272B2 (en) * 2004-11-01 2014-12-30 Sap Se System and method for management and verification of invoices
TWI447664B (en) * 2011-05-12 2014-08-01
CN103870983A (en) * 2014-02-28 2014-06-18 浪潮软件集团有限公司 Electronic invoice safety management service system based on cloud computing and cryptographic technology

Also Published As

Publication number Publication date
TW202026906A (en) 2020-07-16

Similar Documents

Publication Publication Date Title
CN109902086B (en) Index creation method, device and equipment
CN109902071B (en) Service log storage method, system, device and equipment
CN109951290B (en) Time service authentication method, device and equipment for chain type account book
CN106446184A (en) Method and device for data processing of service system
CN105989129A (en) Real-time data statistic method and device
CN105045917A (en) Example-based distributed data recovery method and device
WO2019208484A1 (en) Secure aggregate sum system, secure computation device, secure aggregate sum method, and program
CN110061843B (en) Block height creating method, device and equipment in chain type account book
CN112119442B (en) Secret aggregation function calculation system, secret aggregation function calculation method, secret aggregation function calculation device, and recording medium
JP6973633B2 (en) Secret Aggregation Maximum Value System, Secret Aggregation Minimum Value System, Secret Computing Unit, Secret Aggregation Maximum Value Method, Secret Aggregation Minimum Value Method, and Program
CN107070645A (en) Compare the method and system of the data of tables of data
CN110059084A (en) A kind of date storage method, device and equipment
CN110019278A (en) A kind of data verification method, device and equipment
CN112733531A (en) Virtual resource allocation method and device, electronic equipment and computer storage medium
CN110232525B (en) Enterprise risk acquisition method, device, server and storage medium
TWI694338B (en) System of grouping for interrupted continuous serial and method thereof
CN107730390A (en) Data processing method and device, computer-readable medium, electronic equipment
WO2019208486A1 (en) Secure aggregate median value system, secure computation device, secure aggregate median value method, and program
WO2019221108A1 (en) Secret cross tabulation system, secret calculation device, secret cross tabulation method, and program
CN107784091B (en) Operation authority query method and terminal device
CN112217639A (en) Data encryption sharing method and device, electronic equipment and computer storage medium
CN115470241A (en) Aggregated data updating method and device based on mapping dictionary table
CN110008210A (en) A kind of index creation method, device and equipment
JP6613706B2 (en) Table design support apparatus, table design support method, and control program
CN114997109A (en) Receipt conversion method and device, computer equipment and storage medium