text stringlengths 2 132k | source dict |
|---|---|
from \( 1 \) to \( n + 1 - \left\lceil \frac{n+2}{3} \right\rceil \), each odd number up to the upper bound appears twice, and each even number up to the upper bound appears once. To show that this is indeed the minimum, note that each odd number can appear at most twice (once as an \( a_i \) and once as \( 2i-1 \)), a... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
contradiction, so \(p \neq 3\). #### Subcase 1.2: \((p, p+3) = 1\) This implies \(p = 2^t - 3\). For both sides to match in terms of powers of 2, we analyze the \(v_2\) valuation: \[ v_2(2^a p^b) = a + b v_2(p). \] If \(a\) is even, there is no solution to \(x^2 = m^n + 1\) for positive integers \(x, m, n\) with \(m\) ... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\((n^2 - n + 1)^2\), we need to analyze the given condition and derive the solutions. First, let's denote \(d = mn - 1\). We need \(d\) to divide \((n^2 - n + 1)^2\). This implies: \[ d \mid (n^2 - n + 1)^2. \] We start by considering the trivial solution \((m, n) = (2, 2)\): \[ 2 \cdot 2 - 1 = 3 \quad \text{and} \quad... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\quad \forall \ i \in \mathbb{N}^*, \quad b_0 = 2, \quad b_1 = 5, \] we get the sequence: \[ (b_i)_{i=0}^{\infty} = 2, 5, 10, 17, \ldots, \] which can be generalized as: \[ b_i = (i + 1)^2 + 1. \] Thus, the pairs \((m, n)\) that satisfy the condition are: \[ (m, n) = (2, 2) \quad \text{and} \quad (m, n) = ((i+1)^2 + 1,... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\) as "good" if \( \frac{a_t}{t} > \frac{a_s}{s} \) for all \( s ((r-1)t)^{4040} > (rt)^{2020} > a_{t-2020} a_{t-2019} \cdots a_{t-1} \). Since \( \text{lcm}(T) \nmid a_{t-2020} a_{t-2019} \cdots a_{t-1} \), there exists an element in \( T \) smaller than \( a_t \) that does not divide \( a_{t-2020} a_{t-2019} \cdots ... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
must appear in the sequence. The answer is: \boxed{\text{Every sufficiently large number appears in the sequence}}. | \text{Every sufficiently large number appears in the sequence} | china_team_selection_test | | [ "Mathematics -> Number Theory -> Congruences", "Mathematics -> Applied Mathematics -> Statistics -> Proba... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
On the other hand, if \(b = 0\), then the sum evaluates to \(p\). Hence: \[ p^2 N = p^{100} + \sum_{\substack{1 \leq a \leq p-1 \\ 0 \leq b \leq p-1}} \left( \sum_{x=0}^{p-1} \omega^{ax^2 + bx} \right)^{100}. \] To relate the inner sums to Gauss sums, we complete the square: \[ p^2 N = \sum_{b=0}^{p-1} \sum_{a=1}^{p-1}... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\) be an integer. We need to find all functions \( W : \{1, \dots, n\}^2 \to \mathbb{R} \) such that for every partition \([n] = A \cup B \cup C\) into disjoint sets, the following condition holds: \[ \sum_{a \in A} \sum_{b \in B} \sum_{c \in C} W(a,b) W(b,c) = |A| |B| |C|. \] To solve this, we denote the function \( W... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
a, b, c \). This implies that \( f(x,b) \) and \( f(b,x) \) are constants for each \( b \) and all \( x \neq b \). Consequently, \( f(x,y) \) is a constant \( k \) if \( x \neq y \). From the condition \( 2k^2 = 2 \), we find \( k = 1 \) or \( k = -1 \). Therefore, all solutions are of the form where \( W(a,a) \) can b... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\) is injective at 0. **Proof**: Suppose \( f(a) = 0 \) for some \( a \neq 0 \). Then from \( P(x, a) \): \[ af(x) = f(a^3) \implies f \text{ is constant, contradiction!} \quad \blacksquare \] **Claim 3**: \( f(1) = 1 \). **Proof**: From Claim 1, putting \( y = 1 \) gives \( f(1) = 0 \), \( -1 \), or \( 1 \). \( 0 \) c... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\) along with Claim 5 implies: \[ f(y + z) = f(y) + f(z) \quad \forall y, z \implies f \text{ is additive}. \] Using the additivity in \( P(x, y) \), we get: \[ f(xf(y)) + f(y^3) = yf(x) + f(y)^3 \implies f(xf(y)) = yf(x), \] by Claim 1. Replacing \( y \) by \( f(y) \) in the above and using Claim 5, we get: \[ f(xy) =... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
= 10 \)**: All 10 birds are on the same circle. This trivially satisfies the condition. - **Case \( n = 9 \)**: Suppose 9 birds are on one circle and 1 bird is outside. For any 5 birds chosen, at least 4 must be on the circle. This condition is satisfied because any set of 5 birds will include at least 4 from the circl... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
at least three elements each, where the elements in \( A \) form an arithmetic progression and the elements in \( G \) form a geometric progression. We will analyze two main cases: ### Case 1: \( 1 \in A \) Suppose \( A = \{1, 1+k, 1+2k, \ldots, 1+mk\} \) for some integer \( k \). #### Subcase 1a: \( n \in A \) If \( n... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
greater than 1. Then \( A \) must contain \( t \) and other elements forming an arithmetic progression. However, this leads to contradictions regarding the divisibility and properties of the elements in \( A \) and \( G \). #### Subcase 2b: \( n \in A \) If \( n \in A \), then for some \( k \), \( n - k \in A \). This ... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
z^6(xyz - z). \] This simplifies to: \[ x^6(xyz) + y^6(xyz) + z^6(xyz) - (x^7 + y^7 + z^7). \] Factoring out \( xyz \) from the first part, we get: \[ (x^6 + y^6 + z^6)xyz - (x^7 + y^7 + z^7). \] Using the given \( xyz = x + y + z \), we can rewrite it as: \[ (x^6 + y^6 + z^6)(x + y + z) - (x^7 + y^7 + z^7). \] Expandi... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
1 \), the following inequality holds: \[ \left| \sum_{a \in A} x^a - \sum_{b \in B} x^b \right| 2011^{4022} \prod_{k=1}^{2011} \binom{N}{k}. \] By the pigeonhole principle, there exist sets \( A \) and \( B \) satisfying the required conditions. Hence, such sets \( A | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\) and \( B \) do exist. The answer is: \boxed{\text{Yes}}. | \text{Yes} | usa_team_selection_test | | [ "Mathematics -> Algebra -> Intermediate Algebra -> Exponential Functions", "Mathematics -> Algebra -> Intermediate Algebra -> Other" ] | 7 | Determine whether $\sqrt{1001^2+1}+\sqrt{1002^2+1}+ \cdots + \sqrt{2000^2+... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
f(b)}{a \minus{} b}\right|\] for all triples $ (f, a, b)$ such that --$ f$ is a polynomial of degree $ n$ taking integers to integers, and --$ a, b$ are integers with $ f(a) \neq f(b)$. Find $ c(n)$. [i]Shaunak Kishore.[/i] | For each positive integer \( n \), let \( c(n) \) be the largest real number such that \[ c(n)... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\( T \cdot L_n \in \mathbb{Z} \). If \( T \neq 0 \), then \( T \ge \frac{1}{L_n} \), establishing a lower bound on \( c(n) \). To show that this lower bound is attainable, consider a suitable choice of \( c_i \) such that: \[ \frac{f(N!) - f(0)}{N!} = \frac{1}{L_n} \] for large \( N \). Note that: \[ \frac{\binom{N!}{k... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
( n+4 \right )=p\left ( n+2 \right )+p\left ( n+3 \right )$. | We need to determine all positive integers \( n \) such that \[ p(n) + p(n+4) = p(n+2) + p(n+3), \] where \( p(n) \) denotes the partition function, which counts the number of ways \( n \) can be partitioned into positive integers. To solve this, we conside... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
\boxed{1, 3, 5}. | 1, 3, 5 | china_team_selection_test | | [ "Mathematics -> Discrete Mathematics -> Combinatorics", "Mathematics -> Algebra -> Prealgebra -> Integers" ] | 6 | Given is an $n\times n$ board, with an integer written in each grid. For each move, I can choose any grid, and add $1$ to all $2n-1$ numbers in ... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
0 & \cdots & 0 \\ \vdots & \vdots & \vdots & \ddots & \vdots \\ 0 & 0 & 0 & \cdots & 0 \end{pmatrix} \] then we have \((r_1, \ldots, r_n, c_1, \ldots, c_n) = (0, \ldots, 0, 0, 1, \ldots, 1)\). After one operation, this vector becomes \((1, \ldots, 1, 1, 0, \ldots, 0)\), and \((0, \ldots, 0, 0, 1, \ldots, 1)\) after ano... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
we are done. Otherwise, apply an operation to the top left corner, and we are done. The answer is: \(\boxed{\begin{cases} n^2 - n + 1 & \text{if } n \text{ is odd}, \\ n^2 & \text{if } n \text{ is even}. \end{cases}}\). | \begin{cases} n^2 - n + 1 & \text{if } n \text{ is odd}, \\ n^2 & \text{if } n \text{ is even}. \e... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
number of cards, the value of \( S \) is: \[ S = \sum_{i=1}^{51} 51i + \sum_{i=1}^{50} 51i. \] The change in \( S \), denoted as \( \Delta S \), is: \[ \Delta S = 42925. \] Since each transfer changes the value of \( S \) by at most 1 (either increasing or decreasing it by 1), it follows that at least 42925 steps are r... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
helpful, welcome to cite our paper. ``` @misc{gao2024omnimathuniversalolympiadlevel, title={Omni-MATH: A Universal Olympiad Level Mathematic Benchmark For Large Language Models}, author={Bofei Gao and Feifan Song and Zhe Yang and Zefan Cai and Yibo Miao and Qingxiu Dong and Lei Li and Chenghao Ma and Liang Chen and Run... | {
"page_id": null,
"source": 6821,
"title": "from dpo"
} |
Title: A treatise on functional divisibility; the power of primes! URL Source: Markdown Content: Well, this has been a little while coming... FEs have quietly risen in popularity, and FDs (functional divisibilities) rightly along with it. Although FEs from !Image 1: $\mathbb{R}$: p^2+f(p) \mid pf(p)+p =>p^2+f(p) \mid ... | {
"page_id": null,
"source": 6823,
"title": "from dpo"
} |
of standard !Image 12: $(1,n),(m,1)$: m^2+f(1) \mid mf(m)+1$]( (which also implies !Image 14: $m(f(m)-m) \geq f(1)-1$: 1+f(n) \mid f(1)+n$]( (which also implies !Image 16: $f(1)-1 \geq f(n)-n$$]( now gives us: !Image 18: $P(1,p): 1+kp \mid f(1)+p=>1+kp \mid kf(1)+kp$-1$]( Here we first glimpse of the true power of play... | {
"page_id": null,
"source": 6823,
"title": "from dpo"
} |
but time to move on (to USAMO 2012 P4!): Remember how forcing something to be zero by using the infinite-ness of primes played out for us last time- this problem has a very similar feel to it, no? It doesn't turn out to be based on primes basically at all, but it hammers the second turning point for our N1 home: Let's ... | {
"page_id": null,
"source": 6823,
"title": "from dpo"
} |
be infinitely many, and arbitrarily large !Image 61: $n$=n$]( Now say that !Image 63: $f(m_0)=m_0$: m_0-n \mid m_0-f(n)=>m_0-n \mid f(n)-n$]( and !Image 66: $m_0$=n$]( for all !Image 68: $n$ \leq p-2$]( and substituted !Image 73: $p=5$$]( Another one, and the one which hammered home the importance of making something a... | {
"page_id": null,
"source": 6823,
"title": "from dpo"
} |
Well, we've got nothing much else to do, and it pretty much seems like !Image 84: $f(x)=x^2$-m+1 \mid m^2-m+1$]( (and I promise it gets easier as you go through the cases) Case 1: !Image 86: $2f(p)-p^2=1 =>f(p)=\frac{p^2+1}{2}$-p^2 =-1 => f(p)=\frac{p^2-1}2$]( Thus !Image 89: $\frac{p^2-1}2 -p+1 \mid p^2-p+1 =>p^2-2p+1... | {
"page_id": null,
"source": 6823,
"title": "from dpo"
} |
arbitrarily large while !Image 116: $m^2-f(m)$-m^2$]( must equal !Image 118: $0$=m^2$]( Thus the only solution is !Image 120: $f(m)=m^2$ using POP. And yes, I know this was long. Edit: Thanks to ShaftDraftKiller for informing me of ISL 2004 N3, which is almost a perfect example of both our points of POP, and is rather ... | {
"page_id": null,
"source": 6823,
"title": "from dpo"
} |
Title: 15 Regular expressions – R for Data Science (2e) URL Source: Markdown Content: Introduction ------------ In Chapter 14. Next, we’ll talk about some of the other types of patterns that stringr functions can work with and the various “flags” that allow you to tweak the operation of regular expressions. We’ll fini... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
and, where possible, highlighting the match in blue. The simplest patterns consist of letters and numbers which match those characters exactly: ``` str_view(fruit, "berry") #> │ bil #> │ black #> │ blue #> │ boysen #> │ cloud #> │ cran #> ... and 8 more ``` Letters and numbers match exactly and are called **liter... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
and let you match a set of characters, e.g., `[abcd]` matches “a”, “b”, “c”, or “d”. You can also invert the match by starting with `^`: `[^abcd]` matches anything **except** “a”, “b”, “c”, or “d”. We can use this idea to find the words containing an “x” surrounded by vowels, or a “y” surrounded by consonants: ``` str_... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
vector and `FALSE` otherwise: ``` str_detect(c("a", "b", "c"), "[aeiou]") #> TRUE FALSE FALSE ``` Since `str_detect()` returns a logical vector of the same length as the initial vector, it pairs well with `filter()`. For example, this code finds all the most popular names containing a lower-case “x”: ``` babynames |> ... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
matches never overlap. For example, in `"abababa"`, how many times will the pattern `"aba"` match? Regular expressions say two, not three: It’s natural to use `str_count()` with `mutate()`. The following example uses `str_count()` with character classes to count the number of vowels and consonants in each name. ``` bab... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
tibble: 97,310 × 4 #> name n vowels consonants #> #> 1 aaban 10 3 2 #> 2 aabha 5 3 2 #> 3 aabid 2 3 2 #> 4 aabir 1 3 2 #> 5 aabriella 5 5 4 #> 6 aada 1 3 1 #> # ℹ 97,304 more rows ``` ### Replace values As well as detecting and counting matches, we can also modify them with `str_replace()` and `str_replace_all()`. `str... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
**character classes** and their shortcuts which allow you to match any character from a set. Next, you’ll learn the final details of **quantifiers** which control how many times a pattern can match. Then, we have to cover the important (but complex) topic of **operator precedence** and parentheses. And we’ll finish off... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
which also needs to escape `\`. That means to match a literal `\` you need to write `"\\\\"` — you need four backslashes to match one! Alternatively, you might find it easier to use the raw strings you learned about in Section 14.2.2`, there’s an alternative to using a backslash escape: you can use a character class: `... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
avoid matching `summarize`, `summary`, `rowsum` and so on: ``` x │ mary(x) #> │ marize(df) #> │ row(x) #> │ (x) str_view(x, "\\bsum\\b") #> │ (x) ``` When used alone, anchors will produce a zero-width match: ``` str_view("abc", c("$", "^", "\\b")) #> │ abc<> #> │ <>abc #> │ <>abc<> ``` This helps you understan... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
newline); `\S` matches anything that isn’t whitespace. * `\w` matches any “word” character, i.e.letters and numbers; `\W` matches any “non-word” character. The following code demonstrates the six shortcuts with a selection of letters, numbers, and punctuation characters. ``` x │ abcd ABCD -!@#%. str_view(x, "\\D+") ... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
`*` before `+`. Similarly, regular expressions have their own precedence rules: quantifiers have high precedence and alternation has low precedence which means that `ab+` is equivalent to `a(b+)`, and `^a|b$` is equivalent to `(^a)|(b$)`. Just like with algebra, you can use parentheses to override the usual order. But ... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
bowls. #> │ The of juice lemons makes fine punch. #> ... and 714 more ``` If you want to extract the matches for each group you can use `str_match()`. But `str_match()` returns a matrix, so it’s not particularly easy to work with8 (\\w+)") |> head() #> [,1] [,2] [,3] #> [1,] "the smooth planks" "smooth" "planks" #> [2... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
3. End with “x”. 4. Are exactly three letters long. (Don’t cheat by using `str_length()`!) 5. Have seven letters or more. 6. Contain a vowel-consonant pair. 7. Contain at least two vowel-consonant pairs in a row. 8. Only consist of repeated vowel-consonant pairs. 4. Create 11 regular expressions that match the British ... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
be useful: * `dotall = TRUE` lets `.` match everything, including `\n`: ``` x │ Line 1 │ Line> 2 │ Line> 3 ``` * `multiline = TRUE` makes `^` and `$` match the start and end of each line rather than the start and end of the complete string: ``` x │ 1 #> │ Line 2 #> │ Line 3 str_view(x, regex("^Line", multiline = TR... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
Section 14.6) #> │ i ı I str_view("i İ ı I", coll("İ", ignore_case = TRUE, locale = "tr")) #> │ ı I ``` Practice -------- To put these ideas into practice we’ll solve a few semi-authentic problems next. We’ll discuss three general techniques: 1. checking your work by creating simple positive and negative controls 2... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
's easy to tell the depth of a well. #> │ lp the woman get back to her feet. #> │ r purse was full of useless trash. #> │ snowed, rained, and hailed the same morning. #> │ ran half way to the hardware store. #> │ lay prone and hardly moved a limb. #> ... and 57 more ``` A quick inspection of the results shows that... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
### Boolean operations Imagine we want to find words that only contain consonants. One technique is to create a character class that contains all letters except for the vowels (`[^aeiou]`), then allow that to match any number of letters (`[^aeiou]+`), then force it to match the whole string by anchoring to the beginnin... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
we wanted to see if there was a word that contains all vowels? If we did it with patterns we’d need to generate 5! (120) different patterns: It’s much simpler to combine five calls to `str_detect()`: In general, if you get stuck trying to create a single regexp that solves your problem, take a step back and think if yo... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
lets first eliminate the numbered variants: ``` cols │ white #> │ aliceblue #> │ antiquewhite #> │ aquamarine #> │ azure #> │ beige #> ... and 137 more ``` Then we can turn this into one giant pattern. We won’t show the pattern here because it’s huge, but you can see it working: ``` pattern │ Glue the sheet to... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
finds any base R dataset. You can get a list of these datasets via a special use of the `data()` function: `data(package = "datasets")$results[, "Item"]`. Note that a number of old datasets are individual vectors; these contain the name of the grouping “data frame” in parentheses, so you’ll need to strip those off. Reg... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
base R is very slightly different to that used by stringr. That’s because stringr is built on top of the stringi package` syntax. Summary ------- With every punctuation character potentially overloaded with meaning, regular expressions are one of the most compact languages out there. They’re definitely confusing at fir... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
easy to pick up because it follows many of the the same conventions as stringr. In the next chapter, we’ll talk about a data structure closely related to strings: factors. Factors are used to represent categorical data in R, i.e.data with a fixed and known set of possible values identified by a vector of strings. * * *... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
Title: URL Source: Markdown Content: CS 341: Foundations of Computer Science II Prof. Marvin Nakayama # Homework 3 Solutions 1. Give NFAs with the specified number of states recognizing each of the following lan-guages. In all cases, the alphabet is Σ = {0, 1}.(a) The language { w ∈ Σ∗ | w ends with 00 } with three st... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
NFAs closed under complement? Explain your answer. Answer: The class of languages recognized by NFAs is closed under complement, which we 2can prove as follows. Suppose that C is a language recognized by some NFA M ,i.e., C = L(M ). Since every NFA has an equivalent DFA (Theorem 1.39), there is a DFA D such that L(D) =... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
as the power set P(Q), i.e., the set of all subsets of Q, so Q′ = { ∅ , {1}, {2}, {3}, {1, 2}, {1, 3}, {2, 3}, {1, 2, 3} } ; i.e., each state of the equivalent DFA M is a subset of states of the NFA N .3Recall that state 1 is the start state of the NFA N , so the start state of the equivalent DFA M is then E({1}) = {1,... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
from 1 to 2 without reading any symbols by taking the ε-transition. Thus, we first create a DFA state corresponding to the set {1, 2}: {1, 2} The state {1, 2} is the start state of the DFA since this is where the NFA can be without reading any symbols. The state {1, 2} is also an accepting state for the DFA since it co... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
> {1,2} > ∅ > {1,2,3}a > b Now every time we add a new DFA state, we have to determine all the possibilities of where the NFA can go on an a from each NFA state within that DFA state, and where the NFA can go on a b from each NFA state within that DFA state. For DFA state {1, 2, 3}, we next determine where the NFA can ... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
from state {1, 2, 3} to a new state {2, 3}, which is accepting since it contains 2 ∈ F : > {1,2} > {2,3} > ∅ > {1,2,3}a > b > b > a Now do the same for DFA states {2, 3} and ∅. If any new DFA states arise, then we need to determine the a and b transitions out of those states as well. We stop once every DFA state has an... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
two a’s, or exactly two b’s }. Answer: b∗ab ∗a(a ∪ b)∗ ∪ a∗ba ∗ba ∗ (d) The language { w ∈ Σ∗ | w ends in a double letter }. (A string contains a double letter if it contains aa or bb as a substring.) Answer: (a ∪ b)∗(aa ∪ bb ) (e) The language { w ∈ Σ∗ | w does not end in a double letter }. Answer: ε ∪ a ∪ b ∪ (a ∪ b)... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
Answer: To simplify the regular expression, we define Σ1 = {a, b, . . . , z, A, B, . . . , Z} Σ2 = {0, 1, 2, . . . , 9}. Then a regular expression for L0 is Σ1 (Σ 1 ∪ Σ2 ∪ ε) · · · (Σ 1 ∪ Σ2 ∪ ε) # ︸ ︷︷ ︸ 7 times . Note that by including the ε in each of the last parts, we can generate strings that have length strictly... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
out of each state, there is exactly one edge leaving the state for any symbol from Σ, as required for a DFA. 86. Define L to be the set of strings that represent numbers in a modified version of Java. The goal in this problem is to define a regular expression and an NFA for L. To precisely define L, let the set of digi... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
of digits in a string in L. Also, we do not allow for the suffixes L, l, F, f, D, d, at the end of numbers to denote types (long integers, floats, and doubles). Define Σ as the alphabet of all printable characters on a computer keyboard (no control characters), except for parentheses to avoid confusion. (a) Give a regu... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
> Σ1 > Σ1 (c) Give a regular expression for L3. Also, give an NFA for L3 over the alphabet Σ. Answer: A regular expression for L3 is R3 = ( R1 ∪ R2) ( E ∪ e) R1 where R1 and R2 are defined in the previous parts. An NFA for L3 is 10 s1 s2 s3 s4 s5 s6 s7 s8 +, -, ε Σ1 • Σ1 • Σ1 Σ1 Σ1 E, e +, -, ε Σ1 Σ1 (d) Give a regular... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
Title: Just a moment... URL Source: Warning: Target URL returned error 403: Forbidden Warning: This page maybe requiring CAPTCHA, please make sure you are authorized to access this page. Markdown Content: mathematica.stackexchange.com ----------------------------- Verify you are human by completing the action below. m... | {
"page_id": null,
"source": 6825,
"title": "from dpo"
} |
Title: URL Source: Warning: Target URL returned error 403: Forbidden Markdown Content: You've been blocked by network security. To continue, log in to your Reddit account or use your developer token If you think you've been blocked by mistake, file a ticket below and we'll look into it. [Log in]( a ticket]( | {
"page_id": null,
"source": 6827,
"title": "from dpo"
} |
Title: I cannot understand how Irrational Numbers exist, please help me. : r/askmath URL Source: Markdown Content: I cannot understand how Irrational Numbers exist, please help me. : r/askmath =============== Skip to main content right triangle a vivid physical representation of sqrt(2)? Don't get hung up on the | {
"page_id": null,
"source": 6827,
"title": "from dpo"
} |
digits, they are not important, they are just a side property Reply reply } Share Share [ number is just a side of a square, but sometimes they match with our day-life numbers. I don't think this is a good explanation, but hope this helps. Reply reply } Share Share New to Reddit? Create your account and connect with a world of communities. Continue with ... | {
"page_id": null,
"source": 6827,
"title": "from dpo"
} |
to focused questions and discussion concerning mathematics. * * * 177K Members Online ### How to prove that √2 ** √2 is irrational number? do irrational numbers happen because of the 10 character system?]( days ago r/mathematics do irrational numbers happen because of the 10 character system?]( 28 upvotes ·48 comments ... | {
"page_id": null,
"source": 6827,
"title": "from dpo"
} |
* * * Promoted !Image 25: sidebar promoted post thumbnail. * * * 386K Members Online [### Don't understand why 0.3033033303333 is an irrational number?]( 5 upvotes ·25 comments * * * * [I don't understand math as a concept.]( 28: r/askmath icon]( r/askmath]( mo. ago  is irrational?]( 113 upvotes ·110 comments * * * * [Can someone explain to me how to find the answer]( 61: r/askmath icon]( r/askmath]( mo. ago  ## A4. Let n be a positive integer, and consider a sequence a1, a 2, . . . , a n of positive integers. Extend it periodically to an infinite sequence a1, a 2, . ... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
k groups (some of which may be empty) such that the sum of the numbers in each group is at most 1. (Poland) ## C2. In the plane, 2013 red points and 2014 blue points are marked so that no three of the marked points are collinear. One needs to draw k lines not passing through the marked points and dividing the plane int... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
of t1, . . . , n u. An A-partition of n into k parts is a representation of n as a sum n “ a1 ` ¨ ¨ ¨ ` ak, where the parts a1, . . . , a k belong to A and are not necessarily distinct. The number of different parts in such a partition is the number of (distinct) elements in the set ta1, a 2, . . . , a ku.We say that a... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
have distance exactly four from it. (Russia) ## C7. Let n ě 2 be an integer. Consider all circular arrangements of the numbers 0 , 1, . . . , n ; the n ` 1 rotations of an arrangement are considered to be equal. A circular arrangement is called beautiful if, for any four distinct numbers 0 ď a, b, c, d ď n with a ` c “... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
BC . Denote by M and N the feet of the altitudes from B and C, respectively. Denote by ω1 the circumcircle of BW N , and let X be the point on ω1 which is diametrically opposite to W . Analogously, denote by ω2 the circumcircle of CW M , and let Y be the point on ω2 which is diametrically opposite to W . Prove that X, ... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
. (Georgia) ## G5. Let ABCDEF be a convex hexagon with AB “ DE , BC “ EF , CD “ F A , and =A ´ =D “ =C ´ =F “ =E ´ =B. Prove that the diagonals AD, BE, and CF are concurrent. (Ukraine) ## G6. Let the excircle of the triangle ABC lying opposite to A touch its side BC at the point A1.Define the points B1 and C1 analogous... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
Ana and Banana, play the following game of numbers : Initially, some integer n ě k gets written on the blackboard. Then they take moves in turn, with Ana beginning. A player making a move erases the number m just written on the blackboard and replaces it by some number m1 with k ď m1 ă m that is coprime to m. The first... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
and let a1, . . . , a n´1 be arbitrary real numbers. Define the sequences u0, . . . , u n and v0, . . . , v n inductively by u0 “ u1 “ v0 “ v1 “ 1, and uk`1 “ uk ` akuk´1, vk`1 “ vk ` an´kvk´1 for k “ 1, . . . , n ´ 1. Prove that un “ vn. (France) Solution 1. We prove by induction on k that uk “ ÿ > 0ăi1ă... ăităk, ij`... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
“ vn. Solution 2. Define recursively a sequence of multivariate polynomials by P0 “ P1 “ 1, Pk`1px1, . . . , x kq “ Pkpx1, . . . , x k´1q ` xkPk´1px1, . . . , x k´2q, so Pn is a polynomial in n ´ 1 variables for each n ě 1. Two easy inductive arguments show that un “ Pnpa1, . . . , a n´1q, vn “ Pnpan´1, . . . , a 1q,Sh... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
we wished to show. Solution 3. Using matrix notation, we can rewrite the recurrence relation as ˆ uk`1 uk`1 ´ uk ˙ “ ˆuk ` akuk´1 akuk´1 ˙ “ ˆ1 ` ak ´ak ak ´ak ˙ ˆ uk uk ´ uk´1 ˙ for 1 ď k ď n ´ 1, and similarly pvk`1; vk ´ vk`1q “ ´ vk ` an´kvk´1; ´an´kvk´1 ¯ “ p vk; vk´1 ´ vkq ˆ1 ` an´k ´an´k an´k ´an´k ˙ for 1 ď k ď... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
ak 1 ` ak´1 1 ` . . . ` a2 1 ` a1 and vk`1 vk “ 1 ` an´k 1 ` an´k`1 1 ` . . . ` an´2 1 ` an´1 so the problem claims that the corresponding continued fractions for un{un´1 and vn{vn´1 have the same numerator. 10 IMO 2013 Colombia Comment 3. An alternative variant of the problem is the following. Let n be a positive inte... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
## A2. Prove that in any set of 2000 distinct real numbers there exist two pairs a ą b and c ą d with a ‰ c or b ‰ d, such that ˇˇˇˇ a ´ b c ´ d ´ 1 ˇˇˇˇ ă 1 100000 . (Lithuania) Solution. For any set S of n “ 2000 distinct real numbers, let D1 ď D2 ď ¨ ¨ ¨ ď Dm be the distances between them, displayed with their multi... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
5 ¸19 ě 219 “ 29 ¨ 210 ą 500 ¨ 1000 ą 2 ¨ 10 5, and so v ´ u “ Dm ą 2 ¨ 10 5.Since the distance of x to at least one of the numbers u, v is at least pu ´ vq{ 2 ą 10 5, we have |x ´ z| ą 10 5. for some z P t u, v u. Since y ´ x “ 1, we have either z ą y ą x (if z “ v) or y ą x ą z (if z “ u). If z ą y ą x, selecting a “... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
ě f pxy q, (1) f px ` yq ě f pxq ` f pyq (2) for all x, y P Qą0. Given that f paq “ a for some rational a ą 1, prove that f pxq “ x for all x P Qą0. (Bulgaria) Solution. Denote by Zą0 the set of positive integers. Plugging x “ 1, y “ a into (1) we get f p1q ě 1. Next, by an easy induction on n we get from (2) that f pn... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
1. Then by (2) and (5) we get an “ f panq ě f pxq ` f pan ´ xq ě x ` p an ´ xq “ an and therefore f pxq “ x for x ą 1. Finally, for every x P Qą0 and every n P Zą0, from (1) and (3) we get nf pxq “ f pnqf pxq ě f pnx q ě nf pxq, which gives f pnx q “ nf pxq. Therefore f pm{nq “ f pmq{ n “ m{n for all m, n P Zą0. Commen... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
cannot be congruent to i, i ` 1, . . . , n ´ 1, or n pmod nq. (4) Thus our assumption that ai ě n ` i implies the stronger statement that ai ě 2n ` 1, which by a1 ` n ě an ě ai gives a1 ě n ` 1. The minimality of i then yields i “ 1, and ( 4) becomes contradictory. This establishes our first claim. In particular we now... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
. . ` bt. Adding a1 ` . . . ` at to both sides and using that ai ` bi ď n for 1 ď i ď t, we get a1 ` a2 ` ¨ ¨ ¨ ` an ď npn ´ tq ` nt “ n2 as we wished to prove. 14 IMO 2013 Colombia Solution 2. In the first quadrant of an infinite grid, consider the increasing “staircase” obtained by shading in dark the bottom ai cells... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
in row ai, and we only shaded aai ă n ` i light cells in that row, a contradiction. Case 2. ai ě n ` 1If ai ě n ` 1, this dark and light cell is pi, n q. This is the pn ` iq-th cell in row n and we shaded an ď a1 ` n light cells in this row, so we must have i ď a1. But a1 ď aa1 ď n by (1) and (2), so i ď a1 implies ai ... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
Finally, the definitions imply that cci P t aai , a i, a i ´ n, i u so cci ď n ` i ´ 1 by ( 2) and (3). This establishes ( 1) and ( 2) for c1, c 2, . . . .Shortlisted problems – solutions 15 Our new sequence has the additional property that ci ě i for i “ 1, 2, . . . , n, (6) which allows us to construct the following ... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
with n ` i ď cj gives us that n ` i ď cci . This contradicts ( 2). This means that the number of arrows is at most `n > 2 ˘, which implies that > n ÿ > i“1 ci ď ˆn 2 ˙ ` ˆn ` 12 ˙ “ n2. Recalling that ai ď ci for 1 ď i ď n, the desired inequality follows. Comment 1. We sketch an alternative proof by induction. Begin by... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
sequences. Start with any lattice path P from the lower left to the upper right corner of the n ˆ n square S using only steps up and right, such that the total number of steps along the left and top edges of S is at least n. Shade the cells of S below P dark, and the cells of S above P light. Now reflect the light shap... | {
"page_id": null,
"source": 6828,
"title": "from dpo"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.