CN108737976A - A kind of compression transmitting method based on Big Dipper short message - Google Patents

A kind of compression transmitting method based on Big Dipper short message Download PDF

Info

Publication number
CN108737976A
CN108737976A CN201810495167.8A CN201810495167A CN108737976A CN 108737976 A CN108737976 A CN 108737976A CN 201810495167 A CN201810495167 A CN 201810495167A CN 108737976 A CN108737976 A CN 108737976A
Authority
CN
China
Prior art keywords
message
data
compression
difference
type
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
CN201810495167.8A
Other languages
Chinese (zh)
Other versions
CN108737976B (en
Inventor
王健
姜宁
许祖锋
伍小刚
汤晓晨
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nanjing University
NARI Group Corp
Original Assignee
Nanjing University
NARI Group Corp
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 Nanjing University, NARI Group Corp filed Critical Nanjing University
Priority to CN201810495167.8A priority Critical patent/CN108737976B/en
Publication of CN108737976A publication Critical patent/CN108737976A/en
Application granted granted Critical
Publication of CN108737976B publication Critical patent/CN108737976B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/12Messaging; Mailboxes; Announcements
    • H04W4/14Short messaging services, e.g. short message services [SMS] or unstructured supplementary service data [USSD]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/04Protocols for data compression, e.g. ROHC

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

The present invention proposes a kind of compression transmitting method based on Big Dipper short message, message is divided into text-type message and numeric type message by this method by analyzing different types of message space feature, and numeric type message is further subdivided into ordinary numeric value type message and process value type message;According to type of message, efficient combination is carried out on the basis of popular compression algorithm, and is aided with targetedly message coding algorithm, and best compression solution is provided for different types of message.The present invention can solve the prior art only individually to having relatively good compression effectiveness under the conditions of certain, without versatility, the technical issues of single compression coding mode is difficult to obtain preferable compression effectiveness can keep relatively high and stable compression ratio while enhancing algorithm portability.

Description

A kind of compression transmitting method based on Big Dipper short message
Technical field
The present invention relates to communication network and compression transmission field, especially a kind of compression transmission side based on Big Dipper short message Method.
Background technology
When being communicated using Big Dipper short message, due to dipper system civilian message exist communication frequency and length by The efficiency of the problems such as limit, Big Dipper short message communication are relatively low, and the communication resource is in short supply, are compressed to message and are utilized to improving byte Rate has great importance.
It is required that the data of reconstruct are identical with initial data, so need to use lossless compression, it is existing popular Lossless compression algorithm have based on dictionary, " sliding window " LZ77 algorithms, Run- Length Coding RLE algorithms, Huffman encoding algorithm.
LZ77 is that a kind of compressed encoding based on dictionary is theoretical, is pushed away in l977 by Abrall Lempel and Jacob Ziv Go out.LZ77 and its LZ78 algorithm to come down in a continuous line are the bases of many compression algorithms.LZ77 algorithms pass through in reference data stream The uncompressed data more early occurred substitute the data repeated, to realizing the compression of data.Uncompressed data are drawn With then induction-arrangement is carried out using a kind of data structure being known as " length distances to ", meaning is " for each given length The data in particular offset later such as character string ".There is preferable compression effectiveness for the higher signal of repetitive rate.
Huffman coding (Huf.fman Coding) is a kind of coding mode, is that one kind being based on entropy coding (power coding) Lossless data compression algorithms, also referred to as " Huffman encoding " and " Huffman encoding ".In actual use, huffman coding pair Symbol in source file is encoded using variable length coding table.And variable length coding table is by a kind of calculating and assessment source file What the method that probability occurs in each symbol obtained, there is the high source symbol of probability and represented using shorter coding, otherwise occurs The low symbol of probability then uses longer coding.By being replaced to the character in source file so that the file after encoding Average length, desired value reduce, to reach the target of data lossless pressure.It is suitable for frequency rate data unevenly distributed String, distribution more chrominance signal effect are better.
The quality of Run- Length Coding RLE compression effectiveness is decided by the structure of former serial data, if existed in serial data a large amount of Consecutive identical character will obtain very high compression ratio, on the contrary, if the character repeated is few, effect is with regard to poor.
Above several compression methods only individually to having relatively good compression effectiveness under the conditions of certain, do not have versatility, Single compression coding mode is difficult to obtain preferable compression effectiveness.
Invention content
Goal of the invention:In order to solve the above technical problems, the present invention proposes a kind of compression transmission side based on Big Dipper short message Method, this method carry out efficient combination by the different types of message space feature of analysis on the basis of popular compression algorithm, and It is aided with targetedly message coding algorithm, best compression solution is provided for different types of message.
Technical solution:For the above-mentioned technique effect of realization, technical solution proposed by the present invention is:
A kind of compression transmitting method based on Big Dipper short message, this method include data compression stage and decompression phase;
In the data compression stage, transmitting terminal executes step:
(1) transmitting terminal calculates the type factor according to the number of text-type data and numeric type data in current message to be transmitted x:
In formula, AnFor the number of text-type data in current message to be transmitted, AcFor numeric type number in current message to be transmitted According to number;By type factor x compared with pre-set threshold X, when type factor absolute value is more than threshold X, it will correspond to Message classification is text-type message, increases unique compression flag bit in message tail, and execute step (2);Otherwise, it will correspond to Message classification is numeric type message, and executes step (3);
(2) to text-type message, LZ77 codings is first carried out and realize primary compression, the data after primary compression are carried out suddenly again Fu Man is encoded, and is sent to receiving terminal after finally carrying out Big Dipper message encapsulation, the data compression stage terminates;
(3) numeric type message is divided into process value type message and ordinary numeric value type message, including step:
(3-1) prestores part prevalence message as prophesy message, composition prophesy library, by numeric type message and prophesy library In prophesy message carry out characteristic matching, if characteristic matching degree be more than preset matching degree threshold value, judge its successful match, Otherwise, it is determined that for it fails to match;
The character representation of fixed position in numeric type message is PLMC identification fields by (3-2), remembers the PLMC identification fields of message It is expressed as:(P, l, m, c), wherein P is process data tab character, and l is process data start bit, and m is the total position of process data Number, c are process feature position;
(3-3) will be ordinary numeric value type message with the failure of prophesy storehouse matching and without the message classification of PLMC identification fields;It will With prophesy storehouse matching success but without the message classification of PLMC identification fields be matched numeric type message, with foretell storehouse matching, really Whether the fixed matched numeric type message needs priori message;It will be with the success of prophesy storehouse matching and with the message of PLMC identification fields It is classified as mark formula numeric type message;Increase unique pressure in the tail portion of ordinary numeric value type message and process value type message respectively Contracting flag bit;
(4) huffman coding is first carried out to increasing the ordinary numeric value type message after compressing flag bit, then to huffman coding As a result RLE codings are carried out, are sent to receiving terminal after finally carrying out Big Dipper message encapsulation, the data compression stage terminates;
(5) the mark formula number to needing the matched numeric type message of priori message after increasing compression flag bit and C are 0 Value type message carries out priori message difference, obtains difference message, then executes step (7);
(6) to increase compress flag bit after do not need priori message matched numeric type message and C for 0 mark Formula numeric type message carries out difference to its neighboring unit module data, obtains difference message, then executes step (7);
(7) coding is indexed to the process data message segment in difference message, with the process data message segment after coding Original process data message end is substituted, complete message is reassembled into;Huffman coding is first carried out to the message after combination, RLE codings are carried out to huffman coding result again, receiving terminal, data compression stage are sent to after finally carrying out Big Dipper message encapsulation Terminate;
In decompression phase, receiving terminal receives the message that transmitting terminal is sent, and according to the compression flag bit of message tail into Row decompression corresponding with compress mode.
Further, it is total to be included in characteristic value, message possessed by message specific position for the feature in the characteristic matching Length, process data position.
Further, in the step (5) priori message difference the specific steps are:
The last Data Matching message sent is taken out as priori message from buffering area, and priori message W is:
(a0,a1,…,ai,…,ak,…,an)
This message N0 is:
(b0,b1,…,bi,…,bk,…,bn)
Matching message process data position is i-th Dao k, i.e. (ai,…,ak) and (bi,…,bk) matching;Then difference message D0 For:
[b0,b1,…,(bi…bk)-(ai…ak),…,bn];
By calculated matching message process data and difference packet storage to buffering area.
Further, in the step (6) to the neighboring unit module data of message carry out difference the specific steps are:
Defining original message N1 is:
(d0,d1,…,dl,…,dl+c-1,dl+c,…,dl+2c-1,…,dl+(i-1)c,…,dl+(i-1)c+k,…,dl+ic-1,…, dl+m-1,…,dn)
Wherein, l is process data start bit, and m is process data total bit, and c are process feature position, dl,…,dl+c-1For First unit module, dl+c,…,dl+2c-1For second unit module, dl+(i-1)c,…,dl+ic-1For i-th cell module, original message One is shared in N1A unit module;Completely retain first unit module data when difference, neighboring unit module data thereafter Become the difference with previous unit module data, difference message D1 is:
Further, the specific of coding is indexed to the process data message segment in difference message in the step (7) Step is:
Defining difference message N is:
(d0,d1,dl,dl+c-1,…,0,0,0,de,df,dg,0,0,dh,0,0,0,0,…dk,…,dn)
Process data message segment in N is:
dl,dl+c-1,…,0,0,0,de,df,dg,0,0,dh,0,0,0,0,…dk
Wherein, de,df,dg,dkIt is non-zero byte;
Rope number coding is carried out to process data message segment, corresponding index code table S is:
(1,1,…,0,0,0,1,1,1,0,0,1,0,0,0,0,…,1)
Indexing coding message IX is:
[(11...0001110010000...1), dl, dl+c-1, de, df, dg, dh..., dn]。
Further, the decompression phase the specific steps are:
1) after, receiving terminal receives message, Big Dipper message compression flag bit is parsed, judges the compression side of former data Formula;
2) when, being decompressed to text-type message, first remove compression flag bit, then carry out Hofmann decoding, finally carry out LZ77 is decoded;
3) when, being decompressed to ordinary numeric value type message, RLE decodings are first carried out, then carry out Hofmann decoding;
4) when, being decompressed to process value type message, obtained data are determined that each non-zero byte corresponds to by indexing code table Initial data position, 0 filling of other positions, then initial data is restored to by solving corresponding difference algorithm;
The corresponding difference algorithm of the solution includes:PLMC identification fields are checked whether there is in obtained message, are not carried out then Foretell that storehouse matching, extraction process data message section determine that it is priori difference or neighboring unit module data difference fraction, if you need to Priori message then recalls required priori message from memory block and carries out solution difference;If having PLMC identification fields and C in obtained message It is non-zero, then it recalls priori message and carries out solution priori difference;If there are PLMC identification fields in obtained message and C being zero, solved Neighboring unit module data difference.
Advantageous effect:In existing Big Dipper short message compression method, one is can be directed to specific application scenarios to carry out The selection of data compression pattern, such as Chinese Word Intelligent Segmentation and the joint compression algorithm of lossless compression-encoding and the rope of regular length Draw transmission etc. of the code table for fishery harvesting data, compression effectiveness is preferable but the portable difference of compression method;One is use letter The transplanting of single compression algorithm is improved, but adaptability is poor in practical application, is compressed for different messages It is more larger than floating.
Compared with prior art, present invention incorporates the compression methods under different application scenarios, according to Big Dipper message The statistical result of type studies the space characteristic of message, and propose message data type is judged after use The compress mode of corresponding compression algorithm, can keep relatively high and stable compression while enhancing algorithm portability Than.
Description of the drawings
Fig. 1 is compression process flow chart of the present invention;
Fig. 2 is type of message classification schematic diagram.
Specific implementation mode
The present invention is further described below in conjunction with the accompanying drawings.
The present invention provides a kind of Big Dipper short message compression methods, include mainly two processes of compression and decompression.
A, it is as shown in Figure 1 compression process flow chart, including:
Step 1) carries out data type analysis to the message to be sent of transmitting terminal, and judgment method is as follows:
If text-type data amount check is An, numeric type data number is Ac, the type factor:
It understands to work as x>Text class data are dominant when 0, otherwise numeric type data is dominant, and situation in x=0 practical applications Less, this method wouldn't give discussion.Regulation is worked as | x |>When 0.7, i.e., any one data account for total data number more than 85% when and Assert that it is this message main Types.
Type of message is classified as shown in Fig. 2, if data type carries out step 2) using text data as main Types; If using numeric type data as main Types, process data is determined whether using matched and mark formula, is not to carry out Step 3) is that process data carries out step 4).The matched refers to prestoring the format of part prevalence message as prophesy The message received is carried out characteristic matching to judge message format, if format by message, composition prophesy library with prophesy message It is higher with spending, then it can determine that it is process data, corresponding compression method used to it, otherwise it fails to match, described to be characterized in Refer to based on the set form of message, is included in characteristic value possessed by specific position, message total length, process data position etc. Part or all of information;The mark formula refers to, it is specified that sending message in fixed position with (P, l, m, c) identification fields (abbreviation PLMC identification fields) illustrate the data characteristics of process data, wherein P be process data tab character (can also be character string or Digital coding), l is process data start bit, and m is process data total bit, and c are process feature position, is to indicate to need when c is 0 It wants priori message to carry out compression processing, unit module data bits is indicated when c is non-zero, the priori message refers to last hair The message for the same format sent.In no process data identification fields and common number cannot be determined that it is with when foretelling storehouse matching success Value type message.
The data for increasing 2bit in message tail are used as the compression flag bit for indicating compress mode, and judging result is text Type message timestamp is denoted as 01, and numeric type message is 10 (ordinary numeric value type messages) or 11 (process value type messages), and following Only the original message data in addition to compressing flag bit is handled in compression step.
Step 2), 01 text-type message compression use LZ77 to encode logarithm first using LZ77- Huffman encoding algorithms According to primary compression is carried out, the LZ77 codings refer to substituting weight by the uncompressed data more early occurred in reference data stream It appears again existing data, to realize the compression of data.A kind of number of " length-distance to " is then used the references of uncompressed data Induction-arrangement is carried out according to structure, i.e., for the data in character string of each given length etc. later particular offset, is led to Sliding window is crossed to store the data buffer storage of certain length, buffer data is used for searching matching;By making after primary compression Reduce the average length and desired value of data with huffman coding, the huffman coding refer to the high character of occurrence probability with compared with Short coding, the low symbol of occurrence probability is with compared with long codes.
Step 3), 10 ordinary numeric value type message compressions, Huffman-RLE encryption algorithms.The RLE compression algorithms refer to leading to It crosses the identical element continuously repeated to carry out integrating elimination redundancy, be replaced by using data and its length in initial data Hold.
Step 4), 11 process value type message compressions, as shown in table 1:
1 process value type message differential mode of table corresponds to table
A, for C 0 and to need the matched process value type message of priori message, following differential mode is carried out, this Text is called priori differential type, is a kind of mode for needing priori message to carry out difference, and step is:
The last Data Matching message sent is taken out as priori message from buffering area, and priori message W is
(a0,a1,…,ai,…,ak,…,an)
This message N0 is:
(b0,b1,…,bi,…,bk,…,bn)
Matching message process data position is i to k, i.e. (ai,…,ak) and (bi,…,bk) matching;Then difference message D0 is
[b0,b1,…,(bi…bk)-(ai…ak),…,bn],
And preserve the calling of this data information waiting next time.
B, C it is non-zero when to corresponding identification fields provide information, to neighboring unit module data carry out difference, referred to herein as its For adjacent first differential type, in matched message also having segment message takes such differential mode.Original message N1 is (d0, d1,…,dl,…,dl+c-1,dl+c,…,dl+2c-1,…,dl+(i-1)c,…,dl+(i-1)c+k,…,dl+ic-1,…,dl+m-1,…,dn)
Wherein l is process data start bit, and m is process data total bit, and c is unit module data bits, dl,…, dl+c-1For first unit module, dl+c,…,dl+2c-1For second unit module ..., dl+(i-1)c,…,dl+ic-1For i-th cell mould Block, the shared unit module of original message N1 mono-, when difference, completely retain first unit module data, thereafter neighboring unit module Data become itself and previous mouldThe difference of block number evidence, difference message D1 are
d0,d1,…,dl,…,dl+c-1,(dl+c…dl+2c-1)-(dl…dl+c-1),…,(dl+(i-1)c…dl+ic-1),
-(dl+(i-2)c…dl+(i-1)c-1),(dl+ic…dl+(i+1)c-1)
-(dl+(i-1)c…dl+ic-1,…,dn)
Since process data is typically all the data of in chronological sequence acquisition order, there is regular hour characteristic, and There is certain relevance, numerical value becomes smaller and many places become so will appear after process data message segment progress difference between numerical value For 0 byte the case where.Do not consider that 0 character in original message, poor message distribution are similar to message N
(d0,d1,dl,dl+c-1,…,0,0,0,de,df,dg,0,0,dh,0,0,0,0,…dk,…,dn)
Wherein process message segment is
dl,dl+c-1,…,0,0,0,de,df,dg,0,0,dh,0,0,0,0,…dk
Wherein, de、df、dg、dkIt is non-zero byte;
Then rope number coding is carried out to process data message segment, corresponding index code table S is
(1,1,…,0,0,0,1,1,1,0,0,1,0,0,0,0,…,1)
Then non-zero in transmission difference message after transmission indexes code table, index coding message IX is:
[(11...0001110010 000...1), dl, dl+c-1, de, df, dg, dh..., dn]
Process data message after coding is substituted into original process data message, is held after being reassembled into complete message Row step 3) is further compressed.
B, decompression is equivalent to the inverse process of compression, and decompression process includes:
After step 1), receiving terminal receive message, Big Dipper message is parsed, compression flag bit is parsed, is judged The compress mode of former data, compression flag bit carry out step 2) when being 01, compression flag bit carries out step 3), compression mark when being 10 Step 4) is carried out when will position is 11.
Step 2), the decompression of 01 text-type message, remove compression flag bit, first carry out Hofmann decoding, then carry out LZ77 Decoding.
Step 3), the decompression of 10 ordinary numeric value type messages, Hofmann decoding is carried out after RLE decodings.
Step 4), the decompression of 11 process value type messages, carry out step 3), and obtained data are determined by indexing code table The data of each non-zero byte correspond to expression Data Position and are high-order or low levels, restore eventually by corresponding difference algorithm is solved To initial data.The corresponding difference algorithm of the solution refers to that PLMC identification fields are checked whether there is in obtained message, not then into Row prophesy storehouse matching, extraction process data message section determine that it is priori differential type or adjacent first differential type, if you need to priori message Then required message is recalled from memory block carry out solution difference;Have and C non-zero, recalls priori message and carry out solution priori difference;Have and C Position is zero, carries out solving adjacent first difference.
The content of present invention is described further below by specific embodiment.
1, text-type message
If text-type message is:ABABCBABABCAD
Compression stage:
Type of message is identified first, An=13, Ac=0, the type factor are obtained by scanning messagex>0.7 and x is just, it is determined that it is text-type message, to increase marker bit 01 in message tail, former Beginning message becomes ABABCBABABCAD (01).
Then start to compress, LZ77 compressions are carried out to the message content in addition to compressing flag bit, when compressed data, There can be 2 kinds of situations between forward direction buffering area and moving window after phrase match is:It can will not when can not find matching The symbolic coding matched is at sign flag (majority is all character itself);Its longest matching is then encoded into phrase when finding matching Label.P-marker includes three parts information:(in the offset (being calculated since the place matching), matching in sliding window Symbol numbers, first symbol in the forward direction buffering area after matching).Default sliding window is 8byte, and buffering area is 4byte, the then message obtained after being compressed by LZ77 are:
AB (6,2, C) (4,3, A) (2,2, A) D (01).
The message obtained after being compressed later to LZ77 carries out huffman coding, and according to huffman coding principle, small value is just It is indicated with less bit, big value is just indicated with more bit, for example, we protect above-mentioned compression offset and number in text Huffman coding is carried out, the value of the offset-number obtained after LZ77 compressions is:
6,2,4,3,2,2
In this example, 2 occur 3 times, and 3 occur 1 time, and 4 occur 1 time, and 6 occur 1 time, have here 4 it is whole Number, it is only necessary to which 2bit is indicated, such as code table:
0→2,10→3,110→4,111→6
Become after above-mentioned message compression:
11101101000
Code table is first transmitted when transmission transmits message after compression again.
Decompression phase:
The compression flag information of message end two bits is first checked when decompression, and text-type decompression is confirmed as when being 01 Mode removes compression flag bit 01 after confirmation.
Solution huffman coding is carried out first, message correspondence is decompressed according to code table, such as
Message segment 11101101000
Code table 0 → 2,10 → 3,110 → 4,111 → 6
So message segment decompression procedure is
111 0 110 10 0 0→→6,2,4,3,2,2
LZ77 decodings are carried out to this message after according to code table solution huffman coding, by coding symbols and keep sliding Symbol in window updates decompression data.When decoding character marking refers to copying label coding to sliding window at character In;Decoding P-marker is then the lookup response offset amount in sliding window, while the phrase for finding specified length is replaced. Such as LZ77 decodings are carried out to message AB (6,2, C) (4,3, A) (2,2, A) D, sliding window 8byte is decoded as label A A is decoded as AB to label B, ABABC is decoded as ... to label (6,2, C), and final decoding result is ABABCBABABCAD.
2, numeric type message
Provide following four kinds of messages:
Message 1:50 16 10 10 00 78 24 00 00 95 71 00 00 EE EE
Message 2:16 83 62 04 17 04 15 54 P 04 05 00 03 63 18
Message 3:15 82 17 03 07 04 11 13 04 17 04 15 54 05 27 04 16 AC 06 37 04 1E DC P 04 14 05 00 58 8E
Message 4:68 BE 01 BE 01 68 A8 03 44 07 00 02 0C E1 02 01 01 04 19 09 17 06 11 04 00 00 00 40 26 00 00 40 26 00 00 10 33 00 00 10 33 00 00 20 22 00 00 05 43 00 03 51 16 19 09 17 00 CC 16
Type of message judgement is carried out to above four kinds of messages, judges that formula can obtain above-mentioned report according to the type factor first Text is numeric type message, and 4-7 byte of number is PLMC identification fields before presetting end, wherein 1 no marks section of message and prophesy library With failure, it is determined as that ordinary numeric value type message, message end position add compression flag bit 10;Message 2 has PLMC identification fields, and C are Zero, it is zero message to determine that it is mark formula C, and process value type message, message end position adds compression flag bit 11;Message 3 has PLMC identification fields, and C non-zeros determine that it is C non-zero messages of mark formula, and process value type message, message end position adds compression Flag bit 11;2 no marks section of message but 68 BE of its field, 01 BE 01 68 ... 0C and prophesy storehouse matching, are that 376.1 agreements are whole 1 class data message is held, is determined as that matched process value type message, message end position add compression flag bit 11.
1), ordinary numeric value type message (except compression flag bit)
50 16 10 10 00 78 24 00 00 95 71 00 00 EE EE
Compression
Huffman coding, code table are carried out first:
0→00,1000→EE,1001→10,1010→50,1011→16,
1100→78,1101→24,1110→95,1111→71
Coding message:101010111001100101100110100111011110010001000
RLE coding messages set segment length maximum 4bit, and number is up to 4, and message is after coding:
(3,10) 11 (2,1001) (2,0110) 10 (2,0111) (2,100), 0100
Decompression:
The compression flag information of message end two bits is first checked when decompression, and ordinary numeric value type solution is confirmed as when being 10 Compress mode.
It is encoded according to RLE, previous position is to repeat message segment number, and latter position is to repeat message segment content, solution RLE codings; Later according to huffman code table solution huffman coding.
2), process value type message
A, in this example, in above-mentioned 3 kinds of process-types message data processing procedure, message 2 is similar with message 4, is generation with message 4 Table explains compression process.
Compression:
Step 1, according to prophesy library information, pick out process data message segment, process data message segment is in this example:
00 00 00 40 26 00 00 40 26 00 00 10 33 00 00 10 33 00 00 20 22 00 00 05 43
Step 2, the last process data content for sending such message of inquiry are (if this receives such report for first time Wen Ze skips this step), for example, the process data message segment of last time message is
00 00 00 40 10 00 00 40 10 00 00 10 23 00 00 10 23 00 00 20 00 00 00 05 33
Message segment is after carrying out difference:
00 00 00 00 16 00 00 00 16 00 00 00 10 00 00 00 10 00 00 00 22 00 00 00 10
Step 3 is indexed coding to step 2 gained message, thus code table each represent 4bit data whether be 0, it is not 0 mark 1, index code table corresponds to as follows for 0 mark 0:
00 00 00 00 11 00 00 00 11 00 00 00 10 00 00 00 10 00 00 00 11 00 00 00 10
Process data message segment is after index coding:161611221
Step 3 gained message segment is replaced the process data message segment in former message by step 4, such as ordinary numeric value type message Compression step carries out Huffman-RLE codings.
Decompression:
Step 1, compression flag bit are 11 and determine that it is matched numeric type message, progress not comprising PLMC identification fields It is decompressed with formula data type message;
Step 2, such as ordinary numeric value type message compression step carry out Huffman-RLE coding and decodings;
Step 3, according to matching message format, extraction process data message section, according to index code table to affiliated message segment into Row decoding, so code table each be extended for four, if 0 this four be 0, if 1, be sequentially filled message segment data, such as It replaces with the 1, the 2nd 1 for 1st 1 and replaces with 6 ...;
Step 4, the last process data content for sending such message of solution difference inquiry, with step 3 gained message segment phase Add to obtain this process data section message;
Process data message segment in step 5, the message segment replacement step 2 for obtaining step 4 forms complete message.
B, message 3 is C non-zero messages of mark formula in this example, the difference is that, message 3 is using phase with message 2 The differential mode of adjacent unit module data, also will appear the message for needing neighboring unit module data difference in matched message Type, by foretell library message carry out characterizing definition, in addition to judgment mode when to type of message is different, processing mode with Message 3 is similar, so this explains compression process for sentencing message 3.
Compression:
Step 1, according to PLMC identification fields information extraction process data message sections, known by message segment P 04 14 05, process 4 bytes of data message Duan Cong start, altogether 20 bytes, and unit module data length is 5 bytes, and thus we extract The process data message segment gone out is:
03 07 04 11 13 04 17 04 15 54 05 27 04 16 AC 06 37 04 1E DC
Step 2 retains the 1st cell data, and difference obtains successively
03 07 04 11 13 01 10 00 04 41 01 10 00 01 58 01 10 00 08 30
Step 3 is indexed step 2 the data obtained coding, and index code table is as follows:
01 01 01 11 11 01 10 00 01 11 01 10 00 01 11 01 10 00 01 10
Coded data is:
374111211441111581183
Step 3 gained message segment is replaced the process data message segment in former message by step 4, such as ordinary numeric value type message Compression step carries out Huffman-RLE codings.
Decompression:
Step 1, compression flag bit are 11 and determine that it is matched numeric type message, progress not comprising PLMC identification fields It is decompressed with formula data type message;
Step 2, such as ordinary numeric value type message compression step carry out Huffman-RLE coding and decodings;
Step 3, according to matching message format, extraction process data message section, according to index code table to affiliated message segment into Row decoding, so code table each be extended for four, if 0 this four be 0, if 1, be sequentially filled message segment data, such as It replaces the 3, the 2nd 1 for 1st 1 and replaces with 7 ...
Step 4, solution difference indicate that segment information knows that cell data length is 5 bytes according to PLMC, retain preceding 5 bytes Constant, 6-10 byte datas are added to obtain original 6-10 byte datas, 11-15 byte datas and original 6-10 with 1-5 byte datas Byte data adds up to original 11-15 byte datas, and so on, obtain all initial data;
Process data message segment in step 5, the message segment replacement step 2 for obtaining step 4 forms complete message.
The above is only a preferred embodiment of the present invention, it should be pointed out that:For the ordinary skill people of the art For member, various improvements and modifications may be made without departing from the principle of the present invention, these improvements and modifications are also answered It is considered as protection scope of the present invention.

