[ home ] [ math / cs / ai / phy / as / chem / bio / geo ] [ civ / aero / mech / ee / hdl / os / dev / web / app / sys / net / sec ] [ med / fin / psy / soc / his / lit / lin / phi / arch ] [ off / vg / jp / 2hu / tc / ts / adv / hr / meta / tex ] [ chat ] [ wiki ]

/math/ - Mathematics


Name
Email
Subject
Comment
Verification
Instructions:
  • Press the Get Captcha button to get a new captcha
  • Find the correct answer and type the key in TYPE CAPTCHA HERE
  • Press the Publish button to make a post
  • Incorrect answer to the captcha will result in an immediate ban.
File
Password (For file deletion.)

25 Dec 2021Mathchan is launched into public

7 / 1 / 5 / ?

File: kotberet.png ( 154.62 KB , 393x403 , 1642718192578.png )

Image
As well as "Jew" or "gay" id on /pol/. I mean it's a three-letter word where second letter can be written as a number (k0t) and first and last letter aren't the same.

Now let's talk about IDs. They are 8-character sequences consisting of base64 characters (numbers, lowercase, uppercase letters, / and +). So, there can be

10+26+26+2=6410 + 26 + 26 + 2 = 64


possible characters for one position in id and thus

K0=648=248=281 474 976 710 656K_0 = 64^8 = 2^{48} = 281\ 474\ 976\ 710\ 656


possible IDs (BIG number :o).

Now back, to KOT.
You can write letters k, o and t in uppercase or lowercase and you can also write o as zero. That means you have
2×3×2=122\times3\times2 = 12
combinations of base64 characters that can make up the word "k0T".

Suppose that first three letters of your ID is one of 12 possible K0Ts. We have 5 letters of ID left and they can be anything from base64 alphabet.
So, there are

K1=12×645=12×230=12 884 901 888K_1 = 12 \times 64^5 = 12 \times 2^{30} = 12\ 884\ 901\ 888


So, it's also many, many ids. More than all cats, all humans, but less than all chickens in the world. So, maybe kot ID isn't really that rare.

Also there are 6 positions on which KoT id can happen:
KOTxxxxx
xKOTxxxx
xxKOTxxx
xxxKOTxx
xxxxKOTx
xxxxxKOT

We can assume that there are the same number of ids with KoT on n-th position where
n=1...6n = 1 ... 6
.

Remember, that KOT id can happen twice, so we must exclude duplicates:
KOTKOTxx
KOTxKOTx
KOTxxKOT
xKOTKOTx
xKOTxKOT
xxKOTKOT

Each of these duplicate positions exists in
K2=12×12×642=144×212=589824K_2 = 12 \times 12 \times 64^2 = 144 \times 2^{12} = 589824

configurations.

Because one duplicate can belong to two sets of IDs with at least one kot id (KOTxxKOT can belong to KOTxxxxx and xxxxxKOT), our equation for number of all KOT ids must be:

6×K16×K26 \times K_1 - 6 \times K_2


Let's calculate it:

6×K16×K2=6 \times K_1 - 6 \times K_2 =

6×12×2306×144×212=6 \times 12 \times 2^{30} - 6 \times 144 \times 2^{12} =

72×230864×212=72 \times 2^{30} - 864 \times 2^{12} =

77 305 872 38477\ 305\ 872\ 384


For every human on this planet there are approximately 10 KOT ids. :o

Now we can calculate probablility of having koT id:

77305872384K0=773058723842814749767106560.0002746456313641\frac{77305872384}{K_0} = \frac{77305872384}{281474976710656} \approx 0.00027464563 \approx \frac{1}{3641}


Thus, k0t id happens approximately one time for every 3641 ids.
Now you can calculate daily probability, because I don't know if ids on /bant/ are boardwise or just one for every poster and thread. x)
>>
you could have said "Calculating the daily probability is left as an exercise for the reader" though
>>
>>109
A almost forgot how my math lecturers said this. x) After corona started it's all gone. xp There were online lectures, but it's not the same. The best part of them were my friends joking about equations on the blackboard and even memes from r/dankmemes. xp

In next "lecture" I can calculate probability for kek or sus id.
>>
>>110
can you calculate the probability of "jak" id on /qa/ though
>>
>>126

Assuming that you can write second 'a' of 'jak' as 4 it's the same probability.

Thoughever, you can write it also as 'jaq' or 'jac', so there are 6 possibilities of writing the last letter there are:

2×3×6=362 \times 3 \times 6 = 36


Possible variation of previous constants for JaK:

K0=the sameK_0 = the\ same


K1=36×645=36×230=38 654 705 664K_1 = 36 \times 64^5 = 36 \times 2^{30} = 38\ 654\ 705\ 664


K2=36×36×642=1296×212=5 308 416K_2 = 36 \times 36 \times 64^2 = 1296 \times 2^{12} = 5\ 308\ 416



The final equation for the number of jAc IDs:

