Undergrad What is the probability that the product of the digits is odd?

  • Thread starter Thread starter littlemathquark
  • Start date Start date
  • Tags Tags
    Probability
Click For Summary
SUMMARY

The probability that the product of the digits in a randomly chosen natural number is odd is determined by the nature of the digits. The first solution calculates the probability as p(n) = 5/4 * (5^n - 1) / (10^n - 1), which approaches zero as n approaches infinity. The second solution simplifies the problem by stating that the probability of all digits being odd decreases exponentially, yielding p(1) = 1/2 for a single digit. Both solutions are valid under different assumptions regarding the inclusion of zero as an even digit.

PREREQUISITES
  • Understanding of natural numbers and their properties
  • Familiarity with probability theory and basic combinatorics
  • Knowledge of exponential functions and limits
  • Ability to differentiate between even and odd numbers
NEXT STEPS
  • Explore the concept of infinite series and their convergence
  • Study the principles of combinatorial probability
  • Learn about the properties of digits in number theory
  • Investigate how to calculate probabilities involving multiple conditions
USEFUL FOR

Mathematicians, statisticians, educators, and students interested in probability theory and number properties will benefit from this discussion.

littlemathquark
Messages
204
Reaction score
26
TL;DR
What is the probability that the product of the digits in any selected positions of a randomly chosen digit natural number is odd?
I have two solutions, but I have no idea which solution correct. Both of them seem correct to me. Help please.

First solution:
There is an infinite number of natural numbers.
Product of digits is odd only if all digits in number are odd.

Counting natural numbers with all odd digits:

1-digit: 5
2-digit: 5*5
3-digit: 5*5*5
4-digit: 5*5*5*5=5^4

n-digit: 5^n

If we want probability for natural numbers up to n-digits:

Total number of odd-product numbers is :

5+5^2+5^3+…+5^n=5*(1+5+5^2+…+5^(n-1))=5*(5^n-1)/(5–1)=5/4*(5^n-1)

p(n)=5/4*(5^n-1)/(10^n-1)

If n is going to the infinity p(n) is going to 0.

Second solution:
Depends on the length of the digit string.

The more digits there are in a number, the greater the probability that at least one of them is even. If any of them are even, the product is even.

So really the question reduces to the probability that all the digits are odd, and that’s just inverse powers of 2…

1 digit: 1/2 = 50%

2 digits: 1/(2²) = 25%

3 digits: 1/(2³) = 12.5%

and so on.
 
  • Like
Likes apostolosdt
Physics news on Phys.org
littlemathquark said:
First solution:
There is an infinite number of natural numbers.
There is no uniform distribution on the natural numbers. It's only possible on a finite subset.

The best you can do is to take the limit as ##N \to \infty## for a subset of ##N## natural numbers. In this case, it's pretty clear that the proportion of natural numbers with all odd digits goes to zero as ##N \to \infty##.
 
Last edited:
The probability is zero.
 
littlemathquark said:
TL;DR Summary: What is the probability that the product of the digits in any selected positions of a randomly chosen digit natural number is odd?

I have no idea which solution correct. Both of them seem correct to me.
They are both correct.
 
But one of them p(1)=5/9 but for other solution(second) p(1)=1/2.which is correct?
 
littlemathquark said:
But one of them p(1)=5/9 but for other solution(second) p(1)=1/2.which is correct?
Maybe in the first case you didn't count zero as an even number and the second case you did
 
  • Like
Likes Dale and Gavran
Hornbein said:
Maybe in the first case you didn't count zero as an even number and the second case you did
And not only ## 0 ##.
In the second solution the original poster has included ## 00 ## into 2-digit natural numbers, ## 000 ## into 3-digit natural numbers, ## 0000 ## into 4-digit natural numbers and so on, and that is wrong.
 
What is the probability that the product of the digits in any k selected positions of a randomly chosen n-digit natural number is odd?
What about this question? Are solution the same?
 
  • #10
littlemathquark said:
What is the probability that the product of the digits in any k selected positions of a randomly chosen n-digit natural number is odd?
What about this question? Are solution the same?
That's just slightly tricky in that an n-digit number has a first digit that is randomly 1-9 and n-1 digits that are randomly 0-9.

You could calculate the two cases where the first digit is or is not in the k digits separately.
 
  • #11
The digits that make a number even are 2,4,6,8. So 6 of the digits will keep the product odd.

0.6^(n-1)*5/9 = 0.6^n * 25/27
 
  • #12
Hornbein said:
The digits that make a number even are 2,4,6,8. So 6 of the digits will keep the product odd.

0.6^(n-1)*5/9 = 0.6^n * 25/27
On second thought, if any one of the digits is zero then the product is zero. Is that even or odd?
 
  • #13
Hornbein said:
On second thought, if any one of the digits is zero then the product is zero. Is that even or odd?
Zero is even.
 
  • #14
PeroK said:
That's just slightly tricky in that an n-digit number has a first digit that is randomly 1-9 and n-1 digits that are randomly 0-9.

You could calculate the two cases where the first digit is or is not in the k digits separately.
Can you give a solution? I can not solve fully.
 

Similar threads

Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
857
  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 8 ·
Replies
8
Views
3K
  • · Replies 12 ·
Replies
12
Views
2K
  • · Replies 55 ·
2
Replies
55
Views
8K
  • · Replies 20 ·
Replies
20
Views
2K