WO2014045318A1 - 圧縮プログラム、圧縮方法及び圧縮装置 - Google Patents

圧縮プログラム、圧縮方法及び圧縮装置 Download PDF

Info

Publication number
WO2014045318A1
WO2014045318A1 PCT/JP2012/005993 JP2012005993W WO2014045318A1 WO 2014045318 A1 WO2014045318 A1 WO 2014045318A1 JP 2012005993 W JP2012005993 W JP 2012005993W WO 2014045318 A1 WO2014045318 A1 WO 2014045318A1
Authority
WO
WIPO (PCT)
Prior art keywords
character string
compression
character
compression dictionary
order information
Prior art date
Application number
PCT/JP2012/005993
Other languages
English (en)
French (fr)
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 JP2014536411A priority Critical patent/JP6003995B2/ja
Priority to PCT/JP2012/005993 priority patent/WO2014045318A1/ja
Publication of WO2014045318A1 publication Critical patent/WO2014045318A1/ja
Priority to US14/656,290 priority patent/US9219497B2/en

Links

Images

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M7/00Conversion of a code where information is represented by a given sequence or number of digits to a code where the same, similar or subset of information is represented by a different sequence or number of digits
    • H03M7/30Compression; Expansion; Suppression of unnecessary data, e.g. redundancy reduction
    • H03M7/40Conversion to or from variable length codes, e.g. Shannon-Fano code, Huffman code, Morse code
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M7/00Conversion of a code where information is represented by a given sequence or number of digits to a code where the same, similar or subset of information is represented by a different sequence or number of digits
    • H03M7/30Compression; Expansion; Suppression of unnecessary data, e.g. redundancy reduction
    • H03M7/3084Compression; Expansion; Suppression of unnecessary data, e.g. redundancy reduction using adaptive string matching, e.g. the Lempel-Ziv method
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M7/00Conversion of a code where information is represented by a given sequence or number of digits to a code where the same, similar or subset of information is represented by a different sequence or number of digits
    • H03M7/30Compression; Expansion; Suppression of unnecessary data, e.g. redundancy reduction
    • H03M7/3084Compression; Expansion; Suppression of unnecessary data, e.g. redundancy reduction using adaptive string matching, e.g. the Lempel-Ziv method
    • H03M7/3091Data deduplication

