其他分享
首页 > 其他分享> > ARC 记录

ARC 记录

作者:互联网

ARC145F Modulo Sum of Increasing Sequences

先考虑 \(p\mid n\) 的情况,令 \(b=\frac pn\)。

典中典。

列出生成函数:

\[[x^ky^m](\prod_{i=0}^{n-1}(1+x^iy))^b\bmod(x^n-1) \]

一个关于循环卷积的结论是:(就是对多项式的每个位置单位根反演然后线性组合)

\[[x^0]f\bmod(x^n-1)=\frac{1}{n}\sum_{i=1}^nf(\omega_n^i) \]

应用可得:

\[[y^m]\frac{1}{n}\sum_{i=1}^n\omega_n^{-ik}\prod_{j=0}^{n-1}(1+\omega^{ij}_ny)^b\\ =[y^m]\sum_{d\mid n}(\prod_{i=0}^{\frac{n}{d}-1}(1+\omega^i_{\frac{n}{d}}y)^d)(\sum_{i=1}^n[\gcd(i,n)=d]\omega^{-ik}_n)\\=[y^m]\sum_{d\mid n}(1-(-y)^{\frac{n}{d}})^d(\sum_{i=1}^{\frac{n}{d}}\omega_{\frac{n}{d}}^{-ik}\sum_{p\mid\gcd(\frac{n}{d},i)}\mu(p))\\=[y^m]\sum_{d\mid n}(\sum_{i=0}^d{d\choose i}(-1)^{\frac{ni}{d}+i}y^{\frac{ni}{d}})(\sum_{p\mid\frac{n}{d}}\mu(p)\sum_{i=1}^{\frac{n}{dp}}\omega_{\frac{n}{dp}}^{-ik})\\=\sum_{d\mid n}{d\choose\frac{dm}{n}}(-1)^{m+\frac{dm}{n}}\sum_{p\mid \frac{n}{d}}\mu(p)[\frac{n}{dp}\mid k]\frac{n}{dp}\\=\sum_{d\mid n}{\frac{n}{d}\choose\frac{m}{d}}(-1)^{m+\frac{m}{d}}\sum_{p\mid d,k}\mu(\frac{d}{p})p\]

Submission

ARC142E Pairing Wizards

ARC142F Paired Wizards

ARC138E Decreasing Subsequence

ARC134E Modulo Nim

ARC134F Flipping Coins

ARC133F Random Transition

ARC132E Paw

ARC132F Takahashi The Strongest

ARC127F ±AB

ARC125E Snack

ARC125F Tree Degree Subset Sum

ARC124E Pass to Next

ARC124F Chance Meeting

ARC117E Zero-Sum Ranges 2

ARC117F Gateau

标签:frac,记录,sum,mid,mu,ARC,omega,dp
来源: https://www.cnblogs.com/xiaoziyao/p/16667226.html