[15.02.05] 타일 채우기 4

20
타타 타타타 4 130 45 타타타

Upload: kenny-park

Post on 25-Jul-2015

96 views

Category:

Education


2 download

TRANSCRIPT

Page 1: [15.02.05] 타일 채우기 4

타일

채우

기 4

13

04

5 박

현민

Page 2: [15.02.05] 타일 채우기 4

INTR

ODUCTION

CH

AP

TE

R 1

Page 3: [15.02.05] 타일 채우기 4

[949] 타일 채우기 4

Page 4: [15.02.05] 타일 채우기 4

[342D] Xenia and Dominoes

Page 5: [15.02.05] 타일 채우기 4

IDEA

CH

AP

TE

R 2

Page 6: [15.02.05] 타일 채우기 4

Codeforces Round #199 (Div. 2) Editorial

In the problem you can count number of correct puzzles or substract number of incorrect puzzles from number of all puzzles. In any case you should count DP, where the state is (j, mask) — j — number of the last full column, mask — mask of the last column. This problem is equivalent to the well known problem about domino tiling or the problem about parquet.

To get the solution of the whole problem I did the following. I try to at-tach one domino to each of 4 directions, then paint all three cells in black and count the number of correct puzzles. But in this case you will count some solutions several number of times. So you need to use inclusion exclusion formula for these 4 directions.

Page 7: [15.02.05] 타일 채우기 4

O 가 최대 1 개이므로 간단한 포함배제를 사용한다

( 움직이는 것을 고려하지 않은 전체 경우의 수 )

-

( 움직일 수 있는 타일이 하나도 없는 경우의 수 )

Page 8: [15.02.05] 타일 채우기 4

REALIZAT

ION

CH

AP

TE

R 3

Page 9: [15.02.05] 타일 채우기 4

BIT DYNAMICAL BACKTRACKING

고급 교재 199~214 쪽 참고

Page 10: [15.02.05] 타일 채우기 4

BIT INDEX

1

2

4

Page 11: [15.02.05] 타일 채우기 4

CASE 0

- -

- -

- -

- -

|

|

|

|

- -

Page 12: [15.02.05] 타일 채우기 4

CASE 1

X

- -

- -

X

|

|

Page 13: [15.02.05] 타일 채우기 4

CASE 2

- -

X

- -

Page 14: [15.02.05] 타일 채우기 4

CASE 3

X

X

- -

Page 15: [15.02.05] 타일 채우기 4

CASE 4

- -

- -

X

|

|

X

Page 16: [15.02.05] 타일 채우기 4

CASE 5

X

- -

X

Page 17: [15.02.05] 타일 채우기 4

CASE 6

- -

X

X

Page 18: [15.02.05] 타일 채우기 4

CASE 7

X

X

X

Page 19: [15.02.05] 타일 채우기 4

그림을 추가하려면 아이콘을 클릭하십시오

감사

합니

Page 20: [15.02.05] 타일 채우기 4

이 프

리젠

테이

션은

http://

slides

hare.

net/5

25hm/1

50205-4

에서

다시

보실

수 있

습니