Definitions

  • the present invention relates to a data compression technique or decompression technique.
  • the search performed in the above compression processing is performed by collating character information in the list with character information to be compressed, and character information in the list that matches the character information to be compressed is specified as a result of the collation. .
  • a range to be collated in the list is narrowed down using an index prepared in advance.
  • a compression code is assigned to a combination of character strings such as words, and the compression rate is improved by expressing two or more character strings with one compression code.
  • the search for the compression code assigned to the character string and the search for the compression code assigned to the combination including the character string overlap. It is done.
  • the search for a combination of character strings includes matching with a combination of character strings to which a compression code is assigned, and the character string to be checked is longer than the matching of the compression code assignment unit. The amount increases.
  • the object in the process of specifying a compression code assigned to a read character string, a search performed on a character string group and a search performed on a set of character string combinations
  • the object is to suppress the amount of processing performed in duplicate.
  • a compression program is included in a compression dictionary that associates a concatenated character string including a plurality of character strings with a compression code when the computer reads a plurality of character strings including a certain character string from a file to be compressed. That at least one of the concatenated character strings refers to the order information indicating whether or not the certain character string is included in the order of the certain character string in the plurality of character strings, and the order information includes In this case, a process of searching the compression dictionary using the plurality of character strings is executed.
  • a concatenated character string included in a compression dictionary that associates a concatenated character string including a plurality of character strings with a compression code is stored.
  • a concatenated character string included in a compression dictionary that associates a concatenated character string including a plurality of character strings with a compression code is stored.
  • the plurality of character strings refers to the order information indicating whether or not the certain character string is included in the order of the certain character string, and indicates that the order information includes
  • a compression method is used that searches the compression dictionary using the plurality of character strings.
  • the compression device includes a concatenated character string included in a compression dictionary that associates a concatenated character string including a plurality of character strings with a compression code when a plurality of character strings including a certain character string are read from a file to be compressed. That at least one of the reference information section refers to order information indicating whether or not to include the certain character string in the order of the certain character string in the plurality of character strings, and that the order information includes A search unit that searches the compression dictionary using the plurality of character strings.
  • FIG. 1 shows a functional configuration example of the computer 1.
  • FIG. 2 shows an example of the compression processing of the first embodiment.
  • FIG. 3 shows a flowchart example of the compression process.
  • FIG. 4 shows an example of the data structure of the aggregation table T5.
  • FIG. 5 shows an example of the data structure of the character string compression dictionary T1.
  • FIG. 6 shows an example of the data structure of the aggregation table T6.
  • FIG. 7 shows an example of the data structure of the linked character string compression dictionary T3.
  • FIG. 8 shows an example of a flowchart for generating the order information table T2.
  • FIG. 9 shows an example of the data structure of the order information table T2.
  • FIG. 10 shows an example of the data structure of the storage area for storing the conversion target data.
  • FIG. 10 shows an example of the data structure of the storage area for storing the conversion target data.
  • FIG. 11 shows an example of a flowchart of the conversion process.
  • FIG. 12 shows an example of a flowchart of the conversion process.
  • FIG. 13 shows an example of a flowchart of the conversion process.
  • FIG. 14 illustrates an example of compression processing according to the second embodiment.
  • FIG. 15 shows an example of the data structure of the order information table T41.
  • FIG. 16 shows an example of the data structure of the order information table T42.
  • FIG. 17 illustrates a flowchart example of the compression processing according to the second embodiment.
  • FIG. 18 shows a flowchart example of the generation process.
  • FIG. 19 is a flowchart illustrating a part of the conversion process according to the second embodiment.
  • FIG. 20 illustrates an example of compression processing according to the third embodiment.
  • FIG. 21 is a flowchart illustrating a part of the conversion process according to the third embodiment.
  • FIG. 22 is a flowchart illustrating a part of the conversion process according to the third embodiment.
  • FIG. 23 illustrates a flowchart example of the conversion process according to the fourth embodiment.
  • FIG. 24 illustrates a flowchart example of the conversion process according to the fourth embodiment.
  • FIG. 25 shows a hardware configuration example of the computer 1.
  • FIG. 26 shows a program configuration example of the computer 1.
  • FIG. 27 shows a configuration example of the system.
  • FIG. 1 shows a functional configuration example of the computer 1.
  • the computer 1 is a computer that executes compression processing.
  • the computer 1 includes a compression unit 11, an expansion unit 12 and a storage unit 13. If the computer 1 performs compression processing but does not perform expansion processing, the expansion unit 12 may be configured as an additional component.
  • the compression unit 11 includes a control unit 111, a generation unit 112, a reference unit 113, and a search unit 114.
  • control unit 111 causes the generation unit 112, the reference unit 113, and the search unit 114 to execute processing according to the procedure, and executes compression processing.
  • the generation unit 112 generates an order information table T2 indicating the order between character strings.
  • the generation unit 112 further indicates, for example, the correspondence between the character string compression dictionary T1 indicating the correspondence between the character string and the compression code, and the linked character string including a plurality of character strings to which the compression code is assigned, and the compression code.
  • a concatenated character string compression dictionary T3 and the like are generated. Details of the order information table T2, the character string compression dictionary T1, and the concatenated character string compression dictionary T3 will be described later.
  • the generation unit 112 stores the generated character string compression dictionary T1, the order information table T2, and the linked character string compression dictionary T3 in the storage unit 13.
  • the character string compression dictionary T1, the order information table T2, and the concatenated character string compression dictionary T3 may be stored in the storage unit 13 before processing the file to be compressed.
  • the character string compression dictionary T1, the order information table T2, and the linked character string compression dictionary T3 are acquired by communication, reading from a portable storage medium, and the like, and stored in the storage unit 13.
  • the generation unit 112 has an additional configuration.
  • the reference unit 113 acquires, for example, order information indicating the order between character strings from the order information table T2 under the control of the control unit 111.
  • the search unit 114 performs a character string search for the character string compression dictionary T1 and the connected character string compression dictionary T3, for example.
  • the search unit 114 specifies a character string that matches the character string to be searched among the character strings included in the character string compression dictionary T1.
  • the search unit 114 specifies a character string that matches the character string to be searched among the character strings included in the concatenated character string compression dictionary T3.
  • the control unit 111 executes a compression process using the processing results of the generation unit 112, the reference unit 113, and the search unit 114.
  • An example of compression processing executed by the control unit 111 is shown in FIG.
  • FIG. 2 shows an example of the compression processing of the first embodiment.
  • the file F1 to be compressed is compressed to generate a compressed file F2. Details of each procedure of the compression processing shown in FIG. 2 will be described later with reference to FIGS.
  • the control unit 111 sequentially reads out the file F1 to be compressed in units of character strings (S10).
  • FIG. 2 illustrates a group of character strings (character string W1, character string W2, and character string W3) that are continuous in the file F1 to be compressed.
  • the control unit 111 sequentially causes the search unit 114 to perform a search process using the read character string as a search target character string (S11).
  • the search unit 114 specifies a character string that matches the character string to be searched in the character string compression dictionary T1.
  • the control part 111 acquires a search result from the search part 114 (S12).
  • the search result is returned that the character string matching the character string to be searched is not included in the character string compression dictionary T1.
  • a compression code corresponding to the specified character string is returned as a search result.
  • the character string compression dictionary T1 further indicates the correspondence between the compression code and the code length of the compression code.
  • the control unit 111 acquires a code length corresponding to a compression code returned as a search result, and controls a writing position in the compressed file F2 according to the acquired code length.
  • the character string compression dictionary T1 further indicates a correspondence relationship between a character string and a pointer indicating the position of information regarding the character string in the order information table T2.
  • the control unit 111 uses a pointer corresponding to the character string specified by the search process.
  • the character string compression dictionary T1 may include both the code length of the compression code and a pointer indicating the position of the character string in the order information table T2.
  • the control unit 111 When the control unit 111 receives a search result of the compression code corresponding to the specified character string for a plurality of character strings read continuously, the control unit 111 refers to the order information table T2 in the reference unit 113. (S13).
  • the reference unit 113 determines whether or not the order of the character strings in the plurality of character strings specified by the control unit 111 is indicated in the order information table T2, and returns a determination result to the control unit 111 (S14).
  • the order information table T2 is, for example, a table indicating the number of each character string that can exist in the concatenated character string in the concatenated character string group registered in the concatenated character string compression dictionary T3.
  • the order information table T2 indicates whether each character string exists as the first character string or whether it exists as the second character string in any of the character strings included in the concatenated character string group. , ..., the presence / absence information is included.
  • the reference unit 113 may refer to the presence / absence information regarding each character string based on the pointer.
  • control unit 111 When the control unit 111 receives a determination result from the reference unit 113 that the order of the plurality of designated character strings is not indicated in the order information table T2, the control unit 111 selects any one of the plurality of designated character strings.
  • the compressed code received in S12 is written in the storage unit 13 (S15).
  • the control unit 111 also controls the writing position in the storage unit 13.
  • control unit 111 stores the character string searched by the search unit 114 even when a search result indicating that the character string matching the character string to be searched is not included in the character string compression dictionary T1 is received. Write to the unit 13 (S15).
  • control unit 111 When the control unit 111 receives a determination result indicating that a plurality of designated character strings are indicated in the order information table T2 from the reference unit 113, the control unit 111 concatenated character strings for the plurality of character strings determined by the reference unit 113.
  • the search unit 113 is made to search the compression dictionary T3 (S16).
  • the search unit 114 specifies a linked character string that matches a plurality of character strings to be searched in the linked character string compression dictionary T3.
  • the control part 111 acquires a search result from the search part 114 (S17).
  • the concatenated character string cannot be specified by the search, it is returned as a search result that the concatenated character string that matches the plurality of character strings to be searched is not included in the concatenated character string compression dictionary T3.
  • a concatenated character string can be specified by the search, a compression code corresponding to the specified concatenated character string is returned as a search result.
  • control unit 111 When the control unit 111 receives a search result indicating that a concatenated character string that matches a plurality of character strings to be searched is not included in the concatenated character string compression dictionary T3, the control unit 111 selects one of the specified character strings.
  • the compression code received in S12 for the column is written in the storage unit 13 (S15).
  • the control unit 111 writes the compressed code received in S17 into the storage unit 13 (S18).
  • a compression code is also assigned to a concatenated character string that is a combination of character strings registered in the character string compression dictionary T1. If the code length of the compression code assigned to the concatenated character string is smaller than the sum of the code lengths of the compression codes assigned to each of the plurality of character strings included in the concatenated character string, the compression rate for the concatenated character string Will improve.
  • the character string read from the file F1 to be compressed may be searched in both the character string compression dictionary T1 and the concatenated character string compression dictionary T3. If the corresponding compression code is found by searching the concatenated character string compression dictionary T3, the compression code obtained as a result of searching the character string compression dictionary T1 is not used, and the search processing to the character string compression dictionary T1 becomes useless. . When the corresponding compression code is not found in the search of the linked character string compression dictionary T3, the search process itself of the linked character string compression dictionary T3 is wasted.
  • the control unit 111 can suppress the search of the concatenated character string compression dictionary T3 according to the reference result of the order information table T2, and can suppress useless search processing.
  • the reference unit 113 can specify the character string to be referred to included in the order information table T2 by referring to the order information table T2 based on the pointer read from the character string compression dictionary T1. By using the pointer, the reference unit 113 can suppress the search with the character string to be referred to in the order information table T2.
  • the computer 1 can maintain the compression processing speed by reducing the processing amount required for the search in the concatenated character string compression dictionary T3 while improving the compression rate by assigning the compression code to the concatenated character string. .
  • FIG. 3 shows an example of a flowchart of compression processing.
  • the compression function is called by an operator input or an instruction by a program (S100)
  • preprocessing of the compression function is performed (S101).
  • the control unit 111 reads a list of character strings to which a compression code is assigned from the storage unit 13 into the work area.
  • the character string is, for example, character information constituting a unit such as a word or a phrase including one or more characters.
  • the character string may be information such as a code or a tag used in the system.
  • the length of the character string may be handled as a fixed length or a variable length.
  • the list of character strings read out in S101 includes a plurality of character strings such as words and phrases.
  • a plurality of character string lists may be stored in the storage unit 13, and one of them may be selected by an instruction.
  • a character string list specialized for the field to which the file F1 to be compressed belongs is prepared.
  • computer-related book data is compressed using a character string list that includes more computer terms than other character string lists.
  • words and phrases included in the character string list are selected based on, for example, a dictionary. For example, a character string list including words published in a computer terminology dictionary or a character string list including words published in a chemical terminology dictionary is selected. Further, when the document data is an address book or the like, a character string list including words listed in the place name dictionary is selected.
  • control unit 111 reads the file F1 to be compressed into the work area (S102).
  • the control unit 111 performs the processing of S102 to S107 in units of blocks obtained by dividing the compression target file F1 into blocks.
  • the control unit 111 performs a totaling process of character strings included in the data read in the process of S102 (S103).
  • control unit 111 further counts the number of appearances of combinations of a plurality of character strings. In this process, the control unit 111 may only extract combinations of character strings that have a large number of appearances.
  • the control unit 111 assigns a compression code to each character string according to the number of appearances for each character string, and generates a character string compression dictionary T1 (S104).
  • the control unit 111 further assigns a compression code to a combination of a plurality of character strings in accordance with the counting result in S103, and generates a linked character string compression dictionary T3.
  • the character string compression dictionary T1 indicates the correspondence between the character string and the compression code as described above.
  • the compression code is assigned according to the number of appearances for each character string, for example, according to a Huffman coding Huffman tree generation algorithm or an arithmetic compression compression code generation algorithm.
  • codes are assigned according to the order of the number of appearances of character strings included in the aggregation table. That is, a shorter compression code is assigned to a character string having a larger number of appearances.
  • a compression code having a length corresponding to the appearance probability of each character string is assigned. Also in arithmetic compression, a shorter compression code is assigned as the appearance probability is higher (as the number of appearances is larger).
  • the control unit 111 associates each generated compression code with a character string and stores it in the character string compression dictionary T1.
  • the concatenated character string compression dictionary T3 is also generated based on the same algorithm as the character string compression dictionary T1.
  • FIG. 4 shows an example of the data structure of the aggregation table T5.
  • the control unit 111 totals each character string using the total table T5 shown in FIG.
  • the tabulation table T5 shows, for example, the correspondence between each character string and the number of appearances of each character string in the file F1 to be compressed.
  • the tabulation table T5 may store, for example, information indicating the frequency instead of the number of appearances.
  • the tabulation table T5 includes each character string in the character string list read in S101.
  • character strings such as “Kawasaki City”, “Tokyo”, and “Yokohama City” are included, and the number of appearances counted for each character string is associated.
  • the control unit 111 In S104, the control unit 111 generates a character string compression dictionary T1 based on the aggregation table T5 of FIG.
  • FIG. 5 shows an example of the data structure of the character string compression dictionary T1.
  • the character string compression dictionary T1 shown in FIG. 5 associates character strings, code lengths, compression codes, and pointers with each other.
  • the character string included in the character string compression dictionary T1 includes each character string in the character string list read in S101, as in the total table T5.
  • the control unit 111 assigns a compression code to each character string based on the aggregation result stored in the aggregation table T5 after the aggregation processing in S103, and stores the compression code in association with each character string in the character string compression dictionary T1.
  • control unit 111 when storing in the character string compression dictionary T1, the control unit 111 also stores the code length of each compression code.
  • a pointer is also associated. Since the pointer is information generated by the process of S105, it will be described later in the description of the process of S105.
  • FIG. 6 shows an example of the data structure of the aggregation table T6.
  • the control unit 111 totals the connected character strings using the total table T6 shown in FIG.
  • the tabulation table T6 indicates, for example, a correspondence relationship between a connected character string and the number of appearances of the connected character string in the file F1 to be compressed. Similar to the aggregation table T5, the aggregation table T6 may store, for example, information indicating the frequency instead of the number of appearances.
  • the concatenated character string in the aggregation table T6 is, for example, a plurality of continuous character strings included in the compression target file F1.
  • the control unit 111 reads a character string continuous with the character string W1, the character string W2, and the character string W3 from the compression target file F1. Then, the control unit 111, for example, includes a concatenated character string CW1 composed of a character string W1 and a character string W2, a concatenated character string CW2 composed of a character string W2 and a character string W3, a concatenated character string composed of a character string W1, a character string W2, and a character string W3.
  • CW3 is registered in the aggregation table T6. If the reading of the character strings is repeated, the number of connected character strings registered in the aggregation table T6 increases. For example, the control unit 111 appears more than a certain number every time a predetermined number of character strings are read. The connected character string not to be processed is removed from the total table T6.
  • a concatenated character string such as “Miyamae-ku, Kawasaki-shi, Kanagawa” or “Nakahara-ku, Kawasaki-shi, Kanagawa” is registered in the tabulation table T6 by the counting process of the control unit 111.
  • “Miyamae Ward, Kawasaki City, Kanagawa Prefecture” is a concatenated character string including a plurality of character strings “Kanagawa Prefecture”, “Kawasaki City”, and “Miyamae Ward”.
  • the control unit 111 When the processing of S103 ends, the control unit 111 generates the order information table T2 based on the concatenated character string compression dictionary T3. In the process of S104, the control unit 111 generates a linked character string compression dictionary T3 based on the tabulation table T6 after the tabulation process of S103.
  • the control unit 111 assigns a compression code to each connected character string registered in the aggregation table T6 according to the number of appearances.
  • an algorithm for assigning a compression code an algorithm similar to the generation of the character string compression dictionary T1 can be used.
  • the control unit 111 may assign a compression code using the total results of both the total table T5 and the total table T6.
  • control unit 111 may separately perform the allocation of the compression code based on the aggregation table T5 and the allocation of the compression code based on the aggregation table T6. In that case, the control unit 111 gives an identifier indicating whether the compressed code is a compressed code registered in the character string compression dictionary T1 or a compressed code registered in the linked character string compression dictionary T3. To do.
  • FIG. 7 shows an example of the data structure of the linked character string compression dictionary T3.
  • a concatenated character string and a compression code assigned to the concatenated character string are associated with each other.
  • the concatenated character string included in the concatenated character string compression dictionary T3 is a concatenated character string registered in the aggregation table T6. Alternatively, it is a part of the concatenated character string registered in the concatenated character string compression dictionary T3.
  • FIG. 8 shows an example of a flowchart for generating the order information table T2.
  • the generation unit 112 performs preprocessing such as securing a storage area for storing the order information table T2 in the storage unit 13 (S201).
  • FIG. 9 shows an example of the data structure of the order information table T2.
  • the order information table T2 indicates the correspondence between the character string and the order information of the character string.
  • the character string order information is information indicating the order in which the character string appears in the concatenated character string registered in the concatenated character string compression dictionary T3.
  • the order information table T2 illustrated in FIG. 9 includes the connected character string registered in the connected character string compression dictionary T3 for each of the character string orders (first, second,..., Nth) in the connected character string. One of them includes information indicating whether or not the character string exists.
  • a storage area is secured according to a predetermined number n indicating what order is handled in the order information table T2. Further, the character string information in the order information table T2 may be removed after the order information table T2 is generated. This is because the correspondence between the character string and the order information is maintained by a pointer described later.
  • the generation unit 112 refers to the concatenated character string compression dictionary T3 and determines whether there is an unprocessed concatenated character string (S202). If there is an unprocessed linked character string as a result of the determination in S202 (S202: YES), the generation unit 112 reads the unprocessed linked character string from the linked character string compression dictionary T3 (S203). If there is no unprocessed linked character string as a result of the determination in S202 (S202: NO), the generation unit 112 notifies the control unit 111 that the generation process has ended, and ends the generation process (S210). .
  • the generating unit 112 determines whether or not there is an unprocessed character string among the concatenated character strings read in S203 (S204). If there is no unprocessed character string (S204: NO), the processing for the concatenated character string read in S203 has been completed, and thus the generation unit 112 performs the process of S202 again.
  • the sequence information table T2 is searched with the unprocessed character string (S205).
  • the generation unit 112 determines whether or not the character string used for the search in S205 is unregistered in the order information table T2 according to the search result in S205 (S206). If not registered in the order information table T2 (S206: YES), the generation unit 112 newly registers the character string determined as unprocessed in S204 in the order information table (S207). Further, the generation unit 112 stores the pointer indicating the storage position of the order information of the character string registered in S207 in the character string compression dictionary T1 shown in FIG.
  • a pointer corresponding to the character string is stored in the character string compression dictionary T1 shown in FIG. Pointers are not associated with some character strings in the character string compression dictionary T1.
  • Such a character string is a character string that does not exist in the concatenated character string registered in the concatenated character string compression dictionary T3.
  • the generation unit 112 determines the order based on the character string determined as unprocessed in S204.
  • the information table T2 is updated (S209). Specifically, the generation unit 112 includes the sequence information corresponding to the character string determined as unprocessed in S204, in the concatenated character string read in S203 of the character string determined as unprocessed in S204. Reference is made to presence / absence information corresponding to the order (indicating “present” or “absent”). The generation unit 112 updates the referenced presence / absence information to “exist”. When the presence / absence information indicates “exist”, the generation unit 112 may not perform the update. When the update process of S209 is completed, the generation unit 11 performs the determination process of S204 again.
  • control unit 111 compresses the data included in the file F1 to be compressed based on the character string compression dictionary T1 and the concatenated character string compression dictionary T3 generated in S104, and the order information table T2.
  • a process of converting to a code is performed (S106).
  • the control unit 111 causes the reference unit 113 and the search unit 114 to execute processing, and performs the conversion processing in S106.
  • a storage area for storing the processing results of the reference unit 113 and the search unit 114 is provided in the storage unit 13.
  • FIG. 10 shows an example of the data structure of the storage area for storing the conversion target data.
  • Storage areas L0, L1, L2 and L3 are shown in FIG.
  • the storage areas L1, L2, and L3 are each a storage area that can store n pieces of data, for example, and the storage area L0 is, for example, information that can identify n pieces of data (for example, 0 to n ⁇ 1). Value).
  • a character string is stored in the storage area L1
  • a pointer is stored in the storage area L2
  • a compression code is stored in the storage area L3.
  • FIG. 11, FIG. 12 and FIG. 13 show flowchart examples of the conversion process.
  • the control unit 111 performs pre-processing (S301).
  • the pre-processing in S301 includes, for example, the setting of the initial value of the counter value i stored in the storage area L0, the setting of the reading position of the character string from the compression target file F1, and the writing position of the compression code to the compression file F2. And so on.
  • the control unit 111 updates the counter value i (S302).
  • control unit 111 reads the character string from the designated read position in the compression target file F1, and stores the read character string in the i-th storage position of the storage area L1 (S303). When data is already written in the i-th storage position of the storage area L1, the control unit 111 overwrites the read character string. The control unit 111 further updates the read position from the file F1 to be compressed according to the length of the character string read in S303 (S304).
  • the control unit 111 causes the search unit 114 to search the character string compression dictionary T1 based on the character string read in S303 (S305).
  • the search unit 114 searches the character string compression dictionary T ⁇ b> 1 using the character string read in S ⁇ b> 303 and returns the search result to the control unit 111. If the character string matching the character string read in S303 can be specified in the character string compression dictionary T1, the search unit 114 uses the compression code associated with the specified character string as the search result. . In this case, the search result may include a pointer associated with the specified character string.
  • a character string that matches the character string read in S303 cannot be specified, a message to that effect is returned to the control unit 111.
  • the control unit 111 determines whether or not the character string has been specified based on the search result received from the search unit 114 (S306). If the search unit 114 can identify the character string (S306: YES), the compression code included in the search result is stored in the i-th position of the storage area L2 (S307). Next, the control unit 111 determines whether or not a pointer is included in the search result received from the search unit 114 (S308). If a pointer is included in the search result (S308: YES), the control unit 111 stores the pointer included in the search result at the i-th position in the storage area L3 (S309).
  • the control unit 111 determines whether or not a pointer is stored at the i + j-th position in the storage area L3 (S311).
  • the control unit 111 causes the reference unit 113 to store the order information table based on the pointer at the i + jth position in the storage area L3.
  • Reference of T2 is executed (S312).
  • the pointer at the i + jth position in the storage area L3 indicates the position in the order information table T2 of the order information for the character string stored at the i + jth position in the storage area L1.
  • the reference unit 113 refers to the presence / absence information regarding the j-th character string in the order information indicated by the pointer, and returns the reference result to the control unit 111.
  • the control unit 111 determines whether or not the reference result received from the reference unit 113 indicates “exist” (S313). When the reference result indicates “exist” (S313: YES), the control unit 111 determines whether or not the counter value j is less than a predetermined value (S314). If the counter value j is less than the predetermined value (S314: YES), the control unit 111 increments the counter value j (S315), and performs the process of S311 again.
  • the predetermined value may be a unique value or a value specified before a compression instruction. As a result of the determination in S314, the concatenated character string compression dictionary T3 is searched only when a predetermined number or more consecutive character strings match the order information.
  • control unit 111 When there is no pointer at the i + j-th position of the pointer storage area L3 at the i + j-th position in the storage area L3 (S311: NO), and when the reference result indicates “absent” (S313: NO), the control unit 111 , S321 is performed. The process of S321 will be described later.
  • the control unit 111 performs the process of S316.
  • the control unit 111 causes the search unit 114 to search the concatenated character string compression dictionary T3 based on the character string stored in the i + 1th to i + jth positions in the storage area L1 (S316).
  • the search unit 114 stores the character string stored in the (i + 1) th position in the storage area L1, the character string stored in the (i + 2) th position in the storage area L1,..., Stored in the (i + j) th position in the storage area L1. Based on the concatenated character string continuous with the character string, the concatenated character string compression dictionary T3 is searched. The search unit 114 returns the search result of the linked character string compression dictionary T3 to the control unit 111. When the concatenated character string that matches the concatenated character string instructed by the control unit 111 is specified in the concatenated character string compression dictionary T3, the search unit 114 searches for a compression code associated with the specified concatenated character string. As a result. In addition, when the connected character string that matches the connected character string instructed by the control unit 111 cannot be specified in the connected character string compression dictionary T3, the search unit 114 sets the search result to that effect.
  • the control unit 111 determines whether the concatenated character string stored in the i + 1th to i + jth positions in the storage area L1 is included in the concatenated character string compression dictionary T3. It is determined whether or not (S317).
  • the search result is a compression code
  • the control unit 111 causes the character string that matches the concatenated character string stored in the i + 1 to i + jth positions in the storage area L1 to be stored in the concatenated character string compression dictionary T3. It is determined that it is included (S317: YES). In this case, the control unit 111 writes the compression code included in the search result at the writing position of the compressed file F2 (S318).
  • control unit 111 updates the writing position based on the code length of the compression code written in S318 (S319), and updates the counter value i (S320).
  • the control unit 111 stores the linked character string in the linked character string compression dictionary T3. It is determined that there is no matching connected character string (S317: NO). In that case, the control unit 111 writes the compression code stored at the (i + 1) th position in the storage area L3 at the write position of the compressed file F2 (S321). In S321, when the compression code is not stored in the i + 1 th position of the storage area L3, the control unit 111 writes the character string stored in the i + 1 th position of the storage area L1, for example.
  • control unit 111 writes the character string stored at the (i + 1) th position in the storage area L1 after compressing it based on another compression algorithm.
  • the control unit 111 updates the write position according to the code length of the compression code written in S321 (S322), and increments the counter value i (S323).
  • the control unit 111 updates S322 in accordance with the length of the written character string, and when the compressed code generated by another compression algorithm is written in S321. Then, S322 is updated according to the code length of the compressed code.
  • the control unit 111 determines whether or not the data in the compression target file F1 has been read (S324). If there is unread data in the file F1 to be compressed (S324: NO), the control unit 111 executes the process of S302 again. If the data in the file F1 to be compressed has been read (S324: YES), the control unit 111 determines whether the storage area L1 is the i th EOF (file end point identifier). (S325). If the i-th stored information in the storage area L1 is not EOF (S325: NO), the control unit 111 performs the process of S310 again. If the i-th information stored in the storage area L1 is EOF (S325: YES), the conversion process is terminated and the process returns to the flow of FIG. 3 (S326).
  • the control unit 111 stores the compressed file F2 (S107).
  • the control unit 111 displays a screen in which the file name and the file storage location are specified, and the specified file name is specified in the file storage location specified in the input according to the displayed screen.
  • the called compression function is closed (S108).
  • FIG. 14 shows an example of compression processing according to the second embodiment.
  • the control unit 111 refers to the order information table T4 before searching the character string compression dictionary T1 with the read character string (S19), and performs character string compression according to the reference result (S20).
  • the search of the dictionary T1 is suppressed. Thereby, useless search of the character string compression dictionary T1 is suppressed.
  • the control unit 111 writes the read character string in the compressed file F2 (S21). Instead of writing the character string in S21, the read character string may be compressed by another compression algorithm and written to the compressed file F2.
  • the character string compression dictionary T1 is searched, the same compression process as in the first embodiment is performed.
  • the order information table T4 is a table generated based on the character string compression dictionary T1, and reflects the order of character information in each character string included in the character string compression dictionary T1.
  • the order information table T4 includes a record for each type of character information. Each record indicates the number of character information of the record in the character string included in the character string compression dictionary T1. More specifically, there is an item for each order such as whether or not it exists as the first character information in the character string, whether or not it exists as the second character information. In each item, “exist” is indicated if any one of the character strings included in the character string compression dictionary T1 is applicable, and “absent” is indicated if none of the character strings is applicable.
  • FIG. 15 shows a data configuration example of the order information table T41 in Japanese as an example of the order information table T4.
  • a record is provided for each piece of character information such as “river”, “ku”,.
  • Each record further includes an item corresponding to each position (first character, second character,...) In the character string.
  • “river” record “exist (1)” is indicated by the first character item, and “absent (0)” is indicated by the second character item.
  • the character string compression dictionary T1 includes a character string including “river” as the first character, but does not include a character string including “river” as the second character.
  • the order information table T4 is referred to based on part or all of the character information in the read character string.
  • the order information table T41 based on the character string “Kawasaki city”, “existence” is indicated in the first character item of the character information “river” record, and the character information “saki” record 2 “Existence” is indicated in the item of the character, and “existence” is indicated in the item of the third character of the record of the character information “city”.
  • “Kawasaki city” is included in the character string compression dictionary T1
  • the control unit 111 does not suppress the search (S11) of the character string compression dictionary T1.
  • FIG. 16 shows a data configuration example of the order information table T42 in Japanese as an example of the order information table T4.
  • a record is provided for each piece of character information such as “a”, “e”,.
  • Each record further includes an item corresponding to each position (first character, second character,...) In the character string.
  • the character string compression dictionary T1 includes a character string including “a” as the second character, but does not include a character string including “a” as the third character.
  • “man” may be included in the character string compression dictionary T1, but “sea” is not included.
  • Example 1 an address is used as an example in the character string in the character string compression dictionary T1 and the concatenated character string in the concatenated character string compression dictionary T3.
  • a place name indicating a narrow area is successively written from a place name showing a wide area.
  • a place name indicating a wide area is used continuously with a place name indicating a plurality of narrow areas.
  • a place name indicating a wide area “Tokyo” is used in combination with “Akiruno City” and “Musashino City” which are place names indicating a narrow area. That is, there are concatenated character strings “Akiruno City, Tokyo” and “Musashino City, Tokyo”.
  • the concatenated character string as one long character string in the order information table T4
  • handling the long character string increases the size of the order information table T4.
  • the character string that is commonly combined for multiple character strings such as the English notation of the address described above
  • the length of the first character string will be different.
  • the position of the character string used in common varies. Then, since the number of locations determined as “existing” by the commonly used character strings is increased, it may be difficult to obtain the suppression effect by referring to the order table T4.
  • the generation unit 112 included in the computer 1 illustrated in FIG. 1 includes, for example, an order information table T4 indicating the order between character information in addition to the order information table T2, the character string compression dictionary T1, and the connected character string compression dictionary T3. And so on.
  • the generation unit 112 stores the generated order information table T4 in the storage unit 13.
  • the reference unit 113 refers to the order information table T2 and the order information table T4 in response to an instruction from the control unit 111.
  • the control unit 111 suppresses the search process of the search unit 114 according to the reference results of the order information table T2 and the order information table T4.
  • FIG. 17 shows a flowchart example of the compression processing of the second embodiment.
  • the control unit 111 After the processing of S101, the control unit 111 generates the order information table T4 (S109).
  • the control unit 111 returns to the flow of S102 shown in FIG. Details of the generation processing (S109) of the order information table T4 will be described with reference to FIG.
  • FIG. 18 shows an example of a flowchart of the generation process.
  • the control unit 111 reads definition information about the position in the character string (S601).
  • the definition information includes, for example, a definition for designating how many characters (length of character information) from what character (start position) in the character string. According to an example of the definition, “one character” is designated from “first character”.
  • the definition information includes one or more definitions. As an example of definition information, a definition specifying “1 character” from “first character”, a definition specifying “1 character” from “second character”, and a “1 character” from “third character” Definition information including a definition that specifies “one character” from “fourth character” may be used. Also, the designation of the start position and the length of character information included in each definition is determined by, for example, either a count from the beginning of the character string or a count from the end of the character string.
  • control unit 111 secures a storage area for storing the order information table T4 in the storage unit 13 (S602). In the process of S602, the control unit 111 further initializes the presence / absence information included in the order information table T4 to information indicating “absence”.
  • the order information table T4 includes, for example, items corresponding to the definitions included in the definition information acquired in S601. Therefore, for example, the order information table T4 includes at least items of the number of definitions included in the definition information. Since each item indicates “present” or “absent” information, each item includes one or more bits of data (for example, each field includes one bit, “1” indicates “present”, “0”) Indicates “absence”). Further, for example, the order information table T4 includes records of the number of types of character information. The number of character information types is determined according to, for example, the number of character code types included in the character code system used and the length of the character information defined in the definition information acquired in S601.
  • the number of types of character information is, for example, a number obtained by raising the number of types of character codes included in the character code system by the length of the defined character information. Further, for example, the start position of each record corresponding to each character information is indicated by the character information itself.
  • the size of the order information table T4 and the start position of the record corresponding to the character information will be described using an ASCII code system as an example.
  • Each character code of the ASCII code system is expressed by 1 byte.
  • the character information is represented by 2 bytes.
  • the start position of the order information record for character information expressed in 2 bytes is a numerical value corresponding to the 2-byte character information from the start position of the order information table T4.
  • the ASCII code corresponding to the character information “AA” is 0x4141, and “16705” in decimal.
  • the start position of the record of the order information regarding the character information “AA” is a position of 16705 bytes from the start position of the order information table T4.
  • the size of each record is 1 byte.
  • the storage area used in the order information table T4 is 16 KB which is 1/4 of 64 KB.
  • the control unit 111 sequentially reads out character strings from the character string list read into the work area in S101 of FIG. 3 (S603).
  • the control unit 111 causes the reference unit 113 to execute the reference process of the order information table T4.
  • the reference unit 113 selects an unprocessed definition from the definitions acquired in S601, refers to the order information table T4 using the selected definition, and acquires presence / absence information (S604).
  • the reference unit 113 acquires presence / absence information on the character information at the position indicated by the selected definition in the character string read in S603.
  • the reference unit 113 determines whether the acquired presence / absence information indicates “exist” (S605). When the acquired presence / absence information indicates “absence” (S605: NO), the reference unit 113 updates the presence / absence information of the corresponding part of the order information table T4 to “existence” (S606). If the presence / absence information acquired in S604 indicates “presence” (S605: YES) or if the processing in S606 is performed, it is determined whether there is an unprocessed definition (S607). If there is an unprocessed definition in the determination of S607 (S607: NO), the process of S604 is performed again based on the unprocessed definition.
  • the control unit 111 When the character string read in S603 is subjected to a reference process with each definition included in the definition information (S607: YES), the control unit 111 does not have an unprocessed character string in the character string list. It is judged (S608). If it is determined in S608 that there is an unprocessed character string (S608: NO), the process returns to S603, and the control unit 111 reads the unprocessed character string again. If it is determined in S608 that there is no unprocessed character string (S608: YES), the control unit 111 returns to S102 in FIG. 3 (S609).
  • the procedure of the conversion process to the compression code is different as shown in FIG.
  • the conversion procedure in the second embodiment is a procedure in which a part of the conversion procedure shown in FIGS. 11 to 13 is changed.
  • FIG. 19 is a flowchart illustrating a part of the conversion process according to the second embodiment.
  • the control unit 111 causes the reference unit 113 to refer to the order information table T4 (S401).
  • the reference unit 113 refers to the order table T4 for character information included in the character string stored at the i-th position in the storage area L1, based on the position of the character information in the character string. Further, which position in the character string is referred to is determined by the definition information used when generating the order information table T4.
  • Example of processing using the order information table T41 For example, referring to the order information table T41 based on the character string “Kawasaki City”, it is determined based on the order information table T41 whether the character information “river” exists at the position “first character”. That is, the first existence information of the record of the character information “river” is confirmed. In this case, the presence / absence information is “1”, which indicates “existence”.
  • the reference unit 113 performs the same processing on the character information “Saki” and “City”.
  • the control unit 111 determines whether there is a possibility that the character string is stored in the character string compression dictionary T1 based on the reference result of the reference unit 113 (S402). That is, the control unit 111 determines whether “existence” is indicated for any combination of the character information and the position in the character string for which the order information table T4 is referenced. As a result of the determination in S402, if there is a possibility that the character string is stored in the character string compression dictionary T1 (S402: YES), the control unit 111 causes the search unit 114 to search the character string compression dictionary T1. Is executed.
  • control unit 111 causes the search unit 114 to execute a search when any combination of the character information and the position in the character string for which the order information table T4 is referred to indicates “exist”. .
  • the control unit 111 returns to the process of S306 in FIG. 11 (S404).
  • the control unit 111 returns to the process of S306 in FIG. 11 without executing the search of the character string compression dictionary. .
  • the character string compression dictionary T1 it is possible to prevent the character string compression dictionary T1 from being searched unnecessarily even for character strings that are not registered in the character string compression dictionary T1.
  • FIG. 20 shows an example of the compression process of the third embodiment.
  • the control unit 111 causes the order information table T4 to be referred to a plurality of times (S19, S20), and as a result of the reference, there is a possibility that the order information table T4 is continuously included in the character string compression dictionary T1.
  • the order information table T2 is referred to based on those continuous character strings (S23, S24). That is, the control unit 111 skips the search of the character string compression dictionary T1 and determines whether or not it is registered in the concatenated character string compression dictionary T3 first (S16, S17). As a result, the concatenated character string compression is performed. If it is not included in the dictionary T3, the character string compression dictionary T1 is searched (S11, S12).
  • the linked character string compression dictionary T3 and the character string compression dictionary T1 tend to be searched redundantly. According to the third embodiment, although it is registered in the concatenated character string compression dictionary T3, searching the character string compression dictionary T1 is suppressed.
  • FIG. 21 and FIG. 22 show a flowchart example of a part of the conversion process of the third embodiment.
  • the control unit 111 causes the reference unit 113 to refer to the order information table T4 (S327).
  • the reference unit 113 refers to the order information table T4 based on the position in the character string of the character information regarding the character information included in the character string stored at the i-th position in the storage area L1.
  • the control unit 111 determines whether or not there is a possibility that the character string stored at the i-th position in the storage area L1 is stored in the character string compression dictionary T1. (S328).
  • the criterion for determination is the same as S402 in FIG.
  • the control unit 111 determines whether or not there is a pointer at the i + j-th position in the storage area L3 (S331). As a result of the determination in S331, if there is a pointer in the reference unit 113 (S331: YES), the control unit 111 refers to the order information table T2 based on the pointer (S332), and if there is no pointer (S331: NO), stores it.
  • the order information table T2 is referred to based on the i + jth character string in the region L1 (S333).
  • the reference unit 113 refers to the order information for the jth character string in the concatenated character string.
  • the control unit 111 performs compression processing of the i-th character string in the storage area L1.
  • the control unit 111 causes the search unit 114 to search the character string compression dictionary T1 using the i-th character string in the storage area L1 (S337).
  • the control unit 111 determines whether or not a matching character string is specified in the character string compression dictionary T1 by the search by the search unit 114 (S338).
  • the control unit 111 stores a compression code associated with the specified character string in the character string compression dictionary T1 in the storage area.
  • the i-th position of L2 is stored (S340). Further, the control unit 111 determines whether or not a pointer is associated with the specified character string in the character string compression dictionary T1 (S341). If there is a pointer (S341: YES), the pointer is stored. Store in the i-th position of the area L3 (S342).
  • S342 is performed or when the pointer is not associated with the specified character string in the character string compression dictionary T1 (S341: NO)
  • the control unit 111 returns to the process of S321 shown in FIG.
  • a database may contain a list of similar data. Furthermore, the number of character strings included in each data to be enumerated may be fixed. In such a case, the matching with the concatenated character string may be confirmed in units of data including a plurality of character strings, rather than collating while shifting one character string at a time. In the fourth embodiment, for example, it is confirmed whether or not the character strings are continuously read and stored in the linked character string compression dictionary T3 before the character string compression dictionary T1 is searched for each character string. Is done.
  • FIG. 23 and FIG. 24 show a flowchart example of the conversion process of the fourth embodiment.
  • the control unit 111 performs preprocessing (S501).
  • the process of S501 is, for example, the same process as S301 illustrated in FIG.
  • the control unit 111 reads a character string from the compression target file F1 (S502), and returns to the process of S502 until a line feed code is read (S503: NO).
  • the control unit 111 causes the reference unit 113 to refer to the order information table T2 (S504).
  • the reference unit 113 refers to the order information included in the order information table T2 for each of the plurality of character strings read by repeating S502.
  • the control unit 111 determines whether or not each of the read character strings is consistent with the order information referred to by the reference unit 113 (S505). If any of the plurality of character strings matches the order information (S505: YES), the control unit 111 causes the search unit 114 to search the linked character string compression dictionary T3 with the plurality of read character strings ( S506). The control unit 111 determines whether or not a concatenated character string that matches the read character strings is registered in the concatenated character string compression dictionary T3 according to the search result of the search unit 114 (S507).
  • the control unit 111 selects one character string from a plurality of character strings (S511). Next, the control unit 111 causes the reference unit 113 to refer to the order information table T4 for character information included in the selected character string (S512). As a result of the reference, the control unit 111 determines whether the referenced character information is consistent with the order information (S513).
  • the control unit 111 When any of the referred character information matches the order information (S513: YES), the control unit 111 causes the search unit 114 to search the character string compression dictionary T1 with the selected character string (S514). The control unit 111 determines whether there is a character string that matches the selected character string according to the search result of the character string compression dictionary T1 (S515). If there is a matching character string (S515: YES), the control unit 111 writes the compression code associated with the matching character string by the character string compression dictionary T1 at the writing position of the compressed file F2 (S517). .
  • the control unit 111 When at least one of the referred character information does not match the order information (S513: NO), or when there is no character string that matches the character string compression dictionary T1 (S515: NO), the control unit 111 The selected character string is written into the writing position of the compressed file F2 (S516).
  • the control unit 111 determines whether or not there is an unprocessed character string in the compression target file F1. Determination is made (S509). If there is no unprocessed character string (S509: YES), the control unit 111 ends the conversion process (S510). If there is an unprocessed character string (S509: NO), the control unit 111 performs the process of S502 again.
  • FIG. 25 shows a hardware configuration example of the computer 1 used in the first to fourth embodiments.
  • the computer 1 includes, for example, a processor 301, a RAM (Random Access Memory) 302, a ROM (Read Only Memory) 303, a drive device 304, a storage medium 305, an input interface (I / F) 306, an input device 307, an output interface (I / F) 308, an output device 309, a communication interface (I / F) 310, a SAN (Storage Area Network) interface (I / F) 311, a bus 312 and the like. Each piece of hardware is connected via a bus 312.
  • a processor 301 includes, for example, a processor 301, a RAM (Random Access Memory) 302, a ROM (Read Only Memory) 303, a drive device 304, a storage medium 305, an input interface (I / F) 306, an input device 307, an output interface (I / F) 308, an output device 309,
  • the RAM 302 is a readable / writable memory device, and for example, a semiconductor memory such as SRAM (Static RAM) or DRAM (Dynamic RAM), or a flash memory even if not a RAM is used.
  • the ROM 303 includes a PROM (Programmable ROM).
  • the drive device 304 is a device that performs at least one of reading and writing of information recorded in the storage medium 305.
  • the storage medium 305 stores information written by the drive device 304.
  • the storage medium 305 is a storage medium such as a hard disk, a flash memory such as an SSD (Solid State Drive), a CD (Compact Disc), a DVD (Digital Versatile Disc), or a Blu-ray disc.
  • the computer 1 includes a drive device 304 and a storage medium 305 for each of a plurality of types of storage media.
  • the input interface 306 is connected to the input device 307 and transmits the input signal received from the input device 307 to the processor 301.
  • the output interface 308 is connected to the output device 309 and causes the output device 309 to execute output in accordance with an instruction from the processor 301.
  • the communication interface 310 controls communication via the network 3.
  • the SAN interface 311 controls communication with a storage device connected to the computer 1 via a storage area network.
  • the input device 307 is a device that transmits an input signal according to an operation.
  • the input signal is, for example, a key device such as a keyboard or a button attached to the main body of the computer 1, or a pointing device such as a mouse or a touch panel.
  • the output device 309 is a device that outputs information according to the control of the computer 1.
  • the output device 309 is, for example, an image output device (display device) such as a display, or an audio output device such as a speaker.
  • an input / output device such as a touch screen is used as the input device 307 and the output device 309.
  • the input device 307 and the output device 309 may be integrated with the computer 1 or may be an apparatus that is not included in the computer 1 and is connected to the computer 1 from the outside, for example.
  • the processor 301 reads the program stored in the ROM 303 or the storage medium 305 to the RAM 302 and performs the processing of the compression unit 11 or the processing of the decompression unit 12 according to the procedure of the read program.
  • the RAM 302 is used as a work area of the processor 301.
  • the function of the storage unit 13 is that the ROM 303 and the storage medium 305 are program files (such as an application program 24, middleware 23, and OS 22 described later) and data files (compression target data file, compression file, decompression target data file, decompression file, etc.) )
  • the RAM 302 is used as a work area of the processor 301.
  • the program read by the processor 301 will be described with reference to FIG.
  • FIG. 26 shows a configuration example of the program of the computer 1.
  • the processor 301 operates in accordance with the procedure in accordance with the OS 22 to control / manage the hardware 21 group, whereby processing according to the application program 24 and the middleware 23 is executed in the hardware group 21. Further, in the computer 1, the middleware 23 or the application program 24 is read into the RAM 302 and executed by the processor 301.
  • the processor 301 performs processing based on the compression function included in the middleware 23 or the application program 24, whereby the function of the compression unit 11 is realized (by controlling the hardware group 21 based on the OS 22). . Further, the processor 301 performs processing based on the decompression function included in the middleware 23 or the application program 24, thereby realizing the function of the decompression unit 12 (controlling the hardware group 21 based on the OS 22). Is done.
  • Each of the compression function and the decompression function may be defined in the application program 24 itself, or may be a function of the middleware 23 that is executed by being called according to the application program 24.
  • FIG. 27 shows a configuration example of an apparatus in a system including the computers of the first to fourth embodiments.
  • the system in FIG. 27 includes a computer 1 a, a computer 1 b, a base station 2, and a network 3.
  • the computer 1a is connected to the network 3 connected to the computer 1b by at least one of wireless and wired.
  • the compression unit 11 and the decompression unit 12 shown in FIG. 1 may be included in either the computer 1a or the computer 1b shown in FIG.
  • the computer 1b may include the compression unit 11 illustrated in FIG. 1, the computer 1a may include the decompression unit 12, the computer 1b may include the compression unit 11 illustrated in FIG. 1, and the computer 1a may include the decompression unit 12. Further, both the computer 1 a and the computer 1 b may include the compression unit 11 and the expansion unit 12.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

 一側面においては、読みだした文字列に割り当てられた圧縮符号を特定する処理において、文字列群に対して行なわれる検索と、文字列の組み合わせの集合に対して行なわれる検索とで、重複して行なわれる処理量を抑制することを目的とする。 一態様では、コンピュータにより、ある文字列を含む複数の文字列を圧縮対象のファイルから読み出した場合に、文字列を複数含む連結文字列と圧縮符号とを対応付ける圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、前記複数の文字列中の前記ある文字列の順序で、前記ある文字列を含むか否かを示す順序情報の参照を行ない、前記順序情報が含む旨を示す場合に、前記複数の文字列による前記圧縮辞書の検索を行なう、処理を実行する。

