Dear :
I use the Product:"TI TMS320VC5510", related link:
http://focus.ti.com/docs/prod/folder...320vc5510.html
In this environment, its data type "double" is 4 bytes, and it doesn't
support 8bytes-double. The precision is not good enough for me. So I
need the class "8ByteDouble" to improve the precision.
For example,in this environment,
double dvar = 0.123456789999;
the compiler compiles the dvar : 0.1234568
caused by the length of the double is 4 bytes,not 8bytes.
But I need the 0.----9999.
The class 8ByteDouble could sovle this problem??
If no, any solution could sovle it??
Thanks for your help.
JKop <> wrote in message news:<GHG%c.26841$>...
> Yes I could help you, but not to be rude, that would result
> in me writing the (long) class for you. I can suggest
> methods though: instead of using decimals, define a minimal
> unit, let's say 0.0000000000001 or whatever. You'll store
> this as integer 1. Maybe try something along the following
> lines:
>
> class 8ByteDouble
> {
> private:
> char bytes[4];
>
> public:
> 8ByteDouble& operator+=(...
> };
>
> 8ByteDouble sin(8ByteDouble& k)
> {
> ...
> }
>
> Then again you could search the net and find one that's
> already been done for you.
>
> Have you tried "long double"?
>
> Note that a "byte" is different sizes on different
> machines. Most of them though are 8-Bit.
>
>
> -JKop