HomeWork20251107

HomePage | Memberswill go by tor | RecentChanges | Join |

task 1

a

because there is inverse a 1Z m *a^{-1} \in Z_m^*, so x=a 1b(modm)x=a^{-1} \cdot b (\mod{m})

b

because aa is not coprime with mm, let gg be the gcd of aa and mm, there are two integers p,qp,q such that ap+mq=g>1a p + m q =g>1. Therefore any number who is not multiple of gg is a candidate of bb as it must be k,b=ax+mk\exists k, b=a x + m k

c

Given another group generator g ig^i, the group is {g i1,g i2,,g i(m1),g im=(g m) i=1 i=1}\{g^{i \cdot 1}, g^{i \cdot 2}, \cdots, g^{i \cdot (m-1)}, g^{i \cdot m}=(g^m)^i=1^i=1\}

if ii is not coprime with mm, then there would be some smaller number a<m,g ia=1a&lt;m, g^{i a}=1 already; to have g ia=1g^{i a}=1, it means ia=mki a = m k for some kk. By 質因數分解 ii and mm, not coprime means some common prime factor for both, for example, i=3 15 2,m=2 33 4i=3^1 \cdot 5^2, m=2^3 \cdot 3^4 have 3 as common prime factor, then (3 15 2)a=(2 33 4)k(3^1 \cdot 5^2)a=(2^3 \cdot 3^4)k, a smaller aa to be 2 33 3<2 33 42^3 \cdot 3^3 &lt; 2^3 \cdot 3^4 and accordingly k=5 2k=5^2

The set of all generators is {g i|i and m coprime}\{g^i | \text{i and m coprime}\}

a side note. The order of a subgroup SS must be 1h\frac{1}{h} of the order of the group GG for some positive integer hh. To prove this, define xS{xs|sS}x S \equiv \{x \cdot s | s \in S\} who has the same size as SS, then x 1Sx_1 S and x 2Sx_2 S are two either identical or disjoint sets for any group element x 1,x 2x_1,x_2, never partial intersection, therefore GG treated as a set must be disjoint union of x 1S,x 2S,,x hSx_1 S, x_2 S, \cdots, x_h S for some x 1,x 2,,x hx_1, x_2, \cdots, x_h. Then a trivial collary is that a group of order of a prime number has no trivial subgroup and any element other than 1 is a generator. Also, the set {x j|j is an integer}\{x^j| \text{j is an integer}\} must be a subgroup for any group element xx, therefore x |G|=1x^|G|=1 for any group element xx

d

all elements except 0 (operator's 1) can be generator by c above

task 2

any cyclic group (G,)(G,\cdot) of order mm is isomorphic to (Z m,+)(Z_m,+) with translation: g k i=1 k1g^k \Leftrightarrow \sum_{i=1}^k {1}

a

{g α1,g α2,,g α(n1),g αn=g m=1}\{g^{\alpha \cdot 1}, g^{\alpha \cdot 2}, \cdots, g^{\alpha \cdot (n-1)}, g^{\alpha \cdot n}=g^m=1\}

b

let the answer be pp, then g αp=g xαg^{\alpha p}=g^{x \alpha}

so k,αp=xα+km\exists k, \alpha p =x \alpha + k m

so px=knp-x=k n

so p=x(modn)p=x (\mod{n})

c

what DDH?

m=2×3×5=30m=2 \times 3 \times 5=30

(Z m *,)(Z_m^*,\cdot) is not necessarily cyclic (so nothing to do with task 2?)

Z 30 *={1,7,11,13,17,19,23,29}Z_30^*=\{1, 7, 11, 13, 17, 19, 23, 29\}

but 7 4=11 4=13 4=17 4=19 2=23 4=29 2=17^4=11^4=13^4=17^4=19^2=23^4=29^2=1 and each element only forms a subgroup of order 2 or 4, never the whole group of order 8

(Z m,+)(Z_m,+) is cyclic group

d

as (Z m *,)(Z_m^*,\cdot) is not necessarily cyclic, a XZ m *X \in Z_m^* might not be of the form X=g xX=g^x except trivial one

however, If X,g,p 1,p 2,,p 44X,g,p_1,p_2, \cdots,p_44 are known and XX is pre-determined as X=g x(modm)X=g^x (\mod{m}) for some xx, then

Define:

X iX(modp i)X_i \equiv X (\mod{p_i})

g ig(modp i)g_i \equiv g (\mod{p_i})

By X=g x(modm)X=g^x (\mod{m})

X i=g i x(modp i)X_i=g_i^x (\mod{p_i}) and there is a ia_i such that X i=g i a iX_i=g_i^{a_i}. If NOT such a ia_i, for example g i=1g_i=1 and X i1X_i \neq 1, then the original quesntion is, as mentioned above, not well-posed and has no solution. To have a taste of such case, consider the problem of finding xZ 30 *x \in Z_30^* such that 29=7 x(mod30)29=7^x (\mod{30})

Knowing g i p i=1g_i^{p_i}=1 (this is also a condition for well-posed question that g ig_i must be a generator of (Z p i *,)(Z_{p_i}^*,\cdot), say, for (Z 7 *,)(Z_7^*,\cdot)) only 3 and 5 possible for g ig_i, there is some k ik_i such that x=a i+k ip ix=a_i+k_i p_i aka x=a i(modp i)x=a_i (\mod{p_i})

Then by the black box hint, xx is found

A side note. This is the story of 韓信點兵, 韓信 as a general in 秦末漢初 good at math used this method to count the head count of soldiers by grouping the soldiers by p ip_i and getting the a ia_i

task 3

task 4

Because cyclic, let S=g rS=g^r, given g p=1g^p=1, then the collision is

g x 1+rx 2=g x 1+rx 2g^{x_1+r x_2}=g^{x_1'+r x_2'} aka

x 1x 1=r(x 2x 2)(modp)x_1-x_1'=r (x_2-x_2') (\mod{p})

Since pp is prime, (Z p *,)(Z_p^*, \cdot) is itself a group having x 2x 2x_2-x_2' and the inverse of x 2x 2x_2-x_2' exists, therefore

r=(x 1x 1)(x 2x 2) 1(modp)r= (x_1-x_1') \cdot (x_2-x_2')^{-1} (\mod{p})

task 5

a

k,r,tZ 2 nk,r,t \in Z_2^n and s=k+rs=k+r where + in in sense of Z 2 nZ_2^n

u=s+t=k+r+tu=s+t=k+r+t

w=u+r=k+r+t+r=k+tw=u+r=k+r+t+r=k+t

w+t=k+t+t=kw+t=k+t+t=k

Alice answer kk and Bob answer w+tw+t, both the same

b

(S,U,W)=(K+R,K+R+T,K+R+T+R)(S,U,W)=(K+R,K+R+T,K+R+T+R)

R=U+WR=U+W

therefore K=S+R=S+U+WK=S+R=S+U+W

So the D can compute K=S+U+WK=S+U+W which should be the same as the 4rd argument for KK by answering true iff S+U+WS+U+W and 4rd argument the same