Claims (6)

1. a kind of compression transmitting method based on Big Dipper short message, which is characterized in that this method includes the reconciliation of data compression stage Compression stage;
In the data compression stage, transmitting terminal executes step:
(1) transmitting terminal calculates type factor x according to the number of text-type data and numeric type data in current message to be transmitted:
In formula, AnFor the number of text-type data in current message to be transmitted, AcFor numeric type data in current message to be transmitted Number;By type factor x compared with pre-set threshold X, when type factor absolute value is more than threshold X, by corresponding message It is classified as text-type message, increases unique compression flag bit in message tail, and execute step (2);Otherwise, by corresponding message It is classified as numeric type message, and executes step (3);
(2) to text-type message, LZ77 codings is first carried out and realize primary compression, Huffman is carried out again to the data after primary compression Coding is sent to receiving terminal after finally carrying out Big Dipper message encapsulation, and the data compression stage terminates;
(3) numeric type message is divided into process value type message and ordinary numeric value type message, wherein process value type message again into One step be subdivided into matched numeric type and mark formula numeric type message, and indicate formula numeric type message according to C whether be Zero is two kinds of message, including step:
(3-1) prestores part prevalence message as prophesy message, and composition prophesy library will be in numeric type message and prophesy library It foretells that message carries out characteristic matching, if characteristic matching degree is more than preset matching degree threshold value, judges its successful match, it is no Then, it is determined as that it fails to match;
The character representation of fixed position in numeric type message is PLMC identification fields by (3-2), remembers that the PLMC identification fields of message indicate For:(P, l, m, c), wherein P be process data tab character, l be process data start bit, m be process data total bit, c For process feature position;
(3-3) will be ordinary numeric value type message with the failure of prophesy storehouse matching and without the message classification of PLMC identification fields;Will with it is pre- It says storehouse matching success but is matched numeric type message without the message classification of PLMC identification fields, then basis and prophesy storehouse matching As a result, determine the matched numeric type message whether need priori message;It will be with the success of prophesy storehouse matching and with PLMC marks The message classification of will section is mark formula numeric type message;Increase respectively in the tail portion of ordinary numeric value type message and process value type message Add unique compression flag bit;
(4) huffman coding is first carried out to increasing the ordinary numeric value type message after compressing flag bit, then to huffman coding result RLE codings are carried out, are sent to receiving terminal after finally carrying out Big Dipper message encapsulation, the data compression stage terminates;
(5) the mark formula numeric type to needing the matched numeric type message of priori message after increasing compression flag bit and C are 0 Message carries out priori message difference, obtains difference message, then executes step (7);
(6) to increase compress flag bit after do not need priori message matched numeric type message and C for 0 mark formula number Value type message carries out difference to its neighboring unit module data, obtains difference message, then executes step (7);
(7) coding is indexed to the process data message segment in difference message, is substituted with the process data message segment after coding Original process data message end, is reassembled into complete message;Huffman coding is first carried out to the message after combination, then right Huffman coding result carries out RLE codings, and receiving terminal, data compression stage knot are sent to after finally carrying out Big Dipper message encapsulation Beam;
In decompression phase, receiving terminal receives the message that transmitting terminal is sent, and according to the compression flag bit of message tail carry out with The corresponding decompression of compress mode.
2. a kind of compression transmitting method based on Big Dipper short message according to claim 1, which is characterized in that the feature The feature matched is included in characteristic value, message total length, process data position possessed by message specific position.
3. a kind of compression transmitting method based on Big Dipper short message according to claim 1, which is characterized in that the step (5) in priori message difference the specific steps are:
The last Data Matching message sent is taken out as priori message from buffering area, and priori message W is:
(a0,a1,…,ai,…,ak,…,an)
This message N0 is:
(b0,b1,…,bi,…,bk,…,bn)
Matching message process data position is i-th Dao k, i.e. (ai,…,ak) and (bi,…,bk) matching;Then difference message D0 is:
[b0,b1,…,(bi…bk)-(ai…ak),…,bn];
By calculated matching message process data and difference packet storage to buffering area.
4. a kind of compression transmitting method based on Big Dipper short message according to claim 3, which is characterized in that the step (6) in the neighboring unit module data of message carry out difference the specific steps are:
Defining original message N1 is:
(d0,d1,…,dl,…,dl+c-1,dl+c,…,dl+2c-1,…,dl+(i-1)c,…,dl+(i-1)c+k,…,dl+ic-1,…, dl+m-1,…,dn)
Wherein, l is process data start bit, and m is process data total bit, and c are process feature position, dl,…,dl+c-1It is first Unit module, dl+c,…,dl+2c-1For second unit module, dl+(i-1)c,…,dl+ic-1For i-th cell module, in original message N1 One is sharedA unit module;Completely retain first unit module data when difference, neighboring unit module data thereafter become With the difference of previous unit module data, difference message D1 is:
5. a kind of compression transmitting method based on Big Dipper short message according to claim 4, which is characterized in that the step (7) in the process data message segment in difference message be indexed coding the specific steps are:
Defining difference message N is:
(d0,d1,dl,dl+c-1,…,0,0,0,de,df,dg,0,0,dh,0,0,0,0,…dk,…,dn)
Process data message segment in N is:
dl,dl+c-1,…,0,0,0,de,df,dg,0,0,dh,0,0,0,0,…dk
Wherein, de、df, dg, dkIt is non-zero byte;
Rope number coding is carried out to process data message segment, corresponding index code table S is:
(1,1,…,0,0,0,1,1,1,0,0,1,0,0,0,0,…,1)
Indexing coding message IX is:
[11...0001110010000...1), dl, dl+c-1, de, df, dg, dh..., dn]。
6. a kind of compression transmitting method based on Big Dipper short message according to claim 5, which is characterized in that the decompression Stage the specific steps are:
1) after receiving terminal receives message, Big Dipper message compression flag bit is parsed, judges the compress mode of former data;
2) when being decompressed to text-type message, first remove compression flag bit, then carry out Hofmann decoding, finally carry out LZ77 solutions Code;
3) when being decompressed to ordinary numeric value type message, RLE decodings are first carried out, then carry out Hofmann decoding;
4) when being decompressed to process value type message, obtained data are determined into the corresponding original of each non-zero byte by indexing code table Beginning Data Position, 0 filling of other positions, then it is restored to initial data by solving corresponding difference algorithm;
The corresponding difference algorithm of the solution includes:PLMC identification fields are checked whether there is in obtained message, are not foretold then Storehouse matching, extraction process data message section determine that it is priori difference or neighboring unit module data difference fraction, if you need to priori Message then recalls required priori message from memory block and carries out solution difference;If having PLMC identification fields in obtained message and C being non-zero, It then recalls priori message and carries out solution priori difference;If there are PLMC identification fields in obtained message and C being zero, solve adjacent Unit module data difference.
CN201810495167.8A 2018-05-22 2018-05-22 Compression transmission method based on Beidou short message Expired - Fee Related CN108737976B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810495167.8A CN108737976B (en) 2018-05-22 2018-05-22 Compression transmission method based on Beidou short message

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810495167.8A CN108737976B (en) 2018-05-22 2018-05-22 Compression transmission method based on Beidou short message

