Velocity Reviews > How Do You Pronounce char?

# How Do You Pronounce char?

Ido Yehieli
Guest
Posts: n/a

 01-31-2008
On Jan 30, 12:58 am, CBFalconer <(E-Mail Removed)> wrote:
> Ido Yehieli wrote:
> > "Malcolm McLean" <(E-Mail Removed)> wrote:
> >> "float" can be pronounced "a real value" if you want to add a
> >> touch of class.

> > But it isn't. How do you represent sqrt(2), pi or even the
> > rational fraction 1/3? A float is a floating point number, not
> > a real number.

> As integers, try 1, 3, 0. If you want exact values you are out of
> luck, even if the machine has floats, doubles, etc. of any finite
> size. However you can represent 1/3 as a rational.

My point was that a float doesn't represent a real number, in fact it
doesn't even represent a rational number.

-Ido.

Malcolm McLean
Guest
Posts: n/a

 01-31-2008

"Ido Yehieli" <(E-Mail Removed)> wrote in message
>
> On Jan 30, 12:58 am, CBFalconer <(E-Mail Removed)> wrote:
>> Ido Yehieli wrote:
>> > "Malcolm McLean" <(E-Mail Removed)> wrote:
>> >> "float" can be pronounced "a real value" if you want to add a
>> >> touch of class.
>> > But it isn't. How do you represent sqrt(2), pi or even the
>> > rational fraction 1/3? A float is a floating point number, not
>> > a real number.

>> As integers, try 1, 3, 0. If you want exact values you are out of
>> luck, even if the machine has floats, doubles, etc. of any finite
>> size. However you can represent 1/3 as a rational.

>
> My point was that a float doesn't represent a real number, in fact it
> doesn't even represent a rational number.
>

They are rational numbers. Just not the ratio you passed in as decimal.

--
Free games and programming goodies.
http://www.personal.leeds.ac.uk/~bgy1mm

Mark McIntyre
Guest
Posts: n/a

 01-31-2008
Malcolm McLean wrote:
>
> "Ido Yehieli" <(E-Mail Removed)> wrote in message

>> My point was that a float doesn't represent a real number, in fact it
>> doesn't even represent a rational number.
>>

> They are rational numbers. Just not the ratio you passed in as decimal.

You misunderstood - the prev poster was pointing out that you can't use
floats to represent rational numbers. 1/3 was an example.

--
Mark McIntyre

CLC FAQ <http://c-faq.com/>

Morris Dovey
Guest
Posts: n/a

 01-31-2008
Ido Yehieli wrote:
>
> On Jan 29, 2:10 pm, "Malcolm McLean" <(E-Mail Removed)> wrote:
> > "float" can be pronounced "a real value" if you want to add a touch of
> > class.

>
> But it isn't. How do you represent sqrt(2), pi or even the rational
> fraction 1/3? A float is a floating point number, not a real number.

Just as you would if you were using a pencil and paper to show
the values - as rational approximations using a representation

--
Morris Dovey
DeSoto Solar
DeSoto, Iowa USA
http://www.iedu.com/DeSoto

Ben Bacarisse
Guest
Posts: n/a

 01-31-2008
Mark McIntyre <(E-Mail Removed)> writes:

> Malcolm McLean wrote:
>>
>> "Ido Yehieli" <(E-Mail Removed)> wrote in message

>
>>> My point was that a float doesn't represent a real number, in fact it
>>> doesn't even represent a rational number.
>>>

>> They are rational numbers. Just not the ratio you passed in as decimal.

>
> You misunderstood -

Then I misunderstood as well. As far as I can see, Ido Yehieli made a
statement that needed to be corrected. If a float does not represent
a real (and all do) and "it does not even represent a rational
number" then I puzzled about what is does represent.

This is so wrong that I suspect a language issue. "a float" and "it"
suggest one instance of the type float, but Ido probably wanted to
talk about the type float and the set of rationals. "The float type
does not represent the set of reals, in fact it does not even represent
the rationals" is much more likely what was meant.

> the prev poster was pointing out that you can't
> use floats to represent rational numbers.

You can't mean that, surely. Did you mean to say "... *all* rational
numbers", i.e. that the values of type float represent a very small
subset of the rationals?

> 1/3 was an example.

--
Ben.

Malcolm McLean
Guest
Posts: n/a

 01-31-2008

