Sereja and Sets
题意翻译
### 题目描述
对于一个有 $m$ 条线段的集合 $S$ 来说,定义函数 $f(S)$ 为你最多可以从这个集合中选择多少线段使得他们都不相交。端点重合也算相交。线段的右端点都小于等于 $n$。
对于给定的 $n,k$,求出有多少个满足条件的 $S$ 满足 $f(S)=k$。
### 输入格式
输入仅一行,$n,k$。$(1\le n\le 500,\ \ 0\le k\le 500)$。
### 输出格式
输出一行一个正整数,表示答案。对 $10^9+7$ 取模。
题目描述
Let's assume that set $ S $ consists of $ m $ distinct intervals $ [l_{1},r_{1}] $ , $ [l_{2},r_{2}] $ , $ ... $ , $ [l_{m},r_{m}] $ ( $ 1<=l_{i}<=r_{i}<=n $ ; $ l_{i},r_{i} $ are integers).
Let's assume that $ f(S) $ is the maximum number of intervals that you can choose from the set $ S $ , such that every two of them do not intersect. We assume that two intervals, $ [l_{1},r_{1}] $ and $ [l_{2},r_{2}] $ , intersect if there is an integer $ x $ , which meets two inequalities: $ l_{1}<=x<=r_{1} $ and $ l_{2}<=x<=r_{2} $ .
Sereja wonders, how many sets $ S $ are there, such that $ f(S)=k $ ? Count this number modulo $ 1000000007 $ $ (10^{9}+7) $ .
输入输出格式
输入格式
The first line contains integers $ n $ , $ k $ $ (1<=n<=500; 0<=k<=500) $ .
输出格式
In a single line, print the answer to the problem modulo $ 1000000007 $ $ (10^{9}+7) $ .
输入输出样例
输入样例 #1
3 1
输出样例 #1
23
输入样例 #2
3 2
输出样例 #2
32
输入样例 #3
2 0
输出样例 #3
1
输入样例 #4
2 2
输出样例 #4
2