Publications (2)

Publication Number Publication Date
CN108737976A true CN108737976A (en) 2018-11-02
CN108737976B CN108737976B (en) 2021-05-04

Family

ID=63938843

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810495167.8A Expired - Fee Related CN108737976B (en) 2018-05-22 2018-05-22 Compression transmission method based on Beidou short message

Country Status (1)

Country Link
CN (1) CN108737976B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110149600A (en) * 2019-05-15 2019-08-20 青岛农业大学 A method of it is communicated based on dipper system
CN110166959A (en) * 2019-05-15 2019-08-23 青岛农业大学 A kind of compression method carrying out big data communication for Beidou short message
CN110166958A (en) * 2019-05-15 2019-08-23 青岛农业大学 A method of big data communication is carried out using Beidou short message
CN110913433A (en) * 2019-10-29 2020-03-24 长沙海格北斗信息技术有限公司 PVT information compression transmission method based on Beidou short message
CN111163038A (en) * 2018-11-08 2020-05-15 财团法人车辆研究测试中心 Vehicle-mounted network data sampling conversion method and system
WO2021051532A1 (en) * 2019-09-16 2021-03-25 平安科技(深圳)有限公司 Data compression method, apparatus and device, and computer-readable storage medium
CN112804271A (en) * 2021-04-15 2021-05-14 中国气象科学研究院 Data compression method, device, terminal and computer readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103258030A (en) * 2013-05-09 2013-08-21 西安电子科技大学 Mobile device memory compression method based on dictionary encoding and run-length encoding
EP2962396A1 (en) * 2013-03-01 2016-01-06 Gurulogic Microsystems OY Entropy modifier and method
CN105743616A (en) * 2016-05-06 2016-07-06 南京大学 Long message segmentation and reliable communication method based on Beidou short message communication
CN106559668A (en) * 2015-09-25 2017-04-05 电子科技大学 A kind of low code rate image compression method based on intelligent quantization technology
CN106776677A (en) * 2016-10-25 2017-05-31 腾讯科技(深圳)有限公司 Document conversion method, device and document transmission system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2962396A1 (en) * 2013-03-01 2016-01-06 Gurulogic Microsystems OY Entropy modifier and method
CN103258030A (en) * 2013-05-09 2013-08-21 西安电子科技大学 Mobile device memory compression method based on dictionary encoding and run-length encoding
CN106559668A (en) * 2015-09-25 2017-04-05 电子科技大学 A kind of low code rate image compression method based on intelligent quantization technology
CN105743616A (en) * 2016-05-06 2016-07-06 南京大学 Long message segmentation and reliable communication method based on Beidou short message communication
CN106776677A (en) * 2016-10-25 2017-05-31 腾讯科技(深圳)有限公司 Document conversion method, device and document transmission system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
王鑫旭: "应用XML技术的RFID集成数据压缩算法研究", 《中国优秀硕士学位论文全文数据库信息科技辑》 *

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111163038A (en) * 2018-11-08 2020-05-15 财团法人车辆研究测试中心 Vehicle-mounted network data sampling conversion method and system
CN110149600A (en) * 2019-05-15 2019-08-20 青岛农业大学 A method of it is communicated based on dipper system
CN110166959A (en) * 2019-05-15 2019-08-23 青岛农业大学 A kind of compression method carrying out big data communication for Beidou short message
CN110166958A (en) * 2019-05-15 2019-08-23 青岛农业大学 A method of big data communication is carried out using Beidou short message
CN110149600B (en) * 2019-05-15 2021-09-03 青岛农业大学 Communication method based on Beidou system
CN110166958B (en) * 2019-05-15 2021-11-09 青岛农业大学 Method for carrying out big data communication by using Beidou short message
WO2021051532A1 (en) * 2019-09-16 2021-03-25 平安科技(深圳)有限公司 Data compression method, apparatus and device, and computer-readable storage medium
CN110913433A (en) * 2019-10-29 2020-03-24 长沙海格北斗信息技术有限公司 PVT information compression transmission method based on Beidou short message
CN110913433B (en) * 2019-10-29 2023-05-26 长沙金维信息技术有限公司 PVT information compression transmission method based on Beidou short message
CN112804271A (en) * 2021-04-15 2021-05-14 中国气象科学研究院 Data compression method, device, terminal and computer readable storage medium

