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 8856559
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T14:23:01+00:00 2026-06-14T14:23:01+00:00

I wanted to create a vector with three values 1/6, 2/3 and 1/6. Obviously

  • 0

I wanted to create a vector with three values 1/6, 2/3 and 1/6. Obviously I Matlab has to convert these rational numbers into real numbers but I expected that it would maximize the precision available.

It’s storing the values as doubles but it’s storing them as –

b =

    0.1667    0.6667    0.1667

This is a huge loss of precision. Isn’t double supposed to mean 52 bits of accuracy for the fractional part of the number, why are the numbers truncated so severly?

  • 1 1 Answer
  • 0 Views
  • 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-06-14T14:23:02+00:00Added an answer on June 14, 2026 at 2:23 pm

    The numbers are only displayed that way. Internally, they use full precision. You can use the format command to change display precision. For example:

    format long

    will display them as:

    0.166666666666667    0.666666666666667    0.166666666666667

    So the answer is simple; there is no loss of precision. It’s only a display issue.

    You can read the documentation on what other formats you can use to display numbers.

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

Sidebar

Related Questions

I wanted to create some subdirectories inside my blob. But it is not working
I wanted to create jquery plugin & started off creating a sample jquery plugin...But
I wanted to create a empty bullet paragraph, but it didn't work. This is
I wanted to create smth similar to this one Kansas county map where user
I wanted to create a new property on a table in my model.. Basically
I wanted to create a control with a TextBox and to bind TextBox.Text property
I wanted to create a very simple method that switches between views in a
I wanted to create a page with a simple button which runs away from
I wanted to create one js file which includes every js files to attach
I wanted to create a default value for :order : class Comment < ActiveRecord::Base

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.