Description

圧縮プログラム、圧縮方法及び圧縮装置
 本発明は、データの圧縮技術または伸張技術に関する。
 ハフマン符号化やLZ78などの圧縮アルゴリズムを用いて、文字や単語などの文字情報に対して圧縮符号を割り当てて圧縮を行なう方法がある。これらの圧縮アルゴリズムに基づく圧縮処理では、圧縮符号が割り当てられた文字情報のリストを用意し、圧縮対象の文字情報に合致する文字情報でリスト内を検索し、検索の結果得られた文字情報に対応付けられた圧縮符号を用いて圧縮データを生成する処理が行なわれる。
 上記の圧縮処理で行なわれる検索は、リスト内の文字情報と圧縮対象の文字情報との照合により行なわれ、照合の結果として、圧縮対象の文字情報と合致するリスト内の文字情報が特定される。リスト内の文字情報と照合を行なう前に、予め用意したインデックスを用いて、リスト内で照合対象となる範囲を絞り込むことも行なわれる。
特開2012-142024号公報 特開平5-224878号公報
 さらに、単語などの文字列の組み合わせに対して圧縮符号を割り当てて、2以上の文字列を1つの圧縮符号で表現することによって、圧縮率が向上する。しかしながら、圧縮対象のファイルから読み出した文字列について圧縮を行なう場合に、その文字列に割り当てられた圧縮符号の検索と、その文字列を含む組み合わせに対して割り当てられた圧縮符号の検索とが重複して行なわれる。特に、文字列の組み合わせについての検索は、圧縮符号を割り当てられた文字列の組み合わせとの照合を含み、照合対象の文字列が圧縮符号の割り当て単位の照合よりも長くなるため、検索に要する処理量が増大する。
 本発明の一側面においては、読みだした文字列に割り当てられた圧縮符号を特定する処理において、文字列群に対して行なわれる検索と、文字列の組み合わせの集合に対して行なわれる検索とで、重複して行なわれる処理量を抑制することを目的とする。
 一態様では、圧縮プログラムが、コンピュータに、ある文字列を含む複数の文字列を圧縮対象のファイルから読み出した場合に、文字列を複数含む連結文字列と圧縮符号とを対応付ける圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、前記複数の文字列中の前記ある文字列の順序で、前記ある文字列を含むか否かを示す順序情報の参照を行ない、前記順序情報が含む旨を示す場合に、前記複数の文字列による前記圧縮辞書の検索を行なう、処理を実行させる。
 一態様では、コンピュータが、ある文字列を含む複数の文字列を圧縮対象のファイルから読み出した場合に、文字列を複数含む連結文字列と圧縮符号とを対応付ける圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、前記複数の文字列中の前記ある文字列の順序で、前記ある文字列を含むか否かを示す順序情報の参照を行ない、前記順序情報が含む旨を示す場合に、前記複数の文字列による前記圧縮辞書の検索を行なう、ことを実行する圧縮方法が用いられる。
 一態様では、圧縮装置は、ある文字列を含む複数の文字列を圧縮対象のファイルから読み出した場合に、文字列を複数含む連結文字列と圧縮符号とを対応付ける圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、前記複数の文字列中の前記ある文字列の順序で前記ある文字列を含むか否かを示す順序情報の参照を行なう参照部と、前記順序情報が含む旨を示す場合に、前記複数の文字列による前記圧縮辞書の検索を行なう検索部と、を含む。
 一側面においては、文字列群に対して行なわれる検索と、文字列の組み合わせの集合に対して行なわれる検索とで、重複して行なわれる処理量を抑制することができる。
