Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.advocacy > #650372

Re: A Problem To Solve :-)

From Physfitfreak <Physfitfreak@gmail.com>
Newsgroups comp.os.linux.advocacy, sci.physics
Subject Re: A Problem To Solve :-)
Date 2024-03-03 13:02 -0600
Message-ID <us2hg4$tba4$2@solani.org> (permalink)
References (11 earlier) <urlmqs$mk3p$1@solani.org> <uru46k$r281$1@solani.org> <17b8f7d5912c2f50$20384$3953837$802601b3@news.usenetexpress.com> <us0hqb$saki$1@solani.org> <us2g9b$tba4$1@solani.org>

Cross-posted to 2 groups.

Show all headers | View raw


On 3/3/2024 12:41 PM, Physfitfreak wrote:
> On 3/2/2024 6:55 PM, Physfitfreak wrote:
>> Note that in general you can write the decimals as sum of fractions 
>> with powers of 10 in the denominators of them. If you replace those 
>> 10s by 2 x 5 then you can convert that decimal number to a fraction 
>> with nothing in its denominator but factors of 2 and 5 _only_. Since 
>> this holds for any fraction with terminating decimal, then all you 
>> need to show to prove the fraction does not have terminating decimals 
>> is to show that a prime other than 2 or 5 is also a factor in the 
>> denominator.
> 
> 
> I missed one logical step. Here is a better explanation.
> 
> Any fraction can be written as a number with decimals that either 
> terminate, or continue for ever.
> 
> But _if_ the fraction has terminating decimals, then the number can be 
> written as a _finite_ sum of fractions with various powers of 10 in 
> their denominators. Like for instance:
> 
> 11/8 = 1.375 = 1/[(10)^0] + 3/[(10)^1] + 7/[(10)^2] + 5/[(10)^3]
> 
>       = 1 + 3/(2 x 5) + 7/(2^2 x 5^2) + 5/(2^3 x 5^3)
> 
> Now add these fractions. You place the greatest common divisor which is 
> (2^3 x 5^3) in the denominator of the resultant fraction, and use the 
> elementary method of adding the fractions to get:
> 
>      denominator of the result = (2^3 x 5^3)
>      numerator of the result = (2^3 x 5^3) + 3(2^2 x 5^2) + 7(2 x 5) + 5
> 
> So, as you see, for a fraction with terminating decimals you would 
> _only_ have powers of 2 and/or 5 in the denominator, plus the fraction 
> will be exactly equal to what it first was (in this case reducing to 11/8).
> 
> But with a fraction with non-terminating decimals, say 11/6, you would 
> have:
> 
> 11/6 = 1.8333333333... = 1/[(10)^0] + 8/[(10)^1] + 3/[(10)^2] + 
> 3/[(10)^3] + ...
> 
> So you can't trivially get the greatest common divisor for it so you 
> could sum the fractions. To be able to make the sum, you can do this:
> 
> 11/6 = 1/[(10)^0] + 8/[(10)^1] + 3/(90)
> 
> Now you'd be able to perform the sum:
> 
>       denominator of the result = 90 = 2 x 5 x 3 x 3
>       numerator of the result  = 90 + 72 + 3 = 165
> 
> and as you see, the denominator now has had to have prime number(s) 
> other than 2 or 5.
> 
> So this check can be used to easily find whether 11/6 has terminating or 
> non-terminating decimals:
> 
> denominator = 2 x 3
> 
> and since the prime 3 appears there, the fraction will have 
> non-terminating decimals.
> 
> 
> 


I don't know about you cro-magnons, but the numerical methods class we 
had here 40 years back, briefly went over this trivial matter, cause it 
was one of the cases where we had to check whether we should deal, or 
not deal, with the machine epsilon in our codes.

And generally, we learned in that course, to not take things for granted 
as it were presented to you. You'd have to be more careful with it.

An "engineer" would just throw the code at any computer and stick his 
dick in it as well. Us physicists couldn't afford that :-)





-- 
This email has been checked for viruses by Avast antivirus software.
www.avast.com

