I'm creating a simple flowchart using Tikz, and I'd really like the "decision" nodes to be lozenge-shaped (think "tilted parallelogram") rather than square, in order to fit text better.      Here's a minimal example, which is only the top part of the flow-chart and so doesn't illustrate the worst of the node in terms of text fit, but does show what I've got as opposed to what I would like, which is the "decision" node shape here:     \documentclass[a4paper]{article}  \usepackage{amsmath}  \usepackage{tikz} \usetikzlibrary{positioning} \usetikzlibrary{shapes.geometric} \usetikzlibrary{arrows,automata}  % Define block styles \tikzstyle{decision} = [diamond, draw, text width=10em, text badly centered, node distance=3cm, inner sep=0pt] \tikzstyle{line} = [draw, -latex'] \tikzstyle{cloud} = [draw, ellipse, node distance=3cm]  \begin{document}  \begin{figure} \begin{center} \begin{tikzpicture} % Nodes   \node[cloud] (a) {$p_n$ is proposed.};   \node[decision, below of=a] (b) {Has a positum $\phi$ been admitted?};   \node[decision, below left of=b] (c) {Is $p_n$ true?};   \node[cloud, below right of=b] (g) {Nothing happens.};  % Edges   \path [line] (a) -- (b);   \path [line] (b) -- node {no}(g);   \path [line] (b) -- node {yes}(c); \end{tikzpicture} \end{center} \end{figure}  \end{document}
I am very new to the TikZ package, and I need to draw some flow chars by using the following shapes.   However I couldn't figure out how to draw the 4th and and 6th ones below. It would be very nice (for completeness) to help with all of the shapes in the list below.      Your help will be greatly appreciated.  Note: I have visited  but it contains some other shapes.
How to count entities with commands/check if there are only one or a certain number of entities or players left? I want to run a command when there are only 10 entities left. I know you can use /execute unless entity to detect when all matching mobs have died, but it doesn't work if you want to run a command when there are for example 10 entities left.  A command like /execute if entity @e[limit=10] does not work, it also triggers if there is only one entity.  Such a counting system could also be used to determine once there is only one player left in an arena, meaning they have won a battle or similar. How to handle client requests to violate copyrights? Many econometrics textbooks (e.g. Wooldridge, "Econometric analysis...") simply write something similar to: "If the population model is $y = xB + u$ and (1) $\text{Cov}(X,U) = 0$; (2) $X'X$ is full rank, then OLS consistently estimate parameters $B$". I've worked out the math behind consistency but I'm a bit lost in interpreting the meaning.  We're talking about consistent estimation, but estimation of what? Please tell me if the following points are correct:   If we have random sample $X,Y$ and $X'X$ is invertible, then we can always define Best Linear Predictor of $y$ given $x$. And then OLS always consistently estimates coefficients of Best Linear Predictor (because in BLP we have $\text{Cov}(u,x)=0$ from the definition). Bottom line: we can always interpret OLS estimates as coefficients of BLP The only question is whether BLP corresponds to conditional expectation $\text{E}(y|x)$. If it does (for which we need $\text{E}(u|x) = 0$), then we can interpret OLS estimates as partial effects.   What is wrong with this or what am I missing? I don't get the point of stating the assumption of $\text{Cov}(u,x) = 0$, if this assumption is by definition fulfilled in case of Best Linear Predictor. And if we want to give structural interpretation to BLP coefficients (partial effects) we need stronger assumption of $\text{E}(u|x) = 0$ anyway. Is there any other interpretation we may have with zero covariance? How to format a duration in java? (e.g format H:MM:SS) Continuum between addition, multiplication and exponentiation? I noticed this  which attempts to find the shades of grey between a linear and log scale where results are between zero and one.  However, I was looking for the more general case where we find the continuum between the operators themselves - add, multiply, and exponentiation or even higher.  The function could be a hyperoperation$(n,x,y)$, where $x$ and $y$ are the numbers to operate on, and $n$ is allowed to be a non-integer number for the type of operator. So $n=1$ would be 'addition', $n=2$ would be multiplication, and $n=3$ would be exponentiation. But one would also have $n=2.5$ to be the shade of grey BETWEEN multiplication and exponentiation, or $n=3.5$ or $4$ for beyond exponentiation and tetration).  I want the formula to work with real numbers, not just integers. Any thoughts?  These related posts may also be of interest: How to use Alt+Shift to switch keyboard layouts? I recently upgraded to Ubuntu 13.10, with the new keyboard handling system. The little "switch keyboard" option does not let me set it to Alt+Shift. How can I get this keyboard binding, as I have absolutely no interest in using the Mac-esque Super+Space combo? Distribution of a ratio of uniforms: What is wrong? Suppose that  $X$ and $Y$ are two i.i.d. uniform random variables on the interval $[0,1]$  Let $Z=X/Y$, I am finding the cdf of $Z$, i.e. $ \Pr(Z\leq z) $.  Now, I came up with two ways of doing this. One produces a correct answer consistent with the pdf here: , the other does not. Why is the second method wrong?  First Method  $\newcommand{\rd}{\mathrm{d}} \Pr(Z\leq z) = \Pr(X/Y\leq z) = \Pr(X\leq zY) = \int^{1}_{0}\int^{\min(1,zy)}_{0} \rd x \rd y = \int^{1}_{0}\min(1,zy)\ \rd y$ $  = \left\{      \begin{array}{lr}        \int^{1/z}_{0}zy\ \rd y + \int^{1}_{1/z} \rd y&amp; : z &gt; 1\\        \int^{1}_{0}zy\ \rd y &amp; : z \leq 1      \end{array}    \right. $ $  = \left\{      \begin{array}{lr}        1 - \frac{1}{2z} &amp; : z &gt; 1\\        \frac{z}{2} &amp; : z \leq 1      \end{array}    \right. $  This appears correct.  Second Method  $\Pr(X/Y\leq z) = \Pr(X \leq zY\ |\ zY \geq 1)\Pr(zY \geq 1) + \Pr(X \leq zY\ |\ zY &lt; 1)\Pr(zY &lt; 1) $ by total probability  $ = \Pr(X \leq zY\ |\ zY \geq 1)\Pr(Y \geq 1/z) + \Pr(X \leq zY\ |\ zY &lt; 1)\Pr(Y &lt; 1/z)$  Taking $z&gt;1$ yields $ (1)(1-\frac{1}{z}) + (\int^{1/z}_{0}\int^{zy}_{0} \rd x \rd y)(\frac{1}{z}) = 1-\frac{1}{z} + (\int^{1/z}_{0}zy\ \rd y)(\frac{1}{z}) = 1-\frac{1}{z} + \frac{1}{2z^{2}}$  This is already different. Why is this wrong?  Thanks! Show that $G$ is cyclic Here is a problem from Herstein.     Let G be a finite abelian group so that the equation $x^n=e$ has at most $n$ solutions in $G$ for every positive integer $n$. Show that $G$ is cyclic.   I will have to basically show that there exists an element $g$ in $G$ having order $o(G)$.   I showed that such an element exists if $o(G)=p_1p_2...p_k$ where $p_i$ are primes. But I could not proceed if $o(G)=p_1^{a_1}p_2^{a_2}$. I feel that if I can prove this I will be able to extend. What's an idiom for doing something in an unnecessarily complicated way? For an example, I'll quote C.S. Lewis' The Voyage of the Dawn Treader:     One day the cat got into the dairy and twenty of them were at work moving all the milk out; no one thought of moving the cat.   Is there an idiom for this type of situation? how do I get my code to use the value of the $HOME variable? I'm trying to put together a generic script that will check the existence of several key directories for various users on different servers. Additionally, I want to leverage each user's $HOME variable.  For eg, let's say this were true:   on server 1: jdoe's home is /home/jdoe  on server 2: jdoe's home is /opt/jdoe2 server 3 hasn't been built yet; we won't know where they build his $HOME until the server is built. on server 4: mysql's home is /opt/home/mysql   This is what I have for my important directories (ordered from most to least impt):  $ cat mylist.txt $HOME/most_impt_dir1 $HOME/most_impt_dir2 $HOME/most_impt_dir3 $HOME/misc $HOME/junk   ...I want to find the most impt dir owned by this user.   Here's what I'm trying:  for i in `cat mylist.txt` do    if [[ -O $i ]] &amp;&amp; [[ -d $i ]]; then     echo "found it: $i"     break   else     echo "$i is not it."   fi  done   The above code does not work for anything in my list because it is literally checking for dirs beginning with $HOME. How do I get my code to use the value of the user's $HOME variable? Why is the colour picker displaying tinted colors? The colour picker is behaving not as I expect it to. I cannot move the selector towards most of the edges, setting the RGB to 1.00 for red and the rest to 0 just gets an orange colour. Also I cannot simply keep the "value" the same and select a different shade, the "value" resets.  I'm not sure if i've pressed something in error or there is a setting in the user preferences/elsewhere that needs changing. I'm using the cycles renderer. The issue occurs with any colour picking :- material, background etc. Quitting Blender and restarting does not resolve the issue. Version 2.79.6 Explanation of unpredictable behaviour of tee I encountered a behaviour that I don't understand while testing a script that sums the outputs from repeated executions of a program. To reproduce it create the text files out, which represents the output of my program, and sum, the file that holds the sum of the values returned on previous executions and which starts out as a copy of out,  cat &gt; out &lt;&lt; EOF 2 20 5 50 EOF cp out sum   The strange thing happens on running  paste out sum | awk '{$1 += $3; $2 += $4; NF = 2; print}' | tee sum   several times (15-20 times might be needed). Each time it runs, this command should add to the values in sum the corresponding values in out and write the results back to sum. What I get is that it works an unpredictable number of times, then sum reverts back to  2 20 5 50   I have later learned that  and solved the issue using a temporary file, still, this behaviour baffles me:   why does … | tee sum work at all (even if only for a limited number of iterations), while … &gt; sum never overwrites sum? why doesn't it work a predictable number of times? What does 5' and 3' mean in DNA and RNA strands? What are 5' and 3' in DNA and RNA strands? Please clarify with some images and please use simple English. Show that there is no solution to the congruence $x^2\equiv3\bmod5$.   I'm not sure if the fact that the only numbers divisible by $5$ are those ending in $0$ or $5$ will help&hellip; Why are rings called rings? Algorithm for computing Hadamard product of two rational generating functions If I have two generating functions $A(x) = \sum_na_nx^n$ and $B(x) = \sum_n b_nx^n$   then the Hadamard product is $(A \star B)(x) = \sum_{n} a_nb_nx^n$.  Now when $A$ and $B$ are both rational functions ($P(x)/Q(x)$ with polynomials $P, Q$) I've seen non-constructive proofs that $A \star B$ is also rational.  Given two rational generating functions $A$, $B$, is there an algorithm that efficiently computes $A \star B$? Or at least a constructive proof you could use to write an algorithm? PHP mail function doesn't complete sending of e-mail How can I install the Social-Engineering Toolkit (SET)? There is this software (SET) from Backtack 5 source that I found out about. But I don't know how to install this thing. Could somebody help me?  Here the link: Any Info on Generalized Binomial and Exponential Series? I was reading Concrete Mathematics by Knuth et al. and on p. 200, it references the generalized binomial series $\mathcal B_t(z)$ and the generalized exponential series $\mathcal E_t(z)$, defined as $$\mathcal B_t(z)=\sum_{k\ge0}(tk)^{\underline{k-1}}\frac{z^k}{k!}\quad\text{and}\quad\mathcal E_t(z)=\sum_{k\ge0}(tk+1)^{k-1}\frac{z^k}{k!},$$ where $x^{\underline k}$ denotes the falling factorial. I was interested in the generalized binomial series because it satisfied the identity $$\frac{\mathcal B_t(z)^r}{1-t+t\mathcal B_t(z)^{-1}}=\sum_{k\ge0}\binom{tk+r}{k}z^k.$$ I've been trying to find a way to compute the sum $\sum_{n\le k\le m}\binom{tk+r}{k}$, so this seemed related. It seems that $\mathcal E_1(z)$ is also somewhat related to the Lambert $W$ function, though I might be wrong. Searching them up online didn't seem to get anywhere, and I just want to find more sources where I can learn about these functions. If anyone can find some resources, I'd appreciate it! There exist several implementations of the GBDT family of model such as:   GBM XGBoost LightGBM Catboost.    What are the mathematical differences between these different implementations?  Catboost seems to outperform the other implementations even by using only its default parameters according to , but it is still very slow.  My guess is that catboost doesn't use the dummified variables, so the weight given to each (categorical) variable is more balanced compared to the other implementations, so the high-cardinality variables don't have more weight than the others. It allows the weak categorical (with low cardinality) to enter to some trees, hence better performance. Other than that, I have no further explanation.