CN110769361A - Method and device for compressing and decompressing positioning information - Google Patents

Method and device for compressing and decompressing positioning information Download PDF

Info

Publication number
CN110769361A
CN110769361A CN201810821550.8A CN201810821550A CN110769361A CN 110769361 A CN110769361 A CN 110769361A CN 201810821550 A CN201810821550 A CN 201810821550A CN 110769361 A CN110769361 A CN 110769361A
Authority
CN
China
Prior art keywords
longitude
information
data
coordinate
target
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
CN201810821550.8A
Other languages
Chinese (zh)
Other versions
CN110769361B (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.)
HARBIN HAINENGDA TECHNOLOGY Co Ltd
Original Assignee
HARBIN HAINENGDA TECHNOLOGY Co Ltd
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 HARBIN HAINENGDA TECHNOLOGY Co Ltd filed Critical HARBIN HAINENGDA TECHNOLOGY Co Ltd
Priority to CN201810821550.8A priority Critical patent/CN110769361B/en
Publication of CN110769361A publication Critical patent/CN110769361A/en
Application granted granted Critical
Publication of CN110769361B publication Critical patent/CN110769361B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/02Services making use of location information
    • H04W4/025Services making use of location information using location based information parameters
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W64/00Locating users or terminals or network equipment for network management purposes, e.g. mobility management

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The application provides a method and a device for compressing and decompressing positioning information, which respectively determine a target high latitude area to which the latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude area and a target coordinate conversion rule when the obtained latitude coordinate of a terminal is greater than a high latitude area critical coordinate, further convert longitude integer information into data on the longitude integer information occupation digit according to the target coordinate conversion rule, convert longitude decisecond information into data on the longitude decisecond information occupation digit to obtain first compressed data, and send the first compressed data to a base station; therefore, when the latitude coordinate of the terminal belongs to the high latitude area coordinate, the integral information of the longitude coordinate is converted and compressed along with the longitude decisecond information according to the corresponding target coordinate conversion rule, and is sent to the base station for reduction, so that the problem of longitude coordinate distortion in a high latitude area is solved, and the reduction accuracy of the compressed positioning information is further ensured.

Description