図1は、コンピュータ1の機能構成例を示す。 図2は、実施例1の圧縮処理の例を示す。 図3は、圧縮処理のフローチャート例を示す。 図4は、集計テーブルT5のデータ構造例を示す。 図5は、文字列圧縮辞書T1のデータ構造例を示す。 図6は、集計テーブルT6のデータ構造例を示す。 図7は、連結文字列圧縮辞書T3のデータ構造例を示す。 図8は、順序情報テーブルT2生成のフローチャート例を示す。 図9は、順序情報テーブルT2のデータ構造例を示す。 図10は、変換対象データを格納する記憶領域のデータ構造例を示す。 図11は、変換処理のフローチャート例を示す。 図12は、変換処理のフローチャート例を示す。 図13は、変換処理のフローチャート例を示す。 図14は、実施例2の圧縮処理の例を示す。 図15は、順序情報テーブルT41のデータ構造例を示す。 図16は、順序情報テーブルT42のデータ構造例を示す。 図17は、実施例2の圧縮処理のフローチャート例を示す。 図18は、生成処理のフローチャート例を示す。 図19は、実施例2の変換処理の一部のフローチャート例を示す。 図20は、実施例3の圧縮処理の例を示す。 図21は、実施例3の変換処理の一部のフローチャート例を示す。 図22は、実施例3の変換処理の一部のフローチャート例を示す。 図23は、実施例4の変換処理のフローチャート例を示す。 図24は、実施例4の変換処理のフローチャート例を示す。 図25は、コンピュータ1のハードウェア構成例を示す。 図26は、コンピュータ1のプログラム構成例を示す。 図27は、システムの構成例を示す。
 本発明の実施形態について、適宜図面を用いて下記に説明する。
