https://artofproblemsolving.com/wiki/api.php?action=feedcontributions&user=TrueshotBarrage&feedformat=atom AoPS Wiki - User contributions [en] 2021-05-13T15:05:30Z User contributions MediaWiki 1.31.1 https://artofproblemsolving.com/wiki/index.php?title=User:TrueshotBarrage&diff=84000 User:TrueshotBarrage 2017-02-17T03:19:20Z <p>TrueshotBarrage: </p> <hr /> <div>Hello everyone! I don't really get on AoPS too much anymore. If you need to contact me, send me a PM or an email at s883546@stu.mps-al.org. Thanks!<br /> <br /> [[User:TrueshotBarrage|David Kim]] 10:49, 31 May 2013 (EDT), Edited! @ 10:18, 16 February 2017 (EDT)</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=User:TrueshotBarrage&diff=83999 User:TrueshotBarrage 2017-02-17T03:19:02Z <p>TrueshotBarrage: </p> <hr /> <div>Hello everyone! I don't really get on AoPS too much anymore. If you need to contact me, send me a PM or an email at s883546@stu.mps-al.org. Thanks!</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=2017_AMC_12B_Problems/Problem_16&diff=83997 2017 AMC 12B Problems/Problem 16 2017-02-17T03:15:49Z <p>TrueshotBarrage: /* Solution 2 */</p> <hr /> <div>==Problem 16==<br /> The number &lt;math&gt;21!=51,090,942,171,709,440,000&lt;/math&gt; has over &lt;math&gt;60,000&lt;/math&gt; positive integer divisors. One of them is chosen at random. What is the probability that it is odd?<br /> <br /> &lt;math&gt;\textbf{(A)}\ \frac{1}{21} \qquad \textbf{(B)}\ \frac{1}{19} \qquad \textbf{(C)}\ \frac{1}{18} \qquad \textbf{(D)}\ \frac{1}{2} \qquad \textbf{(E)}\ \frac{11}{21}&lt;/math&gt;<br /> <br /> ==Solution==<br /> If a factor of &lt;math&gt;21!&lt;/math&gt; is odd, that means it contains no factors of &lt;math&gt;2&lt;/math&gt;. We can find the number of factors of two in &lt;math&gt;21!&lt;/math&gt; by counting the number multiples of &lt;math&gt;2&lt;/math&gt;, &lt;math&gt;4&lt;/math&gt;, &lt;math&gt;8&lt;/math&gt;, and &lt;math&gt;16&lt;/math&gt; that are less than or equal to &lt;math&gt;21&lt;/math&gt;.After some quick counting we find that this number is &lt;math&gt;10+5+2+1 = 18&lt;/math&gt;. If the prime factorization of &lt;math&gt;21!&lt;/math&gt; has &lt;math&gt;18&lt;/math&gt; factors of &lt;math&gt;2&lt;/math&gt;, there are &lt;math&gt;19&lt;/math&gt; choices for each divisor for how many factors of &lt;math&gt;2&lt;/math&gt; should be included (&lt;math&gt;0&lt;/math&gt; to &lt;math&gt;18&lt;/math&gt; inclusive). The probability that a randomly chosen factor is odd is the same as if the number of factors of &lt;math&gt;2&lt;/math&gt; is &lt;math&gt;0&lt;/math&gt; which is &lt;math&gt;\boxed{\textbf{(B)}\frac{1}{19}}&lt;/math&gt;.<br /> <br /> Solution by: vedadehhc<br /> <br /> ==Solution 2==<br /> We can write &lt;math&gt;21!&lt;/math&gt; as its prime factorization:<br /> &lt;cmath&gt;21!=2^{18}\times3^9\times5^4\times7^3\times11\times13\times17&lt;/cmath&gt;<br /> <br /> Each exponent of these prime numbers are one less than the number of factors at play here. This makes sense; &lt;math&gt;2^{18}&lt;/math&gt; is going to have &lt;math&gt;19&lt;/math&gt; factors: &lt;math&gt;2^0, 2^1, 2^2,...\text{ }2^{18}&lt;/math&gt;, and the other exponents will behave identically. <br /> <br /> In other words, &lt;math&gt;21!&lt;/math&gt; has &lt;math&gt;(18+1)(9+1)(4+1)(3+1)(1+1)(1+1)(1+1)&lt;/math&gt; factors. <br /> <br /> We are looking for the probability that a randomly chosen factor of &lt;math&gt;21!&lt;/math&gt; will be odd--numbers that do not contain multiples of &lt;math&gt;2&lt;/math&gt; as factors.<br /> <br /> From our earlier observation, the only factors of &lt;math&gt;21!&lt;/math&gt; that are even are ones with at least one multiplier of &lt;math&gt;2&lt;/math&gt;, so our probability of finding an odd factor becomes the following:<br /> &lt;cmath&gt;P(\text{odd})=\dfrac{\text{number of odd factors}}{\text{number of all factors}}=\dfrac{(9+1)(4+1)(3+1)(1+1)(1+1)(1+1)}{(18+1)(9+1)(4+1)(3+1)(1+1)(1+1)(1+1)}=\dfrac{1}{(18+1)}=\boxed{\dfrac{1}{19}}&lt;/cmath&gt;<br /> <br /> Solution submitted by [[User:TrueshotBarrage|David Kim]]<br /> <br /> ==See Also==<br /> {{AMC12 box|year=2017|ab=B|num-b=15|num-a=17}}<br /> {{MAA Notice}}</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=2017_AMC_12B_Problems/Problem_16&diff=83996 2017 AMC 12B Problems/Problem 16 2017-02-17T03:13:12Z <p>TrueshotBarrage: Added another solution</p> <hr /> <div>==Problem 16==<br /> The number &lt;math&gt;21!=51,090,942,171,709,440,000&lt;/math&gt; has over &lt;math&gt;60,000&lt;/math&gt; positive integer divisors. One of them is chosen at random. What is the probability that it is odd?<br /> <br /> &lt;math&gt;\textbf{(A)}\ \frac{1}{21} \qquad \textbf{(B)}\ \frac{1}{19} \qquad \textbf{(C)}\ \frac{1}{18} \qquad \textbf{(D)}\ \frac{1}{2} \qquad \textbf{(E)}\ \frac{11}{21}&lt;/math&gt;<br /> <br /> ==Solution==<br /> If a factor of &lt;math&gt;21!&lt;/math&gt; is odd, that means it contains no factors of &lt;math&gt;2&lt;/math&gt;. We can find the number of factors of two in &lt;math&gt;21!&lt;/math&gt; by counting the number multiples of &lt;math&gt;2&lt;/math&gt;, &lt;math&gt;4&lt;/math&gt;, &lt;math&gt;8&lt;/math&gt;, and &lt;math&gt;16&lt;/math&gt; that are less than or equal to &lt;math&gt;21&lt;/math&gt;.After some quick counting we find that this number is &lt;math&gt;10+5+2+1 = 18&lt;/math&gt;. If the prime factorization of &lt;math&gt;21!&lt;/math&gt; has &lt;math&gt;18&lt;/math&gt; factors of &lt;math&gt;2&lt;/math&gt;, there are &lt;math&gt;19&lt;/math&gt; choices for each divisor for how many factors of &lt;math&gt;2&lt;/math&gt; should be included (&lt;math&gt;0&lt;/math&gt; to &lt;math&gt;18&lt;/math&gt; inclusive). The probability that a randomly chosen factor is odd is the same as if the number of factors of &lt;math&gt;2&lt;/math&gt; is &lt;math&gt;0&lt;/math&gt; which is &lt;math&gt;\boxed{\textbf{(B)}\frac{1}{19}}&lt;/math&gt;.<br /> <br /> Solution by: vedadehhc<br /> <br /> ==Solution 2==<br /> We can write &lt;math&gt;21!&lt;/math&gt; as its prime factorization:<br /> &lt;cmath&gt;21!=2^{18}\times3^9\times5^4\times7^3\times11\times13\times17&lt;/cmath&gt;<br /> <br /> Each exponent of these prime numbers are one less than the number of factors at play here. This makes sense; &lt;math&gt;2^{18}&lt;/math&gt; is going to have &lt;math&gt;19&lt;/math&gt; factors: &lt;math&gt;2^0, 2^1, 2^2,...\text{ }2^{18}&lt;/math&gt;, and the other exponents will behave identically. <br /> <br /> In other words, &lt;math&gt;21!&lt;/math&gt; has &lt;math&gt;(18+1)(9+1)(4+1)(3+1)(1+1)(1+1)(1+1)&lt;/math&gt; factors. <br /> <br /> We are looking for the probability that a randomly chosen factor of &lt;math&gt;21!&lt;/math&gt; will be odd--numbers that do not contain multiples of &lt;math&gt;2&lt;/math&gt; as factors.<br /> <br /> From our earlier observation, the only factors of &lt;math&gt;21!&lt;/math&gt; that are even are ones with at least one multiplier of &lt;math&gt;2&lt;/math&gt;, so our probability of finding an odd factor becomes the following:<br /> &lt;cmath&gt;P(\text{odd})=\dfrac{\text{number of odd factors}}{\text{number of all factors}}=\dfrac{(9+1)(4+1)(3+1)(1+1)(1+1)(1+1)}{(18+1)(9+1)(4+1)(3+1)(1+1)(1+1)(1+1)}=\dfrac{1}{(18+1)}=\boxed{\dfrac{1}{19}}&lt;/cmath&gt;<br /> <br /> Solution submitted by TrueshotBarrage<br /> <br /> ==See Also==<br /> {{AMC12 box|year=2017|ab=B|num-b=15|num-a=17}}<br /> {{MAA Notice}}</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=2014_AMC_10B_Problems/Problem_5&diff=60132 2014 AMC 10B Problems/Problem 5 2014-02-20T22:34:37Z <p>TrueshotBarrage: /* Problem */</p> <hr /> <div>==Problem==<br /> <br /> Doug constructs a square window using 8 equal-size panes of glass, as shown. The ratio of the height to width of each pane is 5 : 2, and the borders around and between the panes are 2 inches wide. In inches, what is the side length of the square window?<br /> <br /> &lt;math&gt; \textbf {(A) } 26 \qquad \textbf {(B) } 28 \qquad \textbf {(C) } 30 \qquad \textbf {(D) } 32 \qquad \textbf {(E) } 34&lt;/math&gt;<br /> <br /> ==Solution==<br /> <br /> ==See Also==<br /> {{AMC10 box|year=2014|ab=B|num-b=4|num-a=6}}<br /> {{MAA Notice}}</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=2014_AMC_10B_Problems/Problem_7&diff=60129 2014 AMC 10B Problems/Problem 7 2014-02-20T22:32:45Z <p>TrueshotBarrage: Edit</p> <hr /> <div><br /> ==Problem==<br /> <br /> Suppose &lt;math&gt;A&gt;B&gt;0&lt;/math&gt; and A is &lt;math&gt;x&lt;/math&gt;% greater than &lt;math&gt;B&lt;/math&gt;. What is &lt;math&gt;x&lt;/math&gt;?<br /> <br /> &lt;math&gt; \textbf {(A) } 100(\frac{A-B}{B}) \qquad \textbf {(B) } 100(\frac{A+B}{B}) \qquad \textbf {(C) } 100(\frac{A+B}{A})\qquad \textbf {(D) } 100(\frac{A-B}{A}) \qquad \textbf {(E) } 100(\frac{A}{B})&lt;/math&gt;<br /> <br /> ==Solution==<br /> We have that A is x% greater than B, so &lt;math&gt;A=\frac{100+x}{100}(B)&lt;/math&gt;. We solve for &lt;math&gt;x&lt;/math&gt;. We get <br /> <br /> &lt;math&gt;\frac{A}{B}=\frac{100+x}{100}&lt;/math&gt;<br /> <br /> &lt;math&gt;100\frac{A}{B}=100+x&lt;/math&gt;<br /> <br /> &lt;math&gt;100(\frac{A}{B}-1)=x&lt;/math&gt;<br /> <br /> &lt;math&gt;\boxed{100(\frac{A-B}{B}) (\textbf{A})}=x&lt;/math&gt;.<br /> <br /> (Edited by TrueshotBarrage)<br /> <br /> ==See Also==<br /> {{AMC10 box|year=2014|ab=B|num-b=6|num-a=8}}<br /> {{MAA Notice}}</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=2014_AMC_10A_Problems/Problem_5&diff=59858 2014 AMC 10A Problems/Problem 5 2014-02-19T13:51:45Z <p>TrueshotBarrage: /* Solution */</p> <hr /> <div>{{duplicate|[[2014 AMC 12A Problems|2014 AMC 12A #5]] and [[2014 AMC 10A Problems|2014 AMC 10A #5]]}}<br /> ==Problem==<br /> <br /> On an algebra quiz, &lt;math&gt;10\%&lt;/math&gt; of the students scored &lt;math&gt;70&lt;/math&gt; points, &lt;math&gt;35\%&lt;/math&gt; scored &lt;math&gt;80&lt;/math&gt; points, &lt;math&gt;30\%&lt;/math&gt; scored &lt;math&gt;90&lt;/math&gt; points, and the rest scored &lt;math&gt;100&lt;/math&gt; points. What is the difference between the mean and median score of the students' scores on this quiz?<br /> <br /> &lt;math&gt; \textbf{(A)}\ 1\qquad\textbf{(B)}\ 2\qquad\textbf{(C)}\ 3\qquad\textbf{(D)}}\ 4\qquad\textbf{(E)}\ 5&lt;/math&gt;<br /> <br /> <br /> ==Solution==<br /> Without loss of generality, let there be &lt;math&gt;20&lt;/math&gt; students(the least whole number possible) who took the test. We have &lt;math&gt;2&lt;/math&gt; students score &lt;math&gt;70&lt;/math&gt; points, &lt;math&gt;7&lt;/math&gt; students score &lt;math&gt;80&lt;/math&gt; points, &lt;math&gt;6&lt;/math&gt; students score &lt;math&gt;90&lt;/math&gt; points and &lt;math&gt;5&lt;/math&gt; students score &lt;math&gt;100&lt;/math&gt; points. <br /> <br /> The median can be obtained by eliminating members from each group. The median is &lt;math&gt;90&lt;/math&gt; points. <br /> <br /> The mean is equal to the total number of points divided by the number of people, which gives &lt;math&gt;87&lt;/math&gt;<br /> <br /> Thus, the difference between the median and the mean is equal to &lt;math&gt;90-87=\boxed{\textbf{(C)}\ 3}&lt;/math&gt;<br /> <br /> (Solution/revised by armalite46)<br /> (&lt;math&gt;\LaTeX&lt;/math&gt; fixed by TrueshotBarrage)<br /> <br /> ==See Also==<br /> <br /> {{AMC10 box|year=2014|ab=A|num-b=4|num-a=6}}<br /> {{AMC12 box|year=2014|ab=A|num-b=4|num-a=6}}<br /> {{MAA Notice}}</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=Chicken_McNugget_Theorem&diff=59809 Chicken McNugget Theorem 2014-02-17T18:04:18Z <p>TrueshotBarrage: </p> <hr /> <div>The '''Chicken McNugget Theorem''' (or '''Postage Stamp Problem''' or '''Coin Problem''') states that for any two [[relatively prime]] [[positive integer]]s &lt;math&gt;m,n&lt;/math&gt;, the greatest integer that cannot be written in the form &lt;math&gt;am + bn&lt;/math&gt; for [[nonnegative]] integers &lt;math&gt;a, b&lt;/math&gt; is &lt;math&gt;mn-m-n&lt;/math&gt;.<br /> <br /> A consequence of the theorem is that there are exactly &lt;math&gt;\frac{(m - 1)(n - 1)}{2}&lt;/math&gt; positive integers which cannot be expressed in the form &lt;math&gt;am + bn&lt;/math&gt;. The proof is based on the fact that in each pair of the form &lt;math&gt;(k, (m - 1)(n - 1) - k+1)&lt;/math&gt;, exactly one element is expressible.<br /> <br /> == Origins ==<br /> The story goes that the Chicken McNugget Theorem got its name because in McDonalds, people bought Chicken McNuggets in 9 and 20 piece packages. Somebody wondered what the largest amount you could never buy was, assuming that you did not eat or take away any McNuggets. They found the answer to be 151 McNuggets, thus creating the Chicken McNugget Theorem.<br /> <br /> ==Proof==<br /> &lt;b&gt;Definition&lt;/b&gt;. An integer &lt;math&gt;N \in \mathbb{Z}&lt;/math&gt; will be called &lt;i&gt;purchasable&lt;/i&gt; if there exist nonnegative integers &lt;math&gt;a,b&lt;/math&gt; such that &lt;math&gt;am+bn = N&lt;/math&gt;.<br /> <br /> We would like to prove that &lt;math&gt;mn-m-n&lt;/math&gt; is the largest non-purchasable integer. We are required to show that (1) &lt;math&gt;mn-m-n&lt;/math&gt; is non-purchasable, and (2) every &lt;math&gt;N &gt; mn-m-n&lt;/math&gt; is purchasable. <br /> Note that all purchasable integers are nonnegative, thus the set of non-purchasable integers is nonempty.<br /> <br /> &lt;b&gt;Lemma&lt;/b&gt;. Let &lt;math&gt;A_{N} \subset \mathbb{Z} \times \mathbb{Z}&lt;/math&gt; be the set of solutions &lt;math&gt;(x,y)&lt;/math&gt; to &lt;math&gt;xm+yn = N&lt;/math&gt;. Then &lt;math&gt;A_{N} = \{(x+kn,y-km) \;:\; k \in \mathbb{Z}\}&lt;/math&gt; for any &lt;math&gt;(x,y) \in A_{N}&lt;/math&gt;.<br /> <br /> &lt;i&gt;Proof&lt;/i&gt;: By [[Bezout's Lemma]], there exist integers &lt;math&gt;x',y'&lt;/math&gt; such that &lt;math&gt;x'm+y'n = 1&lt;/math&gt;. Then &lt;math&gt;(Nx')m+(Ny')n = N&lt;/math&gt;. Hence &lt;math&gt;A_{N}&lt;/math&gt; is nonempty. It is easy to check that &lt;math&gt;(Nx'+kn,Ny'-km) \in A_{N}&lt;/math&gt; for all &lt;math&gt;k \in \mathbb{Z}&lt;/math&gt;. We now prove that there are no others. Suppose &lt;math&gt;(x_{1},y_{1})&lt;/math&gt; and &lt;math&gt;(x_{2},y_{2})&lt;/math&gt; are solutions to &lt;math&gt;xm+yn=N&lt;/math&gt;. Then &lt;math&gt;x_{1}m+y_{1}n = x_{2}m+y_{2}n&lt;/math&gt; implies &lt;math&gt;m(x_{1}-x_{2}) = n(y_{2}-y_{1})&lt;/math&gt;. Since &lt;math&gt;m&lt;/math&gt; and &lt;math&gt;n&lt;/math&gt; are coprime and &lt;math&gt;m&lt;/math&gt; divides &lt;math&gt;n(y_{2}-y_{1})&lt;/math&gt;, &lt;math&gt;m&lt;/math&gt; divides &lt;math&gt;y_{2}-y_{1}&lt;/math&gt; and &lt;math&gt;y_{2} \equiv y_{1} \pmod{m}&lt;/math&gt;. Similarly &lt;math&gt;x_{2} \equiv x_{1} \pmod{n}&lt;/math&gt;. Let &lt;math&gt;k_{1},k_{2}&lt;/math&gt; be integers such that &lt;math&gt;x_{2}-x_{1} = k_{1}n&lt;/math&gt; and &lt;math&gt;y_{2}-y_{1} = k_{2}m&lt;/math&gt;. Then &lt;math&gt;(x_{2}-x_{1})k_{2}m = (y_{2}-y_{1})k_{1}n&lt;/math&gt; implies &lt;math&gt;k_{1} = k_{2}&lt;/math&gt;. We have the desired result. &lt;math&gt;\square&lt;/math&gt;<br /> <br /> &lt;b&gt;Lemma&lt;/b&gt;. For any integer &lt;math&gt;N&lt;/math&gt;, there exists unique &lt;math&gt;(a_{N},b_{N}) \in \mathbb{Z} \times \{0,1,\ldots,m-1\}&lt;/math&gt; such that &lt;math&gt;a_{N}m + b_{N}n = N&lt;/math&gt;.<br /> <br /> &lt;i&gt;Proof&lt;/i&gt;: By the division algorithm, there exists &lt;math&gt;k&lt;/math&gt; such that &lt;math&gt;0 \le y-km \le m-1&lt;/math&gt;. &lt;math&gt;\square&lt;/math&gt;<br /> <br /> &lt;b&gt;Lemma&lt;/b&gt;. &lt;math&gt;N&lt;/math&gt; is purchasable if and only if &lt;math&gt;a_{N} \ge 0&lt;/math&gt;.<br /> <br /> &lt;i&gt;Proof&lt;/i&gt;: If &lt;math&gt;a_{N} \ge 0&lt;/math&gt;, then we may simply pick &lt;math&gt;(a,b) = (a_{N},b_{N})&lt;/math&gt; so &lt;math&gt;N&lt;/math&gt; is purchasable. If &lt;math&gt;a_{N} &lt; 0&lt;/math&gt;, then &lt;math&gt;a_{N}+kn &lt; 0&lt;/math&gt; if &lt;math&gt;k \le 0&lt;/math&gt; and &lt;math&gt;b_{N}-km &lt; 0&lt;/math&gt; if &lt;math&gt;k &gt; 0&lt;/math&gt;, hence at least one coordinate of &lt;math&gt;(a_{N}+kn,b_{N}-km)&lt;/math&gt; is negative for all &lt;math&gt;k \in \mathbb{Z}&lt;/math&gt;. Thus &lt;math&gt;N&lt;/math&gt; is not purchasable. &lt;math&gt;\square&lt;/math&gt;<br /> <br /> Thus the set of non-purchasable integers is &lt;math&gt;\{xm+yn \;:\; x&lt;0,0 \le y \le m-1\}&lt;/math&gt;. We would like to find the maximum of this set. <br /> Since both &lt;math&gt;m,n&lt;/math&gt; are positive, the maximum is achieved when &lt;math&gt;x = -1&lt;/math&gt; and &lt;math&gt;y = m-1&lt;/math&gt; so that &lt;math&gt;xm+yn = (-1)m+(m-1)n = mn-m-n&lt;/math&gt;.<br /> <br /> ==Problems==<br /> ===Introductory===<br /> *Marcy buys paint jars in containers of &lt;math&gt;2&lt;/math&gt; and &lt;math&gt;7&lt;/math&gt;. What's the largest number of paint jars that Marcy can't obtain?<br /> *Bay Area Rapid food sells chicken nuggets. You can buy packages of &lt;math&gt;11&lt;/math&gt; or &lt;math&gt;7&lt;/math&gt;. What is the largest integer &lt;math&gt;n&lt;/math&gt; such that there is no way to buy exactly &lt;math&gt;n&lt;/math&gt; nuggets? Can you Generalize ?(ACOPS)<br /> <br /> ===Intermediate===<br /> *Ninety-four bricks, each measuring &lt;math&gt;4''\times10''\times19'',&lt;/math&gt; are to stacked one on top of another to form a tower 94 bricks tall. Each brick can be oriented so it contributes &lt;math&gt;4''\,&lt;/math&gt; or &lt;math&gt;10''\,&lt;/math&gt; or &lt;math&gt;19''\,&lt;/math&gt; to the total height of the tower. How many different tower heights can be achieved using all ninety-four of the bricks? [[1994 AIME Problems/Problem 11|Source]]<br /> <br /> ===Olympiad===<br /> *On the real number line, paint red all points that correspond to integers of the form &lt;math&gt;81x+100y&lt;/math&gt;, where &lt;math&gt;x&lt;/math&gt; and &lt;math&gt;y&lt;/math&gt; are positive integers. Paint the remaining integer point blue. Find a point &lt;math&gt;P&lt;/math&gt; on the line such that, for every integer point &lt;math&gt;T&lt;/math&gt;, the reflection of &lt;math&gt;T&lt;/math&gt; with respect to &lt;math&gt;P&lt;/math&gt; is an integer point of a different colour than &lt;math&gt;T&lt;/math&gt;. (India TST)<br /> <br /> ==See Also==<br /> *[[Theorem]]<br /> *[[Prime]]<br /> <br /> [[Category:Theorems]]<br /> [[Category:Number theory]]</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=File:Trapezoid_problem.png&diff=53011 File:Trapezoid problem.png 2013-06-14T02:26:08Z <p>TrueshotBarrage: uploaded a new version of &amp;quot;File:Trapezoid problem.png&amp;quot;</p> <hr /> <div>An alcumus problem. test.</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=File:Trapezoid_problem.png&diff=53010 File:Trapezoid problem.png 2013-06-14T02:24:22Z <p>TrueshotBarrage: An alcumus problem. test.</p> <hr /> <div>An alcumus problem. test.</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=User_talk:JBL&diff=52894 User talk:JBL 2013-05-31T14:54:41Z <p>TrueshotBarrage: </p> <hr /> <div>Todo: [[Prism]], [[Cylinder]], [[Pyramid]], [[Cone]]<br /> <br /> == Is this how you use user talk? ==<br /> <br /> Yeah.. I didn't see that the article's sequence was defined starting with &lt;math&gt;F_1&lt;/math&gt;<br /> -[[User:Mountain.dew|Mountain.dew]] 11:03, 9 December 2007 (EST)<br /> <br /> == Re: Naming ==<br /> <br /> I viewed the thread, and it seems that theorems would be capitalized, which is explicitly what that page says. It was extremely vague otherwise. <br /> <br /> Also, should we move this discussion to [[AoPSWiki:Discussion]] since it now has three participants...? [[User:Temperal|Temperal]]&lt;span style=&quot;color:red&quot;&gt;&lt;small&gt;&lt;sup&gt;[[User Talk:Temperal|xy]]&lt;/sup&gt;&lt;/small&gt;&lt;/span&gt; 17:04, 17 December 2007 (EST)<br /> <br /> == Large equations ==<br /> <br /> I normally [[2002 AMC 12B Problems/Problem 20|use]] &lt;tt&gt;\begin{align*}&lt;/tt&gt; (or eqnarray [[User:Azjps/Proofs#Use LaTeX|etc]]), but I breakup large equations because apparently the math wraps around if its too long. At least on my browser, the following equation appears on two lines (and justified weirdly) rather than one:<br /> <br /> &lt;math&gt;[AEDF] = [AE'F] + [AED] + [AE'D] = 100 + 50\sqrt{3} + 500\sqrt{2} - 350\sqrt{3} + 300\sqrt{6} - 600 = 500\sqrt{2} - 350\sqrt{3} + 300\sqrt{6} - 600&lt;/math&gt;<br /> <br /> I probably should format everything/center, but [[2007 AIME I Problems/Problem 12]] has no nice solution besides a ton of algebra so I'm not very inclined to do that ;) . &lt;font style=&quot;font-family:Georgia,sans-serif&quot;&gt;[[User:Azjps|Azjps]] ([[User talk:Azjps|&lt;font color=&quot;green&quot;&gt;talk&lt;/font&gt;]])&lt;/font&gt; 16:58, 17 January 2008 (EST)<br /> :Oh, that's just because I was too lazy (at that time) to fix the entire article, as centering one line involving more trivial calculations would sort of stick out. I'll format everything now. &lt;font style=&quot;font-family:Georgia,sans-serif&quot;&gt;[[User:Azjps|Azjps]] ([[User talk:Azjps|&lt;font color=&quot;green&quot;&gt;talk&lt;/font&gt;]])&lt;/font&gt; 21:19, 17 January 2008 (EST)<br /> <br /> == Re: Capitalization ==<br /> <br /> Thanks for the help. I forgot to do the search there.<br /> <br /> [[User:Shreyas patankar|Shreyas patankar]] 19:25, 28 January 2008 (EST)<br /> <br /> I'm still confused about capitalization. Where do we use title case (Intermediate Mean Value Theorem) and sentence case(Cartesian product)?<br /> <br /> [[User:Shreyas patankar|Shreyas patankar]] 22:21, 15 February 2008 (EST)<br /> <br /> == Revert of my addition at Cauchy Schwarz Inequality ==<br /> <br /> Is this untrue? I thought it was true... [[User:Temperal|Temperal]]&lt;span style=&quot;color:red&quot;&gt;&lt;small&gt;&lt;sup&gt;[[User Talk:Temperal|xy]]&lt;/sup&gt;&lt;/small&gt;&lt;/span&gt; 16:31, 9 April 2008 (UTC)<br /> <br /> :Ah, sorry, didn't see the other section. My bad. [[User:Temperal|Temperal]]&lt;span style=&quot;color:red&quot;&gt;&lt;small&gt;&lt;sup&gt;[[User Talk:Temperal|xy]]&lt;/sup&gt;&lt;/small&gt;&lt;/span&gt; 16:31, 9 April 2008 (UTC)<br /> <br /> == LaTeX: Math page ==<br /> I assume you just used &quot;replace all&quot; or something to remove all the &quot;\displaymath&quot;s. Now we have this though (and I know nothing about LaTeX): &quot;Notice that the summation symbol looks much nicer now - adding theat the beginning of your math (inside the &lt;math&gt;...&lt;/math&gt;) will often make complicated math render more nicely.&quot; Heh, I seriously spent about 2-3 minutes trying to figure out what &quot;theat&quot; was. [[User:Mathnerdmo|Mathnerdmo]] 17:19, 1 August 2008 (UTC)<br /> <br /> :Just a note, the wiki parser automatically deletes any \ displaystyle s on articles (as a result of a latex upgrade on the wiki sometime back), so the deletion was unintentional. &lt;font style=&quot;font-family:Georgia,sans-serif&quot;&gt;[[User:Azjps|Azjps]] ([[User talk:Azjps|&lt;font color=&quot;green&quot;&gt;talk&lt;/font&gt;]])&lt;/font&gt; 20:49, 1 August 2008 (UTC)<br /> <br /> == Wow... ==<br /> <br /> First time posting something on another person's talk page :)<br /> [[User:TrueshotBarrage|TrueshotBarrage]] 10:54, 31 May 2013 (EDT)</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=User_talk:TrueshotBarrage&diff=52893 User talk:TrueshotBarrage 2013-05-31T14:50:13Z <p>TrueshotBarrage: Created page with &quot;HELLO, FIRST TEXT CONCILIATORY MOLE&quot;</p> <hr /> <div>HELLO, FIRST TEXT<br /> <br /> CONCILIATORY MOLE</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=User:TrueshotBarrage&diff=52892 User:TrueshotBarrage 2013-05-31T14:49:42Z <p>TrueshotBarrage: Created page with &quot;Hello everyone! Please call me &quot;trueshot&quot;, not &quot;trueshotbarrage&quot; or, even, &quot;TB.&quot; Anyways, I don't really get on the Wiki too much, so don't expect it to be filled. You can leave ...&quot;</p> <hr /> <div>Hello everyone! Please call me &quot;trueshot&quot;, not &quot;trueshotbarrage&quot; or, even, &quot;TB.&quot; Anyways, I don't really get on the Wiki too much, so don't expect it to be filled. You can leave a message on the Talk Page, or just send me a PM. Thanks!<br /> <br /> <br /> [[User:TrueshotBarrage|TrueshotBarrage]] 10:49, 31 May 2013 (EDT)</div> TrueshotBarrage https://artofproblemsolving.com/wiki/index.php?title=User:Davidkim2106&diff=47363 User:Davidkim2106 2012-06-09T22:26:14Z <p>Davidkim2106: </p> <hr /> <div>'''Hello!'''<br /> <br /> This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] User Page.<br /> <br /> This page has not been developed much yet because I am busy with my schoolwork and AoPS &quot;FTW!&quot;. This page will be updated later.<br /> <br /> Thanks,<br /> <br /> '''David'''<br /> <br /> &lt;math&gt;\left(\sqrt{\sqrt{\sqrt{\sqrt{256}}}}\right)&lt;/math&gt; &lt;math&gt;+&lt;/math&gt; &lt;math&gt;\left(\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}\right)&lt;/math&gt; &lt;math&gt;= ?&lt;/math&gt;<br /> <br /> <br /> &lt;math&gt; \frac{(x+y)(2x-y)(y-x)^{2}}{(x-y)(x^{2}-y^{2})(2x-y)} -1????&lt;/math&gt;</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=AoPS_Wiki:Sandbox&diff=47362 AoPS Wiki:Sandbox 2012-06-09T22:25:09Z <p>Davidkim2106: /* Test 0 */</p> <hr /> <div>{{AoPSWiki:Sandbox/header}} &lt;!-- Please do not delete this line --&gt;<br /> In the computer world, a '''sandbox''' is a place to test and experiment -- essentially, it's a place to play.<br /> <br /> This is the AoPSWiki Sandbox. Feel free to experiment here.<br /> <br /> Warning: anything you place here is subject to deletion without notice.<br /> <br /> == Test 0==<br /> <br /> What is &lt;math&gt; \frac{(x+y)(2x-y)(y-x)^{2}}{(x-y)(x^{2}-y^{2})(2x-y)} ???&lt;/math&gt;<br /> <br /> ==Test 1==<br /> <br /> &lt;asy&gt;<br /> <br /> dot((0,0));<br /> dot((1,0));<br /> dot((0,1));<br /> dot((1,1));<br /> dot((2,0));<br /> dot((0,2));<br /> dot((1,2));<br /> dot((2,1));<br /> dot((2,2));<br /> dot((3,0));<br /> dot((3,1));<br /> dot((3,2));<br /> dot((3,3));<br /> dot((2,3));<br /> dot((1,3));<br /> dot((0,3));<br /> dot((0,4));<br /> dot((1,4));<br /> dot((2,4));<br /> dot((3,4));<br /> dot((4,4));<br /> dot((4,3));<br /> dot((4,2));<br /> dot((4,1));<br /> dot((4,0));<br /> dot((5,0));<br /> dot((5,1));<br /> dot((5,2));<br /> dot((5,3));<br /> dot((5,4));<br /> dot((5,5));<br /> dot((4,5));<br /> dot((3,5));<br /> dot((2,5));<br /> dot((1,5));<br /> dot((0,5));<br /> dot((0,6));<br /> dot((1,6));<br /> dot((2,6));<br /> dot((3,6));<br /> dot((4,6));<br /> dot((5,6));<br /> dot((6,6));<br /> dot((6,5));<br /> dot((6,4));<br /> dot((6,3));<br /> dot((6,2));<br /> dot((6,1));<br /> dot((6,0));<br /> dot((7,0));<br /> dot((7,1));<br /> dot((7,2));<br /> dot((7,3));<br /> dot((7,4));<br /> dot((7,5));<br /> dot((7,6));<br /> dot((7,7));<br /> dot((6,7));<br /> dot((5,7));<br /> dot((4,7));<br /> dot((3,7));<br /> dot((2,7));<br /> dot((1,7));<br /> dot((0,7));<br /> draw((0,1)--(1,7),red);<br /> draw((1,7)--(7,6),red);<br /> draw((7,6)--(6,0),red);<br /> draw((6,0)--(0,1),red);<br /> draw((2,7)--(7,5),blue);<br /> draw((0,2)--(2,7),blue);<br /> draw((5,0)--(0,2),blue);<br /> draw((5,0)--(7,5),blue);<br /> draw((3,7)--(7,4),yellow);<br /> draw((7,4)--(4,0),yellow);<br /> draw((4,0)--(0,3),yellow);<br /> draw((0,3)--(3,7),yellow);<br /> draw((4,7)--(7,3),green);<br /> draw((7,3)--(3,0),green);<br /> draw((3,0)--(0,4),green);<br /> draw((0,4)--(4,7),green);<br /> draw((5,7)--(7,2),black);<br /> draw((7,2)--(2,0),black);<br /> draw((2,0)--(0,5),black);<br /> draw((0,5)--(5,7),black);<br /> draw((0,6)--(1,0),purple);<br /> draw((1,0)--(7,1),purple);<br /> draw((7,1)--(6,7),purple);<br /> draw((0,6)--(6,7),purple);<br /> <br /> &lt;/asy&gt;<br /> <br /> ==Test 2==<br /> &lt;b&gt;Test&lt;/b&gt;<br /> <br /> &lt;asy&gt;<br /> <br /> dot((0,0));<br /> dot((1,0));<br /> dot((0,1));<br /> dot((1,1));<br /> dot((0,2));<br /> dot((2,0));<br /> dot((1,2));<br /> dot((2,1));<br /> dot((2,2));<br /> dot((3,0));<br /> dot((3,1));<br /> dot((3,2));<br /> dot((3,3));<br /> dot((2,3));<br /> dot((1,3));<br /> dot((0,3));<br /> <br /> &lt;/asy&gt;<br /> <br /> ==Test 3==<br /> &lt;asy&gt;<br /> dot((0,0));<br /> dot((0,4));<br /> dot((3,4444));<br /> dot((3,0));<br /> dot((1.5,2));<br /> draw((0,0)--(3,4444),green);<br /> draw((0,4)--(3,0),green);<br /> draw((0,0)--(0,4),red);<br /> draw((0,4)--(3,4),red);<br /> draw((3,0)--(3,4),red);<br /> draw((3,0)--(0,0),red);<br /> &lt;/asy&gt;</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=AoPS_Wiki:Sandbox&diff=47361 AoPS Wiki:Sandbox 2012-06-09T22:23:18Z <p>Davidkim2106: </p> <hr /> <div>{{AoPSWiki:Sandbox/header}} &lt;!-- Please do not delete this line --&gt;<br /> In the computer world, a '''sandbox''' is a place to test and experiment -- essentially, it's a place to play.<br /> <br /> This is the AoPSWiki Sandbox. Feel free to experiment here.<br /> <br /> Warning: anything you place here is subject to deletion without notice.<br /> <br /> == Test 0==<br /> <br /> <br /> <br /> ==Test 1==<br /> <br /> &lt;asy&gt;<br /> <br /> dot((0,0));<br /> dot((1,0));<br /> dot((0,1));<br /> dot((1,1));<br /> dot((2,0));<br /> dot((0,2));<br /> dot((1,2));<br /> dot((2,1));<br /> dot((2,2));<br /> dot((3,0));<br /> dot((3,1));<br /> dot((3,2));<br /> dot((3,3));<br /> dot((2,3));<br /> dot((1,3));<br /> dot((0,3));<br /> dot((0,4));<br /> dot((1,4));<br /> dot((2,4));<br /> dot((3,4));<br /> dot((4,4));<br /> dot((4,3));<br /> dot((4,2));<br /> dot((4,1));<br /> dot((4,0));<br /> dot((5,0));<br /> dot((5,1));<br /> dot((5,2));<br /> dot((5,3));<br /> dot((5,4));<br /> dot((5,5));<br /> dot((4,5));<br /> dot((3,5));<br /> dot((2,5));<br /> dot((1,5));<br /> dot((0,5));<br /> dot((0,6));<br /> dot((1,6));<br /> dot((2,6));<br /> dot((3,6));<br /> dot((4,6));<br /> dot((5,6));<br /> dot((6,6));<br /> dot((6,5));<br /> dot((6,4));<br /> dot((6,3));<br /> dot((6,2));<br /> dot((6,1));<br /> dot((6,0));<br /> dot((7,0));<br /> dot((7,1));<br /> dot((7,2));<br /> dot((7,3));<br /> dot((7,4));<br /> dot((7,5));<br /> dot((7,6));<br /> dot((7,7));<br /> dot((6,7));<br /> dot((5,7));<br /> dot((4,7));<br /> dot((3,7));<br /> dot((2,7));<br /> dot((1,7));<br /> dot((0,7));<br /> draw((0,1)--(1,7),red);<br /> draw((1,7)--(7,6),red);<br /> draw((7,6)--(6,0),red);<br /> draw((6,0)--(0,1),red);<br /> draw((2,7)--(7,5),blue);<br /> draw((0,2)--(2,7),blue);<br /> draw((5,0)--(0,2),blue);<br /> draw((5,0)--(7,5),blue);<br /> draw((3,7)--(7,4),yellow);<br /> draw((7,4)--(4,0),yellow);<br /> draw((4,0)--(0,3),yellow);<br /> draw((0,3)--(3,7),yellow);<br /> draw((4,7)--(7,3),green);<br /> draw((7,3)--(3,0),green);<br /> draw((3,0)--(0,4),green);<br /> draw((0,4)--(4,7),green);<br /> draw((5,7)--(7,2),black);<br /> draw((7,2)--(2,0),black);<br /> draw((2,0)--(0,5),black);<br /> draw((0,5)--(5,7),black);<br /> draw((0,6)--(1,0),purple);<br /> draw((1,0)--(7,1),purple);<br /> draw((7,1)--(6,7),purple);<br /> draw((0,6)--(6,7),purple);<br /> <br /> &lt;/asy&gt;<br /> <br /> ==Test 2==<br /> &lt;b&gt;Test&lt;/b&gt;<br /> <br /> &lt;asy&gt;<br /> <br /> dot((0,0));<br /> dot((1,0));<br /> dot((0,1));<br /> dot((1,1));<br /> dot((0,2));<br /> dot((2,0));<br /> dot((1,2));<br /> dot((2,1));<br /> dot((2,2));<br /> dot((3,0));<br /> dot((3,1));<br /> dot((3,2));<br /> dot((3,3));<br /> dot((2,3));<br /> dot((1,3));<br /> dot((0,3));<br /> <br /> &lt;/asy&gt;<br /> <br /> ==Test 3==<br /> &lt;asy&gt;<br /> dot((0,0));<br /> dot((0,4));<br /> dot((3,4444));<br /> dot((3,0));<br /> dot((1.5,2));<br /> draw((0,0)--(3,4444),green);<br /> draw((0,4)--(3,0),green);<br /> draw((0,0)--(0,4),red);<br /> draw((0,4)--(3,4),red);<br /> draw((3,0)--(3,4),red);<br /> draw((3,0)--(0,0),red);<br /> &lt;/asy&gt;</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=AoPS_Wiki:Sandbox&diff=47360 AoPS Wiki:Sandbox 2012-06-09T22:18:51Z <p>Davidkim2106: /* Sandbox Area */</p> <hr /> <div>{{AoPSWiki:Sandbox/header}} &lt;!-- Please do not delete this line --&gt;<br /> In the computer world, a '''sandbox''' is a place to test and experiment -- essentially, it's a place to play.<br /> <br /> This is the AoPSWiki Sandbox. Feel free to experiment here.<br /> <br /> Warning: anything you place here is subject to deletion without notice.<br /> <br /> == test 89810312 ==<br /> &lt;hide&gt;hidden text&lt;/hide&gt;<br /> <br /> ==Test 1==<br /> <br /> &lt;asy&gt;<br /> <br /> dot((0,0));<br /> dot((1,0));<br /> dot((0,1));<br /> dot((1,1));<br /> dot((2,0));<br /> dot((0,2));<br /> dot((1,2));<br /> dot((2,1));<br /> dot((2,2));<br /> dot((3,0));<br /> dot((3,1));<br /> dot((3,2));<br /> dot((3,3));<br /> dot((2,3));<br /> dot((1,3));<br /> dot((0,3));<br /> dot((0,4));<br /> dot((1,4));<br /> dot((2,4));<br /> dot((3,4));<br /> dot((4,4));<br /> dot((4,3));<br /> dot((4,2));<br /> dot((4,1));<br /> dot((4,0));<br /> dot((5,0));<br /> dot((5,1));<br /> dot((5,2));<br /> dot((5,3));<br /> dot((5,4));<br /> dot((5,5));<br /> dot((4,5));<br /> dot((3,5));<br /> dot((2,5));<br /> dot((1,5));<br /> dot((0,5));<br /> dot((0,6));<br /> dot((1,6));<br /> dot((2,6));<br /> dot((3,6));<br /> dot((4,6));<br /> dot((5,6));<br /> dot((6,6));<br /> dot((6,5));<br /> dot((6,4));<br /> dot((6,3));<br /> dot((6,2));<br /> dot((6,1));<br /> dot((6,0));<br /> dot((7,0));<br /> dot((7,1));<br /> dot((7,2));<br /> dot((7,3));<br /> dot((7,4));<br /> dot((7,5));<br /> dot((7,6));<br /> dot((7,7));<br /> dot((6,7));<br /> dot((5,7));<br /> dot((4,7));<br /> dot((3,7));<br /> dot((2,7));<br /> dot((1,7));<br /> dot((0,7));<br /> draw((0,1)--(1,7),red);<br /> draw((1,7)--(7,6),red);<br /> draw((7,6)--(6,0),red);<br /> draw((6,0)--(0,1),red);<br /> draw((2,7)--(7,5),blue);<br /> draw((0,2)--(2,7),blue);<br /> draw((5,0)--(0,2),blue);<br /> draw((5,0)--(7,5),blue);<br /> draw((3,7)--(7,4),yellow);<br /> draw((7,4)--(4,0),yellow);<br /> draw((4,0)--(0,3),yellow);<br /> draw((0,3)--(3,7),yellow);<br /> draw((4,7)--(7,3),green);<br /> draw((7,3)--(3,0),green);<br /> draw((3,0)--(0,4),green);<br /> draw((0,4)--(4,7),green);<br /> draw((5,7)--(7,2),black);<br /> draw((7,2)--(2,0),black);<br /> draw((2,0)--(0,5),black);<br /> draw((0,5)--(5,7),black);<br /> draw((0,6)--(1,0),purple);<br /> draw((1,0)--(7,1),purple);<br /> draw((7,1)--(6,7),purple);<br /> draw((0,6)--(6,7),purple);<br /> <br /> &lt;/asy&gt;<br /> <br /> ==Test 2==<br /> &lt;b&gt;Test&lt;/b&gt;<br /> <br /> &lt;asy&gt;<br /> <br /> dot((0,0));<br /> dot((1,0));<br /> dot((0,1));<br /> dot((1,1));<br /> dot((0,2));<br /> dot((2,0));<br /> dot((1,2));<br /> dot((2,1));<br /> dot((2,2));<br /> dot((3,0));<br /> dot((3,1));<br /> dot((3,2));<br /> dot((3,3));<br /> dot((2,3));<br /> dot((1,3));<br /> dot((0,3));<br /> <br /> &lt;/asy&gt;<br /> <br /> ==Test 3==<br /> &lt;asy&gt;<br /> dot((0,0));<br /> dot((0,4));<br /> dot((3,4444));<br /> dot((3,0));<br /> dot((1.5,2));<br /> draw((0,0)--(3,4444),green);<br /> draw((0,4)--(3,0),green);<br /> draw((0,0)--(0,4),red);<br /> draw((0,4)--(3,4),red);<br /> draw((3,0)--(3,4),red);<br /> draw((3,0)--(0,0),red);<br /> &lt;/asy&gt;</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=User:Davidkim2106&diff=47359 User:Davidkim2106 2012-06-09T22:14:44Z <p>Davidkim2106: </p> <hr /> <div>'''Hello!'''<br /> <br /> This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] User Page.<br /> <br /> This page has not been developed much yet because I am busy with my schoolwork and AoPS &quot;FTW!&quot;. This page will be updated later.<br /> <br /> Thanks,<br /> <br /> '''David'''<br /> <br /> &lt;math&gt;\left(\sqrt{\sqrt{\sqrt{\sqrt{256}}}}\right)&lt;/math&gt; &lt;math&gt;+&lt;/math&gt; &lt;math&gt;\left(\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}\right)&lt;/math&gt; &lt;math&gt;= ?&lt;/math&gt;<br /> <br /> <br /> &lt;math&gt;(x+y)(2x-y)(y-x)^2/ {(x-y)(x^2-y^2)(2x-y)&lt;/math&gt;</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=User:Davidkim2106&diff=47358 User:Davidkim2106 2012-06-09T22:09:50Z <p>Davidkim2106: </p> <hr /> <div>'''Hello!'''<br /> <br /> This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] User Page.<br /> <br /> This page has not been developed much yet because I am busy with my schoolwork and AoPS &quot;FTW!&quot;. This page will be updated later.<br /> <br /> Thanks,<br /> <br /> '''David'''<br /> <br /> &lt;math&gt;\left(\sqrt{\sqrt{\sqrt{\sqrt{256}}}}\right)&lt;/math&gt; &lt;math&gt;+&lt;/math&gt; &lt;math&gt;\left(\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}\right)&lt;/math&gt; &lt;math&gt;= ?&lt;/math&gt;</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=User:Davidkim2106&diff=47357 User:Davidkim2106 2012-06-09T22:06:29Z <p>Davidkim2106: </p> <hr /> <div>'''Hello!'''<br /> <br /> This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] User Page.<br /> <br /> This page has not been developed much yet because I am busy with my schoolwork and AoPS &quot;FTW!&quot;. This page will be updated later.<br /> <br /> Thanks,<br /> <br /> '''David'''<br /> <br /> &lt;math&gt;\sqrt{\sqrt{\sqrt{\sqrt{256}}}}&lt;/math&gt; &lt;math&gt;+&lt;/math&gt; &lt;math&gt;\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}&lt;/math&gt; &lt;math&gt;= ?&lt;/math&gt;</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=User:Davidkim2106&diff=47356 User:Davidkim2106 2012-06-09T22:03:34Z <p>Davidkim2106: Created page with &quot;'''Hello!''' This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] User Page. This page has not been developed much yet because I am busy with my schoolwork an...&quot;</p> <hr /> <div>'''Hello!'''<br /> <br /> This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] User Page.<br /> <br /> This page has not been developed much yet because I am busy with my schoolwork and AoPS &quot;FTW!&quot;. This page will be updated later.<br /> <br /> Thanks,<br /> <br /> '''David'''</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=User_talk:Davidkim2106&diff=47355 User talk:Davidkim2106 2012-06-09T21:53:07Z <p>Davidkim2106: Created page with &quot;'''Hello!''' This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] Talk Page. Feel free to write on my talk page for questions, comments, or anything else you ...&quot;</p> <hr /> <div>'''Hello!'''<br /> <br /> This is davidkim2106's[http://en.wikipedia.org/wiki/User:Davidkim2106] Talk Page.<br /> <br /> Feel free to write on my talk page for questions, comments, or anything else you might want to post. Put tildes (~) under each comment.<br /> <br /> Thanks,<br /> <br /> '''David'''</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=LaTeX:Commands&diff=44450 LaTeX:Commands 2012-02-04T02:48:25Z <p>Davidkim2106: /* See Also */</p> <hr /> <div>{{Latex}}<br /> <br /> This page introduces various useful commands for rendering math in LaTeX, as well as instructions for building your own commands.<br /> <br /> ==Math Commands==<br /> Here are some commonly used math commands in LaTeX.<br /> ===Exponents and Subscripts===<br /> Make exponents in LaTeX with ^ and subscripts with _ as shown in the examples below.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol!!Command<br /> |-<br /> |&lt;math&gt;2^{2}&lt;/math&gt;||2^2||&lt;math&gt;\textstyle a_i&lt;/math&gt;||a_i<br /> |-<br /> | &lt;math&gt;\textstyle 2^{23}&lt;/math&gt;||2^{23}||&lt;math&gt;\textstyle n_{i-1}&lt;/math&gt;||n_{i-1}<br /> |-<br /> | &lt;math&gt;a^{i+1}_3&lt;/math&gt;||a^{i+1}_3||&lt;math&gt;x^{3^2}&lt;/math&gt;||x^{3^2}<br /> |-<br /> | &lt;math&gt;2^{a_i}&lt;/math&gt;||2^{a_i}||&lt;math&gt;2^a_i&lt;/math&gt;||2^a_i<br /> |}<br /> Notice that we can apply both a subscript and an exponent at the same time, and that we can use {} to tell LaTeX what to apply a subscript or exponent to (compare the examples on the bottom row).<br /> <br /> Finally, notice that we use {} for any exponent or subscript that is more than one character. You have to do so, or you'll end up with &lt;math&gt;2^234&lt;/math&gt; or &lt;math&gt;a^i+1_n-1&lt;/math&gt; when you really want &lt;math&gt;2^{234}&lt;/math&gt; or &lt;math&gt;a^{i+1}_{n-1}&lt;/math&gt;.<br /> <br /> ===Fractions===<br /> {|class=&quot;latextable&quot;<br /> !Symbol!!Command<br /> |-<br /> |&lt;math&gt;\textstyle \frac{1}{2}&lt;/math&gt;||\frac{1}{2}<br /> |-<br /> | &lt;math&gt;\textstyle \frac{2}{x+2}&lt;/math&gt;||\frac{2}{x+2}<br /> |-<br /> | &lt;math&gt;\textstyle \frac{1+\frac{1}{x}}{3x + 2}&lt;/math&gt;||\frac{1+\frac{1}{x}}{3x + 2}<br /> |}<br /> Most fractions look better in (remember, you don't need the declaration if you are in &lt;nowiki&gt;$...$&lt;/nowiki&gt; or &lt;nowiki&gt;$$...$$&lt;/nowiki&gt; mode.) You can use \dfrac as a shortcut:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\frac{1}{2}&lt;/math&gt;||\dfrac{1}{2}<br /> |-<br /> | &lt;math&gt;\frac{2}{x+2}&lt;/math&gt;||\dfrac{2}{x+2}<br /> |-<br /> | &lt;math&gt;\frac{1+\frac{1}{x}}{3x + 2}&lt;/math&gt;||\dfrac{1+\frac{1}{x}}{3x + 2}<br /> |}<br /> Use \cfrac for continued fractions:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}&lt;/math&gt;||\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}<br /> |}<br /> <br /> ===Radicals===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\sqrt{2}&lt;/math&gt;||\sqrt{2}<br /> |-<br /> | &lt;math&gt;\sqrt{x+y}&lt;/math&gt;||\sqrt{x+y}<br /> |-<br /> | &lt;math&gt;\sqrt{x+\frac{1}{2}}&lt;/math&gt;||\sqrt{x+\frac{1}{2}}<br /> |-<br /> | &lt;math&gt;\sqrt{3}&lt;/math&gt;||\sqrt{3}<br /> |-<br /> | &lt;math&gt;\sqrt[n]{x}&lt;/math&gt;||\sqrt[n]{x}<br /> |}<br /> <br /> ===Sums, Products, Limits and Logarithms===<br /> We use _ to get the 'bottom' parts of summations, products, and limits, as well as the subscripts of logarithms. We use ^ to get the 'top' parts of sums and products. (Integration symbols work the same way, as you'll see in the [[LaTeX:Commands#Calculus|calculus section]].) Click here for a few [[LaTeX:Commands#Other_Functions|other commands]] which take 'bottom' parts.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\textstyle \sum_{i=1}^{\infty}\frac{1}{i}&lt;/math&gt;||\sum_{i=1}^{\infty}\frac{1}{i}<br /> |-<br /> | &lt;math&gt;\textstyle \prod_{n=1}^5\frac{n}{n-1}&lt;/math&gt;||\prod_{n=1}^5\frac{n}{n-1}<br /> |-<br /> | &lt;math&gt;\textstyle \lim_{x\to\infty}\frac{1}{x}&lt;/math&gt;||\lim_{x\to\infty}\frac{1}{x}<br /> |-<br /> |&lt;math&gt;\textstyle \log_n n^2&lt;/math&gt;||\log_n n^2<br /> |}<br /> Some of these are prettier in display mode:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\sum_{i=1}^{\infty}\frac{1}{i}&lt;/math&gt;||\sum_{i=1}^{\infty}\frac{1}{i}<br /> |-<br /> | &lt;math&gt;\prod_{n=1}^5\frac{n}{n-1}&lt;/math&gt;||\prod_{n=1}^5\frac{n}{n-1}<br /> |-<br /> | &lt;math&gt;\lim_{x\to\infty}\frac{1}{x}&lt;/math&gt;||\lim_{x\to\infty}\frac{1}{x}<br /> |}<br /> Note that we can use sums, products, and logarithms without _ or ^ modifiers.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\sum\frac{1}{i}&lt;/math&gt;||\sum\frac{1}{i}<br /> |-<br /> | &lt;math&gt;\frac{n}{n-1}&lt;/math&gt;||\frac{n}{n-1}<br /> |-<br /> | &lt;math&gt;\textstyle \log n^2&lt;/math&gt;||\log n^2<br /> |-<br /> | &lt;math&gt;\textstyle \ln e&lt;/math&gt;||\ln e<br /> |}<br /> <br /> ===Mods===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;9\equiv 3 \bmod{6}&lt;/math&gt;||9\equiv 3 \bmod{6}<br /> |-<br /> | &lt;math&gt;9\equiv 3 \pmod{6}&lt;/math&gt;||9\equiv 3 \pmod{6}<br /> |-<br /> | &lt;math&gt;9\equiv 3 \mod{6}&lt;/math&gt;||9\equiv 3 \mod{6}<br /> |-<br /> | &lt;math&gt;9\equiv 3\pod{6}&lt;/math&gt;||9\equiv 3 \pod{6}<br /> |}<br /> <br /> ===Combinations===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\scriptstyle\binom{9}{3}&lt;/math&gt;||\binom{9}{3}<br /> |-<br /> | &lt;math&gt;\scriptstyle\binom{n-1}{r-1}&lt;/math&gt;||\binom{n-1}{r-1}<br /> |}<br /> These often look better in display mode:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\dbinom{9}{3}&lt;/math&gt;||\dbinom{9}{3}<br /> |-<br /> | &lt;math&gt;\dbinom{n-1}{r-1}&lt;/math&gt;||\dbinom{n-1}{r-1}<br /> |}<br /> <br /> ===Trigonometric Functions===<br /> {| class=&quot;latextable&quot;<br /> !Symbol!!Command!!Symbol!!Command!!Symbol!!Command<br /> |-<br /> |&lt;math&gt;\textstyle \cos&lt;/math&gt;||\cos||&lt;math&gt;\textstyle \sin&lt;/math&gt;||\sin||&lt;math&gt;\textstyle \tan&lt;/math&gt;||\tan<br /> |-<br /> | &lt;math&gt;\sec&lt;/math&gt;||\sec||&lt;math&gt;\textstyle \textstyle \csc&lt;/math&gt;||\csc||&lt;math&gt;\textstyle \cot&lt;/math&gt;||\cot<br /> |-<br /> | &lt;math&gt;\textstyle \arccos&lt;/math&gt;||\arccos||&lt;math&gt;\textstyle \arcsin&lt;/math&gt;||\arcsin||&lt;math&gt;\textstyle \arctan&lt;/math&gt;||\arctan<br /> |-<br /> | &lt;math&gt;\textstyle \cosh&lt;/math&gt;||\cosh||&lt;math&gt;\textstyle \sinh&lt;/math&gt;||\sinh||&lt;math&gt;\textstyle \tanh&lt;/math&gt;||\tanh<br /> |-<br /> | &lt;math&gt;\textstyle \coth&lt;/math&gt;||\coth <br /> |}<br /> Here are a couple examples:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\textstyle \cos^2 x +\sin^2 x = 1&lt;/math&gt;||\cos^2 x +\sin^2 x = 1<br /> |-<br /> | &lt;math&gt;\cos 90^\circ = 0&lt;/math&gt;||\cos 90^\circ = 0 <br /> |}<br /> <br /> ===Calculus===<br /> Below are examples of calculus rendered in LaTeX. Most of these commands have been introduced before. Notice how definite integrals are rendered (and the difference between regular math and display mode for definite integrals). The , in the integrals makes a small space before the dx.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\frac{d}{dx}\left(x^2\right) = 2x&lt;/math&gt;||\frac{d}{dx}\left(x^2\right) = 2x<br /> |-<br /> | &lt;math&gt;\int 2x\,dx = x^2+C&lt;/math&gt;||\int 2x\,dx = x^2+C<br /> |-<br /> | &lt;math&gt;\int^5_1 2x\,dx = 24&lt;/math&gt;||\int^5_1 2x\,dx = 24<br /> |-<br /> | &lt;math&gt;\int^5_1 2x\,dx = 24&lt;/math&gt;||\int^5_1 2x\,dx = 24<br /> |-<br /> | &lt;math&gt;\frac{\partial^2U}{\partial x^2} + \frac{\partial^2U}{\partial y^2}&lt;/math&gt;||\frac{\partial^2U}{\partial x^2} + \frac{\partial^2U}{\partial y^2}<br /> |-<br /> | &lt;math&gt;\frac{1}{4\pi}\oint_\Sigma\frac{1}{r}\frac{\partial U}{\partial n} ds&lt;/math&gt;||\frac{1}{4\pi}\oint_\Sigma\frac{1}{r}\frac{\partial U}{\partial n} ds<br /> |}<br /> <br /> ===Overline and Underline===<br /> <br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\overline{a+bi}&lt;/math&gt;||\overline{a+bi}<br /> |-<br /> | &lt;math&gt;\underline{431}&lt;/math&gt;||\underline{431}<br /> |}<br /> <br /> ===Other Functions===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol !! Command!!Symbol !! Command<br /> |-<br /> |&lt;math&gt;\arg&lt;/math&gt;||\arg||&lt;math&gt;\textstyle\deg&lt;/math&gt;||\deg||&lt;math&gt;\textstyle\det&lt;/math&gt;||\det<br /> |-<br /> | &lt;math&gt;\dim&lt;/math&gt;||\dim||&lt;math&gt;\textstyle\exp&lt;/math&gt;||\exp||&lt;math&gt;\textstyle\gcd&lt;/math&gt;||\gcd<br /> |-<br /> |&lt;math&gt;\hom&lt;/math&gt;||\hom||&lt;math&gt;\inf&lt;/math&gt;||\inf||&lt;math&gt;\ker&lt;/math&gt;||\ker<br /> |-<br /> | &lt;math&gt;\textstyle\lg&lt;/math&gt;||\lg||&lt;math&gt;\liminf&lt;/math&gt;||\liminf||&lt;math&gt;\limsup&lt;/math&gt;||\limsup<br /> |-<br /> | &lt;math&gt;\textstyle\max&lt;/math&gt;||\max||&lt;math&gt;\textstyle\min&lt;/math&gt;||\min||&lt;math&gt;\Pr&lt;/math&gt;||\Pr<br /> |-<br /> | &lt;math&gt;\sup&lt;/math&gt;||\sup<br /> |}<br /> Some of these functions take 'bottom' parts just like sums and limits. Some render differently in display mode and regular math mode.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol !! Command!!Symbol !! Command<br /> |-<br /> | &lt;math&gt;\dim_x&lt;/math&gt;||\dim_x||&lt;math&gt;\textstyle\gcd_x&lt;/math&gt;||\gcd_x||&lt;math&gt;\inf_x&lt;/math&gt;||\inf_x<br /> |-<br /> | &lt;math&gt;\liminf_x&lt;/math&gt;||\liminf_x||&lt;math&gt;\limsup_x&lt;/math&gt;||\limsup_x||&lt;math&gt;\textstyle\max_x&lt;/math&gt;||\max_x<br /> |-<br /> | &lt;math&gt;\textstyle\min_x&lt;/math&gt;||\min_x||&lt;math&gt;\Pr_x&lt;/math&gt;||\Pr_x||&lt;math&gt;\sup_x&lt;/math&gt;||\sup_x<br /> |}<br /> <br /> ==Matrices==<br /> We can build an array or matrix with the \begin{array} command, and use \left and \right to properly size the delimiters around the matrix:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> The characteristic polynomial $f(\lambda)$ of the<br /> $3 \times 3$ matrix<br /> $<br /> \left(<br /> \begin{array}{ccc}<br /> a &amp; b &amp; c \\<br /> d &amp; e &amp; f \\<br /> g &amp; h &amp; i \end{array}<br /> \right)$<br /> is given by the equation<br /> $f(\lambda)<br /> = \left|<br /> \begin{array}{ccc}<br /> \lambda - a &amp; -b &amp; -c \\<br /> -d &amp; \lambda - e &amp; -f \\<br /> -g &amp; -h &amp; \lambda - i \end{array}<br /> \right|.$<br /> &lt;/nowiki&gt;<br /> &lt;/pre&gt;<br /> More simply, we can use the shortcut commands in the amsmath package:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> The characteristic polynomial $f(\lambda)$ of the<br /> $3 \times 3$ matrix<br /> $<br /> \begin{pmatrix}<br /> a &amp; b &amp; c \\<br /> d &amp; e &amp; f \\<br /> g &amp; h &amp; i<br /> \end{pmatrix}$<br /> is given by the equation<br /> $f(\lambda)<br /> = \begin{vmatrix}<br /> \lambda - a &amp; -b &amp; -c \\<br /> -d &amp; \lambda - e &amp; -f \\<br /> -g &amp; -h &amp; \lambda - i<br /> \end{vmatrix}.$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> You can read more about how the array command works [[LaTeX:Layout|here]] (it works the same as tabular) and more about using \left and \right [[LaTeX:Commands |here]].<br /> <br /> We can also use this environment to typeset any mathematics that calls for multiple columns, such as funky function definitions like this one:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> $f(x) = \left\{ \begin{array}{ll}<br /> x+7 &amp; \mbox{if 5&lt; x};\\<br /> x^2-3 &amp; \mbox{if -3 \le x \le 5};\\<br /> -x &amp; \mbox{if x &lt; -3}.\end{array} \right.$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> <br /> But it would be better to use the cases environment and \text command that the amsmath package provides:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> $<br /> f(x) = \begin{cases}<br /> x+7 &amp; \text{if 5&lt; x}; \\<br /> x^2-3 &amp; \text{if -3 \le x \le 5};\\<br /> -x &amp; \text{if x &lt; -3}.<br /> \end{cases}<br />$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> <br /> ==Text Styles in Math Mode==<br /> You can render letters in various styles in math mode. Below are examples; you should be able to use these with any letters. The \mathbb requires the amsfonts package to be include in your document's preamble.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol !! Command!!Symbol !! Command!!Symbol !! Comand<br /> |-<br /> |&lt;math&gt;\mathbb{R}&lt;/math&gt;||\mathbb{R}||&lt;math&gt;\mathbf{R}&lt;/math&gt;||\mathbf{R}||&lt;math&gt;\mathcal{R}&lt;/math&gt;||\mathcal{R}||&lt;math&gt;\mathfrak{R}&lt;/math&gt;||\mathfrak{R}<br /> |-<br /> | [[Image:Mathbb1.gif]]||\mathbb{Z}||&lt;math&gt;\mathbf{Z}&lt;/math&gt;||\mathbf{Z}||&lt;math&gt;\mathcal{Z}&lt;/math&gt;||\mathcal{Z}||&lt;math&gt;\mathfrak{Z}&lt;/math&gt;||\mathfrak{Z}<br /> |-<br /> | &lt;math&gt;\mathbb{Q}&lt;/math&gt;||\mathbb{Q}||&lt;math&gt;\mathbf{Q}&lt;/math&gt;||\mathbf{Q}||&lt;math&gt;\mathcal{Q}&lt;/math&gt;||\mathcal{Q}||&lt;math&gt;\mathfrak{Q}&lt;/math&gt;||\mathfrak{Q}<br /> |}<br /> If you're persistent, you can dig a few more out of [ftp://ftp.ams.org/pub/tex/doc/amsfonts/amsfndoc.pdf this document].<br /> <br /> If you want to drop a little bit of text in the middle of math mode, you can use the \text command. The \text command is most useful in &lt;nowiki&gt;$$...$$&lt;/nowiki&gt; or &lt;nowiki&gt;$...$&lt;/nowiki&gt; mode, where breaking up the math mode would force the output on to a new line entirely.<br /> So<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> $$n^2 + 5 = 30\text{ so we have }n=\pm5$$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> gives<br /> <br /> [[Image:Text1.gif]]<br /> <br /> ==How to Build Your Own Commands==<br /> The command \newcommand is used to create your own commands. We'll start with an example:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> \documentclass[11pt]{article}<br /> \usepackage{amsmath}<br /> <br /> \pdfpagewidth 8.5in<br /> \pdfpageheight 11in<br /> \newcommand{\reci}{\frac{1}{#1}}<br /> \newcommand{\hypot}{\sqrt{#1^2+#2^2}}<br /> \newcommand{\cbrt}{\sqrt{#1}}<br /> <br /> \begin{document}<br /> <br /> The reciprocal of 2 is $\reci{2}$.<br /> <br /> The hypotenuse has length $\hypot{3}{4}$.<br /> <br /> I'm sick of writing $\backslash$sqrt{2}' all the time, just to get $\cbrt{2}$.<br /> <br /> \end{document}<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> The \newcommand declarations are in the preamble. Each is of the form<br /> <br /> \newcommand{name of new command}[number of arguments]{definition}<br /> <br /> The name of the new command, which must begin with a \, is the name you'll use in the document to use the command. The number of arguments is how many inputs will be sent to the command. The definition is just normal LaTeX code, with #1, #2, #3, etc., placed where you want the inputs to go when the new command is called.<br /> <br /> New commands can be used for all sorts of purposes, not just for making math commands you'll use a lot easier to call. For example, try this:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> \documentclass[11pt]{article}<br /> \usepackage{amsmath}<br /> <br /> \pdfpagewidth 8.5in<br /> \pdfpageheight 11in<br /> \newcounter{prob_num}<br /> \setcounter{prob_num}{1}<br /> \newcommand{\prob}{\bigskip \bigskip\arabic{prob_num}.\stepcounter{prob_num} #1<br /> \par\nopagebreak\medskip A.\ #2\hfill B.\ #3\hfill<br /> C.\ #4\hfill D.\ #5\hfill E.\ NOTA}<br /> <br /> \begin{document}<br /> <br /> \prob{What is $2+2$?}{4}{5}{6}{7}<br /> <br /> \prob{What is $\sqrt{100}$?}{81}{10}{9}{1}<br /> <br /> \prob{Evaluate $\displaystyle\sum_{n=1}^\infty \frac{1}{n^2}$.}<br /> {$\displaystyle\frac{1}{e}$} {$\displaystyle\frac{2}{\pi}$}<br /> {$\displaystyle\frac{\pi^3}{8}$} {$\displaystyle\frac{\pi^2}{6}$}<br /> <br /> \end{document}<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> In the example above, we create a new command called \prob. Each time we call \prob, we supply 5 arguments, one for the question and one for each of the multiple choices.<br /> <br /> In the preamble and the definition of \prob, you'll see a few new LaTeX commands:<br /> <br /> \newcounter{prob_num} creates a counter variable called prob_num<br /> <br /> \setcounter{prob_num}{1} setsprob_num to equal 1.<br /> <br /> In the definition of \prob, the \bigskip and \medskip commands create vertical space.<br /> <br /> \arabic{prob_num} prints out the current value of the counter prob_num as an arabic numeral.<br /> <br /> \stepcounter{prob_num} increments the counter prob_num by 1.<br /> <br /> \nopagebreak tells LaTeX not to break the page between the problem and the choices unless it really, really, really has to.<br /> <br /> The \hfill commands put roughly equal space between the choices.<br /> <br /> Once you build a body of custom commands that you will be using in many LaTeX documents, you should learn about [[LaTeX:Packages|creating your own package]] so you don't have to copy all your custom commands from document to document.<br /> <br /> ==See Also==<br /> *[[LaTeX:Packages | Next: Packages]]<br /> *[[LaTeX:Symbols | Previous: Symbols]]</div> Davidkim2106 https://artofproblemsolving.com/wiki/index.php?title=LaTeX:Commands&diff=44449 LaTeX:Commands 2012-02-04T02:48:16Z <p>Davidkim2106: /* See Also */</p> <hr /> <div>{{Latex}}<br /> <br /> This page introduces various useful commands for rendering math in LaTeX, as well as instructions for building your own commands.<br /> <br /> ==Math Commands==<br /> Here are some commonly used math commands in LaTeX.<br /> ===Exponents and Subscripts===<br /> Make exponents in LaTeX with ^ and subscripts with _ as shown in the examples below.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol!!Command<br /> |-<br /> |&lt;math&gt;2^{2}&lt;/math&gt;||2^2||&lt;math&gt;\textstyle a_i&lt;/math&gt;||a_i<br /> |-<br /> | &lt;math&gt;\textstyle 2^{23}&lt;/math&gt;||2^{23}||&lt;math&gt;\textstyle n_{i-1}&lt;/math&gt;||n_{i-1}<br /> |-<br /> | &lt;math&gt;a^{i+1}_3&lt;/math&gt;||a^{i+1}_3||&lt;math&gt;x^{3^2}&lt;/math&gt;||x^{3^2}<br /> |-<br /> | &lt;math&gt;2^{a_i}&lt;/math&gt;||2^{a_i}||&lt;math&gt;2^a_i&lt;/math&gt;||2^a_i<br /> |}<br /> Notice that we can apply both a subscript and an exponent at the same time, and that we can use {} to tell LaTeX what to apply a subscript or exponent to (compare the examples on the bottom row).<br /> <br /> Finally, notice that we use {} for any exponent or subscript that is more than one character. You have to do so, or you'll end up with &lt;math&gt;2^234&lt;/math&gt; or &lt;math&gt;a^i+1_n-1&lt;/math&gt; when you really want &lt;math&gt;2^{234}&lt;/math&gt; or &lt;math&gt;a^{i+1}_{n-1}&lt;/math&gt;.<br /> <br /> ===Fractions===<br /> {|class=&quot;latextable&quot;<br /> !Symbol!!Command<br /> |-<br /> |&lt;math&gt;\textstyle \frac{1}{2}&lt;/math&gt;||\frac{1}{2}<br /> |-<br /> | &lt;math&gt;\textstyle \frac{2}{x+2}&lt;/math&gt;||\frac{2}{x+2}<br /> |-<br /> | &lt;math&gt;\textstyle \frac{1+\frac{1}{x}}{3x + 2}&lt;/math&gt;||\frac{1+\frac{1}{x}}{3x + 2}<br /> |}<br /> Most fractions look better in (remember, you don't need the declaration if you are in &lt;nowiki&gt;$...$&lt;/nowiki&gt; or &lt;nowiki&gt;$$...$$&lt;/nowiki&gt; mode.) You can use \dfrac as a shortcut:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\frac{1}{2}&lt;/math&gt;||\dfrac{1}{2}<br /> |-<br /> | &lt;math&gt;\frac{2}{x+2}&lt;/math&gt;||\dfrac{2}{x+2}<br /> |-<br /> | &lt;math&gt;\frac{1+\frac{1}{x}}{3x + 2}&lt;/math&gt;||\dfrac{1+\frac{1}{x}}{3x + 2}<br /> |}<br /> Use \cfrac for continued fractions:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}&lt;/math&gt;||\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1+\cfrac{2}{1}}}}<br /> |}<br /> <br /> ===Radicals===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\sqrt{2}&lt;/math&gt;||\sqrt{2}<br /> |-<br /> | &lt;math&gt;\sqrt{x+y}&lt;/math&gt;||\sqrt{x+y}<br /> |-<br /> | &lt;math&gt;\sqrt{x+\frac{1}{2}}&lt;/math&gt;||\sqrt{x+\frac{1}{2}}<br /> |-<br /> | &lt;math&gt;\sqrt{3}&lt;/math&gt;||\sqrt{3}<br /> |-<br /> | &lt;math&gt;\sqrt[n]{x}&lt;/math&gt;||\sqrt[n]{x}<br /> |}<br /> <br /> ===Sums, Products, Limits and Logarithms===<br /> We use _ to get the 'bottom' parts of summations, products, and limits, as well as the subscripts of logarithms. We use ^ to get the 'top' parts of sums and products. (Integration symbols work the same way, as you'll see in the [[LaTeX:Commands#Calculus|calculus section]].) Click here for a few [[LaTeX:Commands#Other_Functions|other commands]] which take 'bottom' parts.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\textstyle \sum_{i=1}^{\infty}\frac{1}{i}&lt;/math&gt;||\sum_{i=1}^{\infty}\frac{1}{i}<br /> |-<br /> | &lt;math&gt;\textstyle \prod_{n=1}^5\frac{n}{n-1}&lt;/math&gt;||\prod_{n=1}^5\frac{n}{n-1}<br /> |-<br /> | &lt;math&gt;\textstyle \lim_{x\to\infty}\frac{1}{x}&lt;/math&gt;||\lim_{x\to\infty}\frac{1}{x}<br /> |-<br /> |&lt;math&gt;\textstyle \log_n n^2&lt;/math&gt;||\log_n n^2<br /> |}<br /> Some of these are prettier in display mode:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\sum_{i=1}^{\infty}\frac{1}{i}&lt;/math&gt;||\sum_{i=1}^{\infty}\frac{1}{i}<br /> |-<br /> | &lt;math&gt;\prod_{n=1}^5\frac{n}{n-1}&lt;/math&gt;||\prod_{n=1}^5\frac{n}{n-1}<br /> |-<br /> | &lt;math&gt;\lim_{x\to\infty}\frac{1}{x}&lt;/math&gt;||\lim_{x\to\infty}\frac{1}{x}<br /> |}<br /> Note that we can use sums, products, and logarithms without _ or ^ modifiers.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\sum\frac{1}{i}&lt;/math&gt;||\sum\frac{1}{i}<br /> |-<br /> | &lt;math&gt;\frac{n}{n-1}&lt;/math&gt;||\frac{n}{n-1}<br /> |-<br /> | &lt;math&gt;\textstyle \log n^2&lt;/math&gt;||\log n^2<br /> |-<br /> | &lt;math&gt;\textstyle \ln e&lt;/math&gt;||\ln e<br /> |}<br /> <br /> ===Mods===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;9\equiv 3 \bmod{6}&lt;/math&gt;||9\equiv 3 \bmod{6}<br /> |-<br /> | &lt;math&gt;9\equiv 3 \pmod{6}&lt;/math&gt;||9\equiv 3 \pmod{6}<br /> |-<br /> | &lt;math&gt;9\equiv 3 \mod{6}&lt;/math&gt;||9\equiv 3 \mod{6}<br /> |-<br /> | &lt;math&gt;9\equiv 3\pod{6}&lt;/math&gt;||9\equiv 3 \pod{6}<br /> |}<br /> <br /> ===Combinations===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\scriptstyle\binom{9}{3}&lt;/math&gt;||\binom{9}{3}<br /> |-<br /> | &lt;math&gt;\scriptstyle\binom{n-1}{r-1}&lt;/math&gt;||\binom{n-1}{r-1}<br /> |}<br /> These often look better in display mode:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\dbinom{9}{3}&lt;/math&gt;||\dbinom{9}{3}<br /> |-<br /> | &lt;math&gt;\dbinom{n-1}{r-1}&lt;/math&gt;||\dbinom{n-1}{r-1}<br /> |}<br /> <br /> ===Trigonometric Functions===<br /> {| class=&quot;latextable&quot;<br /> !Symbol!!Command!!Symbol!!Command!!Symbol!!Command<br /> |-<br /> |&lt;math&gt;\textstyle \cos&lt;/math&gt;||\cos||&lt;math&gt;\textstyle \sin&lt;/math&gt;||\sin||&lt;math&gt;\textstyle \tan&lt;/math&gt;||\tan<br /> |-<br /> | &lt;math&gt;\sec&lt;/math&gt;||\sec||&lt;math&gt;\textstyle \textstyle \csc&lt;/math&gt;||\csc||&lt;math&gt;\textstyle \cot&lt;/math&gt;||\cot<br /> |-<br /> | &lt;math&gt;\textstyle \arccos&lt;/math&gt;||\arccos||&lt;math&gt;\textstyle \arcsin&lt;/math&gt;||\arcsin||&lt;math&gt;\textstyle \arctan&lt;/math&gt;||\arctan<br /> |-<br /> | &lt;math&gt;\textstyle \cosh&lt;/math&gt;||\cosh||&lt;math&gt;\textstyle \sinh&lt;/math&gt;||\sinh||&lt;math&gt;\textstyle \tanh&lt;/math&gt;||\tanh<br /> |-<br /> | &lt;math&gt;\textstyle \coth&lt;/math&gt;||\coth <br /> |}<br /> Here are a couple examples:<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\textstyle \cos^2 x +\sin^2 x = 1&lt;/math&gt;||\cos^2 x +\sin^2 x = 1<br /> |-<br /> | &lt;math&gt;\cos 90^\circ = 0&lt;/math&gt;||\cos 90^\circ = 0 <br /> |}<br /> <br /> ===Calculus===<br /> Below are examples of calculus rendered in LaTeX. Most of these commands have been introduced before. Notice how definite integrals are rendered (and the difference between regular math and display mode for definite integrals). The , in the integrals makes a small space before the dx.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\frac{d}{dx}\left(x^2\right) = 2x&lt;/math&gt;||\frac{d}{dx}\left(x^2\right) = 2x<br /> |-<br /> | &lt;math&gt;\int 2x\,dx = x^2+C&lt;/math&gt;||\int 2x\,dx = x^2+C<br /> |-<br /> | &lt;math&gt;\int^5_1 2x\,dx = 24&lt;/math&gt;||\int^5_1 2x\,dx = 24<br /> |-<br /> | &lt;math&gt;\int^5_1 2x\,dx = 24&lt;/math&gt;||\int^5_1 2x\,dx = 24<br /> |-<br /> | &lt;math&gt;\frac{\partial^2U}{\partial x^2} + \frac{\partial^2U}{\partial y^2}&lt;/math&gt;||\frac{\partial^2U}{\partial x^2} + \frac{\partial^2U}{\partial y^2}<br /> |-<br /> | &lt;math&gt;\frac{1}{4\pi}\oint_\Sigma\frac{1}{r}\frac{\partial U}{\partial n} ds&lt;/math&gt;||\frac{1}{4\pi}\oint_\Sigma\frac{1}{r}\frac{\partial U}{\partial n} ds<br /> |}<br /> <br /> ===Overline and Underline===<br /> <br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command<br /> |-<br /> |&lt;math&gt;\overline{a+bi}&lt;/math&gt;||\overline{a+bi}<br /> |-<br /> | &lt;math&gt;\underline{431}&lt;/math&gt;||\underline{431}<br /> |}<br /> <br /> ===Other Functions===<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol !! Command!!Symbol !! Command<br /> |-<br /> |&lt;math&gt;\arg&lt;/math&gt;||\arg||&lt;math&gt;\textstyle\deg&lt;/math&gt;||\deg||&lt;math&gt;\textstyle\det&lt;/math&gt;||\det<br /> |-<br /> | &lt;math&gt;\dim&lt;/math&gt;||\dim||&lt;math&gt;\textstyle\exp&lt;/math&gt;||\exp||&lt;math&gt;\textstyle\gcd&lt;/math&gt;||\gcd<br /> |-<br /> |&lt;math&gt;\hom&lt;/math&gt;||\hom||&lt;math&gt;\inf&lt;/math&gt;||\inf||&lt;math&gt;\ker&lt;/math&gt;||\ker<br /> |-<br /> | &lt;math&gt;\textstyle\lg&lt;/math&gt;||\lg||&lt;math&gt;\liminf&lt;/math&gt;||\liminf||&lt;math&gt;\limsup&lt;/math&gt;||\limsup<br /> |-<br /> | &lt;math&gt;\textstyle\max&lt;/math&gt;||\max||&lt;math&gt;\textstyle\min&lt;/math&gt;||\min||&lt;math&gt;\Pr&lt;/math&gt;||\Pr<br /> |-<br /> | &lt;math&gt;\sup&lt;/math&gt;||\sup<br /> |}<br /> Some of these functions take 'bottom' parts just like sums and limits. Some render differently in display mode and regular math mode.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol !! Command!!Symbol !! Command<br /> |-<br /> | &lt;math&gt;\dim_x&lt;/math&gt;||\dim_x||&lt;math&gt;\textstyle\gcd_x&lt;/math&gt;||\gcd_x||&lt;math&gt;\inf_x&lt;/math&gt;||\inf_x<br /> |-<br /> | &lt;math&gt;\liminf_x&lt;/math&gt;||\liminf_x||&lt;math&gt;\limsup_x&lt;/math&gt;||\limsup_x||&lt;math&gt;\textstyle\max_x&lt;/math&gt;||\max_x<br /> |-<br /> | &lt;math&gt;\textstyle\min_x&lt;/math&gt;||\min_x||&lt;math&gt;\Pr_x&lt;/math&gt;||\Pr_x||&lt;math&gt;\sup_x&lt;/math&gt;||\sup_x<br /> |}<br /> <br /> ==Matrices==<br /> We can build an array or matrix with the \begin{array} command, and use \left and \right to properly size the delimiters around the matrix:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> The characteristic polynomial $f(\lambda)$ of the<br /> $3 \times 3$ matrix<br /> $<br /> \left(<br /> \begin{array}{ccc}<br /> a &amp; b &amp; c \\<br /> d &amp; e &amp; f \\<br /> g &amp; h &amp; i \end{array}<br /> \right)$<br /> is given by the equation<br /> $f(\lambda)<br /> = \left|<br /> \begin{array}{ccc}<br /> \lambda - a &amp; -b &amp; -c \\<br /> -d &amp; \lambda - e &amp; -f \\<br /> -g &amp; -h &amp; \lambda - i \end{array}<br /> \right|.$<br /> &lt;/nowiki&gt;<br /> &lt;/pre&gt;<br /> More simply, we can use the shortcut commands in the amsmath package:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> The characteristic polynomial $f(\lambda)$ of the<br /> $3 \times 3$ matrix<br /> $<br /> \begin{pmatrix}<br /> a &amp; b &amp; c \\<br /> d &amp; e &amp; f \\<br /> g &amp; h &amp; i<br /> \end{pmatrix}$<br /> is given by the equation<br /> $f(\lambda)<br /> = \begin{vmatrix}<br /> \lambda - a &amp; -b &amp; -c \\<br /> -d &amp; \lambda - e &amp; -f \\<br /> -g &amp; -h &amp; \lambda - i<br /> \end{vmatrix}.$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> You can read more about how the array command works [[LaTeX:Layout|here]] (it works the same as tabular) and more about using \left and \right [[LaTeX:Commands |here]].<br /> <br /> We can also use this environment to typeset any mathematics that calls for multiple columns, such as funky function definitions like this one:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> $f(x) = \left\{ \begin{array}{ll}<br /> x+7 &amp; \mbox{if 5&lt; x};\\<br /> x^2-3 &amp; \mbox{if -3 \le x \le 5};\\<br /> -x &amp; \mbox{if x &lt; -3}.\end{array} \right.$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> <br /> But it would be better to use the cases environment and \text command that the amsmath package provides:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> $<br /> f(x) = \begin{cases}<br /> x+7 &amp; \text{if 5&lt; x}; \\<br /> x^2-3 &amp; \text{if -3 \le x \le 5};\\<br /> -x &amp; \text{if x &lt; -3}.<br /> \end{cases}<br />$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> <br /> ==Text Styles in Math Mode==<br /> You can render letters in various styles in math mode. Below are examples; you should be able to use these with any letters. The \mathbb requires the amsfonts package to be include in your document's preamble.<br /> {| class=&quot;latextable&quot;<br /> !Symbol !! Command!!Symbol !! Command!!Symbol !! Command!!Symbol !! Comand<br /> |-<br /> |&lt;math&gt;\mathbb{R}&lt;/math&gt;||\mathbb{R}||&lt;math&gt;\mathbf{R}&lt;/math&gt;||\mathbf{R}||&lt;math&gt;\mathcal{R}&lt;/math&gt;||\mathcal{R}||&lt;math&gt;\mathfrak{R}&lt;/math&gt;||\mathfrak{R}<br /> |-<br /> | [[Image:Mathbb1.gif]]||\mathbb{Z}||&lt;math&gt;\mathbf{Z}&lt;/math&gt;||\mathbf{Z}||&lt;math&gt;\mathcal{Z}&lt;/math&gt;||\mathcal{Z}||&lt;math&gt;\mathfrak{Z}&lt;/math&gt;||\mathfrak{Z}<br /> |-<br /> | &lt;math&gt;\mathbb{Q}&lt;/math&gt;||\mathbb{Q}||&lt;math&gt;\mathbf{Q}&lt;/math&gt;||\mathbf{Q}||&lt;math&gt;\mathcal{Q}&lt;/math&gt;||\mathcal{Q}||&lt;math&gt;\mathfrak{Q}&lt;/math&gt;||\mathfrak{Q}<br /> |}<br /> If you're persistent, you can dig a few more out of [ftp://ftp.ams.org/pub/tex/doc/amsfonts/amsfndoc.pdf this document].<br /> <br /> If you want to drop a little bit of text in the middle of math mode, you can use the \text command. The \text command is most useful in &lt;nowiki&gt;$$...$$&lt;/nowiki&gt; or &lt;nowiki&gt;$...$&lt;/nowiki&gt; mode, where breaking up the math mode would force the output on to a new line entirely.<br /> So<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> $$n^2 + 5 = 30\text{ so we have }n=\pm5$$<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> gives<br /> <br /> [[Image:Text1.gif]]<br /> <br /> ==How to Build Your Own Commands==<br /> The command \newcommand is used to create your own commands. We'll start with an example:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> \documentclass[11pt]{article}<br /> \usepackage{amsmath}<br /> <br /> \pdfpagewidth 8.5in<br /> \pdfpageheight 11in<br /> \newcommand{\reci}{\frac{1}{#1}}<br /> \newcommand{\hypot}{\sqrt{#1^2+#2^2}}<br /> \newcommand{\cbrt}{\sqrt{#1}}<br /> <br /> \begin{document}<br /> <br /> The reciprocal of 2 is $\reci{2}$.<br /> <br /> The hypotenuse has length $\hypot{3}{4}$.<br /> <br /> I'm sick of writing $\backslash$sqrt{2}' all the time, just to get $\cbrt{2}$.<br /> <br /> \end{document}<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> The \newcommand declarations are in the preamble. Each is of the form<br /> <br /> \newcommand{name of new command}[number of arguments]{definition}<br /> <br /> The name of the new command, which must begin with a \, is the name you'll use in the document to use the command. The number of arguments is how many inputs will be sent to the command. The definition is just normal LaTeX code, with #1, #2, #3, etc., placed where you want the inputs to go when the new command is called.<br /> <br /> New commands can be used for all sorts of purposes, not just for making math commands you'll use a lot easier to call. For example, try this:<br /> &lt;pre&gt;&lt;nowiki&gt;<br /> \documentclass[11pt]{article}<br /> \usepackage{amsmath}<br /> <br /> \pdfpagewidth 8.5in<br /> \pdfpageheight 11in<br /> \newcounter{prob_num}<br /> \setcounter{prob_num}{1}<br /> \newcommand{\prob}{\bigskip \bigskip\arabic{prob_num}.\stepcounter{prob_num} #1<br /> \par\nopagebreak\medskip A.\ #2\hfill B.\ #3\hfill<br /> C.\ #4\hfill D.\ #5\hfill E.\ NOTA}<br /> <br /> \begin{document}<br /> <br /> \prob{What is $2+2$?}{4}{5}{6}{7}<br /> <br /> \prob{What is $\sqrt{100}$?}{81}{10}{9}{1}<br /> <br /> \prob{Evaluate $\displaystyle\sum_{n=1}^\infty \frac{1}{n^2}$.}<br /> {$\displaystyle\frac{1}{e}$} {$\displaystyle\frac{2}{\pi}$}<br /> {$\displaystyle\frac{\pi^3}{8}$} {$\displaystyle\frac{\pi^2}{6}$}<br /> <br /> \end{document}<br /> &lt;/nowiki&gt;&lt;/pre&gt;<br /> In the example above, we create a new command called \prob. Each time we call \prob, we supply 5 arguments, one for the question and one for each of the multiple choices.<br /> <br /> In the preamble and the definition of \prob, you'll see a few new LaTeX commands:<br /> <br /> \newcounter{prob_num} creates a counter variable called prob_num<br /> <br /> \setcounter{prob_num}{1} setsprob_num to equal 1.<br /> <br /> In the definition of \prob, the \bigskip and \medskip commands create vertical space.<br /> <br /> \arabic{prob_num} prints out the current value of the counter prob_num as an arabic numeral.<br /> <br /> \stepcounter{prob_num} increments the counter prob_num by 1.<br /> <br /> \nopagebreak tells LaTeX not to break the page between the problem and the choices unless it really, really, really has to.<br /> <br /> The \hfill commands put roughly equal space between the choices.<br /> <br /> Once you build a body of custom commands that you will be using in many LaTeX documents, you should learn about [[LaTeX:Packages|creating your own package]] so you don't have to copy all your custom commands from document to document.<br /> <br /> ==See Also==<br /> *[[LaTeX:Packages | Next: Packages]]<br /> *[[LaTeX:Symbols | Previous: Symbols]]<br /> ws</div> Davidkim2106