"Ben Bacarisse" <(E-Mail Removed)> wrote in message
> Then I misunderstood as well. As far as I can see, Ido Yehieli made a
> statement that needed to be corrected. If a float does not represent
> a real (and all do) and "it does not even represent a rational
> number" then I puzzled about what is does represent.
>

If represents a number, or not a number, depending on what isnan() returns.
So floats certainly are not a subset of the rationals.

--
Free games and programming goodies.
http://www.personal.leeds.ac.uk/~bgy1mm

Mark McIntyre
Guest
Posts: n/a

 01-31-2008
Ben Bacarisse wrote:
> Mark McIntyre <(E-Mail Removed)> writes:
>
>> Malcolm McLean wrote:
>>> "Ido Yehieli" <(E-Mail Removed)> wrote in message
>>>> My point was that a float doesn't represent a real number, in fact it
>>>> doesn't even represent a rational number.
>>>>
>>> They are rational numbers. Just not the ratio you passed in as decimal.

>> You misunderstood -

>
> Then I misunderstood as well.

Yes.

As far as I can see, Ido Yehieli made a
> statement that needed to be corrected.

I think he made a statement you misunderstood. He was saying that the
float type is incapable of representing real numbers in general.

If a float does not represent
> a real (and all do)

Represent 0.11111111 recurring exactly in IEEE floating point.

and "it does not even represent a rational
> number" then I puzzled about what is does represent.

It represents a subset of reals , and a smaller subset of rationals.

> This is so wrong that I suspect a language issue.

I don't agree. In many languages, the impersonal and singular pronouns
are commonly used to represent generalised ideas. On fait quelquechose.
Er geht.

"The float type
> does not represent the set of reals, in fact it does not even represent
> the rationals" is much more likely what was meant.

Yes, I think thats exactly what he meant.

>> the prev poster was pointing out that you can't
>> use floats to represent rational numbers.

>
> You can't mean that, surely. Did you mean to say "... *all* rational
> numbers", i.e. that the values of type float represent a very small
> subset of the rationals?

That's what I said. Apparently nobody here did basic logic at school.

--
Mark McIntyre

CLC FAQ <http://c-faq.com/>

CBFalconer
Guest
Posts: n/a

 01-31-2008
Mark McIntyre wrote:
> Malcolm McLean wrote:
>> "Ido Yehieli" <(E-Mail Removed)> wrote:

>
>>> My point was that a float doesn't represent a real number, in
>>> fact it doesn't even represent a rational number.
>>>

>> They are rational numbers. Just not the ratio you passed in as
>> decimal.

>
> You misunderstood - the prev poster was pointing out that you
> can't use floats to represent rational numbers. 1/3 was an example.

^-- binary ^-- all

Correct as above.

--
[mail]: Chuck F (cbfalconer at maineline dot net)
[page]: <http://cbfalconer.home.att.net>

--
Posted via a free Usenet account from http://www.teranews.com

Ben Bacarisse
Guest
Posts: n/a

 02-01-2008
"Malcolm McLean" <(E-Mail Removed)> writes:

> "Ben Bacarisse" <(E-Mail Removed)> wrote in message
>> Then I misunderstood as well. As far as I can see, Ido Yehieli made a
>> statement that needed to be corrected. If a float does not represent
>> a real (and all do) and "it does not even represent a rational
>> number" then I puzzled about what is does represent.
>>

> If represents a number, or not a number, depending on what isnan() returns.
> So floats certainly are not a subset of the rationals.

You are quite right that some floating point representations include
values that are not in the set of reals.

--
Ben.

Ben Bacarisse
Guest
Posts: n/a

 02-01-2008
Mark McIntyre <(E-Mail Removed)> writes:

> Ben Bacarisse wrote:

<snip>
>> "The float type
>> does not represent the set of reals, in fact it does not even represent
>> the rationals" is much more likely what was meant.

>
> Yes, I think thats exactly what he meant.

We are all agreed then.

>>> the prev poster was pointing out that you can't
>>> use floats to represent rational numbers.

>>
>> You can't mean that, surely. Did you mean to say "... *all* rational
>> numbers", i.e. that the values of type float represent a very small
>> subset of the rationals?

>
> That's what I said. Apparently nobody here did basic logic at
> school.

Do you answer "yes" when asked if you want red or white?

--
Ben.