[実施例1]
 図1は、コンピュータ1の機能構成例を示す。コンピュータ1は、圧縮処理を実行するコンピュータである。コンピュータ1は、圧縮部11、伸張部12および記憶部13を含む。コンピュータ1が圧縮処理を行なう一方で、伸張処理を行なわないならば、伸張部12を付加的構成としてもよい。圧縮部11は、制御部111、生成部112、参照部113および検索部114を含む。
 制御部111は、例えば、手順に沿って生成部112、参照部113及び検索部114に処理を実行させ、圧縮処理を実行する。生成部112は、例えば、文字列間の順序を示す順序情報テーブルT2を生成する。生成部112は、さらに、例えば、文字列と圧縮符号との対応関係を示す文字列圧縮辞書T1、および圧縮符号が割り当てられた文字列を複数含む連結文字列と圧縮符号との対応関係を示す連結文字列圧縮辞書T3などを生成する。順序情報テーブルT2、文字列圧縮辞書T1および連結文字列圧縮辞書T3の詳細については後述する。また、生成部112は、生成した文字列圧縮辞書T1、順序情報テーブルT2および連結文字列圧縮辞書T3を、記憶部13に格納する。
 また、文字列圧縮辞書T1、順序情報テーブルT2および連結文字列圧縮辞書T3が、圧縮対象のファイルに対して処理を行なう前に、記憶部13に記憶されることとしてもよい。この場合、文字列圧縮辞書T1、順序情報テーブルT2および連結文字列圧縮辞書T3は、通信や可搬記憶媒体からの読み出しなどにより取得され、記憶部13に記憶される。文字列圧縮辞書T1、順序情報テーブルT2および連結文字列圧縮辞書T3が予め記憶部13に記憶される場合においては、生成部112は付加的構成となる。
 参照部113は、例えば、制御部111の制御に応じて順序情報テーブルT2から、文字列間の順序を示す順序情報を取得する。また、検索部114は、例えば、文字列圧縮辞書T1および連結文字列圧縮辞書T3に対して、文字列検索を行なう。例えば、検索部114は、文字列圧縮辞書T1に含まれる文字列のうち、検索対象の文字列に合致する文字列を特定する。また、例えば、検索部114は、連結文字列圧縮辞書T3に含まれる文字列のうち、検索対象の文字列に合致する文字列を特定する。
 制御部111は、上記の生成部112、参照部113および検索部114の処理結果を用いて、圧縮処理を実行する。制御部111による実行される圧縮処理の例が図2に示される。
 図2は、実施例1の圧縮処理の例を示す。図2においては、圧縮対象のファイルF1が圧縮されて、圧縮ファイルF2が生成される。図2に示される圧縮処理の各手順の詳細については、図3~13などを用いて後述される。
 制御部111は、圧縮対象のファイルF1から、文字列単位で順次読み出しを行なう(S10)。図2においては、圧縮対象のファイルF1内で連続する文字列群(文字列W1、文字列W2および文字列W3)が例示されている。制御部111は、順次、読みだした文字列を検索対象の文字列として、検索部114に検索処理を実行させる(S11)。S11において、検索部114は、文字列圧縮辞書T1内で検索対象の文字列に合致する文字列を特定する。そして、制御部111は、検索部114から検索結果を取得する(S12)。検索により文字列を特定できない場合には、検索対象の文字列に合致する文字列が文字列圧縮辞書T1に含まれない旨が、検索結果として返される。検索により文字列が特定できた場合には、特定された文字列に対応する圧縮符号が、検索結果として返される。
 一例として、文字列圧縮辞書T1は、さらに、圧縮符号と、その圧縮符号の符号長との対応関係を示す。制御部111は、例えば、検索結果として返される圧縮符号に対応する符号長を取得し、取得した符号長に応じて圧縮ファイルF2への書き込み位置を制御する。他の一例として、文字列圧縮辞書T1は、さらに、文字列と、順序情報テーブルT2におけるその文字列に関する情報の位置を示すポインタとの対応関係を示す。制御部111は、例えば、後述の処理(S13)において、検索処理で特定された文字列に対応するポインタを用いる。文字列圧縮辞書T1は、圧縮符号の符号長と、文字列の順序情報テーブルT2における位置を示すポインタとの双方を含んでよい。
 制御部111は、連続して読みだした複数の文字列について、特定された文字列に対応する圧縮符号の検索結果を受けた場合には、参照部113に、順序情報テーブルT2の参照を実行させる(S13)。参照部113は、制御部111から指定された複数の文字列における文字列の順序が、順序情報テーブルT2に示されているか否かを判定し、制御部111に判定結果を返す(S14)。順序情報テーブルT2は、例えば、連結文字列圧縮辞書T3に登録された連結文字列群において、各文字列は連結文字列内の何番目に存在しうるかを示すテーブルである。すなわち、順序情報テーブルT2は、各文字列について、連結文字列群に含まれるいずれかの文字列において、1番目の文字列として存在するか否か、2番目の文字列として存在するか否か、・・・という存否の情報を含む。例えば、叙述したように、文字列圧縮辞書T1からポインタも読み出される場合には、参照部113は各文字列に関する存否の情報を、ポインタに基づいて参照してもよい。
 制御部111は、指定された複数の文字列の順序が順序情報テーブルT2に示されていない旨の判定結果を参照部113から受けると、指定した複数の文字列のうちのいずれかの文字列についてS12で受けた圧縮符号を、記憶部13に書き込む(S15)。制御部111は、記憶部13への書き込み位置についても制御する。
 また、制御部111は、検索対象の文字列に合致する文字列が文字列圧縮辞書T1に含まれない旨の検索結果を受けた場合にも、検索部114に検索させた文字列を、記憶部13に書き込む(S15)。
 制御部111は、指定された複数の文字列が順序情報テーブルT2に示されている旨の判定結果を参照部113から受けると、参照部113に判定された複数の文字列についての連結文字列圧縮辞書T3の検索を検索部113に実行させる(S16)。S16において、検索部114は、連結文字列圧縮辞書T3内で検索対象の複数の文字列に合致する連結文字列を特定する。そして、制御部111は、検索部114から検索結果を取得する(S17)。検索により連結文字列を特定できない場合には、検索対象の複数の文字列に合致する連結文字列が連結文字列圧縮辞書T3に含まれない旨が、検索結果として返される。検索により連結文字列が特定できた場合には、特定された連結文字列に対応する圧縮符号が、検索結果として返される。
 制御部111は、検索対象の複数の文字列に合致する連結文字列が連結文字列圧縮辞書T3に含まれない旨の検索結果を受けると、指定した複数の文字列のうちのいずれかの文字列についてS12で受けた圧縮符号を、記憶部13に書き込む(S15)。一方、制御部111は、特定された連結文字列に対応する圧縮符号が検索結果として返された場合には、S17で受けた圧縮符号を記憶部13に書き込む(S18)。
 上述の通り、実施例1の圧縮処理においては、文字列圧縮辞書T1に登録された文字列同士の組み合わせである連結文字列に対しても圧縮符号が割り当てられている。連結文字列に割り当てる圧縮符号の符号長が、連結文字列に含まれる複数の文字列のそれぞれに対して割り当てられる圧縮符号の符号長の和よりも小さければ、連結文字列に対しての圧縮率が向上する。
 連結文字列に対して圧縮符号を割り当てることとすると、圧縮対象のファイルF1から読み出した文字列が、文字列圧縮辞書T1と連結文字列圧縮辞書T3との双方において検索されることがある。連結文字列圧縮辞書T3の検索で対応する圧縮符号が見つかると、文字列圧縮辞書T1を検索した結果得られる圧縮符号は使用されないため、文字列圧縮辞書T1への検索処理が無駄となってしまう。連結文字列圧縮辞書T3の検索で対応する圧縮符号が見つからない場合には、連結文字列圧縮辞書T3の検索処理そのものが無駄となってしまう。さらには、連結文字列は複数の文字列の組み合わせであるので、検索対象の文字列と合致するか否かの照合処理の処理量は、文字列同士の照合処理よりも大きくなる。上述の通り、制御部111は、順序情報テーブルT2の参照結果に応じて連結文字列圧縮辞書T3の検索を抑止し、無駄な検索処理を抑えることができる。
 また、参照部113は、順序情報テーブルT2の参照を文字列圧縮辞書T1から読み出したポインタに基づいて行なうことにより、順序情報テーブルT2に含まれる参照対象の文字列を特定できる。ポインタを用いることにより、参照部113は、順序情報テーブルT2の参照対象の文字列での検索を抑制できる。
 すなわち、コンピュータ1は、連結文字列に圧縮符号を割り当てることで圧縮率を向上させつつ、連結文字列圧縮辞書T3内の検索に要する処理量を減らすことにより、圧縮処理速度を維持することができる。
 以下に、図2に示す実施例1の圧縮処理の手順を、図面に示したフローチャート及びデータ構造を参照しつつ、より詳細に説明する。
  図3は、圧縮処理のフローチャート例を示す。操作者の入力やプログラムによる指示により、圧縮機能が呼び出される(S100)と、圧縮機能の前処理が行なわれる(S101)。S101の処理において、制御部111は、記憶部13から、圧縮符号が割り当られる文字列のリストをワークエリアに読み出す。文字列は、例えば、1または複数の文字を含む単語や文節などの単位を構成する文字情報である。また、文字列は、システム内で用いられるコードや、タグなどの情報であってもよい。文字列の長さは、固定長として取り扱っても可変長として取り扱ってもよい。
 S101で読み出される文字列のリストは、単語や文節などの文字列を複数含む。文字列のリストが記憶部13に複数記憶され、そのいずれかが指示により選択されてもよい。その場合、例えば、圧縮対象のファイルF1の属する分野に特化した文字列リストが用意される。例えば、コンピュータ関連の書籍データに対し、他の文字列リストよりもコンピュータ用語を多く含む文字列リストを用いた圧縮が行なわれる。また、文字列リストに含まれる単語や文節は、例えば辞典に基づき選択される。例えば、コンピュータ用語辞典に掲載された単語を含む文字列リストや、化学用語辞典に掲載された単語を含む文字列リストなどが選択される。また、文書データが住所録などである場合には、地名辞典に掲載された単語を含む文字列リストなどが選択される。
 次に、制御部111は、圧縮対象のファイルF1をワークエリアに読み出す(S102)。圧縮対象のファイルF1のサイズが大きくワークエリアに読み出せない場合には、制御部111は、圧縮対象のファイルF1をブロック分割して得られるブロック単位で、S102~S107の処理を行なう。次に制御部111は、S102の処理で読み出されたデータに含まれる文字列の集計処理を行なう(S103)。
 S103において、さらに、制御部111は、複数の文字列による組み合わせの出現回数を集計する。この処理において、制御部111は、出現回数が多い文字列の組み合わせを抽出するのみでもよい。
 S103の集計処理においては、文字列リストに含まれる各文字列の圧縮対象のファイルF1における出現回数がカウントされる。S103の処理後、制御部111は、文字列ごとの出現回数に応じて、各文字列に圧縮符号を割り当てて、文字列圧縮辞書T1を生成する(S104)。S104において、制御部111は、さらに、S103の集計結果に応じて、複数の文字列の組み合わせに対しても圧縮符号を割り当てて、連結文字列圧縮辞書T3を生成する。文字列圧縮辞書T1は、上述のとおり、文字列と圧縮符号との対応関係を示す。文字列ごとの出現回数に応じた圧縮符号の割り当ては、例えば、ハフマン符号化のハフマン木生成アルゴリズムや、算術圧縮の圧縮符号生成アルゴリズムに従って割り当てられる。ハフマン符号化のハフマン木生成アルゴリズムでは、集計テーブルに含まれる文字列の出現回数の順序に応じて符号の割り当てを行なう。すなわち、出現回数が多い文字列ほど短い圧縮符号が割り当てられる。また、算術圧縮では、各文字列の出現確率に応じた長さの圧縮符号が割り当てられる。算術圧縮においても出現確率が大きいほど(出現回数が多いほど)短い圧縮符号が割り当てられる。制御部111は、生成された各圧縮符号を文字列に対応付けて、文字列圧縮辞書T1に格納する。連結文字列圧縮辞書T3も、文字列圧縮辞書T1と同様のアルゴリズムに基づいて生成される。
 図4は、集計テーブルT5のデータ構造例を示す。S103において、制御部111は、図4に示す集計テーブルT5を用いて各文字列の集計を行なう。集計テーブルT5は、例えば、各文字列と、各文字列の圧縮対象のファイルF1内における出現回数との対応関係を示す。集計テーブルT5は、出現回数でなく、例えば、頻度を示す情報を格納してもよい。例えば、集計テーブルT5には、S101で読みだした文字列リスト内の各文字列が含まれる。図4の例においては、「川崎市」、「東京都」、「横浜市」などの文字列が含まれ、それぞれの文字列について集計された出現回数が対応付けられている。
 S104において、制御部111は、図4の集計テーブルT5に基づいて文字列圧縮辞書T1を生成する。図5は、文字列圧縮辞書T1のデータ構造例を示す。図5に示す文字列圧縮辞書T1は、文字列、符号長、圧縮符号及びポインタを互いに関連付ける。文字列圧縮辞書T1に含まれる文字列は、集計テーブルT5と同様、S101で読みだした文字列リスト内の各文字列が含まれる。制御部111は、S103の集計処理後の集計テーブルT5に格納された集計結果に基づいて、各文字列に圧縮符号を割り当て、各文字列に対応づけて文字列圧縮辞書T1に格納する。制御部111は、さらに、文字列圧縮辞書T1に格納する際に、各圧縮符号の符号長も併せて格納する。文字列圧縮辞書T1において、さらに、ポインタも関連付けられているが、ポインタはS105の処理で生成する情報であるので、S105の処理の説明において後述する。
 図6は、集計テーブルT6のデータ構造例を示す。S103において、制御部111は、図6に示す集計テーブルT6を用いて連結文字列の集計を行なう。集計テーブルT6は、例えば、連結文字列と、連結文字列の圧縮対象のファイルF1内での出現回数との対応関係を示す。集計テーブルT5と同様、集計テーブルT6も、出現回数でなく、例えば、頻度を示す情報を格納してもよい。集計テーブルT6内の連結文字列は、例えば、圧縮対象のファイルF1内に含まれる連続する複数の文字列である。
 一例として、制御部111が、文字列W1、文字列W2、文字列W3と連続する文字列を圧縮対象のファイルF1から読み出したとする。すると、制御部111は、例えば、文字列W1および文字列W2による連結文字列CW1、文字列W2および文字列W3による連結文字列CW2、文字列W1、文字列W2及び文字列W3による連結文字列CW3を集計テーブルT6に登録する。文字列の読み出しを繰り返すと、集計テーブルT6に登録される連結文字列の数が増大することとなるので、制御部111は、例えば、文字列を所定数読みだすたびに、ある一定数以上出現しない連結文字列は、集計テーブルT6から除くなどの処理を行なう。
 制御部111の集計処理により、例えば、図6に示すように、集計テーブルT6に、「神奈川県川崎市宮前区」や「神奈川県川崎市中原区」などの連結文字列が登録され、それぞれの出現回数と対応づけられる。「神奈川県川崎市宮前区」は、「神奈川県」、「川崎市」及び「宮前区」という複数の文字列を含んだ連結文字列である。
 S103の処理が終了すると、制御部111は、連結文字列圧縮辞書T3に基づいて、順序情報テーブルT2を生成する。S104の処理においては、制御部111は、S103の集計処理後の集計テーブルT6に基づいて、連結文字列圧縮辞書T3を生成する。制御部111は、集計テーブルT6に登録された各連結文字列に対し、出現回数に応じて圧縮符号を割り当てる。圧縮符号を割り当てるアルゴリズムは、文字列圧縮辞書T1生成と同様のアルゴリズムを用いることができる。制御部111は、集計テーブルT5と集計テーブルT6との両方の集計結果を用いて、圧縮符号の割り当てを行なってもよい。また、制御部111は、集計テーブルT5に基づく圧縮符号の割り当てと、集計テーブルT6に基づく圧縮符号の割り当てとを別々に行なってもよい。その場合には、制御部111は、圧縮符号に対し、文字列圧縮辞書T1に登録される圧縮符号であるか、連結文字列圧縮辞書T3に登録される圧縮符号であるかを示す識別子を付与する。
 図7は、連結文字列圧縮辞書T3のデータ構造例を示す。連結文字列圧縮辞書T3は、連結文字列と、連結文字列に割り当てられた圧縮符号とが対応付けられている。連結文字列圧縮辞書T3に含まれる連結文字列は、集計テーブルT6に登録された連結文字列である。もしくは、連結文字列圧縮辞書T3に登録された連結文字列のうちの一部である。
 図3の説明に戻る。S104の処理が終了すると、制御部111は、生成部112に、順序情報テーブルT2の生成を実行させる(S105)。図8は、順序情報テーブルT2生成のフローチャート例を示す。生成部112は、順序情報テーブルT2の生成を指示される(S200)と、順序情報テーブルT2を記憶する記憶領域を記憶部13に確保するなどの前処理を行なう(S201)。
 図9は、順序情報テーブルT2のデータ構造例を示す。順序情報テーブルT2は、文字列と、その文字列の順序情報との対応関係を示す。文字列の順序情報とは、その文字列が連結文字列圧縮辞書T3に登録された連結文字列において出現する順序を示す情報である。図9に例示する順序情報テーブルT2は、連結文字列における文字列の順番(1番目、2番目、・・・n番目)のそれぞれについて、連結文字列圧縮辞書T3に登録された連結文字列のいずれかに、その文字列が存在するか否かを示す情報を含む。図9に例示する順序情報テーブルT2においては、連結文字列圧縮辞書T3に登録された連結文字列のいずれか少なくとも1つがその文字列を含めば、「存在」を示す「1」が格納される。その一方で、連結文字列圧縮辞書T3に登録されたいずれの連結文字列もその文字列を含まない場合には、「不在」を示す「0」が格納される。図9の例によれば、文字列「川崎市」を2番目の文字列として含む連結文字列が、連結文字列圧縮辞書T3に登録されている。その一方で、文字列「川崎市」を1番目や3番目に含む連結文字列は、連結文字列圧縮辞書T3に登録されていない。
 S201の処理においては、何番目までの順序を順序情報テーブルT2で扱うかを示す所定数nに応じて、記憶領域が確保される。また、順序情報テーブルT2における文字列の情報は、順序情報テーブルT2が生成された後に取り除かれてもよい。これは、文字列と順序情報との対応関係が、後述のポインタにより維持されるためである。
 S201の処理を終えると、生成部112は、連結文字列圧縮辞書T3を参照し、未処理の連結文字列が存在するか否かを判定する(S202)。S202の判定の結果、未処理の連結文字列が存在する場合(S202:YES)は、生成部112は、未処理の連結文字列を連結文字列圧縮辞書T3から読み出す(S203)。S202の判定の結果、未処理の連結文字列が存在しない場合(S202:NO)は、生成部112は、生成処理が終了した旨を制御部111に通知し、生成処理を終了する(S210)。
 生成部112は、S203の処理を行なうと、S203で読みだした連結文字列のうち、未処理の文字列が存在するか否かを判定する(S204)。未処理の文字列が存在しない場合(S204:NO)には、S203で読みだした連結文字列についての処理が完了しているので、生成部112は、再度S202の処理を行なう。
 S204の判定で、未処理の文字列が存在する場合(S204:YES)には、未処理の文字列で順序情報テーブルT2内を検索する(S205)。次に、生成部112は、S205の検索結果に応じて、S205の検索に用いた文字列が順序情報テーブルT2に未登録であるか否かを判定する(S206)。順序情報テーブルT2に未登録である場合(S206:YES)には、生成部112は、S204で未処理と判定された文字列を順序情報テーブルに新たに登録する(S207)。さらに、生成部112は、S207で登録した文字列の順序情報の格納位置を示すポインタを、S207で登録した文字列と対応付けて図5に示す文字列圧縮辞書T1に格納する(S208)。図5に示す文字列圧縮辞書T1には、文字列に対応するポインタが格納される。文字列圧縮辞書T1中の一部の文字列については、ポインタが対応付けられない。そのような文字列は、連結文字列圧縮辞書T3に登録された連結文字列内に存在しない文字列である。
 S208が終了するか、S205において検索した文字列が順序情報テーブルに登録済みである場合(S206:NO)には、生成部112は、S204で未処理と判定された文字列に基づいて、順序情報テーブルT2の更新を行なう(S209)。具体的には、生成部112は、S204で未処理と判定された文字列に対応する順序情報のうち、S204で未処理と判定された文字列のS203で読み出された連結文字列内で順番に相当する存否情報(「存在」または「不在」を示す)を参照する。生成部112は、参照した存否情報を「存在」に更新する。存否情報が「存在」を示す場合には、生成部112が更新を行なわないこととしてもよい。S209の更新処理を終えると、生成部11は、再度S204の判定処理を行なう。
 S105の処理が終了すると、制御部111は、S104で生成された文字列圧縮辞書T1および連結文字列圧縮辞書T3、ならびに順序情報テーブルT2に基づいて、圧縮対象のファイルF1に含まれるデータを圧縮符号に変換する処理を行なう(S106)。制御部111は、参照部113および検索部114に処理を実行させて、S106の変換処理を行なう。S106の変換処理において、参照部113および検索部114の処理結果などを格納する記憶領域が記憶部13に設けられる。
 図10は、変換対象データを格納する記憶領域のデータ構造例を示す。記憶領域L0、L1、L2およびL3が図10に示される。記憶領域L1、L2,L3は、例えば、それぞれn個のデータを格納可能な記憶領域であり、記憶領域L0は、例えば、n個のデータを識別可能な情報(例えば、0~n-1の値)を格納する記憶領域である。図10は、一例として、記憶領域L1には文字列が格納され、記憶領域L2にはポインタが格納され、記憶領域L3には圧縮符号が格納される。図10のようなデータ構造とすることにより、例えば、プログラムに「記憶領域のi番目のデータを取得する」手順が示されている場合に、「神奈川県」という文字列のデータへのアクセスが可能となる。
 制御部111によるS106の処理を詳細に説明する。
 図11、図12及び図13は、変換処理のフローチャート例を示す。S106の変換処理が開始される(S300)と、制御部111は前処理を実行する(S301)。S301の前処理とは、例えば、記憶領域L0に格納されるカウンタ値iの初期値のセット、圧縮対象のファイルF1からの文字列の読み出し位置のセット、圧縮ファイルF2への圧縮符号の書き込み位置のセットなどである。制御部111は、例えば、i=0(「=」は代入演算子)などとセットする。次に、制御部111は、カウンタ値iの更新を行なう(S302)。S302においては、制御部111は、iがn以上となり、記憶領域L1、L2およびL3の範囲を超えた値を示す場合に、i=i-n(「=」は代入演算子)とセットして、カウンタ値を更新する。
 次に制御部111は、圧縮対象のファイルF1内の指定された読み出し位置から文字列を読み出し、読みだした文字列を記憶領域L1のi番目の格納位置に格納する(S303)。記憶領域L1のi番目の格納位置に既にデータが書き込まれている場合には、制御部111は、読みだした文字列を上書きする。制御部111は、さらに、S303で読みだした文字列の長さに応じて、圧縮対象のファイルF1からの読出し位置を更新する(S304)。
 制御部111は、S303で読みだした文字列に基づいて、検索部114に文字列圧縮辞書T1を検索させる(S305)。検索部114は、制御部111の指示に応じて、S303で読みだした文字列で文字列圧縮辞書T1を検索し、検索結果を制御部111に返す。検索部114は、文字列圧縮辞書T1内で、S303で読み出された文字列に合致する文字列を特定できた場合には、特定した文字列に対応付けられた圧縮符号を検索結果とする。この場合、検索結果として、特定した文字列に対応付けられたポインタを含んでもよい。一方、S303で読み出された文字列に合致する文字列を特定できない場合には、その旨を制御部111に検索結果として返す。
 次に制御部111は、検索部114から受けた検索結果に基づき、文字列を特定できたか否かを判定する(S306)。検索部114が文字列を特定できた場合(S306:YES)には、検索結果に含まれる圧縮符号を記憶領域L2のi番目の位置に格納する(S307)。次に、制御部111は、検索部114から受けた検索結果にポインタが含まれるか否かを判定する(S308)。検索結果にポインタが含まれている場合(S308:YES)には、制御部111は、検索結果に含まれるポインタを、記憶領域L3のi番目の位置に格納する(S309)。
 S309の処理を終えると、制御部111は、次に記憶領域L0に格納されるカウンタ値jのセットを行なう(S310)。S306において、検索部114が文字列を特定できない旨の検索結果を受けたと判定した場合(S306:NO)や、S308で検索結果にポインタが含まれていない場合(S308:NO)にも、制御部111は、S310の処理を行なう。S310においては、j=1(「=」は代入演算子)とセットされる。
 次に、制御部111は、記憶領域L3のi+j番目の位置にポインタが格納されているか否かを判定する(S311)。記憶領域L3のi+j番目の位置にポインタが格納されている場合(S311:YES)に、制御部111は、参照部113に、記憶領域L3のi+j番目の位置のポインタに基づいて、順序情報テーブルT2の参照を実行する(S312)。記憶領域L3のi+j番目の位置のポインタは、記憶領域L1のi+j番目の位置に記憶された文字列についての順序情報の順序情報テーブルT2における位置を示す。S312において、参照部113は、ポインタが示す順序情報のうち、j番目の文字列に関する存否情報を参照し、参照結果を制御部111に返す。
 制御部111は、参照部113から受ける参照結果が「存在」を示すか否か判定する(S313)。参照結果が「存在」を示す場合(S313:YES)には、制御部111は、カウンタ値jが所定値未満であるか否か判定する(S314)。カウンタ値jが所定値未満であれば(S314:YES)、制御部111は、カウンタ値jをインクリメントして(S315)、さらにS311の処理を再度行なう。所定値は、固有の値であってもよいし、圧縮指示前に指定される値であってもよい。S314の判定が行われることにより、所定数以上連続する文字列が順序情報と整合した場合のみ、連結文字列圧縮辞書T3の検索が行なわれる。
 記憶領域L3のi+j番目の位置にポインタ記憶領域L3のi+j番目の位置にポインタが無い場合(S311:NO)、参照結果が「不在」を示す場合(S313:NO)には、制御部111は、S321の処理を行なう。S321の処理については後述する。カウンタ値jが所定値以上である場合(S314:NO)に、制御部111はS316の処理を行なう。S316において、制御部111は、検索部114に、記憶領域L1のi+1番目からi+j番目の位置に格納された文字列に基づく、連結文字列圧縮辞書T3の検索を実行させる(S316)。検索部114は、記憶領域L1のi+1番目の位置に格納された文字列、記憶領域L1のi+2番目の位置に格納された文字列、・・・記憶領域L1のi+j番目の位置に格納された文字列と連続させた連結文字列に基づいて、連結文字列圧縮辞書T3を検索する。検索部114は、連結文字列圧縮辞書T3の検索結果を制御部111に返す。検索部114は、制御部111に指示された連結文字列に合致する連結文字列を連結文字列圧縮辞書T3内で特定した場合には、特定した連結文字列に対応付けられた圧縮符号を検索結果とする。また、検索部114は、制御部111に指示された連結文字列に合致する連結文字列を連結文字列圧縮辞書T3内で特定できない場合には、その旨を検索結果とする。
 制御部111は、検索部114から受けた検索結果に基づいて、記憶領域L1のi+1番目からi+j番目の位置に格納された文字列による連結文字列が、連結文字列圧縮辞書T3に含まれるか否かを判断する(S317)。検索結果が圧縮符号である場合には、制御部111は、記憶領域L1のi+1番目からi+j番目の位置に格納された文字列による連結文字列に合致する文字列が連結文字列圧縮辞書T3に含まれると判断する(S317:YES)。この場合、制御部111は、検索結果に含まれる圧縮符号を、圧縮ファイルF2の書き込み位置に書き込む(S318)。さらに、制御部111は、S318で書き込んだ圧縮符号の符号長に基づいて書込み位置を更新し(S319)、カウンタ値iを更新する(S320)。S320のカウンタ値iの更新は、制御部111がi=i+j(「=」は代入演算子)とカウンタ値iに値を代入することにより行なわれる。
 検索結果に、検索を指示された連結文字列に合致する連結文字列を連結文字列圧縮辞書T3内で特定できない旨を示される場合には、制御部111は、連結文字列圧縮辞書T3内に合致する連結文字列なしと判断する(S317:NO)。その場合、制御部111は、記憶領域L3のi+1番目の位置に格納された圧縮符号を、圧縮ファイルF2の書き込み位置に書き込む(S321)。S321において、記憶領域L3のi+1番目の位置に圧縮符号が格納されていない場合には、制御部111は、例えば、記憶領域L1のi+1番目の位置に格納された文字列を書き込む。もしくは、制御部111は、記憶領域L1のi+1番目の位置に格納された文字列を他の圧縮アルゴリズムに基づいて圧縮してから書き込む。S321の処理後、制御部111は、S321で書き込んだ圧縮符号の符号長に応じて書込み位置を更新し(S322)、カウンタ値iをインクリメントする(S323)。制御部111は、S321で文字列を書き込んだ場合には、書き込んだ文字列の長さに応じてS322の更新を行ない、S321で別の圧縮アルゴリズムにより生成された圧縮符号を書き込んだ場合には、その圧縮符号の符号長に応じてS322の更新を行なう。
 S320またはS323によりカウンタ値iが更新されると、制御部111は、圧縮対象のファイルF1内のデータを読み出し終わったか否かを判断する(S324)。圧縮対象のファイルF1内に読み出していないデータがある場合(S324:NO)には、制御部111は再度S302の処理を実行する。また、圧縮対象のファイルF1内のデータを読み出して終わった場合(S324:YES)には、制御部111は、記憶領域L1のi番目にEOF(ファイル終点の識別子)であるか否かを判断する(S325)。記憶領域L1のi番目に格納された情報がEOFでなければ(S325:NO)、制御部111は、S310の処理を再度行なう。記憶領域L1のi番目に格納された情報がEOFであれば(S325:YES)、変換処理を終了し、図3のフローに戻る(S326)。
 S106の処理が実行されると、制御部111は、圧縮ファイルF2を保存する(S107)。S107の処理において、例えば、制御部111は、ファイル名、ファイルの格納場所を指定される画面を表示させ、表示された画面に応じた入力に指定されたファイル格納場所に、指定されたファイル名で圧縮ファイルを格納する。圧縮ファイルが保存されると、呼び出された圧縮機能はクローズされる(S108)。