Method and device for compressing and decompressing positioning information
Technical Field
The present invention relates to the field of data compression, and more particularly, to a method and an apparatus for compressing and decompressing positioning information.
Background
With the development of wireless communication technology, people have established a large number of communication base stations in the global scope, so as to use the communication base stations as wireless positioning base stations, and position the accurate position of the user terminal according to self-positioning information (latitude and longitude coordinates) sent by the user terminal.
In order to increase the rate at which the user terminal sends its own positioning information to the base station, the user terminal often compresses the positioning information and then sends the compressed positioning information to the base station. At present, the compression method adopted by the user terminal usually omits the integer information (degree) of the longitude and latitude coordinates, only compresses the microsecond information of the longitude and latitude coordinates, and transmits the compressed information to the base station, so that the base station adds the integer information of the longitude and latitude coordinates and the decompressed microsecond information to restore the accurate position of the user terminal. However, since the coverage radius of the base station in the high latitude area spans two longitude lines, when the longitude coordinate of the user terminal in the high latitude area is compressed by the existing compression method, the longitude coordinate restored by the base station is deviated, and the problem of longitude coordinate distortion is caused.
Disclosure of Invention
In view of this, the present invention provides a method and an apparatus for compressing and decompressing positioning information, which solve the problem of longitude coordinate distortion in high latitude areas.
In order to achieve the purpose, the invention provides the following technical scheme:
a compression method of positioning information is applied to a terminal and comprises the following steps:
acquiring positioning information of a terminal, wherein the positioning information comprises a longitude coordinate and a latitude coordinate, and the longitude coordinate comprises longitude integer information and longitude millisecond information;
when the latitude coordinate is larger than a high latitude area critical coordinate, determining a target high latitude area to which the latitude coordinate belongs, a target data occupation digit and a target coordinate conversion rule, wherein the target data occupation digit comprises a longitude integer information occupation digit and a longitude decisecond information occupation digit;
converting the longitude integer information into data on the number of occupied digits of the longitude integer information according to the target coordinate conversion rule, and converting the longitude decisecond information into data on the number of occupied digits of the longitude decisecond information;
and taking the converted data on the number of bits occupied by the longitude integer information and the converted data on the number of bits occupied by the longitude decisecond information as first compressed data, and sending the first compressed data to a base station.
Preferably, when the latitude coordinate is greater than the high latitude area critical coordinate, determining a target high latitude area to which the latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude area, and a target coordinate conversion rule includes:
when the latitude coordinate is larger than the critical coordinate of the high latitude area, judging whether the latitude coordinate belongs to a first high latitude area;
if the latitude coordinate belongs to the first high latitude area, the first high latitude area is used as the target high latitude area, a first data occupation digit corresponding to the first high latitude area is used as the target data occupation digit, a first coordinate conversion rule corresponding to the first high latitude area is used as the target coordinate conversion rule, the first data occupation digit comprises a 1-bit longitude integer information occupation digit and a 12-bit longitude decisecond information occupation digit, and the first coordinate conversion rule comprises a first longitude integer information conversion rule and a first longitude decisecond information conversion rule.
Preferably, the converting the longitude integer information into data on the number of bits occupied by the longitude integer information and the converting the longitude decisecond information into data on the number of bits occupied by the longitude decisecond information according to the target coordinate conversion rule includes:
judging whether the longitude integer information is even number;
if the longitude integer information is even degree, converting the longitude integer information into 0 according to a first longitude integer information conversion rule in the target coordinate conversion rule, and using the 0 as data of the 1-bit longitude integer information occupying bit number;
if the longitude integer information is odd-numbered, converting the longitude integer information into 1 according to a first longitude integer information conversion rule in the target coordinate conversion rule, and using the 1-bit longitude integer information as data occupying the number of bits;
and converting the longitude deciseconds information into data of the 12-bit longitude deciseconds information occupying digits by using a longitude deciseconds information conversion formula according to a first longitude deciseconds information conversion rule in the target coordinate conversion rule.
Preferably, after determining that the latitude coordinate does not belong to the first high latitude region, the method further includes:
judging whether the latitude coordinate belongs to a second high latitude area, wherein the second high latitude area is larger than the first high latitude area;
if the latitude coordinate belongs to the second high latitude area, the second high latitude area is used as the target high latitude area, a second data occupation bit corresponding to the second high latitude area is used as the target data occupation bit, a second coordinate conversion rule corresponding to the second high latitude area is used as the target coordinate conversion rule, the second data occupation bit comprises a 2-bit longitude integer information occupation bit and an 11-bit longitude decisecond information occupation bit, and the second coordinate conversion rule comprises a second longitude integer information conversion rule and a second longitude decisecond information conversion rule.
Preferably, the converting the longitude integer information into data on the number of bits occupied by the longitude integer information and the converting the longitude decisecond information into data on the number of bits occupied by the longitude decisecond information according to the target coordinate conversion rule includes:
performing mod4 operation on the longitude integer information according to a second longitude integer information conversion rule in the target coordinate conversion rule to obtain an operation result, and converting the operation result into binary data serving as data of the number of bits occupied by the 2-bit longitude integer information;
and converting the longitude deciseconds information into data of the 11-bit longitude deciseconds information occupying digits by using a longitude deciseconds information conversion formula according to a second longitude deciseconds information conversion rule in the target coordinate conversion rule.
Preferably, after determining that the latitude coordinate does not belong to the second high latitude region, the method further includes:
judging whether the latitude coordinate belongs to a third high latitude area, wherein the third high latitude area is larger than the second high latitude area;
if the latitude coordinate belongs to the third high latitude area, taking the third high latitude area as the target high latitude area, taking a third data occupation digit corresponding to the third high latitude area as the target data occupation digit, taking a third coordinate conversion rule corresponding to the third high latitude area as the target coordinate conversion rule, wherein the third data occupation digit comprises a 3-bit longitude integer information occupation digit and a 10-bit longitude decisecond information occupation digit, and the third coordinate conversion rule comprises a third longitude integer information conversion rule and a third longitude decisecond information conversion rule.
Preferably, the converting the longitude integer information into data on the number of bits occupied by the longitude integer information and the converting the longitude decisecond information into data on the number of bits occupied by the longitude decisecond information according to the target coordinate conversion rule includes:
performing mod8 operation on the longitude integer information according to a third longitude integer information conversion rule in the target coordinate conversion rule to obtain an operation result, and converting the operation result into binary data serving as data of the 3-bit longitude integer information occupying the bit number;
and converting the longitude deciseconds information into data of the 10-bit longitude deciseconds information occupying digits by using a longitude deciseconds information conversion formula according to a third longitude deciseconds information conversion rule in the target coordinate conversion rule.
Preferably, the compression method further comprises:
when the latitude coordinate is smaller than or equal to the high latitude area critical coordinate, utilizing a longitude, minute and second information conversion formula to convert the longitude, minute and second information to obtain second compressed data;
transmitting the second compressed data to the base station.
A decompression method of positioning information is applied to a base station and comprises the following steps:
acquiring longitude coordinates of a base station;
receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by converted longitude integer information and data on the number of bits occupied by longitude minute-second information;
determining a target decompression rule corresponding to the first compressed data;
and decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal.
Preferably, the determining the target decompression rule corresponding to the first compressed data includes:
and when the longitude integer information occupation bit number is 1 bit and the longitude deciseconds information occupation bit number is 12 bits, taking a first decompression rule as the target decompression rule, wherein the first decompression rule comprises a first longitude integer information decompression rule and a first longitude seconds information decompression rule.
Preferably, the decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal includes:
when base station longitude integer information in the base station longitude coordinate is even degree and data on occupied digits of the converted longitude integer information is 0, taking the base station longitude integer information as longitude integer information of a terminal according to the first longitude integer information decompression rule;
or, when the base station longitude integer information in the base station longitude coordinate is an even degree and the data of the converted longitude integer information on the occupied digit is 1, according to the first longitude integer information decompression rule, taking the value obtained by subtracting 1 from the base station longitude integer information as the longitude integer information of the terminal;
or, when the base station longitude integer information in the base station longitude coordinate is odd-numbered degree and the data on the bit occupied by the converted longitude integer information is 0, taking the value obtained by subtracting 1 from the base station longitude integer information as the longitude integer information of the terminal;
or, when the base station longitude integer information in the base station longitude coordinate is odd-numbered degree and the data of the converted longitude integer information occupying the digit number is 1, taking the base station longitude integer information as the longitude integer information of the terminal;
according to the first longitude/second information decompression rule, performing the second information conversion on the data of the converted longitude/second information occupying digit number to obtain the longitude/second information of the terminal;
and adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal.
Preferably, the determining the target decompression rule corresponding to the first compressed data includes:
and when the number of occupied bits of the longitude integer information is 2 bits and the number of occupied bits of the longitude deciseconds information is 11 bits, taking a second decompression rule as the target decompression rule, wherein the second decompression rule comprises a second longitude integer information decompression rule and a second longitude deciseconds information decompression rule.
Preferably, the decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal includes:
according to the second longitude decisecond information decompression rule, performing decisecond information conversion on data on the digit number occupied by the converted longitude decisecond information to obtain longitude decisecond information of the terminal;
when the longitude decimals information of the terminal is larger than the offset preset value, subtracting the first offset from the longitude integer information of the base station to obtain the longitude integer information of the terminal;
or when the longitude decimals information of the terminal is less than or equal to the preset offset value, adding the longitude integer information of the base station and the first offset to obtain the longitude integer information of the terminal;
adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal;
the first offset is obtained by subtracting a first operation result obtained by performing mod4 operation on base station longitude integer information in the base station longitude coordinate and a second operation result obtained by performing data format conversion on data on the bit occupied by the converted longitude integer information; and when the numerical value obtained by data format conversion of the data on the number of bits occupied by the converted longitude integer information is 0, taking 4 as the second operation result.
Preferably, the determining the target decompression rule corresponding to the first compressed data includes:
and when the number of occupied bits of the longitude integer information is 3 bits and the number of occupied bits of the longitude deciseconds information is 10 bits, taking a third decompression rule as the target decompression rule, wherein the third decompression rule comprises a third longitude integer information decompression rule and a third longitude deciseconds information decompression rule.
Preferably, the decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal includes:
according to the third longitude decisecond information decompression rule, performing decisecond information conversion on data on the digit number occupied by the converted longitude decisecond information to obtain longitude decisecond information of the terminal;
when the longitude decimals information of the terminal is larger than the offset preset value, subtracting the second offset from the longitude integer information of the base station to obtain the longitude integer information of the terminal;
or when the longitude decimals information of the terminal is less than or equal to the preset offset value, adding the longitude integer information of the base station and the second offset to obtain the longitude integer information of the terminal;
adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal;
the second offset is obtained by subtracting a third operation result obtained by performing mod8 operation on base station longitude integer information in the base station longitude coordinate and a fourth operation result obtained by performing data format conversion on data on the bit occupied by the converted longitude integer information; and when the numerical value obtained by data format conversion of the data on the number of bits occupied by the converted longitude integer information is 0, taking 8 as the fourth operation result.
A compression device of positioning information is applied to a terminal and comprises:
the terminal comprises an acquisition module, a processing module and a processing module, wherein the acquisition module is used for acquiring positioning information of the terminal, the positioning information comprises a longitude coordinate and a latitude coordinate, and the longitude coordinate comprises longitude integer information and longitude millisecond information;
the determining module is used for determining a target high latitude area to which the latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude area and a target coordinate conversion rule when the latitude coordinate is larger than a high latitude area critical coordinate, wherein the target data occupation digit comprises a longitude integer information occupation digit and a longitude decisecond information occupation digit;
the conversion module is used for converting the longitude integer information into data on the number of bits occupied by the longitude integer information and converting the longitude deciseconds information into data on the number of bits occupied by the longitude deciseconds information according to the target coordinate conversion rule;
and the sending module is used for taking the converted data on the number of bits occupied by the longitude integer information and the converted data on the number of bits occupied by the longitude decisecond information as first compressed data and sending the first compressed data to a base station.
A decompression device of positioning information is applied to a base station, and comprises:
the acquisition module is used for acquiring longitude coordinates of the base station;
the receiving module is used for receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by converted longitude integer information and data on the number of bits occupied by longitude decisecond information;
a determining module, configured to determine a target decompression rule corresponding to the first compressed data;
and the decompression module is used for decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal.
According to the technical scheme, compared with the prior art, the invention provides a method and a device for compressing and decompressing positioning information, which respectively determine a target high latitude area to which the latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude area and a target coordinate conversion rule when the obtained latitude coordinate of a terminal is greater than a high latitude area critical coordinate, further convert longitude integer information into data on the longitude integer information occupation digit according to the target coordinate conversion rule, convert longitude deciseconds information into data on the longitude deciseconds information occupation digit to obtain first compressed data, and send the first compressed data to a base station; therefore, when the latitude coordinate of the terminal belongs to the high latitude area coordinate, the integral information of the longitude coordinate is converted and compressed along with the longitude decisecond information according to the corresponding target coordinate conversion rule, and is sent to the base station for reduction, so that the problem of longitude coordinate distortion in a high latitude area is solved, and the reduction accuracy of the compressed positioning information is further ensured.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a flowchart of a method for compressing positioning information according to an embodiment of the present invention;
fig. 2 is a flowchart of another method for compressing positioning information according to an embodiment of the present invention;
fig. 3 is a flowchart of another method for compressing positioning information according to an embodiment of the present invention;
fig. 4 is a flowchart of a method for decompressing location information according to an embodiment of the present invention;
fig. 5 is a flowchart of another method for decompressing location information according to an embodiment of the present invention;
fig. 6 is a flowchart of another method for decompressing location information according to an embodiment of the present invention;
fig. 7 is a flowchart of another method for decompressing location information according to an embodiment of the present invention;
fig. 8 is a schematic structural diagram of a device for compressing positioning information according to an embodiment of the present invention;
fig. 9 is a schematic structural diagram of a device for decompressing location information according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The embodiment of the invention discloses a compression method of positioning information, which is applied to a terminal, please refer to the attached figure 1, and the method specifically comprises the following steps:
s101: acquiring positioning information of a terminal, wherein the positioning information comprises a longitude coordinate and a latitude coordinate, and the longitude coordinate comprises longitude integer information and longitude millisecond information;
specifically, the longitude coordinate of the terminal is composed of longitude integer information and longitude deciseconds information, such as E68.134 °, where 68 ° is the longitude integer information and 0.134 ° is the longitude deciseconds information.
The latitude coordinate of the terminal is composed of latitude integer information and latitude nanosecond information, such as N75.5 °, where 75 ° is latitude integer information and 0.5 ° is latitude nanosecond information.
It should be noted that both the longitude coordinate and the latitude coordinate of the terminal can be obtained by a positioning technology carried by the terminal, such as a positioning technology based on GPS.
S102: when the latitude coordinate is larger than a high latitude area critical coordinate, determining a target high latitude area to which the latitude coordinate belongs, a target data occupation digit and a target coordinate conversion rule, wherein the target data occupation digit comprises a longitude integer information occupation digit and a longitude decisecond information occupation digit;
specifically, the critical coordinate of the high latitude area may be a latitude value set according to the latitude, such as 60 ° north latitude; if the latitude coordinate of the terminal exceeds the critical coordinate of the high latitude area, the terminal is proved to be in the high latitude area; conversely, if the latitude coordinate of the terminal is less than or equal to the critical coordinate of the high latitude area, the terminal is proved to be in the middle and low latitude areas.
The target coordinate conversion rule is mainly used for carrying out data format conversion on the longitude coordinate of the terminal in the target high latitude area, so that the longitude coordinate is compressed, air interface resources occupied by data sent to the base station are reduced, and the sending rate is increased.
The occupied digit of the target data is mainly used for storing longitude integer information and longitude nanosecond information after the longitude coordinate of the terminal in the target high latitude area is converted. The converted longitude integer information is stored in the longitude integer information occupying digit number in the target data occupying digit number, and the converted longitude decisecond information is stored in the longitude decisecond information occupying digit number in the target data occupying digit number.
S103: converting the longitude integer information into data on the number of occupied digits of the longitude integer information according to the target coordinate conversion rule, and converting the longitude decisecond information into data on the number of occupied digits of the longitude decisecond information;
specifically, according to the determined target coordinate conversion rule, corresponding data conversion is respectively carried out on longitude integer information and longitude nanosecond information of the terminal to obtain first compressed data which is composed of the converted longitude integer information and the converted longitude nanosecond information together, namely the data on the occupied digit number of the converted longitude integer information and the data on the occupied digit number of the longitude nanosecond information, so that the problem of longitude coordinate distortion of a base station in a high latitude area after the compressed data sent by the terminal is reduced is solved, and the reduction accuracy rate of the compressed positioning information is effectively improved.
S104: and taking the converted data on the number of bits occupied by the longitude integer information and the converted data on the number of bits occupied by the longitude decisecond information as first compressed data, and sending the first compressed data to a base station.
The embodiment of the invention discloses a compression method of positioning information, which is applied to a terminal, and comprises the steps of respectively determining a target high latitude area to which a latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude area and a target coordinate conversion rule when the obtained latitude coordinate of the terminal is greater than a high latitude area critical coordinate, converting longitude integer information into data on the longitude integer information occupation digit according to the target coordinate conversion rule, converting longitude deciseconds information into data on the longitude deciseconds information occupation digit, obtaining first compression data, and sending the first compression data to a base station; therefore, when the latitude coordinate of the terminal belongs to the high latitude area coordinate, the integral information of the longitude coordinate is converted and compressed along with the longitude decisecond information according to the corresponding target coordinate conversion rule, and is sent to the base station for reduction, so that the problem of longitude coordinate distortion in a high latitude area is solved, and the reduction accuracy of the compressed positioning information is further ensured.
On the basis of the embodiment shown in fig. 1, another method for compressing positioning information is disclosed in the embodiment of the present invention, and referring to fig. 2, the method specifically includes the following steps:
s201: the method comprises the steps of obtaining positioning information of a terminal, wherein the positioning information comprises longitude coordinates and latitude coordinates, and the longitude coordinates comprise longitude integer information and longitude minute-second information.
S202: when the latitude coordinate is larger than the critical coordinate of the high latitude area, judging whether the latitude coordinate belongs to a first high latitude area, if so, executing S203, otherwise, executing S204;
specifically, the first high latitude region may be set to 60 ° to 75.5 ° north latitude.
S203: taking the first high latitude area as the target high latitude area, taking a first data occupation digit corresponding to the first high latitude area as the target data occupation digit, taking a first coordinate conversion rule corresponding to the first high latitude area as the target coordinate conversion rule, wherein the first data occupation digit comprises a 1-bit longitude integer information occupation digit and a 12-bit longitude decisecond information occupation digit, the first coordinate conversion rule comprises a first longitude integer information conversion rule and a first longitude decisecond information conversion rule, and executing S205;
specifically, the first coordinate conversion rule is to perform data format conversion on longitude coordinates of which latitude coordinates belong to a first high latitude region (60 ° north latitude to 75.5 ° north latitude), thereby implementing compression processing on the longitude coordinates belonging to the first high latitude region. The first longitude integer information conversion rule is used for converting longitude integer information in longitude coordinates, and may be set as: the longitude integer information is even degree, the data of 1-bit longitude integer information occupying the digit number is 0, the longitude integer information is odd degree, and the data of 1-bit longitude integer information occupying the digit number is 1; the first picosecond information conversion rule is used for converting the picosecond information in the longitude coordinate, and can be set as follows: using longitude minute second information conversion formula:
λ=L*cosα
the data of 12-bit longitude decimals information occupying digits are calculated, α is latitude, and L is the length of the latitude line at the 1-degree longitude interval at the equator.
The first data occupation digit is mainly used for storing longitude integer information and longitude decimalsecond information which belong to a first high latitude area (60 degrees to 75.5 degrees of north latitude) and are obtained by converting longitude coordinates. The 1-bit longitude integer information occupies the number of bits and is used for storing the longitude integer information converted by the first longitude integer information conversion rule; the 12-bit longitude decisecond information occupies the number of bits for storing the longitude decisecond information converted by the first longitude decisecond information conversion rule. For example, the first number of data occupancy bits is 13-bit data occupancy bits- "yxxx xxxx xxxx", where "y" is the number of 1-bit longitude integer information occupancy bits and "xxx xxxx xxxx" is the number of 12-bit longitude deciseconds information occupancy bits.
S204: judging whether the latitude coordinate belongs to a second high latitude area, wherein the second high latitude area is larger than the first high latitude area, if so, executing S206, otherwise, executing S207;
specifically, the second high latitude region may be set to 75.5 ° north latitude — 82.8 ° north latitude.
S205: and judging whether the longitude integer information is even degrees, if so, executing S208, and if not, executing S209.
S206: taking the second high latitude area as the target high latitude area, taking a second data occupation digit corresponding to the second high latitude area as the target data occupation digit, taking a second coordinate conversion rule corresponding to the second high latitude area as the target coordinate conversion rule, wherein the second data occupation digit comprises a 2-bit longitude integer information occupation digit and an 11-bit longitude decisecond information occupation digit, the second coordinate conversion rule comprises a second longitude integer information conversion rule and a second longitude decisecond information conversion rule, and executing S210;
specifically, the second coordinate conversion rule is to perform data format conversion on longitude coordinates of which latitude coordinates belong to a second high latitude region (75.5 ° north latitude — 82.8 ° north latitude), thereby implementing compression processing on the longitude coordinates belonging to the second high latitude region. The second longitude integer information conversion rule is used for converting longitude integer information in the longitude coordinate, and may be set as: carrying out mod4 operation on the longitude integer information to obtain an operation result, and converting the operation result into binary data serving as data of the number of bits occupied by the 2-bit longitude integer information; the second longitude decisecond information conversion rule is used for converting longitude decisecond information in longitude coordinates, and can be set as: using longitude minute second information conversion formula:
λ=L*cosα
the data of 11 longitude minutes second information occupying digits are calculated, α is latitude, and L is the length of the latitude line at the 1-degree longitude interval at the equator.
The second data occupation digit is mainly used for storing longitude integer information and longitude minute-second information which belong to a second high latitude area (75.5 degrees of north latitude-82.8 degrees of north latitude) and are obtained through conversion of longitude coordinates. The number of bits occupied by the 2-bit longitude integer information is used for storing the longitude integer information converted by the second longitude integer information conversion rule; and the 11-bit longitude decisecond information occupies the number of bits and is used for storing the longitude decisecond information converted by the second longitude decisecond information conversion rule. For example, the second number of data occupancy bits is 13-bit data occupancy bits- "yyxx xxxx xxxx" where "yy" is the number of 2-bit longitude integer information occupancy bits and "xx xxxx xxxx" is the number of 11-bit longitude deciseconds information occupancy bits.
S207: judging whether the latitude coordinate belongs to a third high latitude area, wherein the third high latitude area is larger than the second high latitude area, if so, executing S211, and if not, ending;
specifically, the third high latitude region may be set to 82.8 ° to 90 ° north latitude.
S208: converting the longitude integer information into 0 according to a first longitude integer information conversion rule in the target coordinate conversion rule, wherein the 0 is used as data of the 1-bit longitude integer information occupying the number of bits, and executing S212;
for example, the longitude integer information acquired in S201 is "68 °" and is an even number of degrees, and at this time, the longitude integer information "68 °" is converted into 0 according to the first longitude integer information conversion rule, and is used as data occupying the 1-bit longitude integer information.
S209: converting the longitude integer information into 1 according to a first longitude integer information conversion rule in the target coordinate conversion rule, wherein the 1-bit longitude integer information is used as data occupying the number of bits, and executing S212;
for example, the longitude integer information acquired in S201 is "71 °" and is odd-numbered degrees, and at this time, the longitude integer information "71 °" is converted into 1 according to the first longitude integer information conversion rule, and is used as data occupying the number of bits of 1-bit longitude integer information.
S210: performing mod4 operation on the longitude integer information according to a second longitude integer information conversion rule in the target coordinate conversion rule to obtain an operation result, converting the operation result into binary data serving as data of the number of bits occupied by the 2-bit longitude integer information, and executing S213;
for example, the longitude integer information acquired in S201 is "77 °", and mod4 operation is performed on the longitude integer information "77 °" according to the second longitude integer information conversion rule to obtain an operation result "1", and then the operation result "1" is converted into binary data "01" as data on the number of bits occupied by the 2-bit longitude integer information.
S211: taking the third high latitude area as the target high latitude area, taking a third data occupation digit corresponding to the third high latitude area as the target data occupation digit, taking a third coordinate conversion rule corresponding to the third high latitude area as the target coordinate conversion rule, wherein the third data occupation digit comprises a 3-bit longitude integer information occupation digit and a 10-bit longitude decisecond information occupation digit, and the third coordinate conversion rule comprises a third longitude integer information conversion rule and a third longitude decisecond information conversion rule, and executing S214;
specifically, the third coordinate conversion rule is to perform data format conversion on a longitude coordinate of which the latitude coordinate belongs to a third high latitude region (82.8 degrees to 90 degrees north latitude), so as to compress the longitude coordinate belonging to the third high latitude region. The third longitude integer information conversion rule is used for converting longitude integer information in the longitude coordinate, and may be set as: carrying out mod8 operation on the longitude integer information to obtain an operation result, and converting the operation result into binary data serving as data of the number of bits occupied by the 3-bit longitude integer information; the third longitude decisecond information conversion rule is used for converting longitude decisecond information in longitude coordinates, and can be set as: using longitude minute second information conversion formula:
λ=L*cosα
the data of the number of the occupied digits of the 10-bit longitude decimals information is calculated, α is the latitude, and L is the length of the latitude line at the 1-degree longitude interval at the equator.
The third data occupation digit is mainly used for storing longitude integer information and longitude decimals information which belong to a third high latitude area (north latitude 82.8 degrees-north latitude 90 degrees) and are obtained by converting longitude coordinates. The number of bits occupied by the 3-bit longitude integer information is used for storing the longitude integer information converted by the third longitude integer information conversion rule; and the 10-bit longitude decisecond information occupies the number of bits and is used for storing the longitude decisecond information converted by the third longitude decisecond information conversion rule. For example, the third number of occupied bits is 13-bit data occupied bits- "yyyx xxxx xxxx", where "yyy" is the number of occupied bits of 3-bit longitude integer information and "x xxxx xxxx" is the number of occupied bits of 10-bit longitude deciseconds information.
S212: according to a first longitude, minute and second information conversion rule in the target coordinate conversion rule, converting the longitude, minute and second information into data of which the 12-bit longitude, minute and second information occupies the number of bits by using a longitude, minute and second information conversion formula, and executing S215;
for example, the longitude minute-second information acquired in S201 is "0.934 °", and the longitude minute-second information conversion formula is used:
λ=L*cosα
the data of 12-bit longitude decimals information occupying digits are calculated, α is latitude, and L is the length of the latitude line at the 1-degree longitude interval at the equator.
S213: according to a second longitude deciseconds information conversion rule in the target coordinate conversion rule, converting the longitude deciseconds information into data of the 11-bit longitude deciseconds information occupying digits by using a longitude deciseconds information conversion formula, and executing S215.
S214: performing mod8 operation on the longitude integer information according to a third longitude integer information conversion rule in the target coordinate conversion rule to obtain an operation result, converting the operation result into binary data serving as data of the 3-bit longitude integer information occupying the number of bits, and executing S216;
for example, the longitude integer information acquired in S201 is "86 °", and mod8 operation is performed on the longitude integer information "86 °" according to the third longitude integer information conversion rule to obtain an operation result "6", and then the operation result "6" is converted into binary data "110" as data on the number of bits occupied by the 3-bit longitude integer information.
S215: and taking the converted data on the number of bits occupied by the longitude integer information and the converted data on the number of bits occupied by the longitude decisecond information as first compressed data, and sending the first compressed data to a base station.
S216: according to a third longitude decisecond information conversion rule in the target coordinate conversion rule, converting the longitude decisecond information into data of the 10-bit longitude decisecond information occupying digits by using a longitude decisecond information conversion formula, and executing S215.
The embodiment of the invention discloses a compression method of positioning information, which is applied to a terminal, and is characterized in that when an acquired latitude coordinate of the terminal is larger than a critical coordinate of a high latitude area, a target high latitude area to which the latitude coordinate belongs is determined from a first high latitude area, a second high latitude area and a third high latitude area, so that a target data occupation digit and a target coordinate conversion rule corresponding to the target high latitude area are further determined, the longitude integer information is converted into data on the longitude integer information occupation digit according to a longitude integer information conversion rule in the target coordinate conversion rule, and the longitude decisecond information is converted into data on the longitude decisecond information occupation digit according to a longitude decisecond information conversion rule in the target coordinate conversion rule, so that first compression data are acquired and sent to a base station; therefore, according to the latitude height, the high latitude area is divided into the first high latitude area, the second high latitude area and the third high latitude area in sequence, so that the longitude coordinates are divided in detail, and when the first compressed data is obtained according to the corresponding target data occupation digit and the target coordinate conversion rule, the compression accuracy of the positioning information can be further improved on the basis of solving the problem of longitude coordinate distortion of the high latitude area.
On the basis of the embodiment shown in fig. 1, another method for compressing positioning information is disclosed in the embodiment of the present invention, and referring to fig. 3, the method specifically includes the following steps:
s301: the method comprises the steps of obtaining positioning information of a terminal, wherein the positioning information comprises longitude coordinates and latitude coordinates, and the longitude coordinates comprise longitude integer information and longitude minute-second information.
S302: when the latitude coordinate is smaller than or equal to the high latitude area critical coordinate, utilizing a longitude, minute and second information conversion formula to convert the longitude, minute and second information to obtain second compressed data;
specifically, when the latitude coordinate is less than or equal to the critical coordinate of the high latitude area, the terminal is proved to be in the low latitude area or the medium latitude area, correspondingly, the position of the base station does not belong to the high latitude area, that is, the coverage radius of the base station does not span two longitude lines, at this time, longitude integer information of the longitude coordinate of the terminal is discarded, and a longitude minute second information conversion formula is utilized:
λ=L*cosα
only the longitude minute-second information is converted to obtain second compressed data, where α is the latitude and L is the length of the latitude line at 1 degree longitude interval at the equator.
It should be noted that the second compressed data obtained after the conversion may be 13-bit data composed of binary format, such as "xxxx xxxx xxxx".
S303: transmitting the second compressed data to the base station.
The compression method of the positioning information disclosed by the embodiment of the invention is applied to the terminal, and when the obtained latitude coordinate of the terminal is less than or equal to the critical coordinate of the high latitude area, only the longitude decisecond information is converted by using the longitude decisecond information conversion formula to obtain the second compression data, and the second compression data is sent to the base station, so that the compression efficiency of the positioning information can be improved on the basis of ensuring that the longitude coordinate is not distorted.
The embodiment of the invention discloses a method for decompressing positioning information, which is applied to a base station and refers to the attached figure 4, wherein the method specifically comprises the following steps:
s401: acquiring longitude coordinates of a base station;
specifically, the longitude coordinate of the base station is composed of integral longitude information of the base station and deciseconds longitude information of the base station, such as E72.5 °, where 72 ° is integral longitude information of the base station, and 0.5 ° is deciseconds longitude information of the base station.
It should be noted that the longitude coordinate of the terminal can be obtained by the positioning technology of the base station itself.
S402: receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by converted longitude integer information and data on the number of bits occupied by longitude minute-second information;
specifically, the data on the number of bits occupied by the converted longitude integer information is the converted longitude integer information of the terminal; and the converted longitude decimals information occupies data on the number of digits and is converted longitude decimals information of the terminal.
S403: determining a target decompression rule corresponding to the first compressed data;
specifically, the target decompression rule is mainly used for decompressing the determined first compressed data to restore the first compressed data and obtain the actual location information of the terminal.
S404: and decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal.
Specifically, the first compressed data is composed of data on the number of bits occupied by the converted longitude integer information and data on the number of bits occupied by the longitude nanosecond information, so that when a target decompression rule is adopted to decompress the first compressed data, corresponding decompression operations are respectively carried out on the data on the number of bits occupied by the converted longitude integer information and the data on the number of bits occupied by the longitude nanosecond information to restore the longitude coordinate of the terminal, and therefore the longitude integer information of the longitude coordinate of the terminal is added to the first compressed data, the restoring accuracy of the longitude coordinate of the terminal is facilitated, and the problem of high latitude area longitude coordinate distortion caused by directly adding the longitude integer information of the base station and the microsecond information of the decompressed terminal is solved.
The embodiment of the invention discloses a method for decompressing positioning information, which is applied to a base station, and comprises the steps of obtaining a longitude coordinate of the base station, receiving first compressed data from a terminal simultaneously so as to determine a target decompression rule corresponding to the first compressed data, and decompressing data on the number of bits occupied by converted longitude integer information in the first compressed data and data on the number of bits occupied by longitude minute-second information respectively by using the target decompression rule and the longitude coordinate of the base station so as to restore the longitude coordinate of the terminal; therefore, the decompression operation of the longitude integer information of the longitude coordinate of the terminal is added, the reduction accuracy of the decompression operation is facilitated, and the problem of high latitude area longitude coordinate distortion caused by directly adding the longitude integer information of the base station and the minute-second information of the decompressed terminal is solved.
On the basis of the embodiment shown in fig. 4, another method for decompressing positioning information is disclosed in the embodiment of the present invention, which is applied to a base station, and please refer to fig. 5, where the method specifically includes the following steps:
s501: and acquiring longitude coordinates of the base station.
S502: and receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by the converted longitude integer information and data on the number of bits occupied by the longitude decisecond information.
S503: when the number of bits occupied by the longitude integer information is 1 bit and the number of bits occupied by the longitude deciseconds information is 12 bits, taking a first decompression rule as the target decompression rule, wherein the first decompression rule comprises a first longitude integer information decompression rule and a first longitude deciseconds information decompression rule;
specifically, the first scaled integer information decompression rule may be set as: the longitude integer information of the base station in the longitude coordinate of the base station is even degree, and when the data of the converted longitude integer information occupying the digits is 0, the longitude integer information of the base station is used as the longitude integer information of the terminal; when base station longitude integer information in a base station longitude coordinate is even degree, and data on the occupied digit of the converted longitude integer information is 1, subtracting 1 from the base station longitude integer information to obtain a numerical value serving as longitude integer information of the terminal;
the longitude information of the base station in the longitude coordinate of the base station is odd number degree, when the data of the converted longitude integer information occupying the digits is 0, the value obtained by subtracting 1 from the longitude integer information of the base station is used as the longitude integer information of the terminal; and when the base station longitude integer information in the base station longitude coordinate is odd number degrees and the data of the converted longitude integer information occupying the digit number is 1, taking the base station longitude integer information as the longitude integer information of the terminal.
The first minute-second information decompression rule may be set to: and performing the second-minute information conversion on the data of the converted longitude second-minute information occupying digits to obtain the longitude second-minute information of the terminal.
S504: when base station longitude integer information in the base station longitude coordinate is even degree and data on occupied digits of the converted longitude integer information is 0, taking the base station longitude integer information as longitude integer information of a terminal according to the first longitude integer information decompression rule;
when the base station longitude integer information in the base station longitude coordinate is an even degree and the data of the converted longitude integer information occupying the digit number is 1, according to the first longitude integer information decompression rule, taking the value obtained by subtracting 1 from the base station longitude integer information as the longitude integer information of the terminal;
or, when the base station longitude integer information in the base station longitude coordinate is odd number degree and the data of the converted longitude integer information occupying the digits is 0, subtracting 1 from the base station longitude integer information to obtain a numerical value as the longitude integer information of the terminal;
alternatively, when the base station longitude integer information in the base station longitude coordinate is odd-numbered and the data in the number of bits occupied by the converted longitude integer information is 1, the base station longitude integer information is used as the longitude integer information of the terminal.
S505: according to the first longitude/second information decompression rule, performing the second information conversion on the data of the converted longitude/second information occupying digit number to obtain the longitude/second information of the terminal;
specifically, the information conversion of the minutes and seconds is mainly to restore the data of the converted longitude minutes and seconds information occupying digits into an expression form of the longitude minutes and seconds information.
S506: and adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal.
The embodiment of the invention discloses a method for decompressing positioning information, which is applied to a base station, and is characterized in that when the number of bits occupied by longitude integer information is 1 bit and the number of bits occupied by longitude decisecond information is 12 bits, a first decompression rule is used as a target decompression rule, the first longitude integer information decompression rule in the first decompression rule is further used for determining the longitude integer information of a terminal, and the first longitude decisecond information decompression rule in the first decompression rule is used for determining the longitude decisecond information of the terminal so as to add the longitude integer information and the longitude decisecond information and restore the longitude coordinate of the terminal; therefore, based on the longitude integer information occupied bit number and the longitude deciseconds information occupied bit number, the corresponding decompression rule is determined to serve as the target decompression rule, so that the decompression operation of the data on the longitude integer information occupied bit number and the data on the longitude deciseconds information occupied bit number after conversion is respectively realized, the compression rule adopted during terminal compression can be accurately obtained, and the reduction accuracy of the decompression operation is improved.
On the basis of the embodiment shown in fig. 4, another method for decompressing positioning information is disclosed in the embodiment of the present invention, which is applied to a base station, and please refer to fig. 6, where the method specifically includes the following steps:
s601: and acquiring longitude coordinates of the base station.
S602: and receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by the converted longitude integer information and data on the number of bits occupied by the longitude decisecond information.
S603: when the number of bits occupied by the longitude integer information is 2 bits and the number of bits occupied by the longitude deciseconds information is 11 bits, taking a second decompression rule as the target decompression rule, wherein the second decompression rule comprises a second longitude integer information decompression rule and a second longitude deciseconds information decompression rule;
specifically, the second longitude minute-second information decompression rule may be set as: converting the converted data of the longitude decisecond information occupying digits to obtain the longitude decisecond information of the terminal;
the second longitude integer information decompression rule may be set to: when the longitude decimals information of the terminal is larger than the offset preset value, subtracting the first offset from the longitude integer information of the base station to obtain the longitude integer information of the terminal; adding longitude integer information of the base station and the first offset when the longitude decimals information of the terminal is smaller than or equal to the offset preset value to obtain longitude integer information of the terminal;
the first offset is obtained by subtracting a first operation result obtained by performing mod4 operation on base station longitude integer information in a base station longitude coordinate and a second operation result obtained by performing data format conversion on data on the bit occupied by the converted longitude integer information; and when the numerical value obtained by data format conversion of the data on the number of bits occupied by the converted longitude integer information is 0, taking the numerical value 4 as a second operation result.
S604: and according to the second longitude deciseconds information decompression rule, performing data format conversion on the data on the digit occupied by the converted longitude deciseconds information to obtain the longitude deciseconds information of the terminal.
S605: when the longitude decimals information of the terminal is larger than a preset offset value, subtracting a first offset from longitude integer information of a base station to obtain longitude integer information of the terminal, wherein the first offset is obtained by subtracting a first operation result obtained by performing mod4 operation on the longitude integer information of the base station in a longitude coordinate of the base station and a second operation result obtained by performing data format conversion on data on the bit occupied by the converted longitude integer information; when the numerical value obtained by data format conversion of the data on the digit occupied by the converted longitude integer information is 0, taking 4 as the second operation result;
it should be noted that, when the longitude decimals information of the terminal is less than or equal to the preset offset value, the longitude integer information of the base station is added to the first offset to obtain the longitude integer information of the terminal.
The offset preset value may be a preset one-minute-second message, such as 0.5 °, and is mainly used for identifying whether the terminal is located on the left side or the right side of the base station. For example, when the longitude minute-second information of the terminal is less than or equal to the offset preset value, the terminal is located on the right side of the base station.
Secondly, when the value of the converted data format of the data on the occupied digit of the converted longitude integer information is 0, the longitude integer information is proved to be divisible by 4, and at the moment, the value of 4 is used as a second operation result.
S606: and adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal.
The embodiment of the invention discloses a method for decompressing positioning information, which is applied to a base station, and is characterized in that when the number of occupied digits of longitude integer information is 2 bits and the number of occupied digits of longitude decisecond information is 11 bits, a second decompression rule is used as a target decompression rule, the second longitude integer information decompression rule in the second decompression rule is further used for determining the longitude integer information of a terminal, and the second longitude decisecond information decompression rule in the second decompression rule is used for determining the longitude decisecond information of the terminal so as to add the longitude integer information and the longitude decisecond information and restore the longitude coordinate of the terminal; therefore, based on the longitude integer information occupied bit number and the longitude deciseconds information occupied bit number, the corresponding decompression rule is determined to serve as the target decompression rule, so that the decompression operation of the data on the longitude integer information occupied bit number and the data on the longitude deciseconds information occupied bit number after conversion is respectively realized, the compression rule adopted during terminal compression can be accurately obtained, and the reduction accuracy of the decompression operation is improved.
On the basis of the embodiment shown in fig. 4, another method for decompressing positioning information is disclosed in the embodiment of the present invention, which is applied to a base station, and please refer to fig. 7, where the method specifically includes the following steps:
s701: and acquiring longitude coordinates of the base station.
S702: and receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by the converted longitude integer information and data on the number of bits occupied by the longitude decisecond information.
S703: when the number of bits occupied by the longitude integer information is 3 bits and the number of bits occupied by the longitude deciseconds information is 10 bits, taking a third decompression rule as the target decompression rule, wherein the third decompression rule comprises a third longitude integer information decompression rule and a third longitude deciseconds information decompression rule;
specifically, the third longitude minute-second information decompression rule may be set as: converting the converted data of the longitude decisecond information occupying digits to obtain the longitude decisecond information of the terminal;
the third longitude integer information decompression rule may be set to: when the longitude decimals information of the terminal is larger than the offset preset value, subtracting the second offset from the longitude integer information of the base station to obtain the longitude integer information of the terminal; when the longitude decimals information of the terminal is smaller than or equal to the offset preset value, adding the longitude integer information of the base station and the second offset to obtain the longitude integer information of the terminal;
the second offset is obtained by subtracting a third operation result obtained by performing mod8 operation on base station longitude integer information in a base station longitude coordinate and a fourth operation result obtained by performing data format conversion on data on the bit occupied by the converted longitude integer information; and when the numerical value obtained by data format conversion of the data on the number of bits occupied by the converted longitude integer information is 0, taking the numerical value 8 as a fourth operation result.
S704: and according to the third longitude decisecond information decompression rule, performing the decisecond information conversion on the data of the converted longitude decisecond information occupying digit number to obtain the longitude decisecond information of the terminal.
S705: when the longitude decimals information of the terminal is larger than the offset preset value, subtracting the second offset from the longitude integer information of the base station to obtain the longitude integer information of the terminal;
it should be noted that, when the longitude decimals information of the terminal is less than or equal to the offset preset value, the longitude integer information of the base station is added to the second offset to obtain the longitude integer information of the terminal;
the offset preset value may be a preset one-minute-second message, such as 0.5 °, and is mainly used for identifying whether the terminal is located on the left side or the right side of the base station. For example, when the longitude minute-second information of the terminal is greater than the offset preset value, the terminal is located on the left side of the base station.
Secondly, when the value of the converted data format of the data on the occupied digit of the converted longitude integer information is 0, it is proved that the longitude integer information can be divided by 8, and at this time, the value 8 is used as a fourth operation result.
S706: and adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal.
The method for decompressing the positioning information disclosed by the embodiment of the invention is applied to a base station, and is characterized in that when the number of occupied digits of longitude integer information is 3 and the number of occupied digits of longitude decisecond information is 10, a third decompression rule is used as a target decompression rule, the third longitude integer information decompression rule in the third decompression rule is further used for determining the longitude integer information of a terminal, and the third longitude decisecond information decompression rule in the third decompression rule is used for determining the longitude decisecond information of the terminal so as to add the longitude integer information and the longitude decisecond information and restore the longitude coordinate of the terminal; therefore, based on the longitude integer information occupied bit number and the longitude deciseconds information occupied bit number, the corresponding decompression rule is determined to serve as the target decompression rule, so that the decompression operation of the data on the longitude integer information occupied bit number and the data on the longitude deciseconds information occupied bit number after conversion is respectively realized, the compression rule adopted during terminal compression can be accurately obtained, and the reduction accuracy of the decompression operation is improved.
The embodiment of the invention discloses a compression device of positioning information, which is applied to a terminal, please refer to fig. 8, and comprises:
an obtaining module 801, configured to obtain location information of a terminal, where the location information includes a longitude coordinate and a latitude coordinate, and the longitude coordinate includes longitude integer information and longitude millisecond information;
a determining module 802, configured to determine, when the latitude coordinate is greater than a high latitude region critical coordinate, a target high latitude region to which the latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude region, and a target coordinate conversion rule, where the target data occupation digit includes a longitude integer information occupation digit and a longitude decisecond information occupation digit;
a conversion module 803, configured to convert the longitude integer information into data on the number of bits occupied by the longitude integer information according to the target coordinate conversion rule, and convert the longitude deciseconds information into data on the number of bits occupied by the longitude deciseconds information;
a sending module 804, configured to send the first compressed data to a base station, where the converted data in the number of bits occupied by the longitude integer information and the converted data in the number of bits occupied by the longitude decisecond information are used as the first compressed data.
When the latitude coordinate of the terminal acquired by the acquisition module 801 is larger than the critical coordinate of a high latitude area, the determination module 802 respectively determines a target high latitude area to which the latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude area and a target coordinate conversion rule, the conversion module 803 further converts longitude integer information into data on the longitude integer information occupation digit according to the target coordinate conversion rule, converts longitude decisecond information into data on the longitude decisecond information occupation digit according to the target coordinate conversion rule, so as to acquire first compressed data, and the first compressed data is transmitted to a base station by the transmission module 804; therefore, when the latitude coordinate of the terminal belongs to the high latitude area coordinate, the integral information of the longitude coordinate is converted and compressed along with the longitude decisecond information according to the corresponding target coordinate conversion rule, and is sent to the base station for reduction, so that the problem of longitude coordinate distortion in a high latitude area is solved, and the reduction accuracy of the compressed positioning information is further ensured.
Please refer to a method flowchart corresponding to fig. 1 for the working process of each module provided in the embodiment of the present invention, and detailed description of the working process is omitted.
The embodiment of the present invention discloses a decompression apparatus for positioning information, which is applied to a base station, please refer to fig. 9, and includes:
an obtaining module 901, configured to obtain a longitude coordinate of a base station;
a receiving module 902, configured to receive first compressed data sent by a terminal, where the first compressed data includes data in bits occupied by converted longitude integer information and data in bits occupied by longitude minute-second information;
a determining module 903, configured to determine a target decompression rule corresponding to the first compressed data;
a decompression module 904, configured to perform a decompression operation on the first compressed data by using the target decompression rule and the longitude coordinate of the base station, so as to obtain a longitude coordinate of the terminal.
The decompression device for positioning information disclosed by the embodiment of the invention is applied to a base station, acquires a longitude coordinate of the base station through an acquisition module 901, and simultaneously receives first compressed data from a terminal through a receiving module 902, so that a target decompression rule corresponding to the first compressed data is determined by a determination module 903, and then a decompression module 904 respectively decompresses data on the number of bits occupied by converted longitude integer information in the first compressed data and data on the number of bits occupied by longitude minute second information by using the target decompression rule and the longitude coordinate of the base station, so as to restore the longitude coordinate of the terminal; therefore, the decompression operation of the longitude integer information of the longitude coordinate of the terminal is added, the reduction accuracy of the decompression operation is facilitated, and the problem of high latitude area longitude coordinate distortion caused by directly adding the longitude integer information of the base station and the minute-second information of the decompressed terminal is solved.
Please refer to a method flowchart corresponding to fig. 4 for the working process of each module provided in the embodiment of the present invention, and detailed description of the working process is omitted.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (17)