6×K16×K2=6 \times K_1 - 6 \times K_2 =

6×36×2306×1296×212=6 \times 36 \times 2^{30} - 6 \times 1296 \times 2^{12} =

216×2307776×212=216 \times 2^{30} - 7776 \times 2^{12} =

231 896 383 488231\ 896\ 383\ 488


And the probability:

231896383488K0=2318963834882814749767106560.00082386145311214\frac{231896383488}{K_0} = \frac{231896383488}{281474976710656} \approx 0.000823861453 \approx \frac{1}{1214}


So it's just pretty much 3 times bigger than "KoT". :o


/qa/ is dead tohough :(
>>
>>106
Let's eneralize this to id of length
nn
(for 4chan:
n=8n=8
) with set of
qq
different possible characers (for base64:
q=64q=64
) and substring of interest of length
 (n)\ell\ (\ell\leq n)
(for k0t:
=3\ell=3
) with
pp
different variations of the substring (for k0t:
p=12p = 12
)

The number of all possible IDs is:

K0=qn\qquad K_0 = q^n


If
k0t
appears in at least one place, we must consume
=3\ell = 3
characters to assemble them into
k0t
, then we return the
k0t
into the bunch (so we now have
n+1n -\ell + 1
items in the bunch) and then we arrange the
k0t
in
(n+11)n - \ell + 1\choose 1
ways. We have
pp
variations of k0t, plus
nn-\ell
other characters which can each be
qq
different vays (so
qnq^{n-\ell}
) (even tho I said "plus" we use
×\times
bcoz of thing called multiplication principle but w/e)

K1=(n+11)pqn\qquad K_1 = {n - \ell + 1 \choose 1}\cdot p \cdot q^{n - \ell}


If there are two
k0t
s somewhere, we must consume
2=62\ell = 6
characters to assemble 2
k0t
s (both with
p=12p=12
variations so
p2p^2
), then we return the k0t in the bunch (we now have
n2+2n -2\ell + 2
items) and we arrange the two kots in
(n2+2)2)n-2\ell + 2)\choose 2
ways. We have two kots which can each be
pp
different ways (so
p2p^2
) and
n2n - 2\ell
unconsoomed characters which can each be
qq
different ways (
qn2q^{n - 2\ell}
)

K2=(n2+2)2)p2qn2\qquad K_2 = {n - 2\ell + 2)\choose 2}\cdot p^2\cdot q^{n - 2\ell}


Therefore if we have
kk
k0t
s, the fomula is the following: (and I have a truly marevolous way to prove this formula by induction but I am also truly a lazy fuck.)

Kk=(nk(1)k)pkqnk\qquad K_k = {n - k(\ell - 1)\choose k}\cdot p^k\cdot q^{n-k\ell}


Now if we want to count all the
k0t
s without duplicates, we must use inclusion-exclusion principle:

KΣ=k=1nk(1)>0(1)k1Kk\qquad K_{\Sigma} = \sum_{k = 1}^{n - k(\ell - 1) > 0}(-1)^{k - 1}\cdot K_k


Then the probability of
k0t
appearing is

P=KΣK0\qquad P = \frac{K_\Sigma}{K_0}



So if I plug in the numbers for
k0t
on /pol/ slash /biz/:

n=8q=64=3p=12\begin{aligned} \qquad n &= 8\\q &= 64\\\ell&=3\\p&=12 \end{aligned}


We get the following result
P=KΣK0=1qnk=1nk(1)>0(1)k1Kk=1648((83+11)12645(86+22)122642)=12642648(6643612)=773058723842814749767106560.02746%\qquad P = \frac{K_\Sigma}{K_0} = \frac{1}{q^n}\sum_{k = 1}^{n - k(\ell - 1) > 0}(-1)^{k - 1}\cdot K_k = \frac{1}{64^8}\cdot\left({8 - 3 + 1\choose 1}\cdot 12\cdot 64^5 - {8 - 6 + 2\choose 2}\cdot 12^2\cdot 64^2\right) = \frac{12\cdot 64^2}{64^8}\cdot(6\cdot 64^3 - 6\cdot 12) = \frac{77305872384}{281474976710656} \approx 0.02746\%


Which matches OP's numbers!
>>
>>129
Nice, I treat the fact that our results are the same as a miracle because I always get something wrong during calculations. x)

Also I wonder if determining number for arbitrary word and
nn
(or just equation for
Kk,k1,...,nK_k, k \in 1,...,n
) can have an elegant equation or generic brute-force algorithm is the best way.

For example the word SUS is kinda sus, because SUSUSUSx is a valid id with three occurences of the searched word.

We can assume that there are problems when
kk
-long suffix of the word is
kk
-long prefix like when 'S' is 1-long suffix and prefix of 'SuS' and I see hope there, but words like 'SSUSSUSS' have the same words of length 1,2 and 5 as prefixes and suffixes of respective lengths.
>>
test