Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
| Download
Project: Peter's Files
Views: 3893
Visibility: Unlisted (only visible to those who know the link)
Image: ubuntu1804

Secret Sequences


Introduction

Ria has a secret sequence s=(s1,s2,s3,s4)N4\mathbf{s}=(s_1,s_2,s_3,s_4)\in\mathbb{N}^4 that Nate wants to know. Nate is allowed to ask questions in the form of sequences q=(q1,q2,q3,q4)N4\mathbf{q}=(q_1,q_2,q_3,q_4)\in\mathbb{N}^4, to which Ria will reply s1q1+s2q2+s3q3+s4q4.s_1q_1+s_2q_2+s_3q_3+s_4q_4.

We can treat the sequences in N4\mathbb{N}^4 as vectors, so Ria's response can also be written as sq\mathbf{s}\cdot\mathbf{q}, where \cdot is the dot product.

We would like to prove the following statement false:

One question qN4\mathbf{q}\in\mathbb{N}^4 is always sufficient to decode a secret sN4\mathbf{s}\in\mathbb{N}^4.

Note: all sequences are in N4\mathbb{N}^4.


Interpretations

What we mean by "decode" is that given q\mathbf{q} and sq\mathbf{s}\cdot\mathbf{q}, Nate should be able to uniquely determine s\mathbf{s}; that is, for all t\mathbf{t}, with st\mathbf{s}\neq\mathbf{t}, we have qsqt\mathbf{q}\cdot\mathbf{s}\neq\mathbf{q}\cdot\mathbf{t}. In shorter notation, ts    sqtq\forall\mathbf{t}\neq\mathbf{s}\implies\mathbf{s}\cdot\mathbf{q}\neq\mathbf{t}\cdot\mathbf{q}

Let D(q,s)D(\mathbf{q},\mathbf{s}) denote the predicate that q\mathbf{q} can "decode" s\mathbf{s}.


Now we have two interpretations of the above statement:

  1. (The "magic question" interpretation) There is some fixed question q\mathbf{q} that can decode any secret s\mathbf{s}. The quantifier chain is q,sD(q,s).\exists\mathbf{q},\forall\mathbf{s}\, D(\mathbf{q},\mathbf{s}).

  2. (The "luck" interpretation) For any secret s\mathbf{s}, there is some question q\mathbf{q} that can decode s\mathbf{s}. The quantifier chain is s,q,D(q,s).\forall\mathbf{s},\exists\mathbf{q}, D(\mathbf{q},\mathbf{s}).


Combinations of Quantifiers

The two interpretations suggest that similar quantifier chains will be interesting.

1. q,s,D(q,s)\exists\mathbf{q},\exists\mathbf{s},D(\mathbf{q},\mathbf{s}) is True.

"There is some question that can decode some secret."

Proof: The question q=(1,1,1,1)\mathbf{q}=(1,1,1,1) decodes the secret sequence s=(1,1,1,1)\mathbf{s}=(1,1,1,1).

\square
2. q,s,D(q,s)\forall\mathbf{q},\forall\mathbf{s},D(\mathbf{q},\mathbf{s}) is False.

"Every question decodes every secret." is False.

Proof: We must show that q,s,ts,qs=qt.\exists\mathbf{q}, \exists\mathbf{s}, \exists \mathbf{t}\neq\mathbf{s},\mathbf{q}\cdot\mathbf{s}=\mathbf{q}\cdot\mathbf{t}. Take q=(1,1,1,1)\mathbf{q}=(1,1,1,1), s=(2,1,1,1)\mathbf{s}=(2,1,1,1), and t=(1,2,1,1)\mathbf{t}=(1,2,1,1). Then qs=2+1+1+1=qt.\mathbf{q}\cdot\mathbf{s} = 2+1+1+1=\mathbf{q}\cdot \mathbf{t}.

\square
3. q,s,D(q,s)\forall\mathbf{q},\exists\mathbf{s},D(\mathbf{q},\mathbf{s}) is True.

"It is possible to ask any question and sometimes decode the secret," is True.