Back to comp.os.linux.advocacy | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-02-27 16:13 -0600
  Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-01 20:50 -0600
    Re: A Problem To Solve :-) Farley Flud <ff@linux.rocks> - 2024-03-02 12:10 +0000
      Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-02 12:06 -0600
        Re: A Problem To Solve :-) Farley Flud <ff@linux.rocks> - 2024-03-02 19:44 +0000
          Re: A Problem To Solve :-) Joel <joelcrump@gmail.com> - 2024-03-02 15:58 -0500
            Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-02 18:59 -0600
          Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-02 21:55 -0600
            Re: A Problem To Solve :-) Farley Flud <ff@linux.rocks> - 2024-03-03 10:24 +0000
              Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 10:03 -0600
                Re: A Problem To Solve :-) rbowman <bowman@montana.com> - 2024-03-03 20:21 +0000
                Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 14:46 -0600
                Re: A Problem To Solve :-) rbowman <bowman@montana.com> - 2024-03-04 01:27 +0000
            Re: A Problem To Solve :-) Farley Flud <ff@linux.rocks> - 2024-03-03 19:28 +0000
              Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 14:34 -0600
          Re: A Problem To Solve :-) Stéphane CARPENTIER <sc@fiat-linux.fr> - 2024-03-03 10:33 +0000
            Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 14:03 -0600
          Re: A Problem To Solve :-) DFS <dfs@nospam.com> - 2024-03-03 09:57 -0500
        Re: A Problem To Solve :-) Stéphane CARPENTIER <sc@fiat-linux.fr> - 2024-03-03 10:26 +0000
          Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 10:08 -0600
          Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 14:04 -0600
            Re: A Problem To Solve :-) Stéphane CARPENTIER <sc@fiat-linux.fr> - 2024-03-03 20:42 +0000
              Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 14:48 -0600
                Re: A Problem To Solve :-) Stéphane CARPENTIER <sc@fiat-linux.fr> - 2024-03-03 21:20 +0000
                Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 15:30 -0600
        Re: A Problem To Solve :-) DFS <dfs@nospam.com> - 2024-03-03 09:33 -0500
    Re: A Problem To Solve :-) Farley Flud <ff@linux.rocks> - 2024-03-02 14:09 +0000
      Re: A Problem To Solve :-) Farley Flud <fflud@gnu.rocks> - 2024-03-02 19:18 +0000
        Re: A Problem To Solve :-) Joel <joelcrump@gmail.com> - 2024-03-02 14:25 -0500
        Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-02 19:01 -0600
        Re: A Problem To Solve :-) DFS <nospam@dfs.com> - 2024-03-03 09:36 -0500
      Re: A Problem To Solve :-) Chris Ahlstrom <OFeem1987@teleworm.us> - 2024-03-02 16:22 -0500
        Re: A Problem To Solve :-) Farley Flud <ff@linux.rocks> - 2024-03-02 22:27 +0000
          Re: A Problem To Solve :-) Joel <joelcrump@gmail.com> - 2024-03-02 17:40 -0500
          Re: A Problem To Solve :-) rbowman <bowman@montana.com> - 2024-03-03 00:09 +0000
            Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-02 19:17 -0600
              Re: A Problem To Solve :-) rbowman <bowman@montana.com> - 2024-03-03 04:18 +0000
                Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 10:17 -0600
      Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-02 18:55 -0600
        Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 12:41 -0600
          Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 13:02 -0600
            Re: A Problem To Solve :-) Farley Flud <ff@linux.rocks> - 2024-03-03 19:25 +0000
              Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-03 14:22 -0600
                Re: A Problem To Solve :-) rbowman <bowman@montana.com> - 2024-03-04 03:01 +0000
    Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-05 14:42 -0600
      the answer is “Pwnage” -hh <recscuba_google@huntzinger.com> - 2024-03-05 18:20 -0500
        Re: the answer is “Pwnage” Farley Flud <ff@linux.rocks> - 2024-03-05 23:47 +0000
          Re: the answer is “Pwnage” Physfitfreak <Physfitfreak@gmail.com> - 2024-03-05 22:52 -0600
        Re: the answer is “Pwnage” Physfitfreak <Physfitfreak@gmail.com> - 2024-03-05 22:41 -0600
      Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-07 17:29 -0600
        Re: A Problem To Solve :-) Chris Ahlstrom <OFeem1987@teleworm.us> - 2024-03-07 19:18 -0500
          Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-07 19:02 -0600
            Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-07 19:27 -0600
            Re: A Problem To Solve :-) Chris Ahlstrom <OFeem1987@teleworm.us> - 2024-03-08 07:38 -0500
        Nice. </Sarcasm> "Relf"  <Usenet@Jeff-Relf.Me> - 2024-03-07 16:46 -0800
        Re: A Problem To Solve :-) Physfitfreak <Physfitfreak@gmail.com> - 2024-03-10 16:11 -0500

csiph-web