1. A compression method of positioning information is applied to a terminal, and comprises the following steps:
acquiring positioning information of a terminal, wherein the positioning information comprises a longitude coordinate and a latitude coordinate, and the longitude coordinate comprises longitude integer information and longitude millisecond information;
when the latitude coordinate is larger than a high latitude area critical coordinate, determining a target high latitude area to which the latitude coordinate belongs, a target data occupation digit and a target coordinate conversion rule, wherein the target data occupation digit comprises a longitude integer information occupation digit and a longitude decisecond information occupation digit;
converting the longitude integer information into data on the number of occupied digits of the longitude integer information according to the target coordinate conversion rule, and converting the longitude decisecond information into data on the number of occupied digits of the longitude decisecond information;
and taking the converted data on the number of bits occupied by the longitude integer information and the converted data on the number of bits occupied by the longitude decisecond information as first compressed data, and sending the first compressed data to a base station.
2. The compression method according to claim 1, wherein when the latitude coordinate is greater than the high latitude region critical coordinate, determining a target high latitude region to which the latitude coordinate belongs, a target number of occupied bits of data corresponding to the target high latitude region, and a target coordinate transformation rule includes:
when the latitude coordinate is larger than the critical coordinate of the high latitude area, judging whether the latitude coordinate belongs to a first high latitude area;
if the latitude coordinate belongs to the first high latitude area, the first high latitude area is used as the target high latitude area, a first data occupation digit corresponding to the first high latitude area is used as the target data occupation digit, a first coordinate conversion rule corresponding to the first high latitude area is used as the target coordinate conversion rule, the first data occupation digit comprises a 1-bit longitude integer information occupation digit and a 12-bit longitude decisecond information occupation digit, and the first coordinate conversion rule comprises a first longitude integer information conversion rule and a first longitude decisecond information conversion rule.
3. The compression method according to claim 2, wherein said converting the longitude integer information into data on the number of bits occupied by the longitude integer information and converting the longitude deciseconds information into data on the number of bits occupied by the longitude deciseconds information according to the target coordinate conversion rule comprises:
judging whether the longitude integer information is even number;
if the longitude integer information is even degree, converting the longitude integer information into 0 according to a first longitude integer information conversion rule in the target coordinate conversion rule, and using the 0 as data of the 1-bit longitude integer information occupying bit number;
if the longitude integer information is odd-numbered, converting the longitude integer information into 1 according to a first longitude integer information conversion rule in the target coordinate conversion rule, and using the 1-bit longitude integer information as data occupying the number of bits;
and converting the longitude deciseconds information into data of the 12-bit longitude deciseconds information occupying digits by using a longitude deciseconds information conversion formula according to a first longitude deciseconds information conversion rule in the target coordinate conversion rule.
4. The compression method according to claim 2, further comprising, after determining that the latitude coordinate does not belong to the first high latitude region:
judging whether the latitude coordinate belongs to a second high latitude area, wherein the second high latitude area is larger than the first high latitude area;
if the latitude coordinate belongs to the second high latitude area, the second high latitude area is used as the target high latitude area, a second data occupation bit corresponding to the second high latitude area is used as the target data occupation bit, a second coordinate conversion rule corresponding to the second high latitude area is used as the target coordinate conversion rule, the second data occupation bit comprises a 2-bit longitude integer information occupation bit and an 11-bit longitude decisecond information occupation bit, and the second coordinate conversion rule comprises a second longitude integer information conversion rule and a second longitude decisecond information conversion rule.
5. The compression method according to claim 4, wherein said converting the longitude integer information into data on the number of bits occupied by the longitude integer information and converting the longitude deciseconds information into data on the number of bits occupied by the longitude deciseconds information according to the target coordinate conversion rule comprises:
performing mod4 operation on the longitude integer information according to a second longitude integer information conversion rule in the target coordinate conversion rule to obtain an operation result, and converting the operation result into binary data serving as data of the number of bits occupied by the 2-bit longitude integer information;
and converting the longitude deciseconds information into data of the 11-bit longitude deciseconds information occupying digits by using a longitude deciseconds information conversion formula according to a second longitude deciseconds information conversion rule in the target coordinate conversion rule.
6. The compression method according to claim 4, further comprising, after determining that the latitude coordinate does not belong to the second high latitude region:
judging whether the latitude coordinate belongs to a third high latitude area, wherein the third high latitude area is larger than the second high latitude area;
if the latitude coordinate belongs to the third high latitude area, taking the third high latitude area as the target high latitude area, taking a third data occupation digit corresponding to the third high latitude area as the target data occupation digit, taking a third coordinate conversion rule corresponding to the third high latitude area as the target coordinate conversion rule, wherein the third data occupation digit comprises a 3-bit longitude integer information occupation digit and a 10-bit longitude decisecond information occupation digit, and the third coordinate conversion rule comprises a third longitude integer information conversion rule and a third longitude decisecond information conversion rule.
7. The compression method as claimed in claim 6, wherein said converting the longitude integer information into data on the number of bits occupied by the longitude integer information and converting the longitude deciseconds information into data on the number of bits occupied by the longitude deciseconds information according to the target coordinate conversion rule comprises:
performing mod8 operation on the longitude integer information according to a third longitude integer information conversion rule in the target coordinate conversion rule to obtain an operation result, and converting the operation result into binary data serving as data of the 3-bit longitude integer information occupying the bit number;
and converting the longitude deciseconds information into data of the 10-bit longitude deciseconds information occupying digits by using a longitude deciseconds information conversion formula according to a third longitude deciseconds information conversion rule in the target coordinate conversion rule.
8. The compression method of claim 1, further comprising:
when the latitude coordinate is smaller than or equal to the high latitude area critical coordinate, utilizing a longitude, minute and second information conversion formula to convert the longitude, minute and second information to obtain second compressed data;
transmitting the second compressed data to the base station.
9. A method for decompressing positioning information, applied to a base station, includes:
acquiring longitude coordinates of a base station;
receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by converted longitude integer information and data on the number of bits occupied by longitude minute-second information;
determining a target decompression rule corresponding to the first compressed data;
and decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal.
10. The decompression method according to claim 9, wherein the determining the target decompression rule corresponding to the first compressed data comprises:
and when the longitude integer information occupation bit number is 1 bit and the longitude deciseconds information occupation bit number is 12 bits, taking a first decompression rule as the target decompression rule, wherein the first decompression rule comprises a first longitude integer information decompression rule and a first longitude seconds information decompression rule.
11. The decompression method according to claim 10, wherein performing a decompression operation on the first compressed data using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal comprises:
when base station longitude integer information in the base station longitude coordinate is even degree and data on occupied digits of the converted longitude integer information is 0, taking the base station longitude integer information as longitude integer information of a terminal according to the first longitude integer information decompression rule;
or, when the base station longitude integer information in the base station longitude coordinate is an even degree and the data of the converted longitude integer information on the occupied digit is 1, according to the first longitude integer information decompression rule, taking the value obtained by subtracting 1 from the base station longitude integer information as the longitude integer information of the terminal;
or, when the base station longitude integer information in the base station longitude coordinate is odd-numbered degree and the data on the bit occupied by the converted longitude integer information is 0, taking the value obtained by subtracting 1 from the base station longitude integer information as the longitude integer information of the terminal;
or, when the base station longitude integer information in the base station longitude coordinate is odd-numbered degree and the data of the converted longitude integer information occupying the digit number is 1, taking the base station longitude integer information as the longitude integer information of the terminal;
according to the first longitude/second information decompression rule, performing the second information conversion on the data of the converted longitude/second information occupying digit number to obtain the longitude/second information of the terminal;
and adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal.
12. The decompression method according to claim 9, wherein the determining the target decompression rule corresponding to the first compressed data comprises:
and when the number of occupied bits of the longitude integer information is 2 bits and the number of occupied bits of the longitude deciseconds information is 11 bits, taking a second decompression rule as the target decompression rule, wherein the second decompression rule comprises a second longitude integer information decompression rule and a second longitude deciseconds information decompression rule.
13. The decompression method according to claim 12, wherein performing a decompression operation on the first compressed data using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal comprises:
according to the second longitude decisecond information decompression rule, performing decisecond information conversion on data on the digit number occupied by the converted longitude decisecond information to obtain longitude decisecond information of the terminal;
when the longitude decimals information of the terminal is larger than the offset preset value, subtracting the first offset from the longitude integer information of the base station to obtain the longitude integer information of the terminal;
or when the longitude decimals information of the terminal is less than or equal to the preset offset value, adding the longitude integer information of the base station and the first offset to obtain the longitude integer information of the terminal;
adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal;
the first offset is obtained by subtracting a first operation result obtained by performing mod4 operation on base station longitude integer information in the base station longitude coordinate and a second operation result obtained by performing data format conversion on data on the bit occupied by the converted longitude integer information; and when the numerical value obtained by data format conversion of the data on the number of bits occupied by the converted longitude integer information is 0, taking 4 as the second operation result.
14. The decompression method according to claim 9, wherein the determining the target decompression rule corresponding to the first compressed data comprises:
and when the number of occupied bits of the longitude integer information is 3 bits and the number of occupied bits of the longitude deciseconds information is 10 bits, taking a third decompression rule as the target decompression rule, wherein the third decompression rule comprises a third longitude integer information decompression rule and a third longitude deciseconds information decompression rule.
15. The decompression method according to claim 14, wherein performing a decompression operation on the first compressed data using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal comprises:
according to the third longitude decisecond information decompression rule, performing decisecond information conversion on data on the digit number occupied by the converted longitude decisecond information to obtain longitude decisecond information of the terminal;
when the longitude decimals information of the terminal is larger than the offset preset value, subtracting the second offset from the longitude integer information of the base station to obtain the longitude integer information of the terminal;
or when the longitude decimals information of the terminal is less than or equal to the preset offset value, adding the longitude integer information of the base station and the second offset to obtain the longitude integer information of the terminal;
adding the longitude integer information and the longitude decisecond information to obtain a longitude coordinate of the terminal;
the second offset is obtained by subtracting a third operation result obtained by performing mod8 operation on base station longitude integer information in the base station longitude coordinate and a fourth operation result obtained by performing data format conversion on data on the bit occupied by the converted longitude integer information; and when the numerical value obtained by data format conversion of the data on the number of bits occupied by the converted longitude integer information is 0, taking 8 as the fourth operation result.
16. A compression device of positioning information is applied to a terminal, and comprises:
the terminal comprises an acquisition module, a processing module and a processing module, wherein the acquisition module is used for acquiring positioning information of the terminal, the positioning information comprises a longitude coordinate and a latitude coordinate, and the longitude coordinate comprises longitude integer information and longitude millisecond information;
the determining module is used for determining a target high latitude area to which the latitude coordinate belongs, a target data occupation digit corresponding to the target high latitude area and a target coordinate conversion rule when the latitude coordinate is larger than a high latitude area critical coordinate, wherein the target data occupation digit comprises a longitude integer information occupation digit and a longitude decisecond information occupation digit;
the conversion module is used for converting the longitude integer information into data on the number of bits occupied by the longitude integer information and converting the longitude deciseconds information into data on the number of bits occupied by the longitude deciseconds information according to the target coordinate conversion rule;
and the sending module is used for taking the converted data on the number of bits occupied by the longitude integer information and the converted data on the number of bits occupied by the longitude decisecond information as first compressed data and sending the first compressed data to a base station.
17. A decompression device of positioning information, applied to a base station, comprises:
the acquisition module is used for acquiring longitude coordinates of the base station;
the receiving module is used for receiving first compressed data sent by a terminal, wherein the first compressed data comprises data on the number of bits occupied by converted longitude integer information and data on the number of bits occupied by longitude decisecond information;
a determining module, configured to determine a target decompression rule corresponding to the first compressed data;
and the decompression module is used for decompressing the first compressed data by using the target decompression rule and the longitude coordinate of the base station to obtain the longitude coordinate of the terminal.
CN201810821550.8A 2018-07-24 2018-07-24 Method and device for compressing and decompressing positioning information Active CN110769361B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810821550.8A CN110769361B (en) 2018-07-24 2018-07-24 Method and device for compressing and decompressing positioning information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810821550.8A CN110769361B (en) 2018-07-24 2018-07-24 Method and device for compressing and decompressing positioning information