Also Published As

Publication number Publication date
CN108737976B (en) 2021-05-04

Similar Documents

Publication Publication Date Title
CN108737976A (en) A kind of compression transmitting method based on Big Dipper short message
EP1134901B1 (en) Method and apparatus for data compression of network packets employing per-packet hash tables
CA2321233C (en) Block-wise adaptive statistical data compressor
US7764202B2 (en) Lossless data compression with separated index values and literal values in output stream
US6100824A (en) System and method for data compression
EP0793349A2 (en) Method and apparatus for performing data compression
US8872677B2 (en) Method and apparatus for compressing data-carrying signals
EP0438955B1 (en) Data compression method
WO2011007956A2 (en) Data compression method
EP0903866B1 (en) Method and apparatus for data compression
CN107565970B (en) Hybrid lossless compression method and device based on feature recognition
US6301394B1 (en) Method and apparatus for compressing data
JP4760727B2 (en) Data compression apparatus, decoding apparatus thereof, method thereof, and program
CN116055008B (en) Router data processing method for cloud server connection
KR101667240B1 (en) Secure and lossless data compression
Mahmood et al. An Efficient 6 bit Encoding Scheme for Printable Characters by table look up
EP0438954B1 (en) Method of decoding compressed data
KR100636370B1 (en) Apparatus and method for coding using bit-precision, and apparatus and method for decoding according to the same
GB2334653A (en) Data compression system with dictionary updating algorithm
US7750826B2 (en) Data structure management for lossless data compression
KR101791877B1 (en) Method and apparatus for compressing utf-8 code character
US20020176633A1 (en) Method of compressing data by use of self-prefixed universal variable length code
CN109831211B (en) Semi-dynamic data compression algorithm using control symbols
KR101752281B1 (en) Method and apparatus for compressing utf-8 code character
CN111342844B (en) LZW coding and improved run-length coding-based radar data lossless compression and decompression method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20210504