[実施例2]
 実施例2の圧縮処理も、図1に示すコンピュータ1で行なわれる。
 図14は、実施例2の圧縮処理の例を示す。実施例2においては、制御部111は、読みだした文字列で文字列圧縮辞書T1を検索する前に順序情報テーブルT4を参照し(S19)、参照結果(S20)に応じて、文字列圧縮辞書T1の検索を抑止する。これにより、文字列圧縮辞書T1の無駄な検索が抑制される。文字列圧縮辞書T1の検索が抑止された場合には、制御部111は、読みだした文字列を圧縮ファイルF2に書き込む(S21)。S21で文字列を書き込む代わりに、読みだした文字列を別の圧縮アルゴリズムで圧縮し、圧縮ファイルF2に書き込むこととしてもよい。文字列圧縮辞書T1の検索が行なわれた場合には、実施例1と同様の圧縮処理が行なわれる。
 順序情報テーブルT4は、文字列圧縮辞書T1に基づき生成されるテーブルであり、文字列圧縮辞書T1に含まれる各文字列における文字情報の順序が反映されている。順序情報テーブルT4は、文字情報の種類ごとのレコードを含む。各レコードには、そのレコードの文字情報が文字列圧縮辞書T1に含まれる文字列において、何番目に存在するかが示される。さらに具体的には、文字列中の1番目の文字情報として存在するか否か、2番目の文字情報として存在するか否か、・・・と各順番について項目を有する。各項目においては、文字列圧縮辞書T1に含まれるいずれか少なくとも1つの文字列で該当すれば、「存在」が示され、いずれの文字列も該当しない場合に、「不在」が示される。
 図15は、順序情報テーブルT4の一例として、日本語表記の順序情報テーブルT41のデータ構成例を示す。順序情報テーブルT41では、「川」、「区」、・・・などの文字情報それぞれについてレコードが設けられる。さらに各レコードは、文字列中の各位置(1文字目、2文字目、・・・)に対応する項目を含む。例えば、「川」のレコードでは、1文字目の項目で「存在(1)」が示され、2文字目の項目で「不在(0)」が示される。これによれば、文字列圧縮辞書T1には、1文字目に「川」を含む文字列が含まれるが、2文字目に「川」を含む文字列は含まれない。
 図14に示す順序情報テーブルT4の参照(S19)では、読みだした文字列内の一部もしくは全部の文字情報基づいて順序情報テーブルT4が参照される。例えば、「川崎市」という文字列に基づいて順序情報テーブルT41を参照すると、文字情報「川」のレコードの1文字目の項目に「存在」が示され、文字情報「崎」のレコードの2文字目の項目に「存在」が示され、文字情報「市」のレコードの3文字目の項目に「存在」が示される。この参照結果の場合には、「川崎市」が文字列圧縮辞書T1に含まれる可能性があるので、制御部111は、文字列圧縮辞書T1の検索(S11)を抑止しない。一方、例えば、「市原市」などの文字列の場合には、文字情報「市」のレコードの1文字目の項目に「不在」が示される。そのため、この参照結果の場合には、「市原市」が文字列圧縮辞書T1に含まれないことが明らかなので、制御部111は、文字列圧縮辞書T1の検索(S11)を抑止する。
 図16では、順序情報テーブルT4の一例として、日本語表記の順序情報テーブルT42のデータ構成例を示す。順序情報テーブルT42のデータ構成例では、「a」、「e」、・・・などの文字情報それぞれについてレコードが設けられる。さらに各レコードは、文字列中の各位置(1文字目、2文字目、・・・)に対応する項目を含む。例えば、「a」のレコードでは、2文字目の項目で「存在(1)」が示され、3文字目の項目で「不在(0)」が示される。これによれば、文字列圧縮辞書T1には、2文字目に「a」を含む文字列が含まれるが、3文字目に「a」を含む文字列は含まれない。例えば、「man」は文字列圧縮辞書T1に含まれるかもしれないが、「sea」は含まれない。
 ちなみに、実施例1において、文字列圧縮辞書T1内の文字列や、連結文字列圧縮辞書T3内の連結文字列では、住所が例として用いられた。住所を日本語表記する場合には、広範囲な領域を示す地名から、徐々に狭い領域を示す地名が連続して表記される。広範囲な領域を示す地名は、複数の狭い範囲を示す地名と連続して用いられる。例えば、「東京都」という広範囲な領域を示す地名は、狭い範囲を示す地名である「あきる野市」とも「武蔵野市」とも組み合わせて用いられる。すなわち、「東京都あきる野市」および「東京都武蔵野市」という連結文字列が存在する。
 上述の例とは異なり、住所を英語表記する場合には、狭い範囲を示す地名に続いて、広い範囲を示す地名が表記される。すなわち、住所の英語表記においては、連結文字列のうち、後続する文字列が、複数の文字列に対して共通して組み合わされる。先の例を用いると、「Tokyo-to」は、「Akiruno-shi」とも「Musashino-shi」とも組み合わされる。すると、連結文字列は、「Akiruno-shi, Tokyo-to」や「Musashino-shi, Tokyo-to」などと表記される。
 上記の英語表記例に基づく順序情報テーブルにおいては、文字列「Tokyo-to」については、2番目の順序に「存在」が示され、「Akiruno-shi」や「Musashino-shi」については1番目の順序に「存在」が示される。
 例えば、連結文字列を1つの長い文字列として、順序情報テーブルT4に格納する方法もあるが、長い文字列を扱うことにより順序情報テーブルT4のサイズが増大してしまう。さらには、先に説明した住所の英語表記など、複数の文字列に対して共通して組み合わせられる文字列が連結文字列の先頭に来ない場合には、先頭の文字列の長さが異なることにより、共通して用いられる文字列の位置が変動してしまう。すると、共通して用いられる文字列により「存在」と判定され箇所が多くなるので、順序テーブルT4参照による抑止効果が得られにくくなることもある。
 以下に、実施例2の圧縮処理をさらに詳細に説明する。
 図1に示すコンピュータ1に含まれる生成部112は、例えば、順序情報テーブルT2、文字列圧縮辞書T1および連結文字列圧縮辞書T3の他に、さらに、文字情報間の順序を示す順序情報テーブルT4などを生成する。生成部112は、生成した順序情報テーブルT4を記憶部13に記憶させる。参照部113は、制御部111の指示に応じて、順序情報テーブルT2および順序情報テーブルT4を参照する。制御部111は、順序情報テーブルT2および順序情報テーブルT4の参照結果に応じて、検索部114の検索処理を抑止する。
 図17は、実施例2の圧縮処理のフローチャート例を示す。実施例2では、図3に示すフローチャートにおいて、S101の処理後に、制御部111は、順序情報テーブルT4の生成を実行する(S109)。順序情報テーブルT4が生成されると、制御部111は、図3に示すS102のフローに戻る。順序情報テーブルT4の生成処理(S109)の詳細については、図18を用いて説明する。
 図18は、生成処理のフローチャート例を示す。順序情報テーブルT4の生成処理が呼び出される(S600)と、制御部111は、文字列中の位置についての定義情報を読み出す(S601)。定義情報は、例えば、文字列中の何文字目(開始位置)から何文字分(文字情報の長さ)を指定する定義を含む。定義の一例によれば、「1文字目」から「1文字分」が指定される。また、定義情報は1または複数の定義を含む。定義情報の一例として、「1文字目」から「1文字」を指定する定義と、「2文字目」から「1文字」を指定する定義と、「3文字目」から「1文字」を指定する定義と、「4文字目」から「1文字」を指定する定義と、を含む定義情報を用いてもよい。また、各定義に含まれる開始位置と文字情報の長さとの指定は、例えば、文字列の冒頭からのカウントか、末尾からのカウントか、いずれかのカウント方法により定められる。
 次に、制御部111は、記憶部13に順序情報テーブルT4を格納する記憶領域を確保する(S602)。S602の処理において、制御部111は、さらに、順序情報テーブルT4に含まれる存否情報を「不在」示す情報に初期設定する。
 順序情報テーブルT4は、例えば、S601で取得した定義情報に含まれる各定義に対応する項目を備える。そのため、例えば、順序情報テーブルT4は、少なくとも、定義情報に含まれる定義の数の項目を備える。各項目は、それぞれ「存在」または「不在」の情報を示すため、1ビット以上のデータが含まれる(例えば、各フィールドが1ビットを含み、「1」で「存在」を示し、「0」で「不在」を示す)。また、例えば、順序情報テーブルT4は、文字情報の種類の数のレコードを備える。文字情報の種類の数は、例えば、使用される文字コード系に含まれる文字コードの種類の数と、S601で取得する定義情報に定義される文字情報の長さに応じて定められる。文字情報の種類の数は、例えば、文字コード系に含まれる文字コードの種類の数を、定義された文字情報の長さで冪乗した数となる。また、例えば、各文字情報に対応する各レコードは、文字情報そのものによりその開始位置が示される。
 順序情報テーブルT4のサイズと、文字情報に対応するレコードの開始位置とについて、ASCIIコード系を例に用いて説明する。ASCIIコード系の各文字コードは、1バイトで表現される。定義情報において、文字情報の長さが「2文字分」で定義される場合には、文字情報は2バイトで表現される。一例として、各レコードについて1バイトの領域を確保すると、2バイトで表現される文字情報についての順序情報のレコードの開始位置は、順序情報テーブルT4の開始位置から2バイトの文字情報に対応する数値で特定される。例えば、「AA」という文字情報に対応するASCIIコードは0x4141であり、10進数では、「16705」である。すなわち、文字情報「AA」に関する順序情報のレコードの開始位置は、順序情報テーブルT4の開始位置から16705バイトの位置であることが特定される。上記の例において、各レコードのサイズが1バイトであるとしたが、1バイトであれば、定義情報に8つの定義が含まれても対応できる。また、上記の例における順序情報テーブルT4のサイズは、2の16乗バイト(=64KB)の記憶領域に格納されることとなる。しかしながら、ASCIIコード系においては、0x00~0x7Fまでしか使用されておらず、0x80~0xFFに対応する文字コードは使用されていない。実際には、上記の例において、順序情報テーブルT4で使用される記憶領域は、64KBの1/4の16KBで充分である。
 S602の処理で順序情報テーブルT4の記憶領域が確保されると、制御部111は、図3のS101でワークエリアに読み出した文字列リストから、順次文字列を読み出す(S603)。S603の処理を行なうと、制御部111は、参照部113に順序情報テーブルT4の参照処理を実行させる。参照部113は、S601で取得した定義のうち、未処理の定義を選択し、選択した定義を用いて順序情報テーブルT4を参照し、存否情報を取得する(S604)。参照部113は、S603で読み出された文字列内で、選択した定義に示される位置にある文字情報について存否情報を取得する。参照部113は、取得された存否情報が「存在」を示すか判断する(S605)。取得した存否情報が「不在」を示す場合(S605:NO)には、参照部113は、順序情報テーブルT4の該当箇所の存否情報を「存在」に更新する(S606)。S604で取得した存否情報が「存在」を示す(S605:YES)か、S606の処理が行なわれた場合には、未処理の定義がないかどうか判断する(S607)。S607の判断で未処理の定義がある場合(S607:NO)には、未処理の定義に基づいてS604の処理を再度行なう。
 S603で読みだした文字列に対して、定義情報に含まれる各定義での参照処理を行なった場合(S607:YES)は、制御部111は、文字列リスト内に未処理の文字列がないか判断する(S608)。S608の判断において、未処理の文字列が存在する場合(S608:NO)は、S603に戻り、制御部111は、未処理の文字列の読み出しを再度行なう。S608の判断において、未処理の文字列が存在しない場合(S608:YES)には、制御部111は、図3のS102に処理に戻る(S609)。
 また、実施例2においては、図14に示すように圧縮符号への変換処理の手順が異なる。実施例2での変換手順は、図11~13に示される変換手順の一部が変更された手順である。図19は、実施例2の変換処理の一部のフローチャート例を示す。
 図11のS305の処理を行なう(S400)と、制御部111は、参照部113に順序情報テーブルT4を参照させる(S401)。参照部113は、記憶領域L1のi番目の位置に格納された文字列に含まれる文字情報について、その文字情報の文字列中の位置に基づいて順序テーブルT4を参照する。また、文字列中のどの位置について参照を行なうかは、順序情報テーブルT4を生成する際に用いた定義情報により定められる。
 順序情報テーブルT41を用いて処理を例示する。例えば、「川崎市」という文字列に基づいて、順序情報テーブルT41を参照すると、文字情報「川」が位置「1文字目」に存在するか否かを順序情報テーブルT41に基づいて判断する。すなわち文字情報「川」のレコードの1番目の存否情報が確認される。この場合、存否情報が「1」であり「存在」が示されている。参照部113は、同様の処理を文字情報「崎」、「市」に対しても行なう。
 S401の処理が行なわれると、制御部111は参照部113の参照結果に基づいて、文字列が文字列圧縮辞書T1に格納されている可能性があるか否か判断する(S402)。すなわち、制御部111は、順序情報テーブルT4の参照が行なわれた文字情報と文字列中位置の組み合わせのうち、いずれの組み合わせも「存在」が示されたか否かについて判断する。S402の判断の結果、文字列が文字列圧縮辞書T1に格納されている可能性がある場合(S402:YES)には、制御部111は、検索部114に、文字列圧縮辞書T1内の検索を実行させる。すなわち、制御部111は、順序情報テーブルT4の参照が行なわれた文字情報と文字列中位置の組み合わせのうち、いずれの組み合わせも「存在」を示す場合には、検索部114に検索を実行させる。文字列圧縮辞書T1の検索が行なわれると、制御部111は、図11のS306の処理に戻る(S404)。一方、文字列圧縮辞書T1に格納されている可能性が無い場合(S402:NO)には、文字列圧縮辞書の検索を実行させずに、制御部111は、図11のS306の処理に戻る。
 上述のように、実施例2では、文字列圧縮辞書T1に登録されていない文字列についても、無駄に文字列圧縮辞書T1を検索してしまうことが抑制される。