Publications (2)

Publication Number Publication Date
CN110769361A true CN110769361A (en) 2020-02-07
CN110769361B CN110769361B (en) 2021-05-14

Family

ID=69326789

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810821550.8A Active CN110769361B (en) 2018-07-24 2018-07-24 Method and device for compressing and decompressing positioning information

Country Status (1)

Country Link
CN (1) CN110769361B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1948990A (en) * 2006-11-16 2007-04-18 北京尧天网迅科技有限公司 Method of compressing GPS positioning information
US20130036238A1 (en) * 2011-08-01 2013-02-07 Motorola Solutions, Inc. Method and system for compressing location data of a radio for over-the-air transmission
CN104581635A (en) * 2015-01-13 2015-04-29 哈尔滨海能达科技有限公司 Method and system for transmitting locating information and device
CN106886038A (en) * 2015-12-15 2017-06-23 骑记(厦门)科技有限公司 The processing method and processing device of movement locus
CN107742313A (en) * 2017-09-26 2018-02-27 华勤通讯技术有限公司 A kind of data compression method and equipment applied to vector space

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1948990A (en) * 2006-11-16 2007-04-18 北京尧天网迅科技有限公司 Method of compressing GPS positioning information
US20130036238A1 (en) * 2011-08-01 2013-02-07 Motorola Solutions, Inc. Method and system for compressing location data of a radio for over-the-air transmission
CN103930792A (en) * 2011-08-01 2014-07-16 摩托罗拉解决方案公司 Method and system for compressing location data of a radio for over-the-air transmission
CN104581635A (en) * 2015-01-13 2015-04-29 哈尔滨海能达科技有限公司 Method and system for transmitting locating information and device
CN106886038A (en) * 2015-12-15 2017-06-23 骑记(厦门)科技有限公司 The processing method and processing device of movement locus
CN107742313A (en) * 2017-09-26 2018-02-27 华勤通讯技术有限公司 A kind of data compression method and equipment applied to vector space

