473,404 Members | 2,137 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

Prceision greater than that of a double

Hi

Could anyone help me in a precision code,
i want my output to a file to be to precision(12)
but this dont apply to when a output is 0.000312764827372 which is defined as double.
Is there anyway to make this figure to precision 12 including the zero's and not after the zero's. This applies to a list of values in my output file.
If anyone knows of a decimal point code then please let me know.

thanks
Feb 26 '08 #1
4 1471
sicarie
4,677 Expert Mod 4TB
ravipanchal-

Please do not "thread hijack" (ask your question in someone else's thread). It is EXTREMELY rude. I will split this off for you. Please review the Posting Guidelines of this site for the rest of the rules we ask everyone who posts to abide by.

So what have you tried on this? Did you Google search for a library that will allow for a datatype with extra precision?

Thanks,

sicarie
Feb 26 '08 #2
And what code have you tried + which language?
Feb 26 '08 #3
RedSon
5,000 Expert 4TB
And what code have you tried + which language?
Language is probably c/c++ code. Have you tried searching google for libraries?
Feb 26 '08 #4
Language is probably c/c++ code. Have you tried searching google for libraries?
I know, but C != C++.
Feb 26 '08 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: Martin | last post by:
I am trying to write code that selects a random number in the range 0 to n, where n can be substantially greater than the RAND_MAX on my system which is 32767. I am using VC++ 2003 FWIW. As you...
6
by: Alexander Stoyakin | last post by:
Hello, please advise on the following issue. I need to check that difference between two double values is not higher than defined limit. int main() { double limit = 0.3; double val1 = 0.5,...
3
by: =?Utf-8?B?U2NvdHQ=?= | last post by:
Hello, I would like to convert a double to a string and have the resulting string contain all of the original values after the decimal place. Currently, the problem that I am having is that the...
11
by: Steven Woody | last post by:
long i = nnn; long j; double d; d = i; j = ( long )d; in this case, i == j ? thanks.
1
by: DK | last post by:
Observe the following snippet of code and see if you can explain why it happens. Dim sAnything as Single sAnything = 31.308 If sAnything 31.308 then msgbox "value greater" else
206
by: md | last post by:
Hi Does any body know, how to round a double value with a specific number of digits after the decimal points? A function like this: RoundMyDouble (double &value, short numberOfPrecisions) ...
2
by: Markus Dehmann | last post by:
I have two integers i1 and i2, the second of which is guaranteed to be between 0 and 99, and I encode them into one double: double encoded = (double)i1 + (double)i2 / (double)100; So, for...
0
by: =?ISO-8859-1?Q?Marcel_M=FCller?= | last post by:
clintonb wrote: There is nothing like an original double amount. If you care about rounding errors you must not store any currency value in an approximate number. You must not do this even once....
13
by: =?Utf-8?B?U3RlZmFuRw==?= | last post by:
With the test I've made on my WinXP/VS2005/C#2.0, I get a precision of 42bit. Is this specified in C# or dependent on what? double dLeft = 2183.23 - 695.37; double dRight = 1487.86; double...
7
by: Kürşat | last post by:
Hi, I have a strange problem about a simple sum operation on a double variable. There is a loop in my application like this : double _max = 0.4; double _step = 0.1; for (double d = 0.0; i...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.