[実施例3]
 実施例3の圧縮処理も、図1に示すコンピュータ1で行なわれる。
 図20は、実施例3の圧縮処理の例を示す。実施例3においては、制御部111は、順序情報テーブルT4の参照を複数回実行させ(S19、S20)、参照の結果、連続して文字列圧縮辞書T1に含まれる可能性ありとなった場合に、それらの連続する文字列に基づいて順序情報テーブルT2を参照させる(S23、S24)。すなわち、制御部111は、文字列圧縮辞書T1の検索を飛ばして、先に連結文字列圧縮辞書T3に登録されているか否かの判定を行ない(S16、S17)、その結果、連結文字列圧縮辞書T3に含まれていない場合に、文字列圧縮辞書T1の検索を実行させる(S11、S12)。
 連結文字列圧縮辞書T3に登録される連結圧縮文字列の数が多くなってくると、それだけ連結文字列圧縮辞書T3と文字列圧縮辞書T1とについて、重複して検索が実行されがちになる。実施例3によれば、連結文字列圧縮辞書T3に登録されているにも関わらず、文字列圧縮辞書T1を検索してしまうことが抑制される。
 以下に、実施例3の圧縮処理をさらに詳細に説明する。実施例2と同様に、S101の処理の後に、S109の処理が行なわれる(図17)。実施例3においては、図20を用いて説明したように、圧縮符号への変換処理の手順が図11~13に示す手順から一部変更されている。
 図21および図22は、実施例3の変換処理の一部のフローチャート例を示す。制御部111は、図11に示すS304の処理を行なうと、制御部111は、参照部113に順序情報テーブルT4を参照させる(S327)。これは、図19に示すS401と同様の処理である。参照部113は、記憶領域L1のi番目の位置に格納された文字列に含まれる文字情報について、その文字情報の文字列中の位置に基づいて順序情報テーブルT4を参照する。制御部111は、参照部113の参照結果に基づいて、記憶領域L1のi番目の位置に格納された文字列が文字列圧縮辞書T1に格納されている可能性があるか否かを判定する(S328)。判定の基準は、図19のS402と同様である。
 文字列圧縮辞書T1に格納されている可能性がない場合(S328:NO)には、制御部111は、カウンタ値iにi=i+1(「=」は代入演算子)の代入を行なう(S329)。S329の処理を行なうと、制御部111は、図1に示すS302の処理に戻る。
 文字列圧縮辞書T1に格納される可能性がある場合(S328:YES)には、制御部111は、カウンタ値jにj=1(「=」は代入演算子)の代入を行なう(S330)。次に、制御部111は、記憶領域L3のi+j番目の位置にポインタがあるか否か判定する(S331)。S331の判定の結果、制御部111は、参照部113に、ポインタがあれば(S331:YES)ポインタに基づいて順序情報テーブルT2を参照し(S332)、ポインタがなければ(S331:NO)記憶領域L1のi+j番目の文字列に基づいて順序情報テーブルT2を参照する(S333)。S332およびS333のいずれにおいても、参照部113は、連結文字列のうちj番目の文字列についての順序情報を参照する。
 制御部111は、S332またはS333の参照結果に、「存在」が示されているか否かを判断する(S334)。参照結果が「存在」を示す場合(S334:YES)には、制御部111は、カウンタ値jが所定値未満であるかを判断する(S335)。カウンタ値jが所定値以上であれば(S335:NO)、制御部111は、図13のS316の処理に戻る。カウンタ値jが所定値未満であれば(S335:YES)、制御部111は、カウンタ値jをインクリメント(j=j+1の代入)して(S336)、S331の処理を行なう。
 S334の判定において、参照結果が「不在」を示す場合(S334:NO)には、制御部111は、記憶領域L1のi番目の文字列の圧縮処理を行なう。まず制御部111は、検索部114に、記憶領域L1のi番目の文字列で文字列圧縮辞書T1を検索させる(S337)。制御部111は、検索部114による検索により、文字列圧縮辞書T1内に合致する文字列が特定された否かを判定する(S338)。文字列圧縮辞書T1内に文字列が含まれない場合(S338:NO)には、制御部111は、カウンタ値iをインクリメント(i=i+1と代入)し(S339)、図11のS302の処理に戻る。
 文字列圧縮辞書T1内に合致する文字列が特定される(S338:YES)と、制御部111は、文字列圧縮辞書T1内の特定された文字列に対応づけられた圧縮符号を、記憶領域L2のi番目の位置に格納する(S340)。さらに、制御部111は、文字列圧縮辞書T1内の特定された文字列に、ポインタが対応づけられているか否か判断し(S341)、ポインタがあれば(S341:YES)、そのポインタを記憶領域L3のi番目の位置に格納する(S342)。S342を行なうか、文字列圧縮辞書T1内の特定された文字列にポインタが対応づけられていない場合(S341:NO)には、制御部111は図13に示すS321の処理に戻る。
[実施例4]
 例えば、データベースには、似通ったデータの羅列が含まれることがある。さらに、羅列される各データに含まれる文字列の数が固定されている場合もある。そういった場合には、連結文字列との一致を確認するのに、1文字列ずつずらしながら照合するよりも、複数の文字列を含むデータ単位で行なうこととしてもよい。実施例4においては、例えば、文字列を連続で読み出して、各文字列に対しての文字列圧縮辞書T1の検索よりも先に、連結文字列圧縮辞書T3に格納されるか否かの確認が行なわれる。
 図23および図24は、実施例4の変換処理のフローチャート例を示す。制御部111は、変換処理が開始される(S500)と、前処理を実行する(S501)。このS501の処理は、例えば、図11に示すS301と同様の処理である。次に制御部111は、圧縮対象のファイルF1から文字列を読み出し(S502)、改行コードを読み出すまでS502の処理に戻る(S503:NO)。改行コードを読み出した場合(S503:YES)には、制御部111は、参照部113に、順序情報テーブルT2の参照を行なわせる(S504)。参照部113は、S502の繰り返しで読み出された複数の文字列それぞれについて、順序情報テーブルT2に含まれる順序情報を参照する。制御部111は、読み出された複数の文字列のそれぞれが、参照部113により参照された順序情報と整合するか否かを判定する(S505)。複数の文字列のいずれもが順序情報と整合する場合(S505:YES)には、制御部111は、検索部114に、読みだした複数の文字列で連結文字列圧縮辞書T3を検索させる(S506)。制御部111は、検索部114の検索結果に応じて、読みだした複数の文字列に合致する連結文字列が連結文字列圧縮辞書T3に登録されているか否かを判断する(S507)。合致する連結文字列が連結文字列圧縮辞書T3に登録されていれば(S507:YES)、登録されている連結文字列に対応付けられた圧縮符号を、圧縮ファイルF2の書き込み位置に書き込む(S508)。
 S502で読みだした複数の文字列のいずれかが順序情報と整合しない(S505:NO)か、連結文字列辞書T3に複数の文字列と合致する連結文字列が存在しない場合(S507:NO)には、制御部111は、複数の文字列から1つの文字列を選択する(S511)。次に、制御部111は、参照部113に、選択した文字列に含まれた文字情報について、順序情報テーブルT4を参照させる(S512)。制御部111は、参照の結果、参照された文字情報について順序情報と整合するか否か判定する(S513)。参照された文字情報のいずれもが順序情報と整合する場合(S513:YES)に、制御部111は、検索部114に、選択した文字列で文字列圧縮辞書T1を検索させる(S514)。制御部111は、文字列圧縮辞書T1の検索結果に応じて、選択した文字列に合致する文字列が存在するか否かを判定する(S515)。合致する文字列が存在する場合(S515:YES)には、制御部111は、合致する文字列と文字列圧縮辞書T1により対応づけられる圧縮符号を、圧縮ファイルF2の書き込み位置に書き込む(S517)。
 参照された文字情報のうち少なくとも1つが順序情報と整合しない場合(S513:NO)か、文字列圧縮辞書T1に合致する文字列が存在しない場合(S515:NO)には、制御部111は、選択した文字列を、圧縮ファイルF2の書き込み位置に書き込む(S516)。
 S516またはS517の処理を終えると、S502で読みだした複数の文字列のうち、S511で選択されていない文字列があるか否かを判定する(S518)。選択されていない文字列がある場合(S518:NO)には、制御部111は再度S511の処理を行なう。
 S508の処理を行なうか、S518の判定で選択されていない文字列がない場合(S518:YES)には、制御部111は、圧縮対象のファイルF1内に未処理の文字列がないかどうかを判定する(S509)。制御部111は、未処理の文字列がなければ(S509:YES)、変換処理を終了し(S510)、未処理の文字列があれば(S509:NO)、S502の処理を再度行なう。
 図25は、実施例1~4に用いられるコンピュータ1のハードウェア構成例を示す。コンピュータ1は、例えば、プロセッサ301、RAM(Random Access Memory)302、ROM(Read Only Memory)303、ドライブ装置304、記憶媒体305、入力インターフェース(I/F)306、入力デバイス307、出力インターフェース(I/F)308、出力デバイス309、通信インターフェース(I/F)310、SAN(Storage Area Network)インターフェース(I/F)311およびバス312などを含む。それぞれのハードウェアはバス312を介して接続されている。
 RAM302は読み書き可能なメモリ装置であって、例えば、SRAM(Static RAM)やDRAM(Dynamic RAM)などの半導体メモリ、またはRAMでなくてもフラッシュメモリなどが用いられる。ROM303は、PROM(Programmable ROM)なども含む。ドライブ装置304は、記憶媒体305に記録された情報の読み出しか書き込みかの少なくともいずれか一方を行なう装置である。記憶媒体305は、ドライブ装置304によって書き込まれた情報を記憶する。記憶媒体305は、例えば、ハードディスク、SSD(Solid State Drive)などのフラッシュメモリ、CD(Compact Disc)、DVD(Digital Versatile Disc)、ブルーレイディスクなどの記憶媒体である。また、例えば、コンピュータ1は、複数種類の記憶媒体それぞれについて、ドライブ装置304及び記憶媒体305を設ける。
 入力インターフェース306は、入力デバイス307と接続されており、入力デバイス307から受信した入力信号をプロセッサ301に伝達する。出力インターフェース308は、出力デバイス309と接続されており、出力デバイス309に、プロセッサ301の指示に応じた出力を実行させる。通信インターフェース310はネットワーク3を介した通信の制御を行なう。SANインターフェース311は、ストレージエリアネットワークによりコンピュータ1と接続された記憶装置との通信の制御を行なう。
 入力デバイス307は、操作に応じて入力信号を送信する装置である。入力信号は、例えば、キーボードやコンピュータ1の本体に取り付けられたボタンなどのキー装置や、マウスやタッチパネルなどのポインティングデバイスである。出力デバイス309は、コンピュータ1の制御に応じて情報を出力する装置である。出力デバイス309は、例えば、ディスプレイなどの画像出力装置(表示デバイス)や、スピーカーなどの音声出力装置などである。また、例えば、タッチスクリーンなどの入出力装置が、入力デバイス307及び出力デバイス309として用いられる。また、入力デバイス307及び出力デバイス309は、コンピュータ1と一体になっていてもよいし、コンピュータ1に含まれず、例えば、コンピュータ1に外部から接続する装置であってもよい。
 例えば、プロセッサ301は、ROM303や記憶媒体305に記憶されたプログラムをRAM302に読み出し、読み出されたプログラムの手順に従って圧縮部11の処理または伸張部12の処理を行なう。その際にRAM302はプロセッサ301のワークエリアとして用いられる。記憶部13の機能は、ROM303および記憶媒体305がプログラムファイル(後述のアプリケーションプログラム24、ミドルウェア23およびOS22など)やデータファイル(圧縮対象のデータファイル、圧縮ファイル、伸張対象のデータファイル、伸張ファイルなど)を記憶し、RAM302がプロセッサ301のワークエリアとして用いられることによって実現される。プロセッサ301が読み出すプログラムについては、図26を用いて説明する。
 図26は、コンピュータ1のプログラムの構成例を示す。コンピュータ1において、図25に示すハードウェア群21の制御を行なうOS(オペレーションシステム)22が動作する。OS22に従った手順でプロセッサ301が動作して、ハードウェア21群の制御・管理が行なわれることにより、アプリケーションプログラム24やミドルウェア23に従った処理がハードウェア群21で実行される。さらに、コンピュータ1において、ミドルウェア23またはアプリケーションプログラム24が、RAM302に読み出されてプロセッサ301により実行される。
 プロセッサ301が、ミドルウェア23またはアプリケーションプログラム24に含まれる圧縮機能に基づく処理を行なうことにより、(それらの処理をOS22に基づいてハードウェア群21を制御して)圧縮部11の機能が実現される。また、プロセッサ301が、ミドルウェア23またはアプリケーションプログラム24に含まれる伸張機能に基づく処理を行なうことにより、(それらの処理をOS22に基づいてハードウェア群21を制御して)伸張部12の機能が実現される。圧縮機能および伸張機能は、それぞれアプリケーションプログラム24自体に定義されてもよいし、アプリケーションプログラム24に従って呼び出されることで実行されるミドルウェア23の機能であってもよい。
 図27は、実施例1~4のコンピュータを含むシステムにおける装置の構成例を示す。図27のシステムは、コンピュータ1a、コンピュータ1b、基地局2およびネットワーク3を含む。コンピュータ1aは、無線または有線の少なくとも一方により、コンピュータ1bと接続されたネットワーク3に接続している。
 図1に示す圧縮部11と伸張部12とは、図27に示すコンピュータ1aとコンピュータ1bとのいずれに含まれてもよい。コンピュータ1bが図1に示す圧縮部11を含み、コンピュータ1aが伸張部12を含んでもよいし、コンピュータ1bが図1に示す圧縮部11を含み、コンピュータ1aが伸張部12を含んでもよい。また、コンピュータ1aとコンピュータ1bとの双方が、圧縮部11および伸張部12を備えてもよい。
 1    コンピュータ
 2    基地局
 3    ネットワーク
 1a   コンピュータ
 1b   コンピュータ
 11   圧縮部
 12   伸張部
 13   記憶部
 111  制御部
 112  生成部
 113  参照部
 114  検索部
 

