Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 205031
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T17:31:14+00:00 2026-05-11T17:31:14+00:00

I am to compress location data (latitude,longitude, date,time). All the numbers are in fixed

  • 0

I am to compress location data (latitude,longitude, date,time). All the numbers are in fixed format. 2 of them (latitude,longitude) are with decimal format. Other 2 are integers.

Now these numbers are in fixed format string.

What are the algorithms for compressing numbers in fixed format?
Is number only compressions (if there any) better than string compression?
Should I directly compress string without converting it to numbers and then compress?

Thanks in advance.

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T17:31:14+00:00Added an answer on May 11, 2026 at 5:31 pm

    This is one of these places where a little theory is helpful. You need to think about several things:

    • what is the resolution of your measurements: 0.1° or 0.001°? 1 second or one microsecond?
    • are the measurements associated and in some order, or tossed together randomly?

    Let’s say, just for example, that the resolution is 0.01°. Them you know that your values range from -180° to +180°, or 35900 different values. Lg(35900) ≈ 16 so you need 16 bits; 14 bits for -90°–+90°. Clearly, if you’re storing this kind of value as floating-point, you can compress the data by half immediately.

    Similarly with date time, what’s the range; how many bits must you have?

    Now, if the data is in some order (like, samples taken sequentially aboard a single ship) then all you need is a start value and a delta; that can make a big difference. With a ship traveling at 30 knots, the position can’t change any more that about 0.03 degrees an hour or about 0.0000083 degrees a second. Those deltas are going to be very small values, so you can store them in a very few bits.

    The point is that there are a number of things you can do, but you have to know more about the data than we do to make a recommendation.


    Update: Oh, wait, fixed point strings?!

    Okay, this is (relatively) easy. Just to start with, yes, you want to convert your strings into some binary representation. Just making up a data item, you might have

    040.00105.0020090518212100Z
    

    which you could convert to

    |  4000            | short int, 16 bits |  
    | 10500            | short int, 16 bits |  
    | 20090518212100Z  | 64 bits            |
    

    So that’s 96 bits, 12 bytes versus 26 bytes.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to compress some files (into the ZIP format) and encrypt them if
I am wanting to compress results from QUERYS of the database before adding them
We have a simple binary file format for caching data in our application (C#
We have to compress a ton o' (monochrome) image data and move it quickly.
I want to compress a file into zip, rar and 7z format using java
After downloading images it saves them to this location String extStorageDirectory; protected void onCreate(Bundle
My requirement is to compress xml file into a binary format, transmit it and
I need to compress video image data (lets say a display object) in AS3
The code below get image from some location - and make this image compress
I would like to compress the data coming out of WCF on a basicHttpBinding.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.