Proof: Given any question q=(q1,q2,q3,q4)\mathbf{q}=(q_1,q_2,q_3,q_4), let s=(1,1,1,1),\mathbf{s}=(1,1,1,1), and suppose indirectly that there is some t=(t1,t2,t3,t4)s\mathbf{t}=(t_1,t_2,t_3,t_4)\neq\mathbf{s} for which q1+q2+q3+q4=qs=qt=q1t1+q2t2+q3t3+q4t4.q_1+q_2+q_3+q_4=\mathbf{q}\cdot\mathbf{s}=\mathbf{q}\cdot\mathbf{t}=q_1t_1+q_2t_2+q_3t_3+q_4t_4. If any ti>1t_i>1, then qt>qs\mathbf{q}\cdot\mathbf{t}>\mathbf{q}\cdot\mathbf{s}, so t1=t2=t3=t4=1t_1=t_2=t_3=t_4=1, contradicting that st\mathbf{s}\neq\mathbf{t}.

\square
4. s,q,D(q,s)\exists\mathbf{s},\forall\mathbf{q},D(\mathbf{q},\mathbf{s}) is True.

"There is some secret that can be decoded by any question," is True.

Proof: Let s=(1,1,1,1),\mathbf{s}=(1,1,1,1), and similarly to (3), for all q=(q1,q2,q3,q4)\mathbf{q}=(q_1,q_2,q_3,q_4), there is no ts\mathbf{t}\neq\mathbf{s} for which q1+q2+q3+q4=qs=qt=t1q1+t2q2+t3q3+t4q4.q_1+q_2+q_3+q_4=\mathbf{q}\cdot\mathbf{s}=\mathbf{q}\cdot\mathbf{t}=t_1q_1+t_2q_2+t_3q_3+t_4q_4.

\square
5. q,s,D(q,s)\exists\mathbf{q},\forall\mathbf{s},D(\mathbf{q},\mathbf{s}) is False.

"There is some fixed question that can decode any secret," is False.

Proof: We must show that q,s,ts,qs=qt.\forall\mathbf{q}, \exists\mathbf{s}, \exists \mathbf{t}\neq\mathbf{s},\mathbf{q}\cdot\mathbf{s}=\mathbf{q}\cdot\mathbf{t}.

Well, given any q=(q1,q2,q3,q4)\mathbf{q} = (q_1,q_2,q_3,q_4), let s=(1+q2,1,1,1)\mathbf{s}=(1+q_2,1,1,1) and t=(1,1+q1,1,1)\mathbf{t}=(1,1+q_1,1,1). Then qs=q1(1+q2)+q2+q3+q4=q1+q2(1+q1)+q3+q4=qt.\mathbf{q}\cdot\mathbf{s} = q_1(1+q_2)+q_2+q_3+q_4 = q_1+q_2(1+q_1)+q_3+q_4=\mathbf{q}\cdot\mathbf{t}.

\square
6. s,q,D(q,s)\forall\mathbf{s},\exists\mathbf{q},D(\mathbf{q},\mathbf{s})

``For any secret, we can pick a question to decode it''

Proof: Let s=(s1,s2,s3,s4)\mathbf{s}=(s_1,s_2,s_3,s_4). Pick a1,a2,a3,a4Na_1,a_2,a_3,a_4\in\N, pairwise relatively prime, and ai>sja_i>s_j. Let q1=a2a3a4q_1=a_2a_3a_4 q2=a1a3a4q_2=a_1a_3a_4 q3=a1a2a4q_3=a_1a_2a_4 q4=a1a2a3.q_4=a_1a_2a_3. Then assume indirectly that there is some tN4\mathbf{t}\in\N^4 for which 0=q1(s1t1)+q2(s2t2)+q3(s3t3)+q4(s4t4).0=q_1(s_1-t_1)+q_2(s_2-t_2)+q_3(s_3-t_3)+q_4(s_4-t_4). Since a1a_1 divides the last three terms, a1a_1 must divide q1(s1t1)q_1(s_1-t_1). Since a1a_1 does not divide a1a_1, divides s1t1s_1-t_1. Since s1s_1 and t1t_1 are positive integers, s1t1<s1s_1-t_1< s_1; since a1>s1a_1>s_1 and a1s1t1a_1|s_1-t_1, we must have that t1s1t_1\geq s_1. Similarly, t2s2t_2\geq s_2, t3s3t_3\geq s_3, and t4s4t_4\geq s_4. Then we have that q1(s1t1)+q2(s2t2)+q3(s3t3)+q4(s4t4)<0,q_1(s_1-t_1)+q_2(s_2-t_2)+q_3(s_3-t_3)+q_4(s_4-t_4)<0, a contradiction.

\square