Claims (9)

  1.  コンピュータに、
     ある文字列を含む複数の文字列を圧縮対象のファイルから読み出した場合に、文字列を複数含む連結文字列と圧縮符号とを対応付ける圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、前記複数の文字列中の前記ある文字列の順序で、前記ある文字列を含むか否かを示す順序情報の参照を行ない、
     前記順序情報が含む旨を示す場合に、前記複数の文字列による前記圧縮辞書の検索を行なう、
     処理を実行させることを特徴とする圧縮プログラム。
  2.  前記連結文字列に含まれる文字列のそれぞれは、他の圧縮辞書により圧縮符号と対応づけられた文字列であり、
     前記コンピュータに、さらに、
     前記順序情報が含まない旨を示す場合に、前記複数の文字列のいずれか少なくとも1つの文字列に対して前記他の圧縮辞書に基づく圧縮処理を行なう、
     処理を実行させることを特徴とする請求項1に記載の圧縮プログラム。
  3.  前記コンピュータに、さらに、
     前記他の圧縮辞書に基づく前記圧縮処理が行なわれると、圧縮対象の文字列がある文字情報をある文字列中位置に含む場合に、前記他の圧縮辞書に含まれる文字列のいずれか少なくとも1つの文字列が、前記ある文字情報を前記ある文字列中位置に含むか否かを示す存否情報の参照を行ない、
     前記存否情報に、前記他の圧縮辞書に含まれるいずれの文字列も前記ある文字情報を前記ある文字列中位置に含まないことが示される場合を除いて、前記圧縮対象の文字列による前記他の圧縮辞書の検索を行ない、
     前記他の圧縮辞書の検索結果に応じて、前記圧縮対象の文字列の圧縮を行なう、
     処理を実行させることを特徴とする請求項2に記載の圧縮プログラム。
  4.  前記コンピュータに、
     前記存否情報の参照および前記他の圧縮辞書の前記検索を、前記順序情報の前記参照よりも先に実行させる制御を行ない、
     前記存否情報により前記他の圧縮辞書に含まれるいずれの文字列も前記ある文字情報を前記ある文字列中位置に含まない旨が示されるか、前記他の圧縮辞書の検索により前記圧縮対象の文字列を特定できないかのいずれかの場合に、前記順序情報の前記参照を抑止する、
     処理を実行させることを特徴とする請求項3に記載の圧縮プログラム。
  5.  前記コンピュータに、
     前記他の圧縮辞書の前記検索により特定された文字列と対応づけて記憶された、前記特定された文字列に対応する順序情報を格納する位置を示すポインタを取得し、
     取得したポインタに基づいて、前記順序情報の前記参照を行なう、
     処理を実行させることを特徴とする請求項4に記載の圧縮プログラム。
  6.  前記コンピュータに、さらに、
     前記存否情報に、前記他の圧縮辞書に含まれる文字列のいずれか少なくとも1つの文字列が前記ある文字情報を前記文字列中のある位置に含む旨が示される場合に、前記圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、連結文字列中の前記ある位置に前記圧縮対象の文字列を含むか否かを示す他の順序情報の参照を、前記他の圧縮辞書の前記検索よりも先に行なう、
     ことを実行させることを特徴とする請求項4または5に記載の圧縮プログラム。
  7.  前記コンピュータに、さらに、
     前記複数の文字列による前記他の圧縮辞書の前記検索により、前記複数の文字列に合致する連結文字列が特定された場合には、特定された前記連結文字列に前記圧縮辞書により対応づけられた圧縮符号を圧縮ファイルに書き込む、
     ことを実行させることを特徴とする請求項2~6のいずれか1項に記載の圧縮プログラム。
  8.  コンピュータが、
     ある文字列を含む複数の文字列を圧縮対象のファイルから読み出した場合に、文字列を複数含む連結文字列と圧縮符号とを対応付ける圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、前記複数の文字列中の前記ある文字列の順序で、前記ある文字列を含むか否かを示す順序情報の参照を行ない、
     前記順序情報が含む旨を示す場合に、前記複数の文字列による前記圧縮辞書の検索を行なう、
     ことを実行することを特徴とする圧縮方法。
  9.  ある文字列を含む複数の文字列を圧縮対象のファイルから読み出した場合に、文字列を複数含む連結文字列と圧縮符号とを対応付ける圧縮辞書に含まれる連結文字列のいずれか少なくも1つが、前記複数の文字列中の前記ある文字列の順序で前記ある文字列を含むか否かを示す順序情報の参照を行なう参照部と、 
     前記順序情報が含む旨を示す場合に、前記複数の文字列による前記圧縮辞書の検索を行なう検索部と、
     を含むことを特徴とする圧縮装置。
     
PCT/JP2012/005993 2012-09-21 2012-09-21 圧縮プログラム、圧縮方法及び圧縮装置 WO2014045318A1 (ja)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP2014536411A JP6003995B2 (ja) 2012-09-21 2012-09-21 圧縮プログラム、圧縮方法及び圧縮装置
PCT/JP2012/005993 WO2014045318A1 (ja) 2012-09-21 2012-09-21 圧縮プログラム、圧縮方法及び圧縮装置
US14/656,290 US9219497B2 (en) 2012-09-21 2015-03-12 Compression device, compression method, and recording medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2012/005993 WO2014045318A1 (ja) 2012-09-21 2012-09-21 圧縮プログラム、圧縮方法及び圧縮装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US14/656,290 Continuation US9219497B2 (en) 2012-09-21 2015-03-12 Compression device, compression method, and recording medium

Publications (1)

Publication Number Publication Date
WO2014045318A1 true WO2014045318A1 (ja) 2014-03-27

Family

ID=50340680

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2012/005993 WO2014045318A1 (ja) 2012-09-21 2012-09-21 圧縮プログラム、圧縮方法及び圧縮装置

Country Status (3)

Country Link
US (1) US9219497B2 (ja)
JP (1) JP6003995B2 (ja)
WO (1) WO2014045318A1 (ja)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6742692B2 (ja) * 2015-01-30 2020-08-19 富士通株式会社 符号化プログラムおよび伸長プログラム
CN112637600B (zh) * 2020-12-14 2024-04-05 绍兴文理学院 对数据进行有损或无损压缩的编码、解码的方法或装置
WO2024066753A1 (zh) * 2022-09-29 2024-04-04 华为云计算技术有限公司 压缩数据的方法和相关装置

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000036756A (ja) * 1998-07-17 2000-02-02 Nec Ic Microcomput Syst Ltd 文字列圧縮方式
JP2005284616A (ja) * 2004-03-29 2005-10-13 Casio Comput Co Ltd 辞書データ圧縮装置、電子辞書装置及びプログラム
JP2011138230A (ja) * 2009-12-25 2011-07-14 Fujitsu Ltd 情報処理プログラム、情報検索プログラム、情報処理装置、および情報検索装置
WO2012117544A1 (ja) * 2011-03-02 2012-09-07 富士通株式会社 検索プログラム、検索装置、および検索方法

Family Cites Families (25)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH01297718A (ja) 1988-05-26 1989-11-30 Pfu Ltd ファイル・ラベル検出処理方式
JP2729424B2 (ja) 1991-10-31 1998-03-18 シャープ株式会社 テキスト圧縮装置およびテキスト圧縮用辞書の自動構築装置
JP3105598B2 (ja) 1991-11-06 2000-11-06 富士通株式会社 ユニバーサル符号を用いたデータ圧縮方式
JPH05233312A (ja) 1992-02-19 1993-09-10 Fujitsu Ltd 遷移規則表生成方式
JP3241788B2 (ja) 1992-02-28 2001-12-25 富士通株式会社 データ圧縮方式
US5463389A (en) * 1993-09-24 1995-10-31 Motorola, Inc. Data compression method and device utilizing children arrays
JP3346626B2 (ja) 1993-11-30 2002-11-18 京セラ株式会社 データ圧縮装置
JP3499671B2 (ja) 1996-02-09 2004-02-23 富士通株式会社 データ圧縮装置及びデータ復元装置
JP3143079B2 (ja) * 1997-05-30 2001-03-07 松下電器産業株式会社 辞書索引作成装置と文書検索装置
JP2001052116A (ja) * 1999-08-06 2001-02-23 Toshiba Corp パターン列マッチング装置とパターン列マッチング方法と文字列マッチング装置と文字列マッチング方法
US6671856B1 (en) * 1999-09-01 2003-12-30 International Business Machines Corporation Method, system, and program for determining boundaries in a string using a dictionary
US20020007382A1 (en) * 2000-07-06 2002-01-17 Shinichi Nojima Computer having character input function,method of carrying out process depending on input characters, and storage medium
JP4821039B2 (ja) * 2000-10-24 2011-11-24 日本電気株式会社 地名情報抽出装置、その抽出方法及び記録媒体
GB0200352D0 (en) * 2002-01-09 2002-02-20 Ibm Finite state dictionary and method of production thereof
JP3916219B2 (ja) 2002-03-27 2007-05-16 日立ソフトウエアエンジニアリング株式会社 リンク先圧縮システム
US7256715B1 (en) * 2005-01-07 2007-08-14 Altera Corporation Data compression using dummy codes
JP4682627B2 (ja) * 2005-01-27 2011-05-11 富士ゼロックス株式会社 文書検索装置および方法
US7167115B1 (en) * 2005-08-26 2007-01-23 American Megatrends, Inc. Method, apparatus, and computer-readable medium for data compression and decompression utilizing multiple dictionaries
JP4456554B2 (ja) 2005-10-31 2010-04-28 富士通株式会社 データ圧縮方法及び圧縮データ送信方法
JP5365719B2 (ja) 2007-05-24 2013-12-11 富士通株式会社 情報検索プログラム、該プログラムを記録した記録媒体、および情報検索方法
JP5234730B2 (ja) * 2007-11-05 2013-07-10 シャープ株式会社 電子機器、その制御方法およびコンピュータプログラム
JP2009295143A (ja) * 2008-05-09 2009-12-17 Canvas Mapple Co Ltd 情報検索装置、情報検索方法、及びコンピュータプログラム
JP5190898B2 (ja) * 2010-01-18 2013-04-24 株式会社高速屋 コード列検索装置、検索方法及びプログラム
JP5473893B2 (ja) * 2010-12-28 2014-04-16 株式会社高速屋 コード列検索装置、検索方法及びプログラム
JP5760564B2 (ja) * 2011-03-22 2015-08-12 カシオ計算機株式会社 情報表示装置およびプログラム

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000036756A (ja) * 1998-07-17 2000-02-02 Nec Ic Microcomput Syst Ltd 文字列圧縮方式
JP2005284616A (ja) * 2004-03-29 2005-10-13 Casio Comput Co Ltd 辞書データ圧縮装置、電子辞書装置及びプログラム
JP2011138230A (ja) * 2009-12-25 2011-07-14 Fujitsu Ltd 情報処理プログラム、情報検索プログラム、情報処理装置、および情報検索装置
WO2012117544A1 (ja) * 2011-03-02 2012-09-07 富士通株式会社 検索プログラム、検索装置、および検索方法

Also Published As

Publication number Publication date
JP6003995B2 (ja) 2016-10-05
JPWO2014045318A1 (ja) 2016-08-18
US20150188565A1 (en) 2015-07-02
US9219497B2 (en) 2015-12-22

Similar Documents

Publication Publication Date Title
AU2016200550B2 (en) Encoding program, decompression program, compression method, decompression method, compression device and decompression device
CA2910841C (en) Managing storage of individually accessible data units
EP2978134A1 (en) Compression device, compression method, dictionary generation device, dictionary generation method, expansion device, expansion method, expansion program, and information processing system
JP6531398B2 (ja) プログラム
JP6641857B2 (ja) 符号化プログラム、符号化方法、符号化装置、復号化プログラム、復号化方法および復号化装置
EP2978135A1 (en) Compression device, compression method, decompression device, decompression method, and information processing system
JP6003995B2 (ja) 圧縮プログラム、圧縮方法及び圧縮装置
JP6540308B2 (ja) 符号化プログラム、符号化方法、符号化装置、復号化プログラム、復号化方法および復号化装置
JP6032292B2 (ja) 圧縮プログラム、圧縮装置、伸張プログラムおよび伸張装置
JP6507682B2 (ja) 符号化プログラム、符号化方法および符号化装置
JP2018061166A (ja) 符号化プログラム、符号化装置および符号化方法
JP6252489B2 (ja) 圧縮装置、圧縮方法、圧縮プログラム、伸張装置、伸張方法、伸張プログラム、および圧縮伸張システム
JP6065914B2 (ja) 制御プログラム、制御方法および制御装置
EP3385860A1 (en) Compression of text using multiple dynamic dictionaries
JP2016143987A (ja) 圧縮プログラム、圧縮方法、圧縮装置および伸長プログラム
WO2014030180A1 (ja) 格納プログラム、格納方法、格納装置、伸張プログラム、伸張方法及び伸張装置
WO2014097356A1 (ja) 圧縮プログラム、圧縮方法、圧縮装置、伸張プログラム、伸張方法および伸張装置
US10037148B2 (en) Facilitating reverse reading of sequentially stored, variable-length data
JP2017195628A (ja) 符号化プログラム、符号化方法、符号化装置、復号化プログラム、復号化方法及び復号化装置
JP2006030892A (ja) 音声合成用読み上げテキストデータ選択プログラムおよび音声合成用読み上げテキストデータ選択装置
JP2016134754A (ja) 変換処理プログラム、情報処理装置および変換処理方法
JP2016171589A (ja) 符号化プログラム、符号化方法、符号化装置、復号化プログラム、復号化方法及び復号化装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 12885055

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2014536411

Country of ref document: JP

Kind code of ref document: A

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 12885055

Country of ref document: EP

Kind code of ref document: A1