Also Published As

Publication number Publication date
CN110769361B (en) 2021-05-14

Similar Documents

Publication Publication Date Title
US8468269B2 (en) Method and system for compressing location data of a radio for over-the-air transmission
WO2016112548A1 (en) Location information acquiring method and device
WO2016112836A1 (en) Positioning information transmission method, device and system
CN102474841B (en) Use the apparatus and method of the position of the sequencal estimation terminal sent from base station
EP3930353A1 (en) Apparatus and method for positioning user equipment
CN105450289A (en) Multichannel Beidou satellite communication method
CN107295637A (en) A kind of paging method, equipment and system
US9831894B2 (en) Data compression apparatus
CN110769361B (en) Method and device for compressing and decompressing positioning information
CN110312324B (en) Data transmission method and related equipment
CN100546400C (en) A kind of method, equipment and system that realizes that contextual model is shared
CN102843217B (en) D2D (Device-to-Device) communication system based on network coding and relaying and achieving method of D2D communication system
WO2020019152A1 (en) Method and apparatus for compressing and decompressing positioning information
CN111543098B (en) Method, device and system for transmitting system information
WO2016153707A1 (en) Conveying data between devices in wireless personal area network
CN107580339B (en) Information transmission method, device and wireless communication system
WO2017008751A1 (en) Positioning information transmission method and communication device
CN111034348B (en) User equipment, next generation wireless access network node and wireless communication method thereof
JP3821916B2 (en) Location information transmission terminal
CN113365210A (en) Satellite positioning data compression method
US20230189070A1 (en) Data transmission method and apparatus
CN117498892B (en) UWB-based audio transmission method, device, terminal and storage medium
CN100576858C (en) Be used for the selection of the transmission alphabet collection of short message service
CN111866293B (en) Mobile terminal, communication method and computer-readable storage medium
CN111935855A (en) Wireless sensor network base station device with multiple terminal interfaces

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