Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

Re:有了公式就蛮简单的了。

Posted by 8690891 at 2011-09-22 14:20:30 on Problem 2601
In Reply To:有了公式就蛮简单的了。 Posted by:19891212 at 2008-08-25 18:25:16
> 大概过程:
> a[0]+a[2]-2a[1]-2c[1]=0
> a[1]+a[3]-2a[2]-2c[2]=0
> ……
> a[n-1] + a[n+1] - 2a[n] - 2c[n] = 0
> 累加可得:
> a[0]+a[n+1]-a[1]-a[n]-2c[1]-2c[2]-...-2c[n]=0
> 根据a[n-1]+a[n+1]-2a[n]-2c[n]=0  => a[n+1]-2c[n]-a[n]=a[n]+2c[n]-a[n-1]
> 化简:a[0]+a[n]-a[1]-a[n-1]-2c[1]-2c[2]-...-2c[n-1]=0
> 同理:a[0]+a[n-1]-a[1]-a[n-2]-2c[1]-2c[2]-...-2c[n-2]=0
>       ……
>       a[0]+a[2]-a[1]-a[1]-2c[1]=0
> 相加上面各式可得n*a[0]+a[n+1]-(n+1)*a[1]-2*n*c[1]-2*(n-1)*c[2]-...-2*c[n]=0
> 即a[1]=(n*a[0]+a[n+1]-2*n*c[1]-2*(n-1)*c[2]-...-2*c[n])/(n+1)
> 可能还有优化的空间,大牛们不要笑话我哦!

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator