spamsink: (Default)
[personal profile] spamsink
Ну что, пошёл я на пресловутый chat.openai.com и спросил у него:

Ackermann(4, 4)=?

На что получил вполне разумный ответ

The Ackermann function is a mathematical function that is used to test the computational capabilities of computers. It is a very complex function that grows very quickly, even for relatively small input values.

In general, the Ackermann function is defined as follows:

Ackermann(m, n) =

  • n + 1, if m = 0
  • Ackermann(m - 1, 1), if m > 0 and n = 0
  • Ackermann(m - 1, Ackermann(m, n - 1)), if m > 0 and n > 0
So, in the case of Ackermann(4, 4), we have:

Ackermann(4, 4) = Ackermann(3, Ackermann(4, 3))

Since Ackermann(4, 3) is itself a very large number, the value of Ackermann(4, 4) is extremely large and is not practical to calculate by hand. In general, the Ackermann function grows so quickly that it is not feasible to calculate its value for even moderately large input values.

Замечательно, думаю. А если что посложнее?

What is the expected number of people such that the probability of every day in a year being somebody's birthday is greater than 50%?

Дальше решайте сами, иметь этот вумный как вутка интеллект или не иметь (особо см. выделенное):

The probability that any given day is not somebody's birthday is 1 minus the probability that it is somebody's birthday. For a group of size N, the probability that a given day is not somebody's birthday is (365-1)/365 * (364-1)/364 * ... * (365-N)/365. So the probability that a given day is not somebody's birthday is 1 when the following equation is true:

(365-1)/365 * (364-1)/364 * ... * (365-N)/365 = 1

To solve this equation, we can take the natural logarithm of both sides to get:

ln((365-1)/365 * (364-1)/364 * ... * (365-N)/365) = 0

Since the natural logarithm is a monotonically increasing function, we can apply it to both sides of the inequality to get:

ln(1 - 1/365) + ln(1 - 2/365) + ... + ln(1 - N/365) < 0

We can then rearrange the terms and use the fact that the natural logarithm is an increasing function to get:

N * ln(1 - 1/365) + (N-1) * ln(1 - 2/365) + ... + 1 * ln(1 - N/365) < 0

From this equation, we can see that the value of N that satisfies the inequality is the smallest value of N such that the sum of the natural logarithms on the left-hand side is less than 0.

To find this value of N, we can simply try different values of N and calculate the sum of the natural logarithms until we find the smallest value of N that satisfies the inequality. For example, if we try N = 1, we have:

1 * ln(1 - 1/365) = -0.0027

This value is not less than 0, so we know that N must be greater than 1. If we try N = 2, we have:

2 * ln(1 - 1/365) + ln(1 - 2/365) = -0.0147

This value is also not less than 0, so we know that N must be greater than 2. If we try N = 3, we have:

3 * ln(1 - 1/365) + 2 * ln(1 - 2/365) + ln(1 - 3/365) = -0.0296

This value is less than 0, so we know that N = 3 is the smallest value of N that satisfies the inequality.

Therefore, the expected number of people such that the probability of every day in a year being somebody's birthday is greater than 50% is 3.

Note that this is just an approximation, and the actual value of N may be slightly different depending on the precision of the calculations. Also, this calculation assumes that all birthdays are equally likely, which may not be the case in reality.


Такие дела.

Date: 2023-02-03 02:17 am (UTC)
stas: (Default)
From: [personal profile] stas
Мне этот ведроид заявил, что birthday number - 253. Где-то в среднем норм.

Date: 2023-02-03 02:27 am (UTC)
stas: (Default)
From: [personal profile] stas
Я его спросил: What is the expected number of people such that the probability of every day in a year being somebody's birthday is greater than N%, assuming N equals to any number between 49 and 51?

И оно глаголело:

....
So, if N equals to 49, the expected number of people is slightly greater than 23. If N equals to 50, the expected number of people is exactly 23. If N equals to 51, the expected number of people is slightly less than 23.

Чиста полтора землекопа. А еще смешнее:

What is the expected number of people such that the probability of every day in a year being somebody's birthday is greater than N%, assuming N equals to 49.99991?
To calculate the expected number of people such that the probability of every day in a year being somebody's birthday is greater than N%, assuming N equals to 49.99991, we can use the birthday paradox formula.

The birthday paradox formula states that the probability of two people having the same birthday in a group of N people is approximately given by 1 - (365/365)^(N choose 2), where 365 is the number of days in a year and (N choose 2) is the number of pairs of people in the group.

To find the expected number of people such that the probability of every day in a year being somebody's birthday is greater than 49.99991, we need to find N such that 1 - (365/365)^(N choose 2) is greater than 49.99991. This can be solved numerically or with an iterative approach.

However, it should be noted that the birthday paradox formula is only an approximation and the actual probability of two people having the same birthday can vary based on many factors such as leap years, cultural and regional differences in birth rates, and so on.

Готового ответа в базе нет, а считать ведроид не умеет. Ну и (365/365) конечно, чтоб добить.

Profile

spamsink: (Default)
spamsink

May 2025

S M T W T F S
     123
4 567 8910
11121314151617
18 19 2021222324
25262728293031

Most Popular Tags

Page Summary

Style Credit

Expand Cut Tags

No cut tags
Page generated May. 30th, 2025 01:45 pm
Powered by Dreamwidth Studios
OSZAR »