text
stringlengths
14
5.77M
meta
dict
__index_level_0__
int64
0
9.97k
\section{Introduction} In its more than 50 years of history Mixed Integer Programming (MIP) has become an indispensable tool in Operations Research and Management Science. Enormous strides have been made in the theoretical and computational issues arising in solving MIP problems and commercial MIP solvers can solve a wide range of problems \citep{50book}. One of the reasons for the success of MIP is its modeling flexibility. For instance, 0-1 MIP can be used to model disjunctive constraints (i.e. the selection over a finite number of alternatives) appearing in a wide range of applications in transportation \citep{croxton2003comparison,roberti2014fixed}, telecommunication \citep{d2013gub} and scheduling \citep{manne1960job,pinedo2012scheduling}. Formulating problems using MIP is often straightforward. However, as most textbooks warn, some care should be taken in constructing MIP formulations as some formulation attributes can severely affect the effectiveness of solvers. Good formulations can be obtained following simple guidelines, but more elaborate techniques can provide a significant computational advantage \citep{Mixed-Integer-Linear-Programming-Formulation-Techniques}. For instance, consider the classical \emph{Special Ordered Sets of Type 2 (SOS2)} introduced by \cite{Beale70}. SOS2 constraints on variables $\lambda\in \mathbb{R}^{n+1}$ require that (i) $\sum\nolimits_{i=1}^{n+1} \lambda_i=1$ and $\lambda_i\geq 0$ for all $i\in \set{1,\ldots,n+1}$, and (ii) at most two $\lambda_i$ variables can be non-zero at the same time and if $\lambda_i>0$ and $\lambda_j>0$, then they must be adjacent variables (i.e. $\abs{i-j}\leq 1$). A textbook formulation for SOS2 constraints for $n=4$ is given by \begin{subequations}\label{CC1d} \begin{alignat}{3} \sum\nolimits_{j=1}^5 \lambda_j=1,\quad \lambda_j \geq 0 \quad \forall j\in \set{1,\ldots,5}, \quad\sum\nolimits_{i=1}^4 y_i=1,\quad y\in \set{0,1}^4\\ \lambda_1 \leq y_1,\quad \lambda_2\leq y_1+y_2,\quad \lambda_3 \leq y_2+y_3,\quad \lambda_4\leq y_3+y_4,\quad \lambda_5\leq y_4.\label{CC1dg} \end{alignat} \end{subequations} To evaluate this formulation we consider two formulation attributes: formulation size and strength. For size we use the standard measure corresponding to the smallest number of linear inequalities needed to describe the formulation (where we count an equation as two inequalities). Formulation strength can be evaluated in many ways \cite[Section 2.2]{Mixed-Integer-Linear-Programming-Formulation-Techniques}; we choose to check if the formulation satisfies the following property. \begin{definition}[Ideal Formulation] Let $Ax+By \leq b,\quad y\in \mathbb{Z}^k$ be a MIP formulation\footnote{Where $A$, $B$ and $b$ are appropriately sized rational matrices and vector.}. The Linear Programming (LP) relaxation of this formulation is the polyhedron described by $Ax+By \leq b$, which for simplicity we assume has at least one extreme point or basic feasible solution\footnote{For a case in which this assumption is relaxed see \cite{vielma2017small}.}. We say the MIP formulation is \emph{ideal} if and only if all the extreme points of its LP relaxation satisfy the integrality constraints $y\in \mathbb{Z}^k$. \end{definition} Ideal formulations are in a sense \emph{strongest possible} \cite[Section 2.2]{Mixed-Integer-Linear-Programming-Formulation-Techniques} and usually outperform similarly sized non-ideal formulations. Formulation \eqref{CC1d} fares well with regards to size, as its version for general $n$ only requires $2n+6$ inequalities, with $4$ of these coming from equations (the bounds on the $y$ variables are not actually needed). However, this small size comes at the cost of the formulation not being ideal. Indeed, for \eqref{CC1d} to be ideal every extreme point $\bra{\lambda,y}$ of its LP relaxation must satisfy $y\in \mathbb{Z}^4$. The LP relaxation of \eqref{CC1d} is obtained by replaxing $y\in \set{0,1}^4$ by $0\leq y_i\leq 1$ for all $i\in \set{1,\ldots,4}$ and we can check that $\lambda=(1/2,1/2,0,0,0)$ and $y=(1/2,0,1/2,0)$ is an extreme point of this resulting set. Fortunately, \cite{padberg00} showed how to strengthen \eqref{CC1d} to an ideal formulation without increasing the total number of inequalities. For $n=4$ the resulting formulation is given by \begin{subequations}\label{CC1dstrong} \begin{alignat}{3} \sum\nolimits_{j=1}^5 \lambda_j=1,\quad \lambda_1\geq 0,\quad\lambda_5 \geq 0, \quad\sum\nolimits_{i=1}^4 y_i=1,\quad y\in \set{0,1}^4\\ \lambda_1\leq y_1\leq \lambda_1+\lambda_2\leq y_1+y_2\leq \lambda_1+\lambda_2+\lambda_3\leq y_1+y_2+y_3\leq \lambda_1+\lambda_2+\lambda_3+\lambda_4.\label{CC1dstrongg} \end{alignat} \end{subequations} While both formulations have nearly the same size, the majority of the inequalities of \eqref{CC1dstrong} correspond to general inequalities \eqref{CC1dstrongg}, which are not just variable bounds. In contrast, only half the inequalities of \eqref{CC1d} are general inequalities (see Table~\ref{formsizetable} and Corollary~\ref{unaryformulationsos2}). General inequalities usually have a stronger computational impact than variable bounds as the later can be treated implicitly by LP and MIP solvers. Hence the larger number of general inequalities of \eqref{CC1dstrong} can cancel its advantage from being ideal and indeed it is often computationally outperformed by non-ideal formulation \eqref{CC1d}. A solution to this issue can be found in an advanced formulation technique introduced by \cite{Modeling-Disjunctive-Constraints-FULL}. For $n=4$ this technique yields the formulation for SOS2 given by \begin{subequations}\label{LogCC1dstrong} \begin{alignat}{3} \sum\nolimits_{j=1}^5 \lambda_j=1,\quad \lambda_j \geq 0 \quad \forall j\in \set{1,\ldots,5}, \quad y\in \set{0,1}^2\\ \lambda_1+\lambda_5\leq 1-y_1,\quad \lambda_3\leq y_1,\quad \lambda_4+\lambda_5\leq 1-y_2,\quad \lambda_1+\lambda_2\leq y_2. \end{alignat} \end{subequations} This formulation is also ideal, but its version for general $n$ requires around $2\lceil \log_2 n\rceil+n+2$ inequalities and only $2\lceil \log_2 n\rceil+2$ of these are general inequalities (see Corollary~\ref{sosub}). This allows formulation \eqref{LogCC1dstrong} to have a significant computational advantage over \eqref{CC1d}, \eqref{CC1dstrong} and all known formulations for SOS2 \citep{Mixed-Integer-Models-for-Nonseparable,Modeling-Disjunctive-Constraints-FULL}. An even more dramatic issue arises if we consider a 2-dimensional generalization of SOS2 constraints used to model piecewise linear functions of two variables \citep{lee01,Mixed-Integer-Models-for-Nonseparable}. As detailed in Table~\ref{formsizetable}, the cost of going from the non-ideal 2-dimensional generalization of \eqref{CC1d} to the ideal 2-dimensional generalization of \eqref{CC1dstrong} is a significant increase in the number of inequalities, particularly general inequalities. However, the 2-dimensional generalization of formulation \eqref{LogCC1dstrong} still has a linear number of inequalities and a logarithmic number of general inequalities. This again gives it a significant computational advantage over all known formulations for piecewise linear functions of two variables \citep{Mixed-Integer-Models-for-Nonseparable,Modeling-Disjunctive-Constraints-FULL}. \begin{table}[htpb] \begin{center} \bgroup \def\arraystretch{2}% \begin{tabular}{c|ll|ll} & \multicolumn{2} {l|}{Traditional SOS2}& \multicolumn{2} {l}{2-D Generalization}\\ Formulation & General Inequalities &Bounds& General Inequalities &Bounds\\ \hline \eqref{CC1d}& $n+1$ &$n+1$ & $\bra{\sqrt{n/2}+1}^2$ & $\bra{\sqrt{n/2}+1}^2$\\[2ex] \eqref{CC1dstrong}& $2(n-1)$ &$2$& $\dbinom{2\sqrt{n/2}}{\sqrt{n/2}}$ & $\bra{\sqrt{n/2}+1}^2$\\[2ex] \eqref{LogCC1dstrong} & $2\lceil \log_2 n\rceil$ &$[n-1,n+1]$& $4 \left\lceil \log_2 \sqrt{n/2}\right\rceil+ 2$ & $\bra{\sqrt{n/2}+1}^2$\\ \end{tabular} \egroup \end{center} \caption{Sizes of Formulations for SOS2 Constraints and its 2-dimensional Generalization. We omit the number of inequalities from equations, which is $4$ for \eqref{CC1d} and \eqref{CC1dstrong}, and $2$ for \eqref{LogCC1dstrong}.}\label{formsizetable} \end{table} The only dissadvantage of formulation \eqref{LogCC1dstrong} is its increase in complexity. In particular, while for formulations \eqref{CC1d} and \eqref{CC1dstrong} we can easily interpret the role of the $0$-$1$ variables ($y_i=1$ if and only if $\lambda_i$ and $\lambda_{i+1}$ can be non-zero at the same time), the role of the $0$-$1$ variables is not so clear for \eqref{LogCC1dstrong} (for instance it uses two $0$-$1$ variables instead of four). This increase in complexity makes it hard to generalize \eqref{LogCC1dstrong} to other constraints. In fact, the 2-dimensional generalization of \eqref{LogCC1dstrong} only works for very specific piecewise linear functions, while the 2-dimensional generalizations of \eqref{CC1d} and \eqref{CC1dstrong} work for a wide range of piecewise linear functions. In this paper we propose a new MIP formulation paradigm that should allow extending the success of formulation \eqref{LogCC1dstrong} to a wide range of applications. In particular, this paradigm can construct ideal formulations for any disjunctive constraint that requires a set of variables to be in the union of a finite number of polyhedra with mild technical requirements. We denote the formulations obtained through this paradigm \emph{embedding formulations} as they are based on a geometric construction that \emph{embeds} the disjunctive constraints into a higher dimensional space that contains both the original variables in the constraint (e.g. the $\lambda$ variables for SOS2 constraints) and the $0$-$1$ variables of the formulation (e.g. the $y$ variables). One characteristic of embedding formulations is allowing a flexible use of $0$-$1$ variables that include both traditional uses such as in \eqref{CC1d} and \eqref{CC1dstrong}, and more complex uses such as in \eqref{LogCC1dstrong}. This flexibility is the key to replicating the success of \eqref{LogCC1dstrong} as we show that the size of an embedding formulations can be extremely sensitive to the specific use of $0$-$1$ variables. For this reason we also study the size of the smallest embedding formulation for a disjunctive constraint when we consider all possible uses of $0$-$1$ variables. We denote this the embedding complexity of the associated union of polyhedra. This complexity measure has theoretical interest on its own, but can also be used to evaluate the potential for improvement of existing formulations. For instance, studying this complexity allows us to show that \eqref{LogCC1dstrong} is (nearly) optimal with regard to size. To the best of our knowledge, this result is the first lower bound on sizes of \emph{mixed} integer formulations and one of the few results for any class of integer programming formulations. The only other similar results we are aware of are the techniques to show lower bounds on sizes of combinatorial and \emph{pure} integer formulations introduced by \cite{KaibelW15b,weltge2015sizes}. Finally, we show how the embedding formulation paradigm can be used to generalize the 2-dimensional version of \eqref{LogCC1dstrong} to a wider range of piecewise linear functions than what was considered in \cite{Modeling-Disjunctive-Constraints-FULL}. We also show how the resulting formulations can significantly outperform all other known formulations for piecewise linear functions of two variables. This generalization is based on the computational calculation of a convex hull associated to the embedding formulation. To the best of our knowledge, this is the first example of a computational construction of an effective MIP formulation. Throughout the paper we use the following notation. For a set $S\subseteq \mathbb R^d$ we let $\conv\bra{S}$, $\aff\bra{S}$, $\spann\bra{S}$ and $\dim\bra{S}$ be the convex hull, affine hull, linear span and the dimension of $S$ respectively. For a polyhedron $P\subseteq \mathbb R^d$ we let $\ext\bra{P}$ and $\ray\bra{P}$ be the set of extreme points and extreme rays of $P$. We also let $P_\infty$ be the recession cone of $P$. Given two vectors $a, b\in \mathbb R^V$ for a finite index set $V$ we let $a\cdot b=\sum\nolimits_{v\in V} a_v b_v$ be the inner product between $a$ and $b$. We also let ${\bf 0}\in \mathbb R^V$ be the vector of all zeros and $\mathbf{e}^v\in \mathbb R^V$ be the unit vector such that $\mathbf{e}^v_u=1$ if $u=v$ and $\mathbf{e}^v_u=0$ otherwise (The index set $V$ is often evident form the context so we omit it in this notation). Finally, we let $\sidx{n}:=\set{1,\ldots,n}$, $\sidx{a,b}:=\set{a,a+1,\ldots, b-1,b}$ and $\mathbb{Q}$ be the set of rational numbers. \section{Geometric Construction of Formulations}\label{formulationsec} We consider MIP formulations for the disjunctive constraint \begin{equation}\label{disjunction} x\in \bigcup\nolimits_{i=1}^n P^i \end{equation} where $\mathcal{P}:=\bra{P^i}_{i=1}^n$ is a finite family of polyhedra in $\mathbb R^d$ that satisfy the following assumption. \begin{assumption}\label{ass1}The family of polyhedra $\mathcal{P}:=\bra{P^i}_{i=1}^n$ is such that $P^i$ is a rational polyhedron and $\ext\bra{P^i}\neq \emptyset$ for all $i\in \sidx{n}$, and $P^i_\infty=P^j_\infty$ for all $i,j\in \sidx{n}$. \end{assumption} Disjunctive constraint \eqref{disjunction} is exactly the type of practical\footnote{We can also consider unions of polyhedra without extreme points, but this is uncommon in practice.} constraints that can be modeled using $0$-$1$ MIP \citep{springerlink:10.1007/BFb0121015} and MIP formulations for it can be constructed using a wide range of techniques \citep{Mixed-Integer-Linear-Programming-Formulation-Techniques}. For instance, if the polyhedra are described by linear inequalities, the following result from \cite{springerlink:10.1007/BFb0121015,balas85} gives an ideal and small formulation for \eqref{disjunction}. \begin{theorem}\label{BTheo} Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be a finite family of polyhedra in $\mathbb R^d$ satisfying Assumption~\ref{ass1}. Furthermore, for each $i\in\sidx{n}$, let $A^i\in \mathbb{Q}^{m_i\times d}$ and $b^i\in \mathbb{Q}^{m_i}$ be such that $P^i=\set{x\in \mathbb R^d\,:\, A^i x\leq b^i}$. Then an ideal formulation of \eqref{disjunction} is given by \begin{alignat}{3}\label{BalasForm} A^i x^i\leq b^i y_i\quad\forall i\in \sidx{n},\quad x=\sum\nolimits_{i=1}^n x^i,\quad \sum\nolimits_{i=1}^n y_i=1,\quad y\in \set{0,1}^n. \end{alignat} \end{theorem} Formulation \eqref{BalasForm} achieves the feat of being ideal and small through the use of continuous auxiliary variables $x^i\in \mathbb R^d$, which copy the original variables $x$ for each polyhedron. However, these continuous auxiliary variables can take away the potential computational advantage of \eqref{BalasForm}, particularly when small and ideal formulations without the continuous auxiliary variables are available (e.g. formulation \eqref{LogCC1dstrong} for SOS2 constraints). Unfortunately, there is no known general formulation for disjunctive constraints that is small, ideal and does not use these continuous auxiliary variables. To remedy this, we present a general geometric procedure to construct formulations without continuous auxiliary variables that is always ideal and can sometimes yield small formulations. The basic steps of this procedure are depicted in Figure~\ref{embeddingillust} for the polyhedra $P^1$ and $P^2$ in the left of the figure. The first step embeds the polyhedra into a space that contains an additional $0$-$1$ variable $y_1$ by converting the disjunction from $S:=P^1\cup P^2$ to $S^+:=\bra{P^1\times \set{1}} \cup \bra{P^2\times \set{0}}$. The second step takes the convex hull of this embedding to obtain $Q=\conv\bra{S^+}$. By construction we have that $S^+=Q\cap \bra{\mathbb{R}^2\times \mathbb{Z}}$ and hence the projection of $Q\cap \bra{\mathbb{R}^2\times \mathbb{Z}}$ onto the $x$ variables is equal to $S$. Furthermore, by construction we also have that the extreme points of $Q$ have an integral $y_1$ component. Hence, an ideal formulation of $S$ is given by $\bra{x,y_1}\in Q=\conv\bra{S^+}$ and $y_1\in \mathbb{Z}$. Finally, because $Q$ is a rational polyhedron, this formulation contains only linear inequalities with rational coefficients and the integrality constraint on $y_1$. \begin{figure}[htpb] \begin{center} \includegraphics[scale=0.35]{embedding1b.pdf} \end{center} \caption{Two polyhedra (left in red), their embedding into a space with one $0$-$1$ variable (right in red) and the convex hull of this embedding (right in light blue).}\label{embeddingillust} \end{figure} \subsection{Embedding Formulations} One possible generalization of the embedding procedure in Figure~\ref{embeddingillust} to more than two polyhedra is to embed $\bigcup_{i=1}^n P^i$ into $\bigcup_{i=1}^n \bra{ P^i \times \set{\mathbf{e}^i}}$ where $\mathbf{e}^i$ is the $i$-th unit vector. This procedure is known as the \emph{Cayley trick} or \emph{Cayley Embedding} and is used to study Minkowski sums of polyhedra (e.g. \cite{caytrick,karavelas2013maximum,WeibelPhd}). We here consider a further generalization that pairs the polyhedra $P^i$ with any set of pairwise disjoint $0$-$1$ vectors instead of just the unit vectors $\mathbf{e}^i$. The following proposition and its proof shows that the convex hull of the resulting embedding is a rational polyhedron that can be used to construct an ideal formulation of $x\in \bigcup_{i=1}^n P^i$. \begin{proposition}\label{firstprop} Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be a finite family of polyhedra in $\mathbb R^d$ satisfying Assumption~\ref{ass1}, $k\geq \left\lceil \log_2 n\right\rceil$, $H:=\bra{h^i}_{i=1}^n\in \mathcal{H}_k(n):=\set{\bra{h^i}_{i=1}^n\,:\, h^i\in \set{0,1}^k \quad \forall i\in \sidx{n},\quad h^i\neq h^j \quad \forall i\neq j}$ be a family of pairwise distinct $0$-$1$ vectors indexed in the same way as the polyhedra and \begin{equation}\label{embconv} Q\bra{\mathcal{P},H}:=\conv\bra{\bigcup\nolimits_{i=1}^n P^i\times \set{h^i} }. \end{equation} Then \begin{enumerate}[(i)] \item\label{rationalLPprop} $Q\bra{\mathcal{P},H}$ is a rational polyhedron, \item\label{validprop} $ \bra{x,y}\in Q\bra{\mathcal{P},H} \cap \bra{\mathbb R^d\times\mathbb Z^k} \quad \Leftrightarrow \quad\exists i\in \sidx{n} \text{ s.t. } y=h^i\;\wedge\; x\in P^i,$ and \item\label{idealprop} $\ext\bra{Q\bra{\mathcal{P},H}}\subseteq \mathbb R^d\times \set{0,1}^k$. \end{enumerate} \end{proposition} \proof{Proof.} By Assumption~\ref{ass1}, $\set{P^i\times \set{h^i}}_{i=1}^n$ is a finite family of non-empty polyhedra with identical recession cones. Then, by Lemma 4.41 and Corollary 4.44 in \cite{conforti2014integer}, $Q\bra{\mathcal{P},H}$ is a rational polyhedron and $Q\bra{\mathcal{P},H}=\conv\bra{\bigcup_{i=1}^n \bigcup_{v\in \ext\bra{P^i} }\set{v\times h^i}}+\cone\bra{ \bigcup_{r\in \ray\bra{P^1} }\set{r\times {\bf 0}}}$. This shows the first two properties of $Q\bra{\mathcal{P},H}$. The last follows by additionally noting that the $h^i$'s are distinct extreme points of $[0,1]^k$. \Halmos\endproof Similarly to the example depicted in Figure~\ref{embeddingillust} we obtain a formulation from $Q\bra{\mathcal{P},H}$ by interpreting $H$ as possible values of a $k$-dimensional $0$-$1$ variable $y$. \begin{corollary}[Embedding Formulation]\label{embeddingformdef} Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be a finite family of polyhedra in $\mathbb R^d$ satisfying Assumption~\ref{ass1}, $k\geq \left\lceil \log_2 n\right\rceil$ and $H\in \mathcal{H}_k(n)$. Then an ideal formulation of $x\in \bigcup_{i=1}^n P^i$ is given by \begin{equation}\label{embformeq} \bra{x,y}\in Q\bra{\mathcal{P},H},\quad y\in \mathbb{Z}^k. \end{equation} Furthermore, besides the integrality constraints on $y$, this formulation only includes linear inequalities with rational coefficients. We refer to \eqref{embformeq} as the \emph{embedding formulation} of $\mathcal{P}$ associated to $H$, to $H$ as the \emph{encoding} of the formulation and to $Q\bra{\mathcal{P},H}$ as the \emph{LP relaxation} of the formulation. \end{corollary} \proof{Proof.} The formulation is valid because of property \eqref{validprop} in Proposition~\ref{firstprop}, includes only linear inequalities with rational coefficients because of property \eqref{rationalLPprop} in Proposition~\ref{firstprop}, and is ideal because of property \eqref{idealprop} in Proposition~\ref{firstprop}. \Halmos\endproof Encoding $H$ can have a strong impact in the size of $Q\bra{\mathcal{P},H}$, but different encodings can yield formulations of the same size or even equivalent polyhedra $Q\bra{\mathcal{P},H}$. The following straightforward lemma shows one such possible equivalency. \begin{lemma}\label{isolemma} Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be a finite family of polyhedra in $\mathbb R^d$ satisfying Assumption~\ref{ass1}, $k_1,k_2\geq \left\lceil \log_2 n\right\rceil$, $H\in \mathcal{H}_{k_1}(n)$ and $G\in \mathcal{H}_{k_2}(n)$. If there exists an affine map $A:\mathbb R^{k_1}\to \mathbb R^{k_2}$ such that $A$ is a bijection between $\conv\bra{H}$ and $\conv\bra{G}$ then $Q\bra{\mathcal{P},H}$ is affinely isomorphic to $Q\bra{\mathcal{P},G}$. In particular, if $H:=\bra{h^i}_{i=1}^n$ where $h^i=\mathbf{e}^i$ for all $i\in \sidx{n}$, and $G:=\set{g^i}_{i=1}^n$ where $g^i=\mathbf{e}^{\pi(i)}$ for all $i\in \sidx{n}$ and $\pi:\sidx{n}\to \sidx{n}$ is a permutation, then \[\bra{x,y}\in Q\bra{\mathcal{P},G} \quad \Leftrightarrow \quad \bra{x,y^\pi}\in Q\bra{\mathcal{P},H} \] where $y^\pi_{\pi\bra{i}}=y_i$ for all $i\in \sidx{n}$. \end{lemma} Lemma~\ref{isolemma} shows that when the encoding uses $n$ unit vectors $\mathbf{e}^i\in \set{0,1}^n$ the specific order or polytope-vector assignment in the embedding is inconsequential. Hence, when an encoding of this form is used we assume the unit vectors are assigned in their natural order and refer to the resulting embedding formulation as the \emph{unary encoded} formulation as this encoding can be interpreted as a \emph{unary encoding} of the selection among the polyhedra. A completely different class of encodings are obtained when $n$ is a power of $2$ and $\bra{h^i}_{i=1}^n=\set{0,1}^k$ for $k=\log_2 n$. This case can be interpreted as a \emph{binary encoding} of the selection among the polyhedra and corresponds to the encodings with the smallest number of components or \emph{bits}. For this reason we refer to embedding formulations resulting from such encodings as \emph{binary encoded} formulations. Unlike unary encoded formulations, in Section~\ref{SOS2} we show that permuting the order of a binary encoding can lead to binary encoded formulations of significantly different sizes. This potential size variability over binary and other encodings motivates the following complexity measure for unions of polyhedra, which quantifies the size of its smallest embedding formulation. \begin{definition}[Embedding Complexity] For a polyhedron $Q$ let $\size(Q)$ be equal to the minimum number of inequalities needed to describe $Q$ (equations are counted as two inequalities). Then, for a family of polyhedra $\mathcal{P}:=\bra{P^i}_{i=1}^n$ satisfying Assumption~\ref{ass1} we let its \emph{embedding complexity} be \[\mmc\bra{\mathcal{P}}:=\min\set{\size\bra{Q\bra{\mathcal{P},H}}\,:\, H\in \bigcup\nolimits_{k\geq \left\lceil \log_2 n\right\rceil} \mathcal{H}_k(n) }.\] \end{definition} Constructing an embedding formulation even for a fixed $H$ requires a potentially costly convex hull calculation. Calculating the embedding complexity has the added difficulty of minimizing the size of these convex hulls over all possible encodings. Fortunately, as we show in the following sections it is sometimes possible to give tight bounds on the embedding complexity of specially structured disjunctions such as SOS2 constraints. We also show how we can computationally construct embedding formulations for piecewise linear functions that can provide a significant computational advantage. In both these cases the unions of polyhedra considered have a special combinatorial structure (specifically, all polyhedra are faces of a fixed simplex). For an example of how embedding formulations can lead to a computational advantage for disjunctions without this special structure we refer the reader to \cite{huchette2016strong}. \section{Bounds on embedding complexity for SOS2 constraints}\label{SOS2} SOS2 constraints can be posed as a disjunctive constraint of the form \eqref{disjunction} as follows. \begin{definition} Let $\Delta^{n+1}:=\set{\lambda\in \mathbb R^{n+1}_+\,:\, \sum_{i=1}^{n+1} \lambda_j=1}$. A family of polyhedra $\mathcal{P}:=\bra{P^i}_{i=1}^n$ in $\mathbb R^{n+1}$ is the special ordered sets of type 2 or SOS2 constraint on $\Delta^{n+1}$ if and only if \[ P^i:=\set{\lambda\in \Delta^{n+1}\,:\, \lambda_j\leq 0\quad \forall j\not\in \set{i,i+1}}=\conv\bra{\set{\mathbf{e}^i,\mathbf{e}^{i+1}}}.\] \end{definition} To fully characterize embedding formulations for SOS2 constraints we need to consider the possibility of an encoding not being full dimensional (i.e. $H\in\mathcal{H}_k(n)$ and $\dim(H)<k$), which we handle through the following definition. \begin{definition}For $H:=\bra{h^i}_{i=1}^n$, let $L\bra{H}:=\aff\bra{H}-h^1$ be the linear space parallel to the affine hull of $H$. \end{definition} The following proposition shows that the size and structure of the inequalities of $ Q\bra{\mathcal{P},H}$ have a relatively simple description for SOS2 constraints. \begin{restatable}{proposition}{sosprophyperprop}\label{sos1prophyper}Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be the SOS2 constraint on $\Delta^{n+1}$, $H:=\bra{h^i}_{i=1}^n\in \mathcal{H}_k(n)$, $c^i=h^{i+1}-h^i$ for $i\in \sidx{n-1}$ and for $b\in L(H)\setminus \set{\bf 0}$ let $M(b):=\set{y\in L(H)\,:\, b\cdot y=0}$ be the linear (or central) hyperplane defined by $b$ in $L(H)$. Finally, let $\set{b^l}_{l=1}^L\subseteq L(H)\setminus \set{\bf 0}$ be such that $\set{M\bra{b^l}}_{l=1}^{L}$ is the set of linear hyperplanes spanned by $\bra{c^i}_{i=1}^{n-1}$ in $L(H)$ and $J=\set{1,n+1}\cup \set{j\in \sidx{2,n}\,:\, L\bra{H}=\spann\bra{\set{c^i}_{i\in \sidx{n-1}\setminus\set{j-1} }}} $. Then $\bra{\lambda,y}\in Q\bra{\mathcal{P},H}$ if and only if \begin{subequations}\label{SOS2char} \begin{alignat}{3} \sum\nolimits_{j=1}^{n+1} \lambda_j =1,\quad y&\in \aff\bra{H}\label{sos2equalities}\\ \sum\nolimits_{j=1}^{n+1} \min\set{{b^l\cdot h^j} ,{b^l\cdot h^{j-1}}}\lambda_j \leq b^l\cdot y &\leq \sum\nolimits_{j=1}^{n+1} \max\set{{b^l\cdot h^j} ,{b^l\cdot h^{j-1}}}\lambda_j &\quad&\forall l \in \sidx{L}\label{sos2generalfacets}\\ \lambda_j&\geq 0 &\quad& \forall j\in J\label{sos2boundfacets}, \end{alignat} \end{subequations} where we let $h^0=h^1$ and $h^{n+1}=h^n$. Furthermore, $\dim\bra{Q\bra{\mathcal{P},H}}=n+\dim\bra{H}$, equations \eqref{sos2equalities} precisely describe $\aff\bra{Q\bra{\mathcal{P},H}}$ and all inequalities in \eqref{sos2generalfacets} and \eqref{sos2boundfacets} are facet defining for $Q\bra{\mathcal{P},H}$. Finally, none of the facets defined by \eqref{sos2generalfacets} can be defined by a variable bound on $\lambda$. \end{restatable} The proof of Proposition~\ref{sos1prophyper} is slightly technical and follows from a complete characterization of the facial structure of $ Q\bra{\mathcal{P},H}$ for SOS2 constraints, so we postpone it to Section~\ref{proofofsos1prophyper}. One notable characteristic of \eqref{SOS2char} is the simple form of the inequalities. However, this simplicity hides the possibility of discovering rather complicated formulations whose validity is not straightforward. Indeed, combining Proposition~\ref{sos1prophyper} and Corollary~\ref{embeddingformdef} we have that a valid (and ideal) formulation for SOS2 constraints is $\bra{\lambda,y}$ satisfy \eqref{SOS2char} and $y\in \mathbb{Z}^k$. We can easily check that $\bra{\lambda,y}=\bra{\mathbf{e}^j,h^i}$ is feasible for this formulation if $j\in\set{i,i+1}$. The converse can sometimes be easily verified for encodings with a specific structure, but is not evident from generic formulation \eqref{SOS2char}. To complicate matters further, this converse does not directly imply infeasibility of $\bra{\lambda,y}=\bra{1/2}\bra{\mathbf{e}^j,h^i}+\bra{1/2}\bra{\mathbf{e}^l,h^i}$ for $j\in\set{i,i+1}$ and $l\notin\set{i,i+1}$, which is also required for validity of the formulation. In Section~\ref{examplesection} give an example of how even for fixed $n$ and $H$ it may not be straightforward to verify validity of the formulation based on \eqref{SOS2char} \emph{directly} (i.e. without using Corollary~\ref{embeddingformdef} and the fact that \eqref{SOS2char} describes $ Q\bra{\mathcal{P},H}$). This example illustrates how the embedding formulation procedure can be useful to discover or construct unexpected formulations whose validity is not immediately evident. Besides constructing unexpected formulations, Proposition~\ref{sos1prophyper} allows us to recover existing formulations and determine that one of these is the smallest embedding formulation for SOS2 constraints. Characterization \eqref{SOS2char} of $ Q\bra{\mathcal{P},H}$ considers two classes of facets: those defined by variable bounds \eqref{sos2boundfacets} and those defined by more general inequalities \eqref{sos2generalfacets}. As noted in the introduction the computational cost of variable bounds tends to be smaller so we refine our notion of formulation size to consider this in our analysis. \begin{definition} Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be the SOS2 constraint on $\Delta^{n+1}$ and $H:=\bra{h^i}_{i=1}^n\in \mathcal{H}_k(n)$. We let $\size_G\bra{Q\bra{\mathcal{P},H}}$ and $\size_B\bra{Q\bra{\mathcal{P},H}}$ be the number of inequalities in \eqref{sos2generalfacets} and \eqref{sos2boundfacets} respectively so that $\size\bra{Q\bra{\mathcal{P},H}}=\size_G\bra{Q\bra{\mathcal{P},H}}+\size_B \bra{Q\bra{\mathcal{P},H}}+2\bra{1+k-\dim\bra{H}}$. Finally, we let $\mmc_G\bra{\mathcal{P}}:=\min\set{\size_G\bra{Q\bra{\mathcal{P},H}}\,:\, H\in \bigcup\nolimits_{k\geq \left\lceil \log_2 n\right\rceil} \mathcal{H}_k(n) }$. \end{definition} The first formulation we can recover with Proposition~\ref{sos1prophyper} is the ideal formulation introduced in \cite{padberg00} that was illustrated in \eqref{CC1dstrong}. \begin{corollary}\label{unaryformulationsos2}Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be the SOS2 constraint on $\Delta^{n+1}$ and $H$ be the unary encoding, then $\bra{\lambda,y}\in Q\bra{\mathcal{P},H}$ if and only if \begin{subequations}\label{padbergform2} \begin{alignat}{3} \sum\nolimits_{j=1}^{n+1} \lambda_j=1, \quad\sum\nolimits_{i=1}^n y_i&=1,\quad y\in \set{0,1}^n, &\quad& \\ \sum\nolimits_{j=l+2}^{n+1} \lambda_j \leq \sum\nolimits_{i=l+1}^n y_i,\quad \sum\nolimits_{j=1}^{l} \lambda_j& \leq \sum\nolimits_{i=1}^l y_i &\quad&\forall l \in \sidx{n-1}\label{unaryineq1}\\ \lambda_1\geq 0,\quad \lambda_{n+1}&\geq 0.\label{unaryineq2} \end{alignat} \end{subequations} Furthermore, all inequalities in \eqref{unaryineq1}--\eqref{unaryineq2} are facet defining and hence $\size\bra{Q\bra{\mathcal{P},H}}=2n+4$, $\size_G\bra{Q\bra{\mathcal{P},H}}=2(n-1)$ and $\size_B\bra{Q\bra{\mathcal{P},H}}=2$. \end{corollary} \proof{Proof.} For the unary encoding we have $c^i=\mathbf{e}^{i+1}-\mathbf{e}^i$ for all $i\in \sidx{n-1}$ and hence $L(H)=\set{y\in \mathbb R^{n}\,:\,\sum_{j=1}^{n}y_j=0}$. Furthermore, the set of hyperplanes spanned by $\bra{c^i}_{i=1}^{n-1}$ is $\set{M\bra{b^l}}_{l=1}^{L}$ for $L=n-1$ and $b^l=\bra{n-l}\sum_{i=1}^l \mathbf{e}^i - l\sum_{i=l+1}^n \mathbf{e}^i$ for each $l\in \sidx{L}$. Finally, the elements of $\bra{c^i}_{i=1}^{n-1}$ are linearly independent and hence $J=\set{1,n+1}$ and \eqref{SOS2char} for the unary encoding becomes \begin{subequations}\label{padbergform} \begin{alignat}{3} \sum\nolimits_{j=1}^{n+1} \lambda_j=1, \quad\sum\nolimits_{i=1}^n y_i=1,\quad &y\in \set{0,1}^n\\ \label{padberg1}(n-l){\sum\nolimits_{j=1}^l \lambda_j}-l{\sum\nolimits_{j=l+1}^{n+1}\lambda_j}&\leq (n-l){\sum\nolimits_{i=1}^l y_i}-l{\sum\nolimits_{i=l+1}^n y_i}&\quad& \forall l\in \sidx{n-1}\\ \label{padberg2}(n-l){\sum\nolimits_{i=1}^l y_i}-l{\sum\nolimits_{i=l+1}^n y_i}&\leq (n-l){\sum\nolimits_{j=1}^{l+1} \lambda_j}-l{\sum\nolimits_{j=l+2}^{n+1}\lambda_j} &\quad& \forall l\in \sidx{n-1}.\\ \lambda_1\geq 0,\quad \lambda_{n+1}&\geq 0. \end{alignat} \end{subequations} If we subtract $n-l$ times the implied equation $\sum_{i=1}^n y_i=\sum_{j=1}^{n+1} \lambda_j$ from \eqref{padberg2} and divide by $n$, and add $l$ times this same implied equation to \eqref{padberg1} and divide by $n$ we have that \eqref{padbergform} is equivalent to \eqref{padbergform2}. \Halmos\endproof We can also use Proposition~\ref{sos1prophyper} to recover and generalize the logarithmic formulation from \cite{Modeling-Disjunctive-Constraints-FULL} that we illustrated in \eqref{LogCC1dstrong}. For that we need the following special class of binary encodings with adjacent elements (in the order induced by the SOS2 constraints) that only differ in one bit or coordinate. \begin{definition}\label{graycodecoro} We say $H=\bra{h^i}_{i=1}^n\in \mathcal{H}_{\lceil \log_2 n\rceil}(n)$ is a \emph{gray code} if and only if for all $i\in \sidx{ n-1}$ we have $\sum\nolimits_{j=1}^{\lceil \log_2 n\rceil} \abs{h^{i}_j-h^{i+1}_j}=1$. \end{definition} The following corollary shows that formulation \eqref{SOS2char} for a gray code is precisely the logarithmic formulation when $n$ is a power of two and otherwise eliminates some redundancy of the logarithmic formulation (see \cite{MuldoonPhd} for an alternate derivation and discussion about this redundancy). \begin{corollary}\label{sosub} Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be the SOS2 constraint on $\Delta^{n+1}$ and $H$ be a gray code, then $\bra{\lambda,y}\in Q\bra{\mathcal{P},H}$ if and only if \begin{subequations}\label{sos2formul} \begin{alignat}{3} \sum\nolimits_{j=1}^{n+1} \lambda_j &=1\label{sos2eqqq}\\ \sum\nolimits_{j=1}^{n+1} \min\set{h^j_l,h^{j-1}_l}\lambda_j\leq y_l &\leq \sum\nolimits_{j=1}^{n+1} \max\set{h^j_l,h^{j-1}_l}\lambda_j &\quad&\forall l \in \sidx{\left\lceil \log_2 n\right\rceil}\label{sos2formulgeneral}\\ \lambda_j&\geq 0 &\quad& \forall j\in \sidx{n+1}.\label{sos2formulbound} \end{alignat} \end{subequations} where we let $h^0=h^1$ and $h^{n+1}=h^n$. Furthermore, all inequalities in \eqref{sos2formulgeneral} are facet defining and hence $\size_G\bra{Q\bra{\mathcal{P},H}}=2\left\lceil \log_2 n\right\rceil$. In addition, at least $n-1$ of the inequalities in \eqref{sos2formulbound} are facet defining and hence $\abs{\size_B\bra{Q\bra{\mathcal{P},H}} - n}\leq 1$ and $\abs{\size\bra{Q\bra{\mathcal{P},H}}- \bra{2\left\lceil \log_2 n\right\rceil + n +2}}\leq 1$. Finally, these last two bounds are tight. \end{corollary} \proof{Proof.} For any gray code $c^i\in \bigcup_{j=1}^{\left\lceil \log_2 n\right\rceil}\set{-\mathbf{e}^j,\mathbf{e}^j}$ for each $i\in \sidx{n-1}$ and $L(H)=\mathbb R^{\left\lceil \log_2 n\right\rceil}$. Hence, the set of hyperplanes spanned by $\bra{c^i}_{i=1}^{n-1}$ is $\set{M\bra{b^l}}_{l=1}^{L}$ for $L=\left\lceil \log_2 n\right\rceil$ and $b^l= \mathbf{e}^i$ for each $l\in \sidx{L}$. This yields the results concerning non-bound inequalities. For the bound on the number of facet defining inequalities in \eqref{sos2formulbound} note that $L\bra{H}\neq\spann\bra{\set{c^i}_{i\in \sidx{n-1}\setminus\set{j-1} }}$ if and only if there exist $l\in \sidx{\left\lceil \log_2 n\right\rceil}$ such that $\abs{c^{j-1}}=\mathbf{e}^l$ and $\abs{c^{i}}\neq \mathbf{e}^l$ for all $i\in \sidx{n-1}\setminus\set{j-1}$. Then, the number of inequalities $\lambda_j\geq 0$ which fail to be facet defining is the number of bits that only change once in $H$, which is given by \[T_n^1(H):=\abs{\set{l\in \sidx{\left\lceil \log_2 n\right\rceil}\,:\, \exists i_0\in \sidx{n-1} \text{ s.t. } h^{i_0}_l\neq h^{i_0+1}_l \text{ and } h^i_l=h^{i+1}_l \quad \forall l\in \sidx{n-1}\setminus \set{i_0}}}.\] To show that $T_n^1(H)\leq 2 $ assume for a contradiction that $n\geq 3$ and $T_n^1(H)\geq 3 $. Without loss of generality we may assume there exist $0=i_0< i_1<i_2<i_3<i_4=n$ such that for all $l\in \sidx{3}$ we have $h^{i}_l=1$ for all $i\in \sidx{i_l}$ and $h^i_{l}=0$ for all $i\in \sidx{i_l+1,n}$. Let $k=\lceil \log_2 n\rceil$ be the dimension or number of bits of $H$ so that $n\geq 2^{k-1}+1$. Then, because the indices $i_1,i_2,i_3$ divide $H$ into $4=2^2$ sets, there exits $l\in\sidx{4}$ such that $i_l-i_{l-1}\geq \left\lceil \bra{2^{k-1}+1}/4\right \rceil =2^{k-3}+1$. However, because $h^i\neq h^j$ and $h^i_l=h^j_l$ for all $l\in \sidx{3}$ and $i,j\in \sidx{i_{l-1}+1,i_l}$, we must have $2^{k-3}\geq i_l-i_{l-1}\geq 2^{k-3}+1$ which yields a contradiction. For the tightness of the bounds note that for $H=\bra{(0,0)^T,(1,0)^T,(1,1)^T}$ we have $T_n^1(H)=2$ and for $H=\bra{(1,0,0)^T,(1,1,0)^T,(0,1,0)^T,(0,1,1)^T,(1,1,1)^T,(1,0,1)^T,(0,0,1)^T,(0,0,0)^T}$ we have $T_n^1(H)=0$. Finally, we recover the logarithmic formulation when $n$ is a power of two (e.g. formulation (9) in \cite{Modeling-Disjunctive-Constraints-FULL}) by subtracting \eqref{sos2eqqq} from the second inequality in \eqref{sos2formulgeneral}, noting that $ \min\set{h^j_l,h^{j-1}_l}=1$ if $h^j_l=h^{j-1}_l=1$ and $ \min\set{h^j_l,h^{j-1}_l}=0$ otherwise, and noting that $1-\max\set{h^j_l,h^{j-1}_l}=1$ if $h^j_l=h^{j-1}_l=0$ and $1-\max\set{h^j_l,h^{j-1}_l}=0$ otherwise. \Halmos\endproof Finally, we can use Proposition~\ref{sos1prophyper} to give tight bounds on the embedding complexity of SOS2 constraints, which show that the logarithmic formulation from Corollary~\ref{sosub} is (nearly) optimal. \begin{proposition}\label{sosboundcoro}Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be the SOS2 constraint on $\Delta^{n+1}$, then \begin{itemize} \item $\mmc_G\bra{\mathcal{P}}=2\lceil \log_2 n\rceil$, and \item $n+3+\lceil \log_2 n\rceil\leq \mmc\bra{\mathcal{P}}\leq n+3 +2\lceil \log_2 n\rceil$. \end{itemize} \end{proposition} \proof{Proof.} Let $\set{b^l}_{l=1}^L\subseteq L(H)\setminus \set{\bf 0}$ be such that $\set{M\bra{b^l}}_{l=1}^{L}$ is the set of linear hyperplanes spanned by $\set{c^i}_{i=1}^{n-1}$ in $L(H)$. By Proposition~\ref{sos1prophyper} an easy upper bound on the number of variable bounds $\lambda_j\geq 0$ that are not facet defining is $L$, which is achieved precisely if for all $l\in \sidx{L}$ there is only one $i\in \sidx{n-1}$ such that $b^l\cdot c^i\neq 0$. Hence we have $\size\bra{Q\bra{\mathcal{P},H}}\geq 2+2L+n+1-L=n+3+L$. Then, to obtain a lower bound on both $\mmc_G\bra{\mathcal{P}}$ and $\mmc\bra{\mathcal{P}}$ we need to minimize $L$. For that we note that $L$ is equal to the number of $1$-flats of the (central) hyperplane arrangement $\set{\set{b\in L(H)\,:\, c^i\cdot b =0}}_{i=1}^{n-1}$ in $L(H)$. Because $\spann\bra{\set{c^i}_{i=1}^{n-1}}=L(H)$ the number of such $1$-flats is at least $\dim(L(H))=\dim(H)$. Because all elements of $H$ are pairwise distinct we have that $L\geq \dim(H)\geq \lceil \log_2 n\rceil$, which yields the lower bounds. The upper bounds follow from Corollary~\ref{sosub}. \Halmos\endproof The smallest size embedding formulation is achieved through the use of a very specific class of binary encoding. In the following section we explore how rare this class is with respect to yielding small embedding formulations. \subsection{Size distribution for binary encodings}\label{graphsec} If $n=2^k$ for some $k\in \mathbb Z$, $\mathcal{P}:=\bra{P^i}_{i=1}^n$ is the SOS2 constraint and $H\in \mathcal{H}_{k}(n)$, then Proposition~\ref{sos1prophyper} shows that the number of facets of $Q\bra{\mathcal{P},H}$ defined by general inequalities \eqref{sos2generalfacets} is upper bounded by $2 \binom{n-1}{k-1}$. The following proposition suggests that this upper bound may be nearly achieved. We include a proof of this result in Section~\ref{omproofapendix}. \begin{restatable}{proposition}{antigraylemmaLem}\label{antigraylemma}Let $n=2^k$ for some $k\in \mathbb Z$ and $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be the SOS2 constraint. There exist $H\in \mathcal{H}_{k}(n)$ such that $\size_G\bra{Q\bra{\mathcal{P},H}}$ is equal to twice the number of affine hyperplanes spanned by $\set{0,1}^{k-1}$. \end{restatable} It is believed that the number of affine hyperplanes spanned by $\set{0,1}^{k-1}$ is close to its trivial upper bound of $\binom{n/2}{k-1}$ for $n=2^k$ (e.g. \cite{aichholzer1996classifying}). Both this upper bound and the general-inequality-defined facet bound of $2\binom{n-1}{k-1}$ grow roughly as $n^{\log_2n}$\footnote{We have $\Omega\bra{n^{(1-\varepsilon) \log_2 n}}=\binom{n/2}{k-1}\leq \binom{n-1}{k-1}\leq n^{\log_2 n}$ for all $\varepsilon>0$.}, which suggests that the worst case of $\size_G\bra{Q\bra{\mathcal{P},H}}$ for a binary encoded formulation is quasi-polynomial in $n$. Hence, it seems like an unfortunate selection of the specific binary encoding can lead to a formulation that is significantly larger than the lower bound from Proposition~\ref{sosboundcoro} or even the size of the unary encoded formulation from Corollary~\ref{unaryformulationsos2}. Because of its link with the number of hyperplanes spanned by subsets of $\set{0,1}^{k-1}$ (or $\set{-1,0,1}^{k-1}$), understanding the typical size of a binary encoded embedding formulation for SOS2 constraints may prove extremely challenging (e.g. \cite{voigt2006singular}). For this reason we only pursue a simple empirical study of the distribution of sizes for these formulations. For this study we selected $k\in \sidx{3,6}$ and calculated $\size_G\bra{Q\bra{\mathcal{P},H}}$ for randomly selected binary encodings (the ones associated to a random permutation of $\set{0,1}^{k}$). For $k=3$ we considered all $40,320$ possible encodings, while for $k\in \set{4,5}$ we only used a random sample of $10,000$ encodings and for $k=6$ we only used a random sample of $1,000$ encodings (calculating the formulation sizes for $k=6$ was already computational intensive). The results of this study are presented in Figure~\ref{randomfigure}. \begin{figure}[htpb] \begin{center} \includegraphics[scale=0.37]{sos2.pdf} \end{center} \caption{$\size_G\bra{Q\bra{\mathcal{P},H}}$ for $k\in \sidx{3,6}$ and randomly selected binary encodings.}\label{randomfigure} \end{figure} The figure presents histograms for $\size_G\bra{Q\bra{\mathcal{P},H}}$ with random binary encoding $H$ for each $k$, together with the trivial upper bound of $2 \binom{n-1}{k-1}$ (depicted by the solid red line), $\size_G\bra{Q\bra{\mathcal{P},H}}$ for the unary encoding (depicted by the dotted blue line) and $\size_G\bra{Q\bra{\mathcal{P},H}}$ for the optimal binary encoded formulation (depicted by the dashed green line). The figure shows that the typical value of $\size_G\bra{Q\bra{\mathcal{P},H}}$ for a binary encoding seems to be much closer to the upper bound and suggests that a randomly selected encoding may often lead to a formulation that is significantly larger than even the unary encoded formulation. Hence a careful encoding selection appears crucial to obtain a small formulation. \section{Formulations for Piecewise Linear Functions of Two Variables}\label{pwlsecc} The results in Section~\ref{graphsec} show that it may be hard to construct small embedding formulations. However, we now show how small embedding formulations can be constructed for multivariate piecewise linear functions. MIP formulations for multivariate piecewise linear functions can be constructed using standard generalizations of SOS2 constraints (e.g. \cite{lee01,Modeling-Disjunctive-Constraints-FULL,Mixed-Integer-Models-for-Nonseparable}). For simplicity, we only consider formulations for piecewise linear functions of two variables defined on grid triangulations on $\sidx{m+1}^2$ such as those depicted in Figure~\ref{newpwl2fig}. More precisely, we consider functions $f:[1,m+1]^2\to \mathbb R$ that are continuous in $[1,m+1]^2$ and affine in each triangle of the triangulation (e.g. for the triangulation in Figure~\ref{newpwl2fig2} it is affine in $\conv\bra{\set{\bra{1,1},\bra{1,2},\bra{2,2}}}$). \begin{figure}[htpb] \begin{center} \subfigure[Piecewise Linear Function on the Union-Jack Triangulation for $m=8$]{\label{newpwl2fig1}\includegraphics[scale=0.3]{PWL.pdf}}\quad\quad\quad \subfigure[The Union-Jack Triangulation for $m=2$.]{\label{newpwl2fig2}\includegraphics[scale=0.2]{triang2.pdf}} \end{center} \caption{Piecewise Linear Functions of Two Variables and Grid Triangulations.}\label{newpwl2fig} \end{figure} The following proposition summarizes the standard generalization of SOS2 constraints used to give a disjunctive representation of the graph of a piecewise linear function. It also describes how an embedding formulation can be used to model the corresponding disjunctive constraint and yield a formulation for the graph of this function. \begin{proposition}\label{PWLFORMPROP}Let $\mathcal{T}=\set{T^1_{u,v},T^2_{u,v}}_{u,v=1}^{m}$ be a grid triangulation on $\sidx{m+1}^2$ so that for all $u,v\in \sidx{m}$ we have $T^1_{u,v}\cup T^2_{u,v}= \set{u,u+1}\times\set{v,v+1}$, $\abs{T^1_{u,v}}=\abs{T^2_{u,v}}=3$ and either $T^1_{u,v}\cap T^2_{u,v}=\set{(u,v),(u+1,v+1)}$ or $T^1_{u,v}\cap T^2_{u,v}=\set{(u+1,v),(u,v+1)}$ (e.g. for the triangulation in Figure~\ref{newpwl2fig2} we can take $T_{2,1}^1=\set{\bra{2,1},\bra{3,1},\bra{2,2}}$ and $T_{2,1}^2=\set{\bra{3,1},\bra{3,2},\bra{2,2}}$ or exchange $T_{2,1}^1$ and $T_{2,1}^2$). Finally, let $\Delta_2^{m+1}:=\set{\lambda\in \mathbb R^{\sidx{m+1}^2}_+\,:\, \sum_{u,v=1}^{m+1} \lambda_{\bra{u,v}}=1}$, $n=2m^2$ and $\mathcal{P}\bra{\mathcal{T}}:=\bra{P^i}_{i=1}^{n}$ so that $P^{2\bra{m (u-1)+(v-1)}+t}=P\bra{T_{u,v}^t}:=\set{\lambda\in \Delta_2^{m+1}\,:\, \lambda_{\bra{\bar{u},\bar{v}}}\leq 0\quad \forall \bra{\bar{u},\bar{v}}\notin T_{u,v}^t}$ for all $u,v\in\sidx{m}$ and $t\in \set{1,2}$. Then for any continuous function $f:[1,m+1]\to \mathbb R$ that is affine in $\conv\bra{T}$ for each $T\in \mathcal{T}$, we have that a disjunctive representation of its graph $\gr(f):=\set{\bra{x,z}\in \mathbb R^3\,:\, f(x)=z}$ is given by \begin{subequations}\label{vformexunionpwl} \begin{alignat}{3} \sum\nolimits_{u,v=1}^{m+1} u \lambda_{\bra{u,v}}=x_1,\quad \sum\nolimits_{u,v=1}^{m+1} v \lambda_{\bra{u,v}}=x_2,\quad \sum\nolimits_{u,v=1}^{m+1} f(u,v) \lambda_{\bra{u,v}}&=z&\label{vformnumpwl}\\ \lambda&\in \bigcup\nolimits_{i=1}^{n} P^i.\label{vformnumpwldisj} \end{alignat} \end{subequations} If $k\geq \left\lceil \log_2 n\right\rceil$ and $H\in \mathcal{H}_k(n)$ then an ideal formulation of $\gr(f)$ is given by \eqref{vformnumpwl}, $\bra{\lambda,y}\in Q\bra{\mathcal{P}\bra{\mathcal{T}},H} $ and $y\in \mathbb{Z}^k$. \end{proposition} Constructing and analyzing embedding formulations for triangulations can be significantly more complicated than for SOS2 constraints. However, the analysis can be partially achieved through the following simple lemma that shows how a description of $Q\bra{\mathcal{P}\bra{\mathcal{T}},H}$ can be obtained from an ideal formulation of \eqref{vformnumpwldisj} whose binary variables are \emph{compatible} with the encoding $H$. That is if the formulation can be re-interpreted as a formulation of $(\lambda,y)\in \bigcup\nolimits_{i=1}^{n} P_i \times \set{h^i}$ (the LP relaxation of such formulation corresponds to $Q$ in the lemma). \begin{lemma}\label{formulationLemma}Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be a finite family of polyhedra in $\mathbb R^d$ satisfying Assumption~\ref{ass1}, $k\geq \left\lceil \log_2 n\right\rceil$, $H:=\bra{h^i}_{i=1}^n\in \mathcal{H}_k(n)$ and $Q\subseteq \mathbb R^{d+k}$ be a rational polyhedron. If $\ext\bra{Q}\subseteq \mathbb R^d\times \mathbb Z^k$ and \begin{equation}\label{lemmacondition}\bra{x,y}\in Q\cap \bra{\mathbb R^d\times\mathbb Z^k} \quad \Leftrightarrow \quad\exists i\in \sidx{n} \text{ s.t. } y=h^i\;\wedge\; x\in P^i,\end{equation} then $Q=Q\bra{\mathcal{P},H}$. \end{lemma} \proof{Proof.} By \eqref{lemmacondition}, the definition of $Q\bra{\mathcal{P},H}$ and convexity of $Q$ we have $Q\bra{\mathcal{P},H}\subseteq Q$. Furthermore, \eqref{lemmacondition} and the assumption on $\ext\bra{Q}$ yield $\ext\bra{Q}\subseteq \bigcup_{i=1}^n P^i\times \set{h^i}$. By Proposition~\ref{firstprop} and the fundamental theorem of integer programming applied to $Q\cap \bra{\mathbb R^d\times\mathbb Z^k}$ and $Q\bra{\mathcal{P},H}\cap \bra{\mathbb R^d\times\mathbb Z^k}$ we further have $Q_\infty=P^1_\infty\times\set{\mathbf{0}}=Q\bra{\mathcal{P},H}_\infty$. Finally, combining these properties with Minkowski-Weyl we get $Q=\conv\bra{\ext\bra{Q}}+Q_\infty\subseteq Q\bra{\mathcal{P},H}$, which shows the result. \Halmos\endproof Combining Lemma~\ref{formulationLemma} and formulations from \cite{lee01} and \cite{Modeling-Disjunctive-Constraints-FULL} we can give a rather precise analysis for a triangulation known as the \emph{union-jack} \citep{todd77}, which is depicted in Figure~\ref{newpwl2fig2} (See \cite{Modeling-Disjunctive-Constraints-FULL} for a precise description). In particular, we have that using the unary encoding leads to an extremely large embedding formulation, but using a carefully selected binary encoding leads to a simple formulation with near-optimal size. In the following proposition we let $\size_B\bra{Q\bra{\mathcal{P},H}}$ denote the number of facets of $Q\bra{\mathcal{P},H} $ defined by variable bounds as we did for SOS2 constraints. \begin{restatable}{proposition}{unionjackboundprop}\label{UnionJackCoro}Let $\mathcal{P}=\mathcal{P}(\mathcal{T})$ for a grid triangulation $\mathcal{T}$ on $\sidx{m+1}^2$ and $n=2m^2$ so that $\abs{\mathcal{P}\bra{\mathcal{T}}}=n$. Then $\bra{\sqrt{n/2}+1}^2\leq \mmc\bra{\mathcal{P}}$ and if $H$ is the unary encoding then \[\size_B\bra{Q\bra{\mathcal{P},H}}=\bra{\sqrt{n/2}+1}^2 \quad\text{and}\quad \size\bra{Q\bra{\mathcal{P},H}}=4+\bra{\sqrt{n/2}+1}^2+ \binom{2\sqrt{n/2}}{\sqrt{n/2}}.\] In contrast, if $m$ is a power of two and $\mathcal{T}$ is the union-jack triangulation, then there exist a binary encoding $H\in \mathcal{H}_{\log_2 n}(n)$ such that \begin{equation}\label{unionjackopt} \size_B\bra{Q\bra{\mathcal{P},H}} = \bra{\sqrt{n/2}+1}^2\quad\text{and}\quad \size\bra{Q\bra{\mathcal{P},H}} = 4+\bra{\sqrt{n/2}+1}^2+ 2 \log_2 (n/2). \end{equation} \end{restatable} We postpone a formal proof of Proposition~\ref{UnionJackCoro} to Section~\ref{proofofUnionJackCoro} and instead illustrate it with the following example that shows how Lemma~\ref{formulationLemma} can be used to recover an embedding formulation from the ideal formulation from \cite{Modeling-Disjunctive-Constraints-FULL}. In particular, it shows how studying this formulation reveals the encoding needed to recover the embedding formulation. \begin{example}\label{unionjackex} The union-jack triangulation $\mathcal{T}=\set{T^1_{u,v},T^2_{u,v}}_{u,v=1}^{m}$ for $m=2$ depicted in Figure~\ref{newpwl2fig2} can be described in a standard format used to construct the formulation in \cite{Modeling-Disjunctive-Constraints-FULL} by letting $T^1_{u,v}=\set{(2,2),(2,2v-3),(2u-3,2v-3)}$ and $T^2_{u,v}=\set{(2,2),(2u-3,2),(2u-3,2v-3)}$ for all $u,v\in \sidx{2}$. In addition, the formulation from \cite{Modeling-Disjunctive-Constraints-FULL} for this triangulation is given by \begin{subequations}\label{unionjackexform} \begin{alignat}{6} \lambda_{\bra{2,1}}+\lambda_{\bra{2,3}}&\leq 1-y_1,&\quad \lambda_{\bra{1,2}}+\lambda_{\bra{3,2}}&\leq y_1&\quad& \\ \lambda_{\bra{1,1}}+\lambda_{\bra{2,1}}+\lambda_{\bra{3,1}}& \leq 1-y_2, &\quad \lambda_{\bra{1,3}}+\lambda_{\bra{2,3}}+\lambda_{\bra{3,3}}& \leq y_2 &\quad&\\ \lambda_{\bra{1,1}}+\lambda_{\bra{1,2}}+\lambda_{\bra{1,3}}& \leq 1-y_3, &\quad \lambda_{\bra{3,1}}+\lambda_{\bra{3,2}}+\lambda_{\bra{3,3}}& \leq y_3 &\quad&\\ y &\in \set{0,1}^3,&\quad \sum\nolimits_{u,v=1}^3 \lambda_{(u,v)} &=1, &\quad& \lambda_{(u,v)} &\geq 0 \quad \forall u,v\in \sidx{3}. \end{alignat} \end{subequations} If we let $\mathcal{P}\bra{\mathcal{T}}:=\bra{P^i}_{i=1}^{8}$ as defined in Proposition~\ref{PWLFORMPROP}, we can check that if $\bra{y,\lambda}$ is feasible for \eqref{unionjackexform} and $y=(0,0,0)$ then $\lambda \in P^1=P\bra{T^1_{1,1}}=\set{\lambda\in \Delta_2^3\,:\, \lambda_{\bra{u,v}}\leq 0\quad \forall \bra{u,v}\notin \set{\bra{2,2},\bra{2,1} ,\bra{1,1}}}$. Then letting $h^1=(0,0,0)$ we obtain condition \eqref{lemmacondition} of Lemma~\ref{formulationLemma} for $i=1$. Similarly, we may iterate over all values of $y \in \set{0,1}^3$ to obtain the complete $P\bra{T^t_{u,v}}$-$h^{2\bra{m (u-1)+(v-1)}+t}$ or triangle-vector assignment for Lemma~\ref{formulationLemma} depicted in Figure~\ref{newpwl2fig2} and given by \begin{alignat*}{3} h^1=(0,0,0),\; T_{1,1}^1=\set{\bra{2,2},\bra{2,1} ,\bra{1,1}};&\quad\quad\quad&h^2=(1,0,0),\; T_{1,1}^2=\set{\bra{2,2},\bra{1,2},\bra{1,1}};\\ h^3=(0,0,1),\; T_{2,1}^1=\set{\bra{2,2},\bra{2,1},\bra{3,1}};&\quad\quad\quad&h^4=(1,0,1),\; T_{2,1}^2=\set{\bra{2,2},\bra{3,2},\bra{3,1}};\\ h^5=(0,1,0),\; T_{1,2}^1=\set{\bra{2,2},\bra{2,3},\bra{1,3}};&\quad\quad\quad&h^6=(1,1,0),\; T_{1,2}^1=\set{\bra{2,2},\bra{1,2},\bra{1,3}};\\ h^7=(0,1,1),\; T_{2,2}^1=\set{\bra{2,2},\bra{2,3},\bra{3,3}};&\quad\quad\quad&h^8=(1,1,1),\; T_{2,2}^1=\set{\bra{2,2},\bra{3,2},\bra{3,3}}. \end{alignat*} Because formulation \eqref{unionjackexform} is ideal, by Lemma~\ref{formulationLemma} we have that its LP relaxation is equal to $Q\bra{\mathcal{P}\bra{\mathcal{T}},H}$ for this $H$. \end{example} Proposition~\ref{UnionJackCoro} shows that the specific encoding used can have a significant impact on the size of an embedding formulation for triangulations. As illustrated in Example~\ref{unionjackex}, we can use an existing ideal formulation and Lemma~\ref{formulationLemma} to recover a favorable encoding. Unfortunately, the formulation from \cite{Modeling-Disjunctive-Constraints-FULL} used to obtain the favorable encoding only works for the union-jack triangulation and it is sometimes preferable to use different triangulations such as the ones depicted in Figure~\ref{triag2} (e.g. \cite{Fitting-Piecewise-Linear}). In the following subsection we explore how adapting the favorable encoding for the union-jack triangulation to similar triangulations can sometimes help computationally construct a small embedding formulation. \begin{figure}[htpb] \begin{center} \subfigure[Modified Union-Jack Triangulation for $m=4$.]{\label{triag2a}\quad\quad\quad\quad\quad\quad\includegraphics[scale=.18]{modJ1.pdf}\quad\quad\quad} \subfigure[K1 Triangulation for for $m=4$.]{\label{triag2b}\quad\quad\quad\includegraphics[scale=.18]{K1.pdf}\quad\quad\quad\quad\quad\quad} \end{center} \caption{Different Triangulations.}\label{triag2} \end{figure} \subsection{Constructing Embedding Formulations Computationally}\label{cddsec} One way to construct embedding formulations is to computationally construct the convex hull in \eqref{embconv} for a specific encoding. Picking a random encoding will likely result in an extremely large formulation (cf. Section~\ref{graphsec}). For this reason we now investigate the effectiveness of using a known favorable encoding for a similar constraint. For this we consider the modification of the union-jack triangulation illustrated in Figure~\ref{triag2a}. This triangulation is obtained by changing the way the bottom-left and top-right squares of the triangulation are divided into two triangles (in the original triangulation they are divided into top-left and bottom-right triangles, and in the modified triangulation they are divided into bottom-left and top-right triangles). To construct an embedding formulation for this modified triangulation we adapt the encoding $H$ associated to the logarithmic formulation for the union-jack triangulation (i.e. the encoding illustrated in Example~\ref{unionjackex}). The adaptation uses the same triangle-vector assignment for all triangles except for the ones belonging to the bottom-left and top-right squares. This adaptation is illustrated in Figure~\ref{aaa} for $m=2$ where the top triangulation is the union-jack with the encoding described in Example~\ref{unionjackex} and the bottom triangulation is the modified union-jack with the adapted encoding. For both squares where the encoding is changed, the adaptation assigns to the bottom-left triangle the same $h^i$ assigned to the top-left triangle in the original encoding for the union-jack triangulation. Similarly, the adaptation assigns to top-right triangle the same $h^i$ assigned to the bottom-right triangle in the original encoding. To construct the formulation we simply compute the convex hull of $\bigcup_{=1}^n P^i \times \set{h^i}$ for this modified $H=\bra{h^i}_{i=1}^n$ and $\mathcal{P}\bra{\mathcal{T}}:=\bra{P^i}_{i=1}^{n}$ from Proposition~\ref{PWLFORMPROP} using the software cddlib \citep{cddlib}. We tried this for $m\in \set{4,8,16,32}$ and for all four cases the resulting embedding formulation only had four more inequalities than the formulation for the original union-jack triangulation. In addition, computing the convex hulls with cddlib for each $m\in \set{4,8,16,32}$ took respectively less than a second, 10 seconds, 24 minutes and 3.5 days on an Intel i7-3770 3.40GHz workstation with 32GB of RAM. The computational time can grow quickly with $m$, but fortunately this computation only has to be done once and the formulation can then be stored. Similar to traditional MIP formulations, the resulting stored embedding formulation can be used for free in any problem that requires a piecewise linear functions of two variables based on the modified union-jack triangulation. More specifically, the same formulation can be used independently of the specific data (e.g. actual function values) associated to the piecewise linear functions (i.e. in the formulation from Proposition~\ref{PWLFORMPROP} we need to update \eqref{vformnumpwl}, but we do not need to change the embedding formulation for disjunction \eqref{vformnumpwldisj}). Hence, 3.5 days does not seem that large when compared with the research time required to develop a small and ideal ad-hoc MIP formulation. Of course, this statement is conditional on the resulting formulation being small (so that it can be effectively stored and reused) and the formulation yielding a computational advantage (which is correlated with, but not guaranteed by a small size). To check if the formulation obtained with cddlib preserves the computational advantage of the logarithmic formulation for the original union-jack triangulation, we replicate the computational experiments in \cite{Modeling-Disjunctive-Constraints-FULL} and \cite{Mixed-Integer-Models-for-Nonseparable} for the modified union-jack triangulation. These experiments consider a series of transportation problems whose objective functions are the sum of $25$ piecewise linear functions of two variables on the $\sidx{m+1}^2$ grid for $m\in \set{4,8,16,32}$. For each $m$ the experiment considers $100$ randomly generated instances. With the exception of the logarithmic formulation, all formulations considered in the original experiment are applicable for the modified union-jack triangulation. So we test all these formulations with the logarithmic formulation replaced by the embedding formulation constructed computationally using cddlib. All formulations were implemented using the JuMP modeling language \citep{jump,LubinDunningIJOC,DunningHuchetteLubin2015} and solved with Gurobi v6.5 \citep{gurobi} on an Intel i7-3770 3.40GHz workstation with 32GB of RAM. Solve times for all combinations of formulations and solver are presented in Figure~\ref{resfig1} for $m\in \set{4,8,16,32}$. We refer the reader to \cite{Mixed-Integer-Models-for-Nonseparable} for details on the benchmark formulations, but we note that DCC and MC is obtained by variants of Theorem~\ref{BTheo}, CC is the generalization of formulation \eqref{CC1d} and DCCLog is obtained by combining a variant of Theorem~\ref{BTheo} with the same encoding used for the embedding formulation. We can see that the embedding formulation can provide a significant computational advantage. \begin{figure}[htpb] \begin{center} \subfigure[Encoding Adaptation for $m=2$.]{\label{aaa}\includegraphics[scale=.38,trim=0 -1.2cm 0 0]{compencoding.pdf}\quad\quad\quad} \subfigure[Solve Times for $m\in \set{4,8,16,32}$ {[s]}]{\label{resfig1}\quad\quad\includegraphics[scale=1.1]{J1Gurobi.pdf}} \end{center} \caption{Encoding and Solve Times for Modified Union-Jack Triangulation.} \end{figure} \section{Omitted Proofs and Additional Examples} \subsection{Proof of Proposition~\ref{sos1prophyper}}\label{proofofsos1prophyper} To prove Proposition~\ref{sos1prophyper} we use the following lemma, which gives a precise characterization of the facial structure of $Q\bra{\mathcal{P},H}$ for SOS2 constraints. \begin{lemma}\label{facelemma} Let $\mathcal{P}:=\bra{P^i}_{i=1}^n$ be the SOS2 constraint on $\Delta^{n+1}$, $H:=\bra{h^i}_{i=1}^n\in \mathcal{H}_k(n)$, $h^0=h^1$, $h^{n+1}=h^n$, $c^i=h^{i+1}-h^i$ for $i\in \sidx{0,n}$. In addition, for any $J^-,J^+\subseteq \sidx{n+1}$ let \begin{alignat*}{3} E\bra{J^-,J^+}:&=\bigcup\nolimits_{j\in J^-}\set{\bra{\mathbf{e}^j,h^{j-1}}} &\cup \bigcup\nolimits_{j\in J^+}\set{\bra{\mathbf{e}^j,h^{j}}}\\ &=\bigcup\nolimits_{j\in J^-}\set{\bra{\mathbf{e}^j,h^{j}-c^{j-1}}} &\cup \bigcup\nolimits_{j\in J^+}\set{\bra{\mathbf{e}^j,h^{j}}} \end{alignat*} so that $Q\bra{\mathcal{P},H}=\conv\bra{E\bra{\sidx{n+1},\sidx{n+1}}}$ and $E\bra{\sidx{n+1},\sidx{n+1}}=\ext\bra{Q\bra{\mathcal{P},H}}$. Then for any for any $J^-,J^+\subseteq \sidx{n+1}$ we have \[\dim\bra{E\bra{J^-,J^+}}=\abs{J^+\cup J^-}-1+\dim\bra{\set{c^{j-1}}_{j\in J^+\cap J^-}}.\] Furthermore, $F\subseteq \mathbb R^{n+1+k}$ is a face of $Q\bra{\mathcal{P},H}$ if and only if there exist $J^-,J^+\subseteq \sidx{n+1}$ such that $F=F\bra{J^-,J^+}:=\conv\bra{E\bra{J^-,J^+}}$ and there exist $b\in \mathbb R^k$ such that \begin{equation}\label{facelemmacond} b\cdot c^{j-1}=0 \quad \forall j\in J^+\cap J^-,\quad b\cdot c^{j-1}< 0 \quad j\in J^-\setminus J^+ \quad\text{and}\quad b\cdot c^{j-1}> 0\quad \forall j\in J^+\setminus J^-. \end{equation} \end{lemma} \proof{Proof.} For the dimension of $E\bra{J^-,J^+}$, let $J\subseteq J^-\cap J^+$ be such that $\spann\bra{\set{c^{j-1}}_{j\in J}}=\spann\bra{\set{c^{j-1}}_{j\in J^-\cap J^+}}$ and $\abs{J}=\dim\bra{\set{c^{j-1}}_{j\in J^-\cap J^+}}$, and \[E=\bigcup\nolimits_{j\in J^-\setminus J^+}\set{\bra{\mathbf{e}^j,h^{j-1}}} \cup \bigcup\nolimits_{j\in J^+\setminus J^-}\set{\bra{\mathbf{e}^j,h^{j}}}\cup \bigcup\nolimits_{j\in J^-\cap J^+}\set{\bra{\mathbf{e}^j,h^{j}}}\cup \bigcup\nolimits_{j\in J}\set{\bra{\mathbf{e}^j,h^{j-1}}}. \] We can check that $E$ is a set of $\abs{J^+\cup J^-}+\dim\bra{\set{c^{j-1}}_{j\in J^+\cap J^-}}$ affinely independent vectors. Finally, for any $\bra{\lambda,y}\in E\bra{J^-,J^+}\setminus E$ there exist $j\in J^+\cap J^-\setminus J$ such that $\bra{\lambda,y}=\bra{\mathbf{e}^j,h^{j-1}}=\bra{\mathbf{e}^j,h^{j}-c^{j-1}}$. Let $\mu\in \mathbb R^{J}$ be such that $c^{j-1}=\sum_{i\in J} \mu_i c^{i-1}$. Then $\bra{\mathbf{e}^j,h^{j}-c^{j-1}}= \mu_0 \bra{\mathbf{e}^j,h^{j}}+\sum_{i\in J} \bra{ \mu_i \bra{\mathbf{e}^i,h^i- c^{i-1}} -\mu_i \bra{\mathbf{e}^i,h^i} }$ for $\mu_0=1$ and result follows. For the facial characterization we have that $F\subseteq \mathbb R^{n+1+k}$ is a face of $Q\bra{\mathcal{P},H}$ if and only if there exist $\bra{a,b}\in \mathbb R^{n+1+k}$ such that \begin{equation}\label{facemax} \begin{aligned}F&=\argmax\set{a\cdot \lambda+b\cdot y\,:\, \bra{\lambda,y}\in Q\bra{\mathcal{P},H}}\\&=\conv\bra{\argmax\set{a\cdot \lambda+b\cdot y\,:\, \bra{\lambda,y}\in E\bra{\sidx{n+1},\sidx{n+1}}}}.\end{aligned} \end{equation} Let $c=\max\set{a\cdot \lambda+b\cdot y\,:\, \bra{\lambda,y}\in Q\bra{\mathcal{P},H}}$, $J^-=\set{j\in \sidx{n+1}\,:\, a\cdot\mathbf{e}^j+b\cdot h^{j-1} =c}=\set{j\in \sidx{n+1}\,:\, a\cdot\mathbf{e}^j+ b\cdot h^{j} -b\cdot c^{j-1} =c}$ and $J^+=\set{j\in \sidx{n+1}\,:\, a\cdot\mathbf{e}^j+b\cdot h^{j} =c}$. Then $F=\conv\bra{E\bra{J^-,J^+}}$, $b\cdot c^{j-1}=0$ for all $j\in J^+\cap J^-$, $b\cdot c^{j-1}< 0$ for all $j\in J^-\setminus J^+$ and $b\cdot c^{j-1}> 0$ for all $j\in J^+\setminus J^-$. Conversely if $F=\conv\bra{E\bra{J^-,J^+}}$ for $J^-,J^+\subseteq \sidx{n+1}$ and $b\in \mathbb R^k$ satisfies \eqref{facelemmacond} let $a_j=b\cdot h^j$ for $j\in J^+=\bra{ J^+\cap J^-}\cup \bra{J^+\setminus J^-}$, $a_j=b\cdot h^{j-1}$ for $j\in J^-\setminus J^+$ and $a_j=\min\bra{b\cdot h^{j},b\cdot h^{j-1}}-1$ for $j\in \sidx{n+1}\setminus \bra{J^-\cup J^+}$. The $a$, $b$ and $F$ satisfy \eqref{facemax}. \Halmos\endproof \vspace{0.2in} \proof{Proof of Proposition~\ref{sos1prophyper}.} Throughout the proof we let $h^0=h^1$, $h^{n+1}=h^n$ as in the statement of Lemma~\ref{facelemma} so we can define $c^i=h^{i+1}-h^i$ for all $i\in \sidx{0,n}$ and it coincides with the proposition's statement for $i\in \sidx{n-1}$ and $c^0=c^{n}={\bf 0}$. We will also use the straightforward fact that $L\bra{H}=\spann\bra{\set{c^i}_{i\in \sidx{n-1}}}=\spann\bra{\set{c^i}_{j\in \sidx{0,n}}}$. Any $\bra{\lambda,y}\in Q\bra{\mathcal{P},H}$ satisfies the equations in \eqref{sos2equalities}. Furthermore, because $L\bra{H}=\spann\bra{\set{c^i}_{i\in \sidx{n-1}}}$ we have that the dimension of the affine subspace described by \eqref{sos2equalities} is $n+\dim\bra{\set{c^i}_{i\in \sidx{n-1}}}$. Finally, by Lemma~\ref{facelemma} $\dim\bra{Q\bra{\mathcal{P},H}}=n+\dim\bra{\set{c^i}_{i\in \sidx{n-1}}}$, which shows the statements about $\dim\bra{Q\bra{\mathcal{P},H}}$ and $\aff\bra{Q\bra{\mathcal{P},H}}$. Using Lemma~\ref{facelemma} we have that a face $F\bra{J^-,J^+}=\conv\bra{E\bra{J^-,J^+}}$ for $J^-,J^+\subseteq \sidx{n+1}$ may be a facet of $Q\bra{\mathcal{P},H}$ only if $\abs{J^+\cup J^-}=n+1$ and $\dim\bra{\set{c^{j-1}}_{j\in J^+\cap J^-}}=\dim\bra{L\bra{H}}-1$ or $\abs{J^+\cup J^-}=n$ and $\dim\bra{\set{c^{j-1}}_{j\in J^+\cap J^-}}=\dim\bra{L\bra{H}}$. In the first option $J^+\cup J^-=\sidx{n+1}$ and $J^+\cap J^-\subsetneq \sidx{n+1}$ because $\dim\bra{\set{c^{j-1}}_{j\in \sidx{n+1}}}=\dim\bra{L\bra{H}}$. Then, $\bra{J^-\setminus J^+}\cup \bra{ J^+\setminus J^-}\neq \emptyset$ and condition \eqref{facelemmacond} of Lemma~\ref{facelemma} holds for $b\in \mathbb R^k\setminus \set{\bf 0}$. Furthermore, because of the first part of condition \eqref{facelemmacond} and $\dim\bra{\set{c^{j-1}}_{j\in J^+\cap J^-}}=\dim\bra{L\bra{H}}-1$ we further have that $b=s b^l$ for some $l\in \sidx{L}$ and $s\in \set{-1,1}$, and $J^+\cap J^-=\set{j\in \sidx{n+1}\,:\, c^{j-1}\in M\bra{b^l}}$ (note that because $c^0=c^{n}=0$ we always have $1,n+1\in J^+\cap J^-$). If $s=1$ the second inequality in \eqref{sos2generalfacets} for $b^l$ is satisfied at equality by all points in $E\bra{J^-,J^+}$ and strictly by all points in $E\bra{\sidx{n+1},\sidx{n+1}}\setminus E\bra{J^-,J^+}$, and hence defines $F\bra{J^-,J^+}$. Similarly, if $s=-1$ the first inequality in \eqref{sos2generalfacets} for $b^l$ defines $F\bra{J^-,J^+}$. In the second option we have that $\spann\bra{\set{c^{j-1}}_{j\in J^+\cap J^-}}=L(H)$ and hence the first part of condition \eqref{facelemmacond} of Lemma~\ref{facelemma} implies $b\in L(H)^{\perp}$. However, $\spann\bra{\set{c^{j-1}}_{j\in \sidx{n+1}}}=L(H)$ so the second part of condition \eqref{facelemmacond} implies $J^-\setminus J^+ = J^+\setminus J^-=\emptyset$ and hence $J^-=J^+=\sidx{n+1}\setminus \set{j_0}$ for some $j_0\in J$. Noting that $c^0=c^{n}=0$ we have that condition $\spann\bra{\set{c^{j-1}}_{j\in J^+\cap J^-}}=\spann\bra{\set{c^{j-1}}_{j\in\sidx{n+1}\setminus \set{j_0}}}=L(H)$ holds if and only if $j_0\in J$ for $J$ defined in the proposition statement. Furthermore, in such case the inequality in \eqref{sos2boundfacets} corresponding to $j=j_0$ defines $F\bra{J^-,J^+}$. Hence the equations of \eqref{SOS2char} are precisely those defining $\aff\bra{Q\bra{\mathcal{P},H}}$, every facet of $Q\bra{\mathcal{P},H}$ is defined by an inequality of \eqref{SOS2char} and every inequality of \eqref{SOS2char} is facet defining for $Q\bra{\mathcal{P},H}$. Finally, the last statement follows because the two options considered for facets of $Q\bra{\mathcal{P},H}$ yield two distinct classes of facets. \Halmos\endproof \subsection{An Embedding Formulation for SOS2 Constraints Whose Validity is Not Evident}\label{examplesection} \begin{example} Let $\mathcal{P}:=\bra{P^i}_{i=1}^9$ be the SOS2 constraint on $\Delta^{10}$ and $H=\bigl((0, 1, 1, 1)^T,$ $(0, 1, 0, 0)^T, (0, 0, 0, 0)^T, (0, 1, 0, 1)^T, (0, 0, 0, 1)^T, (1, 0, 0, 0)^T, (1, 1, 0, 1)^T, (1, 0, 1, 1)^T, (1, 1, 1, 1)^T\bigr)$. Then $\bra{c^i}_{i=1}^{8}=\bigl\{ (0, 0, -1, -1)^T, (0, -1, 0, 0)^T, (0, 1, 0, 1)^T, (0, -1, 0, 0)^T, (1, 0, 0, -1)^T, (0, 1, 0, 1)^T,$ $(0, -1, 1, 0)^T, (0, 1, 0, 0)^T\bigr\}$ and the set of hyperplanes spanned by them is given by $\set{M\bra{b^l}}_{l=1}^{5}$ for $b^1=\bra{1,0,0,-1,1}^T$, $b^2=\bra{1,0,0,1}^T$, $b^3=\bra{1,-1,-1,1}^T$, $b^4=\bra{1,0,0,0}^T$ and $b^5=\bra{0,0,1,0}^T$. Finally, $\aff(H)=L(H)=\mathbb{R}^4$ and $\mathbb{R}^4=\spann\bra{\set{c^i}_{i\in \sidx{9}\setminus\set{j-1} }}$ if and only if $j\in \sidx{2,10}\setminus \set{6}$. Then \eqref{SOS2char} in this case is given by \begin{subequations}\label{nine} \begin{alignat}{3} \sum\nolimits_{j=1}^{10} \lambda_j &=1,\quad \label{nineeq}\\ \lambda_5+\lambda_6+\lambda_7+\lambda_8+\lambda_9+\lambda_{10} &\leq y_1-y_3+y_4 \\ \lambda_4+\lambda_5+\lambda_6+2\lambda_7+2\lambda_8+\lambda_9+\lambda_{10} &\geq y_1-y_3+y_4 \label{ninec}\\ \lambda_1+\lambda_5+\lambda_6+\lambda_7+2\lambda_8+2\lambda_9+2\lambda_{10} &\leq y_1+y_4 \\ \lambda_1+\lambda_2+\lambda_4+\lambda_5+\lambda_6+2\lambda_7+2\lambda_8+2\lambda_9+2\lambda_{10} &\geq y_1+y_4 \\ -\lambda_1-\lambda_2-\lambda_3+\lambda_6+\lambda_7+\lambda_8 &\leq y_1-y_2-y_3+y_4 \label{ninef}\\ -\lambda_1-\lambda_2+\lambda_5+\lambda_6+\lambda_7+\lambda_8 +\lambda_9 &\geq y_1-y_2-y_3+y_4 \\ \lambda_7+\lambda_8 +\lambda_9+\lambda_{10} &\leq y_1 \\ \lambda_6+\lambda_7+\lambda_8 +\lambda_9+\lambda_{10} &\geq y_1 \\ \lambda_1 +\lambda_9+\lambda_{10}&\leq y_3 \\ \lambda_1+\lambda_2 +\lambda_8+\lambda_9+\lambda_{10} &\geq y_3 \\ \lambda_j&\geq 0 &\quad& \forall j\in \sidx{10}\setminus\set{6}, \end{alignat} If $y=h^4=\bra{0,1,0,1}^T$ then \eqref{nine} should enforce $\lambda_i=0$ for all $i\notin\set{4,5}$. Inequality \eqref{ninef} enforces that $\lambda_6=1$ cannot hold, but it does not force $\lambda_6=0$ as $\lambda_1=\lambda_6=1/2$ is valid for this inequality. However, this last point is infeasible for \eqref{ninec}. These two inequalities plus \eqref{nineeq} do indeed imply $\lambda_6\leq 0$ (and hence $\lambda_6=0$ because of the lower bounds) when $y=h^4$ as adding \eqref{nineeq}, \eqref{ninec} and \eqref{ninef} yields \[\lambda_6 \leq 1-y_2.\] Furthermore, removing any one of these constraints allows $\lambda_6>0$ when $y=h^4$. \end{subequations} \end{example} \subsection{Proof of Proposition~\ref{antigraylemma}}\label{omproofapendix} To prove Proposition~\ref{antigraylemma} we need the following definition. \begin{definition} Let $n=2^k$ for some $k\in \mathbb Z$. We say $H=\set{h^i}_{i=1}^{n}\in \mathcal{H}_{k}(n)$ is a \emph{anti-gray code}\footnote{The class of codes obtained by switching $n$ and $n-1$ in this definition is sometimes also referred to as anti-gray code.} if and only if $\sum\nolimits_{j=1}^{k} \abs{h^{2i-1}_j-h^{2i}_j}=n $ for all $i\in \sidx{ n/2}$ and $\sum\nolimits_{j=1}^{k} \abs{h^{2i}_j-h^{2i+1}_j}=n -1 $ for all $i\in \sidx{n/2-1}$. \end{definition} Anti-gray codes exist for all $k$ and can easily be constructed from gray codes (e.g. \cite{robinson1981counting}). \vspace{0.2in} \proof{Proof of Proposition~\ref{antigraylemma}.} Let $H$ be an anti-gray code and $c^i=h^{i+1}-h^i$ for $i\in \sidx{n-1}$. Because $H$ is an anti-gray code there exist $I\subseteq \sidx{n-1}$ with $\abs{I}=2^{k-1}$ such that $c^i\in \set{-1,1}^k$ for all $i\in I$. In addition, because $h^i\neq h^j$ for $i\neq j$ we have that $c^i\neq -c^j$ for all $i,j \in I$. Hence for all $s\in \set{-1,1}^k$ there exist $i\in I$ such that $s=c^i$ or $s=-c^i$. The result then follows from Proposition~\ref{sos1prophyper} by noting that $\set{c^i}_{i\in I}$ and $\set{\pm c^i}_{i\in I}$ span the same set of linear hyperplanes and that the number of linear hyperplanes spanned by $\set{-1,1}^k$ is equal to the number of affine hyperplanes spanned by $\set{0,1}^{k-1}$ (e.g. \cite{da2005recursivity}) \Halmos\endproof \subsection{Proof of Proposition~\ref{UnionJackCoro}}\label{proofofUnionJackCoro} \proof{Proof Proposition~\ref{UnionJackCoro}.} For any $H\in \mathcal{H}_k(n)$ we have $Q\bra{\mathcal{P},H}\subseteq\Delta_2^{m+1}:=\set{\lambda\in \mathbb R^{\sidx{m+1}^2}_+\,:\, \sum_{u,v=1}^{m+1} \lambda_{\bra{u,v}}=1}$. We begin by showing that for any $H\in \mathcal{H}_k(n)$ all inequalities $\lambda_{\bra{u,v}}\geq 0$ of $\Delta_2^{m+1}$ are facet defining for $Q\bra{\mathcal{P},H}$. For that let $n=2m^2$ and $\bra{S_i}_{i=1}^{n}$ be such that $S_{2\bra{m (u-1)+(v-1)}+t}=T_{u,v}^t$ for all $u,v\in\sidx{m}$ and $t\in \set{1,2}$ so that $Q\bra{\mathcal{P},H}=\conv\bra{\bigcup_{i=1}^n P\bra{S_i}\times \set{h^i}}$. Then $\lambda_{\bra{u,v}}\geq 0$ describes a face of $Q\bra{\mathcal{P},H}$ because it is valid and is satisfied at equality for all points $\bra{\lambda,y}=\bra{\mathbf{e}^{\bar{u},\bar{v}},h^i}$ for $\bra{\bar{u},\bar{v}}\in S_i\setminus \set{\bra{u,v}}$. Let \begin{equation}\label{genericineql2222} a\cdot\lambda + b\cdot y\leq c \end{equation} be a valid inequality of $Q\bra{\mathcal{P},H}$ that induces a facet containing the face induced by $\lambda_{\bra{u,v}}\geq 0$. Because $Q\bra{\mathcal{P},H}\subseteq\Delta_2^{m+1}\cap \aff\bra{H}$, without loss of generality we may assume $c=0$ and $b\in L\bra{H}$ by possibly adding multiples of $\sum_{u,v=1}^{m+1} \lambda_{\bra{u,v}}=1$ and the equations defining $\aff\bra{H}$. For any $i,j\in \sidx{n}$, $\bra{\underline{u},\underline{v}}\in S_i \setminus \set{\bra{u,v}}$ and $\bra{\overline{u},\overline{v}}\in S_j \setminus \set{\bra{u,v}}$ there exist $\bra{i_l}_{l=1}^r\subseteq \sidx{n}$ and $\bra{\bra{u_l,v_l}}_{l=1}^{r-1} \subseteq \sidx{n+1}^2\setminus \set{\bra{u,v}}$ such that $i_1=i$, $i_r=j$, $\bra{\underline{u},\underline{v}}=\bra{u_{i_1},v_{i_1}}$, $\bra{\overline{u},\overline{v}}=\bra{u_{i_r},v_{i_r}}$ and $\bra{u_l,v_l}\in S_{i_l}\cap S_{i_{l+1}}$ for all $l\in \sidx{r-1}$. Because $\bra{\lambda,y}=\bra{\mathbf{e}^{\bra{u_l,v_l}},h^l}$ and $\bra{\lambda,y}=\bra{\mathbf{e}^{\bra{u_l,v_l}},h^{l+1}}$ satisfy \eqref{genericineql2222} at equality for all $l\in \sidx{r-1}$, we have $b\cdot h^i=b\cdot h^j$ and $a_{\bra{\underline{u},\underline{v}}}=a_{\bra{\overline{u},\overline{v}}}=b\cdot h^i$. Because the first identity holds for all $i,j\in \sidx{n}$ we have $b\cdot\bra{h^i-h^1}=0$ for all $i\in\sidx{n}$, which together with $b\in L\bra{H}$ implies $b=\bf 0$. Similarly, combining $b=\bf 0$ and the fact that the second identity holds for all $\bra{\underline{u},\underline{v}},\bra{\overline{u},\overline{v}}\neq \bra{u,v}$ we obtain $ a_{\bra{\bar{u},\bar{v}}}=0$ for all $\bra{\bar{u},\bar{v}}\neq \bra{u,v}$. Finally, validity of \eqref{genericineql2222} implies $a_{\bra{u,v}}\leq 0$ and being facet defining further implies $a_{\bra{u,v}}<0$. Then \eqref{genericineql2222} is a positive multiple of $\lambda_{\bra{u,v}}\geq 0$ and hence $\lambda_{\bra{u,v}}\geq 0$ is facet defining. The result on $\lambda_{\bra{u,v}}\geq 0$ shows that $\bra{\sqrt{n/2}+1}^2\leq \size_B\bra{Q\bra{\mathcal{P},H}} \leq \mmc\bra{\mathcal{P}} $ for any $H\in \mathcal{H}_k(n)$. The sizes for the unary encoded formulation comes from Proposition~10 in \cite{lee01}, the comments before its statement and Lemma~\ref{formulationLemma}. The existence and sizes for the binary encoded formulation come from the proof of Theorem~1 in \cite{Modeling-Disjunctive-Constraints-FULL}, Lemma~\ref{formulationLemma}, the lower bound on $\size_B\bra{Q\bra{\mathcal{P},H}}$, noting that the bounds on the binary variables of the formulation from \cite{Modeling-Disjunctive-Constraints-FULL} are redundant (cf. the logarithmic formulation for SOS2) and that none of the non-bound inequalities of this formulation are redundant.\Halmos\endproof \ACKNOWLEDGMENT{The author would like to thank the review team including an anonymous associate editor and two anonymous referees for their thoughtful and constructive comments, which significantly improved the exposition of the paper. This research was partially supported by the National Science Foundation under grant CMMI-1351619.} \bibliographystyle{ormsv080}
{ "redpajama_set_name": "RedPajamaArXiv" }
4,656
#pragma once #include <aws/securityhub/SecurityHub_EXPORTS.h> #include <aws/securityhub/SecurityHubRequest.h> #include <aws/core/utils/memory/stl/AWSMap.h> #include <aws/core/utils/memory/stl/AWSString.h> #include <utility> namespace Aws { namespace SecurityHub { namespace Model { /** */ class AWS_SECURITYHUB_API EnableSecurityHubRequest : public SecurityHubRequest { public: EnableSecurityHubRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "EnableSecurityHub"; } Aws::String SerializePayload() const override; /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline const Aws::Map<Aws::String, Aws::String>& GetTags() const{ return m_tags; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline void SetTags(const Aws::Map<Aws::String, Aws::String>& value) { m_tagsHasBeenSet = true; m_tags = value; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline void SetTags(Aws::Map<Aws::String, Aws::String>&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& WithTags(const Aws::Map<Aws::String, Aws::String>& value) { SetTags(value); return *this;} /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& WithTags(Aws::Map<Aws::String, Aws::String>&& value) { SetTags(std::move(value)); return *this;} /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& AddTags(const Aws::String& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& AddTags(Aws::String&& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& AddTags(const Aws::String& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& AddTags(Aws::String&& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), std::move(value)); return *this; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& AddTags(const char* key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& AddTags(Aws::String&& key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** * <p>The tags to add to the hub resource when you enable Security Hub.</p> */ inline EnableSecurityHubRequest& AddTags(const char* key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } /** * <p>Whether to enable the security standards that Security Hub has designated as * automatically enabled. If you do not provide a value for * <code>EnableDefaultStandards</code>, it is set to <code>true</code>. To not * enable the automatically enabled standards, set * <code>EnableDefaultStandards</code> to <code>false</code>.</p> */ inline bool GetEnableDefaultStandards() const{ return m_enableDefaultStandards; } /** * <p>Whether to enable the security standards that Security Hub has designated as * automatically enabled. If you do not provide a value for * <code>EnableDefaultStandards</code>, it is set to <code>true</code>. To not * enable the automatically enabled standards, set * <code>EnableDefaultStandards</code> to <code>false</code>.</p> */ inline bool EnableDefaultStandardsHasBeenSet() const { return m_enableDefaultStandardsHasBeenSet; } /** * <p>Whether to enable the security standards that Security Hub has designated as * automatically enabled. If you do not provide a value for * <code>EnableDefaultStandards</code>, it is set to <code>true</code>. To not * enable the automatically enabled standards, set * <code>EnableDefaultStandards</code> to <code>false</code>.</p> */ inline void SetEnableDefaultStandards(bool value) { m_enableDefaultStandardsHasBeenSet = true; m_enableDefaultStandards = value; } /** * <p>Whether to enable the security standards that Security Hub has designated as * automatically enabled. If you do not provide a value for * <code>EnableDefaultStandards</code>, it is set to <code>true</code>. To not * enable the automatically enabled standards, set * <code>EnableDefaultStandards</code> to <code>false</code>.</p> */ inline EnableSecurityHubRequest& WithEnableDefaultStandards(bool value) { SetEnableDefaultStandards(value); return *this;} private: Aws::Map<Aws::String, Aws::String> m_tags; bool m_tagsHasBeenSet = false; bool m_enableDefaultStandards; bool m_enableDefaultStandardsHasBeenSet = false; }; } // namespace Model } // namespace SecurityHub } // namespace Aws
{ "redpajama_set_name": "RedPajamaGithub" }
5,418
Tadeusz Kulik (ur. 20 czerwca 1952) – polski naukowiec, profesor nauk technicznych o specjalnościach materiały amorficzne i drobnoziarniste, materiały magnetycznie miękkie, materiały nanokrystaliczne. Profesor zwyczajny na Wydziale Inżynierii Materiałowej Politechniki Warszawskiej. Życiorys Urodził się 20 czerwca 1952. W 1977 ukończył studia magisterskie na Wydziale Mechanicznym Technologicznym Politechniki Warszawskiej (późniejszy Wydział Inżynierii Materiałowej PW). 8 lutego 1983 obronił na tym wydziale pracę doktorską pt. Wpływ niskotemperaturowego wygrzewania, odkształcenia i krystalizacji na własności magnetyczne szkieł Co-Si-B, a 16 października 1998 uzyskał na nim habilitację na podstawie rozprawy pt. Nanokrystaliczne materiały magnetycznie miękkie otrzymywane przez krystalizację szkieł metalicznych. Tytuł naukowy profesora w dziedzinie nauk technicznych otrzymał 22 stycznia 2007. Od 1982 zatrudniony na WIM PW i odtąd nieprzerwanie związany z uczelnią. W kadencjach 2005–2008 i 2008–2012 prorektor PW ds. nauki. W kadencji 2002–2005 dziekan WIM PW, a w latach 1999–2002 prodziekan ds. nauki tego wydziału. W latach 2002-2005 dyrektor Centrum Doskonałości NanoCentre na PW. W latach 2001-2002 Dyrektor Uczelnianego Centrum Badawczego "Materiały Funkcjonalne". Pełnomocnik Rektora ds. Nagrody im. Prof. Jana Czochralskiego w latach 2013-2020, organizator czterech edycji konkursu o Nagrodę (2014, 2015, 2017 i 2020). Przewodniczący Uczelnianej Komisji Wyborczej PW od 2019 r. Autor i współautor ponad 260 publikacji naukowych (ponad 220 w bazie danych SCOPUS), cytowanych ok. 2600 razy; Indeks Hirscha = 25 (bez autocytowań). Współautor 3 patentów, autor 1 monografii. Należy do grupy 2 proc. najczęściej cytowanych naukowców na świecie, według listy opublikowanej w październiku 2020 r. w magazynie PLOS Biology a przygotowanej przez uczonych z Uniwersytetu Stanforda we współpracy z wydawnictwem naukowym Elsevier i firmą SciTech Strategies (Table-S6 - career long impact). Część swoich badań prowadził w czasie kilkuletnich pobytów na uniwersytetach zagranicznych: w University of Notre Dame, South Bend, IN, USA (V.1984-XII.1985) i w Universidad Complutense de Madrid, Instituto de Magnetismo Aplicado, Madryt, Hiszpania, (XI.1991-X.1993). Wypromował 9 doktorów. Od 2004 członek Komitetu Nauki o Materiałach Polskiej Akademii Nauk (od 2019 Komitet Inżynierii Materiałowej i Metalurgii PAN), a w kadencji 2007–2010 zastępca przewodniczącego w tymże komitecie. W latach 2008–2015 wiceprezes Polskiej Izby Gospodarczej Zaawansowanych Technologii, a od 2015 członek Rady Izby. Członek pięciu Rad Naukowych: Instytutu Energii Atomowej w Świerku (2003-2011)Środowiskowego Laboratorium Ciężkich Jonów UW (2006-2014), Instytutu Mechaniki Precyzyjnej (2007-2017), Przemysłowego Instytutu Automatyki i Pomiarów PIAP (2011-2015) oraz Instytutu Ceramiki i Materiałów Budowlanych (2015-2019). Polski ekspert rządowy w dziedzinie nanomateriałów (3 priorytet) w Komitecie Programowym i Eksperckiej Grupie Doradczej 6. PR UE w Brukseli (2002-2006)[5]. Członek międzynarodowych komitetów naukowo-sterujących trzech prestiżowych konferencji: International Symposium on Metastable, Amorphous and Nanostructured Materials (od 2006), Rapidly Quenched and Metastable Materials (od 2008) i Soft Magnetic Materials (od 2013) [5]. Przewodniczący Komitetu Organizacyjnego czterech międzynarodowych konferencji: "Fabrication and Properties of Metallic Nanomaterials" (2004), 13th International Symposium on Metastable, Amorphous and Nanostructured Materials (2006), Sympozjum H Bulk Amorphous and Nanocrystalline Materials – E-MRS Fall Meeting (2009) oraz dwóch połączonych konferencji RQ 17 i ISMANAM 27 (2022). Wielokrotnie otrzymywał nagrody uczelniane i ministerialnew tym nagrodę indywidualną MEN za rozprawę habilitacyjną (2000). W 2014 odznaczony Złotym Krzyżem Zasługi, w 2016 Medalem Komisji Edukacji Narodowej, a w 2020 Krzyżem Kawalerskim Orderu Odrodzenia Polski. Wybrane publikacje T. Kulik, H.T. Savage, A. Hernando, A high‑performance hysteresis loop tracer, J. Appl. Phys., 73 (1993) 6855-6857. https://www.researchgate.net/deref/http%3A%2F%2Fdx.doi.org%2F10.1063%2F1.352461 A. Hernando, M. Vázquez, T. Kulik, C. Prados, Analysis of the dependence of spin-spin correlations on the thermal treatment of nanocrystalline materials, Phys. Rev. B, 51 (1995) 3581-3586. https://doi.org/10.1103/physrevb.51.3581 T. Kulik, Nanocrystallization of metallic glasses, J. Non-Crystalline Solids 287 (2001) 145-161. https://doi.org/10.1016/S0022-3093(01)00627-5 J. Dąbrowa, W. Kucza, G. Cieślak, T. Kulik, M. Danielewski, J.W. Yeh, Interdiffusion in the FCC-structured Al-Co-Cr-Fe-Ni high entropy alloys: Experimental studies and numerical simulations, Journal of Alloys and Compounds 674 (2016) 455-462. https://doi.org/10.1016/j.jallcom.2016.03.046 M. Krasnowski, S. Gierlotka, S. Ciołek, T. Kulik, Nanocrystalline NiAl intermetallic alloy with high hardness produced by mechanical alloying and hot-pressing consolidation, Advanced Powder Technology 30 (2019) 1312–1318. https://doi.org/10.1016/j.apt.2019.04.006 C.M. Meylan, F. Papparotto, S. Nachum, J. Orava, M. Miglierini, V. Basykh, J. Ferenc, T. Kulik, A.L. Greer, Stimulation of shear-transformation zones in metallic glasses by cryogenic thermal cycling, Journal of Non-Crystalline Solids 548 (2020) 120299. https://doi.org/10.1016/j.jnoncrysol.2020.120299 Przypisy Wykładowcy Politechniki Warszawskiej Absolwenci polskich politechnik Absolwenci Politechniki Warszawskiej Polscy inżynierowie technolodzy Polscy inżynierowie metalurdzy Urodzeni w 1952
{ "redpajama_set_name": "RedPajamaWikipedia" }
1,543
{"url":"https:\/\/www.aimsciences.org\/article\/doi\/10.3934\/dcdsb.2018046","text":"# American Institute of Mathematical Sciences\n\n\u2022 Previous Article\nLinear type centers of polynomial Hamiltonian systems with nonlinearities of degree 4 symmetric with respect to the y-axis\n\u2022 DCDS-B\u00a0Home\n\u2022 This Issue\n\u2022 Next Article\nOuter synchronization of delayed coupled systems on networks without strong connectedness: A hierarchical method\nMarch\u00a0 2018,\u00a023(2):\u00a0861-885. doi:\u00a010.3934\/dcdsb.2018046\n\n## Hopf bifurcation of an age-structured virus infection model\n\n 1 Faculty of Mathematics, K. N. Toosi University of Technology, P. O. Box:16315-1618, Tehran, Iran 2 Department of Mathematics, University of Louisiana, Lafayette, LA, USA 3 Department of Mathematical Sciences, Sharif University of Technology, P. O. Box: 11155-9415, Tehran, Iran\n\n* Corresponding author\n\nThe first author is supported by The Department of Iranian Student Affairs\n\nReceived\u00a0 December 2016 Revised\u00a0 September 2017 Published\u00a0 December 2017\n\nIn this paper, we introduce and analyze a mathematical model of a viral infection with explicit age-since infection structure for infected cells. We extend previous age-structured within-host virus models by including logistic growth of target cells and allowing for absorption of multiple virus particles by infected cells. The persistence of the virus is shown to depend on the basic reproduction number $R_{0}$. In particular, when $R_{0}\u22641$, the infection free equilibrium is globally asymptotically stable, and conversely if $R_{0}> 1$, then the infection free equilibrium is unstable, the system is uniformly persistent and there exists a unique positive equilibrium. We show that our system undergoes a Hopf bifurcation through which the infection equilibrium loses the stability and periodic solutions appear.\n\nCitation: Hossein Mohebbi, Azim Aminataei, Cameron J. Browne, Mohammad Reza Razvan. Hopf bifurcation of an age-structured virus infection model. Discrete & Continuous Dynamical Systems - B, 2018, 23 (2) : 861-885. doi: 10.3934\/dcdsb.2018046\n##### References:\n\nshow all references\n\n##### References:\nA numerical solution of system (40) tends to the infection-free equilibrium $E_0$, as time tends to infinity, wherein parameter values are $[s, k, T_{0}, p, d, \\gamma, \\delta] = [0.038, 0.0045, 4.6137, 1, 0.093, 0.4, 0.028]$. In this case $R_0 = 0.6518$. (A) Time series of $T$, $T^*$ and $V$. (B) An orbit in the $TVT^*$ space. Eigenvalues of linearized matrix about $\\overline{E}$ are $\\lambda_1 =-0.0779 + 0.0000i, \\lambda_2 = 0.0004 - 0.0209i, \\lambda_3 =0.0004 + 0.0209i.$\nA numerical solution of system (40) approaches to $\\overline{E}$, as time tends to infinity, and $\\bar{E}$ is stable, wherein parameter values are $[s, k, T_{0}, p, d, \\gamma, \\delta] =$ $[0.03285, 0.01, 4.6137, 1.3, 0.045, 0.1, 0.0351]$. In this case $R_0 = 16.0999$, $\\bar{E} = (\\bar{T},\\bar{V},\\bar{I}) =[0.2212, 3.1275, 0.1971]$. (A) Time series of $T$, $T^*$ and $V$. (B) An orbit in the $TVT^*$ space.\nA numerical solution of system (40) tends to the limit cycle, as time tends to infinity, and $\\bar{E}$ is unstable, wherein parameter values are $[s, k, T_{0}, p, d, \\gamma, \\delta] =$ $[0.03285, 0.01, 4.6137, 1.3, 0.03, 0.1, 0.0351]$. In this case $R_0 = 22.4437$, $(\\bar{T},\\bar{V},\\bar{I}) =[ 0.1115, 3.2056, 0.1018]$. (A) Time series of $T$, $T^*$ and $V$. (B) An orbit in the $TVT^*$ space. Eigenvalues of linearized matrix about $\\overline{E}$ are $\\lambda_1 =-0.0779 + 0.0000i, \\lambda_2 = 0.0004 - 0.0209i, \\lambda_3 =0.0004 + 0.0209i.$\nA numerical solution of system (41)-(44) tends to the DFE, as time tends to infinity, wherein parameter values are $[s,T0,k,\\rho,d,\\gamma,\\tau,\\mu,\\nu] =$ $[.1,100000,0.0000005,200,13,0.000003,2,0.05,0.7]$. In this case $R_0 =0.9905$ and $(\\bar{T},\\bar{V},\\bar{I}) =[ 10^5, 0 , 0]$. (A) Time series of $T$, $T^* = J+I$ and $V$. (B) An orbit in the $TVT^*$ space.\nA numerical solution of system (41)-(44) tends to the $\\bar{E}$, as time tends to infinity, and $\\bar{E}$ is stable, wherein parameter values are $[s,T0,k,\\rho,d,\\gamma,\\tau,\\mu,\\nu] =$ $[.1,100000,0.0000008,200,13,0.000003,2,0.05,0.7]$. In this case $R_0 =1.5812$, $(\\bar{T},\\bar{V},\\bar{J}+\\bar{I}) =[ 6.3209\\times 10^4, 4.5989\\times 10^4, 7.4321\\times 10^3]$. The probability of re-infection of infected cells during eclipse phase (during age $0\\leq a \\leq \\tau$) calculated at $\\bar{E}$ is $\\pi(\\tau) = 0.23$. (A) Time series of $T$, $T^* = J+I$ and $V$. (B) An orbit in the $TVT^*$ space.\nA numerical solution of system (41)-(44) tends to the limit cycle, as time tends to infinity, and $\\bar{E}$ is unstable, wherein parameter values are $[s,T0,k,\\rho,d,\\gamma,\\tau,\\mu,\\nu] =$ $[1,100000, 0.000005,200, 13, 0.000001, 2, 0.05, 0.7]$. In this case $R_0 =9.5750$, $(\\bar{T},\\bar{V},\\bar{J}+\\bar{I}) =[ 1.0119\\times 10^4, 1.7976\\times 10^5, 2.9066\\times 10^4]$. The probability of re-infection of infected cells during eclipse phase calculated at $\\bar{E}$ is $\\pi(\\tau) = 0.2882$. (A) Time series of $T$, $T^* = J+I$ and $V$. (B) An orbit in the $TVT^*$ space.\nParameter definition and values from literatures.\n Parameter Value Description Reference $e$ day$^{-1}$ Maximum proliferation rate See text $g$ 0.008 day$^{-1}$ Death rate of uninfected cells [27] $T_{\\text{max}}$ mm$^{-3}$ Density of $T$ cell at which proliferation shouts off See text $k$ $5 \\times 10^{-7}$ ml virion day$^{-1}$ Infection rate of target cells by virus [27] $\\delta$ 0.8 day$^{-1}$ Death rate of infected cells [32] p Varied Virion production rate of an infected cell See text $d$ 3 day$^{-1}$ clearance rate of free virus [22] $\\gamma$ day$^{-1}$ Reinfection rate of infected cells by virus See text\n Parameter Value Description Reference $e$ day$^{-1}$ Maximum proliferation rate See text $g$ 0.008 day$^{-1}$ Death rate of uninfected cells [27] $T_{\\text{max}}$ mm$^{-3}$ Density of $T$ cell at which proliferation shouts off See text $k$ $5 \\times 10^{-7}$ ml virion day$^{-1}$ Infection rate of target cells by virus [27] $\\delta$ 0.8 day$^{-1}$ Death rate of infected cells [32] p Varied Virion production rate of an infected cell See text $d$ 3 day$^{-1}$ clearance rate of free virus [22] $\\gamma$ day$^{-1}$ Reinfection rate of infected cells by virus See text\n [1] Bernold Fiedler. Global Hopf bifurcation in networks with fast feedback cycles. Discrete & Continuous Dynamical Systems - S, 2021, 14 (1) : 177-203. doi: 10.3934\/dcdss.2020344 [2] Min Chen, Olivier Goubet, Shenghao Li. Mathematical analysis of bump to bucket problem. Communications on Pure & Applied Analysis, 2020, 19 (12) : 5567-5580. doi: 10.3934\/cpaa.2020251 [3] Vieri Benci, Sunra Mosconi, Marco Squassina. Preface: Applications of mathematical analysis to problems in theoretical physics. Discrete & Continuous Dynamical Systems - S, 2020\u00a0 doi: 10.3934\/dcdss.2020446 [4] Susmita Sadhu. Complex oscillatory patterns near singular Hopf bifurcation in a two-timescale ecosystem. Discrete & Continuous Dynamical Systems - B, 2020\u00a0 doi: 10.3934\/dcdsb.2020342 [5] Kerioui Nadjah, Abdelouahab Mohammed Salah. Stability and Hopf bifurcation of the coexistence equilibrium for a differential-algebraic biological economic system with predator harvesting. Electronic Research Archive, 2021, 29 (1) : 1641-1660. doi: 10.3934\/era.2020084 [6] Xianyong Chen, Weihua Jiang. Multiple spatiotemporal coexistence states and Turing-Hopf bifurcation in a Lotka-Volterra competition system with nonlocal delays. Discrete & Continuous Dynamical Systems - B, 2020\u00a0 doi: 10.3934\/dcdsb.2021013 [7] Yining Cao, Chuck Jia, Roger Temam, Joseph Tribbia. Mathematical analysis of a cloud resolving model including the ice microphysics. Discrete & Continuous Dynamical Systems - A, 2021, 41 (1) : 131-167. doi: 10.3934\/dcds.2020219 [8] Martin Kalousek, Joshua Kortum, Anja Schl\u00f6merkemper. Mathematical analysis of weak and strong solutions to an evolutionary model for magnetoviscoelasticity. Discrete & Continuous Dynamical Systems - S, 2021, 14 (1) : 17-39. doi: 10.3934\/dcdss.2020331 [9] Sarra Nouaoura, Radhouane Fekih-Salem, Nahla Abdellatif, Tewfik Sari. Mathematical analysis of a three-tiered food-web in the chemostat. Discrete & Continuous Dynamical Systems - B, 2020\u00a0 doi: 10.3934\/dcdsb.2020369 [10] Tetsuya Ishiwata, Young Chol Yang. Numerical and mathematical analysis of blow-up problems for a stochastic differential equation. Discrete & Continuous Dynamical Systems - S, 2021, 14 (3) : 909-918. doi: 10.3934\/dcdss.2020391 [11] Mohamed Dellal, Bachir Bar. Global analysis of a model of competition in the chemostat with internal inhibitor. Discrete & Continuous Dynamical Systems - B, 2021, 26 (2) : 1129-1148. doi: 10.3934\/dcdsb.2020156 [12] Alexander Dabrowski, Ahcene Ghandriche, Mourad Sini. Mathematical analysis of the acoustic imaging modality using bubbles as contrast agents at nearly resonating frequencies. Inverse Problems & Imaging, , () : -. doi: 10.3934\/ipi.2021005 [13] Yangjian Sun, Changjian Liu. The Poincar\u00e9 bifurcation of a SD oscillator. Discrete & Continuous Dynamical Systems - B, 2021, 26 (3) : 1565-1577. doi: 10.3934\/dcdsb.2020173 [14] Xin Guo, Lexin Li, Qiang Wu. Modeling interactive components by coordinate kernel polynomial models. Mathematical Foundations of Computing, 2020, 3 (4) : 263-277. doi: 10.3934\/mfc.2020010 [15] Wenxiong Chen, Congming Li, Shijie Qi. A Hopf lemma and regularity for fractional $p$-Laplacians. Discrete & Continuous Dynamical Systems - A, 2020, 40 (6) : 3235-3252. doi: 10.3934\/dcds.2020034 [16] Philippe G. Ciarlet, Liliana Gratie, Cristinel Mardare. Intrinsic methods in elasticity: a mathematical survey. Discrete & Continuous Dynamical Systems - A, 2009, 23 (1&2) : 133-164. doi: 10.3934\/dcds.2009.23.133 [17] M. Dambrine, B. Puig, G. Vallet. A mathematical model for marine dinoflagellates blooms. Discrete & Continuous Dynamical Systems - S, 2021, 14 (2) : 615-633. doi: 10.3934\/dcdss.2020424 [18] Yifan Chen, Thomas Y. Hou. Function approximation via the subsampled Poincar\u00e9 inequality. Discrete & Continuous Dynamical Systems - A, 2021, 41 (1) : 169-199. doi: 10.3934\/dcds.2020296 [19] Chun Liu, Huan Sun. On energetic variational approaches in modeling the nematic liquid crystal flows. Discrete & Continuous Dynamical Systems - A, 2009, 23 (1&2) : 455-475. doi: 10.3934\/dcds.2009.23.455 [20] Jean-Paul Chehab. Damping, stabilization, and numerical filtering for the modeling and the simulation of time dependent PDEs. Discrete & Continuous Dynamical Systems - S, 2021\u00a0 doi: 10.3934\/dcdss.2021002\n\n2019\u00a0Impact Factor:\u00a01.27","date":"2021-01-23 08:49:23","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.5632452368736267, \"perplexity\": 3265.406978041752}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2021-04\/segments\/1610703536556.58\/warc\/CC-MAIN-20210123063713-20210123093713-00356.warc.gz\"}"}
null
null
<?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/android"> <item android:state_enabled="false" android:color="@color/privacy_cloud_txt_press_color" /> <item android:state_pressed="true" android:color="@color/privacy_cloud_txt_press_color" /> <item android:state_focused="true" android:color="@color/privacy_cloud_txt_press_color" /> <item android:state_selected="true" android:color="@color/privacy_cloud_txt_press_color" /> <item android:color="@color/privacy_cloud_txt_color" /> </selector>
{ "redpajama_set_name": "RedPajamaGithub" }
4,738
\section{Introduction} A fundamental probe in modern astronomy to understand the Universe, its history and evolution, is the measurement of distances. Stellar parallax and the spectroscopic parallax allow us to reach $\sim$ 100-1000 pc, respectively but farther afield other methods are needed. A traditional technique for measuring distances consists in applying the inverse square law for astrophysical sources with known absolute magnitudes, aka, as standard candles. One of the first such objects used in astronomy were Cepheid stars. A Cepheid star's period is directly related to its intrinsic luminosity \citep{Leavitt08,benedict07} and allows one to probe the Universe to 15 Mpc. To attain larger distances brighter objects are required. Type Ia supernovae (SNe~Ia), have an absolute $B$-band magnitude about -19.5 -- -19.2 mag (depending on the assumptions of H$_{0}$ \citealt{richardson02,riess11}) which can be precisely calibrated using photometric and/or spectroscopic information from the SN itself, and be used as excellent distance indicators. Indeed, there are two parameters correlated to the luminosity. The first one is the decline rate: SNe~Ia with fast decline rates are fainter and have narrower light-curve peaks \citep{phillips93} and the second one, the colour \citep{riess96,tripp98}: redder SNe~Ia are fainter. The standardisation of SNe~Ia to a level $\sim$ 0.15--0.2 mag \citep{phillips93,hamuy96,riess96}, led to the measurement of the expansion history of the Universe and showed that, contrary to expectations, the Universe is undergoing an accelerated expansion \citep{riess98,perlmutter99,schmidt98}. Within this new paradigm, one of the greatest challenges is the search for the mechanism that causes the acceleration, an endeavour that will require exquisitely precise measurements of the cosmological parameters that characterise the current cosmological concordance model, i.e., $\Lambda$$CDM$ model. Several techniques that offer the promise to provide such constraints have been put forward over recents years: refined versions of the SNe~Ia method (\citealt{betoule14}), cosmic microwave background radiation measurements (Cosmic Microwave Background Explorer, \citealt{fixsen96,jaffe01}; Wilkinson Microwave Anisotropy Probe, \citealt{spergel07,bennett03}; and more recently the Planck mission, \citealt{planck13}), and baryon acoustic oscillation measurements (\citealt{blake03,seo03}). All of the above techniques have their own merits, but also their own systematic uncertainties that could become dominant with the increasingly higher level of precision required. Thus, it is important to develop as many methods as possible, since the truth will likely emerge from the combination of different independent approaches.\\ \indent While SNe~Ia have been used as the primary diagnostic in constraining cosmological parameters, type IIP supernovae (SNe~IIP) have also been established to be useful independent distance indicators. SNe~IIP are 1--2 mag less luminous than the SNe~Ia however, their intrinsic rate is higher than SNe~Ia rate \citep{li2011}, and additionally the rate peaks at higher redshifts than SNe~Ia \citep{taylor14}, which motivates their use in the cosmic distance scale (see \citealt{hamuy02}). Also the fact that in principle they are the result of the same physical mechanism, and their progenitors are better understood than those of SNe~Ia, further encourages investigations in this direction. SNe~IIP are thought to be core-collapse supernovae (CCSNe), i.e., the final explosion of stars with zero-age main-sequence mass $\geq$ 8 ${\rm M}_{\odot}$ \citep{smart09b}. CCSNe have diverse classes, with a large range of observed luminosities, light-curve shapes, and spectroscopic features. CCSNe are classified in two groups according to the absence (SNe~Ib/c :\citealt{filippenko93,dessart11,bersten14,Kuncarayakti15}) or presence (SNe~II) of \ion{H}{1} lines (\citealt{min41,filippenko97} and references therein). Additional of the SNe~IIP and SNe~IIL which are discussed later, SNe~II are composed by SNe~IIb which evolve spectroscopically from SNe~IIP at early time to \ion{H}{1} deficient few weeks to a month past maximum \citep{woosley87} and SNe~IIn which have narrow \ion{H}{1} emission lines (\citealt{che81,fra82,sch90,chu94,van00,kan12,dejaeger15a}). \indent Historically, SNe~II were separated in two groups: SNe~IIP (70\% of CCSNe; \citealt{li2011}), which are characterised by long duration plateau phases ($\leq$~100~days) of constant luminosity, and SNe~IIL which have linearly declining light-curve morphologies \citep{barbon79}. However, as discussed in detail in \citet{anderson14a}, it is not clear how well this terminology describes the diversity of SNe~II. There are few SNe~II which show flat light-curves, and in addition there are very few (if any) SNe which decline linearly before falling onto the radioactive tail. Therefore, henceforth we simply refer to all SNe with distinct decline rates collectively as SNe~II, and later further discuss SNe in terms of their ``$s_{2}$'' plateau decline rates \citep{anderson14a}. \citet{sanders15} also suggested that the SNe~II family forms a continuous class, while \citet{arcavi13} and \citet{faran14b,faran14a} have argued for two separate populations.\\ \indent The most noticeable difference between SNe~II occurs during the plateau phase. The optically thick phase is physically well-understood and is due to a change in opacity and density in the outermost layers of the SN. At the beginning the hydrogen present in the outermost layers of the progenitor star is ionised by the shock wave, which implies an increase of the opacity and the density which prevent the radiation from the inner parts to escape. After a few weeks, the star has cooled to the temperature allowing the recombination of ionised hydrogen (higher than 5000 K due to the large optical depth). The ejecta expand and the photosphere recedes in mass space, releasing the energy stored in the corresponding layers. The plateau morphology requires a recession of the photosphere in mass that corresponds to a fixed radius in space so that luminosity appears constant. As \citet{anderson14a} show, this delicate balance is rarely observed and there is significant diversity observed in the $V$-band light-curve. To reproduce the plateau morphology, hydrodynamical models have used red supergiant progenitors with extensive H envelopes \citep{grassberg71,falk77,chevalier76}. Direct detections of the progenitor of SNe~IIP have confirmed these models (\citealt{vandyk03,smartt09a}). It has also been suggested that SN~IIL progenitors may be more massive in the zero age main sequence than SNe~IIP \citep{EliasRosa10,EliasRosa11} and with smaller hydrogen envelopes \citep{popov93}.\\ \indent To date several methods have been developed to standardise SNe~II. The first method called the ``Expanding Photosphere Method'' (EPM) was developed by \citet{kirshner74} and allows one to obtain the intrinsic luminosity assuming that SNe~II radiate as dilute blackbodies, and that the SN freely expands with spherical symmetry. The EPM was implemented for the first time on a large number of objects by \citet{schmidt94} and followed by many studies \citep{hamuy01,leonard03,dessart05,dessart06,jones09,enriquez11}. One of the biggest issues with this method is the EPM only works if one corrects for the blackbody assumptions which requires corrections factors computed from model atmospheres (\citealt{eastman96,dessart05} and see \citealt{dessart06} for the resolution of the EPM-based distance problem to SN 1999em). Also to avoid the problem in the estimation of the dilution factor, \citet{baron04} proposed a distance correcting factor that takes into account the departure of the SN atmosphere from a perfect blackbody, the ``Spectral-fitting Expanding Atmosphere Method'' (SEAM, updated in \citealt{dessart08}). This method consists of fitting the observed spectrum using an accurate synthetic spectrum of SNe~II, and then since the spectral energy distribution is completely known from the calculated synthetic spectra, one may calculate the absolute magnitude in any band.\\ \indent A simpler method, also based on photometric and spectroscopic parameters, the ``Standardised Candle Method'' (SCM) was first introduced by \citet{hamuy02}. They found that the luminosity and the expansion velocity are correlated when the SN is in its plateau phase (50 days post explosion). This relation is physically well understood: for a more luminous SN, the hydrogen recombination front will be at a larger radius thereby the velocity of the photosphere will be greater \citep{kasen09} for a given post-explosion time. Thanks to this method the scatter in the Hubble diagram (hereafter Hubble diagram) drops from 0.8 mag to 0.29 mag in the $I$-band. \citet{nugent06} improved this method by adding an extinction correction based on the $(V-I)$ colour at day 50 after maximum. This new method is very powerful and many other studies \citep{nugent06,poznanski09,olivares10,andrea10} have confirmed the possibility to use SNe~II as standard candles finding a scatter between 10 and 18\% in distance. Recently \citet{maguire10} suggested that using near-infrared (NIR) filters, the SCM, the dispersion can drop to a level of 0.1--0.15 mag (using 12 SNe~IIP). Indeed, in the NIR the host-galaxy extinction is less important, thus there may be less scatter in magnitude. Note also the work done by \citet{rodriguez14} where the authors used the Photospheric Magnitude Method (PMM) which correspond to a generalisation of the SCM for various epochs throughout the photospheric phase and found a dispersion of 0.12 mag using 13 SNe. This is an intrinsic dispersion and is not the RMS.\\ \indent The main purpose of this work is to derive a method to obtain purely photometric distances, i.e, standardise SNe~II only using light-curves and colour-curve parameters, unlike other methods cited above which require spectroscopic parameters. This is a big issue, and purely photometric methods will be an asset for the next generation of surveys such as the large synoptic survey telescope (LSST; \citealt{ivezic09,lien14LSST}). These surveys will discover such a large number of SNe that spectroscopic follow-up will be impossible for all but only for small number of events. This will prevent the use of current methods to standardise SNe~II and calculate distances. Therefore deriving distances with photometric data alone is important and useful for the near future but also allows us to reach higher distance due to the fact that getting even one spectrum for a SN~II at $z\geq 1$ is very challenging.\\ \indent The paper is organised as follows. In section 2 a description of the data set is given and in section 3 we explain how the data are corrected for Milky Way (MW) extinction and how the K-correction is applied. In section 4 we describe the photometric colour method (PCM) using optical and NIR filters and we derive a photometric Hubble diagram. In section 5 we present a comparative Hubble diagram using the SCM. In section 6 we compare our method with the SCM and we conclude with a summary in Section 7. \section{Data Sample} \subsection{Carnegie Supernova Project} The \textit{Carnegie Supernova Project}\footnote{\url{http://csp.obs.carnegiescience.edu/}} (CSP, \citealt{ham06}) provided all the photometric and spectroscopic data for this project. The goal of the CSP was to establish a high-cadence data set of optical and NIR light-curves in a well-defined and well-understood photometric system and obtain optical spectra for these same SNe. Between 2004 and 2009, the CSP observed many low redshift SNe~II ($N_{SNe}\sim 100$ with $z \leq 0.04$), 56 had both optical and NIR light-curves with good temporal coverage; one of the largest NIR data samples. Two SN 1987A-like events were removed (SN 2006V and SN 2006au see \citealt{taddia12}) living the sample listed in Table~\ref{parameters} with photometric parameters measured by \citet{anderson14a}. Note that we do not include SNe~IIb or SNe~IIn.\\ \begin{table*} \begin{center} \caption{SN~II parameters} \begin{tabular}{cccccccc} \hline SN & AvG & v$_{helio}$ & v$_{CMB}$& Explosion date & $s_{1}$ & $s_{2}$ &OPTd\\ &(mag)&(km s$^{-1}$)&(km s$^{-1}$)&(MJD)&(mag 100d$^{-1}$)&(mag 100d$^{-1}$)&(days)\\ \hline \hline 2004ej &0.189 &2723(6) &3045(23) &53224.90(5) &$\cdots$ &1.07(0.04) &96.14\\ 2004er &0.070 &4411(33) &4186(37) &53271.80(4) &1.28(0.03) &0.40(0.03) &120.15\\ 2004fc &0.069 &1831(5) &1560(20) &53293.50(10) &$\cdots$ &0.82(0.02) &106.06\\ 2004fx &0.282 &2673(3) &2679(3) &53303.50(4) &$\cdots$ &0.09(0.03) &68.40\\ 2005J &0.075 &4183(1) &4530(24) &53382.78(7) &2.11(0.07) &0.96(0.02) &94.03\\ 2005Z &0.076 &5766(10) &6088(25) &53396.74(8) &$\cdots$ &1.83(0.01) &78.84\\ 2005an &0.262 &3206(31) &3541(39) &53428.76(4) &3.34(0.06) &1.89(0.05) &77.71\\ 2005dk &0.134 &4708(25) &4618(26) &53599.52(6) &2.26(0.09) &1.18(0.07) &84.22\\ 2005dn &0.140 &2829(17) &2693(20) &53601.56(6) &$\cdots$ &1.53(0.02) &79.76\\ 2005dw &0.062 &5269(10) &4974(23) &53603.64(9) &$\cdots$ &1.27(0.04) &92.59\\ 2005dx &0.066 &8012(31) &7924(31) &53615.89(7) &$\cdots$ &1.30(0.05) &85.59\\ 2005dz &0.223 &5696(8) &5327(27) &53619.50(4) &1.31(0.08) &0.43(0.04) &81.86\\ 2005es &0.228 &11287(49) &10917(55) &53638.70(10) &$\cdots$ &1.31(0.05) &$\cdots$\\ 2005gk &0.154 &8773(10) &8588(30) &$\cdots$ &$\cdots$ &1.25(0.07) &$\cdots$\\ 2005hd &0.173 &8323(10) &8246(30) &$\cdots$ &$\cdots$ &1.83(0.13) &$\cdots$\\ 2005lw &0.135 &7710(29) &8079(39) &53716.80(10) &$\cdots$ &2.05(0.04) &107.23\\ 2006Y &0.354 &10074(10) &10220(30) &53766.50(4) &8.15(0.76) &1.99(0.12) &47.49\\ 2006ai &0.347 &4571(10) &4637(30) &53781.80(5) &4.97(0.17) &2.07(0.04) &63.26\\ 2006bc &0.562 &1363(10) &1476(13) &53815.50(4) &1.47(0.18) &-0.58(0.04) &$\cdots$\\ 2006be &0.080 &2145(9) &2243(11) &53805.81(6) &1.26(0.08) &0.67(0.02) &72.89\\ 2006bl &0.144 &9708(49) &9837(50) &53823.81(6) &$\cdots$ &2.61(0.02) &$\cdots$\\ 2006ee &0.167 &4620(19) &4343(27) &53961.88(4) &$\cdots$ &0.27(0.02) &85.17\\ 2006it &0.273 &4650(9) &4353(23) &54006.52(3) &$\cdots$ &1.19(0.13) &$\cdots$\\ 2006ms &0.095 &4543(18) &4401(21) &54034.00(13) &2.07(0.30) &0.11(0.48) &$\cdots$\\ 2006qr &0.126 &4350(5) &4642(21) &54062.80(7) &$\cdots$ &1.46(0.02) &96.85\\ 2007P &0.111 &12224(25) &12570(35) &54118.71(3) &$\cdots$ &2.36(0.04) &84.33\\ 2007U &0.145 &7791(9) &7795(9) &54134.61(6) &2.94(0.02) &1.18(0.01) &$\cdots$\\ 2007W &0.141 &2902(2) &3215(22) &54136.80(7) &$\cdots$ &0.12(0.04) &77.29\\ 2007X &0.186 &2837(6) &3055(16) &54143.85(5) &2.43(0.06) &1.37(0.03) &97.71\\ 2007aa &0.072 &1465(4) &1826(26) &54135.79(5) &$\cdots$ &-0.05(0.02) &67.26\\ 2007ab &0.730 &7056(13) &7091(13) &54123.86(6) &$\cdots$ &3.30(0.08) &71.30\\ 2007av &0.099 &1394(3) &1742(24) &54175.76(5) &$\cdots$ &0.97(0.02) &$\cdots$\\ 2007hm &0.172 &7540(15) &7241(26) &54335.64(6) &$\cdots$ &1.45(0.04) &$\cdots$\\ 2007il &0.129 &6454(10) &6146(24) &54349.77(4) &$\cdots$ &0.31(0.02) &103.43\\ 2007oc &0.061 &1450(5) &1184(19) &54382.51(3) &$\cdots$ &1.83(0.01) &77.61\\ 2007od &0.100 &1734(3) &1377(25) &54402.59(5) &2.37(0.05) &1.55(0.01) &$\cdots$\\ 2007sq &0.567 &4579(4) &4874(21) &54421.82(3) &$\cdots$ &1.51(0.05) &88.34\\ 2008F &0.135 &5506(21) &5305(25) &54470.58(6) &$\cdots$ &0.45(0.10) &$\cdots$\\ 2008K &0.107 &7997(10) &8351(27) &54477.71(4) &$\cdots$ &2.72(0.02) &87.1\\ 2008M &0.124 &2267(4) &2361(8) &54471.71(9) &$\cdots$ &1.14(0.02) &75.34\\ 2008W &0.267 &5757(45) &6041(49) &54485.78(6) &$\cdots$ &1.11(0.04) &83.86\\ 2008ag &0.229 &4439(6) &4428(6) &54479.85(6) &$\cdots$ &0.16(0.01) &102.95\\ 2008aw &0.111 &3110(4) &3438(23) &54517.79(10) &3.27(0.06) &2.25(0.03) &75.83\\ 2008bh &0.060 &4345(8) &4639(22) &54543.54(5) &3.00(0.27) &1.20(0.04) &$\cdots$\\ 2008bk &0.054 &230(4) &-50(20) &54542.89(6) &$\cdots$ &0.11(0.02) &104.83\\ 2008bu &1.149 &6630(9) &6683(10) &54566.78(5) &$\cdots$ &2.77(0.14) &44.75\\ 2008ga &1.865 &4639(3) &4584(5) &54711.85(4) &$\cdots$ &1.17(0.08) &72.79\\ 2008gi &0.181 &7328(34) &7103(37) &54742.72(9) &$\cdots$ &3.13(0.08) &$\cdots$\\ 2008gr &0.039 &6831(41) &6549(46) &54766.55(4) &$\cdots$ &2.01(0.01) &$\cdots$\\ 2008hg &0.050 &5684(10) &5449(19) &54779.75(5) &$\cdots$ &-0.44(0.01) &$\cdots$\\ 2009N &0.057 &1036(2) &1386(25) &54846.79(5) &$\cdots$ &0.34(0.01) &89.50\\ 2009ao &0.106 &3339(5) &3665(23) &54890.67(4) &$\cdots$ &-0.01(0.12) &41.71\\ 2009bu &0.070 &3494(9) &3372(13) &54907.91(6) &0.98(0.16) &0.18(0.04) &$\cdots$\\ 2009bz &0.110 &3231(7) &3393(13) &54915.83(4) &$\cdots$ &0.50(0.02) &$\cdots$\\ \hline \hline \setcounter{table}{2} \end{tabular} \tablecomments{SN and light curve parameters. In the first column the SN name, followed by its reddening due to dust in our Galaxy \citep{schlafly11} are listed. In column 3 we list the host-galaxy heliocentric recession velocity. These are taken from the NASA Extragalactic Database (NED: \url{http://ned.ipac.caltech.edu/}). In column 4 we list the host-galaxy velocity in the CMB frame using the CMB dipole model presented by \citet{fixsen96}. In column 5 the explosion epochs is presented. In columns 6 and 7 we list the decline rate $s_{1}$ and $s_{2}$ in the $V$-band, where $s_{1}$ is the initial, steeper slope of the light-curve and $s_{2}$ is the decline rate of the plateau as defined by \citet{anderson14a} . Finally column 8 presents the optically thick phase duration (OPTd) values, i.e., the duration of the optically thick phase from explosion to the end of the plateau (see \citealt{anderson14a})} \label{parameters} \end{center} \end{table*} \subsection{Data reduction} \subsubsection{Photometry} All the photometric observations were taken at the Las Campanas Observatory (LCO) with the Henrietta Swope 1-m and the Ir\'en\'ee du Pont 2.5-m telescopes using optical ($u$, $g$, $r$, $i$, $B$, and $V$), and NIR filters ($Y$, $J$, and $H$, see \citealt{stritzinger11}). \indent All optical images were reduced in a standard way including bias subtractions, flat-field corrections, application of a linearity correction and an exposure time correction for a shutter time delay. The NIR images were reduced through the following steps: dark subtraction, flat-field division, sky subtraction, geometric alignment and combination of the dithered frames. Due to the fact that SN measurements can be affected by the underlying light of their host galaxies, we took care in correctly removing the underlying host-galaxy light. The templates used for final subtractions were always taken months/years after each SN faded and under seeing conditions better than those of the science frames. Because the templates for some SNe were not taken with the same telescope, they were geometrically transformed to each individual science frame. These were then convolved to match the point-spread functions, and finally scaled in flux. The template images were then subtracted from a circular region around the SN position on each science frame (see \citealt{contreras10}).\\ \indent Observed magnitudes for each SN was derived relative to local sequence stars and calibrated from observations of standard stars in the \citet{lan92} ($BV$), \citet{smithja2002} ($u'g'r'i'$), and \citet{persson04} ($YJHKs$) systems. The photometry of the local sequence stars are on average based on at least three photometric nights. Magnitudes are expressed in the natural photometric system of the Swope+CSP bands. Final errors for each SN are the result of the instrumental magnitude uncertainty and the error on the zero point. The full photometric catalog will be published in an upcoming paper (note that the $V$-band photometry has been already published in \citealt{anderson14a}).\\ \subsubsection{Spectroscopy} The majority of our spectra were obtained with the 2.5m Ir\'en\'ee du Pont telescope using the WFCCD- and Boller and Chiven spectrographs (the last is now decommissioned) at LCO. Additional spectra were obtained with the 6.5m Magellan Clay and Baade telescopes with LDSS-2, LDSS-3, MagE (see \citealt{massey12} for details) and IMACS together with the CTIO 1.5m telescope and the Ritchey-Chr\'etien Cassegrain Spectrograph, and the New Technology Telescope (NTT) at La Silla observatory using the EMMI and EFOSC instruments. The majority of the spectra are the combination of three exposures to facilitate cosmics-ray rejection. Information about the grism used, the exposure time, the observation strategy can be found in \citet{ham06,folatelli10}. All spectra were reduced in a standard way as described in \citet{ham06} and \citet{folatelli13}. Briefly, the reduction was done with IRAF\footnote{IRAF is distributed by the National Optical Astronomy Observatory, which is operated by the Association of Universities for Research in Astronomy (AURA) under cooperative agreement with the National Science Foundation.} using the standard routines (bias subtraction, flat-field correction, 1-D extraction, wavelength and flux calibration). The full spectroscopic sample will be published in an upcoming paper and the reader can refer to \citet{anderson14b} and \citet{gutierrez14} for a thorough analysis of this sample.\\ \section{First photometric corrections} In order to proceed with our aim of creating a Hubble diagram based on photometric measurements using the PCM, in this section we show how to correct apparent magnitudes for MW extinction (AvG) and how to apply the K-correction, without the use of observed SN spectra but only with model spectra. \subsection{MW correction} In the $V$ band the determination of AvG can be applied using the extinction maps of \citealt{schlafly11}. To convert AvG to extinction values in other bands we need to adopt: an extinction law and the effective wavelength for each filter.\\ \indent SN~II spectra evolve with time from a blue continuum at early times to a redder continuum with many absorption/emission features at later epochs. This implies that the effective wavelength of a broad-band filter also changes with time (see the formula given \citealt{Bessell12} A.21). To calculate effective wavelengths at different epochs we adopt a sequence of theoretical spectral models from \citet{dessart13} consisting of a SN progenitor with a main-sequence mass of 15 ${\rm M}_{\odot}$, solar metallicity Z=0.02, zero rotation and a mixing-length parameter of 3\footnote{More information about this model (named m15mlt3) can be found in \citet{dessart13}}. The choice of this model is based on the fact that it provided a good match to a prototypical SN~II such as SN~1999em. For each photometric epoch, we choose the closest theoretical spectrum in epoch since the explosion, the extinction law from \citet{car89} and in time $R_{V}=3.1$ to obtain the MW extinction in the other filters.\\ \subsection{K-correction} Having corrected the observed magnitudes for Galactic extinction, we need to apply also a correction attributable to the expansion of the Universe called the K-correction (KC). A photon received in one broad photometric band--pass in the observed referential has not necessarily been emitted (rest--frame referential) in the same filter, that is why this correction is needed. For each epoch of each filter we use the same procedure to estimate the KC. Here we describe our method step by step for one epoch and a given filter X. \begin{enumerate} \item{We choose in our model spectral library (\citealt{dessart13}, model m15mlt3) the theoretical spectrum (rest frame) closest to the photometric epoch since explosion time (corrected for time dilatation), with a rest-frame spectral energy distribution (SED), $f^{rest}({\lambda}_{rest})$. Because our library covers a limited range of epochs from 12.2 to 133 days relative to explosion, observations outside these limits are ignored.} \item{We bring the rest-frame theoretical spectrum to the observer's frame using $(1+z_{hel})$ the correction, where $z_{hel}$ is the heliocentric redshift of the SN, $f^{obs}({\lambda})={f^{rest}({\lambda}_{rest}(1+z_{hel}))} \times 1/(1+z_{hel})$ where $\lambda$ is the wavelength in the observer's frame.} \item{We match the theoretical spectrum to the observed photometric magnitudes of the SN \citep{hsiao07}. For this we calculate synthetic magnitudes (from the model in the observer's frame,$f^{obs}({\lambda})$) and compare them to the observed magnitudes corrected for MW extinction. We use all the filters available at this epoch. Then we obtain a warping function $W(\lambda)$ (quadratic, cubic, depending on the number of filters used) and do a constant extrapolation for the wavelengths outside of the range of filters used. With our warping function we correct our model spectrum and obtain $f^{obs}_{warp}({\lambda})=W(\lambda) \times f^{obs}({\lambda})$. We compute the magnitude in the observer's frame : \[m^{X}_{z}=-2.5log_{10}\left(\frac{1}{hc} \int f^{obs}_{warp}(\lambda)S^{X}_{\lambda}\lambda d\lambda\right)+ZP_{X} \] with c the light velocity in $\rm{\AA}$ s$^{-1}$, $h$ the Planck constant in ergs s, $\lambda$ is wavelength, $S^{X}_{\lambda}$ the transmission function of filter $X$ and $ZP_{X}$ is the zero point of filter $X$ (see \citealt{contreras10,stritzinger11}).} \item{We bring back the warping spectrum to the rest frame $f^{rest}_{warp}(\lambda)=(1+z_{hel})f^{obs}_{warp}(\lambda \times 1/(1+z_{hel}))$ and we obtain and calculate the magnitude : \[m^{X}_{0}=-2.5log_{10}\left(\frac{1}{hc} \int f^{rest}_{warp}(\lambda)S^{X}_{\lambda}\lambda d\lambda\right)+ZP_{X} \]} \item{Finally we obtain the KC for this epoch as the difference between the observed and the rest frame magnitude, $KC_{X}=m^{X}_{z}-m^{X}_{0}$.} \item{To estimate the associated errors, we follow the same procedure but instead of using the observed magnitudes for the warping, we use the upper limit, i.e., observed magnitudes plus associated uncertainties.} \end{enumerate} As a complementary work on the KC and to validate our method we compare the KC values found using the \citet{dessart13} model to those computed from our database of observed spectra. In both cases we use exactly the same procedure. First the observed spectrum is corrected in flux using the observed photometry (corrected for AvG) in order to match the observed magnitudes. The photometry is interpolated to the spectral epoch. In Figure~\ref{model_obs} we show a comparison between the KC obtained with the theoretical models and using our library of observed spectra at different redshifts. As we can see that the KC values calculated with both methods are very consistent. This exercise validates the choice of using the \citet{dessart13} models to calculate the KC. There are two advantages to use the theoretical models. First we can obtain the KC for NIR filters ($Y$, $J$, $H$) for which we do not have observed spectra, and secondly this method does not require observed spectra which are expensive to obtain in terms of telescope time, and virtually impossible to get at higher redshifts. \begin{figure} \includegraphics[width=10.0cm]{fig_1.eps} \caption{Comparison between the KC calculated using the theoretical models and observed spectra at different redshifts in $V$ band. The black dotted line represents x=y. Each square represents one observed spectrum of our database. The colour bar on the right side represents the different redshifts.} \label{model_obs} \end{figure} \section{The photometric colour Method: PCM} In this section we present our PCM with which we derive the corrected magnitudes necessary for constructing the Hubble diagram solely with photometric data. Since we want to examine Hubble diagrams from photometry obtained at different epochs, we start by linearly interpolating colours on a daily basis from colours observed at epochs around the epoch of interest. The same procedure is used to interpolate magnitudes.\\ \subsection{Methodology} To correct and standardise the apparent magnitude we use two photometric parameters: $s_{2}$ which is the slope of the plateau measured in the $V$-band \citep{anderson14a}, and a colour term at a specific epoch. The colour term is mainly used to take into account the dispersion caused by the host-galaxy extinction. The magnitude is standardised using a weighted least-squares routine by minimising the equation below : \begin{equation} m_{\lambda 1}+\alpha s_{2} - \beta_{\lambda 1} (m_{\lambda 2}-m_{\lambda 3}) = 5 log (cz)+ZP, \end{equation} where $c$ is the speed of light, $z$ the redshift, $m_{\lambda_{1,2,3}}$ the observed magnitudes with different filters, and corrected for AvG and KC, while $\alpha$, $\beta_{\lambda_{1}}$ and $ZP$ are free fitting parameters. The errors on these parameters are derived assuming a reduced chi square equal to one. In order to obtain the errors on the standardised magnitudes, an error propagation is performed in an iterative manner. Note that $\beta_{\lambda_{1}}$ is related to host-galaxy $R_{V}$ if we assume that the colour-magnitude relation is due to extrinsic factors (the intrinsic colour is degenerate with the $ZP$). We obtain : \begin{equation} \beta_{\lambda 1}=\frac{A_{\lambda 1}}{E(m_{\lambda 2}-m_{\lambda 3})} , \end{equation} where $A_{\lambda 1}$ is the host-galaxy extinction in the $\lambda 1$ filter and $E$ the colour excess. Assuming a \citet{car89} law, there is one to one relationship between $R_{V}$ and $\beta_{\lambda_{1}}$. First we obtain the theoretical $\beta$ for different $R_{V}$ values using the \citet{car89} coefficients (a and b): \begin{equation} \beta(R_V)=\frac{a_{\lambda 1}+\frac{b_{\lambda 1}}{R_V}}{(a_{\lambda 2}+\frac{b_{\lambda 2}}{R_V})-(a_{\lambda 3}+\frac{b_{\lambda 3}}{R_V})} . \end{equation} Then we derive $R_{V}$ from the value of $\beta_{\lambda 1}$ determined from the least-squares fit (Eq 1). We will discuss the resulting $R_{V}$ values in section 6.5.\\ \subsection{Hubble flow sample} We select only SNe located in the Hubble flow, i.e., with $cz_{CMB}$ $\geq$ 3000 km s$^{-1}$ in order to minimize the effect of peculiar galaxy motions. Our available sample is composed of the entire sample in the Hubble flow but 3 SNe. We eliminate two SNe due to the fact that the warping function cannot be computed, thus the K-correction (SN 2004ej and SN 2008K). We also take out the outlier SN 2007X and found for this object particular characteristics like clear signs of interaction with the circumstellar medium (flat H alpha P-Cygni profile, see Guti\'errez et al. in prep.).\\ \indent SNe~II are supposedly characterised by similar physical conditions (e.g. temperature) when they arrive towards the end of the plateau \citep{hamuy02} that is why we use the end of the optically thick phase measured in the $V$ band (as defined by \citealt{anderson14a}) as the time origin in order to bring all SNe to the same time scale. When the end of the plateau is not available we choose 80 days post explosion, which is the average for our sample.\\ \indent Given that SNe~II show a significant dispersion in the plateau duration driven by different evolution speeds, we decide to take a fraction of the plateau duration and not an absolute time, to ensure that we compare SNe~II at the same evolutionary phase. Thus, in the following analysis, we adopt OPTd*X\% as the time variable where OPTd is the optically thick phase duration and X is percentage ranging between 1-100\%.\\ \indent In Figure~\ref{RMS_time} we present the variation with evolutionary phase of the dispersion in the Hubble diagram using the filters available and the $(V-i)$ colour. The lowest root mean square (RMS) values in the optical is found for the $r$ band, and at NIR wavelength using the $Y/J$ band. Note that the coverage in the $Y$ band is better than in the $J$ band hence, hereafter we use the $Y$ band. For these two bands we can obtain the median RMS over all the epochs (from 0.2*OPTd to 1.0*OPTd) and the standard deviation. We find for $r$ band 0.47 $\pm$ 0.04 mag and for $Y$ band 0.48 $\pm$ 0.04 mag. In Figure~\ref{RMS_time_couleur} we do as above but this time we change colours. Fixing the $r$ band and using different colours we show the variation of the RMS. This figure shows that the colour that minimises the RMS is $(V-i)$ ($(r-J)$ yields a lower dispersion but the time coverage is significantly less). We find a median RMS over all the epochs of 0.47 $\pm$ 0.05. For this reason we decide to combine the $r$ band and the $(V-i)$ colour for the Hubble diagram. Note also that the best epoch for the $r$ band is close to the middle of the plateau, 55\% of the time from the explosion to the end of the plateau, whereas in the $Y$ band is later in phase post explosion, around 65\%. In general the best epoch to standardise the magnitude is between 60--70\% of the OPTd for NIR filters and for optical filters between 50--60\% of OPTd. Physically these epochs correspond in both cases more or less to the middle of the plateau. Note that we tried other time origin such as the epoch of maximum magnitude instead of the end of the plateau but changing the reference does not lower the RMS.\\ \indent In Figure~\ref{Hubble diagram_hubble_flow} we present a Hubble diagram based entirely on photometric data using $s_{2}$ and colour term for two filters, $r$ band and $Y$ band. In the $r$ band the RMS is 0.44 mag (with 38 SNe) which allows us to measure distances with an accuracy of $\sim$ 20\%. We find the same precision using the $Y'$-band with a RMS of 0.43 mag (30 SNe). Note that the colour term is more important for the optical filter than for the NIR filter. Indeed, for the $r$ band the RMS decreases from 0.50 to 0.44 mag when the colour term is added whereas for the NIR filter the improvement is only of 0.004 mag. Using all available epochs we find a mean improvement of 0.025 $\pm$ 0.011 in $r$ band and 0.014 $\pm$ 0.013 in $Y$ band. This shows that the improvement is significant in optical but less in NIR. The drop using the optical filter is not surprising because this term is probably at least partly related to host-galaxy extinction which is more prevalent in optical wavelengths than in the NIR, so adding a colour term for NIR filters does not significantly influence the dispersion. Note that if we use the weighted root mean square (WRMS) as defined by \citet{blondin11} we find 0.40 mag and 0.36 mag for the $r$ band and $Y$ band, respectively, after $s_{2}$ and colour corrections.\\ \indent In the literature the majority of the studies used SNe~IIP for their sample. To check if we can include all the SNe~II (fast- and slow-decliners) we did some analysis of the SNe and investigate if any of the higher residuals arise from intrinsic SN properties. The overall conclusion is that at least to first order, we did not find any correlation between SNe~II intrinsic differences ($s_{2}$, OPTd,...) and the Hubble residuals. This suggests that SNe within the full range of $s_{2}$ values (i.e., all SNe~II) should be include in Hubble diagram.\\ \indent Following the work of \citet{folatelli10} for SNe~Ia, we investigated the combined Hubble diagram using all the filters available (by averaging the distance moduli derived in each filter) but the dispersion obtained is not much better. We found the same correlation between the distance-modulus residuals in one band versus those in another band as found by \citet{folatelli10}, suggesting that the inclusion of multiple bands does not improve the distance estimate.\\ \indent If we include SNe in the Hubble flow ($cz \geq$~3000 km s$^{-1}$) and very nearby SNe ($cz \leq$~3000 km s$^{-1}$) for the $r$ band the dispersion increases from 0.44 mag to 0.48 mag (46 SNe) whereas in the $Y$ band the RMS increase from 0.43 mag to 0.45 (41 SNe).\\ \indent We also try to use two different epochs, one for the magnitude and the other for the colour but again, this does not improve the RMS. Finally, we try also to use the total decline rate (between maximum to the end of the plateau) instead of the plateau slope. Using the total decline rate does not lower the RMS (dispersion around 0.47 mag for 45 SNe in the $r$ band) but could be useful for high redshift SNe. \begin{figure} \includegraphics[width=9.5cm]{fig_2a.eps} \caption{Variation in phase of the dispersion in the Hubble diagram for different filters and using a colour term $(V-i)$. In the x-axis we present the time as (explosion time+OPTd*X\%). The black squares present the $B$ band, dark blue circle the $g$ band, blue cross the $V$ band, dark green diamonds the $r$ band, green hexagons for the $i$ band, yellow pentagons for the $Y$ band, red plus symbol for the $J$ band. The $H$ band is not presented because the sampling is as good as it is in the other bands.} \label{RMS_time} \end{figure} \begin{figure} \includegraphics[width=9.5cm]{fig_2b.eps} \caption{Variation in phase of the dispersion in the Hubble diagram using the $r$ band and different colours. In the x-axis we present the time as the OPTd*X\%. The black stars present $(r-i)$ colour, dark blue squares are for $(V-r)$, blue circle $(B-V)$, cyan cross $(g-r)$, green diamonds $(V-Y)$, yellow pentagons for $(r-J)$, and red hexagons for $(V-i)$.} \label{RMS_time_couleur} \end{figure} \begin{figure*} \center \includegraphics[width=6.5cm]{r_PCM_a.eps} \includegraphics[width=6.5cm]{r_PCM_b.eps}\\ \includegraphics[width=9.5cm]{r_PCM_c.eps}\\ \includegraphics[width=6.5cm]{Y_PCM_a.eps} \includegraphics[width=6.5cm]{Y_PCM_b.eps}\\ \includegraphics[width=9.5cm]{Y_PCM_c.eps} \caption{In the figures, we present the dispersion (RMS) using the PCM, the number of SNe ($N_{SNe}$) and the epoch chosen with respect to OPTd (OPTd*X\%) for our Hubble flow sample. On the bottom of each plot, the residuals are shown. In all the residual plots, the dashed line correspond to the RMS. \textit{Top Left:} Apparent magnitude corrected for MW extinction and KC in the $r$ band plotted against $cz_{CMB}$; \textit{Top Right:} Apparent magnitude corrected for MW extinction, KC and $s_{2}$ term in the $r$ band plotted against $cz_{CMB}$. \textit{Top Center: } Apparent magnitude corrected for MW extinction, KC, $s_{2}$ term in the $r$ band, and by colour term, $(V-i)$ plotted against $cz_{CMB}$. \textit{Bottom Left:} Apparent magnitude corrected for MW extinction and KC in the $Y$ band plotted against $cz_{CMB}$; \textit{Bottom Right:} Apparent magnitude corrected for MW extinction, KC and $s_{2}$ term in the $Y$ band plotted against $cz_{CMB}$. \textit{Bottom Center:} Apparent magnitude corrected for MW extinction, KC, $s_{2}$ term in the $Y$ band, and by colour term $(V-i)$ plotted against $cz_{CMB}$.} \label{Hubble diagram_hubble_flow} \end{figure*} \section{The standard Candle Method (SCM)} The SCM as employed by various authors gives a Hubble diagram dispersion of 0.25--0.30 mag \citep{hamuy02,nugent06,poznanski09,olivares10,andrea10}. Here we present the Hubble diagram using the SCM for our sample. \subsection{\ion{Fe}{2} velocity measurements} To apply the SCM, we need to measure the velocity of the SN ejecta. One of the best features is \ion{Fe}{2} $\lambda 5018$ because other iron lines such as \ion{Fe}{2} $\lambda 5169$ can be blended by other elements. Expansion velocities are measured through the minimum flux of the absorption component of P-Cygni line profile after correcting the spectra for the heliocentric redshifts of the host-galaxies. Errors were obtained by measuring many times the minimum of the absorption changing the trace of the continuum. The range of velocities is 1800--8000 km s$^{-1}$ for all the SNe. Because we need the velocities for different epochs in order to find the best epoch (as done for the PCM), i.e., with less dispersion, we do an interpolation/extrapolation using a power law \citep{hamuyphd} of the form: \begin{equation} V(t) = A \times t^{\gamma}, \end{equation} where $A$ and $\gamma$ are two free parameters obtained by least-squares minimisation for each individual SN and $t$ the epoch since explosion. In order to obtain the velocity error, we perform a Monte Carlo simulation, varying randomly each velocity measurement according to the observed velocity uncertainties over more than 2000 simulations. From this, for each epoch (from 1 to 120 days after explosion) we choose the velocity as the average value and the incertainty to the standard deviation of the simulations. The median value of $\gamma$ is $-$0.55$\pm$ 0.25. This value is comparable with the value found by other authors ($-$0.5 for \citealt{olivares10} and $-$0.464 by \citealt{nugent06} and $-$0.546 by \citet{takats12}). Note that, as found by \citet{faran14b}, the iron velocity for the fast-decliners (SNe~IIL) also follow a power law but with more scatter. Indeed for the slow-decliners ($s_{2} \leq 1.5$) we find a median value, $\gamma = -0.55 \pm 0.18 $ whereas for the fast-decliners ($s_{2} \geq 1.5$) we obtain $\gamma = -0.56 \pm 0.35 $. More details will be published in an upcoming paper (Guti\'errez et al.). \subsection{Methodology} To standardise the apparent magnitude, we perform a least-squares minimisation on : \small \begin{equation} m_{\lambda 1}+\alpha log(\frac{v_{Fe II}}{5000~km~s^{-1}})-\beta_{\lambda_{1}} (m_{\lambda 2}-m_{\lambda 3} ) = 5 log (cz)+ZP , \end{equation} \normalsize \\ where $c$, $z$, $m_{\lambda 1,2,3}$ are defined in section 4.1 and $\alpha$, $\beta_{\lambda_{1}}$, and $ZP$ are free fitting parameters. The errors on the magnitude are obtained in the same way as for the PCM but the epoch is different. For the SCM, the photospheric expansion velocity is very dependent on the explosion date that is why after trying different epochs and references, we found that the best reference is the explosion time as used in \citet{nugent06}, \citet{poznanski09}, \citet{rodriguez14}. The same epoch for the magnitude, the colour and the iron velocity is employed. Just like for the PCM, we use the same colour, $(V-i)$, and the same filters ($r$, $Y$ band). For some SNe we are not able to measure an iron velocity due to the lack of spectra (only one epoch) and our sample is thus composed of 26 SNe. \subsection{Results} In Figure~\ref{Hubble diagram_SCM} we present the Hubble diagram and the residual for two different filters. The dispersion is 0.29 mag (or 0.30--0.28 mag in WRMS for the $Y$ band and $r$ band respectively) for 24 SNe (some SNe do not have colour at this epoch). These values are some what better than previous studies \citep{hamuy02,nugent06,poznanski09,olivares10,andrea10} where the authors found dispersions around 0.30 mag with 30 SNe (more details in section 6.3). Note the major differences between our study and theirs is that they included very nearby SNe ($cz \leq$~3000 km s$^{-1}$), only slow-declining SNe~II (SNe~II with low $s_{2}$, historically referred to as SNe~IIP), did not calculate a power-law for each SN as we do, and used a different epoch. Note also the work done by \citet{maguire10} where they applyed the SCM to NIR filters ($J$-band and $(V-J)$ colour) using nearby SNe (92\% of their sample with $cz \leq$~3000 km s$^{-1}$), finding a dispersion of 0.39 mag with 12 SNe (see section 6.3). To finish we tried a combination of the PCM and SCM, i.e., adding a $s_{2}$ term to the SCM but this does not improve the dispersion. \begin{figure} \begin{center} \includegraphics[width=9cm]{r_SCM.eps}\\ \includegraphics[width=9cm]{Y_SCM.eps} \caption{In all the figures, we present the dispersion (RMS) using the SCM. The number of SNe ($N_{SNe}$) and the epoch chosen with respect to explosion date in days. Both plots present the Hubble diagram using the SNe in the Hubble flow. On the top we present the Hubble diagram using the $r$ band and the colour $(V-i)$. On the bottom is the same but we use a NIR filter, $Y$ band. On the bottom of each plot we present the residual. In the residuals plot, the dashed line correspond to the RMS.} \label{Hubble diagram_SCM} \end{center} \end{figure} \section{Discussion} Above we demonstrate that using two terms, $s_{2}$ and a colour, we are able to obtain a dispersion of 0.43 mag (optical bands). In this section we try to reduce the RMS by using well-observed SNe and we compare the PCM to the SCM. We also discuss comparisons between the SCM using the CSP sample with other studies. Because the value of the RMS is the crucial parameter to estimate the robustness of the method, we also discuss statistical errors. Finally, we briefly present the values of $R_{V}$ derived from the colour term both from PCM and SCM. \subsection{Golden sample} A significant fraction of values from \citet{anderson14a} do not correspond to the slope of the plateau but sometimes to a combination of $s_{1}$ (initial decline) and $s_{2}$. Indeed, for some SNe, it was impossible to distinguish two slopes and the best fit was only one slope. For this reason we decide to define a new sample composed only by 12 SNe with values of $s_{1}$ and $s_{2}$ and with $cz_{CMB}$ $\geq$ 3000 km s$^{-1}$. From this sample and using the $r$/$(V-i)$ combination we obtain a dispersion of 0.39 mag with 12 SNe, which compares to 0.48 mag from the entire sample. From the $Y$ band the dispersion drops considerably from 0.44 to 0.18 mag with only 8 SNe. However this low value should be taken with caution due to possible statistical effects which are discussed later (see section 6.4). \subsection{Method comparisons} In Figure~\ref{Hubble diagram_compa_r} and in Figure~\ref{Hubble diagram_compa_Y} we compare the Hubble diagram obtained using the SCM and the PCM. For both methods we use the same SNe (Hubble flow sample), and the same set of magnitude-colour. The dispersion using the $r$ band and the $Y$ band is 0.43 mag for the PCM whereas for the SCM is 0.29.\\ \indent In general the SCM is more precise than the PCM but the dispersion found with the PCM is consistent with the results found by the theoretical studies done by \citet{kasen09} (distances accurate to $\sim$ 20\%) but the authors used other photometric correlations (plateau duration). Unfortunately, as suggested by \citet{anderson14a} using this parameter the prediction is not seen in the observations. We tried to use the OPTd values as an input instead of the $s_{2}$ and we did not see any improvement on the dispersion. Note also the recent work of \citet{faran14a}, in which the authors found a correlation between the iron velocity and the $I$-band total decline rate. Although in this paper we do not use the total decline rate but another quantity related to the plateau slope, our work confirms the possibility of using photometric parameters instead of spectroscopic.\\ \begin{figure*} \includegraphics[width=9cm]{r_PCM_SCM_b.eps} \includegraphics[width=9cm]{r_PCM_SCM_a.eps} \caption{In all the figures, we present the dispersion (RMS), the number of SNe ($N_{SNe}$) and the epoch chosen with respect to the end of the plateau (OPTd*X\%) for the SCM and with respect to the explosion date for the SCM. On the bottom of each plot, the residuals are shown. In all the residual plots, the dashed line correspond to the RMS. For both methods we use the Hubble flow sample, $cz_{CMB}$ $\geq$ 3000 km s$^{-1}$, the $r$ band and the colour $(V-i)$. Plotted on the left is the SCM whereas in the right is for the PCM} \label{Hubble diagram_compa_r} \end{figure*} \begin{figure*} \includegraphics[width=9cm]{Y_PCM_SCM_b.eps} \includegraphics[width=9cm]{Y_PCM_SCM_a.eps} \caption{In all the figures, we present the dispersion (RMS), the number of SNe ($N_{SNe}$) and the epoch chosen with respect to the end of the plateau (OPTd*X\%) for the SCM and with respect to the explosion date for the SCM. On the bottom of each plot, the residuals are shown. In all the residuals plot, the dashed line correspond to the RMS. For both methods we use the Hubble flow sample, $cz_{CMB}$ $\geq$ 3000 km s$^{-1}$, the $Y$ band and the colour $(V-i)$. Plotted on the left is the SCM whereas in the right is for the PCM} \label{Hubble diagram_compa_Y} \end{figure*} \subsection{SCM comparisons} In this section we compare our SCM with other studies. First we use only optical filters to compare with \citet{poznanski09} and \citet{olivares10}. Both studies used the $(V-I)$ colour and also the $I$ band. Note that \citet{olivares10} also used the $B$ and $V$ band but here we consider only the $I$ band for consistency. \citet{poznanski09} found a dispersion of 0.38 mag using 40 slow-decliners. In our sample instead of using the $I$ band we used the sloan filter, $i$ band and $(V-i)$ colour. Using our entire sample, i.e., SNe (37 SNe in total for all the redshift range) we derive a dispersion similar to \citet{poznanski09} of 0.32 mag (epoch: 35 days after explosion). We can also compare the parameter $\alpha$ derived from the fit. Again we obtain a consistent value, $\alpha = 4.40 \pm 0.52 $ whereas \citet{poznanski09} found $\alpha = 4.6 \pm 0.70$. The other parameters are not directly comparable due to the fact that the authors assumed an intrinsic colour which is not the case in the current work. Using a Hubble constant ($H_{0}$) equal to 70 km s$^{-1}$ Mpc$^{-1}$ we can translate our ZP to an absolute magnitude ($ZP = M_{corr}-5log(H_{0})+25$) M$_{i}$ = $-$17.12 $\pm$ 0.10 mag that it is lower than the results obtained by \citet{poznanski09} (M$_{I}$ = $-$17.43 $\pm$ 0.10 mag). This difference is probably due to the fact that the corrected magnitude has not been corrected for the intrinsic colour in our work.\\ \indent Using 30 slow-declining SNe in the Hubble flow and very nearby SNe (z between 0.00016 and 0.05140), $(V-I)$ colour and the $I$ band, \citet{olivares10} derived a dispersion of 0.32 mag which is the same that we obtained. However the parameters derived by \citet{olivares10} are different. Indeed using the same equation (5), and the entire sample they obtained $\alpha = 2.62 \pm 0.21 $, $\beta = 0.60 \pm 0.09 $ and $ZP =-2.23 \pm 0.07 $ instead of $\alpha = 4.40 \pm 0.52 $, $\beta = 0.98 \pm 0.31 $ and $ZP =-1.34 \pm 0.10 $ for us. From their ZP ($H_{0}$=70 km s$^{-1}$ Mpc$^{-1}$) we derive M$_{I}$ = -18.00 $\pm$ 0.07 mag (M$_{i}$ = -17.12 $\pm$ 0.15 mag for us). When the authors restrict the sample to objects in the Hubble flow, they end up with 20 SNe and a dispersion of 0.30 mag. If we do the same cut, we find a dispersion of 0.29 for 24 SNe. We obtain consistent dispersion for both samples using similar filters. Note that reducing our sample to slow-decliners alone ($s_{2} \leq 1.5$, the classical SNe~IIP in other studies) in the Hubble flow does not improve the dispersion. As mentioned in section 5.3, the difference in dispersion between \citet{olivares10} and our study can be due, among other things, to the difference in epoch used, or that we calculate a power-law for each SN for the velocity.\\ \indent With respect to the NIR filters \citet{maguire10} suggested that it may be possible to reduce the scatter in the Hubble diagram to 0.1--0.15 mag and this should then be confirmed with a larger sample and more SNe in the Hubble flow. The authors used 12 slow-decliners but only one SN in the Hubble flow. Using the $J$ band and the colour $(V-J)$ they found a dispersion of 0.39 mag against 0.50 mag using the $I$ band. From this drop in the NIR, the authors suggested that using this filter and more SNe in the Hubble flow could reduce the scatter from 0.25-0.3 mag (optical studies) to 0.1--0.15 mag. With the same filters used by \citet{maguire10}, and using the Hubble flow sample, we find a dispersion of 0.28 mag with 24 SNe. This dispersion is 0.1 mag higher than that predicted by \citet{maguire10} (0.1--0.15 mag). To derive the fit parameters, the authors assumed an intrinsic colour $(V-J)_{0}$ $=$ 1 mag. They obtained $\alpha = 6.33 \pm 1.20 $ and an absolute magnitude M$_{J}$=$-$18.06 $\pm$ 0.25 mag ($H_{0}$=70 km s$^{-1}$ Mpc$^{-1}$). If we use only the SNe with $cz_{CMB}$ $\geq$ 3000 km s$^{-1}$ (24 SNe), we find $\alpha = 4.64 \pm 0.64 $ and ZP = $-$2.44 $\pm$ 0.18 which corresponds to M$_{J}$=$-$18.21 $\pm$ 0.18 mag assuming H$_{0}$ = 70 km s$^{-1}$ Mpc$^{-1}$. If we include all SNe at any redshift, the sample goes up to 34 SNe and the dispersion is 0.31 mag. From all SNe we derive $\alpha = 4.87 \pm 0.52 $ and ZP =$-$2.44 $\pm$ 0.20 which corresponds to M$_{J}$=-18.21 $\pm$ 0.20. To conclude, the Hubble diagram derived from the CSP sample using the SCM is consistent and some what better with those found in the literature.\\ \indent More recently, \citet{rodriguez14} proposed another method to derive a Hubble diagram from SNe~II. The PMM corresponds to the generalisation of the SCM, i.e., the distances are obtained using the SCM at different epochs and then averaged. Using the $(V-I)$ colour, and the filter $V$, the authors found an intrinsic scatter of 0.19 mag. Given that the intrinsic dispersion used by \citet{rodriguez14} is a different metric than that used by us (the RMS dispersion) we computed the latter from their data, obtaining 0.24 mag for 24 SNe in the Hubble flow. Using the $V$ band and the $(V-i)$ colour and doing an average over several epochs we found a dispersion of 0.28 mag which is similar to the value found from the SCM and comparable with the value derived by \citet{rodriguez14}. From the $Y$ band and $(V-i)$ colour we find an identical dispersion of 0.29 mag. \subsection{Low number effects} In analysing the Hubble diagram, the figure of merit is the RMS and the holy grail is to obtain very low dispersion in the Hubble diagram (i.e. low distance errors). In our work we show that in the $Y$ band we can achieve a RMS around 0.43--0.48 mag using the Hubble flow sample (30 SNe) and the entire sample (41 SNe), whereas using the golden sample (8 SNe) we obtain a dispersion of 0.18 mag. It is important to know if this decrease in RMS is due to the fact that we used well-studied SNe within the golden sample or if it is due to the low number of SNe. For this purpose we do a test using the Monte Carlo bootstrapping method.\\ \indent From our Hubble flow sample, we remove randomly one SN and compute the dispersion. We do that for 30000 simulations and the final RMS corresponds to the median, and the errors to the standard deviation. Then after removing one SN, we remove randomly two SNe and again estimate the RMS and the dispersion over 30000 simulations. We repeat this process until we have only 4 SNe, i.e., we remove from one SN to (size available sample - 4 SNe). For each simulation we compute a new model, i.e., new fit parameters ($\alpha$, $\beta$, and $ZP$).\\ \indent From this test we conclude that when the number of SNe is lower than 10--12 SNe the RMS is very uncertain because the parameters (i.e., $\alpha$, $\beta$, and $ZP$) start diverging (see Appendix). This implies that the RMS is driven by the reduced number of objects so it is difficult to conclude if the model for the golden sample is better because the RMS is smaller or because it is due to a statistical effect. \subsection{Low $R_{V}$} As stated in section 4.1, the $\beta_{\lambda_{1}}$ colour term is related to the total-to-selective extinction ratio if the colour-magnitude relation is due to extrinsic factors (dust). In the literature, for the MW, $R_{V}$ is known to vary from one line of sight to another, from values as low as 2.1 \citep{welty92} to values as large as 5.6-5.8 \citep{car89,fitzpatrick99,draine03}. In general for the MW, a value of 3.1 is used which corresponds to an average of the Galactic extinction curve for diffuse interstellar medium (ISM). Using the minimisation of the Hubble diagram with a colour term, in the past decade the SNe~Ia community has derived lower $R_{V}$ for host-galaxy dust than for the MW. Indeed they found $R_{V}$ between 1.5--2.5 \citep{krisciunas07,eliasrosa08,goobar08,folatelli10,phillips13,burns14}. This trend was also seen more recently using SNe~II \citep{poznanski09,olivares10,rodriguez14}. This could be due to unmodeled effects such as a dispersion in the intrinsic colours (e.g. \citealt{scolnic14}).\\ \indent We follow previous work in using the minimisation of the Hubble diagram to obtain constraints on $R_{V}$ for host-galaxy dust. Using the PCM, the Hubble flow sample and the $r$ band, we find $\beta_{r}$ close to 0.98. Using a \citet{car89} law we can transform this value in the total-to-selective extinction ratio, and we obtain, $R_{V}=1.01_{-0.41}^{+0.53}$. Following the same procedure but using the SCM, we also derive low $R_{V}$ values, but consistent with those derived using the PCM.\\ \indent At first sight, our analysis would suggest a significantly different nature of dust in our Galaxy and other spiral galaxies, as previously seen in the analysis of SNe~Ia and SNe~II. However, we caution the reader that the low $R_{V}$ values could reflect instead intrinsic magnitude-colour for SNe~II not properly modelled. To derive the $R_{V}$ (or pseudo $R_{V}$) values we assume that all the SNe~II have the same intrinsic colours and same intrinsic colour-luminosity relation, however theoretical models with different masses, metallicity, show different intrinsic colours \citep{dessart13}. Disentangling both effects would require to know the intrinsic colours of our SN sample. Indeed, with intrinsic colour-luminosity corrections the $\beta_{\lambda_{1}}$ colour term could change and thus we will be able to derive an accurate $R_{V}$. In a forthcoming paper we will address this issue through different dereddening techniques (de Jaeger, in prep.) that we are currently investigating. \section{Conclusions} Using 38 SNe~II in the Hubble flow we develop a technique based solely on photometric data (PCM) to build a Hubble diagram based on SNe~II. In summary : \begin{enumerate} \item{Using PCM we find a dispersion of 0.44 mag using the $r$ band and 0.43 mag with the $Y$ band,thus using NIR filters the improvement is not so significant for the PCM.} \item{The $s_{2}$ plays a useful role, allowing us to reduce the dispersion from 0.58 mag to 0.50 mag for $r$ band.} \item{The colour term does not have so much influence on the NIR filters because it is related to the host-galaxy extinction.} \item{We find very low ($\beta$) values (the colour-magnitude coefficient). If $\beta$ is purely extrinsic, it implies very low $R_{V}$ values.} \item{The Hubble diagram derived from the CSP sample using the SCM yields to a dispersion of 0.29 mag, some what better than those found in the literature and emphasising the potential of SCM in cosmology.} \end{enumerate} It is interesting also to obtain more data and SNe for which the initial decline rate and the plateau are clearly visible to try to reduce this dispersion. The PCM is very promising, and more efforts must be done in this direction, i.e., trying to use only photometric parameters. In the coming era of large photometric wide--field surveys like LSST, having spectroscopy for every SNe will be impossible hence the PCM which is the first purely photometric method could be very useful. \acknowledgments The referee is thanked for their through reading of the manuscript, which helped clarify and improve the paper. Support for T. D., S. G., L. G., M. H. , C. G., F. O., H. K., is provided by the Ministry of Economy, Development, and Tourism's Millennium Science Initiative through grant IC120009, awarded to The Millennium Institute of Astrophysics, MAS. S. G., L. G., H. K. and F.O. also acknowledge support by CONICYT through FONDECYT grants 3130680, 3140566, 3140563 and 3140326, respectively. The work of the CSP has been supported by the National Science Foundation under grants AST0306969, AST0607438, and AST1008343. M. D. S., C. C. and E. H. gratefully acknowledge generous support provided by the Danish Agency for Science and Technology and Innovation realized through a Sapere Aude Level 2 grant. The authors thank F. Salgado for his work done with the CSP. This research has made use of the NASA/IPAC Extragalactic Database (NED) which is operated by the Jet Propulsion Laboratory, California Institute of Technology, under contract with the National Aeronautics and Space Administration and of data provided by the Central Bureau for Astronomical Telegrams.
{ "redpajama_set_name": "RedPajamaArXiv" }
6,689
Un radar bistatique est un radar dont l'émetteur et le récepteur sont séparés. La distance entre l'émetteur et le récepteur est de l'ordre de la distance théorique de la cible. Inversement, un radar dont l'émetteur et le récepteur sont au même endroit est appelé « radar monostatique ». Différents types de radars bistatiques Radar pseudo-monostatique Certains systèmes ont bien des émetteurs et récepteurs séparés mais l'angle sous-tendu par l'émetteur, la cible et le récepteur (« angle bistatique ») est voisin de zéro (l'émetteur et le récepteur sont proches l'un de l'autre). Dans ce cas, on est ramené au cas de figure d'un radar monostatique. C'est pourquoi cette configuration est appelée « pseudo–monostatique ». Par exemple, certains radars HF à longue portée ont leur émetteur et leur récepteur séparés de quelques dizaines de kilomètres pour des raisons d'isolation électrique, mais, au regard de leur portée de à , ils ne sont pas considérés comme des bistatiques vrais et sont considérés comme pseudo-monostatiques. Radar à diffraction Dans certaines configurations, le radar bistatique — avec un angle bistatique de — est prévu pour fonctionner comme une barrière et détecter les cibles qui passent entre l'émetteur et le récepteur. Ceci est un cas particulier du radar bistatique que l'on nomme « radar à diffraction » en raison de son principe de fonctionnement qui veut que l'énergie transmise soit diffractée par la cible. La diffraction peut être modélisée en utilisant le principe de Babinet et représente un système potentiel de contre-mesure pour les avions furtifs compte tenu de ce que la surface équivalente radar (SER, ou RCS, Radar Cross Section) n'est sensible qu'à la silhouette de l'avion et n'est pas influencée par les revêtements et les formes furtives. La SER se calcule avec σ = 4πA²/λ², où σ est la surface équivalente radar, A est la surface de la silhouette et λ la longueur d'onde du radar. Cependant, la localisation et la poursuite de cibles furtives restent très difficiles avec les radars à diffraction car les informations déduites des mesures de distance, d'azimut et d'effet Doppler deviennent extrêmement pauvres (tous ces paramètres tendent vers zéro quelle que soit la position de la cible dans la barrière). Radar multistatique Un système radar multistatique comporte au moins trois composants — par exemple, un récepteur et deux émetteurs, ou deux récepteurs et un émetteur, ou encore plusieurs émetteurs et plusieurs récepteurs. C'est, en fait, une généralisation du radar bistatique avec un ou plusieurs récepteurs traitant les informations de un ou plusieurs émetteurs situés sur des positions différentes. Radar passif Un radar bistatique ou multistatique qui utilise les informations d'émetteurs qui ne sont pas des émetteurs radar est appelé radar passif. Par exemple, il peut utiliser les émissions d'une station de radiodiffusion commerciale ou des radiocommunications. C'est un cas particulier du radar bistatique qui peut utiliser des informations provenant d'un émetteur radar ou non. Avantages et inconvénients Avantages principaux Faible coût à l'achat et à l'entretien (si on utilise l'émetteur d'un tiers). Pas d'autorisation d'utilisation d'une fréquence (si on utilise l'émetteur d'un tiers). Mise en œuvre secrète du récepteur. Bonne résistance aux contre-mesures électroniques car le type d'onde, la fréquence utilisée et la position du récepteur sont inconnus. Possibilité d'optimiser la surface équivalente radar (SER) résultante des effets géométriques de la cible. Inconvénients majeurs Système complexe. Frais de communication entre les différents sites. Pas de contrôle de l'émetteur (si on utilise l'émetteur d'un tiers). Plus difficile à mettre en œuvre. Mauvaise couverture à basse altitude car plusieurs sites doivent être à vue. Bibliographie Cherniakov, Bistatic Radar: Principles and Practice., éd. Mikhail, Wiley, 2007. . Willis, Nicholas, Bistatic Radar, SciTech Publishing, éd., 2007. . Voir aussi Type de radars Théorie radar fi:Tutka#Bistaattinen tutka
{ "redpajama_set_name": "RedPajamaWikipedia" }
3,574
{"url":"https:\/\/physweb.bgu.ac.il\/COURSES\/PHYSICS_ExercisesPool\/22_Rigid_body\/e_22_1_030.html","text":"### Rigid Body\n\nFind the moment of inertia for the following bodies:\n1. A cylinder of mass $M$ radius $R$ and height $H$ rotating about its symmetry axis.\n2. A cylinder of mass $M$ radius $R$ and height $H$ rotating about an axis parallel to the symmetry axis and tangent to the surface.\n3. A thin square of side $L$ with its diagonal along\u00a0$x$-axis (mass $M$). Find $I_{xx}$, $I_{yy}$ and $I_{zz}$.","date":"2019-02-23 03:50:16","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 0, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 12, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.9334009289741516, \"perplexity\": 286.63427645537024}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2019-09\/segments\/1550249434065.81\/warc\/CC-MAIN-20190223021219-20190223043219-00388.warc.gz\"}"}
null
null
IND vs ZIM: Win in Melbourne is a must.. or semis will be difficult.. Many changes in Team India's playing 11? November 6, 2022 by Sunil Tiwari India vs Zimbabwe T20 World Cup 2022: India must win the match against Zimbabwe to reach the semi-finals. Otherwise the results will change. The Indian cricket team is coming off with a good performance so far in the ICC T20 World Cup-2022. However, Team India's place in the semi-finals is yet to be confirmed. For this, Rohit Sena must win the match against Zimbabwe on Sunday. If we win this match we are sure to reach the semi finals. But if the Zimbabwean team wins, India will be in trouble. Rain also hampered many matches in this World Cup. Even if the match between India and Zimbabwe is canceled due to rain, India will benefit. Because another point will be added to India's account. With this, Rohit Sena has a chance to play the semi-final. Will there be a huge innings from Rohit? India must win to reach the semi-finals. Captain Rohit Sharma will also try to play a big innings in this match. Despite playing some impressive innings, the Indian captain could not turn them into long innings. Rohit, who has scored only 74 runs in the four matches played so far in the tournament, will now enter the field where he has played some memorable innings. It is difficult to underestimate the Zimbabwean team. The Indian team has to register a victory against Zimbabwe under any circumstances. In the background of the Zimbabwean team led by Regis Chakabwa being a strong competitor.. Rohit Sharma's team must win. Meanwhile, Zimbabwe made a good start in the tournament but could not continue their momentum. Zimbabwean batsmen have not performed well so far and it is not easy to score runs for Bhuvneshwar Kumar, Arshdeep Singh and Mohammed Shami. If you lose, you are out of the tournament. But India will not make the mistake of taking Zimbabwe lightly. Because Zimbabwe has changed the heads of some teams in this World Cup. Defeated a strong team like Pakistan. In such a situation, if Zimbabwe is taken lightly, Team India has a chance to become dangerous. Semi finals equation.. If they win this match, India will reach the top position in Group-2. But if they lose, Pakistan will be shown the way to reach the semi-finals. If Pakistan beat Bangladesh in their last match, they will advance on the basis of better run rate. The other team in the group, South Africa, is currently second with five points. A win against the Netherlands will also advance it. But if South Africa loses and Pakistan wins, then Pakistan and India will be in the top 2. Team India continues to top Group 2. Then Team India could face either England or Australia in the semi-finals. Will Huda get a chance? The Indian team has not changed the batting order at present. Akshar Patel was left out against South Africa and Deepak Hooda was introduced. The Indian team management is likely to give Deepak Hooda another chance as the Zimbabwean batting order has stalwarts like Craig Erwin, Sean Erwin, Ryan Burley and Sean Williams. However, India's biggest challenge will come from Pakistan-born Sikandar Raza, who is in excellent form at the moment. Another option would be to try Harshal Patel. Yuzvendra Chahal is yet to be tried. Because the team management did not want a long line of batsmen at the end. But if India face England in the semi-finals, Chahal may get a place because of his good record against English batsmen. For the first time.. India vs Zimbabwe has never met before in T20 World Cup. Both teams: India: Rohit Sharma (captain), KL Rahul (vice-captain), Virat Kohli, Suryakumar Yadav, Hardik Pandya, Dinesh Karthik (wicket), Akshar Patel, R Ashwin, Mohammed Shami, Arshdeep Singh, Bhuvneshwar Kumar, Rishabh Pant, Deepak Hooda , Harshal Patel, Yuzvendra Chahal. Zimbabwe: Regis Chakabwa (capt), Sean Williams, Sean Erwin, Craig Erwin, Sikandar Raza, Tendai Chhatra, Luke Jongwe, Brad Evans, Wesley Madhewere, Wellington Masakadajka, Tony Munyonga, Richard Ngarwa, Ryan Smrambarwa, Ryan Mranjarwa, Blessing Burr. KL Rahul: Happy birthday to my joker.. Team India cricketer wishes birthday to his girlfriend T-20 World Cup: India reached the semis.. A big shock for South Africa..
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
7,148
Венявский () — польская фамилия. Известные носители Венявский, Адам Тадеуш (1876—1950) — польский композитор. Венявский, Генрик (1835—1880) — польский скрипач. Венявский, Юзеф (1837—1912) — польский пианист и музыкальный педагог. Венявский, Юлиан (1834—1912) — польский писатель, драматург, участник январского восстания 1863 года. См. также Венявская, Ирена Регина (1880—1932) — композитор, дочь Г. Венявского.
{ "redpajama_set_name": "RedPajamaWikipedia" }
4,048
Q: windows wakeup, run script and go back to sleep MacOS has a program called pmset which can start from hibernation and power off again. # pmset repeat wakeorpoweron MTWRFSU 20:19:00 shutdown MTWRFSU 20:25:00 # pmset -g sched Repeating power events: wakepoweron at 8:19PM every day shutdown at 8:25PM every day 8.20PM I run a test that takes 3-4minutes and send a report to our CI system. Is there any equivalent on windows? On windows I've gone the other way keeping it always on, but it wastes power when there is an old laptop just doing a few tests once a day. I've not managed to do this with older(2013-2015) HP Zbooks/Elitebooks. Are there any windows laptops that can do this? Since Apple control both hardware and software they may do this.
{ "redpajama_set_name": "RedPajamaStackExchange" }
9,332
<?php namespace nglasl\extensible; use SilverStripe\CMS\Search\SearchForm; use SilverStripe\Core\ClassInfo; use SilverStripe\Core\Config\Config; use SilverStripe\Forms\DropdownField; use SilverStripe\Forms\FieldList; use SilverStripe\Forms\FormAction; use SilverStripe\Forms\TextField; use SilverStripe\ORM\PaginatedList; use SilverStripe\ORM\Search\FulltextSearchable; use Symbiote\Multisites\Multisites; /** * @author Nathan Glasl <nathan@symbiote.com.au> */ class ExtensibleSearchPageController extends \PageController { public $service; private static $dependencies = array( 'service' => '%$' . ExtensibleSearchService::class ); private static $allowed_actions = array( 'getForm', 'getSearchForm', 'getSearchResults' ); /** * Determine whether the search page should start with a listing. */ public function index() { // Determine whether a search engine has been selected. $engine = $this->data()->SearchEngine; $classes = Config::inst()->get(FulltextSearchable::class, 'searchable_classes'); if(!$engine || (($engine !== 'Full-Text') && !ClassInfo::exists($engine)) || (($engine === 'Full-Text') && (!is_array($classes) || (count($classes) === 0)))) { // The search engine has not been selected. return $this->httpError(404); } // Determine whether the search page should start with a listing. if($this->data()->StartWithListing) { // Display some search results. $request = $this->getRequest(); return $this->getSearchResults(array( 'Search' => $request->getVar('Search'), 'SortBy' => $request->getVar('SortBy'), 'SortDirection' => $request->getVar('SortDirection') ), $this->getForm($request)); } else { // Instantiate some default templates. $templates = array( 'ExtensibleSearch', 'ExtensibleSearchPage', 'Page' ); // Instantiate the search engine specific templates. if($engine !== 'Full-Text') { $explode = explode('\\', $engine); $explode = end($explode); $templates = array_merge(array( $explode, "{$explode}Page" ), $templates); } // Determine the template to use. $this->extend('updateTemplates', $templates); return $this->renderWith($templates); } } /** * Instantiate the search form. * * @parameter <{REQUEST}> http request * @parameter <{DISPLAY_SORTING}> boolean * @return search form */ public function getForm($request = null, $sorting = true) { // Determine whether a search engine has been selected. $engine = $this->data()->SearchEngine; $configuration = Config::inst(); $classes = $configuration->get(FulltextSearchable::class, 'searchable_classes'); if(!$engine || (($engine !== 'Full-Text') && !ClassInfo::exists($engine)) || (($engine === 'Full-Text') && (!is_array($classes) || (count($classes) === 0)))) { // The search engine has not been selected. return null; } // Determine whether the request has been passed through. if(is_null($request)) { $request = $this->getRequest(); } // Display the search. $fields = FieldList::create( TextField::create( 'Search', _t('EXTENSIBLE_SEARCH.SEARCH', 'Search'), $request->getVar('Search') )->addExtraClass('extensible-search')->setAttribute('data-suggestions-enabled', $configuration->get(ExtensibleSearchSuggestion::class, 'enable_suggestions') ? 'true' : 'false')->setAttribute('data-extensible-search-page', $this->data()->ID) ); // Determine whether sorting has been passed through from the template. if(is_string($sorting)) { $sorting = ($sorting === 'true'); } // Determine whether to display the sorting selection. if($sorting) { // Display the sorting selection. $fields->push(DropdownField::create( 'SortBy', _t('EXTENSIBLE_SEARCH.SORT_BY', 'Sort By'), $this->data()->getSelectableFields(), $request->getVar('SortBy') ? $request->getVar('SortBy') : $this->data()->SortBy )->setHasEmptyDefault(true)); $fields->push(DropdownField::create( 'SortDirection', _t('EXTENSIBLE_SEARCH.SORT_DIRECTION', 'Sort Direction'), array( 'DESC' => _t('EXTENSIBLE_SEARCH.DESCENDING', 'Descending'), 'ASC' => _t('EXTENSIBLE_SEARCH.ASCENDING', 'Ascending') ), $request->getVar('SortDirection') ? $request->getVar('SortDirection') : $this->data()->SortDirection )->setHasEmptyDefault(true)); } // Instantiate the search form. $form = SearchForm::create( $this, 'getForm', $fields, FieldList::create( FormAction::create( 'getSearchResults', _t('EXTENSIBLE_SEARCH.GO', 'Go') ) ) ); // When using the full-text search engine, the classes to search needs to be initialised. if($engine === 'Full-Text') { $form->classesToSearch($classes); } // Allow extension customisation. $this->extend('updateExtensibleSearchForm', $form); return $form; } /** * Instantiate the search form. * * @parameter <{REQUEST}> http request * @parameter <{DISPLAY_SORTING}> boolean * @return search form */ public function Form($request = null, $sorting = true) { // This provides consistency when it comes to defining parameters from the template. return $this->getForm($request, $sorting); } /** * Instantiate the search form, primarily outside the search page. * * @parameter <{REQUEST}> http request * @parameter <{DISPLAY_SORTING}> boolean * @return search form */ public function getSearchForm($request = null, $sorting = false) { // Instantiate the search form, primarily excluding the sorting selection. $form = $this->getForm($request, $sorting); if($form) { // When the search form is displayed twice, this prevents a duplicate element ID. $form->setName('getSearchForm'); // Replace the search title with a placeholder. $search = $form->Fields()->dataFieldByName('Search'); $search->setAttribute('placeholder', $search->Title()); $search->setTitle(null); } // Allow extension customisation. $this->extend('updateExtensibleSearchSearchForm', $form); return $form; } /** * Display the search form results. * * @parameter <{SEARCH_PARAMETERS}> array * @parameter <{SEARCH_FORM}> search form * @return html text */ public function getSearchResults($data = null, $form = null) { // Determine whether a search engine has been selected. $page = $this->data(); $engine = $page->SearchEngine; $classes = Config::inst()->get(FulltextSearchable::class, 'searchable_classes'); if(!$engine || (($engine !== 'Full-Text') && !ClassInfo::exists($engine)) || (($engine === 'Full-Text') && (!is_array($classes) || (count($classes) === 0)))) { // The search engine has not been selected. return $this->httpError(404); } // The analytics require the time taken. $time = microtime(true); // This is because the search form pulls from the request directly. if(!isset($data['Search'])) { $data['Search'] = ''; } $search = $data['Search']; $request = $this->getRequest(); $request->offsetSet('Search', $search); // Determine whether the remaining search parameters have been passed through. if(!isset($data['SortBy']) || !$data['SortBy']) { $data['SortBy'] = $page->SortBy; } if(!isset($data['SortDirection']) || !$data['SortDirection']) { $data['SortDirection'] = $page->SortDirection; } if(!isset($form)) { $form = $this->getForm($request); } // Instantiate some default templates. $templates = array( 'ExtensibleSearch', 'ExtensibleSearchPage', 'Page' ); // Determine the search engine that has been selected. if($engine !== 'Full-Text') { // The analytics require the time taken. $time = microtime(true); // Determine the search engine specific search results. $results = singleton($engine)->getSearchResults($data, $form, $page); // The search results format needs to be correct. if(!isset($results['Results'])) { $results = array( 'Results' => $results ); } // Determine the number of search results. $count = isset($results['Count']) ? (int)$results['Count'] : count($results['Results']); // Instantiate the search engine specific templates. $explode = explode('\\', $engine); $explode = end($explode); $templates = array_merge(array( "{$explode}_results", "{$explode}Page_results", 'ExtensibleSearch_results', 'ExtensibleSearchPage_results', 'Page_results', $explode, "{$explode}Page" ), $templates); } // Determine the full-text specific search results. else { // The paginated list needs to be manipulated, as filtering and sorting is not possible otherwise. $start = $request->getVar('start') ? (int)$request->getVar('start') : 0; $form->setPageLength(PHP_INT_MAX); // This is because the search form pulls from the request directly. $request->offsetSet('start', 0); $list = $form->getResults()->getList(); // The search engine may only support limited hierarchy filtering for multiple sites. $filter = $page->SearchTrees()->column(); if(count($filter) && (($hierarchy = $page->supports_hierarchy) || ClassInfo::exists(Multisites::class))) { // Apply the search trees filtering. $list = $list->filter($hierarchy ? 'ParentID' : 'SiteID', $filter); } // Apply custom filtering. $this->extend('updateFiltering', $list); // Apply the sorting. $list = $list->sort("{$data['SortBy']} {$data['SortDirection']}"); // The paginated list needs to be instantiated again. $results = array( 'Title' => _t('EXTENSIBLE_SEARCH.SEARCH_RESULTS', 'Search Results'), 'Query' => $form->getSearchQuery(), 'Results' => PaginatedList::create( $list )->setPageLength($page->ResultsPerPage)->setPageStart($start)->setTotalItems($count = $list->count()) ); // Instantiate the full-text specific templates. $templates = array_merge(array( 'ExtensibleSearch_results', 'ExtensibleSearchPage_results', 'Page_results' ), $templates); } // Determine the template to use. $this->extend('updateTemplates', $templates); $output = $this->customise($results)->renderWith($templates); $output->Count = $count; // Determine whether analytics are to be suppressed. if($search && ($request->getVar('analytics') !== 'false')) { // Update the search page specific analytics. $this->service->logSearch($search, $count, microtime(true) - $time, $engine, $page->ID); } // Display the search form results. return $output; } }
{ "redpajama_set_name": "RedPajamaGithub" }
6,436
Vrci su naseljeno mjesto u općini Konjic, Federacija Bosne i Hercegovine, BiH. Zemljopis Nalaze se na području istočnog Klisa na desnoj obali Neretve, od 1954. Jablaničkog jezera. Kroz selo teče Vrčanski potok koji ljeti presuši. Vrci su siromašni izvorima vode. Malo je šume, a zemljišta pogodnog za strojnom obradom nema pa se za obradu koristilo volove i konji te pred Domovinskim rat freze. Do Vrca se dolazi od Konjica asfaltnom cestom preko Pokojišta. Put je 15 km. Nakon što u promet bude pušten most Ante Dragića koji se gradi preko Jablaničkog jezera na potezu Čelebići-Zavratnice, put će biti kraći za 5 km. Naselje pripada župi Obri. Nalazi se na području istočnog Klisa na desnoj obali Jablaničkog jezera omeđeno selima: Lisičići, Donji i Gornji Nevizdraci, Treboje, Strgonice, Grabovci i Hondići, uglavnom muslimanska. Tu je i selo Rajiči. Vrce čine zaseoci: Antin Dolac, Barakovići, Čolopeci, Dol, Grebac, Jezero, Kale, Požanj, Skukrica i Zagaje, koji su naseljeni 100% Hrvatima te Memidžani naseljeni 100% Muslimanima. Stanovništvo 1991. Nacionalni sastav stanovništva 1991. godine, bio je sljedeći: ukupno: 237 Hrvati - 134 Muslimani - 103 2013. Nacionalni sastav stanovništva 2013. godine, bio je sljedeći: ukupno: 109 Bošnjaci - 105 Hrvati - 3 ostali, neopredijeljeni i nepoznato - 1 Povijest Od 1244. do 1820. godine pripadali su župi Neretvi. Župa Neretva se prvo prostirala područjem Zahumlja, kasnije Podgorja. Vrci su od 1820. do 1919. pripadali župi Podhumu i do 1954. župi Ostrošcu, a nakon toga župi Obrima. U Vrcima je bio franjevački samostan i crkva sv. Mihovila. Zapise o njemu ostavio je fra Marijan Bogdanović u Ljetopisu Kreševskog samostana. Izvorni Vrci bili su u zaselku Jezeru. Izvori Vanjske poveznice Satelitska snimka Naselja u Hercegovačko-neretvanskoj županiji Konjic
{ "redpajama_set_name": "RedPajamaWikipedia" }
3,647
\section{Introduction} Let $R$ be an $\mathbb{E}_1$-ring spectrum. The \emph{topological Hochschild homology} $THH(R)$ of $R$ is a spectrum constructed as the geometric realization of a certain cyclic object built from $R$, a homotopy-theoretic version of the Hochschild complex of an associative ring. Topological Hochschild homology has been studied in particular because of its connections with algebraic $K$-theory via the theory of trace maps. More generally, if $R$ is an $\mathbb{E}_1$-algebra in $A$-modules for an $\mathbb{E}_\infty$-ring $A$, then one can define a relative version $THH^A(R)$. In \cite{WG}, it is shown that Hochschild homology for commutative rings satisfies an \'etale base-change result. Equivalently, if $k$ is a commutative ring and if $A \to B$ is an \'etale morphism of commutative $k$-algebras with $A$ flat over $k$, then there is a natural equivalence $$B \otimes_A THH^{k}(A) \simeq THH^{k}(B).$$ Weibel-Geller's result also applies in the non-flat case, although it cannot be stated in this manner. One can hope to generalize the Weibel-Geller result to the setting of ring spectra. This leads to the following general question. \begin{question} Let $A \to B$ be a morphism of $\mathbb{E}_\infty$-ring spectra. When is the map \begin{equation} THH(A) \otimes_A B \to THH(B) \label{THHcomparemap}\end{equation} an equivalence? \end{question} Following Lurie, we will use the following definition of \'etaleness: \begin{definition} \label{lurieetale} A morphism $ A\to B$ of $\mathbb{E}_\infty$-ring spectra is \emph{\'etale} if $\pi_0(A) \to \pi_0(B)$ is \'etale and the natural map $\pi_*(A) \otimes_{\pi_0(A)} \pi_0(B) \to \pi_*(B)$ is an isomorphism. \end{definition} In \cite{McM}, McCarthy-Minasian consider this question for an \'etale morphism\footnote{We note that \cite{McM} use the word``\'etale'' differently in their paper.} of connective $\mathbb{E}_\infty$-rings and prove the analog of the Weibel-Geller theorem, i.e., that \eqref{THHcomparemap} is an equivalence (cf. \cite[Lem. 5.7]{McM}). In fact, they prove the result more generally for any \emph{$THH$-\'etale morphism} of connective $\mathbb{E}_\infty$-rings. In the setting of structured ring spectra, however, there are additional morphisms of nonconnective ring spectra that have formal properties similar to those of \'etale morphisms, though they are not \'etale on homotopy groups. The \emph{faithful Galois extensions} of Rognes \cite{rognes} are key examples here. This note is primarily concerned with the following analog of the Weibel-Geller and McCarthy-Minasian question. \begin{question} Let $A \to B$ be a $G$-Galois extension of $\mathbb{E}_\infty$-ring spectra, with $G$ finite. When is the comparison map \eqref{THHcomparemap} an equivalence? \end{question} We make two main observations here. Our first observation uses the fact that $THH$, like algebraic $K$-theory, is an invariant not only of ring spectra but of stable $\infty$-categories. We refer, for example, to \cite{BM1, BGT} for a treatment of $THH$ in this context. Using Galois descent, we observe that the map \eqref{THHcomparemap} is an equivalence if and only if the map \( THH(A) \to THH(B)^{hG} \) is an equivalence. These maps are the comparison maps for the \emph{Galois descent} problem in $THH$. Consequently, the results of \cite{CMNN} provide numerous examples in chromatic homotopy theory where \eqref{THHcomparemap} is an equivalence. Our second observation is to reinterpret the base-change question for $THH$ in terms of the formulation $THH(R) \simeq S^1 \otimes R$ for $\mathbb{E}_\infty$-rings, due to McClure-Schw{\"a}nzl-Vogt \cite{MSV}. As a result, we obtain an example where \eqref{THHcomparemap} is not an equivalence. \begin{theorem} \label{mainexample} There is a faithful $G$-Galois extension $A \to B$ of $\mathbb{E}_\infty$-ring spectra which is a faithful $G$-Galois extension such that \eqref{THHcomparemap} is not an equivalence. \end{theorem} Our counterexample Galois extension is very simple; it is the map $C^*(S^1; \mathbb{F}_p) \to C^*(S^1; \mathbb{F}_p)$ induced by the degree $p$ cover $S^1 \to S^1$. We in fact pinpoint exactly what goes wrong from a categorical perspective, and why this phenomenon cannot happen in the \'etale setting, thus proving a variant of the Weibel-Geller-McCarthy-Minasian theorem in the non-connective setting: \begin{theorem} \label{ourversionWG} Let $R$ be an $\mathbb{E}_\infty$-ring, and let $A \to B$ be an \'etale morphism of $\mathbb{E}_\infty$-$R$-algebras (possibly nonconnective). Then the natural map $THH^R(A) \otimes_A B \to THH^R(B)$ is an equivalence. \end{theorem} The use of categorical interpretation of $THH$ in proving such base-change theorems is not new; McCarthy-Minasian use this interpretation in \cite{McM} in a different manner. \subsection*{Acknowledgments} I would like to thank John Rognes and the referee for several helpful comments. The author is supported by the NSF Graduate Research Fellowship under grant DGE-110640. \section{Categorical generalities} Let $\mathcal{C}$ be a cocomplete $\infty$-category, and let $x \in \mathcal{C}$. Given $x \in \mathcal{C}$, we can \cite[\S 4.4.4]{HTT} construct an object $S^1 \otimes x$. Choose a basepoint $\ast \in S^1$. Then we have a diagram \begin{equation} \label{s1square} \xymatrix{ x \ar[d] \ar[r] & y \ar[d] \\ S^1 \otimes x \ar[r] & S^1 \otimes y }.\end{equation} As a result of this diagram, we have a natural map in $\mathcal{C}$, \begin{equation} \label{naturalpushout} (S^1 \otimes x ) \sqcup_x y \to S^1 \otimes y. \end{equation} In order for \eqref{naturalpushout} to be an equivalence, for any object $z \in \mathcal{C}$, the square of spaces \begin{equation} \label{freeloopsquarehom} \xymatrix{ \hom(S^1, \hom_{\mathcal{C}}(y, z)) \ar[d] \ar[r] & \hom_{\mathcal{C}}(y, z) \ar[d] \\ \hom(S^1, \hom_{\mathcal{C}}(x, z)) \ar[r] & \hom_{\mathcal{C}}(x,z) }\end{equation} must be homotopy cartesian. This happens only in very special situations. \begin{proposition} \label{easycartlemma} Let $f\colon X \to Y$ be a map of spaces. Then the diagram \begin{equation} \label{generalcart} \xymatrix{ \hom(S^1, X) \ar[d] \ar[r] & X \ar[d] \\ \hom(S^1, Y) \ar[r] & Y }\end{equation} is homotopy cartesian if and only if for every point $p \in X$, the map from the connected component of $X$ containing $p$ to that of $Y$ containing $f(p)$ is a homotopy equivalence. \end{proposition} \begin{proof} Without loss of generality, we may assume that $X, Y$ are connected spaces, In this case, choosing compatible basepoints in $X, Y$, we get equivalences \[ \Omega X \simeq \mathrm{fib}\left( \hom(S^1, X) \to X\right), \quad \Omega Y \simeq \mathrm{fib} \left( \hom(S^1, Y) \to Y \right), \] and the fact that \eqref{generalcart} is homotopy cartesian now implies that $\Omega X \to \Omega Y$ is a homotopy equivalence. Since $X$ and $Y$ are connected, this implies that $X \to Y$ is a homotopy equivalence. \end{proof} \begin{definition} We will say that a map of spaces $X \to Y$ is a \emph{split covering space} if the equivalent conditions of \Cref{easycartlemma} are met. In particular, $X \to Y$ is a covering space, which is trivial on each connected component of $Y$. \end{definition} Observe that the base-change of a split covering space is still a split covering space. \begin{corollary} \label{whenbasechangeholds} Suppose $x \to y$ is a morphism in $\mathcal{C}$ as above. Then the natural map $(S^1 \otimes x) \sqcup_x y \to S^1 \otimes y$ is an equivalence if and only if, for every object $z \in \mathcal{C}$, the induced map of spaces \( \hom_{\mathcal{C}}(y, z) \to \hom_{\mathcal{C}}(x, z) \) is a split cover. \end{corollary} \begin{proof} Our map is an equivalence if and only if \eqref{freeloopsquarehom} is homotopy cartesian for each $z \in \mathcal{C}$. By \Cref{easycartlemma}, we get the desired claim. \end{proof} We now give this class of morphisms a name. \begin{definition} \label{strongly} A morphism $x \to y$ in an $\infty$-category $\mathcal{C}$ is said to be \emph{strongly 0-cotruncated} if, for every $z \in \mathcal{C}$, the map $\hom_{\mathcal{C}}(y, z) \to \hom_{\mathcal{C}}(x, z)$ is a split covering space. \end{definition} \Cref{whenbasechangeholds} states that $x \to y$ has the property that $(S^1 \otimes x) \sqcup_x y \to S^1 \otimes y$ is an equivalence if and only if the map is strongly 0-cotruncated. For passage to a relative setting, we will find the following useful. \begin{proposition} \label{relativecotrunc} Let $\mathcal{C}$ be a cocomplete $\infty$-category, let $a \in \mathcal{C}$, and let $x \to y$ be a morphism in $\mathcal{C}_{a/}$. If $x \to y$ is strongly 0-cotruncated when regarded as a morphism in $\mathcal{C}$, then it is strongly 0-cotruncated when regarded as a morphism in $\mathcal{C}_{a/}$. \end{proposition} \begin{proof} Suppose $a \to z$ is an object of $\mathcal{C}_{a/}$. Then we have \begin{gather*} \hom_{\mathcal{C}_{a/}}(y, z) = \mathrm{fib} \left( \hom_{\mathcal{C}}(y, z) \to \hom_{\mathcal{C}}(a, z)\right) , \\ \hom_{\mathcal{C}_{a/}}(x, z) = \mathrm{fib} \left( \hom_{\mathcal{C}}(x, z) \to \hom_{\mathcal{C}}(a, z)\right) . \end{gather*} Since $\hom_{\mathcal{C}}(y, z) \to \hom_{\mathcal{C}}(x,z)$ is a split cover, it follows easily that the same holds after taking homotopy fibers over the basepoint in $\hom_{\mathcal{C}}(a, z)$. In fact, we can assume without loss of generality that $\hom_{\mathcal{C}}(x,z)$ is connected, in which case $\hom_{\mathcal{C}}(y, z)$ is a disjoint union $\bigsqcup_S \hom_{\mathcal{C}}(x,y)$. Taking fibers over the map to $\hom_{\mathcal{C}}(a, z)$ preserves the disjoint union as desired, so the map on fibers is a split cover. \end{proof} \section{$\mathbb{E}_\infty$-ring spectra} We let $\mathrm{CAlg}$ denote the $\infty$-category of $\mathbb{E}_\infty$-ring spectra. The construction $THH$ in this case can be interpreted (by \cite{MSV}) as tensoring with $S^1$: that is, we have \[ THH(A) \simeq S^1 \otimes A, \quad A \in \mathrm{CAlg}. \] If one works in a relative setting, under an $\mathbb{E}_\infty$-ring $R$, then one has $THH^{R}(A) \simeq S^1 \otimes A$, where the tensor product is computed in $\mathrm{CAlg}_{R/}$. Given a morphism in $\mathrm{CAlg}_{R/}$, $A \to B$, we can use the setup of the previous section and obtain a morphism \[ THH^R(A) \otimes_A B \to THH^R(B) \] which is a special case of \eqref{naturalpushout}. The base-change problem for $THH$ asks when this is an equivalence. By \Cref{whenbasechangeholds}, this is equivalent to the condition that the morphism $A \to B$ in $\mathrm{CAlg}_{R/}$ should be strongly 0-cotruncated. We can now prove \Cref{ourversionWG} from the introduction, which we restate for convenience. \begin{thm}[] Let $R$ be an $\mathbb{E}_\infty$-ring and let $A \to B$ be an \'etale morphism (as in \Cref{lurieetale}) in $\mathrm{CAlg}_{R/}$. Then the natural morphism \( THH^R(A) \otimes_A B \to THH^R(B) \) is an equivalence. \end{thm} This is closely related to \cite[Theorem 0.1]{WG} and includes it in the case of a flat extension $R \to A$ of discrete $\e{\infty}$-rings . For connective $\mathbb{E}_\infty$-rings, this result is \cite[Lem. 5.7]{McM} (who treat more generally the case of a $THH$-\'etale morphism). \begin{proof} Given an \'etale morphism $A \to B$ in $\mathrm{CAlg}_{R/}$, we need to argue that it is strongly 0-cotruncated. By \Cref{relativecotrunc}, we may reduce to the case where $R = S^0$. Given $C \in \mathrm{CAlg}$, we have a homotopy cartesian square \[ \xymatrix{ \hom_{\mathrm{CAlg}}(B, C) \ar[d] \ar[r] & \hom_{\mathrm{Ring}} (\pi_0 B, \pi_0 C) \ar[d] \\ \hom_{\mathrm{CAlg}}(A, C) \ar[r] & \hom_{\mathrm{Ring}} (\pi_0 A, \pi_0 C) },\] by, e.g., \cite[\S 7.5]{higheralg}. Here $\mathrm{Ring}$ is the category of rings. Since the right vertical map is a map of discrete spaces and therefore a split covering, it follows that $\hom_{\mathrm{CAlg}}(B, C) \to \hom_{\mathrm{CAlg}}(A, C)$ is a split covering as desired. \end{proof} We also note in passing that the \'etale descent theorem has a partial converse in the setting of \emph{connective} $\mathbb{E}_\infty$-rings. We note that this rules out non-algebraic Galois extensions. \begin{corollary} Let $A \to B$ be a morphism of connective $\mathbb{E}_\infty$-rings which is almost of finite presentation \cite[\S 7.2.4]{higheralg}. Suppose the map $THH(A) \otimes_A B \to THH(B)$ is an equivalence. Then $A \to B$ is \'etale. \end{corollary} \begin{proof} Indeed, $B$ defines a 0-cotruncated object (\Cref{0cotrunc}) of $\mathrm{CAlg}_{A/}$ and it is well-known that this, combined with the fact that $B$ is almost of finite presentation, implies that $B$ is \'etale. We reproduce the argument for the convenience of the reader. In fact, since $B$ is 0-cotruncated, one finds that for any $B$-module $M$, the space of maps\footnote{For an $\infty$-category $\mathcal{C}$ and a morphism $x \to y$, we let $\mathcal{C}_{x//y}$ denote $(\mathcal{C}_{x/})_{/y}$ where $y \in \mathcal{C}_{x/}$ via the given morphism.} $\hom_{\mathrm{CAlg}_{A// B}}(B, B \oplus M)$ is homotopy discrete, where the $\mathbb{E}_\infty$-ring $B \oplus M$ is given the square-zero multiplication. Replacing $M$ by $\Sigma M$, it follows that \[ \hom_{\mathrm{CAlg}_{A// B}}(B, B \oplus M) \simeq \Omega \hom_{\mathrm{CAlg}_{A// B}}(B, B \oplus \Sigma M) \] is actually contractible. Thus the cotangent complex $L_{B/A}$ vanishes, which implies that $B$ is \'etale over $A$ by \cite[Lem. 8.9]{DAGVII}. The connectivity is used in this last step. \end{proof} The above argument also appears in \cite[\S 9.4]{rognes}, where it is shown that a map $A \to B$ which is 0-cotruncated as in \Cref{0cotrunc} below (which Rognes calls \emph{formally symmetrically \'etale}, and which has been called \emph{$THH$-\'etale} in \cite{McM}) has to have vanishing cotangent complex (which is called \emph{$TAQ$-\'etale)}; see \cite[Lem. 9.4.4]{rognes}. The key point is that in the connective setting, $TAQ$-\'etaleness plus a weak finiteness condition is enough to imply \'etaleness. This entirely breaks down when one works with nonconnective $\e{\infty}$-ring spectra. \section{Connection with descent} In this section, we will show that the question of base-change in $THH$ is equivalent to a descent-theoretic question. We will then use some of the descent results of \cite{CMNN} to obtain examples where base-change for $THH$ holds. Let $A \to B$ be a faithful $G$-Galois extension of $\mathbb{E}_\infty$-rings for $G$ a finite group. To begin with, we will need to recall a fact about Galois descent. \begin{proposition}[{Cf. for example \cite[Ch.~6]{meier} or \cite[Th.~2.8]{Bannerjee} or \cite[Th.~9.4]{galoischromatic}}] If $A \to B$ is a faithful $G$-Galois extension, then we have an equivalence of symmetric monoidal $\infty$-categories \[ \mathrm{Mod} (A) \simeq \mathrm{Mod}(B)^{hG}, \] where the left adjoint is extension of scalars along $A \to B$ and the right adjoint is given by taking homotopy fixed points. \label{galdesc} \end{proposition} We can restate the above equivalence in the following manner. \begin{corollary} Let $\mathrm{Fun}(BG, \sp)$ be the symmetric monoidal $\infty$-category of $G$-spectra equipped with a $G$-action. Then we have a natural equivalence \[ \mathrm{Mod}_{\mathrm{Fun}(BG, \sp)}(B) \simeq \mathrm{Mod}_{\sp}(A) \] given by taking homotopy fixed points. \end{corollary} \begin{proof} This follows from \Cref{galdesc} using the fact that the construction of forming modules in a symmetric monoidal $\infty$-category is compatible with homotopy limits of symmetric monoidal $\infty$-categories. \end{proof} Let $\mathcal{C} = \mathrm{Fun}(BG, \mathrm{CAlg})$ be the $\infty$-category of $\mathbb{E}_\infty$-algebras equipped with a $G$-action, so that $B$ defines an object of $\mathcal{C}$. We have therefore have natural equivalences of $\infty$-categories \begin{equation} \label{htpyfixedpoints} \mathcal{C}_{B/} \simeq \mathrm{CAlg}( \mathrm{Fun}(BG, \sp))_{B/} \simeq \mathrm{CAlg} ( \mathrm{Mod}_{\mathrm{Fun}(BG, \sp)}(B) ) \simeq \mathrm{CAlg}( \mathrm{Mod}(A)). \end{equation} where the last equivalence is given by taking homotopy fixed points. We now obtain: \begin{proposition} For a faithful $G$-Galois extension $A \to B$, the following two statements are equivalent: \begin{itemize} \item $THH(A) \otimes_A B \to THH(B)$ is an equivalence. \item $THH(A) \to THH(B)$ is a faithful $G$-Galois extension. \item The map $THH(A) \simeq \left( THH(A) \otimes_A B \right)^{hG} \to THH(B)^{hG}$ is an equivalence. \end{itemize} \label{descvsbasechange} \end{proposition} \begin{proof} In this case, the maps $B \to THH(A) \otimes_A B \to THH(B)$ that we obtain are $G$-equivariant, as they are natural in the $\mathbb{E}_\infty$-$A$-algebra $B$. Therefore, the map $THH(A) \otimes_A B \to THH(B)$ is naturally a morphism in $\mathrm{CAlg}(\mathrm{Fun}(BG, \sp))_{B/}$. By \eqref{htpyfixedpoints}, the map is an equivalence if and only if it induces an equivalence on homotopy fixed points. Finally, if $THH(A) \otimes_A B \to THH(B)$ is an equivalence, then the morphism $THH(A) \to THH(B)$ is a base-change of the faithful $G$-Galois extension $A \to B$ and is thus a faithful $G$-Galois extension itself. Conversely, if $THH(A) \to THH(B)$ is a faithful $G$-Galois extension, then the descent map $THH(A) \to THH(B)^{hG}$ is an equivalence. \end{proof} In particular, the map $A \to B$ is strongly 0-cotruncated if and only if one has \emph{Galois descent} for $THH$ along the map $A \to B$. In \cite{CMNN}, we give a general criterion for proving descent in telescopically localized $THH$. \begin{theorem}[\cite{CMNN}] \label{CMNNthm} Suppose $A \to B$ is a $G$-Galois extension such that the map $K_0(B) \otimes \mathbb{Q} \to K_0(A) \otimes \mathbb{Q}$ induced by restriction of scalars is surjective. Fix an implicit prime $p$ and a height $n$. Fix a weakly additive (cf. \cite[Def.~3.11]{CMNN}) invariant $E$ of $\kappa$-compact small idempotent-complete $A$-linear $\infty$-categories taking values in a presentable stable $\infty$-category. Then the natural morphisms $$L_n^f E( \mathrm{Perf}(A)) \to L_n^f E( \mathrm{Perf}(B))^{hG} \to \left( L_n^f E(\mathrm{Perf}(B))\right)^{hG}$$ are equivalences, where $L_n^f$ denotes finitary $L_n$-localization. In particular, one can take $E = K, THH, TC$. \end{theorem} As a result, we can prove that the base-change map is an equivalence in a large class of ``chromatic'' examples of Galois extensions. \begin{theorem} Suppose $A \to B$ is a faithful $G$-Galois extension of $\mathbb{E}_\infty$-rings. Assume that for every prime $p$, the localization $A_{(p)}$ is $L_n^f$-local for some $n = n(p)$. Suppose the map $K_0(B) \otimes \mathbb{Q} \to K_0( A) \otimes \mathbb{Q}$ is surjective (or equivalently has image containing the unit). Then the base-change map $THH(A) \otimes_A B \to THH(B)$ is an equivalence. \end{theorem} \begin{proof} To check that the map $THH(A) \otimes_A B \to THH(B)$ is an equivalence, it suffices to localize at $p$, so we may assume $A$ and $B$ are $p$-local, and therefore $L_n^f$-local. Since $L_n^f$ is a smashing localization, it follows that all $THH$ terms in sight are automatically $L_n^f$-localized. In this case, the result follows by combining \Cref{descvsbasechange} and \Cref{CMNNthm}. \end{proof} \begin{example} Most classes of examples of faithful Galois extensions in chromatic homotopy theory satisfy the conditions of \Cref{CMNNthm}. We refer to \cite[\S 5]{CMNN} for a detailed treatment. For example: \begin{enumerate} \item The $C_2$-Galois extension $KO \to KU$ or the $C_{p-1}$-Galois extension $L \to \widehat{KU}_p$. \item The $G$-Galois extension $E_n^{hG} \to E_n$ if $G$ is a finite subgroup of the extended Morava stabilizer group (cf. \cite[Appendix B]{CMNN} by Meier, Naumann, and Noel). \item Any Galois extension of $TMF[1/n], Tmf_0(n)$ or related spectra. \end{enumerate} It follows that the comparison map in $THH$ is an equivalence for these Galois extensions. \end{example} \section{A counterexample} In this section, we will give an example over $\mathbb{F}_p$ where the comparison (or equivalently descent) map for $THH$ is not an equivalence. We begin with a useful weakening of \Cref{strongly}. \begin{definition} \label{0cotrunc} A morphism $x \to y$ in an $\infty$-category $\mathcal{C}$ is said to be \emph{0-cotruncated} if, for every $z \in \mathcal{C}$, the map $\hom_{\mathcal{C}}(y, z) \to \hom_{\mathcal{C}}(x, z)$ is a covering space (i.e., has discrete homotopy fibers over any basepoint). An object $x \in \mathcal{C} $ is said to be \emph{0-cotruncated} if $\hom_{\mathcal{C}}(x, z)$ is discrete for any $z \in \mathcal{C}$. \end{definition} The condition that $x \to y$ should be cotruncated is equivalent to the statement that $y \in \mathcal{C}_{x/}$ should define a 0-cotruncated object. Note that an object $x \in \mathcal{C}$ is 0-cotruncated if and only if the natural map $x \to S^1 \otimes x$ is an equivalence. In the setting of $\mathbb{E}_\infty$-ring spectra, \'etale morphisms are far from the only examples of 0-cotruncated morphisms. For example, any faithful $G$-Galois extension in the sense of Rognes \cite{rognes} is 0-cotruncated. This is essentially \cite[Lemma 9.2.6]{rognes}. However, we show that faithful Galois extensions need not be \emph{strongly} 0-cotruncated. Equivalently, base-change for $THH$ can fail for them. \begin{proof}[Proof of \Cref{mainexample}] Consider the degree $p$ map $S^1 \to S^1$, which is a $\mathbb{Z}/p$-torsor. Let $k$ be a separably closed field of characteristic $p$. For a space $X$, we let $C^*(X; k) = F(X_+; k)$ denote the $\mathbb{E}_\infty$-rings of $k$-valued cochains on $X$. The induced map of $\mathbb{E}_\infty$-rings $\phi\colon C^*(S^1; k) \to C^*(S^1; k)$ is a faithful $\mathbb{Z}/p$-Galois extension of $\mathbb{E}_\infty$-ring spectra. This follows from \cite[Prop. 5.6.3(a)]{rognes} together with the criterion for the faithfulness via vanishing of the Tate construction \cite[Prop. 6.3.3]{rognes}. See also \cite[Th. 7.13]{galoischromatic}. We will show, nonetheless, that $\phi$ does not satisfy base-change for $THH$, or equivalently that it is not strongly 0-cotruncated. It suffices to show this in $\mathrm{CAlg}_{k/}$ in view of \Cref{relativecotrunc}. By $p$-adic homotopy theory \cite{mandell} (see also \cite{DAG13}, which does not assume $k = \overline{\mathbb{F}_p}$), the natural map \[ S^1 \to \hom_{\mathrm{CAlg}_{k/}}( C^*(S^1; k), k) \] exhibits $\hom_{\mathrm{CAlg}_{k/}}( C^*(S^1; k), k) $ as the $p$-adic completion of $S^1$. In particular, $\hom_{\mathrm{CAlg}_{k/}}( C^*(S^1; k), k) \simeq K(\mathbb{Z}_p, 1) $ and the map given by precomposition with $\phi$ $$\hom_{\mathrm{CAlg}_{k/}}( C^*(S^1; k), k) \stackrel{\phi^*}{\to} \hom_{\mathrm{CAlg}_{k/}}( C^*(S^1; k), k),$$ is identified with multiplication by $p$, $K(\mathbb{Z}_p, 1) \to K(\mathbb{Z}_p, 1)$. In particular, while this is a covering map, it is \emph{not} a split covering map, so that $\phi$ is not strongly 0-cotruncated. \end{proof} The use of cochain algebras in providing such counterexamples goes back to an idea of Mandell \cite[Ex. 3.5]{McM}, who gives an example of a morphism of $\e{\infty}$-ring spectra with trivial cotangent complex (i.e., is $TAQ$-\'etale) which is not $THH$-\'etale. Namely, Mandell shows that if $n > 1$, then the map $C^*( K( \mathbb{Z}/p, n); \mathbb{F}_p) \to \mathbb{F}_p$ has trivial cotangent complex. We close by observing that it is the fundamental group that it is at the root of these problems. \begin{proposition} Let $X$ be a \emph{simply connected,} pointed space, and let $A \to B$ be a faithful $G$-Galois extension of $\mathbb{E}_\infty$-rings. In this case, the map of $\mathbb{E}_\infty$-rings \[ (X \otimes A) \otimes_A B \to X \otimes B, \] is an equivalence. \end{proposition} In particular, one does have base-change for higher topological Hochschild homology (i.e., where $X = S^n, n > 1$). \begin{proof} Following the earlier reasoning, it suffices to show that whenever $C \in \mathrm{CAlg}$, the square \[ \xymatrix{ \hom(X, \hom_{\mathrm{CAlg}}(B, C)) \ar[d] \ar[r] & \hom_{\mathrm{CAlg}}(B, C) \ar[d] \\ \hom(X, \hom_{\mathrm{CAlg}}(A ,C)) \ar[r] & \hom_{\mathrm{CAlg}}(A, C) }\] is homotopy cartesian. However, this follows because $\hom_{\mathrm{CAlg}}(B, C) \to \hom_{\mathrm{CAlg}}(A, C)$ is a covering space, and $X$ is simply connected. \end{proof} \bibliographystyle{alpha}
{ "redpajama_set_name": "RedPajamaArXiv" }
9,334
\section{Introduction} \label{sec_intro} In the first paper of this series \citep*[subsequently referred to as Paper I]{freyer03} we studied the evolution of the circumstellar gas around an isolated 60 $M_{\sun}$ star by means of numerical two-dimensional radiation hydrodynamic simulations. We found that the interaction of the photoionized H {\sc{ii}} region with the stellar wind bubble (SWB) strongly influences the morphological evolution during the early main-sequence (MS) phase of the star. On the one hand, the results show that the dynamical interaction processes contribute to the formation of complex structures which can be found in H {\sc{ii}} regions. On the other hand, these processes also impact on how and to what extent the stellar energy input (wind and H-ionizing radiation) is supplied to the interstellar medium (ISM), distributed among different forms of energy, and ultimately radiated from the system. While the consideration of the stellar wind strongly enhances the kinetic energy of bulk motion present in the system, ionization energy and the associated thermal energy of warm gas are generally lowered because the stellar wind intensifies the formation of high-density structures (clumps) with shorter hydrogen recombination times and stronger cooling. With this paper we continue our numerical analysis of the morphological and energetic influence of massive stars on their ambient ISM for a 35 $M_{\sun}$ star that evolves from the MS through the red supergiant (RSG) and the Wolf-Rayet (W-R) phases until it explodes as a supernova (SN). The goals of this paper are to examine the combined influence of wind and ionizing radiation on the dynamical evolution of circumstellar matter for this second set of stellar parameters, to compare and contrast the two numerical models we have obtained so far and to compare the model with observations of bubbles around W-R stars that have undergone an RSG phase. We will complete our little sequence of circumstellar gas models for a 85 $M_{\sun}$ star (D. Kr\"oger et al. 2005, in preparation) and a 15 $M_{\sun}$ star, representing the upper and lower end, respectively, of the stellar mass range that we are investigating. The remainder of this paper has the following structure: In section \ref{sec_observations} we review some recent observations of W-R stars with circumstellar nebulae that are conjectured to be ejected during the RSG phase of the star. Section \ref{sec_numerics} briefly reflects on the numerical methods and initial conditions used to produce the results presented in this paper and describes the set of stellar parameters used as time-dependent boundary conditions that drive the evolution. The results of the model calculations along with a comparison to observations and analytical models are presented in section \ref{sec_results}. We summarize our main results and conclusions in section \ref{sec_conclusions}. \section{Recent Observations} \label{sec_observations} From the theoretical point of view, each star that has a supersonic wind with a sufficiently high mass-loss rate should be capable of blowing a SWB into the ISM. The crucial indicator for the existence of such SWBs is the hot gas produced at the reverse shock. The X-ray emission of the hot ($10^6-10^8~\mathrm{K}$) gas should be detectable if the surface brightness is high enough for the respective telescope in use. Although theory predicts that even massive stars on the MS are supposed to produce SWBs, they are expected to be large and diffuse with a low surface brightness in X-rays. Thus, the vicinities of W-R stars seem to be promising candidates for the observation of SWBs (also called W-R bubbles if the central star is in its W-R stage). However, only 1/4 to 1/3 of the known galactic W-R stars seem to have associated ring nebulae and only 10 are wind-driven bubbles \citep{wrigge99}, according to the optically derived kinematics of the shell \citep{chu81}. Up to now only 2 of these SWB candidates have actually been detected in X-rays: NGC\,6888 \citep{bochkarev88, wrigge94} and S308 \citep{wrigge99, chu03}. Since both central W-R stars are thought to have undergone the MS $\rightarrow$ RSG $\rightarrow$ W-R evolution that we are investigating in this paper, we will briefly review the recent observational work for a careful comparison with our numerical results. NGC 6888 was among the first galactic ring nebulae whose formation have been attributed to mass ejection and radiation from a W-R star \citep{johnson65}. Its relative proximity and thus large angular size ($18' \times 12'$) has made it to one of the best studied examples of this class of objects. At a distance of 1.45 kpc \citep{wendker75} the physical radius of the nebula is 3.8 pc (major axis) $\times$ 2.5 pc (minor axis). The WN6 star HD 192163 \citep[= WR 136 according to the list of][]{vanderHucht01} is close to the center of the nebula. The ellipsoidal shell appears to be geometrically very thin and has a highly filamentary structure. With a mean electron density in the filaments of the nebula of 400 $\mathrm{cm^{-3}}$ \citep{parker64}, \citet{wendker75} derived a mass of 5 $M_{\sun}$ for the ionized shell and a mean shell thickness of 0.01 pc. The shell expansion velocity varies among different authors in the range $75 - 93~\mathrm{km~s^{-1}}$ \citep{treffers82, marston88, moore00}. It is important to distinguish two morphological features that are theoretically expected to evolve during the RSG and W-R stage of the star: A thin and dense ``RSG shell'' forms around the outflowing RSG wind when the reverse shock becomes radiative due to the high density of the wind in this stage. When the fast W-R wind turns on, the non-radiative reverse shock reestablishes itself and the shocked W-R wind sweeps up the RSG wind in the so-called ``W-R shell''. The dynamical age of the W-R shell \begin{equation} t_{\mathrm{dyn}} = \frac{\eta R_{\mathrm{shell}}}{v_{\mathrm{shell}}} \label{eq_t_dyn} \end{equation} depends on the expansion velocity and on the assumption of the density profile into which the shell expands. Typically, two cases are considered: a constant ambient density \citep[$\eta = 0.6$ according to][]{weaver77} and a $\rho \propto 1/r^2$ density profile \citep[$\eta = 1.0$ according to][]{garcia95a}. With the expansion velocities quoted above, a mean shell radius of 3.2 pc, and the assumption that the optically visible nebula can be associated with the W-R shell, one obtains a minimum value for the dynamical age of NGC 6888 of $2.0 \times 10^4~\mathrm{yr}$ ($\eta = 0.6$ and $v_{\mathrm{shell}}$ = $93~\mathrm{km~s^{-1}}$) and a maximum value of $4.2 \times 10^4~\mathrm{yr}$ ($\eta = 1.0$ and $v_{\mathrm{shell}}$ = $75~\mathrm{km~s^{-1}}$). \citet{moore00} used the WFPC2 on the {\it Hubble Space Telescope (HST)} to examine the filaments of the bright northeast rim of NGC 6888 in the light of the $\mathrm{H\alpha}$ $\lambda 6563$, [O {\sc{iii}}] $\lambda 5007$, and [S {\sc{ii}}] $\lambda\lambda 6717,~6731$ lines. They found filament densities of $1000-1600~\mathrm{cm^{-3}}$. The dense shell is enveloped by a skin of emission most evident in [O {\sc{iii}}] $\lambda 5007$ and it is proposed that this skin arises in a cooling regime behind a radiative shock driven into the medium around the shell. For the low density that is expected in the MS bubble without heat conduction a forward shock ahead of the nebula shell would not be visible. Thus, the authors propose that a considerable fraction of the approximately 18 $M_{\sun}$ RSG wind is possibly present in the MS bubble as a low-density ($2~\mathrm{cm^{-3}}$) exterior layer with low $\mathrm{H\alpha}$ surface brightness, visible only in [O {\sc{iii}}] $\lambda 5007$ postshock emission as the skin engulfing the $\mathrm{H\alpha}$ filaments when it becomes shocked by some combination of nebular shell expansion and the pressure of the postshock W-R wind overtaking the RSG shell. The large discrepancy between the density in the MS bubble of the model and the observed density of the skin could be explained by thermal evaporation of RSG wind material into the MS bubble. Spectroscopy of the nebular shell shows that the ionized gas is enriched with nitrogen and helium and underabundant in oxygen. Possible explanations might be the transport of chemically enriched material from the core of the star to the outer layers that are ejected during the RSG stage \citep{esteban92} or the mixing of W-R and RSG wind material \citep{kwitter81}. The high abundance of nitrogen in the nebula is consistent with the classification of HD 192163 as a WN6 star. There is some debate on how much neutral gas is present in NGC 6888. The answer to this question has implications on the interpretation of the dynamics of the bubble as being either energy or momentum conserving. \citet{marston88} found from {\it IRAS} observations (assuming a gas to dust mass ratio of 100) a shell of 40 $M_{\sun}$ neutral gas directly outside the ionized shell. The difficulty in the interpretation of the observed data is the correct estimate of the forbidden line contribution in the far infrared. \citet{vanBuren88} concluded that the emission in the {\it IRAS} 60 $\mathrm{\mu m}$ and 100 $\mathrm{\mu m}$ bands is predominantly from forbidden [O {\sc{iii}}] lines indicating that the continuum emission from the dust and thus the neutral mass would be negligible. \citet{marston91} claims that the flux contribution from forbidden [O {\sc{iii}}] and [N {\sc{iii}}] lines is only $8-20$\% and that the major reason for these deviating results is the higher flux from the nebula which he derived because of a differing background removal procedure. However, \citet{moore00} conclude from their {\it HST} WFPC2 observations of the nebula that there cannot be a significant amount of neutral material close to the optical nebula. Their result for the hydrogen ionizing flux of $10^{49.3} \mathrm{s^{-1}}$ is in reasonable agreement with the value of $10^{49} \mathrm{s^{-1}}$ from the W-R models of \citet{crowther96} and does perfectly match the value from \citet{garcia96b} that we use for our calculations presented in this paper, but it is roughly a factor of 50 higher than the Lyman continuum flux of $10^{47.6} \mathrm{s^{-1}}$ which \citet{marston88} found as necessary to maintain the observed $\mathrm{H\alpha}$ brightness of the nebula. In other words: Only 2\% of the ionizing photons from HD 192163 are used to ionize the observable nebular shell of NGC 6888 - it is ``density-bounded'' not ``ionization-bounded''. 98\% would still be available to ionize the neutral parts of the shell. Since the shock front ahead of the shell is partially shadowed from the stellar Lyman continuum flux by dense clumps within the shell, it is obvious that there is indeed some neutral material in the shell, but on the other hand the shell is very leaky to Lyman continuum photons and it is unlikely that there is as much as 40 $M_{\sun}$ neutral gas present directly outside the ionized shell because that would process a larger fraction of the stellar Lyman continuum flux into $\mathrm{H\alpha}$ emission. Observational evidence has also been found for the existence of the shell of swept-up ambient ISM around the MS bubble. Using highly resolved {\it IRAS} images \citet{marston95} discovered an elliptical shell with average radius of 19 pc (assuming a distance to HD 192163 of 1.45 kpc) and mass of $\approx$8000~$M_{\sun}$ (assuming a gas to dust mass ratio of 100). However, this value should be used with some caution since it was obtained with the same techniques that have been applied to produce the controversial result for the amount of neutral mass contained in the W-R bubble. NGC 6888 was the first SWB that has been observed in X-rays \citep{bochkarev88, wrigge94}. The latter authors examined the X-ray emission from NGC 6888 using the PSPC detector of the {\it ROSAT} satellite and found that it is filamentary and concentrated in the brightest optical features of the nebula. 70\% of the total X-ray emission originates from only ${\approx}1-2\%$ of the bubble volume. With their assumed distance to NGC 6888 of 1.8 kpc the X-ray luminosity is estimated to be $1.6 \times 10^{34}~\mathrm{ergs~s^{-1}}$ in the energy band $0.07-2.41$ keV and the plasma temperature to be $2 \times 10^6~\mathrm{K}$. \citet{wrigge02} also used the HRI detector on board the {\it ROSAT} satellite to obtain X-ray emission maps with higher spatial resolution. They conclude that approximately half of the total X-ray emission originates from small filaments with typical size of a few tenths of a pc and typical luminosity in the {\it ROSAT} HRI band of several $10^{31}~\mathrm{ergs~s^{-1}}$, corresponding to a hydrogen number density in the filaments of a few $\mathrm{cm^{-3}}$. \citet{wrigge02} also examined the possibility that the emission of these filaments is produced by clumps of dense gas which evaporate in the bubble of hot gas. They find that this explanation could only be consistent with the observations if the bubble gas is sufficiently hot ($5-10 \times 10^6~\mathrm{K}$). S308 surrounding the WN4 star HD 50896 (= EZ CMa = WR 6) is the second SWB that has been observed in X-rays. The optically visible nebula is characterized by an almost spherically symmetric shell with a remarkable protrusion in the northwest quadrant but otherwise with no hints on the formation of pronounced instabilities. The distance to S308 and thus all quantities which scale with the distance are somewhat uncertain. \citet{chu82b} give $D = 1.5~\mathrm{kpc}$. \citet{hamann88} found that the range from 0.9 to a few kpc is in agreement with the results of their spectral analysis, with a preferred value of 2 kpc. \citet{howarth95} estimate $D = 1.8~\mathrm{kpc}$ with an uncertainty of 15\% based on their high-resolution observations of the interstellar Na {\sc{i}} D lines in the spectra of HD 50896 and several nearby stars. Measurements with the {\it Hipparcos} satellite indicated $D = 0.6^{+0.4}_{-0.2}~\mathrm{kpc}$ \citep{perryman97}, which seems to be unreasonably close, when compared with the other distance-estimate techniques. The photometric distance to HD 50896 is $D = 1.0 \pm 0.2~\mathrm{kpc}$ \citep{vanderHucht01} and the kinematic distance based on radial velocity information (of S308 and neighboring H {\sc{ii}} regions) and Galactic rotation is $D = 1.5 \pm 0.2~\mathrm{kpc}$ \citep{chu03}. We will subsequently use a distance of 1.5 kpc and all the distance-depending values that we quote from other papers are scaled accordingly. The radius of the optically visible shell is 9 pc and the shell expands with $v = 63~\mathrm{km~s^{-1}}$ \citep{chu03}. The ionized mass of the shell is 54 $M_{\sun}$ \citep[][scaled according to the values of radius and expansion velocity used here]{chu82b}. The derived average hydrogen number density of the ambient gas that has been swept up is thus $\approx$0.6~$\mathrm{cm^{-3}}$. An interesting implication of the distance and position on the sky is that S308 lies approximately 260 pc above the galactic plane, an unusual place for a massive star. Since HD 50896 also has a compact companion, possibly the stellar remnant of a SN explosion, it has been proposed that it is a runaway star \citep{firmani79}. However, because the location of HD 50896 is almost central within S308 the transverse velocity of HD 50896 with respect to its shell cannot be very high. For an adopted dynamical age of the nebula of 0.14 Myr \citep{chu03} the star can reach its projected displacement from the center of the bubble with a velocity of less than $7~\mathrm{km~s^{-1}}$ \citep{chu82b}. There is no morphological evidence for supersonic transverse motion of the star + shell system with respect to its local ISM. \citet{wrigge99} used the {\it ROSAT} PSPC detector to examine the X-ray emission from S308. Despite some technical difficulties he found that the observed spectrum can be fitted by a two-temperature emission model, one component at $T= 1.5 \times 10^6~\mathrm{K}$ and the second at $T= 2.8 \times 10^7~\mathrm{K}$. A total luminosity of $2.1 \times 10^{33}~\mathrm{ergs~s^{-1}}$ (scaled to the distance of $D = 1.5~\mathrm{kpc}$) in the energy band between 0.1 keV and 2.04 keV has been determined. The emitting volume is probably a thick shell with a ratio of inner to outer radius $\approx$0.5. One of the major conclusions of \citet{wrigge99} regarding the theoretical models is that S308 cannot be described by either the \citet{weaver77} constant ambient density model or by the two-wind model of \citet{garcia95a}. A comparable bubble produced within the two-wind framework would have an X-ray luminosity of $9 \times 10^{33}~\mathrm{ergs~s^{-1}}$, which is roughly in agreement with the observed value (bearing in mind the uncertainty in the determination of the observed X-ray luminosity). The problem is that the stellar wind luminosity which is necessary to reproduce the bubble in the model is only $\approx$3\% of the stellar wind luminosity that \citet{hamann93} derived for HD 50896 ($v_w = 1700~\mathrm{km~s^{-1}}$, $\dot{M}_w = 5.4 \times 10^{-5}~M_{\sun}~\mathrm{yr^{-1}}$, scaled to the distance of $D = 1.5~\mathrm{kpc}$ used here). Even if the lower clumping-corrected mass-loss rate of \citet{nugis98} is used to derive the mechanical wind luminosity, the value from the model is still almost an order of magnitude lower. This is called the ``missing wind problem''. Moreover, the observed X-ray surface brightness profile of S308 is limb brightened while the theoretical profile is centrally filled. The result for the classical bubble model according to \citet{weaver77} is similar: Although the stellar wind luminosity needed to reproduce the observed bubble kinematics is higher than in the two-wind model of \citet{garcia95a}, it is still only $\approx$8\% of the observed value ($\approx$32\% for the clumping-corrected mass-loss rate). \citet{chu03} observed the X-ray emission from the northwest quadrant of S308 using the EPIC CCD cameras of the {\it XMM-Newton} satellite. They found that the X-ray emission is completely interior to the optical shell and reconfirmed the limb brightening. The brightest X-ray emitting regions are linked to bright optical filaments. The total X-ray luminosity of S308, extrapolated from the observed flux from the northwest quadrant, is $\le (1.2 \pm 0.5) \times 10^{34}~\mathrm{ergs~s^{-1}}$ in the energy band between 0.25 keV and 1.5 keV. The observed spectrum can be fitted with the emission of an optically thin, nitrogen-enriched plasma of temperature $T = 1.1 \times 10^6~\mathrm{K}$. This is quite ``cool'' compared to the postshock temperature of order $10^8$ K which is expected for a rare stellar wind with terminal velocity of a few $1000~\mathrm{km~s^{-1}}$ and might indicate that the shocked W-R wind has mixed with cold gas by the processes of thermal evaporation and/or dynamic ablation. The spectrum is very soft so that there is basically no emission beyond 1 keV. The existence of a high-temperature gas component that substantially contributes to the observed emission and that has been claimed to be detected by \citet{wrigge99} is ruled out. Less than 6\% of the observed X-ray flux (which corresponds to 1.5\% of the unabsorbed X-ray flux) can be attributed to the emission of a hotter gas component. The reason for these contradicting results is probably the low signal-to-noise ratio in the {\it ROSAT} PSPC data that \citet{wrigge99} obtained together with a number of point sources which have not been resolved by the PSPC detector. Since the [O {\sc{iii}}] $\lambda 5007$ emission of S308 has a sharp rim, the nebular shell is probably still surrounded by unaffected RSG wind material. This RSG material cannot extend too much farther out, if the protrusion in the northwest quadrant is interpreted as a first blowout. There is a gap between the outer rim of the [O {\sc{iii}}] $\lambda 5007$ emission and the outer edge of the X-ray emission of between 90 arcsec to over 200 arcsec, corresponding to $0.7-1.5$ pc. \citet{chu03} interpret this gap as being filled by the W-R shell and probably a transition layer. This is also indicated by the detection of an interstellar N {\sc{v}} absorption line toward HD 50896, which \citet{boroson97} attribute to the shell of S308. The electron density in the X-ray emitting gas is estimated to be $n_e = 0.28 \pm 0.04~\mathrm{cm^{-3}}$ or $n_e = 0.63 \pm 0.09~\mathrm{cm^{-3}}$ for an assumed hot gas volume filling factor of 0.5 or 0.1, respectively. The filling factor is expected to be closer to 0.5 since the limb-brightened X-ray emission profile suggests emission from a thick shell. The resulting mass of the X-ray emitting gas is $11 \pm 5~M_{\sun}$ or $5 \pm 3~M_{\sun}$ for the two volume filling factors. Assuming that the optical emission which has been used to determine the expansion velocity comes from the W-R shell, the age of the W-R phase can be estimated using equation \ref{eq_t_dyn}. For $R_{\mathrm{shell}}$ = 9 pc, $v_{\mathrm{shell}}$ = $63~\mathrm{km~s^{-1}}$, and $\eta = 1.0$ this yields $t_{\mathrm{dyn}}$ = 0.14 Myr. For a clumping-corrected mass-loss rate of HD 50896 of $1.4 \times 10^{-5}~M_{\sun}~\mathrm{yr^{-1}}$ \citep[][scaled to the distance used here]{nugis98} the mass blown into the bubble by the W-R wind is 2 $M_{\sun}$. This is less than the X-ray emitting gas mass, a fact which in turn supports the idea that RSG material is mixed with the shocked W-R wind in the bubble or that the main source of X-rays is different from the shocked W-R wind. Observations of S308 in the optical waveband furthermore show that besides photoionization there is also shock heating present, indicated by the high [O {\sc{iii}}] $\lambda 5007$/$\mathrm{H\beta}$ ratio of 20 \citep{esteban92b}. Similar to the case of NGC 6888, the [O {\sc{iii}}] $\lambda 5007$ emission leads the $\mathrm{H\alpha}$ emission by 16-20 arcsec \citep{gruendl00} corresponding to $0.12-0.15$ pc. Furthermore, S308 is located in an H {\sc{i}} cavity swept free by the MS wind of HD 50896 \citep{arnal96}. \section{Numerical Method} \label{sec_numerics} \subsection{Radiation Hydrodynamics Scheme} \label{sec_num_rad_hydro} The numerical code used to obtain the results presented in this paper is described in \citeauthor{freyer03}. The hydrodynamical equations are solved together with the transfer of H-ionizing photons on a two-dimensional cylindrical grid. The time dependent ionization and recombination of hydrogen is calculated each time step and we carefully take stock of all the important energy exchange processes in the system. For a closer description of the algorithm we refer the reader to \citet{yorke95}, \citet{yorke96}, and \citeauthor{freyer03}. \subsection{Initial Conditions} \label{subsec_ini_cond} We use the same undisturbed background gas layer with hydrogen number density $n_0 = 20~\mathrm{cm^{-3}}$ and temperature $T_0 = 200~\mathrm{K}$ for the reasons described in \citeauthor{freyer03} and start our calculations with the sudden turn-on of the zero-age main-sequence (ZAMS) stellar radiation field and stellar wind. After $t = 700~\mathrm{yr}$ the spherical one-dimensional solution is used as initial model for the two-dimensional calculations. \subsection{Boundary Conditions} \label{subsec_bound_cond} The basic difference between the 60 $M_{\sun}$ case described in \citeauthor{freyer03} and the 35 $M_{\sun}$ case is the set of time-dependent stellar parameters. The mass-loss rate ($\dot{M}_w$), terminal velocity of the wind ($v_w$), effective temperature ($T_{\mathrm{eff}}$), and photon luminosity in the Lyman continuum ($L_{\mathrm{LyC}}$) drive the evolution of the circumstellar gas. For the 35 $M_{\sun}$ star we adopt the stellar parameters given by \citet[][their version with the ``fast'' $75~\mathrm{km~s^{-1}}$ RSG wind]{garcia96b} shown in Figure \ref{35Msun_input4apj_up.eps}. Here, the star undergoes the following evolution: MS O star $\rightarrow$ RSG star $\rightarrow$ W-R star $\rightarrow$ SN. The MS phase lasts for about $4.52~\mathrm{Myr}$, the RSG phase $0.234~\mathrm{Myr}$ and the final W-R phase $0.191~\mathrm{Myr}$. After $4.945~\mathrm{Myr}$ the calculation stops and the star explodes as a SN. During the star's MS phase the mass-loss rate rises approximately from $3 \times 10^{-7}~M_{\sun}~\mathrm{yr^{-1}}$ to $10^{-6}~M_{\sun}~\mathrm{yr^{-1}}$. With the onset of the RSG phase the mass-loss rate jumps up to almost $10^{-4}~M_{\sun}~\mathrm{yr^{-1}}$. In the final W-R phase it is of the order $(2-3) \times 10^{-5}~M_{\sun}~\mathrm{yr^{-1}}$. The terminal velocity of the stellar wind on the MS is between $2 \times 10^{3}~\mathrm{km~s^{-1}}$ and $4 \times 10^{3}~\mathrm{km~s^{-1}}$, during the RSG phase it drops below $100~\mathrm{km~s^{-1}}$ until it again reaches values of $(1-4) \times 10^{3}~\mathrm{km~s^{-1}}$ in the final W-R phase. The effective temperature during the MS phase lies in the range of $(3-4) \times 10^4~\mathrm{K}$, falls down to a few thousand Kelvin in the RSG phase and temporarily reaches more than $10^5~\mathrm{K}$ during the final W-R phase. While the total photon luminosity of the star is relatively constant with values of $(7-14) \times 10^{38}~\mathrm{ergs~s^{-1}}$ during the whole evolution of the star, the photon luminosity in the Lyman continuum and the mechanical luminosity of the wind reflect the strong changes of mass-loss rate, terminal velocity of the wind and effective temperature. The Lyman continuum luminosity during the MS is in the range of $(2-3) \times 10^{38}~\mathrm{ergs~s^{-1}}$. In the course of the RSG phase it is insignificant due to the strong decrease of the effective temperature. The inverse situation occurs during the subsequent W-R phase: Because of the high effective temperature, most of the radiative power is emitted above the Lyman edge and the Lyman continuum luminosity reaches almost $10^{39}~\mathrm{ergs~s^{-1}}$. The mechanical wind luminosity ($\dot{M}_w v_w^2 / 2$) during the MS phase is $(1-2) \times 10^{36}~\mathrm{ergs~s^{-1}}$, drops by approximately one order of magnitude during the RSG phase, and reaches the highest values between $10^{37}~\mathrm{ergs~s^{-1}}$ and $10^{38}~\mathrm{ergs~s^{-1}}$ in the final W-R phase. Here, the radius of the ``wind generator region'' is $2.16 \times 10^{17}~\mathrm{cm}$. The grid organization scheme as well as the other boundary conditions are unchanged compared to the 60 $M_{\sun}$ case presented in \citeauthor{freyer03}. \subsection{Geometry and Resolution} \label{subsec_geometry} The size of the coarsest mesh, representing the size of the computational domain, is $r_{\mathrm{max}} = z_{\mathrm{max}} = 50~\mathrm{pc}$. This value ensures that the coarsest grid covers the entire evolution during the lifetime of the star and thus prohibits that the ionization front or moving material can reach the outer boundary of the coarsest grid. The size is smaller than for the 60 $M_{\sun}$ case since the size of the developing bubble is smaller as well. Six nested grids are employed within the coarsest grid, resulting in seven grid levels. On each grid level $125 \times 125$ cells (excluding ghost cells) are used resulting in a linear resolution that ranges from $6.25 \times 10^{-3}~\mathrm{pc}$ close to the star to 0.4 pc in the outermost parts of the coarsest grid. \section{Results and Discussion} \label{sec_results} \subsection{A Resolution Study} \label{subsec_validity} Similar to \citeauthor{freyer03} we performed a resolution study for the 35 $M_{\sun}$ case to ensure that the spatial resolution is high enough and that the numerical results are trustworthy. The same selection of parameters was calculated with three different resolutions, medium (125 cells in each dimension), low (61 cells in each dimension), and high (253 cells in each dimension). Again, we compare only the first Myr of the evolution since the high-resolution model would require too much CPU time for the entire lifetime of the star. Figure \ref{comp_resol_228_229_230apj_up.eps} shows the results of this resolution study. The quality of the results is comparable to that of the 60 $M_{\sun}$ case presented in \citeauthor{freyer03}. The variation of the thermal energy with resolution is $\lesssim$ 0.05 dex at almost any time during the first Myr. For ionization energy and kinetic energy of bulk motion the deviation between low and high resolution is $\lesssim$ 0.05 dex for $0.5~\mathrm{Myr} \le t \le 1.0~\mathrm{Myr}$ and $\lesssim$ 0.1 dex for $t \le 0.5~\mathrm{Myr}$, the latter case with a considerably smaller shift between medium and high resolution than between low and medium resolution, indicating that these values are already close to the actual limit. These results show that for the 35 $M_{\sun}$ case discussed here the errors in our energetic analysis due to resolution effects are within an acceptable range, while there are morphological details which remain to be explored in future simulations with even higher resolution. \subsection{Evolution of the 35 $M_{\sun}$ Case} \label{subsec_35msun_model} Figures \ref{ion_uchii_apj230.001.001.3.med.mono.eps} to \ref{ion_uchii_apj229.967.008.1.med.mono.eps} depict the evolution of the gas in the vicinity of and under the influence of the 35 $M_{\sun}$ model star. The data are plotted in the same manner as in \citeauthor{freyer03} for the 60 $M_{\sun}$ case. Once again, we begin our discussion with the initial model that has been set up from the one-dimensional solution. For the 35 $M_{\sun}$ case this is done after 700 yr because --- due to the lower mechanical wind luminosity of the star --- the pressure in the hot bubble is lower. Thus, the forward shock is weaker and the shell of swept-up material is less heated and collapses earlier. As expected, the basic structure of the SWB/H {\sc{ii}} region seen in Figure \ref{ion_uchii_apj230.001.001.3.med.mono.eps} is the same as for the 60 $M_{\sun}$ case except for the length and time scales. The stellar wind flows with the terminal velocity of nearly $4000~\mathrm{km~s^{-1}}$ freely out to $r \approx 0.08~\mathrm{pc}$, the position of the reverse shock, where it is heated up to about $10^8~\mathrm{K}$. The forward shock that sweeps up the H {\sc{ii}} region is at $r \approx 0.23~\mathrm{pc}$ and moves with some $130~\mathrm{km~s^{-1}}$. Density and temperature immediately behind this shock front are $\rho \approx 1.4 \times 10^{-22}~\mathrm{g~cm^{-3}}$ and $T \approx 2.5 \times 10^5~\mathrm{K}$, respectively, which is in good agreement with the jump conditions for a strong shock moving into photoionized gas with $T \approx 8000~\mathrm{K}$. The ionization front is still weak R-type at 4.7 pc. After $5 \times 10^4~\mathrm{yr}$ (Figure \ref{ion_uchii_apj230.017.001.3.med.mono.eps}) the hot bubble extends out to about 2.3 pc. The shell of swept-up H {\sc{ii}} region expands with some $24~\mathrm{km~s^{-1}}$. Density knots have been produced in the thin shell, similar to those seen in the 60 $M_{\sun}$ case, altering the optical depth along different radial lines of sight. The H {\sc{ii}} region has begun to expand with almost $10~\mathrm{km~s^{-1}}$, sweeping up the ambient neutral gas, but the ionization front has started to retreat at the places where the clumps in the stellar wind shell cast shadows into the H {\sc{ii}} region. The basic morphological structure is still comparable to the 60 $M_{\sun}$ case. Figure \ref{ion_uchii_apj230.030.001.3.med.mono.eps} shows the evolutionary state of the 35 $M_{\sun}$ case after 0.2 Myr. The radius of the H {\sc{ii}} region is approximately 9.5 pc and it expands into the ambient medium at several $\mathrm{km~s^{-1}}$. (When neutral shadows and ionized extensions appear, we define the radius of the H {\sc{ii}} region as the distance from the star to the ``undisturbed'' ionization front which is neither extended along the fingers nor shortened by the shadows.) The hot bubble has grown to $r \approx 4.8~\mathrm{pc}$ and the expansion velocity of the stellar wind shell has decelerated to $\approx$13~$\mathrm{km~s^{-1}}$. This is comparable to the sound speed in the H {\sc{ii}} region; i.e., the outermost side of the stellar wind shell is no longer bound by a shock front and has begun to expand into the H {\sc{ii}} region as a result of the pressure gradient between the shell and the H {\sc{ii}} region. (For clarity, we distinguish the stellar wind shell and the H {\sc{ii}} region. Actually, the stellar wind shell is an important part of the H {\sc{ii}} region because it is, at least at this point in time, photoionized by the star.) At $t = 0.2~\mathrm{Myr}$ the geometrical thickness of the stellar wind shell has already grown to 1 pc and the density in the shell is $(6-9) \times 10^{-23}~\mathrm{g~cm^{-3}}$. As a result of the growth of the geometrical shell thickness, the thin-shell instability that triggered the formation of density clumps in the shell ceased and the clumps dissolved; the period of time they were present in the stellar wind shell was relatively short. Thus, the shadows in the H {\sc{ii}} region are much less pronounced and the finger-like extensions of the H {\sc{ii}} region are shorter and less numerous than for the 60 $M_{\sun}$ case. Nevertheless, density fluctuations in the H {\sc{ii}} region of more than an order of magnitude have been produced. (This may be a lower limit because of restrictions in resolution.) Maximum densities are around $\rho \approx 5 \times 10^{-23}~\mathrm{g~cm^{-3}}$ and minima around $\rho \approx 3 \times 10^{-24}~\mathrm{g~cm^{-3}}$. At these densities, temperatures, and masses the clumps are not gravitationally bound. The dissolution of the stellar wind shell can impressively be seen in Figure \ref{ion_uchii_apj230.041.001.3.med.mono.eps} at $t = 0.3~\mathrm{Myr}$. The expansion of the stellar wind shell has become a 2 pc broad belt of outflow with density $(2-5) \times 10^{-23}~\mathrm{g~cm^{-3}}$ from the contact discontinuity at $r \approx 6~\mathrm{pc}$ into the H {\sc{ii}} region with about sound speed. Additional processes are triggered by the rarefaction of the gas that previously belonged to the stellar wind shell: Because of the increase of hydrogen recombination time with lower density, excess photons are generated which reionize the shadowed regions (see lower panel of Figure \ref{ion_uchii_apj230.041.001.3.med.mono.eps}) and advance the ionization front even further, evaporating additional material from the H {\sc{ii}} region shell of swept-up ambient medium ahead. This evaporation is visible in the density increase and the disturbed velocity field in the outer parts of the H {\sc{ii}} region close to the ionization front. As a transient phenomenon, another shell with a density of $(3-6) \times 10^{-23}~\mathrm{g~cm^{-3}}$ develops at $t \approx 0.35~\mathrm{Myr}$ when the former stellar wind shell gas flowing into the H {\sc{ii}} region collides with the photoevaporated material from this swept-up ambient shell. Together with the relics of denser fragments in the H {\sc{ii}} region, the larger opacity in this dense shell causes once again the formation of small ripples in the ionization front at $t \approx 0.4~\mathrm{Myr}$ (Figure \ref{ion_uchii_apj230.048.002.3.med.mono.eps}). At this time the radius of the hot bubble is about 7.5 pc and the geometrical thickness of the whole H {\sc{ii}} region is about 4 pc. However, the newly formed shell soon dissolves because of its overpressure with respect to the rest of the H {\sc{ii}} region, and within certain limits it can thus be said that the dissolution of the stellar wind shell leads to a ``rehomogenization'' of the H {\sc{ii}} region. If we continue our analysis of this case to $t = 0.6~\mathrm{Myr}$ (Figure \ref{ion_uchii_apj230.063.002.2.med.mono.eps}, please note the different scale), we see that the hot bubble has grown to almost 10 pc in radius. The shell-like H {\sc{ii}} region, still expanding into the ambient medium at about $10~\mathrm{km~s^{-1}}$, becomes more and more homogeneous. Nevertheless, remaining density fluctuations from the previous formation and destruction processes are still in the range from $7 \times 10^{-24}~\mathrm{g~cm^{-3}}$ to $4 \times 10^{-23}~\mathrm{g~cm^{-3}}$. We compare the morphological characteristics of the circumstellar gas which result from our runs with different resolution after 1 Myr in Figure \ref{ion_uchii_apj230.092.002.2.med.mono.eps} (high resolution) and Figure \ref{ion_uchii_apj229.404.001.2.med.mono.eps} (medium resolution). As can be expected the overall structure in both runs is the same. The radius of the shell of swept-up ambient gas around the H {\sc{ii}} region is $\approx$17 pc and it expands at almost $10~\mathrm{km~s^{-1}}$. The geometrical thickness of the H {\sc{ii}} region itself is slightly larger in the high-resolution run, the velocity field in the H {\sc{ii}} region is stronger perturbed than in the medium-resolution run, and some fragments of the photoionized gas protrude and get mixed into the hot gas. All the latter deviations can be understood in terms of the finer substructures in the H {\sc{ii}} region, which were able to form in the high-resolution run. However, the trend toward a rehomogenization of the H {\sc{ii}} region continues: The density fluctuations in the H {\sc{ii}} region are only in the range of $9 \times 10^{-24}~\mathrm{g~cm^{-3}}$ to $2 \times 10^{-23}~\mathrm{g~cm^{-3}}$, except for very small regions at the inner side of the shell of swept-up ambient gas. Here the density is reduced after neutral clumps from the shell have been evaporated ``explosively''. Subsequently for $t > 1~\mathrm{Myr}$ we consider only the medium-resolution model. Since the stellar parameters vary only very gradually during the MS phase until the star enters the RSG stage (see Figure \ref{35Msun_input4apj_up.eps}), the basic structure of the SWB/H {\sc{ii}} region remains the same during the next 3 Myr except that it continues to grow. Thus, we can proceed with our description of the evolution to Figure \ref{ion_uchii_apj229.942.003.1.med.mono.eps}, which shows the bubble at the age of 4 Myr (please note once again the larger scale). The radius of the hot bubble is now about 27 pc and the H {\sc{ii}} region extends out to $\approx$35 pc. The hot bubble and the photoionized H {\sc{ii}} region are in pressure equilibrium; as the pressure of the hot bubble decreases through expansion, the pressure of the H {\sc{ii}} region drops, too. Because the temperature in the H {\sc{ii}} region is nearly constant in time, the density has decreased to $(3.9-5.5) \times 10^{-24}~\mathrm{g~cm^{-3}}$. A few dense clumps are visible in the hot bubble which have detached from the H {\sc{ii}} region. The thermal pressure of the SWB/H {\sc{ii}} region is still $\approx$20 times higher than that of the ambient medium and the whole structure still expands at about $4-5~\mathrm{km~s^{-1}}$. As a result of the additionally swept-up material, the reduced pressure in the H {\sc{ii}} region, and the deceleration of the expansion, the geometrical thickness of the outer shell has increased to almost 3 pc while its density has decreased to $\rho \approx (1-2) \times 10^{-22}~\mathrm{g~cm^{-3}}$. Thus, the mass collected in this shell is about $2 \times 10^{38}~\mathrm{g}$. This result is in good agreement with the picture that most of the ambient gas that has been swept up during the expansion since the ionization front turned to D-type is still stored in the outer shell and that only a minor fraction has been evaporated into the H {\sc{ii}} region. At $t \approx 4.52~\mathrm{Myr}$ the star enters the RSG phase. The effective temperature of the star decreases to a few thousand Kelvin and the Lyman continuum flux drops by many orders of magnitude. The mass-loss rate strongly increases and the terminal velocity of the wind decreases; i.e., the star blows a dense and slow wind into the hot bubble. This can be seen in Figure \ref{ion_uchii_apj229.960.017.1.med.mono.eps}, which depicts the state of the circumstellar gas at $t \approx 4.59~\mathrm{Myr}$. At this time the dense RSG wind fills the inner 5 pc of the volume and expands at about $90~\mathrm{km~s^{-1}}$ into the hot bubble extending out to about 30 pc. Although the wind speed during the RSG phase is relatively low (compared to the MS and W-R phases), the material becomes shocked when it is decelerated by the pressure of the MS bubble because the sound speed in the RSG wind is also low. (The gas is cold and neutral, or even molecular, because the soft stellar radiation field in the RSG phase is incapable of ionizing and heating it.) Since the density of the RSG wind is fairly high, this reverse shock is radiative and forms the very thin and dense RSG shell, which is not completely resolved in our calculation \citep[compare to][the case of the fast RSG wind]{garcia96b}. Because of the reduction of Lyman continuum flux, the hydrogen in the former H {\sc{ii}} region between $30~\mathrm{pc} \lesssim r \lesssim 38~\mathrm{pc}$ starts to recombine. The degree of hydrogen ionization drops to $\approx$ 0.3 as the gas cools from about 6600 K at $t = 4~\mathrm{Myr}$ to 4800 K. Thus, the thermal pressure in the (former) H {\sc{ii}} region drops significantly, leading to a further broadening and slowing down of the outer shell of swept-up ambient medium, which at this time has a thickness of about 3 pc and a velocity of $\approx$4~$\mathrm{km~s^{-1}}$. The transition from the RSG phase of the star to the W-R phase occurs at $t \approx 4.754~\mathrm{Myr}$. In the W-R phase the mass-loss rate is somewhat lower than in the RSG stage (see Figure \ref{35Msun_input4apj_up.eps}), but the terminal velocity of the W-R wind is much higher (a few thousand $\mathrm{km~s^{-1}}$). The mechanical luminosity of the W-R wind is thus much higher than that of the RSG wind. Because of the increase of effective temperature to about $10^5~\mathrm{K}$, the stellar photon output occurs largely beyond the Lyman continuum limit; the star's Lyman continuum luminosity $\approx 10^{39}~\mathrm{ergs~s^{-1}}$ is higher than during the MS phase of the star. Figure \ref{ion_uchii_apj229.962.006.1.med.mono.eps} shows the structure of the circumstellar gas at $t = 4.78~\mathrm{Myr}$, some $2.6 \times 10^4~\mathrm{yr}$ after the start of the W-R wind. The fast (and thus less dense) W-R wind reestablishes a non-radiative reverse shock that heats the W-R wind to about $10^8~\mathrm{K}$. The expansion of the hot gas sweeps up the slow RSG wind in the W-R shell. The expansion velocity of the W-R shell is high, almost $400~\mathrm{km~s^{-1}}$. Therefore, a strong shock ahead of the W-R shell heats the RSG wind material and the W-R shell is thick (of the order 1 pc) and hot (${\approx}10^6~\mathrm{K}$). Figure \ref{ion_uchii_apj229.962.006.1.med.mono.eps} pinpoints the moment when the W-R shell and the RSG shell collide so that only one shell of swept-up RSG wind is visible within the MS bubble \citep[see][]{garcia96b}. (The shell distortion at the $z$-axis is a result of the dense clump that has been there before.) Stellar Lyman continuum photons ionize the RSG wind gas (before it is shock heated by the W-R shell) and reionize the former H {\sc{ii}} region, which can be seen by comparison of the lower panels of Figures \ref{ion_uchii_apj229.960.017.1.med.mono.eps} and \ref{ion_uchii_apj229.962.006.1.med.mono.eps}. As long as the W-R shell moves through the RSG wind material, the thermal pressure of the shocked W-R wind inside the W-R shell is counterbalanced by the ram pressure of the RSG material it sweeps up. When the shock passes over the boundary between the RSG and MS winds and moves into the lower density medium, it speeds up as a rarefaction wave travels back into the W-R shell. It is the overpressure of the shocked rarefied W-R gas which is accelerating the much denser W-R shell. This is the classical case of a Rayleigh-Taylor unstable configuration and the W-R shell is torn into long filaments as the shocked W-R wind breaks through it. This can be seen very impressively in Figure \ref{ion_uchii_apj229.963.004.1.med.mono.eps} at $t = 4.80~\mathrm{Myr}$. Figure \ref{ion_uchii_apj229.967.008.1.med.mono.eps} shows the final, pre-supernova state of the circumstellar gas after 4.945 Myr of evolution. The wind flows freely out to $9-10~\mathrm{pc}$. This value is somewhat uncertain, however, due to the very complex flow pattern. The freely flowing wind is surrounded by the hot bubble that extends out to $31-37$ pc (on average 34 pc). The gas density in the hot bubble is $(1-30) \times 10^{-27}~\mathrm{g~cm^{-3}}$. This is fairly high (compared to the density at the end of the MS phase of the star) because some of the RSG/W-R ejecta mixes with the hot bubble gas, enhancing the density significantly and lowering the temperature. The thickness of the shell-like H {\sc{ii}} region has shrunk to $3-8$ pc with an average of 5.5 pc, after the RSG ejecta hit it and the pressure in the hot bubble has risen. This also enhances the density in the H {\sc{ii}} region to $(2-20) \times 10^{-24}~\mathrm{g~cm^{-3}}$. The higher spread is a result of the higher W-R Lyman continuum flux (compared to the MS phase), leading to increased photoevaporation of the swept-up ambient material. Finally, the shell of swept-up ambient gas is $3-4$ pc thick and the gas density in the shell is $(1-2) \times 10^{-22}~\mathrm{g~cm^{-3}}$. The expansion velocity of this shell is $3-4~\mathrm{km~s^{-1}}$ and therefore still supersonic with respect to the cold ambient ISM. The outermost shock moving into the ISM heats the swept-up ISM gas to almost $10^3~\mathrm{K}$. Thus, the whole structure extends out to a distance of $43-44$ pc from the star at this evolutionary time. \subsection{The Energy Balance in the Circumstellar Gas} \label{subsec_e_balance} \subsubsection{Numerical Results} We discuss the energization of the circumstellar gas around the 35 $M_{\sun}$ star on the basis of Figure \ref{e_distri229apj_up.eps} and compare it with its counterpart for the 60 $M_{\sun}$ case (Figure 17 in \citeauthor{freyer03}). The plot shows selected energy contributions in the circumstellar gas as a function of time, namely the kinetic energy of bulk motion in the whole computational domain, the ionization energy (13.6 eV per ionized hydrogen atom), the thermal energy of cold ($T \le 10^3~\mathrm{K}$), warm ($10^3~\mathrm{K} < T < 10^5~\mathrm{K}$), and hot ($T \ge 10^5~\mathrm{K}$) gas, respectively. The ionization energy dominates after several thousand years, when the ionization front reaches the Str\"omgren radius. Here, it attains a value of approximately $3.1 \times 10^{49}~\mathrm{ergs}$, which is about half an order of magnitude less than for the 60 $M_{\sun}$ case due to the lower Lyman continuum luminosity of the 35 $M_{\sun}$ star. The subsequent dip in ionization energy is much less pronounced than for the 60 $M_{\sun}$ case, since at that time there is less structure formation in the H {\sc{ii}} region, as is evident in Figures \ref{ion_uchii_apj230.030.001.3.med.mono.eps} through \ref{ion_uchii_apj230.048.002.3.med.mono.eps}. Afterward, the ionization energy rises smoothly to $1.8 \times 10^{50}~\mathrm{ergs}$ before the star enters the RSG stage. During the RSG stage the ionization energy drops by an order of magnitude since the H-ionizing radiation from the star is completely switched off and the photoionized gas recombines. The gas is reionized when the star evolves to the W-R phase; the ionization energy reaches a global maximum of $2.8 \times 10^{50}~\mathrm{ergs}$. Contrary to the 60 $M_{\sun}$ case, the ionization energy remains the dominant form of energy in the system for the entire evolution except for a brief period at the end of the RSG phase. A feature which we already described for the 60 $M_{\sun}$ case can also be seen in the 35 $M_{\sun}$ case: The evolution of the thermal energy of warm gas follows that of the ionization energy over the lifetime of the star with a shift of $0.7-0.9$ dex due to the fact that for both cases, photoionization is responsible for the bulk production of ionized gas at typically 8000 K. The shift is smaller during the RSG phase of the star because cooling is less efficient in the formerly photoionized regimes when the hydrogen recombines and the plasma becomes neutral. The evolution of the kinetic energy of bulk motion and the thermal energy of hot gas are also very similar; they do not deviate from each other by more than 0.2 dex until the star enters the RSG phase. Whereas the kinetic energy remains basically constant during the RSG phase, the thermal energy of hot gas decreases as the supply of hot gas by the reverse shock dies off. The cooling of the hot gas and mixing with cooler gas continues. Both values rise when the non-radiative reverse shock reestablishes itself in the W-R phase. When the calculations are stopped, the kinetic energy is $4.9 \times 10^{49}~\mathrm{ergs}$ and the thermal energy of hot gas $1.1 \times 10^{50}~\mathrm{ergs}$; the latter value is almost the same as at the end of the 60 $M_{\sun}$ calculation at 4.065 Myr. The thermal energy of cold quiescent gas in the entire computational domain at the beginning of the calculation is $1.6 \times 10^{49}~\mathrm{ergs}$ (the same energy density as in the 60 $M_{\sun}$ case, but with a smaller computational volume). This value grows smoothly during the lifetime of the star as more and more ambient gas becomes swept up and weakly shocked by the outer shell. The thermal energy of the cold gas at the end of the calculation is $3.5 \times 10^{49}~\mathrm{ergs}$; i.e., $1.9 \times 10^{49}~\mathrm{ergs}$ have been added during the evolution. To study the impact of the stellar wind on the energy transfer in the circumstellar gas, we compare the energy in the system as a function of time for the two cases: 1) the standard case with wind and 2) the H {\sc{ii}} region evolution without wind (Figure \ref{E_with_without_wind35apj_up.eps}, see also Figure 18 in \citeauthor{freyer03}). The kinetic energy of bulk motion is enhanced due to the added kinetic energy of the stellar wind shell. On the other hand, the compression of the H {\sc{ii}} region into a shell with higher density reduces the amount of ionization energy stored in the system compared to the windless case. Thus, the ratio of ionization energy for the calculation with wind to that of the windless model is below 1 throughout the lifetime of the star. Both features are well recognized from the 60 $M_{\sun}$ case. In general, the deviations of the energies between the models with and without stellar wind are smaller in the 35 $M_{\sun}$ case, especially during the MS evolution. For most of the MS time the ratios are well within the interval $0.5-2.0$. This difference to the 60 $M_{\sun}$ case exists because the ratio of mechanical luminosity to Lyman continuum luminosity of the 35 $M_{\sun}$ star is smaller than that of the 60 $M_{\sun}$ star. There is a drop in the ratio of the ionization energies with and without wind during the RSG phase of the star. At first glance, this is surprising since in the calculation with stellar wind there is additional ionization energy in the hot bubble. But the density in the hot bubble is very low and although the thermal energy of the hot gas in the bubble is important, there is not much ionization energy involved. The reason for the drop in the ratio of the ionization energies with and without wind is the fact that in the calculation with wind the H {\sc{ii}} region is compressed into a shell surrounding the hot bubble and the density in this shell is higher than in the spherical H {\sc{ii}} region of the windless simulation. The higher density results in shorter recombination times and thus a faster loss of ionization energy when the Lyman continuum radiation of the star ceases at the beginning of the RSG phase. Due to the acceleration of the slow RSG wind by the shocked W-R wind, there is a strong peak in the ratio of the kinetic energies with and without wind. This additional kinetic energy is partially dissipated when the accelerated RSG wind material hits the H {\sc{ii}} region. At the end of the simulation the kinetic energy in the calculation with stellar wind is enhanced by 85\%, whereas the ionization energy is reduced by 34\%, and the thermal energy that is added to the system during the evolution is increased by 88\% compared to the calculation without stellar wind. One of the goals of this work is to determine the efficiencies with which the stellar input energy is converted into the different forms of energy in the circumstellar medium. We show these values for the 35 $M_{\sun}$ case in Figure \ref{Ecompare229apj_up.eps} (compare Figure 21 in \citeauthor{freyer03}). We recall here that we define the transfer efficiency as the cumulative fraction of the stellar input energy that has been converted into a particular form of energy in the circumstellar medium up to the time $t=\tau$, where $\tau$ is the age of the star. Figure \ref{Ecompare229apj_up.eps} shows the transfer efficiencies into kinetic, ionization, and thermal energy and their sum for the 35 $M_{\sun}$ case. As we have already seen in Figure \ref{e_distri229apj_up.eps}, the energization of the circumstellar gas occurs fairly smoothly until the star reaches the RSG stage. The transfer efficiency into kinetic energy reaches $5.6 \times 10^{-4}$ before and during the RSG phase and peaks up to $2.2 \times 10^{-3}$ when the shocked W-R wind accelerates the RSG wind. At the end of the simulation it is $10^{-3}$. The transfer efficiency into thermal energy is higher than that into kinetic energy by a factor of 2 to 3 during most of the MS time. It reaches $1.4 \times 10^{-3}$ before the RSG phase, drops by almost a factor of 2 during the RSG phase, rises again when the star enters the W-R stage, and ends up at $3.6 \times 10^{-3}$ at the end of the simulation. The transfer efficiency into ionization energy is the highest except during the RSG stage of the star. Before the RSG phase it is $4.4 \times 10^{-3}$ and at the end of the simulation it is $5.5 \times 10^{-3}$. The total energy transfer efficiency (into kinetic, thermal, and ionization energy) at the end of the simulation is $10^{-2}$; i.e., 1\% of the total input energy from the star is transferred to the circumstellar gas. This is comparable to the net efficiency of the windless simulation. This result shows that, globally speaking, the role of the stellar wind is less important than for the 60 $M_{\sun}$ case where its presence doubled the total energy transfer efficiency at the end of the calculation. However, the total energy transfer efficiency at the end of the 35 $M_{\sun}$ calculation is 2.7 times as high as for the 60 $M_{\sun}$ case. Since the circumstellar energy in the 35 $M_{\sun}$ case is dominated by ionization energy, a substantial fraction will be lost quickly when the star ultimately turns off. On the other hand, the SN will inject a huge amount of additional energy into the circumstellar gas. Both processes are beyond the scope of this paper. We summarize the values of the individual energy components ($E_k$, $E_i$, $E_{t,\mathrm{cold}}$, $E_{t,\mathrm{warm}}$, and $E_{t,\mathrm{hot}}$) at the end of the 35 $M_{\sun}$ simulations with and without stellar wind in Table \ref{table_num_results}. The values of the energy transfer efficiency into kinetic energy ($\varepsilon_k$), ionization energy ($\varepsilon_i$), thermal energy ($\varepsilon_t$), and their sum ($\varepsilon_{\mathrm{tot}}$) at the end of the 35 $M_{\sun}$ simulations with and without stellar wind are given in Table \ref{table_num_eff}. For comparison purposes the corresponding 60 $M_{\sun}$ results from \citeauthor{freyer03} are also given there. During the lifetime of the 35 $M_{\sun}$ star, the total energy emitted in the Lyman continuum is $E_{\mathrm{LyC}} = 4.61 \times 10^{52}~\mathrm{ergs}$ and the mechanical energy of the stellar wind amounts to $E_w = 4.77 \times 10^{50}~\mathrm{ergs}$. \subsubsection{Comparison with Analytical Results} Taking mean values for the relevant stellar parameters over the lifetime of the 35 $M_{\sun}$ star, we can calculate the kinetic, ionization, and thermal energy in the system according to the analytical solutions given in {\S} 2 of \citeauthor{freyer03}. With $\langle T_{\mathrm{eff}} \rangle = 3.78 \times 10^4~\mathrm{K}$, $\langle L_{\mathrm{LyC}} \rangle = 2.95 \times 10^{38}~\mathrm{ergs~s^{-1}}$, and using $\alpha_B = 3.37 \times 10^{-13}~\mathrm{cm^3~s^{-1}}$ as hydrogen recombination coefficient and $c_{s,\mathrm{\scriptscriptstyle{II}}} = 1.15 \times 10^6~\mathrm{cm~s^{-1}}$ for the isothermal sound speed in the H {\sc{ii}} region (corresponding to $T_{\mathrm{\scriptscriptstyle{II}}} = 8000~\mathrm{K}$), we obtain for $n_0 = 20~\mathrm{cm^{-3}}$ after $\tau = 4.945~\mathrm{Myr}$ from equations (3), (4), and (5) in \citeauthor{freyer03} for the 35 $M_{\sun}$ case without wind: \begin{eqnarray} E_k &=& 2.7 \times 10^{49}~\mathrm{ergs}\ , \nonumber \\ E_i &=& 2.9 \times 10^{50}~\mathrm{ergs}\ , \nonumber \\ E_t &=& 4.5 \times 10^{49}~\mathrm{ergs}\ . \nonumber \end{eqnarray} With the same definition of the energy transfer efficiency according to equation (11) in \citeauthor{freyer03} we get the corresponding energy transfer efficiencies in the analytical approach: \begin{eqnarray} \varepsilon_k &=& 5.8 \times 10^{-4}\ , \nonumber \\ \varepsilon_i &=& 6.4 \times 10^{-3}\ , \nonumber \\ \varepsilon_t &=& 9.7 \times 10^{-4}\ . \nonumber \end{eqnarray} The analytical value for the transfer efficiency into kinetic energy deviates from the numerical result by less than 2\%. Bearing in mind all the approximations which were made in order to obtain the analytical solution, it is clear that the almost perfect correspondence between analytical and numerical result is certainly by chance. This is supported by the fact that the numerical value for $\varepsilon_k$ is almost constant during most of the MS and RSG lifetime, but jumps up by $\approx$40\% during the final W-R stage. Analytical and numerical results for the transfer efficiency into thermal energy show fairly good correspondence immediately before the RSG phase (not shown here), but since the final W-R stage boosts the thermal energy and thus also the transfer efficiency into thermal energy, the final value deviates from the analytical one by approximately a factor of 2. The comparison of analytical and numerical results for the transfer efficiency into ionization energy bears similar results. The values are fairly close to each other before the star turns to the RSG stage, and the deviation at the end of the simulation is also only $\approx$30\%. As we have already discussed in \citeauthor{freyer03}, the comparison of analytical with numerical results is much more difficult in the case of the combined SWB/H {\sc{ii}} region calculation because no analytical solution is yet known for energy transfer efficiencies in the case of H {\sc{ii}} regions with stellar winds. Again, we construct an analytical approximation by simply adding up the energy contributions from the H {\sc{ii}} region and the SWB, bearing in mind that this is only a rough estimation which actually neglects the mutual interactions. In any case the analytical energy transfer efficiencies into kinetic and thermal energy are upper limits, since cooling in the hot bubble is not considered in the analytical approach. Equations (9) and (10) from \citeauthor{freyer03} yield the kinetic and thermal energy for the SWB only. Inserting the mean value of the mechanical wind luminosity, $\langle L_w \rangle = 3.05 \times 10^{36}~\mathrm{ergs~s^{-1}}$, and adding up the results for the pure H {\sc{ii}} region, we obtain \begin{eqnarray} E_k &=& 1.6 \times 10^{50}~\mathrm{ergs}\ , \nonumber \\ E_i &=& 2.9 \times 10^{50}~\mathrm{ergs}\ , \nonumber \\ E_t &=& 2.6 \times 10^{50}~\mathrm{ergs}\ . \nonumber \end{eqnarray} Related to the sum of Lyman continuum radiation energy and mechanical wind energy (which is almost negligible for the 35 $M_{\sun}$ star), we get the corresponding energy transfer efficiencies according to equation (12) in \citeauthor{freyer03}: \begin{eqnarray} \varepsilon_k &=& 3.4 \times 10^{-3}\ , \nonumber \\ \varepsilon_i &=& 6.3 \times 10^{-3}\ , \nonumber \\ \varepsilon_t &=& 5.6 \times 10^{-3}\ . \nonumber \end{eqnarray} Comparing these values with the results of the analytical solution for the windless case and the simulations with and without wind, one can see that the increase of the kinetic energy deposit from the windless to the combined SWB/H {\sc{ii}} region simulation (almost doubled) as well as the increase of the thermal energy deposit (also almost doubled) is about a factor of 3 below the analytical upper limits. \subsection{Comparison with Observations} \label{subsec_comp_obs} In section \ref{sec_observations} we point out the importance of X-ray observations of the hot gas in SWBs to study the physics of SWBs. Thus, we have examined the X-ray properties of our numerical model. In Figure \ref{L_X_plot229_0.1-2.4kev_S308apj_up.eps} we plot the total X-ray luminosity of our model bubble in the energy band $0.1-2.4$ keV as a function of time. The emissivity $j_{\nu} (\rho,T,Z)$ in each grid cell is calculated with the \citet{raymond77} program. For temperatures below $10^5~\mathrm{K}$ the emissivity is set to zero. The total X-ray luminosity at time $t$ is calculated as \begin{equation} L_X(t) = \sum_{\mathrm{cells}} \int\limits_{h\nu=0.1~\mathrm{keV}}^{h\nu=2.4~\mathrm{keV}} 4 \pi j_{\nu}(\rho_\mathrm{cell}(t),T_\mathrm{cell}(t),Z) V_\mathrm{cell}~d\nu\ , \end{equation} where $\rho_\mathrm{cell}(t)$ and $T_\mathrm{cell}(t)$ are the plasma density and temperature in the grid cell, respectively, $V_\mathrm{cell}$ is the volume of the grid cell, and $h\nu$ the energy of the X-ray photons. For the summation over grid cells the finest grid that is available for the respective coordinates is always used. As for the calculation of all the other global quantities, the grid data are mirrored at the equator. We assume optically thin emission; absorption is neglected. For the set of chemical abundances, $Z$, we use the same values which \citet{chu03} used for their spectral X-ray fits of S308 and which are based on the abundance determination of \citet{esteban92b} for the optically visible shell. We assume that the elements not mentioned by \citet{chu03} have the same abundance relative to the solar value as oxygen (0.13). Thus, for the computation of the X-ray emissivity the following elements are considered: H, He, C, N, O, Ne, Mg, Si, S, Ar, Ca, Fe, Ni with the following abundances relative to the solar values \citep{anders89}: 1.0, 2.1, 0.1, 1.6, 0.13, 0.22, 0.13, 0.13, 0.13, 0.13, 0.13, 0.13, 0.13. This set of elemental abundances is intended to represent the chemistry in the RSG wind. The composition of the hot gas in the MS bubble may be different because the radiating material is supposed to originate from the MS wind of the star and (if thermal evaporation or ablation is important) also from the ambient medium. However, for the sake of simplicity we use the same chemical composition for all the emitting gas during the whole evolution. We will briefly discuss impacts of this choice below. The chemical composition employed for this diagnostic purpose is thus inconsistent with the solar chemical composition that is used to calculate the cooling of the gas (energy sink term in the radiation-hydrodynamical equations). Figure \ref{L_X_plot229_0.1-2.4kev_S308apj_up.eps} shows that the X-ray luminosity assumes the value $10^{32}~\mathrm{ergs~s^{-1}}$ soon after the turn on of the stellar wind. It remains remarkably constant during the MS phase and the associated growth of the SWB. The deviation from $10^{32}~\mathrm{ergs~s^{-1}}$ is less than a factor of 2.5 during this period. Most of the X-ray emission originates at the interface between the hot gas in the SWB and the swept-up H {\sc{ii}} shell. Although He and N are overabundant, the strong underabundance of the other metals reduces the X-ray luminosity. Using a solar chemical composition instead of the abundances described above would increase the luminosity in Figure \ref{L_X_plot229_0.1-2.4kev_S308apj_up.eps} by a factor $3-4$. With the onset of the RSG phase the total X-ray luminosity decreases by a factor of $3-4$ until the star reaches the W-R stage. This happens because the hot gas (or more precisely the gas in the interface region close to the shell of swept-up ambient gas) cools and the supply of the bubble with hot gas ceases during the RSG phase. The subsequent onset of the fast W-R wind drives up the total X-ray luminosity by approximately 3 orders of magnitude. It reaches a few times $10^{34}~\mathrm{ergs~s^{-1}}$, but varies quite strongly. It is interesting to note that in this phase almost all of the X-ray emission comes from the W-R shell (instead of the shocked W-R wind). At $t = 4.775~\mathrm{Myr}$ the radius of this X-ray emitting shell is approximately 10 pc with a thickness of $1.0-1.3$ pc. The temperature drops from $2.5 \times 10^6~\mathrm{K}$ behind the shock to $6 \times 10^5~\mathrm{K}$ at the inside of the shell, the density rises from $2 \times 10^{-25}~\mathrm{g~cm^{-3}}$ to $1.2 \times 10^{-24}~\mathrm{g~cm^{-3}}$ and the velocity from 300 to 500 $\mathrm{km~s^{-1}}$. The shocked W-R wind has (from the reverse shock to the contact discontinuity) a density of $5 \times 10^{-27}~\mathrm{g~cm^{-3}}$ to $1.4 \times 10^{-26}~\mathrm{g~cm^{-3}}$, a temperature of $1.0 \times 10^8~\mathrm{K}$ to $5 \times 10^7~\mathrm{K}$ and a velocity of 1000 $\mathrm{km~s^{-1}}$ to 500 $\mathrm{km~s^{-1}}$. The $\mathrm{H\alpha}$ emission comes mostly from the RSG shell. The density in this shell is $(3-12) \times 10^{-25}~\mathrm{g~cm^{-3}}$, which may be seen as a lower limit since this shell is not completely resolved in our calculations. The temperature in the shell is $(8-20) \times 10^3~\mathrm{K}$, indicating that there is shock heating present in addition to photoionization. The shell's velocity has slowed to $25~\mathrm{km~s^{-1}}$ due to its interaction with the MS wind material. Judging by the geometrical extent, the evolutionary state of the W-R bubble at this time is approximately comparable to the currently observable stage of S308. The model data show surprisingly good agreement with the X-ray observations of S308 described above. The total X-ray luminosity of a few times $10^{34}~\mathrm{ergs~s^{-1}}$ is slightly higher but of the same order of magnitude as the $\le 1.2 \pm 0.5 \times 10^{34}~\mathrm{ergs~s^{-1}}$ observed by \citet{chu03}. Since almost all of the X-ray emission in our model comes from the W-R shell, the temperature range of $(0.6-2.5) \times 10^6~\mathrm{K}$ agrees quite well with the $1.1 \times 10^6~\mathrm{K}$ that results from the spectral fit of the observed X-rays. Although the observational proof for the existence of a substantially hotter gas component is still under debate, in our model it could well be identified with the shocked, hot W-R wind which contributes only a small fraction to the total soft X-ray emission. The average density in the X-ray emitting W-R shell is $n_e \approx 0.4~\mathrm{cm^{-3}}$, which is well within the observationally determined range of $n_e = 0.28-0.63~\mathrm{cm^{-3}}$ for the assumed range $0.5-0.1$ of the hot gas volume filling factor \citep{chu03}. The total mass of the W-R shell is approximately 15 $M_{\sun}$; i.e., most of the 18.6 $M_{\sun}$ RSG wind has already been swept up. This is at the upper end of the observationally supported range of $11 \pm 5~M_{\sun}$ for an assumed volume filling factor of 0.5. The fact that the W-R shell supplies most of the X-ray emission alleviates the necessity to assume that thermal evaporation of RSG wind gas raises the mass of the X-ray emitting shocked W-R wind. The process of thermal evaporation, which is not implemented in our numerical model, would not be very efficient anyway, since the temperature gradient between the ${\approx}10^6~\mathrm{K}$ W-R shell and the shocked W-R wind at several times $10^7~\mathrm{K}$ is rather modest. The conclusion of \citet{wrigge99} that S308 cannot be described by the two-wind model seems to be vulnerable because he assumed that the X-ray emission originates from the shocked W-R wind and that the energy in the forward shock ahead of the W-R shell is completely dissipated in a different wavelength range. Consequently, using the formula for the X-ray luminosity of the shocked W-R wind under the impact of conductive evaporation from \citet{garcia95a} in order to reproduce the observed X-ray luminosity, he derived values for the mechanical wind luminosity which are much too low compared to the actually observed values of the central W-R star. By contrast, the mechanical wind luminosity in our model calculation during the first $2 \times 10^4~\mathrm{yr}$ of the W-R stage is in the range $(3-10) \times 10^{37}~\mathrm{ergs~s^{-1}}$, which is in reasonable agreement with the observed stellar wind luminosity (scaled to the distance of $D = 1.5~\mathrm{kpc}$ used here) of $4.9 \times 10^{37}~\mathrm{ergs~s^{-1}}$ \citep{hamann93} or $1.3 \times 10^{37}~\mathrm{ergs~s^{-1}}$ for a clumping-corrected mass-loss rate \citep{nugis98}. Because the X-ray emitting volume is a thick shell ($1.0-1.3$ pc), another observational constraint that is well reproduced in our model is the limb brightening of the X-ray emission. In Figure \ref{IX3_ng_100_2400ev_S308_plot_apj_up.eps} we display the unabsorbed angle-averaged X-ray intensity profile in the energy range $0.1-2.4$ keV at three evolutionary times during the early W-R stage, namely $t = 4.765~\mathrm{Myr}, 4.770~\mathrm{Myr}$, and $4.775~\mathrm{Myr}$, the latter corresponding to the phase discussed above. We see that the ``background'' intensity produced by the hot gas in the MS bubble is of order $10^{-10}~\mathrm{ergs~s^{-1}~cm^{-2}~sr^{-1}}$. The intensity for lines of sight through the W-R shell is higher by $3-5$ orders of magnitude. The limb brightening within the W-R shell can be seen for all three profiles as well as the decrease of the peak intensity with time. The consideration of absorption would not alter this result because the limb brightening is due to the geometry of the emitting plasma rather than due to varying absorption. Since the shocked W-R wind in our model calculation has not yet swept up the entire RSG wind, the X-ray emitting shell is interior to the optical shell as has been found in the observations. Differing from \citet{chu03}, we interpret the gap between the outer rim of the optical emission and the outer edge of the X-ray emission as being the RSG ejecta in front of the W-R shell rather than being the W-R shell itself. The thickness of the gap in our model at this time is approximately 0.5 pc, which is smaller than the observed gap ($0.7-1.5$ pc). However, this strongly depends on the exact instant of time and on the exact duration of the RSG phase as well as the velocity of the RSG wind. If our interpretation of the dynamical evolution is true, the age that has been attributed to the W-R bubble is probably significantly overestimated because of the assumption that the observed velocity $63~\mathrm{km~s^{-1}}$ is the velocity of the W-R shell rather than the velocity of the RSG shell. Based on our model the age of the bubble is ${\approx}2 \times 10^4~\mathrm{yr}$ for the stage described above, much less than the $1.4 \times 10^5~\mathrm{yr}$ derived from the observed velocity of $63~\mathrm{km~s^{-1}}$. As the referee pointed out, there is no observational evidence yet of a high-velocity (${\approx}400~\mathrm{km~s^{-1}}$) gas component that we identify as the W-R shell in our numerical results. The kinematic data obtained from the [O {\sc{iii}}] $\lambda 5007$ emission line observations of S308 and from the N {\sc{v}} $\lambda\lambda 1239,~1243$ and C {\sc{iv}} $\lambda\lambda 1548,~1551$ absorption line studies toward HD 50896 \citep{boroson97} do not show velocities as high as several $100~\mathrm{km~s^{-1}}$. However, if the gas in the W-R shell of our model calculation at $T \approx 10^6~\mathrm{K}$ has reached collisional ionization equilibrium, oxygen exists mostly as O {\sc{vii}}, nitrogen as N {\sc{vi}} or N {\sc{vii}}, and carbon as C {\sc{v}}, C {\sc{vi}}, or even completely ionized. Thus, there is almost no O {\sc{iii}}, N {\sc{v}}, or C {\sc{iv}} in the W-R shell whose emission or, respectively, absorption could be observed. Other ionic tracers are needed to find high-velocity gas of that temperature. The appearance of NGC 6888 is harder to explain within the framework of our model. The observed geometrical size implies that the nebula is younger than S308, provided that the temporal evolution of the stellar parameters during the RSG and W-R stage is about the same. A maximum value of $\approx$8000 yr can be derived under the assumptions that the optically visible nebula has not yet been swept up by the expanding W-R bubble and that our stellar model parameters are appropriate for NGC 6888. The observed X-ray luminosity $1.6 \times 10^{34}~\mathrm{ergs~s^{-1}}$ as well as the emitting plasma temperature $2 \times 10^6~\mathrm{K}$ \citep{wrigge94} are in reasonable agreement with the model data, but the X-ray emission in the model originates from a thick shell which is more or less homogeneous rather than from small filaments with a volume filling factor of only a few \%. Although the hot W-R shell is able to ``hide'' mass from optical observations and thus helps to find the yet undetected portion of RSG wind mass, 8000 yr after the onset of the W-R wind it contains only $\approx$3 $M_{\sun}$, which is not enough to solve the problem completely (assuming that the RSG mass loss used in the model is appropriate for NGC 6888). The biggest difficulty is probably the appearance of the optical shell. In the numerical model the RSG shell already has a radius greater than 10 pc and the unaffected RSG wind between the W-R shell and the RSG shell contributes significantly to the $\mathrm{H\alpha}$ emission. This conflicts with the observation of a very thin, filamentary shell with hydrogen number densities as high as $1000~\mathrm{cm^{-3}}$. There may be various reasons for this mismatch between our model and the observations of NGC 6888. It is possible that physical effects not yet covered in our model are more important for NGC 6888 or that the resolution applied in our calculations is not yet high enough to allow for the formation of high-density filaments. Another possibility is that the actual mass-loss history of HD 192163 differs from what is expected and used in our calculations. Apart from the detailed comparison, Figure \ref{L_X_plot229_0.1-2.4kev_S308apj_up.eps} illustrates another aspect: The fact that up to now only W-R bubbles have been observed in X-rays is not only by chance. At least for the MS $\rightarrow$ RSG $\rightarrow$ W-R sequence the X-ray luminosity during the final W-R stage exceeds that of the rest of the stellar lifetime by more than an order of magnitude. Moreover, during the early W-R phase the emission comes from a relatively small volume (compared to most of the MS lifetime), resulting in an even higher X-ray surface brightness, which is easier to detect. \section{Summary and Conclusions} \label{sec_conclusions} The basic difference between the simulations presented in this paper and those of \citeauthor{freyer03} is the choice of the stellar parameters, which here are chosen to model a 35 $M_{\sun}$ star that undergoes the evolution from the MS through the RSG and W-R stages. The fundamental structures which evolve are basically the same as observed in the 60 $M_{\sun}$ case. They are generally smaller because for most of the time the stellar wind luminosity and the Lyman continuum luminosity are lower than in the 60 $M_{\sun}$ case. At the end of the simulation the entire bubble structure has a radius of $\approx$44 pc, which is some 6 pc smaller than the final bubble of the 60 $M_{\sun}$ case, although the 35 $M_{\sun}$ star lives 0.88 Myr longer than the 60 $M_{\sun}$ star. Instability-driven structure formation during the early MS phase of the star (the formation of ionized fingers corrugating the ionization front and the formation of neutral spokes shadowed by dense clumps), which we found to be quite prominent in the case of the 60 $M_{\sun}$ calculation, is also visible in the calculations presented here, but it is much less pronounced and only short-lived, because of the lower mechanical wind luminosity of the star. The lower mechanical wind luminosity of the star reduces the thermal pressure of the hot gas in the bubble. The lower pressure in the hot bubble increases the geometrical thickness of the shell of swept-up H {\sc{ii}} gas, making it less sensitive to thin-shell instabilities that could trigger the formation of the morphological structures described above. Since this behavior better preserves the basic spherical structure, other morphological effects become visible, which might be prohibited in the 60 $M_{\sun}$ case by the strong corrugation of the bubble shell: When the swept-up H {\sc{ii}} shell broadens geometrically, the plasma density in the shell decreases. This rarefaction reduces the rate of Lyman continuum photons necessary to sustain the photoionization of the shell and excess photons become available, which drive the ionization front outward and photoevaporate additional material from the neutral shell of swept-up ambient medium. The inward flow of evaporated material collides with the outward flow of the dissolving swept-up H {\sc{ii}} shell, temporarily forming a new shell of enhanced density. Since all the plasma within the H {\sc{ii}} region is almost isothermal, this density fluctuation vanishes soon. Another consequence of the reduced stellar wind luminosity (compared to the 60 $M_{\sun}$ case) is the fact that for most of the time the shape of the H {\sc{ii}} region is more or less preserved as a broad shell interior to the thin shell of swept-up ambient material rather than being so thin as in the 60 $M_{\sun}$ case where the H {\sc{ii}} region is compressed into the illuminated inner part of the outer shell. Nevertheless, the geometrical thickness of the photoionized shell shrinks at the end of the simulation when the stellar wind luminosity reaches its maximum during the final W-R stage. The morphological impact of the low-velocity mass-loss phase (the RSG stage) is more prominent than that of the 60 $M_{\sun}$ star (the LBV stage), because the total mass loss during the RSG stage is higher ($\approx$18.6~$M_{\sun}$) than during the LBV stage of the 60 $M_{\sun}$ star ($\approx$7.3~$M_{\sun}$). The slowly expanding RSG wind material is subsequently swept up and accelerated by the shocked W-R wind so that Rayleigh-Taylor instabilities break it into filaments. The final, pre-supernova structure that shows up in the 35 $M_{\sun}$ case after 4.945 Myr is basically comparable to that of the 60 $M_{\sun}$ case at its end. The entire bubble is slightly smaller, the H {\sc{ii}} shell at the inside of the outer neutral swept-up shell is more extended than in the 60 $M_{\sun}$ case. Outer shell and H {\sc{ii}} region are less clumpy and show less rippling as a consequence of the different evolutionary scenarios. The reduced substructure formation during the early MS phase is also reflected in the circumstellar energetics. The decrease of ionization energy and thermal energy of warm gas (compared to the respective case without stellar wind) resulting from the formation of dense photoionized structures with short recombination times is smaller than for the 60 $M_{\sun}$ case. Ionization energy dominates the energy in the circumstellar gas for most of the evolution. The kinetic energy of bulk motion as well as the warm and the hot component of thermal energy stay fairly close together from $t \approx 0.3~\mathrm{Myr}$ until the star enters the RSG phase. The energetic variations during the RSG stage are stronger than those during the LBV stage of the 60 $M_{\sun}$ star because, due to the duration of the RSG phase, the ionizing radiation of the star is switched off for a considerable period of time so that the photoionized regions recombine. In addition, the mass that is ejected during the RSG stage and accelerated during the subsequent W-R stage is about 2.5 times higher than the mass ejected during the LBV stage of the 60 $M_{\sun}$ star. At the end of the 35 $M_{\sun}$ simulation the total energy transfer efficiency is 1\%. This value is about the same as in the corresponding case without stellar wind, but it is 2.7 times higher than the value at the end of the 60 $M_{\sun}$ simulation. 54\% of the net energy which has been added to the system is then in the form of ionization energy, 36\% in thermal energy and 10\% in kinetic energy of bulk motion. The corresponding values at the end of the 60 $M_{\sun}$ calculation are 25\%, 40\%, and 35\%, respectively. This is another indication that the stellar wind plays a more prominent role in the 60 $M_{\sun}$ case. Remarkable agreement of the X-ray properties is found when comparing our model calculations during the early W-R phase with observations of S308. The order of magnitude of the observed X-ray luminosity as well as the temperature of the emitting plasma and the limb brightening of the intensity profile are well reproduced. The obvious explanation that our model overcomes the ``missing wind problem'' described in {\S} \ref{sec_observations} is that almost the entire X-ray emission during this phase comes from the W-R shell rather than from the shocked W-R wind. Analytical models constructed so far \citep[see e.g.][]{garcia95a} assume the W-R shell to be thin and cool so that the energy in the forward shock is completely dissipated in the low-energy wavelength range. The source of X-rays in these models is the shocked W-R wind and the efficiency of heat conduction and thermal evaporation between the hot gas and the cold W-R shell strongly influences the luminosity and the spectral shape of the X-ray emission. If heat conduction is efficient enough to cool the hot shocked W-R wind down to the observed temperature and if the W-R wind luminosity in the models is adjusted to reproduce the observed X-ray luminosity, the W-R wind luminosity is usually much lower than observed \citep{wrigge99}. Another factor that reduces the X-ray luminosity in our model to values roughly comparable with S308 is the assumed set of chemical abundances. Although He and N are overabundant according to the observations in the nebula, the underabundance of the other metals reduces the X-ray luminosity by a factor of $3-4$ compared to what can be expected from solar chemical composition. A further consequence of this interpretation of our results is that the $\mathrm{H\alpha}$ emission originates mostly from the RSG shell. This is in agreement with the finding of \citet{chu03} that the X-ray emission is completely interior to the optical shell. Since the age of S308 (and other W-R bubbles) was hitherto derived from the expansion velocity of the optical nebula under the assumption that the nebula is part of the W-R shell, our results imply an age of S308 which is much younger (${\approx}2 \times 10^4~\mathrm{yr}$) than assumed so far. However, the match of our model data and the observations is worse for the case of NGC 6888. Besides numerical or model restrictions, differences of the mass-loss and luminosity history between the central star of NGC 6888 and our model star might be responsible for the discrepancies. \acknowledgments This work was supported by the Deutsche Forschungsgemeinschaft (DFG) under grant number He~1487/17 and by the National Aeronautics and Space Administration (NASA) under grant NRA-03-OSS-01-TPF. Part of the research described in this paper was conducted at the Jet Propulsion Laboratory (JPL), California Institute of Technology. The computations were performed at the Rechenzentrum der Universit\"at Kiel, the Konrad-Zuse-Zentrum f\"ur Informationstechnik in Berlin, and the John von Neumann-Institut f\"ur Computing in J\"ulich. We thank the referee, Guillermo Garc\'{\i}a-Segura, for valuable comments and for making available new kinematic data of S308.
{ "redpajama_set_name": "RedPajamaArXiv" }
3,281
import { FileInput } from './FileInput'; import translate from '../../i18n/translate'; export class ImageInput extends FileInput { static defaultProps = { ...FileInput.defaultProps, labelMultiple: 'aor.input.image.upload_several', labelSingle: 'aor.input.image.upload_single', itemStyle: { display: 'inline-block', position: 'relative', }, removeStyle: { position: 'absolute', top: '0.5rem', right: '0.5rem', minWidth: '2rem', opacity: 0, }, }; } export default translate(ImageInput);
{ "redpajama_set_name": "RedPajamaGithub" }
7,044
\section*{Abstract} Using density functional theory calculations and the Greens's function formalism, we report the existence of magnetic edge states with a non-collinear spin texture present on different edges of the 1T' phase of the three monolayer transition metal dichalcogenides (TMDs): MoS$_2$, MoTe$_2$ and WTe$_2$. The magnetic states are gapless and accompanied by a spontaneous breaking of the time-reversal symmetry. This may have an impact on the prospects of utilizing WTe$_2$ as a quantum spin Hall insulator. It has previously been suggested that the topologically protected edge states of the 1T' TMDs could be switched off by applying a perpendicular electric field\cite{Qian2014}. We confirm with fully self-consistent DFT calculations, that the topological edge states can be switched off. The investigated magnetic edge states are seen to be robust and remains gapless when applying a field. \section{\label{sec:intro}Introduction} \input{intro} \section{\label{sec:methos}Method} \input{method} \section{Materials} \input{system} \section{\label{sec:MoS2results} The edges of 1T' MoS$_2$} \input{mos2_results} \section{\label{sec:Wresults} Magnetic edges on 1T' TMDs} \input{materials} \section{The effect of gating} \input{gating} \section{\label{sec:conclusion}Conclusion} \input{conc} \vspace*{0.1cm} \begin{acknowledgments} This work is partly funded by the Innovation Fund Denmark (IFD) under File No. 5189-00082B. The authors acknowledge Julian Schneider and Troels Markussen for technical help with the calculations and interpretation of the results. \end{acknowledgments}
{ "redpajama_set_name": "RedPajamaArXiv" }
1,880
# Table of Contents 1. Welcome to San Diego 2. Exploring San Diego 3. Top 10 San Diego Highlights 1. Gaslamp Quarter 2. Embarcadero 3. Balboa Park 4. Old Town State Historic Park 5. Coronado 6. Point Loma 7. Mission Basilica San Diego de Alcalá 8. Mission Bay Park 9. La Jolla 10. East County 4. The Top 10 of Everything 1. Moments in History 2. Historic Sites 3. Architectural Highlights 4. Museums and Art Galleries 5. Beaches 6. Gardens and Nature Reserves 7. Outdoor Activities 8. Off the Beaten Path 9. Children's Attractions 10. Performing Arts Venues 11. Nightlife 12. Cafés and Bars 13. Restaurants 14. Stores and Shopping Centers 15. San Diego for Free 16. Festivals 5. San Diego Area by Area 1. Downtown San Diego 2. Old Town, Uptown, and Mission Valley 3. Ocean Beach, Coronado, and the South 4. Northern San Diego 6. Streetsmart 1. Getting To and Around San Diego 2. Practical Information 3. Places to Stay 7. Maps 8. Acknowledgments 9. Copyright 1. Contents 2. Cover 3. How To Use this Guide ## Discover the world with DK Eyewitness Our travel writers report on what to see, eat, drink and do around the world, while the very best photographs and illustrations bring cities, regions and countries to life. We publish guides to more than 200 destinations around the world, from handy pocket-sized city guides to comprehensive country guides - all available in both print and digital formats. Discover more at https://www.dk.com/travel Double tap to zoom ## Preferred application settings For the best reading experience, the following application settings are recommended: * Colour theme: ** _White background_** * Font size: **_At the smallest point size_** * Orientation: _**Landscape** (for screen sizes over 9″), **Portrait** (for screen sizes below 9″)_ * Scrolling view: _**[OFF]**_ * Text alignment: _**Auto-justification [OFF]** (if the eBook reader has this feature)_ * Auto-hyphenation: _**[OFF]** (if the eBook reader has this feature)_ * Font style: **_Publisher default setting [ON]_** _(if the eBook reader has this feature)_ _**Clockwise from top:** Spanish Village Art Center at Balboa Park, Scripps Pier in La Jolla, La Jolla Cove, exterior of the Mormon Temple, giant panda at the San Diego Zoo, marina with a view of downtown San Diego, Balboa Park in the evening_ WELCOME TO SAN DIEGO San Diego is the riviera of North America, pure and simple, with long stretches of spectacular sandy beaches. The birthplace of the state of California is also historic, hip, active, and friendly, bestowing a warm welcome upon visitors of all ages and every persuasion. With Eyewitness Top 10 San Diego, it's yours to explore. San Diego boasts ritzy villages, retro surf towns, and movie-star good looks, with a cornucopia of gasp-worthy views, from the colorful flotilla of **San Diego Bay** , to the lush city of **La Jolla** to the north, and even parts of Mexico to the south. It is also one of the few places on earth where you can flit from ocean to mountains to desert and back to the city in the span of an afternoon. It is easy to see why San Diegans are proud of **Balboa Park** , with its showcase gardens, museums, and the famed **San Diego Zoo**. This is where locals keep fit, laze, dream, and play. And they do love to play, enjoying Comic-Con International, as well as festivals and outdoor concerts. The city has all the advantages of a big city, minus the bustle, and a mild climate year-round. A stroll along the **Embarcadero** takes you from the historic **_Star of India_** tall ship, past the modern cruise terminal, all the way to the formidable **USS _Midway_** aircraft carrier. The historic **Gaslamp Quarter** , once home to bawdy houses, dance halls, and gambling saloons, is now full of popular shops, bars, and nightclubs. A number of original buildings have become superstar hotels and restaurants. Whether you're visiting for a weekend or a week, our Top 10 guide brings together the best of everything the city has to offer. The guide has useful tips throughout, from seeking out what's free to avoiding the crowds, plus six easy-to-follow itineraries, designed to tie together a clutch of sights in a short space of time. Add inspiring photography and detailed maps, and you've got the essential pocket-sized travel companion. **Enjoy the book, and enjoy San Diego**. # Exploring San Diego A San Diego visit can hop from historic sights to sunny beaches to snowcapped mountains to exotic desert – and then back downtown in time for dinner. There is a wealth of things to see and do, and the city caters to every appetite and ability. These two- and four-day itineraries will help you plan your time and make the most of your visit to the city. * * * ## Two Days in San Diego * * * ### Day 1 Morning Awaken to a view of the bay and then take a morning stroll along the **Embarcadero**. Check out the vessels at the **Maritime Museum** , and board the behemoth **USS _Midway_**. **Embarcadero** , the waterfront area, has been the heart of San Diego since the mid-1500s. Afternoon Wander the historic **Gaslamp Quarter** on a self-guided or organized tour, then trolley to the **Old Town State Historic Park** and immerse yourself in early Californian life. Cap off the day at the **Mission Basilica San Diego de Alcalá** , before heading back to the coast to watch the sun set. ### Day 2 Morning Start off at the **San Diego Zoo** , touring by foot or tram, then explore the rest of **Balboa Park**. Browse Spanish Village artisan shops along the way. Afternoon Visit one or more of San Diego's renowned museums and galleries; many of them have cafés for lunch. Rest your feet at the Botanical Building and lily pond, where buskers perform nearby. Make advance reservations for dinner at **The Prado at Balboa Park** , and catch a show at **The Old Globe**. * * * ## Four Days in San Diego * * * ### Day 1 Morning Begin your day at **Old Town State Historic Park** , venturing out of the park to **Whaley House Museum** and **Presidio Park**. Shop for trinkets at **Bazaar del Mundo** , then lunch at **Old Town Mexican Café & Cantina**. Afternoon Trolley to the **Mission Basilica San Diego de Alcalá** , then head to the **Embarcadero**. Soak up the city's nautical heritage at the **Maritime Museum** or **USS _Midway_**. Catch the ferry to **Coronado** for sunset cocktails at the **Hotel del Coronado**. ### Day 2 Morning Lazy beaches and lots of water- and land-based sports await visitors at **Mission Bay Park**. Take a spin on the 1925 Giant Dipper roller coaster at **Belmont Park**. Afternoon Journey to the **Cabrillo National Monument**. Explore tide pools and the lighthouse, and gaze over the busy bay from the visitor center. Continue up the coast to **La Jolla** to enjoy its chic shops, classy restaurants, and illustrious beaches. See the sun set over La Jolla Cove from **Eddie V's** upstairs patio, with live jazz. ### Day 3 Morning Head northeast to **San Diego Zoo Safari Park**. Continue past **San Pasqual Battlefield** up the mountain to **Julian**. Afternoon Have lunch on Julian's Main Street, pan for gold at Eagle Mine, and shop for local crafts. Drop down to the **Anza-Borrego Desert State Park** at twilight. **Native American casinos** may tempt you on the way back to downtown San Diego. ### Day 4 Morning Tram through the **San Diego Zoo** and head for the sights of **Balboa Park**. Enjoy a picnic lunch by the fountain outside **Reuben H. Fleet Science Center**. **San Diego Zoo** offers access to the Skyfari® Aerial Tram that cuts across its length to additional Balboa Park sights. Afternoon After the park, enjoy dinner and a music club in the historic **Gaslamp Quarter** , ending the day in the lively bars. * * * Top 10 San Diego Highlights The idyllic beach at the waterfront area of Embarcadero ## Top 10 San Diego Highlights 1 | Gaslamp Quarter ---|--- 2 | Embarcadero ---|--- 3 | Balboa Park ---|--- 4 | Old Town State Historic Park ---|--- 5 | Coronado ---|--- 6 | Point Loma ---|--- 7 | Mission Basilica San Diego de Alcalá ---|--- 8 | Mission Bay Park ---|--- 9 | La Jolla ---|--- 10 | East County ---|--- Back to Top 10 San Diego Highlights # GASLAMP QUARTER Great nightclubs, trendy restaurants, and unique boutiques compete for attention in San Diego's most vibrant neighborhood. Alonzo Horton's 1867 New Town seemed doomed to the wrecking ball in the 1970s, but a civic revitalization program transformed the dilapidated area into a showcase destination. By 1980, the Gaslamp Quarter was decreed a National Historic District. The historic buildings of the Gaslamp Quarter Gaslamp Quarter Map ### NEED TO KNOW www.gaslamp.org **Ingle Building:** 801 4th St **San Diego Hardware:** 840 5th Ave **William Heath Davis House:** 410 Island Ave 619 233 4692; open 10am–5pm Tue–Sat, noon–4pm Sun; adm $10 **Louis Bank of Commerce:** 835 5th Ave **Keating Building:** 432 F St **Lincoln Hotel:** 536 5th Ave **Balboa Theatre:** 868 4th Ave **Old City Hall:** 664 5th Ave **Yuma Building:** 643 5th Ave Google Map * Stop at the Ghirardelli Chocolate Shop _(643 5th Ave)_ for a hot fudge sundae. * Parking is difficult on weekends. Take the San Diego Trolley; it stops right at Gaslamp. * Historical walking tours are held 1pm Thu (summer only), 5pm Fri & 11am Sat _($20;www.gaslampfoundation.org)_. ## 1. Ingle Building Google Map A mural marks the Golden Lion Tavern that was once located here. Note the lion sculptures, stained-glass windows, and 1906 stained-glass dome over the bar. ## 2. San Diego Hardware Google Map Once a dance hall, then a five-and-dime store, this building housed one of San Diego's oldest businesses, founded in 1892. Though the store relocated in 2006, the original storefront remains on Fifth Avenue. ## 3. William Heath Davis House Google Map Named after the man who tried but failed to develop San Diego in 1850, the museum is home to the Gaslamp Quarter Historical Foundation. It's the oldest wooden structure in the downtown area. ## 4. Louis Bank of Commerce Google Map A bank until 1893, this Victorian structure was the favorite bar of Wyatt Earp. It once contained the Golden Poppy Hotel, a notorious brothel. The Victorian facade of the Louis Bank of Commerce ## 5. Wrought-Iron Gas Lamps San Diego's historic district is named after the quaint green wrought-iron gas lamps that line the streets– they actually run on electricity. ## 6. Keating Building Google Map Fannie Keating built this Romanesque-style building in 1890 in honor of her husband George. It once housed some of the most prestigious offices in the whole town. The imposing Keating Building ## 7. Lincoln Hotel Google Map Built in 1913, the four-story tiled structure features Chinese elements, the original beveled glass in its upper stories, and its original green-and-white ceramic tile facade. Japanese prisoners were housed here before departing for internment camps during World War II. ## 8. Balboa Theatre Google Map This landmark 1,500-seat theater started out as a grand cinema with waterfalls flanking the stage. Notice the beautiful tiled dome on the roof. A restoration project converted the building into a venue for live performances. Audience at Balboa Theatre ## 9. Old City Hall Google Map Dating from 1874, this Italianate building features 16-ft (5-m) ceilings, brick arches, Classical columns, and a wrought-iron cage elevator. In 1900, the entire city government could fit inside. Today, the building houses condos, shops, and a restaurant. ## 10. Yuma Building Google Map Captain Wilcox of the US _Invincible_ owned downtown's first brick structure in 1888. The building was named for his business dealings in Yuma, Arizona. Airy residential lofts with large bay windows now occupy the upper levels of the building. ### STINGAREE DISTRICT After its legitimate businesses relocated in the late 19th century, New Town was home to brothels, opium dens, saloons, and gambling halls, some operated by famous lawman Wyatt Earp. It became known as "Stingaree" because one could be stung on its streets as easily as by the sting-aree fish in the bay. After police tried (and failed) to clean up Stingaree in 1912, it slowly disintegrated into a slum until rescued by the Gaslamp Quarter Foundation some 50 years later. Back to Gaslamp Quarter Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # EMBARCADERO Ever since Juan Cabrillo sailed into San Diego Bay in 1542, much of the city's life has revolved around its waterfront. Pioneers stepped ashore on its banks; immigrants worked as whalers and fishermen; the US Navy left an indelible mark with its shipyards and warships. Tourism has added another layer to the harbor's lively atmosphere. The Embarcadero welcomes visitors with its art displays, walkways, nautical museums, harbor cruises, and benches on which to sit and enjoy the uninterrupted harbor activity. Embarcadero Map ### NEED TO KNOW **USS Midway Museum:** 910 N. Harbor Dr; 619 544 9600; open 10am–5pm; adm adult $20, child $10 **Santa Fe Depot:** 1050 Kettner Blvd Google Map * Flagship Cruises offers 1- and 2-hour narrated tours. There are several departures daily. * For a quick bite, try Island Deli at 955 Harbor Island Drive. Their fresh sandwiches are good outdoor options. * Pedicabs are usually available to take you down to Seaport Village. ## 1. San Diego Harbor Google Map One of the greatest attractions of the Embarcadero is this bustling harbor, where you can watch as Navy destroyers, aircraft carriers, ferries, cruise ships, and sailboats glide past. Be a part of the action by taking a harbor cruise. The bustling harbor at Embarcadero ## 2. Seaport Village Google Map New England and Spanish design blend eclectically in this waterfront area _(seeSeaport Village)_ with brilliant harbor views. The waterfront Seaport Village ## 3. San Diego County Administration Center Google Map Dedicated by President F. Roosevelt, this 1936 civic structure looks especially magisterial at night. Enter through the west door and feel free to wander about. ## 4. Tuna Harbor Google Map San Diego was once home to the world's largest tuna fleet, with 200 commercial boats. Portuguese immigrants dominated the trade until the canneries moved to Mexico and Samoa. The US Tuna Foundation still keeps its offices here. ## 5. USS Midway Museum Google Map The 1,000-ft (305-m) USS _Midway_, commissioned in 1945, was once the world's largest warship. Many docents on board are veterans of the carrier. ## 6. Embarcadero Marina Park Google Map Relax on one of the grassy expanses to enjoy the excellent views of the harbor and Coronado Bridge. Joggers and bicyclists use the paths around the park, and on weekends, entertainers and artists demonstrate their work. ## 7. San Diego Convention Center Google Map The center was designed to complement the waterfront location, with its flying buttresses, skylight tubes, and rooftop sails. The San Diego Convention Center building ## 8. Piers Google Map Glistening cruise ships bound for Mexico and the Panama Canal tie up at B Street Pier. Harbor cruises and ferries to Coronado can be caught nearby. ## 9. Santa Fe Depot Google Map The train cars may be modern, but the atmosphere recalls the stylish days of rail travel. The interiors of the Spanish-Colonial style building feature burnished oak benches, original tiles, and chandeliers. ## 10. Maritime Museum of San Diego Google Map Nautical lovers can gaze at _San Salvador_ , _Star of India_ , _Berkeley_ , _Medea_ , and other vintage ships _(seeMaritime Museum of San Diego_) restored to their former glory. The restored ship, Berkeley ### SAN DIEGO AND THE MILITARY San Diego has had strong military ties ever since the Spanish built the presidio (fortress) in 1769, and the military contributes handsomely to the local economy. Their presence is everywhere: Navy SEALS train at Coronado, three aircraft carriers and warships berth in the harbor, and Marines land amphibious tanks along Camp Pendleton. Ship parades and tours are popular events in San Diego's September/October Fleet Week. Back to Embarcadero Back to Top 10 San Diego Highlights # USS MIDWAY MUSEUM USS Midway Museum Floor Plan ## 1. Hangar Deck The hangar deck stored the carrier's aircraft, with elevators raising planes up to the flight deck as needed. Now the carrier's entry level, it has audio-tour headsets, aircraft displays, a gift shop, café, and restrooms. Don't miss the 24-ft (7-m) Plexiglas model of the _Midway_ used in World War II to construct the carrier. Fighter plane on the hangar deck ## 2. Virtual Reality Flight Simulations For an additional price, which also includes a briefing, a flight suit, and 30 minutes of flight, you can experience flying a plane by taking the controls of a flight simulator. Also on hand are several standard flight stations, where, for another ticket, you can practice taking off from a carrier. ## 3. Post Office The _Midway_ 's crew often had to wait several weeks at a time for a Carrier Onboard Delivery flight to receive letters from home. The post office was also in charge of the disbursement of money orders. ## 4. Aircraft More than two dozen planes and helicopters are on display on the flight and hangar decks. Among the displays are the F-14A Tomcat, which flies at speeds exceeding Mach 2, two F-4 Phantoms, and an A-6E Intruder. The _Midway_ once held up to 80 aircraft. ## 5. Galley The _Midway_ could store up to 1.5-million lbs (680,388 kg) of dry provisions and a quarter-million lbs (113,398 kg) of meat and vegetables to serve the crew 13,000 meals daily. ## 6. Flight Deck The area of the _Midway_ 's flight deck is roughly 4 acres (1.6 ha) in size. Additional aircraft are displayed here, and the Island is entered from here. The flight deck was where dramatic landings and take-offs took place – take-offs were from the bow, and the angled deck was used for landings. Flight deck of the USS _Midway_ ## 7. Berths Sleeping berths for 400 of the 4,500 crew members are displayed on the hangar deck. Beds were too short to be comfortable for anyone over 6 ft (1.8 m), and the accompanying metal lockers could hold barely more than a uniform. Enlisted men were often just out of high school. ## 8. Arresting Wire and Catapults Notice the arresting wire on the flight deck. This enabled a pilot to land a 20-ton jet cruising at 150 miles (241 km) an hour on an area the size of a tennis court. A hook attached to the tail of a plane grabbed the wire during landing. Two steam catapults helped propel the plane for take-off. ## 9. Island Ladders take you up to the navigation room and bridge, sometimes called the Superstructure, from where the ship's movements were commanded. The flight control deck oversaw aircraft operations. The Island, or Superstructure ## 10. Metal Shop On the mess deck, the metal shop produced metal structures and replicated metal parts for the ship or its aircraft. Self-sufficiency and versatility were the keywords for tours of duty when the ship would be away for months at a time. ### HISTORY OF THE MIDWAY Commissioned on September 10, 1945, the _Midway_ was named after the Battle of Midway, which was the turning point for the Allies in the War of the Pacific. She remained the largest ship in the world for ten years, and was the first ship too large to transit the Panama Canal. After the fall of Saigon on April 30, 1975, she saw further action during Operation Desert Storm in 1991, and finished her years of service by evacuating military personnel threatened by the 1991 eruption of Mount Pinatubo in the Philippines. The _Midway_ was decommissioned in 1992. **Vietnam War anniversary gathering, USS _Midway_** ### TOP 10 MIDWAY STATISTICS **1.** Overall length: 1,001 ft, 6 inches (305 m) **2.** Width: 258 ft (78.6 m) **3.** Height: 222 ft, 3 inches (67.7 m) **4.** Full displacement: 70,000 tons (63,502,932 kg) **5.** Number of propellers: 4 **6.** Weight of each propeller: 22 tons (19,958 kg) **7.** Boilers: 12 **8.** Miles of piping: 200 (322 km) **9.** Miles of copper conductor: 3,000 (4,828 km) **10.** Ship fuel capacity: 2.23 million gallons (8.4 million literws) Back to Embarcadero Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # BALBOA PARK Since the early 20th century, Balboa Park has awed San Diegans with its romantic hillside setting, lush landscaping, and splendid architecture. The park's magnificent Spanish structures date from the 1915–16 Panama-California Exposition. On weekends, thousands of visitors come to indulge their interests, whether it's recreational, Shakespeare, or art. However, the park is probably best known as the home of the world-famous San Diego Zoo, where almost 4,000 animals and 800 species reside. Balboa Park Map ### NEED TO KNOW www.balboapark.org **House of Hospitality:** 619 239 0512; open 9:30am–4:30pm daily **House of Pacific Relations:** 619 234 0739; open 11am–5pm Sat & Sun; www.sdhpr.org **Spreckels Organ Pavilion:** 619 702 8138; regular concerts: 2–3pm Sun; summer concerts: 7:30–9pm Mon (mid-Jun–Aug) **San Diego Zoo:** 619 231 1515; open 9am–6pm (to 9pm Jun 24–Sep 4); adm adult $54, child $44; www.sandiegozoo.org Google Map * Explorer passes can be purchased at the visitor center, giving admission to five or 17 museums. * Get lunch at the Japanese Sculpture Garden's Tea Pavilion. * Some parking lots aren't open until 8:30am. ## 1. Reuben H. Fleet Science Center Google Map Explore sense and touch in the Gallery of Illusions and Perceptions _(seeReuben H. Fleet Science Center)_, learn about electricity, digital recording, and tornados, or catch an IMAX movie or a planetarium show. Children enjoying an exhibit at the Reuben H. Fleet Science Center ## 2. Botanical Building Google Map Constructed for the 1915–16 Panama-California Exposition, the Botanical Building is one of the world's largest lath structures. It houses more than 2,100 orchids, palms, and other tropical plants, and seasonal flowers. ## 3. The Old Globe Google Map The Tony-winning Old Globe Theatre, the Sheryl and Harvey White Theatre, and the Lowell Davies Festival Theatre form a wonderful cultural resource. ## 4. Casa del Prado Google Map The outstanding structure is a reconstruction of a building from the Panama-California Exposition. Wall reliefs commemorate Saint Junípero Serra and Juan Cabrillo. ## 5. Spanish Village Art Center Google Map Architect Richard Requa wanted visitors to experience the simple life of a Spanish village. This complex houses 37 art and craft studios. Entrance to the Spanish Village Art Center ## 6. House of Hospitality Google Map Modeled on a hospital in Spain and now a visitor center, this was erected for the Panama-California Exposition and rebuilt in the 1990s. ## 7. House of Pacific Relations Google Map Founded in 1935, these cottages feature cultural ambassadors from 33 countries showcasing local traditions. ## 8. Spreckels Organ Pavilion Google Map One of the world's largest outdoor organs, it contains 4,530 pipes. The metal curtain protecting it weighs close to 12 tons. Free recitals are held on Sundays. The grand outdoor organ ## 9. San Diego Zoo Google Map In this zoo, thousands of animals thrive in re-created natural habitats. Thanks to breeding programs and webcams, endangered baby pandas are now superstars. ## 10. California Tower and Dome Google Map Built for the Exposition, this building, with its 200-ft (61-m) tower, has come to represent San Diego's identity. Famous figures of the city's past are represented on the facade. Inside is the Museum of Man. California Tower and Dome ### BALBOA PARK AND WORLD WAR II More than 2,000 beds were lined up in Balboa Park's museums for those wounded in 1941's Pearl Harbor attack. All buildings were used for barracks. The park became one of the largest hospital training centers in the world: 600 Navy nurses were stationed at the House of Hospitality, and the lily pond served as a rehab pool. In 1947, the military returned the park to the city. Back to Balboa Park Back to Top 10 San Diego Highlights # SAN DIEGO ZOO San Diego Zoo Map ## 1. Panda Trek Google Map The giant panda superstars spend most of their day eating bamboo, oblivious to the millions of adoring fans that line up for hours for a glimpse or to watch them via a 24-hour panda cam. Six panda births have occurred at the zoo in the last nine years, most recently male Xiao Liwu in July 2012. The area also features golden-hued takins, considered national treasures in China along with the pandas. Giant pandas examining an enrichment toy in their enclosure ## 2. Polar Bear Plunge Google Map In this recreated Arctic tundra habitat, three huge polar bears lounge about and frolic in the chilly water of a 130,000-gallon plunge pool. Sometimes, for a special enrichment treat, zookeepers fill the enclosure with 18 tons of shaved snow for the bears to play in. Don't miss the pool viewing area down below; the bears often swim right up to the window. ## 3. Scripps Aviary Google Map Inside a massive mesh cage, experience an exotic rainforest with sounds of cascading water and more than 130 screeching, chirping, and cawing African birds. Sit on a bench amid lush vegetation and try to spot a silvery-checked hornbill or gold-breasted starling. Scripps Aviary ## 4. Gorilla Tropics Google Map These Western lowland gorillas romp and climb over wide areas of jungle and grassland. Parent gorillas lovingly tend to their children, while others sit quietly with chins in hand, contemplating the strange two-legged creatures observing them from the other side of the glass. ## 5. Lost Forest Google Map Otis, several thousand pounds of male hippo, lives in a re-creation of the Congo River Basin with female Funani, who gave birth in 2015 to their daughter Devi. They share their jungle home with forest buffaloes, swamp monkeys, and okapis, whose long black prehensile tongues let them grab nearby leaves to eat. ## 6. Tiger River Google Map A misty rainforest filled with orchids is home to the endangered Malayan tiger. Marvel at these wondrous animals as they sit majestically on the rocks, with waterfalls flowing behind them. This natural habitat was created to resemble their native jungle environment, with steep slopes, logs to climb on, and a warm cave near the viewing window. Malayan tiger, Tiger River habitat ## 7. Reptile House Google Map If it slithers, hisses, or rattles, it's here. Be glad these animals, especially the king cobra, Albino python, and Gila monsters, are behind glass. Cages marked with a red dot indicate the venomous ones. ## 8. Children's Zoo Little ones love petting the goats and sheep in the paddock (wash-up sinks are nearby), while older kids squeal with mischievous glee at the tarantulas, black-widow spiders, and hissing cockroaches. The nursery takes care of baby animals whose mothers can't look after them. ## 9. Elephant Odyssey Google Map The endangered elephants consume up to 125 lbs (57 kg) of hay and 30 gallons of water a day. Keep your camera ready, as the elephants often toss barrels or scratch their back under a special roller. Asian elephants have dome-shaped backs, while the ears of an African elephant are shaped like the African continent. An elephant in the Elephant Odyssey ## 10. Conrad Prebys Australian Outback Google Map Discover Australian wildlife from wombats to kookaburras – as many as seven different marsupials and 25 species of birds. The decks at the Queenslander House overlook a forest for the zoo's largest koala colony outside of Australia. A koala at San Diego Zoo Back to Balboa Park Back to Top 10 San Diego Highlights # BALBOA PARK MUSEUMS Balboa Park Museums Map ## 1. San Diego Museum of Man 619 239 2001 • Open 10am–5pm daily • Adm • www.museumofman.org Google Map Learn about evolution from a replica of a 4-million-year-old human ancestor, and visit the Ancient Egypt room for mummies and funerary objects. Artifacts from the Kumeyaay, San Diego's original inhabitants, and a replica of a Mayan monument emphasize the culture of the Americas. ## 2. San Diego Museum of Art 619 232 7931 • Open 10am–5pm Mon, Tue & Thu (to 8pm Fri), noon–5pm Sun • Adm • www.sdmart.org Google Map This exceptional museum has works by old masters and major 19th- and 20th-century artists. Be sure to check out the Asian art collection. Visitors at San Diego Museum of Art ## 3. Mingei International Museum 619 239 0003 • Open 10am–5pm Tue–Thu & Sun (to 6pm Fri & Sat) • Adm • www.mingei.org Google Map The Japanese word _mingei_ means "art of the people" and on view here is a display of international folk art. Exhibits include textiles, jewelry, furniture, and pottery. ## 4. San Diego Natural History Museum 619 232 3821 • Open 10am–5pm daily • Adm • www.sdnhm.org Google Map Galleries showcase the evolution and diversity of California. Exhibits, guided weekend nature walks, and field trips explore the natural world. Display at the Natural History Museum ## 5. Timken Museum of Art 619 239 5548 • Open 10am–4:30pm Tue–Sun (from noon Sun) • www.timkenmuseum.org Google Map The collection includes Rembrandt's _Saint Bartholomew_ , and works by Rubens and Bruegel the Elder. ## 6. San Diego History Center 619 232 6203 • Open 10am–5pm daily • Adm • www.sandiegohistory.org Google Map An alternating collection of old photographs and artifacts that introduce San Diego's early years. ## 7. Museum of Photographic Arts 619 238 7559 • Open 10am–5pm Tue–Sun (summer: to 8pm Thu) • Adm • www.mopa.org Google Map Temporary exhibitions featuring the world's most celebrated camera geniuses mix with pieces from the museum's permanent collection. The theater screens film classics. ## 8. San Diego Air and Space Museum 619 234 8291 • Open 10am–4:30pm daily • Adm • www.sandiegoairandspace.org Google Map One of the museum's finest planes, the Lockheed A-12 Blackbird spy plane, greets you on arrival. Don't miss the International Aerospace Hall of Fame. ## 9. San Diego Automotive Museum 619 231 2886 • Open 10am–5pm daily • Adm • sdautomuseum.org Google Map Discover California's car culture through classic vehicles and rotating and permanent exhibits. A Racing Hall of Fame honors past giants of the racing world. A classic car at San Diego Automotive Museum ## 10. Centro Cultural de la Raza 619 235 6135 • Open noon–4pm Tue–Sun • www.centrodelaraza.com Google Map This former water tower, decorated with colorful murals, celebrates indigenous, Chicano, Mexican, and Latino art and culture with rotating exhibits and performances. ### THE MOTHER OF BALBOA PARK Horticulturalist Kate Sessions needed room to establish a nursery in 1910. She struck a deal with the city of San Diego in which she promised to plant 100 trees a year in the then-called City Park and 300 trees elsewhere in exchange for 36 acres. A 35-year planting frenzy resulted in 10,000 glorious trees and shrubs, shady arbors draped with bougainvillea, and flower gardens that burst with color throughout the year. **The Alcázar Gardens** look particularly beautiful and colorful when in full bloom during the spring. ### TOP 10 GARDENS OF BALBOA PARK **1.** Alcázar Gardens **2.** Japanese Friendship Garden **3.** Botanical Building and Lily Ponds **4.** Palm Canyon **5.** Casa del Rey Moro **6.** Zoro Garden **7.** Rose Garden **8.** Desert Garden **9.** Florida Canyon **10.** Moreton Bay Fig Tree Back to Balboa Park Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # OLD TOWN STATE HISTORIC PARK After Mexico won its independence from Spain in 1821, many retired soldiers created what is now Old Town, laying their homes and businesses around the plaza in typical Spanish style. Through trade with Boston, the town began to prosper. After a fire in 1872 destroyed much of the commercial center, San Diego moved to a "New Town" closer to the bay. Today, you can explore the preserved and restored structures of San Diego's pioneer families. Old Town State Historic Park Map ### NEED TO KNOW 4002 Wallace St • (619) 220-5422 • www.parks.ca.gov • **Open** May–Sep 10am–5pm daily; Oct–Apr 10am–4pm Mon–Thu, 10am–5pm Fri & Sat **La Casa de Estudillo:** closed Mon **Seeley Stable Museum:** closed Tue Google Map * Head to one of San Diego's most famous Mexican restaurants, Old Town Mexican Café & Cantina, and watch the ladies make tortillas as you have lunch. * One-hour walking tours led by park staff leave daily at 11am and 2pm from the Robinson-Rose House. * Park concessionaires sell traditional souvenirs and other wares; nearby Bazaar del Mundo offers colorful, unique items. ## 1. Plaza Google Map The plaza was once used by Spanish communities for bullfights, political events, executions, and fiestas. Since 1846, tradition maintains that the Old Town flagpole must be made from a ship's mast. ## 2. La Casa de Estudillo Google Map Built in 1827 by José Estudillo, the Presidio's commander, this adobe home is Old Town's show-piece. Workmen shaped the curved red tiles of the roof by spreading clay over their legs. José Estudillo's clay home ## 3. Seeley Stable Museum Google Map Before railroads, Albert Seeley ran a stagecoach business between San Diego and LA. This barn houses original carriages and wagons from the Wild West. A wagon at the Seeley Stable Museum ## 4. Mason Street School Google Map This one-room school opened in 1865. Its first teacher, Mary Chase Walker, resigned her $65-a-month position when townspeople complained that she had invited a black woman to lunch. ## 5. San Diego Union Historical Museum Google Map This wood-frame house was built in New England and shipped down in 1851. It was home to the early years of _The San Diego Union_ , the city's oldest newspaper. ## 6. Colorado House Google Map The name Wells Fargo came to symbolize the opening of the American West. At this little museum housed in a former hotel, a restored stagecoach is the main exhibit. Facade of the Colorado House ## 7. La Casa de Machado y Stewart Google Map Jack Stewart married Rosa Machado in 1845 and moved to this adobe home, where the family remained until 1966. Its deterioration finally forced them to move. ## 8. Robinson-Rose House Google Map Docents are on hand to answer questions at this house, which dates from 1853 and is the headquarters of Old Town. Look out for the model of the 1872 Old Town. ## 9. La Casa de Bandini Google Map Peruvian Juan Bandini arrived in San Diego in 1819 and became one of its wealthiest citizens. His former home is now the Cosmopolitan Hotel. Interior of Juan Bandini's former home ## 10. First San Diego Courthouse Google Map This reconstruction of the 1847 courthouse marks the city's first fire-brick structure. Not to be missed is the ominous 1860 jail cell out back. ### FIRST IMPRESSIONS In his epic story of early San Diego, _Two Years Before the Mast_ (1840), Richard Henry Dana described the town as "a small settlement directly before the fort, composed of about 40 dark-brown-looking huts or houses, and two larger ones plastered." Bostonian Mary Chase Walker, San Diego's first schoolhouse teacher, was more blunt: "Of all the dilapidated, miserable looking places I had ever seen, this was the worst." Back to Old Town State Historic Park Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # CORONADO Sometimes described as an island because its village-like atmosphere is far removed from the big city, picturesque Coronado lies on a sliver of land between the Pacific Ocean and San Diego Bay. More retired Navy officers live here than any other place in the US, and although the military presence is high, it's unobtrusive. For over 100 years, visitors have flocked to Coronado to be part of this charmed life. Even with its thriving resorts, restaurants, sidewalk cafés, and unique shops, the village never seems overwhelmed. Coronado Map ### NEED TO KNOW coronadovisitorcenter.com **Hotel del Coronado:** 1500 Orange Ave; 619 435 6611; www.hoteldel.com **Meade House:** 1101 Star Park Cir **Ferry Landing Market Place:** 1201 1st St at B Ave; 619 435 8895; open 10am daily, various closing times **Coronado Museum of History and Art:** 1100 Orange Ave; 619 435 7242; open 9am–5pm Mon–Fri, 10am–5pm Sat & Sun; adm $5; www.coronadohistory.org **San Diego Ferry:** 619 234 4111; adm $4.25 Google Map * Enjoy the Hotel del Coronado's ambience by having a drink in the Babcock & Story Bar. * Excellent historical walking tours depart from Glorietta Bay Inn _(1630 Glorietta Blvd; 619 435 5993; Tue, Thu & Sat at 11am; adm)_. ## 1. Hotel del Coronado Google Map This 1887–8 Queen Anne wooden masterpiece is a National Historic Landmark. It was the first hotel west of the Mississippi with electric lights. The resplendent Hotel del Coronado ## 2. Meade House Google Map L. Frank Baum moved to Coronado in 1904 and produced much of his work at this charming house, now a private residence. ## 3. US Naval Amphibious Base Google Map South of Coronado, along the Silver Strand, this training camp for the hallowed Navy SEALS is off-limits to the public. ## 4. Coronado Bridge Google Map Connecting San Diego to Coronado since 1969, this 2.2-mile (3.5-km) span has won architectural awards for its unique design. Struts and braces in a box girder give it a sleek look. The Coronado Bridge ## 5. Coronado Central Beach Google Map Coronado's main beach claims a golden swath adjacent to the Hotel del Coronado. Families, fishers, surfers, and swimmers all stake spots, while dog-walkers rule the north end. ## 6. Mansions along Ocean Boulevard Google Map Designed by prominent early 20th-century architects Hebbard and Gill, mansions dominate Coronado's oceanfront. A mansion along Ocean Boulevard ## 7. Ferry Landing Marketplace Google Map Next to the ferry dock is a shopping area selling beachwear, jewelry, souvenirs, and art. This is a handy spot to rent a bike or grab a snack. ## 8. Coronado Museum of History and Art Google Map In a 1910 Neo-Classical bank building, galleries exhibit early village history, with photos of the Hotel del Coronado, Tent City, and military memorabilia. Exhibit from the Coronado Museum of History and Art ## 9. San Diego Ferry Google Map Before the Coronado Bridge, access was only by a long drive around Southern San Diego or via the ferry, which is now only for foot passengers. ## 10. Orange Avenue Google Map The main shopping street has restaurants and sidewalk cafés, as well as a theater and a museum. Independence Day and Christmas parades see residents out celebrating. ### THE DUKE AND DUCHESS OF WINDSOR When the British King Edward VIII gave up his throne to marry American Wallis Simpson, romantics insisted they originally met at the Hotel del Coronado. In 1920, Wallis Spencer, then married to a naval officer of that name, lived at the hotel. That April, Edward visited Coronado. It is unclear whether the couple met then; it wasn't until 15 years later that they were formally introduced. Back to Coronado Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # POINT LOMA Point Loma was once one of the roughest areas in San Diego. The city's first boats were tied up here, followed by the largest whaling operation on the West Coast and leather tanning and tallow production. Today, sailboats and lavish yachts grace the marinas of Point Loma, and the waterfront homes make up some of the most expensive real estate in the city. The Cabrillo National Monument, one of the most visited monuments in the US, boasts the most breathtaking views of the entire city. San Diego skyline, visible from Point Loma Point Loma Map ### NEED TO KNOW **Cabrillo National Monument Visitor Center:** 1800 Cabrillo Memorial Drive; 619 557 5450; open 9am–5pm daily; adm $10 per vehicle, $5 per person (cyclists and walk-ins); tickets last for 7 days and visitors can return as many times as they like; www.nps.gov/cabr Google Map * Vending machines at the Cabrillo National Monument Visitor Center offer snacks. If you want to spend the day exploring the tide pools or hiking, bring food and water. * Bring binoculars to enjoy the views and, if visiting the tide pools, shoes with plenty of grip. * The San Diego Metropolitan Transit comes out to the monument. Take bus 28 or 84c from the Old Town Transportation Center. ## 1. Cabrillo National Monument Google Map The spot where Cabrillo stepped ashore is on a spit of land downhill at Ballast Point. This statue is a worthy tribute to the brave explorer and his men who traversed the seas to claim new territory for Spain. Statue of Juan Rodríguez Cabrillo ## 2. Old Point Loma Lighthouse Google Map This Cape Cod-style building was completed in 1855. Unfortunately, coastal fog often hid the beacon light, so another lighthouse, the New Point Loma Lighthouse, was built below the cliff. ## 3. Tide Pools Google Map Now protected by law, starfish, anemones, warty sea cucumbers and wooly sculpins thrive in their own little world. ## 4. Bayside Trail Google Map A 2-mile (3.2-km) round-trip hiking path runs on an old military defense road. Signs on the way identify over 300 indigenous plants such as sage scrub and Indian paintbrush. ## 5. Sunset Cliffs Google Map A path runs along the edge of these spectacular 400-ft (122-m) high cliffs, but signs emphatically warn of their instability. The beach is accessible from Sunset Cliffs Park. Sunset Cliffs ## 6. Point Loma Nazarene University Google Map Once a yoga commune, much of the original architecture of this Christian university is still intact. ## 7. Military Exhibit Google Map After the 1941 Pearl Harbor attack, many felt that San Diego would be the next target. The exhibit explores how the military created a coastal defense system and the largest gun in the US. ## 8. Whale Overlook Google Map Pacific gray whales migrate yearly to give birth in the warm, sheltered waters of Baja California before heading back to Alaska for a summer of good eating. January and February are the best times to spot whales. ## 9. Fort Rosecrans National Cemetery Google Map The southern end of Point Loma belongs to the military installations of Rosecrans Fort. Innumerable crosses mark the graves of more than 100,000 US veterans, some of whom died at the Battle of San Pasqual in the Mexican-American War. Graves of veterans at the Fort Rosecrans National Cemetery ## 10. Visitor Center Google Map Browse through the center's outstanding books about the Spanish, Native Americans, and early California, or enjoy the daily film screenings. Park rangers are on hand to answer questions. ### JUAN CABRILLO After participating in the conquest of Mexico and Guatemala, Juan Cabrillo was instructed to explore the northern limits of the West Coast of New Spain in search of gold and a route to Asia. He arrived at Ballast Point on September 28, 1542, claimed the land for Spain, and named it San Miguel. Cabrillo died a few months later from complications of a broken bone. Spain saw the expedition as a failure and left the territory untouched for more than 200 years. Back to Point Loma Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # MISSION BASILICA SAN DIEGO DE ALCALÁ Founded by Saint Junípero Serra in 1769, this was California's first mission. Serra encouraged Native Americans to live here, exchanging work in the fields for religious instruction. Harassment by soldiers and lack of water supplies caused the mission to be moved from its original location in Old Town to this site. In 1976, Pope Paul VI bestowed the mission with the status of minor basilica. In 2015, Pope Francis canonized Junípero Serra, the first such ceremony to be conducted on US soil. ### NEED TO KNOW 10818 San Diego Mission Road • 619 281 8449 • www.missionsandiego.com • **Open** 9am–4:45pm daily • Adm $3; Tote-a-Tape Tours $2 **Church:** Mass 7am & 5:30pm Mon–Fri, 5:30pm Sat, 7am, 8am, 9am, 10am, 11am, noon & 5:30pm Sun Google Map * Food and drinks are not allowed inside the mission. * Be aware that the San Diego Trolley stops a good three blocks away. Mission Floor Plan ## 1. La Casa del Padre Serra The original 1774 adobe walls and beams survived a Native American attack, military occupation, earthquakes, and years of neglect. Padres lived simply, with few material comforts. Interior of Padre Serra's quarters ## 2. Campanario This graceful 46-ft (14-m) bell tower defines California mission architecture. One of the bells is considered an original, and the crown atop another suggests it was probably cast in a royal foundry. The graceful bell tower ## 3. Padre Luis Jayme Museum Artifacts here include records of births and deaths in Saint Serra's handwriting, the last crucifix he held, and old photographs showing the extent of the mission's dereliction prior to restoration efforts. ## 4. Garden Statues Four charming statues of St. Anthony of Padua, patron saint of the Native Americans; St. Serra; St. Joseph, saint of Serra's expedition; and St. Francis keep vigil over the inner garden. Statue of St. Anthony of Padua ## 5. Chapel Taken from a Carmelite monastery in Plasencia, Spain, this small chapel features choir stalls, a throne, and an altar dating from the 1300s. The choir stalls are held together by grooves rather than nails. The raised seats allowed the monks to stand while singing. ## 6. Cemetery Although it no longer contains real graves, this is the oldest cemetery in California. The crosses are made of original mission tiles. A memorial honors Native Americans who died during the mission era. ## 7. El Camino Real Also called the Royal Road or King's Highway, this linked the state's 21 missions, each a day's distance apart on foot. ## 8. Church The width of a mission church depended on available beams. Restored to specifications of a former 1813 church on this site, it features adobe bricks, the original floor tiles, and wooden door beams. The church at Mission Basilica San Diego de Alcalá ## 9. Gardens Exotic plants add to the lush landscape around the mission. With few indigenous Californian species available, missionaries and settlers brought plants from all parts of the world, including cacti from Mexico and bird of paradise from South Africa. The lush gardens at the mission ## 10. Padre Luis Jayme Memorial On November 5, 1775, Native Americans attacked the mission. A cross marks the approximate spot where the Kumeyaay tribe killed Jayme, California's first martyr. ### JUNÍPERO SERRA Franciscan father Saint Junípero Serra spent 20 years in Mexico before coming to California. Few of his companions survived the tough "Sacred Expedition" across the desert. Serra, undeterred, established California's first mission in 1769. His sainthood was controversial for many Native Americans as they felt the mission system had helped to fragment their culture. Back to Mission Basilica San Diego de Alcalá Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # MISSION BAY PARK In 1542, explorer Juan Rodriguez Cabrillo named this tidal basin "False Bay." Between the 1940s and 1960s, the US Army Corps of Engineers transformed the swampland into a 6.5-sq-mile (17-sq-km) showplace aquatic park and the city's premier recreational playground. Containing 19 miles (30 km) of beach and 27 miles (43 km) of shoreline, Mission Bay offers water and land sports, as well as cozy inlets and grassy knolls for lazy days. Mission Bay Park Map ### NEED TO KNOW 2581 Quivira Court • 619 221 8899 (recorded info 619 221 8824) • www.sandiego.gov/lifeguards/about/contact **Mission Bay Aquatic Center** : 1001 Santa Clara Place; 858 488 1000; open 8am–7pm daily; equipment available for hire such as sailboats, kayaks, bodyboards, paddleboards, and more (terms and conditions apply); lessons and classes available, rates vary (www.mbaquaticcenter.com). **Bayside Walk:** Bahia Belle cruise: 998 West Mission Bay; 858 539 7779 for tickets and public cruises; boarding: Bahia Hotel 6:30pm–1:30am, Catamaran Resort 7pm–1am; adm $10, under 12s $3 (free for resort guests); www.bahiahotel.com/dining-entertainment/bahia-belle-boat-cruise **Belmont Park** : 3146 Mission Blvd; 858 228 9283; open for rides 11am–10pm most days; ride prices vary (free parking and adm) Google Map * The minimum age for boarding the Bahia Belle stern-wheeler after family hours (6:30–9pm) is 21, with a valid ID. All minors must be accompanied by a parent or guardian. ## 1. Fiesta Island Google Map Reached via a causeway, this dune-covered peninsular park has bonfire rings and a leash-free dog area. The site also hosts the infamous Over the Line tournament. Visitors at Fiesta Island ## 2. Mission Bay Aquatic Center Google Map Known as one of the world's largest facilities of its kind, this center at Santa Clara Point offers lessons in nearly every water activity, from surfing and sailing to paddleboard yoga and sea kayaking. ## 3. Bayside Walk Google Map Strollers or cyclists may take this route from the lush Catamaran Resort (the departure point for sternwheeler Bahia Belle) to the park's western edge, where it loops at Mission Point. Rest and take in the views along the path. ## 4. DeAnza Cove Google Map On the northeast corner of the park, DeAnza is convenient for a picnic or swim. Boats and jet skis launch from the ramp, and there is a designated area for volleyball. ## 5. Mariners Point Google Map Jutting from the tip of a small peninsula, this sandy expanse provides an intriguing dichotomy: it hosts skateboard competitions and is a nesting site for the California least tern. The California least tern ## 6. Ventura Bridge Google Map Extending 116 ft (35 m) across Mission Bay Drive, Ventura Bridge connects Quivira and Mariners basins, before linking to Mission Beach and Belmont Park. ## 7. Mission Beach and Ocean Front Walk Google Map Parallel to Mission Beach, Ocean Front Walk is more of a movement than a stroll, a chaotic blend of rollerbladers, skate dancers, cyclists, and surfers running toward the waves. Festivities continue onto Mission Beach – a gigantic 2-mile (3-km), year-round beach party. ## 8. Belmont Park Google Map Belmont Park still retains its old-fashioned seaside aura, highlighted by the 1925 Giant Dipper roller coaster, but there are also attractions like _Tron_ -themed laser tag and the FlowBarrel artificial wave machine. The Giant Dipper roller coaster at Belmont Park ## 9. Crystal Pier Google Map The dividing line between Pacific and Mission beaches, this 750-ft (228-m) pier is notable for its 1930s cottage motel, set right above the water. Even if you don't book a stay at the motel, you can still walk the pier. Crystal Pier ## 10. Quivira Basin Google Map Waterfront shops, restaurants, and a resort are clustered around busy Quivira Basin and Dana Landing, from where daily scuba diving and fishing charters depart. Mission Bay Park Headquarters provides information and maps. From Dana Landing, Ingraham Street cuts across Vacation Isle to Crown Point. Back to Mission Bay Park Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # LA JOLLA Developer Frank Botsford bought a substantial area of barren pueblo land in 1886, which he then subdivided. Other real estate developers soon caught on to La Jolla's potential and built resorts, but it wasn't until Ellen Browning Scripps arrived in 1896 that the town developed as a research, education, and art center. Now, La Jolla (pronounced "hoya") is among the most expensive land in the US. Befittingly, its name translates as "the jewel." La Jolla Map ### NEED TO KNOW **Museum of Contemporary Art:** 700 Prospect St; 858 454 3541; open 11am–5pm Thu–Tue; 11am–7pm 3rd Thu each month; adm $10; free 5–7pm third Thu of month; www.mcasd.org **Mount Soledad Veterans Memorial:** Soledad Rd; open 7am–10pm daily **Scripps Institution of Oceanography:** 8622 Kennel Way; www.sio.ucsd.edu **University of California, San Diego:** 9500 Gilman Dr; 858 534-2230; www.ucsd.edu Google Map * The café at the Museum of Contemporary Art serves good sandwiches and salads. * Watch the paragliders launch from the Torrey Pines cliffs, or stroll the UCSD campus and its Stuart Collection of outdoor sculpture. ## 1. La Jolla Bay Google Map This gathering spot just below La Jolla village is small but startling, wedged between sandstone cliffs with glorious views. Its robust marine life is protected. The picturesque La Jolla Bay ## 2. La Jolla Playhouse Google Map The Tony Award-winning Playhouse, founded by actor Gregory Peck, is housed in the UC San Diego Theatre district _(seeLa Jolla Playhouse)_. A production at La Jolla Playhouse ## 3. Museum of Contemporary Art Google Map Only a fraction of more than 3,000 works from every noteworthy art movement since 1950 are on display at this renowned museum. ## 4. Ellen Browning Scripps Park Google Map Stroll along palm-lined walkways and gaze out over panoramic coastline views. ## 5. Mount Soledad Veterans Memorial Google Map The 43-ft (13-m) cross on Mount Soledad, erected in 1954, is the centerpiece of a memorial that honors veterans of the Korean and other wars. Six walls beneath the cross hold 2,400 plaques. ## 6. Birch Aquarium at Scripps Google Map Brilliantly colored underwater habitats educate at this marine museum _(seeBirch Aquarium at Scripps)_. You'll feel like a scuba diver when viewing sharks swimming in an offshore kelp bed housed in a 70,000-gallon tank. An underwater habitat at the aquarium ## 7. Scripps Institution of Oceanography Google Map Leading the way in global science research, Scripps Oceanography is now in its second century of discovery. Hundreds of research programs are under way on every continent and ocean. ## 8. Torrey Pines State Reserve Google Map At this reserve, hiking trails wind past coastal scrub, sandstone cliffs, and woodlands, with stunning views of the Pacific. Guided tours are available. ## 9. Salk Institute Google Map Dr. Jonas Salk, creator of the first successful polio vaccine, founded this institution for biomedical research in 1960. ## 10. University of California, San Diego (UCSD) Google Map Six colleges make up one of the most prestigious public universities in the country. Geisel Library building, UCSD ### ELLEN BROWNING SCRIPPS Born in England in 1836, Scripps moved to the US in 1844. She became a teacher, investing her savings in her brother's newspaper ventures in Detroit and Cleveland. Already wealthy, she inherited a fortune on his death in 1900. Scripps spent her last 35 years in La Jolla, giving away millions of dollars for the good of humanity. Back to La Jolla Back to Top 10 San Diego Highlights Back to Top 10 San Diego Highlights # EAST COUNTY San Diego's East County offers truly diverse attractions within an hour or so of downtown. Interstate 8 passes casinos and the vintage trains at Campo, with a turnoff to Cuyamaca Rancho State Park. Scenic backroad State Route 78 hits the gold-rush mountain village of Julian. Both roads take in Anza-Borrego Desert State Park. East County Map ### NEED TO KNOW **Borrego Springs Chamber of Commerce:** 786 Palm Canyon Dr; Borrego Springs; 760 767 5555; www.borregospringschamber.com **Anza-Borrego Desert State Park Visitor Center:** 200 Palm Canyon Dr, Borrego Springs; 760 767 5311; open 9am–5pm daily (park open throughout the year); adm (Borrego Palm Canyon Campground) $8 per vehicle Oct–early May, $6 rest of the year; reservations can be made up to 7 months in advance (800 444 7275) Google Map * If crossing the border into Mexico, assure your personal safety and that of your property. Heed US State Department warnings _(www.state.gov/travel)_. * The Borrego Springs Chamber of Commerce is a good source for reputable tour operators for off-road excursions and stargazing expeditions. ## 1. Cuyamaca Rancho State Park Google Map Just 5 miles (8 km) north of I-8, Cuyamaca has more than 100 miles (160 km) of hiking, biking, and horse trails, with desert and coast views along the way. A creek meanders through Green Valley. The sunlit expanse of Cuyamaca ## 2. Native American Casinos Native American communities have more than a dozen 24-hour casinos in the county. Only those over 21 and with valid identification are allowed in gaming areas. ## 3. Julian Google Map After the gold rush of the 1870s, some stayed on in this charming community surrounded by forests in the Cuyamaca Mountains. Filled with B&Bs, this Historical District is a popular weekend getaway and known for its apple orchards. Shops in Julian ## 4. Desert Blooms On first glimpse, this desert may look like a gigantic expanse of nothingness, but it is rife with life, notably wildflowers and bird species. Between February and April, weather permitting, it erupts into a vibrant palette of colorful blooms. Wildflowers blooming in the desert ## 5. Driving Tours Venturing into the desert by car, other than on the main roads, is not advisable for the inexperienced. Roads can be impassable and unpredictable. A variety of tour operators can safely escort you on everything from a short day tour to an off-road overnight adventure. ## 6. Pacific Southwest Railway Google Map Operated by the Railway Museum of San Diego, the _Golden State Limited_ departs twice daily on weekends from the historic Campo train depot for a 12-mile (20-km) round trip to Miller Creek. ## 7. Mount Laguna After a good storm, this 5,738-ft- (1,750-m-) high hamlet at the eastern edge of the Cleveland National Forest becomes a winter playground for San Diegans, who come here to sled, cross-country ski, and generally marvel at the chillier climes. ## 8. Borrego Springs Google Map San Diego County's desert community has lodging, restaurants, tours, and the Park Headquarters, where you can view exhibits, an informative film, and a desert garden. Visitor at Borrego Springs ## 9. Anza-Borrego Desert State Park Google Map California's largest state park at 938 sq miles (2,430 sq km), it offers cacti and posies, rough trails, historic roads, mountainous dunes, extreme temperatures, other-worldly skies – plus peace and quiet. ## 10. Tecate (Mexico) Google Map This Mexican border town is about 20 minutes west via State Route 94. Check with the Border Patrol for any up-to-the-minute safety issues, as well as any needed re-entry visa. If possible, simply park your car in the little lot by the border (someone will come out to take a few dollars) and walk across. ### METAL DINOSAURS Mexico native and California resident, sculptor Ricardo Breceda made the metal "dinosaurs" that pop out of the desert-scape. Breceda created more than 130 full-sized replicas of creatures that once roamed these lands, including desert tortoises, saber-toothed cats, wild horses, and a 350-ft (106-m) serpent. Back to East County Back to Top 10 San Diego Highlights * * * The Top 10 of Everything A stage show at the La Jolla Playhouse ## THE TOP 10 OF EVERYTHING 1 | Moments in History ---|--- 2 | Historic Sites ---|--- 3 | Architectural Highlights ---|--- 4 | Museums and Art Galleries ---|--- 5 | Beaches ---|--- 6 | Gardens and Nature Reserves ---|--- 7 | Outdoor Activities ---|--- 8 | Off the Beaten Path ---|--- 9 | Children's Attractions ---|--- 10 | Performing Arts Venues ---|--- 11 | Nightlife ---|--- 12 | Cafés and Bars ---|--- 13 | Restaurants ---|--- 14 | Stores and Shopping Centers ---|--- 15 | San Diego for Free ---|--- 16 | Festivals ---|--- Back to The Top 10 of Everything # MOMENTS IN HISTORY ## 1. In the Beginning A skull discovered in 1929 established human presence in San Diego about 12,000 years ago. The Kumeyaay tribe, present at the time of Cabrillo's landing, lived in small, organized villages, and subsisted on wild fruits and nuts, game, and fish. ## 2. Discovery by Juan Cabrillo (1542) Cabrillo was the first European to land at San Diego Bay. The Spanish believed that Baja and Alta California were part of a larger island, "Isla California," named for a legendary land in a Spanish 15th-century romance. California was part of the Spanish Empire for the next 279 years. Juan Cabrillo ## 3. The Spanish Settlement (1769) Fearing the loss of California, Spain sent an expedition, led by Gaspar de Portolá and Franciscan friar Junípero Serra, to build military posts and Christian missions. Disastrous for the Native Americans, the settlement survived and a city slowly took hold. The Spanish Settlement ## 4. Independence of Mexico (1821) After gaining independence, Mexico secularized the California missions and gave their land to the politically faithful. The rancho system of land management lasted into the 1900s. Ports were open to all and the city became a center for the hide trade. ## 5. Alonzo Horton's New City (1867) Horton realized an investment opportunity to develop a city closer to the water than Old Town. He bought 960 acres for $265, then sold and gave lots to anyone who could build a brick house. Property values soared, and "New Town" became today's San Diego. In 1850, California became part of the US and, later, its 31st state. ## 6. Transcontinental Railroad (1885) Interest was renewed in San Diego when the Transcontinental Railroad reached town. Real estate speculators poured in, infrastructure was built, and the future looked bright. However, Los Angeles seemed more promising, and San Diego's population, having gone from 5,000 to 40,000 in two years, shrank to 16,000. ## 7. Panama-California Exposition (1915–16) To celebrate the opening of the Panama Canal and draw economic attention to the first US port of call on the West Coast, Balboa Park was made into an attraction. Fair animals found homes at the zoo and Spanish-Colonial buildings became park landmarks. ## 8. California-Pacific Exposition (1935–6) A new Balboa Park exposition was launched to help alleviate effects of the Great Depression. The architect Richard Requa designed buildings inspired by Aztec, Mayan, and Puebloan themes. California-Pacific Exposition ## 9. World War II The founding of the aircraft industry, spurred by the presence of Ryan Aviation and Convair, gave San Diego an enduring industrial base. After Pearl Harbor, the Pacific Fleet HQ moved here. The harbor was enlarged, and hospitals, camps, and housing changed the city's landscape. ## 10. Later Redevelopment (1981–1995) The Downtown redevelopment brought new life to the area, with the addition of Horton Plaza, the restoration of the historic US Grant Hotel, and the San Diego Convention Center. In Balboa Park, it resulted in three new theaters in the Old Globe complex, and rebuilding of the House of Charm and the House of Hospitality. ### TOP 10 FAMOUS SAN DIEGO FIGURES #### 1. Father Luis Jayme (1740–75) California's first Christian martyr died in a Native American attack. #### 2. Richard Henry Dana (1815–82) Author of the 19th-century classic _Two Years Before the Mast_ , a historical record of early San Diego. #### 3. William Heath Davis (1822–1909) This financier _(seeWilliam Heath Davis House)_ established a new settlement known as "Davis' Folly." #### 4. Alonzo Horton (1813–1909) Real estate magnate Horton, the "father" of San Diego, successfully established the city's present location in 1867. #### 5. Wyatt Earp (1848–1929) Old West sheriff and famed gunman Earp owned saloons and gambling halls in the Gaslamp Quarter. #### 6. John D. Spreckels (1853–1926) Spreckels, a generous philanthropist and businessman, was the owner of the Hotel del Coronado. #### 7. L. Frank Baum (1856–1919) The author of the _Wonderful Wizard of Oz_ lived in and considered Coronado an "earthly paradise" _(seeMeade House)_. #### 8. Charles Lindbergh (1902–74) Lindbergh was the first to fly solo across the Atlantic in 1927. #### 9. Theodore Geisel (1904–91) Best known as the beloved Dr. Seuss, Geisel lived and worked in La Jolla. **The author Theodore Geisel** #### 10. Dr. Jonas Salk (1914–95) Developed the first effective polio vaccination, licensed for use in 1955, and founded the non-profit Salk Institute in 1960. Back to Moments in History Back to The Top 10 of Everything Back to The Top 10 of Everything # HISTORIC SITES ## 1. Ballast Point Point Loma Google Map In 1542, while the Kumeyaay tribe waited on a beach at Ballast Point, Juan Cabrillo stepped ashore and claimed the land for Spain. In 1803, the "Battle of San Diego Bay" took place here, after Spanish Fort Guijarros fired on an American brig in a smuggling incident. ## 2. Old Town Google Map Mexico won its independence from Spain in 1821, after which retired soldiers and their families moved downhill from the presidio, built homes, and opened businesses. An open trade policy attracted others to settle, and by the end of the decade, 600 people lived in Old Town – San Diego's commercial and residential center until 1872. Entrance to a courtyard in Old Town ## 3. Presidio Hill Google Map Spain established its presence in California atop this hill, and Saint Serra founded the first California mission here. During the Mexican-American War in 1846, Fort Stockton, made of earthworks on top of the hill, changed hands thrice between Mexican-Californian ranchers, known as Californios. ## 4. Lindbergh Field Google Map San Diego International Airport was popularly called Lindbergh Field after Charles Lindbergh, who began the first leg of his transatlantic crossing here in 1927. The US Army Air Corps drained the surrounding marshland, took over the small airport, and enlarged the runways to accommodate the heavy bomber aircraft manufactured in San Diego during World War II. ## 5. Julian Google Map The discovery of gold in the hills northeast of San Diego in 1870 was the largest strike in Southern California. For five years, miners poured into the town of Julian, which would have become the new county seat if San Diego supporters had not plied the voters of Julian with liquor on election day. The gold eventually ran out, but not until millions of dollars were pumped into San Diego's economy. ## 6. Mission Basilica San Diego de Alcalá Google Map Originally built on Presidio Hill in 1769, this mission _(seeMission Basilica San Diego De Alcalá)_ moved up the valley a few years later. It was the first of 21 missions, as well as the birthplace of Christianity in the state of California. It was the only mission to be attacked by the indigenous peoples of USA. In 1847, the US Cavalry occupied the grounds. Mission Basilica San Diego de Alcalá ## 7. Border Field State Park 619 575 3613 • Call for opening hours Google Map The Mexican-American War ended with the signing of the Treaty of Guadalupe Hidalgo on February 2, 1848. A US and Mexican Boundary Commission then determined the new international border between the two countries, with California divided into Alta and Baja. A marker placed in 1851 on a bluff in this park shows the farthest western point of the new border. ## 8. San Pasqual Battlefield State Historic Park 15808 San Pasqual Valley Rd, Escondido • Open 10am–4pm Sat & Sun Google Map On December 6, 1846, a volunteer army of Californios, defeated the invading American army in one of the bloodiest battles of the Mexican-American War. Though the Californios won the battle, they later lost the war, and California became part of USA. ## 9. Mission San Luis Rey de Francia Google Map Nicknamed the "King of Missions" for its size, wealth, and vast agricultural estates, this mission is the largest adobe structure in California. The Franciscan padres Christianized 3,000 Native Americans here. After secularization, the mission fell into disrepair and was used for a time as military barracks. It has since been restored to its former glory. ## 10. Gaslamp Quarter Google Map Filled with late-19th-century Victorian architecture, this historic site _(seeGaslamp Quarter)_ was once the commercial heart of Alonzo Horton's New Town. When development moved north to Broadway, the area filled with gambling halls and brothels. It was revitalized in the 1970s. Buildings in the Gaslamp Quarter Back to Historic Sites Back to The Top 10 of Everything Back to The Top 10 of Everything # ARCHITECTURAL HIGHLIGHTS ## 1. San Diego County Administration Center 1600 Pacific Hwy • Open 8am–5pm Mon–Fri Google Map Four architects responsible for San Diego's look collaborated on this civic landmark. What began as a Spanish-Colonial design evolved into a more "Moderne" 1930s style with intricate Spanish tile work and plaster moldings on the tower. ## 2. Louis Bank of Commerce Google Map Builders of the Hotel del Coronado, the Reid brothers can also take credit for one of the architectural treasures of the Gaslamp Quarter: a stately, four-story twin-towered Victorian structure _(seeLouis Bank of Commerce)_. Built in 1888, it was San Diego's first granite building. Of special merit are the ornate bay windows that project from the facade. ## 3. California Tower and Dome Google Map Bertram Goodhue designed this San Diego landmark for the Panama-California Exposition of 1915–16, using Spanish Plateresque, Baroque, and Rococo details. The geometric tile dome imitates Moorish ceramic work often seen in southern Spain. An iron weather vane in the shape of a Spanish ship tops the 200-ft (61-m) tower. California Tower and Dome ## 4. Mormon Temple 7474 Charmant Dr, La Jolla Google Map The temple of the Church of the Latter Day Saints is an ornate, futuristic structure. The golden trumpet-playing angel, Moroni, crowns one of the towers and points the way to Salt Lake City. Interiors are closed to the public. The Mormon Temple lit up at night ## 5. Hotel del Coronado Google Map Designed by James and Merritt Reid in 1887, this hotel was once the largest in the country to be built entirely of wood. Advanced for its time, the hotel had running bathroom water and telephones, as well as a birdcage elevator. ## 6. Salk Institute 10010 N. Torrey Pines Rd • 858 453 4100 • Open 8am–5:30pm Mon–Fri • Guided tours: noon Mon, Wed & Fri; adm • www.salk.edu Google Map At one of the most famous buildings in San Diego _(seeSalk Institute)_, twin six-story laboratories comprised of teak panels, concrete and glass stand across from each other, separated by a marble courtyard with a channel of water in the middle. Note architect Louis Kahn's use of "interstitial" space: mechanical devices between floors can change laboratory configurations. ## 7. El Cortez 702 Ash St Google Map This landmark was once the tallest building and most famous hotel in downtown San Diego. A glass elevator once led to the romantic Sky Room. Ornate Spanish details decorate the reinforced concrete structure, which is now a private condo building. ## 8. Geisel Library UCSD Google Map Named for famed children's author, Dr. Seuss, and designed by William Pereira, the library at UCSD has tiers of glass walls supported by reinforced concrete cantilevers. Filmmakers have used it as a backdrop for sci-fi shows. ## 9. Westfield Horton Plaza Google Map Inside Westfield Horton Plaza is a wonderful hodgepodge of bridges and ramped walkways connecting six staggered levels, embellished with towers and cupolas. Its distinctive sherbet color scheme has been copied on many renovation projects throughout San Diego. Clock at the Westfield Horton Plaza ## 10. Cabrillo Bridge Google Map Built as an entryway to the 1915–16 Panama-California Exposition, this cantilevered and multiple-arched bridge has a 1,500-ft (457-m) span. The best view of the bridge, especially during Christmas, is from the 163 Freeway below. ### TOP 10 PUBLIC ART SIGHTS #### 1. Guardian of Water A 23-ft (70-m) high granite sculpture depicts a pioneer woman. **Guardian of Water sculpture** #### 2. Westfield Horton Plaza Fountain Flowing water and electric lights were technological breakthroughs in 1909. Plaques honor city notables. #### 3. Tunaman's Memorial A bronze sculpture of three tunamen casting their lines. #### 4. Magic Carpet Ride The "Cardiff Kook" surfer statue is often elaborately decorated by pranksters. #### 5. The Cat in the Hat The Cat in the Hat looks over Dr. Seuss' shoulder in this bronze sculpture. #### 6. Surfhenge Imperial Beach Pier Surfboards pay tribute to the surf gods. #### 7. Woman of Tehuantepec House of Hospitality A 1,200-lb (544-kg) piece of limestone is sculpted into an Aztec woman. #### 8. Sun God A fiberglass bird stretches its wings atop a 15-ft (5-m) concrete arch. #### 9. Paper Vortex San Diego International Airport A paper airplane is artfully transformed into an origami crane. #### 10. Homecoming Navy Pier, Harbor Drive A bronze sculpture depicts a sailor and his family in a homecoming embrace. Back to Architectural Highlights Back to The Top 10 of Everything Back to The Top 10 of Everything # MUSEUMS AND ART GALLERIES ## 1. Museums of Balboa Park Google Map Housed in stunning structures of Spanish-Colonial, Mayan, and Aztec designs, exhibits at these acclaimed museums constantly change, making Balboa Park a year-round attraction. Enjoy fine art, photography, aerospace, anthropology, model trains, and much more. San Diego Museum of Art, Balboa Park ## 2. Museum of Contemporary Art Google Map The most important contemporary art trends are presented at this museum. Docent-led tours, lectures, and special family nights make art accessible to all. The museum's flagship facility _(seeMuseum of Contemporary Art)_ is at the former oceanfront home of Ellen Browning Scripps, with a satellite location downtown. ## 3. San Diego Chinese Historical Museum 404 3rd Ave • 619 338 9888 • Open 10:30am–4pm Tue–Sat, noon–4pm Sun • Adm • www.sdchm.org Google Map A wide range of artifacts such as ceramics, bone toothbrushes, and old photographs document a fascinating slice of San Diego's history in this Spanish-style building that once served as a Chinese mission. Of note is the ornate bed that once belonged to a Chinese warlord. In the back garden is a koi pond. ## 4. Tasende Gallery 820 Prospect St, La Jolla • 858 454 3691 Google Map This gallery presents international contemporary artists. Discover the colorful works of Gaudi-influenced artist Niki de Saint Phalle, the pen-and-ink drawings of Mexico's José Luis Cuevas, and the surrealist paintings of Chilean Roberto Matta, among others. ## 5. Maritime Museum of San Diego 1492 N. Harbor Dr • 619 234 9153 • Open Jun–Aug: 9am–9pm daily; Sep–May: 9am–8pm daily • Adm • www.sdmaritime.org Google Map This fascinating museum pays tribute to the men and ships that so influenced the history and life of San Diego. A range of exhibitions educate and entertain, while several anchored ships can be boarded and explored. The _Star of India_ tall ship, MMSD ## 6. Sparks Gallery 530 6th Ave • 619 696 1416 Google Map Housed in the historic Sterling Hardware Building, this is one of San Diego's top galleries. Exhibits span a range of mediums, from photography to sculpture and painting, all by contemporary artists from Southern California. ## 7. Quint Gallery 7547 Girard Ave, La Jolla • 858 454 3409 Google Map Since 1981, Mark Quint has brought outstanding contemporary artwork to San Diego. Collaborations with collectors, artists, and curators have garnered global acclaim. Exhibited in the 3,000-sq-ft (280-sq-m) space are works by traditional and cutting-edge artists, local and international. ## 8. Michael J. Wolf Fine Arts 363 5th Ave • 619 702 5388 Google Map The oldest gallery in the Gaslamp Quarter features works of emerging US and international contemporary artists. See the urban landscapes of Luigi Rocca, mixed media paintings by Josue Castro, and portraits by Rolling Stone Ronnie Wood. ## 9. Joseph Bellows Gallery 7661 Girard Ave, La Jolla • 858 456 5620 Google Map This intimate gallery showcases important vintage prints and contemporary photographs. Three exhibition areas display photography of a superb quality and host a busy program of themed and solo shows. Both renowned and emerging photographers are represented, and past exhibitions have included work by Ansel Adams, Ave Pildas, Dana Montlack, and Wayne Gudmundson. ## 10. Spanish Village Art Center 1770 Village Pl • 619 233 9050 • Open 11am–4pm daily • www.spanishvillageart.com Google Map In a Spanish village-like atmosphere adobe houses from the 1935–6 California-Pacific Exposition have been turned into lovely artists' studios, where you can shop or even take a lesson from the artists. Spanish Village Art Center Back to Museums and Art Galleries Back to The Top 10 of Everything Back to The Top 10 of Everything # BEACHES ## 1. Windansea Beach Google Map Legendary among surfers for its shorebreaks, this beach found literary fame as the setting for Tom Wolfe's _The Pumphouse Gang_. The beach gets a little wider south of the "Shack," a local landmark, but those with small children should still take care. The rugged rocks of Windansea Beach ## 2. Ocean Beach Google Map The laid-back atmosphere of Ocean Beach attracts not just locals but also some out-of-towners. Surfers usually go out around the pier, and swimmers farther down the beach. There tends to be a strong rip current at the beach, so it is best not to swim out of sight from a lifeguard station. The beach has plenty of facilities, including showers, several picnic tables, and volleyball courts. ## 3. Pacific Beach Google Map A beach-going spirit fills the air as skateboarders, joggers, and cyclists cruise the promenade parallel to the beach. Chances to people-watch are endless, since Pacific Beach has a reputation for being the place to hang out. Walk out to the Crystal Pier Hotel, past the bungalows, to watch surfers shooting the curl. ## 4. La Jolla Shores Google Map A great family beach with sunbathers, Frisbee-throwers, and boogie-boarders spread out along a broad, sandy white strip lapped by gentle surf, it gets crowded in the summer. Kellogg Park, alongside part of the beach, is a good picnic area for those who forgot their towels. The La Jolla Underwater Ecological Reserve is just offshore, so divers are usually out in the water. ## 5. Torrey Pines State Beach Google Map Miles of sandy beaches and secret coves nestle beneath towering sandstone cliffs. During low tide, tide pools offer a glimpse into life under the sea. Torrey Pines is a San Diego favorite because of its lack of crowds, intimacy, and natural beauty. Parking is available at the Torrey Pines State Reserve or by the gliderport on top of the cliff. ## 6. Dog Beach North end of Ocean Beach at San Diego River Google Map Leashes optional! Your dog can run loose to chase after balls, Frisbees, and other dogs with joyous abandon. The beach is open 24 hours, so you can even come here for a midnight swim. Posts with handy plastic bags help you pick up the aftermath. Pets playing at Dog Beach ## 7. Black's Beach Google Map This beach is best known for its nude sunbathers. Access to the beach, which is between Torrey Pines State Beach and La Jolla Shores, is either down an unstable 300-ft (91-m) cliff or via a 1-mile (1.6-km) walk along the beach from either the north or south during low tide. Surfers find the southern end of the beach ideal, as do the hang-gliders who launch off from the cliffs above. ## 8. Coronado Central Beach Google Map Between the iconic Hotel del Coronado and North Island Naval Air Station, along mansion-lined Ocean Avenue, Coronado's municipal beach has been ranked as one of America's best. Its wide swath of golden sand invites sunbathing, sandcastle building, and family fun. Areas are designated for surfers, swimmers, and fishers, and the north end is for dogs and their humans. US Navy SEALS occasionally pop out of the ocean while training. ## 9. Mission Beach Google Map At this popular beach, sunburned, sandy bodies vie for space upon the sand, volleyballs and Frisbees fly overhead, and skateboarders and cyclists try to balance drinks and MP3 players as they careen down the board-walk. If the beach scene gets overwhelming, Belmont Park is just a block away. ## 10. Mission Bay Beaches Google Map Protected from the waves of the Pacific Ocean, 27 miles (43 km) of shoreline, including 19 miles (30 km) of sandy beaches, coves, and inlets, offer idyllic picnic locations. On sunny days, the water is filled with sailboats, kayaks, waterskiers, windsurfers, and rowers. Bike paths wind for miles along the shoreline, and wide grassy areas and ocean breezes make flying kites ideal. Kayakers at a Mission Bay beach Back to Beaches Back to The Top 10 of Everything Back to The Top 10 of Everything # GARDENS AND NATURE RESERVES ## 1. Torrey Pines State Reserve 12600 N. Torrey Pines Rd • 858 755 2063 • Open 7:15am–sunset daily • Parking fee $12–$20 Google Map This stretch of California's wild coast offers a glimpse into an ancient ecosystem. Wildflowers bloom along hiking trails that lead past rare Torrey pines and 300 other endangered species. Viewing areas overlook sandstone cliffs to the beach. Spot quail, mule deer, and coyotes. Hikers at Torrey Pines State Reserve ## 2. Balboa Park Google Map This landmark destination _(seeBalboa Park)_ and heart of San Diego offers an array of superb activities. Visit its gardens and museums for inspiration, to play sports, or to watch a concert. Although crowded, Sundays are good days to experience the community at leisure. The Lily Pond at Balboa Park ## 3. Spreckels Park Coronado Google Map Named after John D. Spreckels, who donated the land, the park hosts Sunday concerts during the summer as well as art and garden shows. An old-fashioned bandstand, shady trees, green lawns, and picnic tables complete the picture of a small-town community center. ## 4. Mission Trails Regional Park 1 Father Junípero Serra Trail Google Map At one of the country's largest urban parks, hiking and biking trails wind along rugged hills and valleys. The San Diego River bisects the park, and a popular trail leads to the Old Mission Dam. The energetic can hike up Cowles Mountain, San Diego's highest peak at 1,591 ft (485 m). ## 5. Los Peñasquitos Canyon Preserve 12020 Black Mountain Rd Google Map Archeologists discovered artifacts of the prehistoric La Jolla culture in this ancient canyon. You can also explore the adobe home of San Diego's first Mexican land grant family. Between two large coastal canyons, trails lead past woodland, oak trees, chaparral, and a waterfall. ## 6. Kate O. Sessions Memorial Park 5115 Soledad Rd, Pacific Beach Google Map Named in honor of the mother of Balboa Park, this peaceful spot, with a terrific view of Mission Bay, is a popular area for picnics. Take advantage of the ocean breezes to rediscover kite flying. Walking trails extend 2 miles (3 km) through a canyon lined with native coastal sage. ## 7. Mission Bay Park 2688 E. Mission Bay Dr Google Map This aquatic wonderland _(seeMission Bay Park)_ offers every watersport conceivable. You can also bicycle, play volleyball, jog, or nap on the grass. Excellent park facilities include boat rentals, playgrounds, fire rings, and picnic tables. ## 8. Ellen Browning Scripps Park Google Map Broad lawns shaded by palms and Monterey cypress trees stretch along the cliffs from La Jolla Cove to Children's Pool. Promenades offer stunning views of the cliffs and beach. Ellen Browning Scripps Park ## 9. Embarcadero Marina Park Marina Park Way Google Map Join the downtown workers for some fresh air and sunshine. Wide grassy areas and benches give you solitude to enjoy the sweeping views of the harbor. During summer, concerts are held on the lawn. ## 10. Tijuana River National Estuarine Research Reserve 301 Caspian Way, Imperial Beach Google Map Serene hiking paths wind through fields of wildflowers and plants. More than 300 species of migratory birds stop by at different times of the year. A visitor center offers information to enhance your visit. ### TOP 10 SPECTACULAR VIEWS #### 1. Coronado Bridge Coronado, downtown, and San Diego harbor sparkle both day and night. **Boats at Coronado Bridge** #### 2. Point Loma The breathtaking view from the peninsula's end _(seePoint Loma)_ takes in the city, harbor and Pacific Ocean. #### 3. Mount Soledad San Diego's most glorious view takes in Coronado, Point Loma, downtown, the valleys, and Mission Bay. #### 4. Bertrand at Mr. A's Planes on approach to Lindbergh Field make dining here a visual affair. #### 5. Manchester Grand Hyatt San Diego The 40th-floor lounge offers views of San Diego Bay and Coronado. #### 6. Torrey Pines State Reserve The view down the wind-eroded cliffs and across the Pacific is magnificent. #### 7. Eddie V's Prime Seafood Every table here has water views, but the best spot is the upstairs patio with live jazz. #### 8. Flying into San Diego You can almost see what people are having for dinner as you fly in directly over downtown San Diego. #### 9. Presidio Park A panoramic view extends from the freeways in Mission Valley below to Mission Bay and the Pacific. #### 10. Ferries in San Diego Harbor On a sunny day, nothing beats a ferry ride on the harbor, gazing at the white sailboats against a blue sky. Back to Gardens and Nature Reserves Back to The Top 10 of Everything Back to The Top 10 of Everything # OUTDOOR ACTIVITIES ## 1. Horseback Riding Happy Trails: 2180 Monument Rd; 619 947 3152; www.ponylandsandiego.com Guided horseback rides are available on trails, through parks, and on the beach. The South Bay area offers the only beach where you can take an exhilarating ride on the sand and in the waves. There are also pony rides for children, hayrides, and romantic carriage rides. ## 2. Hiking Hiking is available in every environment imaginable. Los Peñasquitos Canyon Preserve and Mission Trails Regional Park offer trails of varying difficulty through their canyons and valleys; the trails of Torrey Pines State Reserve and Tijuana River National Estuarine Research Reserve pass near the ocean. The San Diego Natural History Museum hosts guided nature tours. ## 3. Cycling Bikes & Beyond: 1201 1st St, Coronado; 619 435 7180 • iCommute: dial 511 and say "iCommute"; www.icommutesd.com With over 300 miles (483 km) of bikeways, San Diego is a very cycle-friendly city. iCommute's map details bike rides around the city and county, and is available online. Cycling in the sunshine ## 4. Sailing and Boating Seaforth Boat Rentals: 1641 Quivira Rd, Mission Bay; 888 834 2628 Whether at Mission Bay or the Pacific Ocean, you're bound to see something that floats. Sailing enthusiasts can rent almost any type of boat, some complete with a crew, champagne, and hors d'oeuvres. Sailors enjoying the calm waters ## 5. Surfing San Diego Surfing Academy: 800 447 7873 San Diego's beaches are famous for surfing. The months with the strongest swells are in late summer and fall, ideally under offshore wind conditions. Designated surfing areas can be found at every beach. ## 6. Swimming The Plunge: 3115 Ocean Front Walk; 858 228 9300; adm Nothing beats an ocean dip, though the temperatures seldom exceed 70° F (21° C) even in the summer. Alternatively, most hotels have pools. The Plunge at the Wave House Athletic Club at Mission Beach is a great public pool. ## 7. Sportfishing Seaforth Sportsfishing: 1717 Quivira Rd, Mission Bay; 619 224 3383 Albacore, yellowfin, and dorado are just some of the fish in the offshore waters. Summer and fall are the best months, and half-, full-, and multiple-day trips are all available. A fishing license is not required to fish off the public piers. ## 8. Golfing San Diego CVB: 619 236 1212; www.sandiego.org With San Diego's perfect climate and amazing views, over 90 public courses and resort hotels offer some of the best golfing in the country. Tee times may be hard to get, so reserve early. The San Diego Convention and Visitors Bureau (CVB) has a golf guide. A team of golfers at a sand trap ## 9. Diving San Diego Ocean Enterprises: 7710 Balboa Ave; 858 565 6054 The best spots for diving off the coast are the giant kelp forests of Point Loma and the La Jolla Underwater Ecological Reserve. Common sealife includes lobsters and garibaldi – the official state marine fish. ## 10. Skateboarding Cheap Rentals: 3689 Mission Blvd; 858 488 9070; www.cheap-rentals.com Mission Bay and Pacific Beach are the best areas to enjoy the miles of pathway shared by rollerbladers and joggers. Some areas prohibit skating, so watch out for the signs. ### TOP 10 SPECTATOR SPORTS, TEAMS AND VENUES #### 1. Rodeos Catch professional rodeo action at Lakeside, Poway, and Ramona. #### 2. San Diego Padres 100 Park Blvd • 619 795 5000 Petco Park hosts the National League Padres' baseball team. #### 3. San Diego State University Aztecs Take the San Diego Trolley out to Qualcomm Stadium. #### 4. San Diego Gulls Ice Hockey 3500 Sports Arena Blvd • 619 224 4625 The San Diego Gulls play in the ECHL Premier AA Hockey League. #### 5. Del Mar Thoroughbred Club 2260 Jimmy Durante Blvd, Del Mar • 858 755 1141 Celebrities and horseracing fans head here to watch the thoroughbreds racing. #### 6. Hang gliding/Paragliding Keen hang gliders and paragliders take off from the high ocean cliffs located north of La Jolla. #### 7. San Diego Polo Club 14555 El Camino Real, Rancho Santa Fe • 858 481 9217 • Adm Attend polo matches on Sundays. #### 8. Golf Watch the annual golf tournaments at Torrey Pines and La Costa. #### 9. Mission Bay Park Mission Bay hosts many boating events. #### 10. San Diego Chargers 619 280 2121 Catch this American Football Conference team playing at Qualcomm Stadium. **San Diego Chargers** Back to Outdoor Activities Back to The Top 10 of Everything Back to The Top 10 of Everything # OFF THE BEATEN PATH ## 1. Paragliding at Torrey Pines Torrey Pines Gliderport: 2800 Torrey Pines Scenic Dr, La Jolla; 858 452 9858 Google Map Soar off the spectacular cliffs of Torrey Pines. In your first lesson, you'll receive basic instructions followed by 20–30 minutes of gliding with your instructor. If you'd like to watch for a while before making that exhilarating plunge, a viewing area and café sit on the cliff's edge. Paragliding at Torrey Pines ## 2. Gambling at Native American Casinos Barona Resort & Casino: 1932 Wildcat Canyon Rd, Lakeside; 619 443 2300 • Viejas Casino: 5000 Willows Rd, Alpine; 619 445 5400 Google Map Google Map Feeling lucky? A dozen casinos promise non-stop Las Vegas-style action and jackpots galore. Starting as a small bingo hall 20 years ago, Native American gaming is now a billion-dollar industry of resort hotels, concert venues, and golf courses. Today, San Diego County has the highest concentration of casinos in the state of California. Thousands of slot machines, video poker, and gaming tables in immense, striking buildings will satisfy the gambler in you. ## 3. Rent a Harley Davidson Eagle Rider of San Diego: 2400 Kettner Blvd; 619 446 0022 Google Map Born to be wild? Don your jeans and a black leather jacket and rent a bike for a day. You won't be alone: droves of bikers take to the highway, especially on weekends. The backcountry of San Diego County is a prime area for powering a Fat Boy, Road King, or Dyna Wide Glide down the road. ## 4. Biplane Flying San Diego Air Tours: Montgomery Field; 800 359 2939 • www.airtoursofsandiego.com Google Map Two of you sit in the front cockpit of a beautifully restored 1920s biplane wearing helmet and goggles, and soar over beaches, lakes, golf courses, and houses, while the pilot flies behind. The _Beech Belle_ , a restored World War II VIP biplane, is great for that special occasion. If you're looking for an extra thrill, the pilot will put you through aerobatic loops and rolls, or you can take the controls in Top Dog Air Combat. ## 5. Roar and Snore at San Diego Zoo Safari Park Google Map On weekends from May through November, sleep alongside wild animals just as you would in an African game park. Tents that hold up to four persons are provided. Programs include guided discovery hikes and animal encounters, an open-flame grilled dinner, campfire snacks, special late night programs, and a pancake breakfast before a gorgeous sunrise. Reservations are essential. Deer, San Diego Zoo Safari Park ## 6. Tall Ship Adventure Sail Google Map Take a three-hour adventure aboard _The Californian_ , the State of California's official tall ship and a replica of a Gold Rush-era cutter. Passengers can assist in manning the helm, hauling the line, and the end-of-day cannon salute. Crew members tell whaling and battle tales and of San Diego's sailing past. Booking is advised; departure is from the Maritime Museum. ## 7. UFO Spotting in East County Google Map Several San Diego groups take UFO (Unidentified Flying Object) sightings seriously. The best places to spot UFOs are in Borrego Springs and Ocotillo Wells. Given San Diego's strong military presence, that saucer in the sky might well be a secret government mission. ## 8. Diving at Wreck Alley Google Map Just off Mission Beach is the final resting place for the _Yukon_ , a decommissioned Canadian warship, the coastguard cutter _Ruby E_ , and a barge, all deliberately sunk to create an artificial reef. A research tower here collapsed on its own, with its dangling wires and protrusions only adding to the otherworldly, ethereal atmosphere. Thousands of invertebrate marine creatures live here. Charter boats will take you out. ## 9. Hot-Air Ballooning California Dreamin': 33133 Vista del Monte Rd, Temecula; 800 373 3359; www.californiadreamin.com Google Map You can watch or take part in inflating a brilliantly colored balloon. Hop in the basket and begin to float over the valleys and hills with a glass of champagne in hand. Balloon rides take flight above the Temecula wine country at sunrise and the Del Mar coastline at sunset. Hot-air balloon ## 10. Steam Train Rides Chula Vista Live Steamers: Rohr Park, 4548 Sweetwater Rd, Bonita; 619 397 6197; www.chulavistalivesteamers.org Google Map Run by ordinary people who happen to love all things steam – lawn mowers, tractors, cranes, boats, and trains, Chula Vista is dedicated to maintaining the tracks of the Sweetwater & Rohr Park Railroad. The members offer free rides (donations appreciated) on the steam locomotive on the second weekend of each month. Back to Off the Beaten Path Back to The Top 10 of Everything Back to The Top 10 of Everything # CHILDREN'S ATTRACTIONS ## 1. San Diego Zoo Google Map During seasonal holidays and summer, Dr. Zoolittle presents his entertaining science shows and guest performers delight the crowds. The zoo also offers summer camps and art classes, while special family events are held throughout the year. Gorilla at San Diego Zoo ## 2. Balboa Park Carousel Balboa Park • Adm Google Map Kids will love the carved animals and hand-painted murals of this unique 1910 carousel, right by the zoo. Its Brass Ring game gives riders the chance to win a free turn. ## 3. LEGOLAND® Google Map Children are fascinated by the 30 million plastic bricks fashioned into famous landmarks and life-sized African animals. In Fun Town, kids can drive electric cars or pilot a helicopter; at the Imagination Zone, they can build robots. Other attractions here _(seeLegoland)_ include a 4-D movie adventure and a waterpark. ## 4. Adventure Kids in Egypt at the San Diego Museum of Man Google Map On the museum's second floor, kids dress up as pharaohs and learn about ancient Egypt by building a pyramid, deciphering hieroglyphics, and listening to the god Anubis explain the mummification process. At a re-creation of an archeological dig, kids dig through sand for treasure and also learn to identify an artifact's age. ## 5. Marie Hitchcock Puppet Theater in Balboa Park Balboa Park • 619 544 9203 • Adm • www.balboaparkpuppets.com Google Map Named after the park's beloved and skilled "puppet lady," the Balboa Park Puppet Guild houses a wonderful collection of marionettes and hand, rod, and shadow puppets. The Magic of Ventriloquism, Pinocchio, and Grimm's classics are some of the shows here. ## 6. Harbor Seal-Watching at Children's Pool Coast Blvd & Jenner St, La Jolla Google Map Children used to swim at this sheltered cove, but harbor seals had much the same idea. The seals are protected by federal law so the beach is now closed, and children must view the entertaining crowds of marine animals swimming and sleeping from behind a rope. ## 7. Reuben H. Fleet Science Center 1875 El Prado • 619 238 1233 • Open 10am–6pm daily (to 8pm Sat) • Adm • www.rhfleet.org Google Map Science can be fun for all. At Kid City, children aged 2–5 can play with conveyor belts, air chutes, and colorful foam blocks. Older kids go wild building complex structures at Block Busters! and enjoy other hands-on areas. In the Virtual Zone, kids can explore symmetry in time as a video camera records movement. ## 8. San Diego Zoo Safari Park Google Map This park has more than 3,000 wild and endangered animals from Africa, Europe, Asia, North and South America, and Australia. Herds of animals roam freely in enclosures that replicate their natural habitats. Compatible animals are mixed, allowing visitors to observe their interactions. Kids will enjoy the safari adventures – ziplines, cheetah runs, and an open-air caravan are among the most popular attractions. ## 9. Belmont Park 3190 Mission Blvd • 858 488 1549 • Adm for rides Google Map This old-fashioned fun zone keeps the kids entertained for hours. They can board the Giant Dipper roller coaster, take a ride on the Tilt-a-Whirl, and go on an antique carousel; enjoy the Bumper Cars; or climb high above the ground on the challenging Sky Ropes Adventure. For indoor adventures, there's Laser Tag, Laser Maze, rock climbing, and mini golf. The Giant Dipper at Belmont Park ## 10. Birch Aquarium at Scripps 2300 Expedition Way • 858 534 3474 • Open 9am–5pm daily • Adm • www.aquarium.ucsd.edu Google Map Coral reefs, seahorses, octopi, and undulating jellyfish have a high ooh-and-ah factor for kids. The aquarium presents special hands-on activities, scavenger hunts, and craft workshops throughout the year, among more than 30 tanks filled with brilliantly colored fish. Kids love the sea-dragon display and the baby seahorse nursery. Back to Children's Attractions Back to The Top 10 of Everything Back to The Top 10 of Everything # PERFORMING ARTS VENUES ## 1. The Old Globe 1363 Old Globe Way • 619 234 5623 • Check event schedule • www.theoldglobe.org Google Map Every year 250,000 people attend performances at the three theaters in this complex: the 600-seat Old Globe Theatre, the intimate White Theatre, and the outdoor Davies Theatre, which hosts a Shakespeare festival in the summer. The Old Globe, built in 1935 ## 2. La Jolla Playhouse La Jolla Village Dr at Torrey Pines Rd, UCSD Campus, La Jolla • 858 550 1010 Google Map Gregory Peck, Mel Ferrer, and Dorothy McGuire founded this theater in 1947. All the Hollywood greats once performed here. Now affiliated with UCSD, many plays that debuted here have gone on to win the Tony. ## 3. San Diego Civic Theatre 1100 3rd Ave • 619 570 1100 Google Map If you missed the latest Broadway show, dont worry: chances are the touring company will perform at this grand theater. Featuring local talent and the world's most acclaimed stars, the San Diego Opera stages four annual productions here. ## 4. Lyceum Theatre 79 Horton Plaza • 619 544 1000 Google Map Two theaters are part of the San Diego Repertory Theatre complex: the 550-seat Lyceum and the 270-seat Lyceum Space Theatre. Shows run from the experimental to multilingual performances and Shakespeare with a modern slant. In addition, the theater hosts visiting companies and art exhibitions. ## 5. Starlight Bowl 2005 Pan American Plaza • 619 232 7827 • www.starlighttheatre.org Google Map The San Diego Civic Light Opera performs summer Broadway shows in this idyllic Balboa Park setting. It is under a flight path, so plane-spotters cue the performers when to freeze. Audiences good-humoredly accept the interruptions. Humphrey's Concerts by the Bay ## 6. Humphrey's Concerts by the Bay 2241 Shelter Island Dr, Shelter Island • 619 224 3577 Google Map From May to October, jazz, rock, comedy, blues, folk, and world music are performed in an outdoor 1,350-seat amphitheater next to San Diego Bay. Special packages to Humphrey's Restaurant and Humphrey's Half Moon Inn are available to patrons. ## 7. Theatre in Old Town 4040 Twiggs St • 619 337 1525 Google Map Only 250 amphitheater-style seats wrap around the stage of this theater in an Old Town barn. Leading local company Cygnet Theatre performs dramas, musicals, and comedies such as _The History Boys_ , _A Little Night Music_ , and _A Christmas Carol_. ## 8. Spreckels Theatre 121 Broadway • 619 235 9500 Google Map Commissioned by John D. Spreckels, this Neo-Baroque landmark presents theatrical shows and concerts. Murals, Classical statuary, and an elegant marble lobby give the theater an aura of old San Diego. Ornate interior, Spreckels Theatre ## 9. Sleep Train Amphitheatre 2050 Entertainment Cir, Chula Vista • 619 671 3500 Google Map Major pop artists perform from March to October in this notable open-air amphitheater. Great sight lines and giant video screens ensure a good view. There is seating for 10,000 people and the grass can accommodate another 10,000. ## 10. Copley Symphony Hall 750 B St • 619 235 0804 Google Map Formerly known as Fox Theatre, a Rococo-Spanish Renaissance extravaganza built in 1929, this venue was to be destroyed until developers donated it to the San Diego Symphony in 1984. Since restored, the hall hosts excellent classical music concerts. ### TOP 10 MOVIES FILMED IN SAN DIEGO #### 1. Citizen Kane, 1941 Director and actor Orson Welles used the California Tower and Dome in Balboa Park as Xanadu. #### 2. Sands of Iwo Jima, 1949 John Wayne raced up a hill at Camp Pendleton, the setting for the World War II battle in the acclaimed film. **_Sands of Iwo Jima_ , 1949** #### 3. Some Like It Hot, 1959 The distinctive structure of the Hotel del Coronado formed a backdrop for Marilyn Monroe, Jack Lemmon, and Tony Curtis. #### 4. MacArthur, 1971 Gregory Peck, born in La Jolla in San Diego, played the eponymous general on Silver Strand State Beach. #### 5. The Stunt Man, 1980 This Peter O'Toole film had several stuntmen jumping off the roof of the city's Hotel del Coronado. #### 6. Top Gun, 1986 Tom Cruise chatted up Kelly McGillis at the iconic Kansas City Barbecue, in the harbor district. #### 7. Titanic, 1996 Filmed in an enormous, specially built water tank at Rosarito Beach, Mexico. #### 8. Almost Famous, 1999 Nothing much had to be changed for the Volkswagen and Birkenstock look of 1970s Ocean Beach. #### 9. Pearl Harbor, 2000 Kate Beckinsale proved her love for Ben Affleck by bidding him goodbye at the San Diego Railroad Museum in Campo. #### 10. Traffic, 2000 Along with scenes of San Diego and Tijuana, _Traffic_ 's car explosion took place in the judges' parking lot of the Hall of Justice. Back to Performing Arts Venues Back to The Top 10 of Everything Back to The Top 10 of Everything # NIGHTLIFE ## 1. Prohibition 548 5th Ave • Closed Wed; reservations through website only • Adm Google Map A small, intimate jazz bar with perfect martinis and a laid-back crowd that comes for the great music and exceptional service. The bar has the feel of a private members club but it welcomes all. Plush interior of Prohibition ## 2. Onyx Room 852 5th Ave • 619 235 6699 • Closed Mon, Wed & Sun • Adm Thu–Sat Google Map At this chic basement club, order the cocktail of the month and settle back in a vibrant lounge atmosphere. Upstairs is the Onyx's sister bar Thin, where the unique "engineered" drinks and atmosphere are the epitome of urban cool. ## 3. Fluxx 500 4th Ave • 619 232 8100 • Open 9pm–2am Thu–Sat • Adm • Dress code applies Google Map More of an experience than a club, Fluxx showcases top music events, custom sound and lighting, a huge dance floor, a VIP section, and bottle service. DJs mix up hip-hop, top 40, rock, and electronic sounds. ## 4. El Dorado Cocktail Lounge 1030 Broadway • 619 237 0550 • Adm Google Map This classy boutique martini lounge with Wild West bordello-themed decor offers an amazing variety of entertainment, such as dance parties, DJs, live music, and art shows. The nightly events, top-notch service, and exceptional variety of drinks, including specialty cocktails, draw in the crowds. ## 5. RoofTop600 600 F St • 619 814 2055 • Adm Google Map Located inside the Andaz Hotel, this nightclub is a glittering nightspot with sexy dancers from Thursday to Saturday. An open-air rooftop lounge combines DJ sets with private cabanas and panoramic views of the downtown skyline. ## 6. Cafe Sevilla 353 5th Ave • 619 233 5979 • Adm Google Map This restaurant-nightclub offers everything Latin. Tango and flamenco dinner shows are held in the Spanish restaurant, while instructors teach salsa and samba downstairs. You can practice your moves to the live bands that perform afterward. The basement becomes a Latin/Euro dance club on Friday and Saturday nights. Latin-style decor at Cafe Sevilla ## 7. Casbah 2501 Kettner Blvd • 619 232 4355 • Adm Google Map Underground alternative rock rules at this grungy club. Famous and future bands turn up the decibels every night. Past headliners have included The Dillinger Escape Plan, The Kills, Futuristic, and Monsieur Periné. ## 8. The Tipsy Crow 770 5th Ave • 619 338 9300 • Adm after 9:30pm Thu & after 8:30pm Fri & Sat Google Map Set in a historic building, the Tipsy Crow occupies three floors. Upstairs are marble fireplaces, tapestries, and a library; on the ground level, a long mahogany bar serves drinks of choice; while the downstairs hosts live music and the Gaslamp Comedy Show. Exterior of the Tipsy Crow ## 9. Humphrey's Backstage Live 2241 Shelter Island Dr • 619 224 3577 • Adm for most bands Google Map Enjoy a variety of live music nightly at this waterfront lounge with an unbeatable view of the bay. Come early for a terrific happy hour. ## 10. National Comedy Theatre 3717 India St • 619 295 4999 • Adm Google Map Held on Fridays and Saturdays, the National Comedy Theatre's improvisational shows are family-friendly and popular. The audience chooses a game for each show, and decides the winner. ### TOP 10 GAY AND LESBIAN VENUES #### 1. Spin 2028 Hancock St • 619 294 9590 Three floors of bars and a dance club. **The main dancefloor at Spin** #### 2. Cheers of San Diego 1839 Adams Ave • 619 298 3269 This dependably divey beer and wine bar has been in business since 1982. #### 3. The Brass Rail 3796 5th Ave • 619 298 2233 San Diego's oldest gay bar. #### 4. Urban Mo's Bar & Grill 308 University Ave • 619 491 0400 Rowdy, hetero-friendly drag club. #### 5. Pecs 2046 University Ave • 619 296 0889 Gay Harley-Davidson enthusiasts frequent this popular bar. #### 6. The Gossip Grill 1440 University Ave • 619 260 8023 A lesbian restaurant and bar with a sensual atmosphere and great food. #### 7. Number One Fifth Ave 3845 5th Ave • 619 299 1911 Video bar, pool table, and patio. #### 8. Numbers 3811 Park Blvd • 619 294 7583 Pool tables and two dance floors. #### 9. Rich's 1051 University Ave • 619 295 2195 Dancing go-go boys and girls. #### 10. Lips San Diego 3036 El Cajon Blvd • 619 295 7900 Drag shows and crowded Sunday brunches, with a cover charge. Back to Nightlife Back to The Top 10 of Everything Back to The Top 10 of Everything # CAFÉS AND BARS ## 1. Cafe-Bar Europa – The Turquoise 873 Turquoise St • 858 488 4200 Google Map Reminiscent of the bars of Bohemian Europe, this Pacific Beach café exudes tradition in a high-speed world. You can even philosophize over a glass of absinthe. Tapas are the featured fare in the restaurant, and live entertainment is scheduled most nights. ## 2. La Sala La Valencia Hotel, La Jolla Google Map Sitting in the hotel's lobby lounge amid Spanish mosaics, hand-painted ceilings and murals, red-tiled floors, and huge palms is like being in a Spanish palace. Order a drink and gaze out at the ocean; a pianist plays in the evening. On sunny days, take advantage of the outside tables. ## 3. Habano's Café & Cigar Lounge 3111 Hancock St • 619 692 0696 Google Map Buy a cigar from the huge stock in the walk-in humidor, then light up in a rustic setting with big, comfortable furniture or on the patio. There are also craft beers, espresso, tapas, and panini. Bands play on weekends. ## 4. Bean Bar 1068 K St • 503 358 8554 Google Map Baristas make your coffee from the finest beans at this East Village neighborhood café, small in size but big on quality. Service is friendly, beverages are diligently prepared, and the proprietors firmly believe in direct trade. ## 5. Lestat's Coffee House 3343 Adams Ave • 619 282 0437 Google Map Named after the character in Anne Rice's vampire novels, this café in a hip spot serves coffee and pastries 24 hours a day. Local bands entertain in the evening. There's free Wi-Fi, too. Lestat's Coffee House ## 6. The Field Irish Pub 544 5th Ave • 619 232 9840 Google Map Literally imported from Ireland, the wood walls, flooring, decorations, and assorted curios were shipped over and reassembled. Even the bartenders and waitresses are the real thing, not to mention the Guinness. Grab a sidewalk seat on Fifth Avenue or try for a window seat upstairs. The pub food is also great. St. Patrick's Day at the Field Irish Pub ## 7. Twiggs Bakery & Coffee House 4590 Park Blvd • 619 296 0616 Google Map Enjoy a latte and a snack in this fun café. It's packed all day with locals. On the second and fourth Mondays of each month, you'll find poetry readings being held here. ## 8. Top of the Hyatt Google Map Window seats at this bar in the Manchester Grand Hyatt hotel are at a premium at sunset, offering breathtaking views of the bay, Coronado, Point Loma, and the jets over Lindbergh Field. Dark woods exude a sedate, plush atmosphere, with drink prices to match. Elegant interior of the Top of the Hyatt ## 9. Wet Stone Wine Bar & Café 1927 4th Ave • 619 255 2856 Google Map Chef/owner Christian Gomez serves bold dishes in an intimate, eclectic space with tropical plants, against a soundtrack of sultry rhythms. Carefully selected wines are available by the glass or bottle. ## 10. Waterfront Bar & Grill 2044 Kettner Blvd • 619 232 9656 Google Map San Diego's oldest tavern opened shortly after Prohibition ended. Customers at this basic watering hole ranged from laborers to lawyers, and the present clientele is still diverse. Business is brisk, the bar is fully stocked, and burgers and light fare are on the menu. ### TOP 10 BREAKFAST SPOTS #### 1. The Cottage Enjoy the freshly-baked cinnamon rolls and Belgian waffles here. **Outdoor seating at The Cottage** #### 2. Café 222 222 Island Ave • 619 236 9902 • $ Try Café 222's pumpkin waffles and French toast. #### 3. Brockton Villa Start the morning here with crêpes, omelets, or a "tower of bagel". #### 4. Crown Room Hotel del Coronado The room is legendary, and the Sunday feast amazing. #### 5. Hash House A Go Go 3628 5th Ave • 619 298 4646 • $ Locals vote this hip, award-winning café the best breakfast spot in town. #### 6. Hob Nob Hill 2271 1st Ave • 619 239 8176 • $ Enjoy waffles, omelets, and pancakes. #### 7. Broken Yoke Café 1851 Garnet Ave • 858 270 0045 • $ Choose from 30 varieties of omelets. #### 8. Kono's Café 704 Garnet Ave • 858 483 1669 • No credit cards • $ Join the line for banana pancakes and breakfast burritos. #### 9. Richard Walker's Pancake House 520 Front St • 619 231 7777 • $ More than 100 items are offered here. #### 10. The Mission 3795 Mission Blvd • 858 488 9060 • $ Breakfast is served until 3pm in this funky "Chino-Latino" café. See restaurant price categories Back to Cafés and Bars Back to The Top 10 of Everything Back to The Top 10 of Everything # RESTAURANTS ## 1. Bertrand at Mr. A's Google Map For casually elegant dining with a dazzling view, this restaurant with friendly staff is hard to beat. Inspired by contemporary French-Mediterranean cuisine, the seasonal menu of American dishes is the star here. Unusual for San Diego, there is a dress code here that asks diners to leave shorts and casual wear at home. A dining room with a view at Bertrand at Mr. A's ## 2. Island Prime Google Map Presided over by chef Deborah Scott, the scrumptious New American cuisine at Island Prime includes fresh seafood, prime steaks, mouth-watering "Deborah's Compositions," as well as fine wines. The C Level bar (with a happy hour) offers appetizers and more filling fare. ## 3. El Agave Tequileria Google Map Ancient Mexican and Spanish spices and traditions make for a unique Mexican dining experience _(seeEl Agave Tequileria)_. Shrimp, sea bass, and the filet mignon prepared with goat's cheese and a dark tequila sauce are heavenly. Mole, the distinctive blending of spices, garlic, and sometimes even chocolate, is a specialty. There are some 150 tequila selections here as well. ## 4. The Marine Room Google Map Guests can dine on exciting, romantic global cuisine derived from French classics at this restaurant. If you're not that hungry and would like to enjoy the sunset, opt for the hors d'oeuvres in the lounge. ## 5. Sushi Ota Google Map Don't be fooled by the modest exterior: this is possibly San Diego's most cherished restaurant for an authentic Japanese experience and all things sushi, as proven by the many Japanese patrons. The restaurant is also famous for its sea urchin dishes. ## 6. Baci Ristorante Google Map Classic Italian cuisine is presented in this subtly modern restaurant with Old World charm. The menu includes creative specials, as well as traditional dishes. The tuxedo-clad waiters, who have been there for years, deliver excellent service. ## 7. The Prado at Balboa Park Google Map Hand-painted ceilings, glass sculptures, and whimsical artwork adorn this atmospheric restaurant. A large terrace overlooks the gardens of Balboa Park. A variety of margaritas and drinks from around South America complement an excellent cuisine best described as Latin and Italian fusion. ## 8. Filippi's Pizza Grotto Google Map At this Little Italy favorite, the red-checkered table-cloths, dim lights, and hundreds of Chianti bottles hanging from the ceiling haven't changed in decades. Enter through the Italian deli in front to get to the authentic dishes on offer. ## 9. Eddie V's Prime Seafood Google Map Views of La Jolla Cove loom from every table of this casually upscale restaurant. Mouth-melting seafood, selections from the oyster bar, and comfort-food sides pair with wines from the highly praised cellar. Live jazz plays nightly on the upper level patio. Tuna dish at Eddie V's Prime Seafood ## 10. Emerald Chinese Seafood Restaurant Google Map San Diego's best Chinese restaurants are found in Kearny Mesa. The Asian community packs into this large dining room to enjoy lunchtime dim sum and fresh, simple but exquisitely prepared seafood dishes at dinner. ### TOP 10 ROMANTIC RESTAURANTS #### 1. 1500 Ocean Excellent service and elegant offerings at this impressive spot. **Refined dining at 1500 Ocean** #### 2. Mille Fleurs A charming French restaurant _(seeMille Fleurs)_ with top service and a great wine list. #### 3. Chez Loma Delicious French cuisine here creates the ingredients for romance. #### 4. Old Venice 2910 Cañon St • 619 222 5888 • $$ A casually elegant venue that's not too pricey in Point Loma. #### 5. BiCE 425 Island Ave • 619 239 2423 • $$ Authentic Italian dishes are served in this modern, elegant restaurant. #### 6. The WineSellar & Brasserie 9550 Waples St, Suite 115 • 858 450 9557 • $$$ A delightful brasserie with excellent wine tasting. #### 7. Candelas on the Bay 1201 1st St, Coronado • 619 435 4300 • $$ Mexican nouvelle cuisine in a chic setting. Seafood is the specialty here. #### 8. The Marine Room Haute cuisine, candlelight, and soft music arouse the senses _(seeThe Marine Room)_. #### 9. George's at the Cove 1250 Prospect St • 858 454 4244 • $$$ The most popular place to propose in San Diego. #### 10. Primavera Ristorante 932 Orange Ave • 619 435 0454 • $$ Specialties like _osso bucco_ can melt hearts at this slice of Northern Italy. See restaurant price categories Back to Restaurants Back to The Top 10 of Everything Back to The Top 10 of Everything # STORES AND SHOPPING CENTERS ## 1. Nordstrom Google Map Holding an almost cult-like status among shopping fanatics, "Nordies" remains as popular as ever for its vast clothing selection and impressive shoe department. Belying the plush surroundings, this department store can be quite affordable. Of course, there is always the personal shopper who will help you out in the designer section. The Nordstrom Café is popular for lunch, with a menu that includes soups, sandwiches, pasta dishes, and salads. ## 2. Westfield Horton Plaza Google Map A destination in its own right, Macy's and Nordstrom department stores serve as anchors to this festive shopping experience. Designed as an amusement park for shoppers, ramps lead past staggered shopping levels that hold more than 130 specialty shops, a few restaurants, and movie theaters. Westfield Horton Plaza's landmark is the 1907 Jessop's Clock, a 21-ft- (6.4-m-) high timepiece with 20 dials that display the time in all parts of the world. Westfield Horton Plaza ## 3. Fashion Valley Google Map This ritzy shopping center contains six major department stores, including Neiman Marcus and Nordstrom, as well as 200 specialty boutiques. Tiffany & Co., MAC cosmetics, and Louis Vuitton are just a few of the stores found here. The San Diego Trolley conveniently stops in the parking lot. ## 4. Liberty Station Formerly the Naval Training Center, this waterfront compendium of Spanish Colonial-Revival buildings now welcomes shoppers with its many grocery stores, art galleries, and wine bars. Monthly art walks and live entertainment are free, as is parking. ## 5. The Wine Bank Google Map A regular clientele of wine connoisseurs frequent this intimate Gaslamp Quarter business. Hundreds of offerings from California and the rest of the world are found on two floors. The expertise of its wine professionals will help in your selection of fine wines in all price ranges. Call for the latest wine tasting schedule. ## 6. Girard Avenue & Prospect Street Google Map These intersecting streets in La Jolla are synonymous with upscale shopping and high-end art galleries. If you're seeking an expensive look, chic clothing boutiques and Italian shoe stores will happily oblige. The gorgeous displays in the home decor shops will give you great ideas to take home. In the breezy arcades, don't miss the one-of-a-kind shops and beachwear boutiques. ## 7. Seaport Village Google Map If you're looking for souvenirs or that unusual knick-knack for the shelf, this is the right place. The Village's superb location along San Diego's waterfront will keep you occupied. Each summer, the Busker Fest brings street performers here from across the country to entertain. The waterfront Seaport Village ## 8. REI Google Map To participate in San Diego's outdoor life, you might need sports equipment. This store has it all, including rentals of camping gear, snowshoes, and tents, as well as a full-service bike shop. You can also take bike lessons, enjoy lectures, and sign up for photography classes. ## 9. University and Fifth Avenues Google Map In Uptown, near the intersection of University and Fifth Avenues, the predominately gay and lesbian Hillcrest neighborhood is a haven of fun and enticing shops, cafés, restaurants, and bars. Bookshops, resale wear, and vinyl record stores are among the independent businesses. Secondhand store on Fifth Avenue ## 10. Newport Avenue Google Map This is not just the main road through town; it is also one big blast into the past before the street hits the beach. You can pick up anything from Arts and Crafts-era pottery to tie-dye T-shirts. Street parking is available. Back to Stores and Shopping Centers Back to The Top 10 of Everything Back to The Top 10 of Everything # SAN DIEGO FOR FREE ## 1. Whales, Dolphins, and Seals Google Map In season, you can often see migrating whales while staring out to sea. The same is true for dolphins, especially in the Encinitas area. Harbor seals can be seen lazing around the Children's Pool in La Jolla, for which the normal fee is waived on Tuesdays. Seals lying around the Children's Pool in La Jolla ## 2. Nature Trails Explore the miles of hiking trails at the Mission Trails Regional Park (www.mtrp.org) and the Torrey Pines State Preserve. The latter is also prime bird-watching territory. All of San Diego's beaches and parks are great for picnics. ## 3. Timken Museum of Art 1500 El Prado, Balboa Park • 619 239 5548 • www.timkenmuseum.org Google Map Admittance is free to this impressive and important collection of Russian icons, Parisian tapestries, European Old Masters, American works, and other fine art. The permanent collection includes Bruegel, Rubens, Vermeer, and _Saint Bartholomew_ – San Diego's only Rembrandt painting. Timken Museum of Art ## 4. Park at the Parks Park for free and enter for free at the city's glorious parks with year-round blossoms and playgrounds for the kids. Centerpiece Balboa Park is by far the urban favorite, while Old Town is full of history and aquatic Mission Bay Park is great for families. Ethereal skies and sands at Anza-Borrego are also free. ## 5. International Cottages 1549 El Prado, Balboa Park • 619 234 0739 • Open four hours between noon and 5pm Sunday • www.sdhpr.org Google Map More than 30 countries are represented within the historic 1935 cottages of Balboa Park's House of Hospitality. At 2pm, on a rotating basis, member houses epitomize their countries through song, dance, or other means. ## 6. Shakespeare Readings Upstart Crow Bookstore & Coffee House, 835 West Harbor Drive, Suite C • 619 232 4855 • 6:45–8pm 1st Tue of the month • www.sandiegoshakespearesociety.org Google Map Everyone is welcome to join the San Diego Shakespeare Society to participate in or listen with other aficionados to works by the Bard. ## 7. Walking Tours 619 231 7463 • www.walkabout-int.org/wabt.html Walkabout International leads free tours in and around San Diego. Some walks go through decorated neighborhoods, while others focus on architecture. Standard walks take place in Mission Bay, Shelter Island, Balboa Park, and Mission Hills. ## 8. Gaze at the Stars Google Map View the night sky at the Reuben H. Fleet Science Center in Balboa Park. Visitors can stargaze for free on the first Wednesday of every month, starting at 8pm, through giant telescopes from the San Diego Astronomy Association. ## 9. Art and Music Spreckels Organ Society: 619 702 8138; www.spreckelsorgan.org Google Map There are gallery openings most weekends and a monthly art walk at Liberty Station. Free concerts are also held during the year; many take place at beaches and parks throughout summer, including performances by the renowned Spreckels Organ Society. For listings, check www.sandiego.org. Spreckel's Organ Pavilion ## 10. 59-Mile Scenic Drive www.sandiego.org This three-hour drive winds through the city's neighborhoods and offers a plethora of memorable views, from the coastline, the bay, and the downtown skyline, to the bordering mountains, and even Mexico. The drive can also be spread out over several days. ### TOP 10 BUDGET TIPS **1.** Ride Balboa Park's free daily tram from Inspiration Point parking lot (www.balboapark.org/visit/parking) to El Prado attractions. **The free tram in Balboa Park** **2.** Purchase the Compass Card day or multiday pass (www.511sd.com/compass) for easy riding across buses and trolleys. **3.** Save money and skip lots of lines at theme parks as well as zoos with CityPass (www.citypass.com/southern-california). **4.** Visit many museums and San Diego Zoo with Balboa Park Explorer Pass (www.balboapark.org/explorer). **5.** Parking is free on most city side streets, but check signs for time limits. **6.** Both the downtown and the La Jolla locations of the Museum of Contemporary Art are free on the third Thursday of every month, from 5–7pm (www.mcasd.org). **7.** Check online site Groupon (www.groupon.com/local/san-diego) for deals on dining, attractions, and tours. **8.** Published weekly, _San Diego Reader_ (www.sandiegoreader.com) lists free and cheap events and deals. **9.** Pick up half-price theater tickets at the ArtsTix (www.sdartstix.com) kiosk in front of the Westfield Horton Plaza. **10.** Join the Morley Field Sports Complex for free or inexpensive sports activities, from jogging and cycling, to archery, basketball, as well as boccie (www.balboapark.org/in-the-park/morley-field-sports-complex; www.sandiego.gov/park-and-recreation/centers/recctr/morley). Back to San Diego for Free Back to The Top 10 of Everything Back to The Top 10 of Everything # FESTIVALS ## 1. Mardi Gras Gaslamp Quarter • Feb/Mar Be quick to grab the strings of beads thrown off the floats at the Masquerade Parade. The parade begins in the afternoon at Fifth Avenue, and the music and revelry carry on until the early morning. The food booths serve up New Orleans-style Cajun food. ## 2. St. Patrick's Day Parade Mar A grand parade of marching bands, bagpipes, community organizations, horses, and school groups begins at Sixth and Juniper. Afterward, an Irish festival takes place at Balboa Park with Irish dancers, lots to eat, green beer, and fun for the entire family. St. Patrick's Day Parade ## 3. Cinco de Mayo May North of the Mexican border, commemorating the French defeat by Mexican troops is a serious business. Restaurants overflow, the Old Town State Historic Park sponsors folkloric ballet performances and mariachi bands, and the historic Gaslamp Quarter hosts a musical street fair. Dancer at Cinco de Mayo celebrations ## 4. Fourth of July Fireworks and Parades Jul Nearly every San Diego community has its own July 4th festivities, such as fireworks, surfing contests, parades, and street festivals. Since the ban of home fireworks, commercial firework shows are the way to go. The biggest show in the county is held over San Diego Harbor. Fireworks marking the Fourth of July ## 5. Comic-Con International Convention Center • Late Jul Comic-Con draws more than 150,000 devotees over several days and literally bursts out of the huge San Diego Convention Center. Tickets sell out super-fast for this wildly popular all-things-comic-and-then-some gathering. Celebrity guests, panels, retailers, games, anime, film screenings, and fringe events line the program. ## 6. Lesbian and Gay Parade and Festival End Jul San Diego's gay community hits the streets in celebration of diversity. The iconic parade begins at Fifth Avenue and Laurel in Hillcrest and moves to Balboa Park, where live bands, food booths, and a party atmosphere prevail. Outrageous costumes are the rule of the day. ## 7. Halloween Festivals & Haunted Houses Gaslamp Quarter & Balboa Park • Oct • Adm Your worst nightmares may come true at the historic 1889 Haunted Hotel, which features ghouls, a clown asylum, and a haunted subway station. The Chamber and Haunted Trails of Balboa Park will terrify you. ## 8. Mother Goose Parade El Cajon • Sun before Thanksgiving Floats, equestrian units, and marching bands make up part of the 200 entries in the largest single-day event in San Diego County, attended by about 400,000 people. A tradition since 1947, the parade revolves around a celebration of children. Mother Goose Parade ## 9. Christmas on the Prado Balboa Pk • First Fri & Sat of Dec Balboa Park launches the Christmas season by opening its doors to the community. Museums are free after 5pm, carolers sing, and food booths are set up. The park is closed to traffic, but shuttles reach the outer parking lots. Dress warmly. ## 10. Boat Parades of Lights Dec Yachts and sailboats vie for the title of best decorated in Mission Bay and the San Diego Harbor. The best viewing areas for the Mission Bay parade are at Crown Point and Fiesta Island; for the San Diego Harbor Parade, head to the Embarcadero. ### TOP 10 FAIRS AND GATHERINGS #### 1. Ocean Beach Kite Festival Ocean Beach • Mar A kite competition with prizes and demonstrations on the beach. #### 2. Avocado Festival Fallbrook • Apr Special tours, 50 food booths, and awards for best dishes draw big crowds. #### 3. Mainly Mozart Festival Apr–Jun • Adm Concerts at San Diego and Tijuana feature works by the wunderkind and his contemporaries. #### 4. San Diego County Fair Del Mar • Jun • Adm Animals, rides, food, and music. **San Diego County Fair performers** #### 5. A Taste of Gaslamp Gaslamp Quarter • Jun • Adm A self-guided tour passes restaurants displaying their kitchen samplings. #### 6. US Open Sand Castle Competition Imperial Beach • Aug Competitors build the most complex and imaginative sand castles. #### 7. Summerfest Aug Classical music and modern compositions in La Jolla, with artists and ensembles from around the world. #### 8. Julian Fall Apple Harvest Mid-Sep–mid-Oct Music, apple cider, and apple pies in a charming mountain town. #### 9. Cabrillo Festival Cabrillo National Monument • End Sep • Adm Soldiers re-enact the Cabrillo landing, and performers showcase Native American, Aztec, and Mayan dances. #### 10. Fleet Week Sep/Oct Navy ship tours and air and sea parades honor the military. Back to Festivals Back to The Top 10 of Everything * * * San Diego Area by Area View across the marina toward the waterfront and its high-rises ## San Diego Area by Area 1 | Downtown San Diego ---|--- 2 | Old Town, Uptown, and Mission Valley ---|--- 3 | Ocean Beach, Coronado, and the South ---|--- 4 | Northern San Diego ---|--- Back to San Diego Area by Area # DOWNTOWN SAN DIEGO Scarcely a generation ago, one drove through downtown San Diego with the windows rolled up, past derelict tattoo parlors and sleazy porn palaces. But it has transformed into a first-class destination for visitors and a trendy area for residents. There are restaurants, art galleries, festivals, performing arts centers, museums, and a sports stadium. The atmosphere is strictly Southern Californian: a blend of urban energy and laid-back priorities. From the edge of the Embarcadero to the beautifully restored Gaslamp Quarter, downtown is a great place to have fun in. ## 1. Embarcadero Google Map For those arriving by ship or train, the Embarcadero is San Diego's front door. Passengers disembark from gleaming white cruise ships tied up at B Street Pier or pass through a 1915 train depot. But the Embarcadero is an attraction in itself. Pedestrian-friendly walkways pass historic ships, museums, shopping centers, and parks. Serious and quirky public artworks and a harbor filled with maritime life define this lively district. Walkway on the Embarcadero ## 2. Gaslamp Quarter Google Map In the mid-19th century, the Gaslamp Quarter was the heart of a new city, but within 50 years it had fallen prey to gambling halls, opium dens, and houses of prostitution, and within another 50 years, it had become a broken-down slum. Now the Gaslamp Quarter sparkles as it looks to a brilliant future. During the day, the gloriously restored buildings attract history buffs and shoppers. By night, crowds dine in fashionable restaurants, listen to music, or sip drinks. The historic Gaslamp Quarter ## 3. Balboa Park and San Diego Zoo Google Map Home to the world-famous San Diego Zoo, 15 unique museums, theaters, countless recreational opportunities, and exquisite landscaping, Balboa Park creates an indelible impression. Year round, vibrant flowers bloom in profusion and pepper tree groves and grassy expanses provide idyllic spots for picnicking. Allow a minimum of a few days to enjoy the park's many attractions. San Diego Museum of Man in Balboa Park ## 4. East Village Google Map Formerly a Victorian village that fell into neglect but survived as a warehouse district and artist colony, this area is now very fashionable. Petco Park, home to the San Diego Padres baseball team, is the neighborhood's major focal point. Check out the 1909 Western Metal Supply building: architects incorporated the vintage building into the stadium's structure. A state-of-the-art Central Library and Children's Museum are located here. Central Library, East Village ## 5. Westfield Horton Plaza Google Map When it opened in 1985, developers hoped this unique shopping center _(seeWestfield Horton Plaza)_ would help revive a declining area. It was an immediate hit – people loved the Plaza's inward-facing design, tiered shopping levels, and the 43 unusual colors of paint on its walls. Over several city blocks, the plaza features more than 130 shops, movie theaters, and stage shows at the Lyceum Theatre. Adjacent to Westfield Horton Plaza is the Balboa Theatre. Built as a cinema in 1924, it now offers live shows. ## 6. Little Italy Google Map This revitalized neighborhood is one of San Diego's oldest. Genoese fishing families were the first Italians to settle along the waterfront in the 1860s. Along with Portuguese immigrants, they founded San Diego's prosperous tuna industry. Little Italy, sometimes known as Middletown, is now a fashionable address. While retaining its Bohemian character, restaurants, galleries, design stores, and a Saturday market line its streets. ## 7. Asian Pacific Historic District Google Map An eight-block area that overlaps part of the Gaslamp Quarter marks the former center of San Diego's Asian community. The Chinese came to San Diego after the California Gold Rush and found fishing and construction work; others ran opium dens and gambling halls. Japanese and Filipino communities followed. This is the home of Chinese New Year celebrations, a farmers' market, and an Asian bazaar. Join a walking tour at the Chinese Historical Museum, and look for Asian architectural flourishes on the buildings. ## 8. Marston House 3525 7th Ave • 619 298 3142 • Open for docent-led tours only: half-hourly tours start at 10am; last tour begins at 4:30pm • Adm Google Map This fine Arts and Crafts house, built in 1905, is open to the public as a museum. The exterior combines elements of Victorian and English Tudor styles, while the interior offers expansive hallways and intimate living spaces adorned with Mission-style furnishings, fine pottery, paintings, and textiles by craftsman artisans. The museum is operated by the San Diego Historical Society. ## 9. Martin Luther King Promenade Google Map Planner Max Schmidt used the idea of functional public art to create this 1/4-mile (0.4-km) promenade along Harbor Drive. Described as a "serape" of colors, textures, and waterworks, the promenade celebrates a multicultural heritage. Granite stones bear quotes by civil-rights leader Dr. Martin Luther King. Martin Luther King Promenade ## 10. Museum of Contemporary Art 1001 & 1100 Kettner Blvd • 858 454 3541 • Open 11am–5pm Thu–Tue (11am–7pm 3rd Thu each month) • Docent-led tours: 5:30pm & 6:45pm 3rd Thu each month, 2pm Sat & Sun (included with admission) • Adm Google Map This two-building downtown location of the museum in La Jolla presents rotating art exhibits, as well as selected pieces from the permanent collection. At the entrance is the 18-ft (5.4-m) _Hammering Man at 3,110,527_ , a steel and aluminum sculpture by Jonathan Borofsky. The museum also hosts lectures and workshops, and there is a themed gallery tour at the free opening on the third Thursday evening each month. ### THE FOUNDING OF MODERN SAN DIEGO When entrepreneur Alonzo Horton arrived in a burgeoning San Diego in 1867, he believed that a new city could prosper in this location. He bought 960 acres and sold and even gave away lots to people. When you walk the Gaslamp Quarter, note the short blocks and lack of alleys, created due to the opinion that corner lots were worth more and alleys only accumulated trash. ### A DAY WALKING AROUND DOWNTOWN ### MORNING Start at the **Santa Fe Depot**. Walk right on Broadway, cross the RR tracks, and walk two blocks to Harbor Drive. Turn right and head to the **Maritime Museum of San Diego**. Check out the exhibits and climb aboard the **_Star of India_**. Walk back down Harbor Drive to the ticket booth for harbor tours. A narrated harbor cruise brings you close to the naval facilities. Next, spend an hour or so aboard the **USS _Midway_** at the **USS Midway Museum**. Finish your morning with lunch at the **Fish Market** _(N. Harbor Drive; 619 232 3474)_. ### AFTERNOON Continue down Harbor Drive to **Seaport Village** and stay on the sidewalk until you reach a crossing. Turn left; walk up the street past the Manchester Grand Hyatt Hotel, across Harbor Drive and the trolley tracks. Walk onto the **Martin Luther King Promenade** , which stretches past beautiful downtown apartment revitalizations. At the Convention Center trolley stop, turn left, then left again on J St. On J and 3rd, stop by the **San Diego Chinese Historical Museum**. Turn left on 3rd and right on Island; you'll pass the historic **Horton Grand Hotel**. At 4th, visit the **William Heath Davis House**. One block farther is the heart of the **Gaslamp Quarter**. Pick up a sundae at **Ghirardelli Soda Fountain** _(631 5th Street)_. Back to Downtown San Diego Back to San Diego Area by Area # Cruising the Bay ## 1. Coronado Bridge Google Map This bridge links Coronado to San Diego. Its gradual incline and curve allow cars to maintain speed. It is high enough for aircraft carriers to pass beneath at high tide. Aerial view of Coronado Bridge ## 2. SPAWAR Google Map This Navy marine mammal facility trains bottlenose dolphins, with their biological sonar, to locate sea mines. ## 3. Naval Base San Diego Google Map This base provides shore support and living quarters for more than 50 naval ships of the Pacific Fleet, and is one of only two major fleet support installations in the country. ## 4. Naval Air Station North Island Google Map Several aircraft carriers tie up here. You can often see high-tech aircraft, submarines, and destroyers. ## 5. Local Marine Wildlife Seals and sea lions are bay residents. The East Pacific green sea turtle and the California least tern have protected foraging habitats. ## 6. Naval Amphibious Base Google Map Home to the Navy SEALS and the Navy Parachute Team, the facility has served as a training base since 1943. It is responsible for training and maintenance of the ships of the Pacific Fleet. ## 7. Cabrillo National Monument Google Map Dedicated to the European discovery of San Diego and Alta California, this monument draws over one million people a year. The statue of Cabrillo is a replica of an original that could not withstand the wind and salt air. ## 8. NASSCO Shipyard Google Map The National Steel and Shipbuilding Company designs and builds US Navy auxiliary ships, commercial tankers, and container ships. It is one of the largest shipyards in the US. ## 9. Museum Vessels of the Embarcadero Google Map The sailing ship _Star of India_ dates back to 1863; _Berkeley_ used to carry passengers in the Bay Area; and the USS _Midway_ features in the USS Midway Museum. The Star of India on the Embarcadero ## 10. Cruise Ship Terminal Google Map San Diego boasts the fastest-growing cruise ship port on the west coast, with 180 ships docking at the B Street Pier throughout the year. Cruises leave for excursions to the Mexican Riviera, Hawaii, Canada, the Panama Canal, and the South Pacific. Back to Downtown San Diego Back to San Diego Area by Area # Shopping ## 1. Goorin Bros. Hat Shop 631 5th Ave • 619 450 6303 Google Map Established in 1895, this is the place for serious lovers of quality headgear of all shapes and styles, catering to both men and women. ## 2. The Wine Bank 363 5th Ave, Suite 100 • 619 234 7487 Google Map Come here _(seeThe Wine Bank)_ for expert staff and two floors of North American and international wines in all price ranges. ## 3. Seaport Village 849 W. Harbor Dr • 619 235 4014 • Open Sep–May: 10am–9pm; Jun–Aug: 10am–10pm Google Map At this complex by the bay, you'll find kites, magnets, gifts for left-handed people, and T-shirts galore. ## 4. Nordstrom 103 Horton Plaza Google Map The many specialty departments here _(seeNordstrom),_ such as cosmetics and accessories, clothing, and shoes are like small boutiques in themselves. ## 5. Vocabulary 414 W. Cedar St • 619 203 4066 Google Map This intimate Little Italy boutique sells apparel for men and women, baby items, home decor, paper goods, and accessories and gifts. Interior of Vocabulary ## 6. Chuck Jones Gallery 232 5th Ave • 619 294 9880 Google Map American Pop artworks are on sale here in a gallery setting. Featured artists include Chuck Jones, Dr. Seuss, Charles Schulz, and Tom Everhart. ## 7. Westfield Horton Plaza 4th Ave & Broadway • 619 239 8180 Google Map This large plaza boasts a wide variety of shops and restaurants. Plans are underway to develop it into a tech "campus" with boutique retail. ## 8. The Cuban Cigar Factory 551 5th Ave • 619 238 2496 Google Map Cigar makers roll tobacco from Central America and the Dominican Republic in San Diego's original cigar factory. Aficionados can select from a variety of cigars. ## 9. United Nations International Gift Shop 2171 Pan American Plaza • 619 233 5044 Google Map Toys, instruments, jewelry, books, crafts, and ethnic clothing are among the temptations at this colorful store. ## 10. Zeglio Custom Clothiers 246 Broadway • 619 343 1433 Google Map Custom tailored men's suits, shirts and pants, as well as expert alterations make this the go-to place in San Diego for weddings, special occasions, and style upgrades. Back to Downtown San Diego Back to San Diego Area by Area # Museum Shops ## 1. San Diego Museum of Art Google Map Exhibit-led art books, stationery, jewelry, purses, flower pressing kits, and Tibetan chests are for sale here. The children's section offers educational toys and gifts. Jewelry at the Museum of Art shop ## 2. Mingei International Museum Google Map This museum store is filled with ethnic clothes, Chinese brushes, Russian dolls, chiming bells, and a good selection of _alebrijes_. ## 3. San Diego Museum of Man Google Map Crafts from around Latin America here _(seeSan Diego Museum of Man)_ include Peruvian gourds, Mexican folk art, and three-legged Chilean good luck pigs. There is also a wide range of Native American crafts such as silver jewelry. ## 4. Museum of Contemporary Art Google Map Check out the select merchandise that relates to the museum's _(seeMuseum of Contemporary Art)_ special exhibitions. The latest art books and handcrafted jewelry are always on offer. ## 5. San Diego Art Institute Shop House of Charm, Balboa Pk Google Map Juried art shows present the work of local artists, whose works often go on sale after being exhibited. This small shop features glass sculptures, porcelain _objets d'art_ , hand-painted cushions, and jewelry. ## 6. Maritime Museum of San Diego Google Map Gratify your nautical gift needs with a variety of model ships, T-shirts, posters, and prints inscribed with an image of the _Star of India_. ## 7. Reuben H. Fleet Science Center Google Map Science toys, videos, puzzles, and hands-on games here _(seeReuben H. Fleet Science Center)_ are very popular with the kids. ## 8. San Diego Chinese Historical Museum Google Map Chinese calligraphy sets, tea sets, snuff bottles, and chops – a type of carved stamp used to sign one's name – are on sale here. ## 9. Museum of Photographic Arts Google Map Exhibition catalogs, prints, note cards, and calendars represent the world's finest photographic artists, both past and present. A wide range of books is also available. Store at Museum of Photographic Arts ## 10. San Diego History Center Google Map If you're interested in San Diego's past, including haunted locations and biographies, this museum offers one of the best collections of local history books. Back to Downtown San Diego Back to San Diego Area by Area # Places to Eat ## 1. Oceanaire Seafood Room 400 J St • 619 858 2277 • $$ Google Map The creative menu here features seafood from around the world. The oysters and crab cakes are legendary. ## 2. Kansas City Barbeque 600 W. Harbor Drive • 619 231 9680 • $ Google Map This busy eatery shot to fame as a setting in the iconic film _Top Gun_. It serves big plates of barbecue favorites with traditional sides. ## 3. The Grant Grill US Grant Hotel, 326 Broadway • 619 744 2077 • $$ Google Map With a club-like ambience, The Grant Grill offers contemporary California cuisine. Try the famous mock turtle soup with chervil and sherry. ## 4. Top of the Market 750 N. Harbor Dr • 619 232 3474 • $$$ Google Map Chichi seafood restaurant with fabulous views. Come here for a window seat, a calm atmosphere, and seafood prepared with panache. ## 5. Filippi's Pizza Grotto 1747 India St • 619 232 5095 • $ Google Map One of the city's most-loved local Italian spots _(seeFilippi's Pizza Grotto)_. Guests should expect a wait as there is limited seating here. ## 6. The Prado at Balboa Park 1549 El Prado, Balboa Park • 619 557 9441 • $$ Google Map Made with _tres leches_ (sponge soaked in three types of milk), caramelized banana, meringue, and fired plantain, the Prado Tres Leches is a must try here. ## 7. Lou & Mickey's 224 5th Ave • 619 237 4900 • $$$ Google Map Delectable steaks, fresh seafood, and pasta dishes are served at booths, tables, or on a shaded patio. Patio area at Lou & Mickey's ## 8. Tender Greens 110 W. Broadway • 619 795 2353 • $ Google Map There's something for everyone here – from fried chicken and hearty salads, to vegan options and soups. ## 9. Currant Brasserie 140 W Broadway • 619 702 6309 • $ Google Map American and French classics such as skillet breakfasts, New Orleans-style beignets, juicy burgers and an absinthe menu draw locals in a steady stream. ## 10. Indigo Grill 1536 India St • 619 234 6802 • $$ Google Map This Little Italy restaurant serves food with a modern Latin kick. Try the tacos with jalapeno tartare sauce or spicy honey aioli. #### PRICE CATEGORIES Price categories include a three-course meal for one, half a bottle of wine, and all unavoidable extra charges including tax. * * * **$** under $40 **$$** $40–$80 **$$$** over $80 Back to Downtown San Diego Back to San Diego Area by Area Back to San Diego Area by Area # OLD TOWN, UPTOWN, AND MISSION VALLEY This long stretch follows the San Diego River from the Mission San Diego de Alcalá to Old Town. For as long as 12,000 years, the Kumeyaay tribe lived in small settlements in the valley, unaware that strangers from the other side of the earth would change their lives forever. Both Spanish soldiers and Franciscan padres had glory here, as well as San Diego's pioneer families. The valley itself holds little interest beyond masses of chain motels and shopping centers intersected by a freeway; however, on the bluffs above, you'll find eclectic neighborhoods overflowing with charm, brilliant architecture, and chic restaurants. Tolerance and diversity creates a progressive, Bohemian air, while rising real estate prices have turned simple bungalow homes into showpieces. And San Diego's birthplace is always close by. ## 1. Old Town State Historic Park Google Map San Diego's first commercial settlement has been either preserved or re-created in this pedestrian-only park. Much of the town was destroyed in a fire in 1872, prompting the development of a new town center closer to the water, but several original structures remain. You can wander into any of Old Town's houses and find museums or concession shops inside. ## 2. Junípero Serra Museum 2727 Presidio Dr • 619 232 6203 • Open Jun–Sep 4: 10am–5pm Tue–Sun; Sep 5–May: 10am–4pm Sat & Sun • Adm • www.sandiegohistory.org Google Map Constructed in 1929 to a design by William Templeton Johnson, the museum building is in keeping with the city's Spanish-Colonial heritage. Its white stucco arches, narrow passages, red-tile roof, and stately tower pay tribute to the first mission, which stood near this site. Artifacts from ongoing archeological excavations, ceramics made by the Kumeyaay tribe, clothing, furniture, and a cannon help illustrate the meager life people led. Climb the tower to compare today's view with that of 1929. ## 3. University of San Diego 5998 Alcalá Park • 619 260 4600 Google Map Grand Spanish Renaissance buildings distinguish this independent Catholic university, its design inspired by the university in the Spanish town of Alcalá de Henares. Of exceptional note is the Founders Chapel with its white marble altar, gold-leaf decoration, 14 stained-glass nave windows, and marble floor. University of San Diego ## 4. Mission Basilica San Diego de Alcalá Google Map A peaceful enclave among the nondescript strip malls of Mission Valley, the mission's original spirit still lingers in the church and its lovely gardens. The first of California's 21 missions was moved to this permanent site a few years after its founding. Over the years, the structure was rebuilt to suit the needs of the time. Its famous facade and bell tower have inspired architects to copy the "Mission Style" throughout San Diego. ## 5. Mission Hills Mission Hills Nursery: 1525 Fort Stockton Dr Google Map One of San Diego's most charming and romantic neighborhoods is in the hills overlooking Old Town and San Diego Bay. Tree-lined streets run past architectural jewels built in various styles. Dating from the early 1900s, homes had to cost at least $3,500, and could not keep any male farm animals. Only those of Caucasian descent could hold property. Kate Sessions' 1910 nursery _(seeThe Mother of Balboa Park)_ can still be visited here. ## 6. Whaley House Museum 2482 San Diego Ave • 619 297 7511 • Open 10am–4:30pm Sun–Tue, 10am–9:30pm Thu–Sat; late May–early Sep: 10am–9:30pm daily • Adm • whaleyhouse.org Google Map California's first two-story brick structure also served as San Diego's first courthouse, county seat, and home to Thomas Whaley, who built it in 1856 over a graveyard and site of a former gallows. The US Commerce Department declared the house officially haunted in the 1960s. Interior of haunted Whaley House ## 7. Hillcrest Google Map Considered San Diego's first suburb in the 1920s, Hillcrest slowly developed into a residential area, offering a quiet alternative to the bustle of downtown. A trolley stop opened the neighborhood up to thriving businesses, restaurants, and theaters; in the 1940s, merchants proudly erected a sign that spanned University Boulevard, proclaiming "Hillcrest" to the world. But fortunes changed, neglect followed, and this sign came down. In the 1970s, the LGBT+ community took up the revitalization challenge and transformed the community into a hip destination with great restaurants, nightlife, and avant-garde shops. And now the sign is back – in neon. ## 8. Presidio Park Google Map The Kumeyaay tribe once used this hillside for sacred ceremonies. Site of the original Spanish presidio and mission settlement, a lovely park is all that's left of San Diego's beginnings. The park contains the Junípero Serra Museum and the remaining earthen walls of Fort Stockton, a fortress that changed hands several times during the Mexican-American War, marked by bronze monuments, a flagpole, and a cannon. The 28-ft (8.5-m) Serra Cross, constructed from mission tiles, honors founder Saint Junípero Serra. ## 9. Mormon Battalion Memorial Visitor's Center 2510 Juan St • 619 298 3317 • Open 9am–9pm daily Google Map In July 1846, 500 men, 32 women, and 51 children set out from Council Bluffs, Iowa, on what would be considered one of the longest military marches in history. Six months and 2,000 miles (3,218 km) later, they reached San Diego to support the American military garrison in the Mexican-American War. At the Visitor's Center, a volunteer from the Church of Latter-Day Saints discusses the march and Mormon contributions to the area. Mormon Battalion Memorial ## 10. Heritage Park County 2454 Heritage Park Row • 619 819 6009 • Open 9am–5pm daily Google Map Downtown's rapid expansion after World War II almost destroyed several Victorian heritage houses and San Diego's first synagogue. The Save Our Heritage Organization rescued and moved these architectural treasures to this specially created park. Of notable interest is the Sherman Gilbert House, once home to art and music patrons Bess and Gertrude Gilbert, who hosted luminaries such as Artur Rubinstein, Anna Pavlova, and the Trapp Family Singers. Houses in Heritage Park ### APOLINARIA LORENZANA In 1800, Apolinaria Lorenzana and 20 orphans arrived from Mexico to be distributed to respectable presidio families. She taught herself to write by copying every written thing she found. She spent her life caring for the mission padres, teaching children and women church doctrine, and tending the sick. Nicknamed La Beata, she was one of the few women to receive a land grant. ### A WALK AROUND OLD TOWN, HERITAGE PARK, AND PRESIDIO PARK ### MORNING Begin at the Old Town Transit Center. Cross the street and follow the path into **Old Town State Historic Park**. Just to the left is the Interpretive Center, where you can pick up a map. Walk along the right side of the Plaza and peek into the Bailey & McGuire Pottery Shop. Follow the signs to **La Casa de Machado y Stewart** and the **Mason Street School**. Back at the Plaza, visit **La Casa de Estudillo** for the best insight into an upper-class home of early California. From the Plaza's southwest corner, continue out of the State Park. Walk along San Diego Avenue, where you'll find souvenir shops, galleries, and restaurants. Try the **Old Town Mexican Café** for lunch. ### AFTERNOON Cross the street at Conde and backtrack up San Diego Avenue to visit the haunted **Whaley House**. Turn right on Harney Street and walk uphill to **Heritage Park**. Backtrack one block to the **Mormon Battalion Visitor's Center**. Turn right on Juan Street and walk to Mason. You'll see a sign indicating "The Old Presidio Historic Trail." Turn right on Mason, follow the golf course to Jackson, and look for the footpath across the street. You'll parallel Jackson to the left and wind uphill to **Presidio Park**. Across the grass are the ruins of **Serra Cross** , the original presidio, and the **Junípero Serra Museum**. Back to Old Town, Uptown, and Mission Valley Back to San Diego Area by Area # Shopping ## 1. Bazaar del Mundo 4133 Taylor St • 619 296 3161 Google Map In a lushly landscaped plaza, quality shops offer Mexican tableware, folk art, Guatemalan textiles, and books. ## 2. Gioia's Room 3739 6th Ave • 619 269 2303 Google Map An interesting boutique that offers accessories and vintage women's clothing with free alterations. ## 3. Old Town Market 4010 Twiggs St • 619 260 1078 Google Map This festive market offers entertainment and local artisans. The shops sell colorful Mexican goods, such as Day of the Dead folk art, as well as jewelry and gifts. Mexican crucifixes, Old Town Market ## 4. Four Winds Trading Company 2448-B San Diego Ave • 619 692 0466 Google Map This Old Town store specializes in authentic Native American pottery, weavings, jewelry, dreamcatchers, and paintings of Native American themes. ## 5. Record City 3757 6th Ave • 619 291 5313 Google Map There's nothing quite like vinyl, and the crates here are stocked with rock and 1980s and 1990s alternative music. Used CDs are also on sale. ## 6. Thread & Seed 2870 4th Ave • 619 994 1425 Google Map This small, tidy and elegant shop features luxe bath products, cosmetics, candles, chocolates, books and jewelry. Their custom gift boxes are a specialty. ## 7. Creative Crossroads 502 University Ave • 800 685 2513 Google Map Local artisans show and sell their wares in this marketplace near the corner of University and Fifth. Purchase jewelry, greeting cards, art, gifts, and Gay Pride apparel. ## 8. Bluestocking Books 3817 5th Ave • 619 296 1424 Google Map This independent store offers new and used books on a wide range of subjects. The search service aims to locate rare and vintage items. ## 9. Whole Foods 711 University Ave • 619 294 2800 Google Map With an emphasis on fresh organic food, you'll find flavorful produce, a great assortment of imported goods, and a deli that specializes in healthy takeout. ## 10. Fashion Valley 7007 Friars Rd • 619 297 3381 Google Map From Neiman Marcus and Nordstrom to Apple, Gucci, and Tiffany, this two-level, open-air mall _(seeFashion Valley)_ has more than 200 stores. There are also many great food outlets and an 18-screen theater. The mall closes at 9pm every night. Back to Old Town, Uptown, and Mission Valley Back to San Diego Area by Area # Places to Eat ## 1. Jack and Giulio's Italian Restaurant 2391 San Diego Ave • 619 294 2074 • $$ Google Map Classics like Caprese salad, scampi, as well as tiramisu are served in a romantic and intimate space – a welcome respite from the crowds in Old Town. ## 2. Saffron 3731 India St • 619 574 7737 • $ Google Map Parking is tricky, but crowds come here for wondrously flavorful Thai cuisine. Takeout is also available. Thai dishes are served up at Saffron ## 3. El Agave Tequileria 2304 San Diego Ave • 619 220 0692 • $$ Google Map Utter culinary magic awaits within one of the first tequilarias in San Diego. Classic Mexican food with modern touches. ## 4. Crest Café 425 Robinson Ave • 619 295 2510 • $ Google Map Locals love this upscale diner, serving fresh soups, salads, and big burgers. Dessert at Crest Café ## 5. Arrivederci Ristorante 3845 4th Ave • 619 299 6282 • $$ Google Map Service at this cozy spot is friendly, prices are reasonable, and the pasta dishes are some of the best in town. ## 6. Blue Water Seafood Market & Grill 3667 India St • 619 497 0914 • $ Google Map A fabulous selection of seafood is on offer at this friendly seafood market. Try the fish tacos, seafood cocktails, or chowders. ## 7. Bertrand at Mr. A's 2550 5th Ave, 12th Floor • 619 239 1377 • $$ Google Map Popular choices at Bertrand at Mr. A's include sautéed Alaskan halibut with scallops and a trio of scrumptious vegetarian creations. ## 8. Casa Guadalajara 4105 Taylor St • 619 295 5111 • $$ Google Map This festive restaurant is a grand celebration of Mexican specialties and premium margaritas, along with folk art, fountains, and mariachis. ## 9. Brooklyn Girl Eatery 4033 Goldfinch St • 619 296 4600 • $$ Google Map Savor seasonal menus with locally sourced products. Try the bacon-wrapped Vietnamese meatballs. ## 10. San Diego Chicken Pie Shop 2633 El Cajon, North Park • 619 295 0156 • No credit cards • $ Google Map Seniors and budget-eaters love the hearty food here: think tasty chicken pies accompanied by mashed potatoes and gravy. See restaurant price categories Back to Old Town, Uptown, and Mission Valley Back to San Diego Area by Area Back to San Diego Area by Area # OCEAN BEACH, CORONADO, AND THE SOUTH South of San Diego to the Mexican border, cultures blend in several communities. Many Mexican citizens live, work, and send their children to school in these border areas; others cross into the US for shopping. While many Americans used to enjoy reciprocal pleasures in Mexico, sadly drug-cartel violence has spilled into Tijuana and other tourist zones. There are good experiences to be had on the US side, particularly in Chula Vista. ## 1. Point Loma Google Map Over one million people a year visit the Cabrillo National Monument at Point Loma. The views are mesmerizing, and the peninsula ends at the meeting point of the Pacific Ocean and San Diego Bay. Half the peninsula is occupied by the military, preventing overdevelopment. Spend time at Sunset Cliffs Park and perhaps spot a whale. Point Loma ## 2. Tijuana Google Map During the days of Prohibition, Tijuana, Mexico, used to be the destination of choice for the Hollywood elite and their followers, and for alcohol and gambling. The palatial, Moorish-designed Agua Caliente Casino & Spa was so popular that it boasted its own landing airstrip for the private planes of the wealthy. Fortunes fell when Mexico declared casino gambling illegal in 1935, and the city later reinvented itself as a family-oriented tourist destination. In recent years, however, drug cartel violence has escalated, and visitors should be diligent and heed all published government warnings. ## 3. Ocean Beach Google Map Unconventional and laid back, OB, as it's locally known, has a somewhat hippie-like feel. On main thoroughfare Newport Avenue, you can still find a few original shops. But OB is mainly about the beach: on any day of the year, surfers are waiting for the next swell; volleyball players are spiking balls over the net; and dogs are running freely on Dog Beach. Surfer at Ocean Beach ## 4. Coronado Google Map In the 1880s, two wealthy businessmen, Elisha Babcock, Jr. and Hampton Story, purchased Coronado and set out to build a town. They sold lots, laid streets, and constructed the landmark Hotel del Coronado. John D. Spreckels soon bought them out and turned Coronado into a haven for old-money gentry. The military permanently took over much of the peninsula during World War I. The old mansions, resorts, and military base exist harmoniously and give Coronado its unique identity. The famous Hotel del Coronado ## 5. San Diego International Airport Google Map No matter where you are in San Diego, look up and you'll see a jet soaring dramatically past the downtown high-rises on its final approach to Lindbergh Field. One hundred years ago, this area was a muddy wasteland that proved to be an ideal spot for budding inventors and pilots to try out their latest machines. In 1927, Ryan Aviation designed, produced, and tested on the beach the _Spirit of St. Louis_ , the historic plane that Charles Lindbergh piloted solo across the Atlantic. ## 6. Harbor Island Google Map Created from 3.5 million tons of mud from the bottom of San Diego Bay, this recreational island is a peninsula that extends into the bay south from the airport. Hotels, restaurants, and marinas offer gorgeous views across the bay of downtown, Point Loma, and Coronado. Facing the island is Spanish Landing Park, which commemorates the 1769 meeting of the sea and land expeditions of Gaspar de Portolá and Junípero Serra _(seeThe Spanish Settlement (1769))_, which permanently brought the Spanish to California. Boats moored in the marina at Harbor Island ## 7. Shelter Island Google Map Not really an island but a peninsula that juts out into San Diego Bay from Point Loma, this is home to pleasure boats and a park along its length. In the 1950s, the city dredged millions of tons of sand and mud from the bay onto a sandbar to create land for marinas and hotels. A number of hotels still have hints of Polynesian themes, a popular style at the time. The San Diego Yacht Club here is the three-time host of the prestigious America's Cup sailing race. Shoreline Park on Shelter Island ## 8. Marine Corps Recruit Depot 1600 Henderson Ave • 619 524 6719 • Open 8am–4pm Mon–Sat (photo ID for Depot; proof of insurance if driving) Google Map Listed on the National Register of Historic Places, the quaint Spanish-Colonial buildings were designed by Bertram Goodhue, architect of several buildings for the Panama-California Exposition in Balboa Park. The Command Museum displays the history of the Marine Corps in Southern California and the wars in which they fought. Exhibits include photos, training films, and a World War II ambulance. ## 9. Border Field State Park Google Map As the endangered Western snowy plover seeks a place to lay her eggs, the green-and-white vehicles of the US Border Patrol swoop down hillsides, lights blazing, in search of an illegal immigrant. An enormous, rusty, corrugated metal fence, which separates the US and Mexico, slices through the park before plunging into the sea. This southern part of the Tijuana River National Estuarine Research Reserve attracts nature lovers who come to hike, ride horses, picnic on the beach, and bird-watch. On the Mexican side of the fence is a lively Mexican community and bullring. ## 10. Living Coast Discovery Center 1000 Gunpowder Point, Chula Vista • 619 409 5900 • Open 10am–5pm daily • Adm Google Map The center is in the Sweetwater Marsh National Wildlife Refuge, one of the few accessible salt marshes left on the Pacific Coast. Rent some binoculars and climb to an observation deck to see how many of the 200 bird species in the refuge you can spot. Or you can also take a self-guided tour along interpretative trails. Children will enjoy petting bat rays and leopard sharks. The parking lot is located near the Baysite/E Street Trolley Station; a free shuttle will take you to the center. Owl, Living Coast Discovery Center ### TENT CITY When John D. Spreckels acquired the Hotel del Coronado in 1890, he felt the beauty of the area should be available to everyone. He built "Tent City," a makeshift town that catered to the less-well-to-do. Arriving by rail and car, families paid $4.50 a week to live in tents equipped with beds, dressers, and flush toilets. Amenities included carnival booths, Japanese gardens, a library, and children's bull fights. At its peak, the town held 10,000 visitors. The tents came down by 1939, when they could no longer compete with the rising popularity of the roadside motel. ### A BIKE RIDE AROUND CORONADO ### MORNING Begin at **Bikes& Beyond** at the **Ferry Landing Market Place**. Walk to the sidewalk facing the harbor and enjoy the city view. Pedestrians and joggers also use this sidewalk, so proceed cautiously. Around the corner, you will face the **Coronado Bridge** ; the bougainvillea-covered walls on the right mark the **Marriott Resort**. Information boards on the way depict harbor wildlife and a map indicates the various navy yards. Under the bridge, the path turns away from the water. At the street, bear left and cross over. There is no protected bike path, but traffic is light on Glorietta Blvd. At the marina, the road will fork; take the lower road to the left. Turn right at the stop-light and get off your bike; bike riding is forbidden on Orange Avenue. **Moo Time Creamery** _(1025 Orange Ave)_ serves delicious homemade ice cream and smoothies. Walk your bike back to the **Hotel del Coronado** and check out the shops on its lower level. Leaving the hotel, bear left to Ocean Avenue; the Pacific Ocean is on the left and several mansions, built in the 1900s–1920s, are on the right. Turn right on Alameda and ride through a typical Coronado neighborhood with Spanish-style houses and bungalows. At 4th, cross the street and walk one block; the **Naval Air Station** will be on your left. Turn right on 1st. It's a straight stretch back to the Market Place. Back to Ocean Beach, Coronado, and the South Back to San Diego Area by Area # Shopping ## 1. Shops at the Hotel del Coronado Google Map You'll find some of the best shopping in Coronado among these extensive shops in the hotel, including women's upscale casual wear, sunglasses, toys, jewelry, and the books of L. Frank Baum. ## 2. Ferry Landing Marketplace Google Map Next to the Coronado Ferry dock, this place offers an eclectic selection of souvenirs, clothing, and galleries. A great farmers' market sets up on Tuesday afternoons. Ferry Landing Marketplace ## 3. Bookstar/Loma Theatre 3150 Rosecrans Place • (619) 225-0465 Google Map Barnes & Noble's branded store Bookstar is set in the vintage Loma Theatre, with its original facade, and makes for a special experience. ## 4. Coronado Museum of History and Art Store Google Map Head to this museum store for historic photos, posters, and books, as well as a fun selection of _Wizard of Oz_ -themed gifts – author L. Frank Baum lived in Coronado. ## 5. Liberty Station 2640 Historic Decatur • 619 573 9300 Google Map You'll find exciting art stores, grocers, wine shops, bakeries, chocolatiers, ethnic jewelry, and more at this waterfront market location _(seeLiberty Station)_. Entertainment events are also held frequently. ## 6. Bay Books 1029 Orange Ave, Coronado • 619 435 0070 Google Map This independent bookstore has helpful staff, an ample selection of books of local interest and international papers and magazines. ## 7. Newport Avenue Ocean Beach Google Map The main drag through Ocean Beach is chock full of antique shops. Some doorways front malls with dozens of shops inside. Finds range from 1950s retro pieces to Victorian and Asian antiques. ## 8. Ocean Beach People's Organic Food Market 4765 Voltaire St • 619 224 1387 Google Map This co-op market has been selling organic, minimally processed natural foods since 1971. For food to go, try the upstairs vegan deli. Non-members are welcome but will be charged a small percentage more. ## 9. Blue Jeans and Bikinis 971 Orange Ave, Coronado • 619 319 5858 Google Map The trendiest blue jeans, along with a wide selection of bikinis, boots, and accessories, are all part of the changing inventory here. ## 10. Las Americas Premium Outlets San Ysidro Google Map Within walking distance of the border with Mexico, you can stop by this _(seeLas Americas Premium Outlets)_ immense 560,000-sq-ft (52,000-sq-m) outlet center. Back to Ocean Beach, Coronado, and the South Back to San Diego Area by Area # Places to Eat ## 1. 1500 Ocean Hotel del Coronado, 1500 Orange Ave • 619 435 6611 • $$$ Google Map The atmosphere here is light, as is the cuisine. There is a good choice of wines from Southern California's finest vineyards. ## 2. Chez Loma 1132 Loma Ave, Coronado • 619 435 0661 • Closed Mon • $$ Google Map The luscious French cuisine will put you in heaven. Diners can get great- value meals in the early-bird special. ## 3. Clayton's Coffee Shop 979 Orange Ave • 619 435 5425 • No credit cards • $ Google Map Come here for home-style cooking. A quarter buys three jukebox plays. ## 4. Primavera Ristorante 932 Orange Ave, Coronado • 619 435-0454 • $$$ Google Map Legendary northern Italian cuisine is served here in an intimate setting. The _tiramisu_ is exceptional. ## 5. Miguel's Cocina 1351 Orange Ave, Coronado • 619 437 4237 • $$ Google Map Colorfully dressed waitresses serve up enormous plates and lethal margaritas. The enchiladas, tacos, and burritos are delicious. Outdoor patio at Miguel's Cocina ## 6. Hodad's 5010 Newport Ave • 619 224 4623 • $ Google Map Soak up the "junkyard Gothic" ambience at this beach café devoted to burgers, brews, and surf. ## 7. Point Loma Seafoods 2805 Emerson St • 619 223 1109 • $ Google Map Order the freshest seafood in San Diego. Salads and sushi are popular. ## 8. Island Prime 880 Harbor Island Dr • 619 298 6802 • $$$ Google Map With its waterfront view and excellent service, this is a preferred spot for special occasions. ## 9. Peace Pies 4230 Voltaire St • 619 223 2880 • $ Google Map Pick up picnic fare or eat in the small dining area or on the outdoor patio. All choices are vegan and gluten free. ## 10. Lobster West 1033 B Ave, Coronado • 619 675 0002 • $ Google Map Fresh Maine lobster is shipped overnight for the delicious lobster rolls, creamy bisque, and the salads. See restaurant price categories Back to Ocean Beach, Coronado, and the South Back to San Diego Area by Area Back to San Diego Area by Area # NORTHERN SAN DIEGO San Diego's explosive growth has been concentrated in North County, formerly an area of wide-open spaces. Prosperous hi-tech, biotech, commercial, and financial businesses have relocated here and play a major role in the city's development. Over one million people live in communities with distinct identities, from the high-end rural estates of Rancho Santa Fe to the more modest housing of Marine Corps families in Oceanside. Travel through fabled beach resorts into laid-back surfer towns and active Camp Pendleton Marine Base, or head east from Oceanside past flower farms and avocado groves, filled with blooms and fruit. ## 1. SeaWorld 500 Sea World Dr, Mission Bay • 619 226 3901 • Open daily • Adm (special prices online) • www.seaworld.com/sandiego Google Map Opened in 1964, SeaWorld covers 150 acres (60 ha) of Mission Bay and allows visitors to see many ocean creatures up close. Its family-oriented thrill rides can compete with those of most adventure parks. It also has a rehabilitation program for stranded marine animals. However, less positive aspects of SeaWorld have come to light since the release of the 2013 documentary _Blackfish_. The park has come under strong criticism, seeing a downturn in public opinion and visitors. ## 2. San Diego Zoo Safari Park 15500 San Pasqual Valley Rd, Escondido • 760 747 8702 • Open 9am–5pm daily (mid-Jun–mid-Sep & mid- to end Dec: to 9pm) • Adm Google Map Many people prefer the Zoo Safari Park to its sister zoo in Balboa Park. By monorail, zipline, or a range of safaris, experience African and Asian animals roaming freely in enormous enclosures. Don't miss the Tull Family Tiger Trail, which takes you up close to Sumatran tigers. A successful breeding program works with more than 165 endangered species, including rhinos and lions. Fountain in the San Diego Botanic Garden ## 3. Mission San Luis Rey de Francia 4050 Mission Ave, Oceanside • 760 757 3651 (ext. 117) • Open 9:30am–5pm Mon–Fri, 10am–5pm Sat & Sun • Adm • www.sanluisrey.org Google Map Named after canonized French king Louis IX, this mission was the last established in Southern California. Relations between the missionaries and the indigenous population were so successful that when Father Peyri was ordered by the Mexican government to return to Spain in 1832, the Native Americans followed him to San Diego Harbor. Today's restored mission has displays on life and artifacts of the mission era and also offers popular retreats. Mission San Luis Rey de Francia ## 4. La Jolla Google Map Surrounded on three sides by ocean bluffs and beaches boasting spectacular views, this gorgeous enclave is noted for upscale shops, boutiques, and fine-dining restaurants. Often cited as having the most expensive properties in the country, it is also home to several prestigious educational and research facilities _(seeBrain Power)_. Torrey Pines offers a number of hiking trails and the famous Torrey Pines Golf Course. La Jolla cove ## 5. Pacific Beach Google Map Residents here enjoy an endless summer climate and easy-going lifestyle. Life revolves around Garnet Avenue's nightclubs, cafés, late-night restaurants, and shops. The street ends at the 1927 Crystal Pier, a great spot to see surfers, or spend a night in a tiny cottage. Come early to claim a fire ring on the beach and cook up some marshmallows, or cycle the boardwalk to Mission Beach. Hale Telescope, Palomar Observatory ## 6. Palomar Observatory 35899 Canfield Road, Palomar Mountain • 760 742 2119 • Open 9am–3pm daily (to 4pm Apr–Oct) Google Map Atop one of North County's highest mountains, the dome of the observatory has an otherworldly look. Part of the California Institute of Technology, Palomar is home to the 200-in (508-cm) Hale Telescope, the largest optical instrument of its kind when installed in 1947. Its moving parts weigh 530 tons, the mirror 14.5 tons. Thanks to computer technology, no one "looks" through the telescope anymore. Self-guided tours offer a look at the telescope itself. ## 7. San Diego Botanic Garden 230 Quail Gardens Drive, Encinitas • 760 436 3036 • Open 9am–5pm daily (exc. Christmas Day) • Adm Google Map This is a treasure-packed expanse of nearly two dozen gardens on well-marked pathways, with viewpoints, sculpture exhibits, garden shops, and plenty of opportunities for bird-watching. Dedicated areas display Australian, African, Mexican, and Central American gardens; succulents and dragon trees; and the country's largest bamboo collection. There's also a Native Plants and Native People trail. ## 8. Temecula Wine Country Thornton Winery: 32575 Rancho California Rd; 951 699 0099 • Callaway Vineyard & Winery: 32720 Rancho California Rd; 951 676 4001 Google Map During the mission days, Franciscan friars recognized that San Diego's soil and climate were ideal for planting grape vines. However, it wasn't until the 1960s that wine was first produced commercially. Now over two dozen wineries stretch across rolling hills studded with oak trees, most of them along Rancho California Road. Wineries offer tastings for a small fee, and many of them operate restaurants and delis. Two of the most popular wineries in the area are Thornton Winery and Callaway Vineyard & Winery. Temecula Wine Country ## 9. Rancho Santa Fe Google Map This well-kept secret enclave, about 5 miles (8 km) east of the coast, harbors exquisite estates for the wealthy. Home to around 3,000 residents, in 1989, The Covenant of Rancho Santa Fe was designated a California Historical Landmark as a historic planned community. Responsibility for this honor rests with architect Lillian Rice, who designed it in 1921. It is a lovely place to explore and dine in. Luxurious living in Rancho Santa Fe ## 10. Mission Beach Google Map The California beach scene struts in full glory along a narrow strip of land filled with vacation rentals and beachwear shops. Skaters, cyclists, and joggers whiz along the Strand, while surfers and sun worshipers pack the sand. Sometimes the streets become so crowded on the Fourth of July weekend that the police have to shut the area down. A block away, Belmont Park is an old-fashioned fun zone with a vintage roller coaster. ### BRAIN POWER Beneath San Diego's "fun in the sun" image is one of the country's most educated populations. With one of the nation's highest incidences of PhDs per capita, 30 percent of residents hold college degrees, and 20 percent of adults are in higher education. La Jolla boasts some of the most prestigious research facilities: the Salk Institute, Scripps Research Institute, Scripps Institution of Oceanography, and UC San Diego. ### A MORNING IN LA JOLLA ### MORNING Begin by looking out the front door of the landmark **La Valencia Hotel**. Turn left onto Prospect Street and walk past restaurants and art galleries. Before you reach Coast Boulevard, a stairway to the left leads to the Sunny Jim Cave, a fascinating, ocean-carved cave, named by L. Frank Baum. To the left of the entrance, a platform overlooks the caves. Continue along Coast Boulevard, admiring views of Torrey Pines and Scripps Pier. Pass through **Ellen Browning Scripps Park**. Beyond the end of the park is **Children's Pool**. Check out the seals and sea lions. Turn left on Cuvier Street and left onto Prospect Street. You'll now be at the **Museum of Contemporary Art**. Check out the exhibits or have a snack in the café. Louis Gill designed the original museum and the older architecture in this area. Walk back toward the village and peek inside 780 Prospect St; the cottage dates back to 1904. Cross Prospect at Fay but keep on Prospect. Pass through the Arcade Building to Girard Avenue. Turn right and window-shop along La Jolla's main street. Of note is **Warwick's** _(7812 Girard Ave; La Jolla)_ , a stationer and bookstore, and **R. B. Stevenson Gallery** _(7661 Girard Ave; La Jolla)_. Go north on Girard for a block and a half, and then finish your walk with one of the freshly baked delights at **Girard Gourmet**. Back to Northern San Diego Back to San Diego Area by Area # Coast Highway 101 ## 1. The Flower Fields 5704 Paseo del Norte, Carlsbad • Adm Google Map In spring, the hillsides explode with brilliant-colored blossoms of the giant tecolote ranunculus. The Carlsbad Ranch harvests 6–8 million bulbs for export. ## 2. LEGOLAND® 1 Legoland Dr, Carlsbad • 760 918 5346 • Adm Google Map This theme park and aquarium is devoted to the plastic brick. Kids enjoy the hands-on activities, waterpark, and models. ## 3. Del Mar Google Map The wealthiest community among North County's beach towns, Del Mar is filled with sidewalk cafés and shops. ## 4. Solana Beach Google Map At this popular beach town, Cedros Design District shops and cafés are two blocks from Fletcher Cove; check with lifeguards before you swim. ## 5. Cardiff-by-the-Sea Google Map Surfers enjoy the reef break at Cardiff, while RV campers kick back at a beachside campground. The San Elijo Lagoon offers hiking trails through an ecological reserve. ## 6. Leucadia Google Map The 21st century hasn't yet hit this sleepy town with a small beach and shops, restaurants, and galleries. ## 7. Carlsbad Google Map In the 1880s, Captain John Frazier discovered that the water here had the same mineral content as a spa in Karlsbad, Bohemia. Today, this pretty village still draws visitors with its beaches, resorts, and shops. ## 8. Oceanside California Surf Museum: 312 Pier View Way; 760 721 6876; open 10am–4pm daily; adm Google Map Town fortunes are tied with adjoining Camp Pendleton. The California Surf Museum shows a history of the sport. ## 9. Camp Pendleton Google Map Endangered species and abundant wildlife thrive at the largest US Marine Corps base and amphibious training facility in the country. ## 10. Encinitas Self-Realization Fellowship Retreat and Hermitage: 215 W. K St • San Diego Botanic Garden: 230 Quail Gardens Dr; adm Google Map Highlights in Encinitas include the Self-Realization Fellowship Retreat and Hermitage and the San Diego Botanic Garden. San Diego Botanic Garden, Encinitas Back to Northern San Diego Back to San Diego Area by Area # Shopping ## 1. San Diego Botanic Garden Gift Shops 230 Quail Gardens Drive, Encinitas • 760 436 3036 Google Map Set in a public garden with more than 4,000 plant species from around the world, these shops sell unique home and garden decor, books, locally made jewelry and more. There's also a selection of plants, most propagated from species found in the garden. A San Diego Botanic Garden shop ## 2. REI 5556 Copley Dr • 858 279 4400 Google Map The go-to store for all your outdoor and sports needs, REI also provides equipment rental for biking, camping, and more. In addition, it organizes activities such as full-moon hikes and offers rock-climbing lessons. ## 3. Chino 6123 Calzada del Bosque, Rancho Santa Fe • 858 756 3184 Google Map The Chino family farm and its store cater to famous chefs and lovers of superb fruit and vegetables. ## 4. Encinitas Seaside Bazaar 459 South Coast Highway 101, Encinitas • 760 753 1611 Google Map This year-round open-air market offers unique antiques and home decor, arts and crafts, and various other delightful surprises. ## 5. Fresh Produce 1147 Prospect St, La Jolla • 858 456 8134 Google Map Colorful, comfy womenswear epitomizes the region's laid-back lifestyle. The pieces here flatter most shapes and sizes. Also stocked are bags, hats, and other seaside needs. ## 6. Trader Joe's 1211 Garnet Ave, Pacific Beach • 858 272 7235 Google Map This market sells imaginative salads, a wide variety of cheeses, wine, and fun ethnic food that you won't find in a regular supermarket. ## 7. Carlsbad Premium Outlets 5620 Paseo del Norte, Carlsbad Google Map Shop for bargains in one of the most pleasant outlet centers around. Gap, Bass, Salvatore Ferragamo, and Jones New York are all here. ## 8. Cedros Design District Cedros Ave, Solana Beach Google Map This former warehouse district has been transformed into a shopping street full of design stores, furnishings, and boutiques. The 100 shops at the Leaping Lotus offer ethnic goods, clothing, and furniture. ## 9. Del Mar Plaza 1555 Camino Del Mar, Del Mar Google Map Italian home accessories, estate art, and well-known chains such as Banana Republic and White House/Black Market can be found here. ## 10. Winery Gift Shops Google Map Most wineries in Temecula operate gift shops that stock unusual cookbooks, entertaining supplies, and home decor items. Additionally, many have delis where you can find picnic food to accompany that bottle of wine you just bought. Back to Northern San Diego Back to San Diego Area by Area # Cafés and Bars ## 1. Belly Up Tavern 143 S. Cedros Ave, Solana Beach • 858 481 9022 • Adm Google Map One of the best live music venues in the county. Old Quonset huts have been acoustically altered to showcase bands. The palm-lined entrance to the Belly Up Tavern ## 2. Encinitas Ale House 1044 S. Coast Hwy 101, Encinitas • 760 943 7180 • $$ Google Map Popular for burgers and ales, this cozy place has 32 taps rotating Belgian and German beers, craft beers, and international microbrews. ## 3. Wild Note Café 143 S. Cedros Ave, Solana Beach • 858 720 9000 • $ Google Map Come here for lunch, served outside or under structural beams. Dinner time tends to be hectic. ## 4. Brockton Villa 1235 Coast Blvd, La Jolla • 858 454 7393 • $$ Google Map This historic place offers breakfast, lunch, or dinner, and fabulous views. Choices include seafood and steak. ## 5. Pannikin 510 N. Coast Hwy 101, Encinitas • 760 436 5824 • $ Google Map Don't miss this coffeehouse located inside a Santa Fe Railroad Depot. Sit upstairs or outside on a shady deck. ## 6. Living Room Coffeehouse 1010 Prospect St • 858 459 1187 • $ Google Map Grab a back table at this hip coffeehouse in upscale La Jolla to enjoy a million-dollar view. ## 7. Ruby's Diner 1 Oceanside Pier, Oceanside • 760 433 7829 • $ Google Map Walk 1,942 ft (591 m) out to the pier's end and order a salad or burger and a malt at this 1940s-style diner. ## 8. VG Donut & Bakery 106 Aberdeen Drive, Cardiff • 760 753 2400 • $ Google Map This local favorite offers dozens of variations of wedding cakes, pastries, bear claws, bagels, fresh hot donuts, cookies, and much more. ## 9. Lotus Café and Juice Bar 765 S. Coast Hwy 101, Encinitas • 760 479 1977 • $ Google Map Lotus is especially appealing to vegetarian and vegan diners, but meat dishes are also offered. Juices are freshly squeezed. ## 10. Lean and Green Café 7825 Fay Ave, Suite 180, La Jolla • 858 459 5326 • $ Google Map The organic offerings here include wraps, salads, and smoothies, as well as vegan and gluten-free items. Back to Northern San Diego Back to San Diego Area by Area # Places to Eat ## 1. Del Mar Rendezvous 1555 Camino Del Mar, Suite 102, Del Mar • 858 755 2669 • Closed Thanksgiving Day & Super Bowl Sun • $$ Google Map Book in advance for this popular modern Chinese restaurant, which also lists more than 100 wines. ## 2. Poseidon 1670 Coast Blvd, Del Mar • Closed Thanksgiving & Christmas Days • 858 755 9345 • $$ Google Map The patio here is great for lunch, dinner, weekend brunch, and cocktails at sunset. ## 3. Eddie V's Prime Seafood 1270 Prospect St, La Jolla • 858 459 5500 • $$$ Google Map Fresh seafood and meat dishes. Every table has a view of La Jolla Cove, and there's live jazz nightly. A plate of food at Eddie V's Prime Seafood ## 4. 101 Café 631 S. Coast Hwy, Oceanside • 760 722 5220 • $ Google Map Since its 1928 beginnings as a roadside diner, folks passing through have enjoyed the home-style comfort food. ## 5. Emerald Chinese Seafood Restaurant 3709 Convoy St, Kearny Mesa • 858 565 6888 • $$ Google Map Favorites here include crispy Peking duck and tender filet mignon. ## 6. The Marine Room 2000 Spindrift Dr, La Jolla • 866 644 2351 • $$$ Google Map Ensure that you bring a big appetite for the Monday Maine Lobster night! ## 7. Sushi Ota 4529 Mission Bay Dr • 858 270 5670 • $$ Google Map Considered the best spot for sushi in town, connoisseurs come to Sushi Ota for the day's freshest fish transformed into tasty works of art. ## 8. Baci Ristorante 1955 W. Morena Blvd • 619 275 2094 • $$ Google Map Enjoy traditional veal, seafood, and pasta here, along with your choice of wine from an extensive list. ## 9. Mille Fleurs 6009 Paseo Delicias, Rancho Santa Fe • 858 756 3085 • $$$ Google Map The most acclaimed restaurant in San Diego County provides a culinary feast. Fireplaces, fresh flowers, and tapestries complement the exquisite and beautifully presented food. Elegant seating at Mille Fleurs ## 10. Vigilucci's Cucina Italiana 2943 State St, Carlsbad • 760 434 2500 • $$ Google Map Classic antipasti, soups, and substantial servings of pastas and entrées are crowd-pleasers here, as is the daily happy hour. See restaurant price categories Back to Northern San Diego Back to San Diego Area by Area * * * Streetsmart A cart displaying goods for sale at the Old Town Market ## Streetsmart 1 | Getting To and Around San Diego ---|--- 2 | Practical Information ---|--- 3 | Places to Stay ---|--- Back to Streetsmart # GETTING TO AND AROUND SAN DIEGO ## Arriving by Air **San Diego International Airport** (SAN), also known as Lindbergh Field, is only 3 miles (5 km) northwest of downtown San Diego. **Alaska Airlines** , **Frontier Airlines** , and **Southwest Airlines** operate from Terminal 1, with all other airlines at Terminal 2. The free Airport Loop shuttle bus connects the two terminals. The only non-stop international flights are to and from Canada, Mexico, Japan, and the UK. Taxis and door-to-door shuttles may be found at the Transportation Plaza, accessible to Terminal 1 via a skybridge and to Terminal 2 directly across the street by exiting baggage claim. Just outside baggage claim, bus route 992 takes approximately 10 minutes to downtown San Diego. It stops at the corner of W. Broadway and Kettner, which is directly across the street from the Santa Fe Depot (Amtrak and the Coaster) and America Plaza (trolley). Buses run every 15 minutes from 5am to 11:30pm on weekdays and every 30 minutes on weekends. **Tijuana International Airport** is located 5 miles (8 km) east of downtown Tijuana, with frequent flights to the rest of Mexico, as well as direct flights to and from China and Japan. Domestic flights within Mexico are often cheaper than flying internationally from California. If you are a ticketed passenger, a fee-based pedestrian bridge to the border is a 5-minute walk from baggage claim. After immigration, shuttles are available to San Ysidro (every 30 minutes from 5am to 2am) or the Santa Fe Depot (every 2 hours from 5:30am to 1:30am). Check **SuperShuttle** 's website for more information. ## Arriving by Train **Amtrak** 's Pacific Surfliners arrive at the historic **Santa Fe Depot** , as does **Coaster**. About 11 trains travel daily to and from Orange County and Los Angeles, and several continue on to Santa Barbara. ## Arriving by Road **Greyhound** buses cover the entire US and most of Canada. There are direct connections from Los Angeles, with many continuing to the border and Tijuana's central bus terminal. A few daily buses go directly to Phoenix. By car from Los Angeles, I-5 passes along coastal towns, heads into downtown, and continues to the international border at San Ysidro. Shortly before La Jolla, I-5 splits with I-805, reconnecting at the border. If driving from the east, I-8 passes through Mission Valley and ends just past SeaWorld. I-15 from Las Vegas serves inland San Diego County. ## Arriving by Cruise Ship All cruise ships moor at B Street Terminal along the Embarcadero on N. Harbor Drive within easy walking distance of downtown. Popular sailings include the Mexican Riviera or mini-cruises to Ensenada and Catalina. A number of ships sail to and from Canada and Alaska, Hawaii, and Panama. ## Traveling by Train A regional commuter rail service runs daily between the Santa Fe Depot and Oceanside. You can buy tickets at vending machines at stations and use them for 2 hours after purchase. ## Traveling by Bus and Trolley Public transport will take you just about anywhere in the city. The **San Diego Metropolitan Transit System** runs buses and trams. City buses connect with the **North County Transit District** , which serves coastal and inland San Diego County. Inexpensive and fun, the red trolley is a light-rail system with three lines. The Blue line travels between the **America Plaza** downtown and the Mexican border at San Ysidro. The Green line is handy for the Gaslamp Quarter, the Convention Center, and Seaport Village. The Orange line crosses downtown and continues out to El Cajon. Buses and trolleys operate from 4:30am until midnight. You can only buy tickets on the bus with exact change. Single adult fares are $2.25, except for express buses. Single adult trolley tickets are $2.50, valid for 2 hours. Vending machines sell trolley tickets at each stop. No transfers are allowed between buses and trolleys. If you plan to hop on and off buses and trolleys, 1- to 4-day, and 14-day passes are available but only with a Compass Card. Reloadable Compass Cards may be purchased for $2 at The Transit Store and Albertson's and Vons supermarkets throughout San Diego. ## Traveling by Car You won't need a car in downtown San Diego, but it's essential to get around the rest of the city or region. A few car-rental agencies also have cars you can drive into Mexico, but you will need to agree this with your agent before traveling and buy additional insurance at the border. These include **Budget** and **California Baja Rent-a-Car**. ## Traveling by Taxi Taxis don't cruise for fares. You can usually find a stand in front of large hotels, the airport, and some shopping centers. Rates are posted on the taxi door; distances can make some trips expensive. You can also call **San Diego Taxi Company** for a ride. **Uber** services are very popular and arguably more affordable. ## Traveling by Water Taxi On-call **San Diego Water Taxis** will transport you to locations around the harbor. They run from Friday to Sunday, noon to 10pm. ## Traveling by Ferry **Flagship Cruises** operates a service between San Diego and Coronado. Ferries depart from Broadway Pier at 990 N. Harbor Drive and the Convention Center Marina. From Coronado, ferries leave from the Coronado Ferry Landing, 1201 First Street. Ferries leave hourly from 9am to 9pm (to 10pm on Friday and Saturday). One-way fares are $4.75. ## Traveling by Bicycle The greater San Diego region has over 1,300 miles (2,090 km) of bikeways. Public bicycles may be rented on an hourly basis or unlimited usage with a monthly membership. **The Bike Revolution, Deco Bike** and **Stay Classy Bike Rentals** all offer good deals. ### DIRECTORY ### ARRIVING BY AIR #### Alaska Airlines alaskaair.com #### Frontier Airlines flyfrontier.com #### San Diego International Airport san.org #### Southwest Airlines southwest.com #### SuperShuttle 800 258 3826 supershuttle.com #### Tijuana International Airport www.airport-tijuana.com/ ### ARRIVING BY TRAIN #### Amtrak amtrak.com #### Coaster gonctd.com #### Santa Fe Depot 1050 Kettner Blvd ### ARRIVING BY ROAD #### Greyhound 1313 National Avenue greyhound.com ### TRAVELING BY BUS AND TROLLEY #### America Plaza Kettner Blvd & W. Broadway #### North County Transit District gonctd.com #### San Diego Metropolitan Transit System sdmts.com ### TRAVELING BY CAR #### Budget www.budget.com/en/locations/us/ca/san-diego #### California Baja Rent-a-Car cabaja.com/usa-rentals ### TRAVELING BY TAXI #### San Diego Taxi Company 619 566 6666 #### Uber uber.com ### TRAVELING BY WATER TAXI #### San Diego Water Taxi 619 234 4411 ### TRAVELING BY FERRY #### Flagship Cruises flagshipsd.com/cruises/coronado-ferry ### TRAVELING BY BICYCLE #### The Bike Revolution thebikerevolution.com #### Deco Bike decobike.com #### Stay Classy Bike Rentals stayclassybikes.com Back to Getting to and Around San Diego Back to Streetsmart Back to Streetsmart # PRACTICAL INFORMATION ## Passports and Visas All visitors to the US must have a valid passport. Citizens of 38 countries may enter without a visa under the Visa Waiver Program for stays of up to 90 days. To use this program, you must have an e-passport embedded with an electronic chip; prior to travel, apply for eligibility through the Electronic System for Travel Authorization ( **ESTA** ). On arrival in the US, a Customs and Border Protection officer will make the final determination to allow entry. A number of countries including the **UK** , **Canada** and **Australia** have consulates in California and are able to provide assistance to their nationals. ## Customs and Immigration If clearing customs and immigration at San Diego International Airport, the process is straightforward. If crossing at the San Ysidro International Border, expect long lines and additional scrutiny if you've come from the interior of Mexico. Everyone above the age of 21 is allowed 1 liter of liquor and 200 cigarettes duty free. Citizens may bring in $400 worth of gifts; non-citizens, $100. Cash exceeding $10,000 must be declared. Fresh produce, meats, plants, and products from endangered species are prohibited. ## Travel Safety Advice Visitors can get up-to-date travel safety information from the **UK Foreign and Commonwealth Office** , the **US Department of State** , and the **Australian Department of Foreign Affairs and Trade**. ## Travel Insurance Be sure to obtain travel insurance before arriving in the US; this will cover you for trip interruptions, lost baggage, and some limited medical expenses. If coming from abroad, always check with your primary healthcare insurer at home to see if you have any coverage while in the US. An international medical insurance policy is a good idea to protect you against the unexpected. Although you won't be denied medical care if you fall ill in the US, you can expect a staggeringly large bill. If renting a car, establish what your auto insurer and credit card company covers in case of accident or theft. An auto insurance policy is not valid in Mexico; if you plan on driving there it's important to buy Mexican insurance before you cross over the border. ## Health Enjoy the brilliant sunshine, but slather on the sunscreen during the day, and be sure to take a hat whenever you're outdoors. California has one of the highest incidences of skin cancer in the USA – no surprise since people pursue outdoor activities year round. Ocean waters are generally clean, except after a heavy storm; accumulated and untreated runoff from miles away washes down storm drains and empties into the ocean, and sewer leaks are common. Smoking is forbidden inside any public enclosed area, including restaurants and bars. The city has banned smoking in parks, on beaches and and open spaces. San Diego has some of the country's best hospitals including **Scripps Hospiral La Jolla** and **Scripps Mercy Hospital** with 24-hr emergency rooms. If it is not a life-threatening situation, opt for urgent-care clinics which are less expensive. If you don't have health insurance, head to a community clinic. Expect to pay on the spot for services rendered. Many pharmacies in the city, such as CVS, Rite-Aid, and Walgreens, are open 24 hours. ## Personal Security San Diego is a safe city; most petty crime is limited to theft and car break-ins. Common sense prevails: don't walk around late at night, and don't leave valuables inside your car. San Diego's proximity to the Mexican border makes car theft a concern – if your car is found across the border, the paperwork to bring it back is overwhelming. Neighborhoods prone to theft include Pacific Beach, San Ysidro, and Mission Valley. Dangerous riptides can occur along the coastal beaches; ask lifeguards about swimming conditions at unfamiliar beaches. Posted green flags indicate safe swimming, yellow mean caution, and red flags denote hazardous surf. If you are caught in a riptide, let the current carry you down the coast until it dies out, then swim in to the shore. San Diego International Airport has a **Lost and Found** department. If you lose an item on the transit system, call **The Transit Store**. Items of value will be transferred to the police department after a set time. San Diego is safe for women travelers, but lone females should always be alert to their surroundings, especially after dark. While the incidence of rape in San Diego is not high, a **rape crisis hotline** is available in an event of sexual assault. Don't walk on the beach alone at night, be careful in parking lots, take the usual precautions at hotels, and control alcohol intake. ## Emergency Services During an **emergency** , dial 911 from any tele-phone. Be prepared to specify your location and whether medical and/or police assistance is needed. Call the **San Diego Police** department for all other matters. ## Travelers with Specific Needs The excellent booklet _Access in San Diego_ , published by **Accessible San Diego** , gives specific access information on many hotels, restaurants, and shopping centers. Also included are public and private transportation firms equipped with lifts, and car rental agencies that offer hand-controlled vehicles. You'll also find a directory of medical equipment suppliers and disability organizations. All buses, trolleys, and the Coaster are equipped with lifts. Amtrak trains have limited accessible spaces and recommend advance reservations. Greyhound provides a lift-equipped bus with advance notice. Super Shuttle provides transportation from the airport, also with advance notice. If driving your own car, reserved parking spaces are marked by a blue curb, a blue-and-white wheelchair logo on the pavement, and by a posted sign. You may park for free in most metered areas, but a special permit must be displayed. Every intersection and sidewalk in San Diego has ramped curbs or at least a ramped driveway. Ramped access is standard in government buildings, museums, some theaters, and large hotels and restaurants. Hotels with more than five rooms must provide accessible accommodation. It is best to call in advance to reserve one of these rooms, and specify if you need a roll-in shower. When making restaurant reservations, do clarify that you require access. Imperial Beach, Ocean Beach, Coronado, Mission Beach, Oceanside, Silver Strand State Beach, and La Jolla Shores have power and manual beach chairs. These are free to use, but it's best to book ahead. ## Currency and Banking Denominations of paper bills are in $1, $2, $5, $10, $20, $50, and $100. Rare but still in circulation are paper bills of $2, $500, $1000, $5000, $10,000 and $100,000. Coins are 1¢, 5¢, 10¢, 25¢, 50¢, and $1. The $1 coins have a slight gold cast to them and are slightly larger and heavier than a 25¢ coin. If paying for anything in cash with a merchant, expect to have any paper bills larger than a $20 scrutinized. San Diego International Airport has international exchange kiosks in Terminal 1 and Terminal 2. **Travelex** has two other locations in Horton Plaza and Fashion Valley. Major banks handle most transactions, but you will need to bring plenty of ID. Large hotels exchange currency as well, but offer low rates. Exchange windows in San Ysidro handle transactions in dollars and pesos. There are 24-hour automatic teller machines (ATMs) all over the city. Look on the back of your bank card or credit card to see which network it's associated with. ATMs inside convenience stores or malls charge you for use, as does your own bank if you go outside the network. Most major banks are found throughout San Diego. Banking hours are usually 9am or 10am until 6pm, Monday through Friday, with Saturday hours from 9am to 1pm or 2pm. **Visa** and **MasterCard** credit and debit cards are widely accepted, **Diners Club** and **American Express** cards slightly less so. If using a non-US-issued credit card, make sure it has a magnetic strip on the back, since chip-and-pin readers are not common. ## Telephone and Internet Coin telephones are hard to find in San Diego, but they still exist at San Diego International Airport, transit stations, hospitals, some hotels and restaurants, and government buildings. You may dial emergency services on 911 without coins from any of these phones. If you carry an unlocked phone, you can find SIM cards with a variety of prepaid, no-contract plans at supermarkets, corner stores, Target, and Walmart. T-Mobile and AT&T stores also carry SIM cards. There are free Wi-Fi hotspots all over the city: in cafés, fast-food restaurants, and even in Horton Plaza shopping center. Public libraries also have computer terminals to use, as do hostels, but you must be a guest. Most hotels offer free Wi-Fi, as does San Diego International Airport but in 30-minute sessions. ## Postal Services Regular post office hours are 8:30am–5pm Monday to Friday, with some branches open on Saturday mornings. Stamps are usually available from vending machines in the lobby, and signage indicates the cost of postage for mail sent to domestic and international addresses. Stamps are available at many supermarkets and franchised mail service stores, which also provide shipping services. Hotel concierges can post mail for you. **FedEx** and **UPS** offer courier services with guaranteed overnight delivery and reliable international service. Many of their franchise offices sell packaging supplies. Much cheaper, the US Postal Service offers overnight service in the continental US and two- and three-day services internationally. ## Television, Radio, and Newspapers All four major US television networks have affiliate local channels in San Diego ( **10 news** for ABC, **CBS 8** for CBS, **Fox 5 San Diego** for Fox and **NBC 7 San Diego** for NBC). Public broadcasting is represented as well. Local news and talk radio stations include **KOGO** , **KFMB** and **KPBS**. The morning local newscast traffic reports can be particularly useful. Try to listen to them before you head out in the morning and you may save yourself from a massive traffic jam. Newspapers can be found at stands throughout the city. The daily **_San Diego Union Tribune_** is strong in regional news on both sides of the border. The **_San Diego Reader_** is the best source of the latest happenings in town. You'll find details of movies and theater timings, and music events. Free copies can be found all over San Diego. ## Opening Hours Most museums are open from 10am to 5pm. Check the website or call before making plans, as many close one day of the week. Retail shops usually open at 10am and close at 5pm or 6pm. Regular hours at shopping malls are 10am–9pm Mon–Sat and 11am–7pm Sun. Department stores sometimes open at 7am for super-sales or extend their hours during the holiday season. Malls close only during a few major holidays, such as Christmas and New Year; however, some stores may be open on Thanksgiving (the fourth Thursday in November) and Easter Sunday. You shouldn't have any trouble finding 24-hour convenience stores, gas stations, drug stores, and supermarkets. A few Walmarts and Targets in San Diego are also open 24 hours. ## Time Difference From the first Sunday in November until the second Sunday in March, San Diego operates on Pacific Standard Time (PST), which is 8 hours behind Greenwich Mean Time (GMT). For the remaining months, the clock moves ahead 1 hour and becomes Pacific Daylight Time (PDT), or 7 hours behind Greenwich Mean Time. ## Electrical Appliances The US uses plugs with two flat blades and sometimes a third round grounding pin. Either type will fit in American sockets. Power is set at 110 volts, so 220-volt-only appliances will not work efficiently, and a power converter will be necessary. Small appliances like hairdryers or curling irons are inexpensive to buy at discount stores, and hotels usually provide hairdryers. Most modern electronics are designed to work on either the 110 or 220 system; however, if coming from abroad, you will need a plug adapter. It might be easier to buy this at home before coming to the US. Most adapters sold in US stores are just for Americans traveling abroad. If you do forget to bring an adapter, you can usually find one in a Best Buy store. ## Weather San Diego enjoys the most temperate climate in the nation. The rainy season usually begins in December, with a few large storms rolling in by spring. Winter days can be warm and sunny, but ocean temperatures are cold. Late spring often presents what locals call "May gray" and "June gloom." During this time, you often find a lot of low cloud cover, but you can just as easily get endless days of dazzling sunshine. Sometimes you might find a rare, mild summer shower. Summer evenings are pleasant but often cool, so make sure you bring a sweater or lightweight jacket with you. During the summer months, be aware that if you leave the coast and head inland the temperatures are considerably warmer. ## Visitor Information Before you travel, order a copy of the _San Diego Visitors Planning Guide_ from the **San Diego Tourism Authority** website. You may view past copies online. You'll also find links to download mobile apps for La Jolla, Little Italy, and other attractions and museums. Once you're in San Diego, stop by the **San Diego Visitor Information Center** at the Embarcadero, where staff will answer your questions about activities and tours. They also sell tickets to attractions. The **Coronado Visitor Center** can give you a map of Coronado and suggest activities in the area. ## Trips and Tours **Old Town Trolley Tours** makes 11 stops in a continuous 2-hour loop around San Diego's most popular attractions, including Old Town, the Embarcadero, Seaport Village, Horton Plaza, Gaslamp Quarter, Coronado, Balboa Park, and Little Italy. From Old Town, tours depart at 9am and every 30 minutes until late afternoon, depending on the time of year. Departure times vary from each stop. The tours are narrated and drivers are quite knowledgeable. Adult tickets are $39 ($35.10 online), and you can hop on and hop off as you please. The same company operates San Diego SEAL tours, which uses a type of amphibious vehicle to first tour the streets of the city before it enters San Diego Bay to power past Navy vessels and harbor sights, and La Jolla and Mission Beach tours. **Five Star Tours** operates bus tours to popular attractions throughout San Diego County, including Legoland, San Diego Safari Park, wine tours, city tours, and a number of trips to Tijuana and Ensenada, Mexico. **San Diego Scenic Tours** offers half- and full-day narrated tours on air-conditioned buses or mini-buses around San Diego, the harbor, and Tijuana (passports are required). Flagship Cruises offers several ways to tour the harbor. There are 1- and 2-hour narrated trips covering the harbor, Shelter Island, Point Loma, Coronado Bridge, and more. Dinner, nature, and whale-watching cruises are also available. Walking tours – like those organized by **Balboa Park Tours** and **Coronado Walking Tour** – are also very popular. ## Shopping You don't have to go far to find something to buy in San Diego. Shopping malls are everywhere, with the same stores as every shopping mall in the country. The best bargains can be found around public holidays. San Diego has three major outlet centers within an hour's driving distance: the **Carlsbad Premium Outlets** in North County, the **Las Americas Premium Outlets** at San Ysidro, and **Viejas Outlet Center** on the Viejas Indian Reservation, east on I-8. You can usually find good deals at the designer spin-off shops. Upscale boutiques are located in La Jolla, and if you're looking for unusual gifts, the museum shops in Balboa Park are a good starting point. Current sales tax in San Diego County is 8 percent. A non-refundable sales tax is added to all retail purchases. ## Dining With its proximity to the Pacific Ocean, Mexico, and surrounding ranch and farmlands, you won't go hungry in San Diego. The Gaslamp Quarter is packed with restaurants, but many are overcrowded and on the noisy side. Foodies tend to go to restaurants in Little Italy or Bankers Hill. For romantic dining with an ocean view, La Jolla offers the city's best choices. Prices of entrées in the more popular tourist areas match those of any urban area. You'll find affordable ethnic restaurants everywhere, with some of the more interesting choices in the Hillcrest neighborhood. If traveling with kids, the best family-friendly restaurants are in Mission Valley and Mission Bay. On weekends throughout the year and during the summer months, it's wise to make a reservation. Some of the better restaurants can be bought out for a private event, so call ahead rather than just show up. Lunch hours are usually 11am to 2pm or 3pm, with dinner service beginning at 5pm or 5:30pm and kitchens closing at 10pm. Dress code is casual everywhere. Most food servers expect a 15–20 percent tip; leave it in cash, or add it to your credit card bill. With large parties, an 18 percent gratuity may be automatically added to the check. Entrées on the lunch menu are often less than half the price of those at dinner. Some restaurants offer early-bird dinners from 4pm until 6pm, with a limited number of discounted entrées. Many restaurants and bars offer happy hours on weekdays. For the price of a drink and a few dollars, you can snack on anything from a hot buffet to chips and dip. Some Mexican restaurants sell inexpensive tacos on "Taco Tuesdays." Check out the advertisements in the _San Diego Reader_. The legal drinking age in California is 21. If you look under 30, restaurant servers and merchants will ask to see your photo identification. In Tijuana, the legal drinking age is 18. ## Accommodation No matter your budget, you'll find something in San Diego – from the ultra-posh to the humble dormitory-style hostel. Given the city's popularity, be sure to make your reservations early to avoid frustration. Staying at a motel chain like **Days Inn** or **Motel 6** offers standardized accommodations with no surprises. Most major chains can be found in Mission Valley's Hotel Circle. Parking is generally free, breakfast is often provided, and you aren't charged countless petty fees. If you plan to stay in San Diego for more than a few weeks, consider renting an apartment. Keep in mind that summer rentals, especially along the beach, are more costly. Be sure to ask what amenities are included. You can always find accommodations on online booking sites such as **Booking.com** and **Airbnb** , but it's important to read the reviews, which are written by bona fide guests, carefully. Sometimes the price is right but the location is remote. The only comfortable place to camp legally near the city is in **San Diego Metro KOA**. This well-located campground offers a swimming pool, hot tub, and bicycle rentals. RV owners can try **Campland on the Bay** , which also accepts tent campers. ### DIRECTORY ### PASSPORTS AND VISAS #### Australia 310 229 2300 usa.embassy.gov.au #### Canada 213 346 2700 canada.ca/Canada-In-Los-Angeles #### ESTA esta.cbp.dhs.gov #### UK gov.uk/world/usa ### TRAVEL SAFETY ADIVCE #### Australian Department of Foreign Affairs and Trade dfat.gov.au smartraveller.gov.au #### UK Foreign and Commonwealth Office gov.uk/foreign-travel-advice #### US Department of State travel.state.gov ### HEALTH #### Scripps Hospital La Jolla 858 457 4123 #### Scripps Mercy Hospital 619 294 8111 ### PERSONAL SECURITY #### Airport Lost and Found 619 400 2141 #### Rape Crisis Hotline 888 385 4657 #### The Transit Store 619 234 1060 ### EMERGENCY SERVICES #### Emergency 911 #### San Diego Police 619 531 2000 ### TRAVELERS WITH SPECIFIC NEEDS #### Accessible San Diego 619 325 7550 access-sandiego.org ### CURRENCY AND BANKING #### American Express 800 528 4800 #### Diners Club 800 234 6377 #### MasterCard 800 627 8372 #### Travelex travelex.com 877 414 6359 #### Visa 800 8472911 ### POSTAL SERVICES #### FedEx fedex.com #### UPS ups.com ### TELEVISION, RADIO, AND NEWSPAPERS #### 10 news 10news.com #### CBS 8 cbs8.com #### Fox 5 San Diego fox5sandiego.com #### KFMB 760 KFMB-AM #### KOGO 600 KOGO-AM #### KPBS 89.5 KPBS-FM #### NBC 7 San Diego nbcsandiego.com #### San Diego Reader sandiegoreader.com #### San Diego Union Tribune sandiegounion-tribune.com ### VISITOR INFORMATION #### Coronado Visitor Center 1100 Orange Ave, Coronado 619 437 8788 coronadovisitorcenter.com #### San Diego Tourism Authority sandiego.org #### San Diego Visitor Information Center 996 N. Harbor Drive 619 737 2999 sandiegovisit.org ### TRIPS AND TOURS #### Balboa Park Tours balboapark.org/visit/tours #### Coronado Walking Tour coronadowalkingtour.com #### Five Star Tours sdsuntours.com #### Old Town Trolley Tours trolleytours.com/san-diego #### San Diego Scenic Tours sandiegoscenictours.com ### SHOPPING #### Carlsbad Premium Outlets premiumoutlets.com/outlet/Carlsbad #### Las Americas Premium Outlets premiumoutlets.com/outlet/las-americas #### Viejas Outlets Center viejas.com/san-diegos-premier-outlet-mall ### ACCOMMODATION #### Airbnb airbnb.com #### Booking.com booking.com #### Campland On the Bay 2211 Pacific Beach Dr campland.com #### Days Inn daysinn.com #### Motel 6 motel6.com #### San Diego Metro KOA 111 N. 2nd Ave, Chula Vista koa.com/campgrounds/san-diego Back to Practical Information Back to Streetsmart Back to Streetsmart # PLACES TO STAY Luxury Hotels Historic Hotels Spa Hotels Business Hotels Mid-Range Hotels Waterfront Hotels Bed and Breakfasts Budget Hotels and Hostels ## Luxury Hotels ### Hard Rock Hotel 207 5th Avenue • 619 702 3000 • www.hardrockhotelsd.com • $ The contemporary rooms and suites at this hotel look out across the Gaslamp Quarter. The atmosphere is lively, and friendly staff will cater to your needs, even loaning you a Fender guitar. Enjoy a drink at the rooftop lounge or taste the impeccable food at Nobu, the on-site restaurant. ### Coronado Island Marriott Resort and Spa 2000 2nd St, Coronado • 619 435 3000 • www.marriott.com/sanci • $$ Lush grounds with a relaxed feel, and dedicated staff make this hotel a top choice. Californian and French styling prevails, with the best of the rooms looking out across the bay to San Diego. The hotel also runs a watertaxi service. ### Estancia La Jolla Hotel & Spa 9700 N. Torrey Pines Rd • 858 550 1000 • www.estancialajolla.com • $$ Elegant and airy rooms offer luxury and comfort in this Spanish ranch-style hotel surrounded by lush gardens. Indulge yourself at the spa or heated saltwater pool. A short walk leads down to the beach. ### Kimpton Solamar 435 6th Ave • 619 819 9500 • www.hotelsolamar.com • $$ This hip boutique hotel in the Gaslamp Quarter offers a complimentary wine hour every evening in the fireplace lounge. California cuisine features at the JSix restaurant, and the fourth-floor pool deck with J6Bar and fire pits is popular with the locals, too. ### La Casa del Zorro Resort & Spa 3845 Yaqui Pass Road, Borrego Springs • 760 767 0100 • www.lacasadelzorro.com • $$ This classic desert resort offers poolside rooms and private casitas, featuring wood-burning fireplaces and marble bathtubs. Facilities include a spa, fitness center, three swimming pools, and tennis courts. Conditions for stargazing in the desert sky are perfect. ### L'Auberge Del Mar Resort & Spa 1540 Camino del Mar, Del Mar • 858 259 1515 • www.laubergedelmar.com • $$ Join the list of Hollywood notables who relax at this boutique hotel and spa near the Pacific. The rooms have marble baths and many include private balconies and fireplaces. ### Rancho Bernardo Inn 17550 Bernardo Oaks Dr, Rancho Bernardo • 877 517 9340 • www.ranchobernardoinn.com • $$ Bougainvillea-adorned patios and red-tile-roof adobe buildings evoke images of early California at this relaxing resort set in stunning grounds. Life here revolves around the adjoining golf course, spa, and tennis courts. ### The Westgate Hotel 1055 Second Avenue • 619 238 1818 • www.westgatehotel.com • $$ With a lobby that suggests the anteroom of the Palace of Versailles, complete with Baccarat crystal chandeliers and French tapestries, this grand hotel offers good value for its location. Spacious rooms with European decor have city views. ### Fairmont Grand Del Mar 5300 Grand Del Mar Court • 858 314 2000 • www.fairmont.com/san-diego • $$$ Discover San Diego's inland beauty at this Spanish- and Italian-style destination resort. Luxurious rooms with fine amenities, superb service, golf, pools, spa, hiking trails, and equestrian facilities are reasons never to leave. ### Four Seasons Residence Club Aviara 7210 Blue Heron Place • 760 603 3700 • vacationrentals.fourseasons.com • $$$ With impeccable service and a superb setting, this property offers luxurious residential rentals. Choose between indoor and outdoor treatment rooms, or a suite with a whirlpool. ### The Lodge at Torrey Pines 11480 N. Torrey Pines Rd, La Jolla • 858 453 4420 • www.lodgetorreypines.com • $$$ Located on the cliffs of Torrey Pines, this lodge offers exquisite accommodations. The rooms look out onto a courtyard that reflects the surrounding coastal environment and the greens of the Torrey Pines Golf Course. Early California Impressionist art graces the walls and signature restaurant. ### Rancho Valencia Resort 5921 Valencia Circle, Rancho Santa Fe • 858 756 1123 • www.ranchovalencia.com • $$$ Bougainvillea cascades over the Spanish casitas in this stunning resort. Many rooms feature cathedral ceilings, private terraces, and fireplaces. Rejuvenation treatments include reflexology, aromatherapy, and various massages. Back to Places to Stay ## Historic Hotels ### Gaslamp Plaza Suites 520 E St • 619 232 9500 • www.gaslampplaza.com • $ Now on the National Register of Historic Places, this building still features much of its original 1913 craftsmanship, such as Australian gumwood, Corinthian marble, and an elevator door made of brass. Complimentary breakfast is served on the rooftop terrace. ### Inn at the Park 525 Spruce St • 619 291 0999 • No air conditioning • www.shellhospitality.com • $ This 1926 inn was popular with Hollywood celebrities en route to their vacations in Mexico in the 1920s and 1930s. The original fixtures lend a delightful retro touch. ### The Keating Hotel 432 F Street • 619 814 5700 • www.thekeating.com • $ Set in a historic 1890 building in the heart of the Gaslamp Quarter, this super-hip boutique hotel was created by the Italian designers responsible for Ferrari and Maserati. The rooms have open rainfall showers. ### Glorietta Bay Inn 1630 Glorietta Blvd, Coronado • 619 435 3101 • www.gloriettabayinn.com • $$ Many of the original fixtures of John D. Spreckels' 1908 Edwardian mansion remain, including the unique hand-made plaster moldings, chandeliers, and a marble staircase. Splurge on one of the antique-filled guest rooms inside the house for a more decadent experience. ### The Grande Colonial 910 Prospect St, La Jolla • 888 828 5498 • www.thegrandecolonial.com • $$ La Jolla's first hotel was designed by Spanish Revival architect Richard Requa. The 1913 building houses luxury suites, while a 1926 building contains the main hotel. Elegantly appointed rooms are in keeping with the hotel's European ambience. ### Horton Grand Hotel 311 Island Ave • 619 544 1886 • www.hortongrand.com • $$ Rebuilt from two Victorian-era hotels, this hotel reflects the character of the Gaslamp Quarter. Rooms are individually decorated in period style, and each has a gas fireplace. ### The Inn at Rancho Santa Fe 5951 Linea del Cielo, Rancho Santa Fe • 858 756 1131 • www.theinnatrsf.com • $$ Refined elegance distinguishes this romantic country inn. Many of the red-roofed adobe casitas scattered about the lush grounds boast comfy queen-sized beds, fireplaces, and kitchens. ### La Jolla Beach and Tennis Club 2000 Spindrift Drive • La Jolla • 858 412 2036 • www.ljbtc.com • $$$ This resort is perfect for an active family: guests can choose to ocean swim, kayak, play tennis or golf, or simply enjoy the sunshine. You can step out the door onto a pristine sand beach. Rooms with kitchenettes are available. ### La Valencia Hotel 1132 Prospect St, La Jolla • 858 454 0771 • www.lavalencia.com • $$$ Since 1926, the "Pink Lady of La Jolla" has enchanted with its splendid Mediterranean ambience, exquisite decor, and ideal location on the cliffs above La Jolla Cove. Rooms vary from quite small to large ocean villas. ### U.S. Grant 326 Broadway • 619 232 3121 • www.marriott.com/hotels/travel/sanlc-the-us-grant-a-luxury-collection-hotel-san-diego/ • $$$ Ulysses S. Grant Jr. commissioned this stately 1910 Renaissance palace. A $56-million renovation has restored it to its former glory, with mahogany furniture and paneling, tile floors, and luxurious rooms. Back to Places to Stay ## Spa Hotels ### Omni La Costa Resort & Spa 2100 Costa Del Mar Rd, Carlsbad • 760 438 9111 • www.lacosta.com • $$ This Spanish-Colonial complex contains two PGA championship golf courses, a tennis center, and the Chopra Center for Wellbeing – a spa and fitness center offering healing treatments. ### Cal-a-Vie 29402 Spa Havens Rd, Vista • 760 842 6831 • www.cal-a-vie.com • $$$ Exhilarating programs focus on fitness, nutrition, and personal care. The Mediterranean-style villas provide luxurious accommodations (packages for 3–7 nights only). ### Golden Door 777 Deer Springs Rd, San Marcos • 760 744 5777 • www.goldendoor.com • $$$ Modeled after the ancient ryokan inns, Japanese gardens, streams, and waterfalls make a glorious backdrop to a week of fitness and meditation. For most of the year, the spa is a women-only domain. ### Rancho La Puerta 476 Tecate Rd, Tecate, Baja California, Mexico • 858 764 5500 • www.rancholapuerta.com • $$$ Since 1940, guests have pursued body and mind fitness at this beautiful Mexican-Colonial-style resort. Lodgings are in casitas decorated with folk art and bright fabrics. The dining room specializes in homegrown organic food. Back to Places to Stay ## Business Hotels ### Town & Country Resort Hotel 500 Hotel Circle N. • 619 291 7131 • www.towncountry.com • $ This sprawling family-owned resort has an onsite convention center and 1,000 rooms. Next door is a golf course, a trolley stop, and the Fashion Valley Mall. ### Embassy Suites Hotel San Diego Bay – Downtown 601 Pacific Hwy • 619 239 2400 • www.embassysuites.com • $$ Guests enjoy spacious suites that have a living area and a separate bedroom. All rooms open onto a palm-tree-filled atrium and offer a view of the bay or city. Enjoy a dip in the indoor pool. ### Hilton La Jolla Torrey Pines 10950 N. Torrey Pines Rd, La Jolla • 858 558 1500 • www.hiltonlajollatorreypines.com • $$ This low-key but chic hotel is located next to the Torrey Pines Golf Course. A valet looks after your immediate needs, and a car service can drive you to La Jolla. All rooms have balconies or terraces, and many feature ocean or harbor views. ### Hyatt Regency La Jolla 3777 La Jolla Village Dr, La Jolla • 858 552 1234 • www.lajolla.hyatt.com • $$ Postmodern architect Michael Graves designed this Italian-style palace hotel. A fitness spa and highly acclaimed restaurants are situated next door. Corporate guests can access the business center. ### Omni San Diego Hotel 675 L St • 619 231 6664 • www.omnihotels.com • $$ A skyway links the hotel to Petco Park, and you can even see the ball field from some rooms. Comfy rooms sport great bathrooms, and if you must tend to business, the Convention Center is only a few blocks away. ### Manchester Grand Hyatt San Diego 1 Market Place • 619 232 1234 • www.manchestergrand.hyatt.com • $$$ Two high-rise towers hold 1,625 rooms, many with personal work areas and all with high-speed Internet. The lounge on the 40th floor is one of San Diego's best. Guests can also make use of two rooftop pools and the 24-hour fitness center. ### Marriott Marquis San Diego Marina 333 W. Harbor Dr • 619 234 1500 • www.marriotthotels.com • $$$ Most rooms at this busy hotel are set up with worktables and high-speed Internet, and offer scenic views of the waterfront and San Diego Bay. The marina and waterfall swimming pool make great distractions. ### Westin Gaslamp Quarter San Diego 910 Broadway Cir • 619 239 2200 • www.starwoodhotels.com • $$$ Attached to Westfield Horton Plaza, this downtown hotel is close to restaurants and entertainment venues. It offers a range of event and meeting spaces, a workout room, and swimming pool. The Gaslamp Quarter and Convention Center are within walking distance. ### Westin San Diego Hotel 400 W. Broad-way • 619 239 4500 • www.westinsandiego.com • $$$ You can't miss this hotel's green silhouette of hexagonal glass towers. Amenities include ergonomic work chairs and high-speed Internet access. The Convention Center is within easy walking distance. Back to Places to Stay ## Mid-Range Hotels ### Bay Club Hotel & Marina 2131 Shelter Island Dr • 619 224 8888 • www.bayclubhotel.com • $ Rattan furniture and tropical fabrics give a Polynesian cast to this hotel. The best rooms are at the back and have views of the marina and Point Loma. Breakfast is included. ### Crowne Plaza San Diego 2270 Hotel Circle N. • 619 297 1101 • www.cp-sandiego.com • $ In the 1960s, a wave of Polynesian-themed hotels sprang up in the area, and those that survived now have a trendy retro feel to them. The tropical decor still rules the public areas, but the rooms are contemporary and overlook the pool or nearby golf course. ### The Dana on Mission Bay 1710 W. Mission Bay Dr • 619 222 6440 • www.thedana.com • $ This hotel is incredibly popular with families. All the water activities of Mission Bay are close by, and the hotel also operates free shuttles to SeaWorld. Tropical landscaping surrounds the grounds, and the swimming pool is a real hit with kids. ### Humphrey's Half Moon Inn and Suites 2303 Shelter Island Dr • 619 224 3411 • www.halfmooninn.com • $ Its summer concert series, tropical landscaping, private marina, and long list of activities make this hotel an ideal choice for those looking for some entertainment. You can pay a little more if you would like a room with a view of the bay. ### Best Western Plus Hacienda Hotel Old Town 4041 Harney St • 800 888 1991 • www.bestwestern.com • $$ On a hillside overlooking Old Town, this charming hacienda-style hotel offers rooms that have private balconies or look onto a courtyard. Free airport transportation is provided. ### Hotel Indigo 509 9th Ave • 619 727 4000 • www.hotelindigo.com • $$ Rooms at this trendy, pet-friendly boutique hotel in the Gaslamp Quarter come with plush bedding, hardwood floors, and complimentary Internet access. The bar terrace looks right over Petco Park and has spectacular views of the city skyline. Back to Places to Stay ## Waterfront Hotels ### Bahia Resort Hotel 998 W. Mission Bay Dr • 858 488 0551 • www.bahiahotel.com • $ This venerable Mission Bay Hotel is right next to the bay and Mission Beach. Among the facil-ities on offer are tennis courts, a hydro-therapy pool, and a fitness center. At night, you can enjoy live music on the _Bahia Belle_ , a stern-wheeler that floats on the bay every evening. ### Carlsbad Inn Beach Resort 3075 Carlsbad Blvd, Carlsbad • 760 434 7020 • www.carlsbadinn.com • $$ Families really love this sprawling resort. Its rooms and timeshare condominiums are available nightly or weekly. Several activities and classes are held daily, and there is also a good Mexican restaurant. ### Catamaran Resort Hotel and Spa 3999 Mission Blvd • 858 488 1081 • www.catamaranresort.com • $$ This Polynesian-themed hotel offers a long list of water activities. It is within walking distance of many restaurants, and Tiki torches light your way through lushly landscaped grounds. The upper floors of the towers have great views. ### Hyatt Regency Mission Bay Spa and Marina 1441 Quivira Road • 619 224 1234 • www.missionbay.regency.hyatt.com • $$ This large, family-friendly resort offers pools and water slides, as well as access to a full marina with kayaks, jet-skis, and sailboats. Spacious rooms feature balconies with lovely views of the Pacific, Mission Bay, or the lush gardens. ### Pacific Terrace 610 Diamond St • 858 581-3500 • www.pacificterrace.com • $$ Sunset views over the Pacific define high living at one of San Diego's finest beach hotels. Large guest rooms come with a balcony or patio. There's no full-service restaurant, but the friendly staff can suggest neighborhood dining options. ### Crystal Pier Hotel & Cottages 4500 Ocean Blvd • 858 483 6983 • www.crystalpier.com • $$$ Reservations are essential for these 1927 Cape Cod-style cottages that sit directly on the pier. Many have kitchenettes, and patios with views of Pacific Beach. ### Tower 23 Hotel 723 Felspar St, Pacific Beach • 877 648 5738 • www.t23hotel.com • $$$ Situated on the beach, this stylish hotel features luxury rooms with rain showers, sleek teak furnishings, and high-end amenities. In-room massages are available on request. The classy JRDN restaurant serves delicious authentic Californian seafood. Back to Places to Stay ## Bed and Breakfasts ### Crone's Cobblestone Cottage B&B 1302 Washington Place • 619 295 4765 • No credit cards • No private bathrooms • No air conditioning • www.cronescobblestonebandb.com • $ At this restored 1913 Craftsman-style bungalow, choose either the Elliott or the Eaton room, both furnished with period antiques. The walls are lined with thousands of books. ### Hillcrest House 3845 Front Street • 619 990 2441 www.hillcresthousebandb.com • $ Choose from five uniquely decorated rooms at this vintage bed and breakfast. It is well situated for San Diego's attractions, and hostess Ann can help you plan your day over a healthy continental breakfast or in the parlor in front of the fireplace. ### Julian Gold Rush Hotel 2032 Main St, Julian • (760) 765-0201 • No air conditioning • www.julianhotel.com • $ Built in 1897 by a freed slave from Missouri, this quaint inn is the oldest continually operating hotel in Southern California. Its lacy curtains might remind you of your grandma's house, but the breakfasts are exceptional. ### The Artists' Loft Strawberry Hill, Julian • 760 765 0765 • No air conditioning • www.artistsloft.com • $$ Secluded and romantic, three cabins deep in the woods will inspire the artist within you. Airy Craftsman-style interiors feature natural wood, fine textiles, a full kitchen, and a wood-burning stove. From your screened porch, gaze at stunning mountain and distant coastline views. ### Hotel Marisol 1017 Park Place • 619 365 4677 • $$ Escape the crowds at this intimate Spanish-style inn, which has hosted guests since 1927. Guest rooms are decorated in soft colors and have plantation shutters. A continental breakfast is complimentary, as are beach chairs and bicycles. Coronado's famous beach is only 5 minutes away. ### The Inn at Europa Village 33350 La Serena Way, Temecula • 951 676 7047 • www.europavillage.com • $$ Ideally situated for touring the Temecula vineyards, rooms in this Mission-style inn have private balconies, Jacuzzis, and fireplaces. Rates include a continental breakfast with fresh pastries. ### Orchard Hill Country Inn 2502 Washington St, Julian • 760 765 1700 • www.orchardhill.com • $$ At this most luxurious of Julian's B&B inns, you can stay in a Craftsman-style cottage with a whirlpool tub, fireplace, and private porch. The tasty breakfasts make for a good start to the day. Back to Places to Stay ## Budget Hotels and Hostels ### Apple Tree Inn 4360 Highway 78, Julian • 760 765 0222 • www.julianappletreeinn.com • $ A few miles outside of Julian, this small cinder-block-style motel offers a quiet night's sleep in basic but tidy rooms that have mountain views and an outdoor pool. Hiking trails, a few restaurants, and shops are nearby. Pet-friendly. ### Borrego Springs Motel 2376 Borrego Springs Road • 760 767 4339 • www.borregospringsmotel.com • $ There are seven queen-bed rooms and one twin-bed room in this no-frills but sparkling clean motel – perfect for those who want to enjoy the surrounding desert. Despite solar power, the motel offers no Wi-Fi, TV, or tele-phones. The helpful proprietors, who live onsite, are local experts. ### HI San Diego Downtown Hostel 521 Market St • 619 525 1531 • No air conditioning • No private bathrooms • www.sandiegohostels.org • $ This bright hostel offers dorm rooms and some private ones, free airport transportation and breakfast, kitchen and lounge facilities, laundry service, and Internet access. ### Kings Inn 1333 Hotel Circle South • 619 297 2231 • www.kingsinnsandiego.com • $ This vintage-style inn with a swimming pool and spa tub has clean, comfortable rooms and friendly, helpful staff. Good onsite restaurants serve breakfast, lunch, and dinner. ### La Pensione 606 W. Date St • 619 236 8000 • No air conditioning • www.lapensionehotel.com • $ In the heart of Little Italy, La Pensione offers rooms with a queen-size bed, TV, and refrigerator. A coin-operated laundry is on the premises, as well as free parking, and some of the city's best Italian restaurants are just a stone's throw away. ### Old Town Inn 4444 Pacific Hwy • 619 260 8024 • www.oldtown-inn.com • $ The rooms here are clean and comfy, and the hotel offers one of the better breakfasts around. An efficiency unit comes with a microwave, refrig-erator, and range top, and parking is also free. ### USA Hostels Gaslamp 726 5th Ave • 619 232 3100 • No air conditioning • No private bathrooms • www.usahostels.com • $ A popular centrally located hostel offering dorm rooms and some private rooms. Facilities include Internet access, a laundry, kitchen, a lounge area with DVDs, and free lockers. The place is famous for its all-you-can-make pancake breakfasts. ### Vagabond Inn Point Loma 1325 Scott St • 619 224 3371 • www.vagabondinn.com • $ This motel is well situated for sportfishing activities and the Cabrillo National Monument. Along with the clean and cheery rooms, guests can enjoy the free breakfast, airport shuttle, parking, and the huge outdoor swimming pool. #### PRICE CATEGORIES For a standard, double room per night (with breakfast if included), taxes, and extra charges. * * * **$** under $200 **$$** $200–$300 **$$$** over $300 Back to Places to Stay Back to Streetsmart # Maps • The following maps are also accessible from the Table of Contents. • To zoom in and out on the both main map and the thumbnails, first double-tap and then pinch and spread, if your device allows. • For optimum viewing, use the screen-lock function on your device and make sure you have installed the latest software updates. zoom northwest zoom northeast zoom southwest zoom southeast zoom northwest zoom northeast zoom southwest zoom southeast ## Acknowledgments **Author** Born in San Diego, Pamela Barrus is an unapologetic vagabond, having traveled solo through some 200 countries. She is the author of _Dream Sleeps: Castle and Palace Hotels of Europe_ and has contributed to a number of national magazines. She still finds San Diego one of the best places in the world to come home to and enjoy the sunshine. The author would like to thank Mary Barrus and Roger Devenyns for sharing their exceptional knowledge and insight of San Diego with her. **Additional contributor** Marael Johnson **Publishing Director** Georgina Dee **Publisher** Vivien Antwi **Design Director** Phil Ormerod **Editorial** Michelle Crane, Rachel Fox, Priyanka Kumar, Lucy Richards, Sands Publishing Solutions, Sally Schafer, Sophie Wright **Cover Design** Maxine Pedliham, Vinita Venugopal **Design** Tessa Bindloss **Commissioned Photography** Robert Holmes **Picture Research** Sumita Khatwani, Ellen Root, Lucy Sienkowska, Rituraj Singh, Vinita Venugopal **Cartography** Suresh Kumar, James Macdonald, Rajesh Kumar Mishra, Casper Morris **DTP** Jason Little **Production** Luca Bazzoli **Factchecker** Carolyn Patten **Proofreader** Kathryn Glendenning **Indexer** Hilary Bird **Revisions** Avanika, Subhashree Bharati, Sumita Khatwani, Shikha Kulkarni, Azeem Siddiqui, Priyanka Thakur, Stuti Tiwari, Vaishali Vashisht **Digital Operations, Delhi** **Senior Manager** Lakshmi Rao **Producer** Suruchi Kakkar **Techno Editor** Sheetal Dayal **Software Engineer** Rachana Kishore **Production Manager** Nain Singh Rawat **Production Coordinator** Manish Bhatt **Picture Credits** The publisher would like to thank the following for their kind permission to reproduce their photographs: **123RF.com:** Florian Blümm; Kan Khampanya; Stephen Minkler; Sean Pavone; Scott Prokop. **1500 Ocean** **Alamy Stock Photo:** America; Art Directors & TRIP; Paul Briden; Citizen of the Planet; Collection Christophel; Ian G Dagnall; David R. Frazier Photolibrary, Inc.; Danita Delimont; f8grapher; GALA Images; Joseph S Giacalone; Granger Collection, NYC; Ian Dagnall Commercial Collection; Blaine Harrington III; Juice Images; David Kilpatrick; Elizabeth Leyden; LH Images; W. G. Murray; Natura-Light; Ron Niebrugge; George Ostertag; RooM the Agency; SeBuKi; Steve Shuey; Witold Skrypczak; Stephen Saks Photography; Sueddeutsche Zeitung Photo; SuperStock; Craig Steven Thrasher; TongRo Images; Visions from Earth; Jason O. Watson; Nik Wheeler; Richard Wong; ZUMA Press Inc. **AWL Images:** Danita Delimont Stock; Marco Simoni. **Balboa Park Conservancy** **Belly Up Tavern:** Pixel Perfect Images/Daniel Knighton. **Belmont Park** **Bertrand at Mr. A's** **Cafe Sevilla** **The Cottage** **Crest Cafe** **Del Mar Rendezvous** **Dreamstime.com:** Adeliepenguin; Agezinder; Americanspirit; Joe Avery; Rinus Baak; Jay Beiler; Jon Bilous; Bshel1983; Scott Burns; Chicco7; Alan Crosthwaite; Kobby Dagan; Dobino; Durson Services Inc.; F11photo; F8grapher; Sandra Foyt; Ben Graham; Hellen8; Irina88w; Ritu Jethani; Kongomonkey; Chon Kit Leong; Meunierd; Stephen Minkler; Sean Pavone; Petthomas; Photoquest; Razyph; Gino Rigucci; Stasvolik; Steveheap; Enrique Gomez Tamez; Mirko Vitali; Welcomia; Angie Westre; Zhukovsky. **Eddie V's Prime Seafood** **The Field Irish Pub** **Getty Images:** Davel5957; Blaine Harrington III; Mark Whitt Photography; Sam Antonio Photography; Stephen Saks; Stringer / Robert Benson; Maureen P Sullivan; Rob Tilley. **Humphrey's Concerts by the Bay** **iStockphoto.com:** Siestacia; Ron Thomas; Tobiasjo; Art Wager. **La Jolla Playhouse:** Kevin Berne; Joan Marcus, Sutton Foster (center) and the cast of La Jolla Playhouse's Tony Award-winning production of, THOROUGHLY MODERN MILLIE. **Lestat's Coffee House** **Lou & Mickey's** **Manchester Grand Hyatt** **Maritime Museum of San Diego** **Miguel's Cocina** **Mille Fleurs** **Museum of Man** **Museum of Photographic Arts:** RyanGobuty Gensler. **The Old Globe** **Photoshot:** Nikhilesh Haval. **Prohibition** **Putnam Foundation, Timken Museum of Art, San Diego** **Reuben H. Fleet Science Center** **Rex by Shutterstock:** Everett Collection; Zhao Hanrong. **San Diego Automotive Museum** **San Diego Botanic Garden** **San Diego Museum of Art** **San Diego Natural History Museum** **Seaport Village** **Spanish Village Art Center** **Spin** **Spreckels Organ Pavilion:** Michael Cox, Robert Lang. **Spreckels Theatre** **SuperStock:** AGE Fotostock/George Ostertag; Richard Cummins; George Ostertag. **Vocabulary** **Front Cover – **Getty Images:** Sam Antonio Photography.** All other images © Dorling Kindersley. For further information see: www.dkimages.com As a guide to abbreviations in visitor information blocks: **Adm** = admission charge; **D** = dinner; **L** = lunch. **To find out more, please contact:** **in the USspecialsales@dk.com** **in the UKtravelguides@uk.dk.com** **in Canadaspecialmarkets@dk.com** **in Australiapenguincorporatesales@penguinrandomhouse.com.au** First American edition, 2005 Published in the United States by DK Publishing, 1450 Broadway, Suite 801 New York, NY 10018 USA Copyright © 2005, 2019 Dorling Kindersley Limited A Penguin Random House Company ISBN: 9780241367964 Reprinted with revisions 2007, 2009, 2011, 2013, 2017, 2019 This abridged Digital Edition published in 2019 ISBN: 9781465495860 All rights reserved. No part of this publication may be reproduced, stored in or introduced into a retrieval system, or transmitted in any form, or by any means (electronic, mechanical, photocopying, recording or otherwise) without the prior written permission of the copyright owner. Within each Top 10 list in this ebook, no hierarchy of quality or popularity is implied. All 10 are, in the editor's opinion, of roughly equal merit. # Table of Contents 1. Welcome to San Diego 2. Exploring San Diego 3. Top 10 San Diego Highlights 1. Gaslamp Quarter 2. Embarcadero 3. Balboa Park 4. Old Town State Historic Park 5. Coronado 6. Point Loma 7. Mission Basilica San Diego de Alcala 8. Mission Bay Park 9. La Jolla 10. East County 4. The Top 10 of Everything 1. Moments in History 2. Historic Sites 3. Architectural Highlights 4. Museums and Art Galleries 5. Beaches 6. Gardens and Nature Reserves 7. Outdoor Activities 8. Off the Beaten Path 9. Children's Attractions 10. Performing Arts Venues 11. Nightlife 12. Cafes and Bars 13. Restaurants 14. Stores and Shopping Centers 15. San Diego for Free 16. Festivals 5. San Diego Area by Area 1. Downtown San Diego 2. Old Town, Uptown, and Mission Valley 3. Ocean Beach, Coronado, and the South 4. Northern San Diego 6. Streetsmart 1. Getting To and Around San Diego 2. Practical Information 3. Places to Stay 7. Maps 8. Acknowledgments 9. Copyright 1. Contents 2. Cover 3. How To Use this Guide
{ "redpajama_set_name": "RedPajamaBook" }
8,098
\section{An alternative way of looking at it} Consider the following symmetry of $q\Pfour(a)$, \begin{equation}\label{eq:symmetry} \mathcal{T}_1: t \mapsto \frac{1}{t},\quad (f_0,f_1,f_2)\mapsto (F_0,F_1,F_2)=(f_0^{-1},f_1^{-1},f_2^{-1}), \end{equation} i.e. \begin{equation*} F_k(t)=\frac{1}{f_k(1/t)}\quad (1\leq k\leq 2), \end{equation*} which sends solutions of $q\Pfour(a)$ to solutions of $q\Pfour(a)$, as well as the trivial symmetry \begin{equation}\label{eq:symmetrytrivial} \mathcal{T}_2: t \mapsto -t,\quad (f_0,f_1,f_2)\mapsto (F_0,F_1,F_2)=(f_0,f_1,f_2). \end{equation} Consider the linear problem \begin{equation*} Y(qz)=A(z,t)Y(z) \end{equation*} where \begin{align*} A=&\begin{pmatrix} u & 0\\ 0 & 1 \end{pmatrix}\begin{pmatrix} -i\,q\frac{t}{f_2}z & 1\\ -1 & -\,i\,q\frac{f_2}{t} z \end{pmatrix} \begin{pmatrix} -\,i\,a_0a_2\frac{t }{f_0}z & 1\\ -1 & -\,i\,a_0a_2\frac{f_0}{t} z \end{pmatrix}\times\\ &\ \times\, \begin{pmatrix} -\,i\,a_0\frac{t}{f_1}z & 1\\ -1 & -\,i\,a_0\frac{f_1}{t} z \end{pmatrix}\begin{pmatrix} u^{-1} & 0\\ 0 & 1 \end{pmatrix}. \end{align*} The symmetries translate to the following symmetries of the linear problem, \begin{align} \mathcal{T}_1:&\quad A(z,t)\mapsto \widetilde{A}(z,t)=A(z,t^{-1})^{\diamond},\\ \mathcal{T}_2:&\quad A(z,t)\mapsto \widetilde{A}(z,t)=-\sigma_3A(z,-t)\sigma_3. \end{align} In turn, these correspond to the following symmetries of the connection matrix, \begin{align} \mathcal{T}_1:&\quad C(z,t)\mapsto \widetilde{C}(z,t)=\sigma_1C(z,t^{-1})^{\diamond},\\ \mathcal{T}_2:&\quad C(z,t)\mapsto \widetilde{C}(z,t)=\sigma_1C(z,-t)\sigma_3. \end{align} In turn, these correspond to the following symmetries of the coordinates $\rho_{1,2,3}$, \begin{align} \mathcal{T}_1:&\quad \rho_k(t)\mapsto \widetilde{\rho}(t)=-\rho_k(t^{-1})\quad (k=1,2,3),\\ \mathcal{T}_2:&\quad \rho_k(t)\mapsto \widetilde{\rho}(t)=\rho_k(-t)^{-1}\quad (k=1,2,3). \end{align} Namely, consider the cubic equation \begin{align*} 0=&+\theta_q(+a_0,+a_1,+a_2)\left(\theta_q(t_0)p_1p_2p_3-\theta_q(-t_0)\right)\\ &-\theta_q(-a_0,+a_1,-a_2)\left(\theta_q(t_0)p_1-\theta_q(-t_0)p_2p_3\right)\\ &+\theta_q(+a_0,-a_1,-a_2)\left(\theta_q(t_0)p_2-\theta_q(-t_0)p_1p_3\right)\\ &-\theta_q(-a_0,-a_1,+a_2)\left(\theta_q(t_0)p_3-\theta_q(-t_0)p_1p_2\right), \end{align*} This equation is invariant under \begin{align} \mathcal{T}_1:&\quad t_0\mapsto t_0^{-1}, \quad \rho_k\mapsto \widetilde{\rho}_k=-\rho_k \quad (k=1,2,3),\\ \mathcal{T}_2:&\quad t_0\mapsto -t_0,\quad \rho_k\mapsto \widetilde{\rho}_k=\rho_k^{-1}\quad (k=1,2,3). \end{align} If we choose $t_0=i$, then this cubic equation is invariant under \begin{equation*} \mathcal{T}_3:=\mathcal{T}_1\circ \mathcal{T}_2:\quad \rho_k\mapsto \widetilde{\rho}_k=-\rho_k^{-1}\quad (k=1,2,3). \end{equation*} There are precisely four fixed points of $\mathcal{T}_3$, given by \begin{equation*} (\rho_1,\rho_2,\rho_3)=(-i,-i,-i), (-i,i,i),(i,-i,i),(i,i,-i)\}. \end{equation*} \section{Notation}\label{app:not} Define the Pauli matrices \begin{equation*} \sigma_1=\begin{pmatrix} 0 & 1\\ 1 & 0 \end{pmatrix},\quad \sigma_2=\begin{pmatrix} 0 & -i\\ i & 0 \end{pmatrix},\quad \sigma_3=\begin{pmatrix} 1 & 0\\ 0 & -1 \end{pmatrix}. \end{equation*} We define the $\mathit{q}$-Pochhammer symbol by means of the infinite product \begin{equation*} (z;q)_\infty=\prod_{k=0}^{\infty}{(1-q^kz)}\qquad (z\in\mathbb{C}), \end{equation*} which converges locally uniformly in $z$ on $\mathbb{C}$. In particular $(z;q)_\infty$ is an entire function, satisfying \begin{equation*} (qz;q)_\infty=\frac{1}{1-z}(z;q)_\infty, \end{equation*} with $(0;q)_\infty=1$ and simple zeros on the semi $q$-spiral $q^{-\mathbb{N}}$. The $\mathit{q}$-theta function is defined as \begin{equation}\label{eq:thetasym} \theta_q(z)=(z;q)_\infty(q/z;q)_\infty\qquad (z\in \mathbb{C}^*), \end{equation} which is analytic on $\mathbb{C}^*$, with essential singularities at $z=0$ and $z=\infty$ and simple zeros on the $q$-spiral $q^\mathbb{Z}$. It satisfies \begin{equation*} \theta_q(qz)=-\frac{1}{z}\theta_q(z)=\theta_q(1/z). \end{equation*} For $n\in\mathbb{N}^*$ we denote \begin{align*} \theta_q(z_1,\ldots,z_n)&=\theta_q(z_1)\cdot \ldots\cdot \theta_q(z_n),\\ (z_1,\ldots,z_n;q)_\infty&=(z_1;q)_\infty\cdot\ldots\cdot (z_n;q)_\infty. \end{align*} For conciseness, we will use bars to denote iteration in $t$. That is, for $f=f(t)$, we denote $f(q\,t)=\overline f$, and $f(t/q)=\underline f$. \section{Riemann Hilbert problem and definitions}\label{app:rhp} Here, we recall the definition of appropriate contours for the Riemann problem corresponding to $q$-difference linear equations, first described by Birkhoff \cite{birkhoffgeneralized1913}. \begin{definition}\label{def:contour} Given non-resonant $\{x_1, \ldots, x_{2n}\}$, which we assume to be invariant under negation, a positively oriented Jordan curve $\gamma$ in $\mathbb{C}^*$ is called \emph{admissible} if all the following conditions are satisfied: \begin{enumerate}[label={{\rm (\roman *)}}] \item It admits local parametrization by analytic functions at each point. \item It possesses the reflection symmetry $\gamma=-\gamma$. \item Letting the region on the left {\rm (}respectively right{\rm )} of $\gamma$ in $\mathbb{C}$ be $D_-$ and $D_+$, we have \begin{equation}\label{eq:insideoutside} q^kx_i\in\begin{cases} D_- & \text{if $k>0$,}\\ D_+ & \text{if $k\leq 0$,} \end{cases} \end{equation} for all $k\in\mathbb{Z}$ and $1\leq i \leq 2n$. \end{enumerate} \end{definition} Equation \eqref{eq:A} has two fundamental solutions defined respectively in $D_\pm$. A relation between the two solutions is provided by a connection or jump matrix $C$. We assume below that $C$ is a $2\times 2$ connection matrix satisfying the first three properties of Definition \ref{def:connectionspace}. The RHP then takes the following form. \begin{definition}[Riemann-Hilbert problem]\label{def:RHP1and2} Given non-resonant critical exponents $\theta_{1,2}$, $\kappa_{1,2}$ and $x_k$, $1\leq k \leq 2n$, a $2\times 2$ connection matrix $C(z)$ satisfying properties \eqref{item:c1}, \eqref{item:c2}, and \eqref{item:c3} of Definition \ref{def:connectionspace}, an admissible curve $\gamma$, and $m\in\mathbb{Z}$, a $2\times2$ complex matrix function $Y^{\B{m}}(z)$ is called a solution of the Riemann-Hilbert problem $\textnormal{RHP}^{\B{m}}(\gamma,C)$ if it satisfies the following conditions. \begin{enumerate}[label={{\rm (\roman *)}}] \item $Y^{\B{m}}(z)$ is analytic on $\mathbb{C}\setminus\gamma$. \item $Y^{\B{m}}(z')$ has continuous boundary values $Y_-^{\B{m}}(z)$ and $Y_+^{\B{m}}(z)$ as $z'$ approaches $z\in \gamma$ from $D_-$ and $D_+$ respectively, where \begin{equation}\label{eq:jumpm} Y_+^{\B{m}}(z)=Y_-^{\B{m}}(z)C(z),\quad z\in \gamma. \end{equation} \item $Y^{\B{m}}(z)$ satisfies \begin{equation}\label{eq:normalisationm} Y^{\B{m}}(z)=\left(I+\mathcal{O}\left(z^{-1}\right)\right)z^{m\sigma_3}\quad z\rightarrow \infty. \end{equation} \end{enumerate} \end{definition} \noindent Here $\sigma_3$ is a Pauli spin matrix (see Appendix \ref{app:not}). \section{Proof of a technical lemma}\label{app:technical_lemma} \begin{proof}[Proof of Lemma \ref{lem:forbidden}] Let $C(z,t)$ be the connection matrix corresponding to the solution $f$. Let $t_*\in q^\mathbb{Z}t_0$ be such that $f(t_*)$ is regular. Then the Lax matrix $A(z,t_*)$ is well-defined at this point and consequently, we have a corresponding connection matrix $C(z,t_*)$ defined via equation \eqref{eq:assodefiiv}. Furthermore, using the time-evolution of the connection matrix in equation \eqref{eq:connection_evolution}, we can thus infer that $C(z,t_0)$ is also well-defined. Now suppose, on the contrary, that the corresponding monodromy coordinates, \begin{equation*} p_k=\pi(C(x_k,t_0)), \end{equation*} lie on the curve defined by the cubic equations \eqref{eq:forbidden_cubic}. We are going to obtain a contradiction by showing that $C(z,t_0)$ does not satisfy property \ref{item:c3}. To this end, we will first obtain a general parametrisation of this curve. Consider the following matrix function, \begin{equation}\label{eq:psuedo_connect} \mathcal{C}(z)=\begin{pmatrix} C_1(z) & C_2(z)\\ -C_1(-z) & C_2(-z) \end{pmatrix}, \end{equation} where \begin{align*} C_1(z)&=\theta_q(+z/u,-z/u,z/w), & u^2 w=&\frac{1}{q a_0^2 a_2} t^{-1},\\ C_2(z)&=z\theta_q(+z/v,-z/v,z/w), & qv^2 w=&\frac{1}{q a_0^2 a_2} t^{+1},\\ \end{align*} for any choice of $t,w\in\mathbb{C}^*$. This matrix satisfies properties \ref{item:c1}, \ref{item:c2}, \ref{item:c4}, as well as a degenerate version of \ref{item:c3}, namely \begin{equation*} |\mathcal{C}(z)|\equiv 0. \end{equation*} The monodromy coordinates, $P_k=\pi(\mathcal{C}(x_k))$, $k=1,2,3$, of this pseudo-connection matrix, read \begin{equation}\label{eq:parametrisation_forbidden} (P_1,P_2,P_3)=\bigg(-\frac{\theta_q(+x_1/w)}{\theta_q(-x_1/w)},-\frac{\theta_q(+x_2/w)}{\theta_q(-x_2/w)},-\frac{\theta_q(+x_3/w)}{\theta_q(-x_3/w)}\bigg). \end{equation} These monodromy coordinates solve the cubic \eqref{eq:cubic} and their expressions are completely independent of $t$. In other words, they lie on the intersection of cubics \eqref{eq:cubic}, as $t$ varies in $\mathbb{C}^*$. In particular, these monodromy coordinates must lie on the curve defined by \eqref{eq:forbidden_cubic}. We will show that \eqref{eq:parametrisation_forbidden} completely parametrises the curve defined by \eqref{eq:forbidden_cubic}, as $w$ varies in $\mathbb{C}^*$. Since we have not assumed anything on $(p_1,p_2,p_3)$, this is equivalent to proving that there exists a $w$ such that \begin{equation}\label{eq:pequality} (P_1,P_2,P_3)=(p_1,p_2,p_3). \end{equation} Now, the equation \begin{equation*} p_1=-\frac{\theta_q(+x_1/w)}{\theta_q(-x_1/w)}, \end{equation*} has two, counting multiplicity, solutions $w_{1,2}$, on the elliptic curve $\mathbb{C}^*/q^2$, related by $w_2\equiv q x_1^2/w_1$ modulo multiplication by $q^2$. For either choice, $w=w_1$ or $w=w_2$, we have $p_1=P_1$ and the pairs $(P_2,P_3)$ and $(p_2,p_3)$ satisfy the same two equations \eqref{eq:forbidden_cubic}, which are quadratic in the remaining variables. In fact, upon fixing the value of $p_1$, \eqref{eq:forbidden_cubic} has two solutions (counting multiplicity), and these two solutions coincide if and only if $w_1$ and $w_2$ coincide on the elliptic curve $\mathbb{C}^*/q^2$. It follows that \eqref{eq:pequality} holds for $w=w_1$ or $w=w_2$. We now fix $w$ such that \eqref{eq:pequality} holds, set $t=t_0$ in \eqref{eq:psuedo_connect}, and consider the quotient \begin{equation*} D(z)=C(z,t_0)^{-1}\mathcal{C}(z). \end{equation*} Since $C(z,t_0)$ and $\mathcal{C}(z)$ have the same monodromy-coordinate values, $D(z)$ is analytic at $z=\pm x_k$, $k=1,2,3$ and thus forms an analytic matrix function on $\mathbb{C}^*$. Then, by property $\ref{item:c2}$, \begin{equation*} D(qz)=t_0^{\sigma_3}D(z)t_0^{-\sigma_3}. \end{equation*} Since $t_0^2\notin q^\mathbb{Z}$, the only analytic matrix functions satisfying this $q$-difference equation are constant diagonal matrices, and therefore $D$ is simply a constant diagonal matrix. But then \begin{equation*} C(z,t_0)D=\mathcal{C}(z), \end{equation*} and neither diagonal entry of $D$ can equal zero, as this contradicts equation \eqref{eq:psuedo_connect}, so $|D|\neq 0$. Hence \begin{equation*} |C(z,t_0)|=|\mathcal{C}(z)|/|D|\equiv 0, \end{equation*} which contradicts property \ref{item:c3}. The lemma follows. \end{proof} \section{A heuristic approach to relating monodromy with asymptotics} Suppose $f$ is a solution of $q\Pfour$ with asymptotics near $t=0$ as described by equations \eqref{eq:asymptoticsf}. Let $C(z)$ be the connection matrix corresponding to this solution $f$ and $(\rho_1,\rho_2,\rho_3)$ the corresponding coordinates on the cubic \begin{align}\label{eq:cubic} 0=&+\theta_q(+a_0,+a_1,+a_2)\left(\theta_q(t_0)\rho_1\rho_2\rho_3-\theta_q(-t_0)\right)\\ &-\theta_q(-a_0,+a_1,-a_2)\left(\theta_q(t_0)\rho_1-\theta_q(-t_0)\rho_2\rho_3\right)\nonumber\\ &+\theta_q(+a_0,-a_1,-a_2)\left(\theta_q(t_0)\rho_2-\theta_q(-t_0)\rho_1\rho_3\right)\nonumber\\ &-\theta_q(-a_0,-a_1,+a_2)\left(\theta_q(t_0)\rho_3-\theta_q(-t_0)\rho_1\rho_2\right).\nonumber \end{align} We may essentially write \begin{equation*} C(z)=C(z;\rho_1,\rho_2,\rho_3), \end{equation*} as the value of $(\rho_1,\rho_2,\rho_3)$ determines $C(z)$ up to scaling. We now substitute the asymptotic expansion of $f$ near $t=0$ into the linear system \begin{equation*} Y(q z, t)=A(z, t)Y(z,t), \end{equation*} with \begin{equation*} A=\begin{pmatrix} -i\,q\frac{t}{f_2}z & 1\\ -1 & -\,i\,q\frac{f_2}{t} z \end{pmatrix} \begin{pmatrix} -\,i\,a_0a_2\frac{t }{f_0}z & 1\\ -1 & -\,i\,a_0a_2\frac{f_0}{t} z \end{pmatrix} \begin{pmatrix} -\,i\,a_0\frac{t}{f_1}z & 1\\ -1 & -\,i\,a_0\frac{f_1}{t} z \end{pmatrix}, \end{equation*} where we have discarded the overall conjugation for simplicity. For simplicity, we just consider the case $j=0$, so $m=3s$. We scale $z$ with $m$ as follows, \begin{equation*} z=t_m^{\frac{1}{3}}\zeta=q^s t_0^{\frac{1}{3}} \zeta, \end{equation*} so that the resulting leading order linear system reads \begin{equation*} Y_{\text{lim}}(q \zeta)=A_\text{lim}(\zeta)Y_\text{lim}(\zeta), \end{equation*} with \begin{equation*} A_\text{lim}(\zeta)=\begin{pmatrix} 0 & 1\\ -1 & r_1 \zeta \end{pmatrix} \begin{pmatrix} 0 & 1\\ -1 & r_2 \zeta \end{pmatrix} \begin{pmatrix} 0 & 1\\ -1 & r_3 \zeta \end{pmatrix}, \end{equation*} where \begin{equation*} r_1=-q\sigma_{2,0}i,\quad r_2=-a_0a_2\sigma_{0,0}i,\quad r_3=-a_0\sigma_{1,0}i. \end{equation*} Suppose that we are able to solve this limiting problem explicitly in terms of special functions. Then we should be able to compute the corresponding connection matrix \begin{equation*} C_{\text{lim}}(z)=C_{\text{lim}}(z;\sigma_{0,0},\sigma_{1,0},\sigma_{2,0}). \end{equation*} On the other hand, we know that the connection matrix $C(z)$ of the original system must coincide with $C_{\text{lim}}(z)$, thus \begin{equation}\label{eq:connection_equality} C(z;\rho_1,\rho_2,\rho_3)=C_{\text{lim}}(z;\sigma_{0,0},\sigma_{1,0},\sigma_{2,0}). \end{equation} This would give us an explicit mapping between the monodromy coordinates and the integration constants for the asymptotics near $t=0$. To justify all this rigorously, we can use Riemann-Hilbert. But first we need to solve the limiting linear problem!! Considering the symmetric solutions, fixed by initial conditions at $t_0=i$ by \begin{equation*} (f_0(i),f_1(i),f_2(i))=(v_0,v_1,v_2),\quad v_0v_1v_2=-1,\quad v_{0,1,2}\in\{\pm 1\}, \end{equation*} we know the left-hand side of equation \eqref{eq:connection_equality}. It is given by \begin{equation}\label{eq:Cfactorised} C(z)=\sigma_1 C_0\left(\frac{v_1}{x_1} z\right) M C_0\left(-\frac{v_0}{x_2} z\right)MC_0\left(\frac{v_2}{x_3} z\right), \end{equation} with $(x_1,x_2,x_3)=(a_0^{-1},a_1/q,q^{-1})$, where \begin{equation*} C_0(z)=c_0\left(\theta_q(+i z)\begin{pmatrix} 1 & 0\\ 0 & -i \end{pmatrix}+\theta_q(-i z)\begin{pmatrix} 0 & -i\\ -1 & 0 \end{pmatrix}\right), \end{equation*} and \begin{equation}\label{eq:defiM} M=\begin{pmatrix} 1 & -1\\ i & i \end{pmatrix}. \end{equation} In order to compute that asymptotics near $t=0$, we need to thus solve the equation \begin{equation*} \sigma_1 C_0\left(\frac{v_1}{x_1} z\right) M C_0\left(-\frac{v_0}{x_2} z\right)MC_0\left(\frac{v_2}{x_3} z\right)=C_{\text{lim}}(z;\sigma_{0,0},\sigma_{1,0},\sigma_{2,0}), \end{equation*} with respect to $(\sigma_{0,0},\sigma_{1,0},\sigma_{2,0})$. \end{document} \section{Conclusion}\label{s:conc} We have shown that two symmetries $\mathcal{T}_{\pm}$ of $q\Pfour$ can be lifted to the corresponding Lax pair and monodromy manifold. We have derived four symmetric solutions of $q\Pfour$ on the discrete time domain $q^\mathbb{Z}i$, which are invariant under $\mathcal{T}_{-}$. We have further shown that they lead to solvable monodromy problems at the reflection point $t=i$, which provided an explicit correspondence between the four symmetric solutions and the four points on the monodromy manifold invariant under $\mathcal{T}_{-}$ in Theorem \ref{thm:solvable}. We also studied the family of $q$-Okamoto rational solutions and showed that they are invariant under both $\mathcal{T}_{+}$ and $\mathcal{T}_{-}$. We further showed that their simplest member leads to an explicitly solvable monodromy problem in its entire $t$-domain. We used this to determine the values of the monodromy coordinates on the monodromy manifold for all the $q$-Okamoto rational solutions. The computation of the monodromy for the $q$-Okamoto rational solutions in Section \ref{s:mero} could serve as a starting point for deducing similar results for other $q$-equations. The pole distributions of the classical Okamoto rational solutions to $\Pfour$ have been analysed via Riemann-Hilbert methods \cite{buckmiller} and the Nevanlinna theory of branched coverings of the Riemann sphere \cite{masoeroroffelsen}. The extension of such studies to the $q$-difference Painlev\'e equations is an open problem. The results of this paper yield Riemann-Hilbert representations for both the symmetric solutions on discrete time domains and the $q$-Okamoto rational solutions, through the theory set up in our previous paper \cite{joshiroffelsenrhp}. These can in turn form the basis of the rigorous asymptotic analysis of these solutions, as $t$ grows small or large or some of the parameters tend to infinity. \section{Introduction} Among the highly transcendental solutions $y(t)$ of a Painlev\'e equation, there exist solutions with solvable monodromy \cites{kitaev1991symmetrical,kaneko2005,pvisymmetric,okumura2007symmetric}, often called {\em symmetric solutions}. For generic parameter values, they are neither classical special functions\footnote{These are defined by Umemura as solutions related to hypergeometric-type or rational functions under classical transformations.} \cite{umemura1998painleve} nor solutions characterized by distinctive asymptotic behaviours, such as the celebrated tritronqu\'ee solutions \cite{jk:01}. In this paper, we show that symmetric solutions also exist for $q$-difference Painlev\'e equations. To be explicit, we focus on the $q$-difference fourth Painlev\'e equation \begin{equation*} \ q\Pfour(a):\begin{cases}\displaystyle \frac{\overline{f}_0}{a_0a_1f_1}=\frac{1+a_2f_2(1+a_0f_0)}{1+a_0f_0(1+a_1f_1)}, &\\ \displaystyle\frac{\overline{f}_1}{a_1a_2f_2}=\frac{1+a_0f_0(1+a_1f_1)}{1+a_1f_1(1+a_2f_2)}, &\\ \displaystyle\frac{\overline{f}_2}{a_2a_0f_0}=\frac{1+a_1f_1(1+a_2f_2)}{1+a_2f_2(1+a_0f_0)}, & \end{cases} \end{equation*} where $q\in\mathbb{C}$, $0<|q|<1$, is given, $f=(f_0,f_1,f_2)$ is a function of $t\in T\subseteq\mathbb{C}$ and $a:=(a_0,a_1,a_2)$ are constant parameters, subject to \begin{equation}\label{eq:conditionfa} f_0f_1f_2=t^2,\quad a_0a_1a_2=q, \end{equation} $T$ is invariant under multiplication by $q$, and $\overline f=f(qt)$. This equation is also known as $q{\rm P}(A_5^{(1)})$ in Sakai's diagram \cite{sakai2001}. We will focus on solutions of $q\Pfour(a)$ that are invariant under the following transformations. \begin{definition}\label{def:symmetry} The following transformations are called {\em discrete symmetries} of $q\Pfour(a)$: \begin{equation}\label{eq:symmetry1} \mathcal{T}_\pm: t \mapsto \frac{\pm 1}{t},\quad (f_0,f_1,f_2)\mapsto (F_0,F_1,F_2)=(f_0^{-1},f_1^{-1},f_2^{-1}), \end{equation} i.e., \begin{equation*} F_k(t)=\frac{1}{f_k(\pm 1/t)}\quad (0\leq k\leq 2), \end{equation*} We call $T$ a {\em symmetric domain} if it is invariant under $t \mapsto \frac{\pm 1}{t}$. Furthermore, a solution $f$ of $q\Pfour(a)$ is called a {\em symmetric solution} if it is invariant under one of the above two symmetries. \end{definition} \noindent We show that $q\Pfour(a)$ is invariant under transformation \eqref{eq:symmetry1} in Section \ref{s:symm}. It is important to note that the above symmetries do not arise as elements of the affine Weyl symmetry group $(A_2+A_1)^{(1)}$ usually associated with $q\Pfour(a)$, but one of them turns out to be an automorphism of the corresponding Dynkin diagram. The difference equation $q\Pfour(a)$ is associated to a linear problem (called a {\em Lax pair}) \cite{joshinobu2016} \begin{subequations} \label{eq:laxpair} \begin{align}\label{eq:laxspectral} Y(qz,t)&={\mathcal A}(z;t,f,u)Y(z,t),\\ Y(z,qt)&={\mathcal B}(z;t,f,u)Y(z,t),\label{eq:laxtime} \end{align} \end{subequations} where $\mathcal A$ and $\mathcal B$ are given in Equations \eqref{eq:JNLax}. The compatibility condition \begin{equation}\label{eq:ABcomp} {\mathcal A}(z, qt){\mathcal B}(z, t)={\mathcal B}(qz,t){\mathcal A}(z,t), \end{equation} is equivalent to the $q\Pfour(a)$ equation, along with a condition on the auxiliary variable $u$ given by \begin{equation}\label{eq:auxiliaryuf} \frac{\overline{u}}{u}=b^2, \end{equation} where $b$ is given by equation \eqref{eq:bb}. The linear problem \eqref{eq:laxspectral} gives rise to a Riemann Hilbert problem (RHP). In a previous paper, we showed that this Riemann Hilbert problem is uniquely solvable (under certain conditions) and proved the invertibility of the map between the linear problem and an algebraic surface, which is a $q$-version of a monodromy surface \cite{joshiroffelsenrhp}. Necessary notation is outlined in Appendix \ref{app:not}. The main result of this paper, Theorem \ref{thm:solvable}, shows that solutions that are symmetric with respect to $\mathcal{T}_-$ lead to an explicitly solvable monodromy problem at the point of reflection, with solutions built out of Jackson $q$-Bessel functions of the second kind, $J_\nu(x;p)$, with $p=q^2$ and exponents $\nu=\pm \tfrac{1}{2}$. The construction of the monodromy surface breaks down at reflection points for the case of $\mathcal{T}_+$, because it violates the non-resonance conditions of the Riemann-Hilbert problem. For the special choice of the parameters, $a_0=a_1=a_2=q^{\frac{1}{3}}$, $q\Pfour$ has a particularly simple solution, given by \begin{equation*} f_0=f_1=f_2=t^{\frac{2}{3}}, \end{equation*} which is symmetric with respect to both $\mathcal{T}_+$ and $\mathcal{T}_-$. We show that the monodromy problem of this solution is solvable everywhere in the complex plane. This solution forms a seed solution for the family of $q$-Okamoto rational solutions, introduced in Kajiwara et al. \cite{kajiwaranoumiyamada2001}. In this paper, we provide the points on the monodromy surface corresponding to each member of this family. \subsection{Outline} The symmetric solutions and their derivations are described in detail in Section \ref{s:symm}. The corresponding linear problem, connection matrix, and monodromy surface are considered in Section \ref{s:mono}. In Section \ref{sec:solve_linear}, we show that the monodromy problem for symmetric solutions is solvable at points of reflection. We consider symmetric solutions on open domains in Section \ref{s:mero}, particularly focussing on the $q$-Okamoto rational solutions, before providing a conclusion in Section \ref{s:conc}. \section{Symmetric solutions on open domains}\label{s:mero} In this section we study symmetric solutions of $q\Pfour$ defined on (connected) open subsets of the complex plane. A particular class of meromorphic solutions is given by the $q$-Okamoto rational solutions. We study them in detail and show that their monodromy problems are solvable for all values of the independent variable. Let $T$ be a non-empty, open and connected subset of the universal covering of $\mathbb{C}^*$, with $qT=T$. We call a triplet $f=(f_0,f_1,f_2)$ of meromorphic functions on $T$ that satisfies $q\Pfour$ identically, a meromorphic solution of $q\Pfour$. We call it symmetric, when the solution (and its domain) are invariant under $\mathcal{T}_+$ or $\mathcal{T}_-$. Each meromorphic solution corresponds to a unique triplet $\rho=(\rho_1,\rho_2,\rho_3)$ of complex functions on $T$ that solve the cubic equation \eqref{eq:cubic} identically in $t$ and the $q$-difference equations \begin{equation}\label{eq:rho_qdif} \rho_k(qt)=-\rho_k(t),\quad (k=1,2,3), \end{equation} which follow from the time-evolution of the connection matrix $C(z,t)$ (see equation \eqref{eq:connection_evolution}). Now, it might happen that, for special values of $t_0\in T$, the value of $f(t)$ does not lie in $(\mathbb{C}^*)^3$, for every $t\in q^\mathbb{Z}t_0$. At such times $t=t_0$, the monodromy coordinates $\rho(t)$ either have an essential singularity, or they lie on the curve defined by equations \eqref{eq:forbidden_cubic}. On the other hand, if $f(t)$ is regular for at least one value of $t\in q^\mathbb{Z}t_0$, then the value of the monodromy coordinates $\rho(t)$ at $t=t_0$ is well-defined and does not lie on the curve given by equations \eqref{eq:forbidden_cubic}. In the following, we restrict our discussion to considering meromorphic solutions which do not have $q$-spirals of poles. If such a solution is symmetric with respect to $\mathcal{T}_-$, that is, \begin{equation*} f_k(t)=1/f_k(-1/t)\quad (k=0,1,2), \end{equation*} then, by Proposition \ref{prop:actioncoordinate}, the $\rho$-coordinates have the same symmetry, \begin{equation}\label{eq:rho_sym} \rho_k(t)=-\frac{1}{\rho_k(-1/t)}\quad (k=1,2,3). \end{equation} This means that we can classify symmetric meromorphic solutions, in terms of meromorphic triplets $\rho=\rho(t)$ which solve the cubic \eqref{eq:cubic}, as well as equations \eqref{eq:rho_qdif} and \eqref{eq:rho_sym}, and do not hit the curve defined by equations \eqref{eq:forbidden_cubic}. Similar statements follow for solutions symmetric with respect to $\mathcal{T}_+$, in which case we have \begin{equation}\label{eq:rho_sym_plus} \rho_k(t)=-\rho_k(-1/t)\quad (k=1,2,3). \end{equation} In the remainder of this section, we focus on a particular collection of symmetric meromorphic solutions for which we compute the monodromy. These solutions are the $q$-Okamoto rational solutions, which are rational in $t^{\frac{1}{3}}$, derived by Kajiwara et al. \cite{kajiwaranoumiyamada2001}. \begin{theorem}[Kajiwara et al. \cite{kajiwaranoumiyamada2001}] \label{thm:oka_rational} For $m,n\in\mathbb{Z}$, the formulas \begin{align*} f_0&=x^2 r^{2n-m}\frac{Q_{m+1,n}(r^{+1}x^2)Q_{m+1,n+1}(r^{-1} x^2)}{Q_{m+1,n}(r^{-1}x^2)Q_{m+1,n+1}(r^{+1} x^2)},\\ f_1&=x^2 r^{-m-n}\frac{Q_{m+1,n+1}(r^{+1} x^2)Q_{m,n}(r^{-1}x^2)}{Q_{m+1,n+1}(r^{-1}x^2)Q_{m,n}(r^{+1} x^2)},\\ f_2&=x^2 r^{2m-n}\frac{Q_{m,n}(r^{+1}x^2)Q_{m+1,n}(r^{-1}x^2)}{Q_{m,n}(r^{-1}x^2)Q_{m+1,n}(r^{+1}x^2)}, \end{align*} give a solution of $q\Pfour$ rational in $x=t^{\frac{1}{3}}$, with parameters \begin{equation*} a_0=r q^m,\quad a_1=r q^{n-m},\quad a_2=r q^{-n},\quad r:=q^{\frac{1}{3}}, \end{equation*} in terms of the $q$-Okamoto polynomials $Q_{m,n}(x)$ defined through the recurrence relations \begin{align}\nonumber Q_{m-1,n}(x/r)Q_{m+1,n+1}(r\, x)=&Q_{m,n}(x/r)Q_{m,n+1}(r\, x)+\\ &x\,Q_{m,n+1}(x/r)Q_{m,n}(r\, x) r^{2m+2n-1},\nonumber\\ Q_{m+1,n}(x/r)Q_{m,n+1}(r\, x)=&Q_{m+1,n+1}(x/r)Q_{m,n}(r\, x)+\label{eq:okamotorecurrence}\\ &x\, Q_{m,n}(x/r)Q_{m+1,n+1}(r\, x)r^{2n-4m+1},\nonumber\\ Q_{m+1,n+1}(x/r)Q_{m,n-1}(r\, x)=&Q_{m,n}(x/r)Q_{m+1,n}(r\, x)+\nonumber\\ &x\, Q_{m+1,n}(x/r)Q_{m,n}(r\, x)r^{2m-4n+1},\nonumber \end{align} with $Q_{0,0}(x)=Q_{1,0}(x)=Q_{1,1}(x)=1$. \end{theorem} From the recurrence relations for the $q$-Okamoto polynomials, it follows that $Q_{m,n}(x)$ is a monic polynomial of degree $d_{m,n}:=m^2+n^2-m(n+1)$. Furthermore, it can be shown by induction that the polynomials are palindromic, i.e. \begin{equation}\label{eq:palindrome} x^{d_{m,n}}Q_{m,n}(1/x)=Q_{m,n}(x), \end{equation} for $m,n\in\mathbb{Z}$. It follows upon writing $f_k=f_k(x)$, that the corresponding rational solutions defined in Theorem \ref{thm:oka_rational}, satisfy \begin{equation*} f_k(x)=1/f_k(\pm 1/x), \end{equation*} for $0\leq k\leq 2$ and any choice of sign. In other words, they are invariant under both $\mathcal{T}_+$ and $\mathcal{T}_-$. Now consider the branch of $x=x(t)$ which evaluates to $x=-i$ at $t=i$. There, the $q$-Okamoto rationals specialise to the symmetric solutions on discrete time domains classified in Lemma \ref{lem:symmetric_solutions}. To see this, it is helpful to note that equation \eqref{eq:palindrome} implies \begin{equation*} (-r)^{d_{m,n}}Q_{m,n}(-1/r)=Q_{m,n}(-r). \end{equation*} Thus, at $x=-i$, so that $t=i$, \begin{align*} f_0(i)&=-r^{2n-m}\frac{Q_{m+1,n}(-r^{+1})Q_{m+1,n+1}(-r^{-1})}{Q_{m+1,n}(-r^{-1})Q_{m+1,n+1}(-r^{+1})},\\ &=-r^{2n-m}(-r)^{d_{m+1,n}-d_{m+1,n+1}},\\ &=(-1)^{1+m}. \end{align*} By similar computations for $f_1(i)$ and $f_2(i)$, we obtain \begin{equation}\label{eq:initiali} f_0(i)=(-1)^{1+m},\quad f_1(i)=(-1)^{1+m+n},\quad f_2(i)=(-1)^{1+n}. \end{equation} So depend on the values of $m,n\in\mathbb{Z}$, the $q$-Okamoto rational solutions specialise to the different symmetric solutions in Lemma \ref{lem:symmetric_solutions}, on the $q$-spiral $q^{\mathbb{Z}}i$. \subsection{Solvable monodromy for the seed solution} In this section, we consider the simplest member of the family of rational solutions defined in Theorem \ref{thm:oka_rational}, corresponding to $m=n=0$. The parameters of $q\Pfour$ then read \begin{equation*} a_0=a_1=a_2=r, \end{equation*} and \begin{equation*} f_0=f_1=f_2=x^2. \end{equation*} We call this solution the seed solution. The corresponding value of $b$ in \eqref{eq:bb} is given by \begin{equation*} b=\frac{i\,x}{1-r x^2}, \end{equation*} and explicit solutions to the auxiliary equations \eqref{eq:auxiliary} and \eqref{eq:timeevolutiond} are given by \begin{equation*} u(x)=\frac{(r\, x^2; r^2)_\infty^2}{\theta_r(x)^2},\quad d(x)=\frac{\theta_r(-x)}{(r\,x^2;r^2)_\infty}. \end{equation*} In this special case, the matrix polynomial in the spectral equation \eqref{eq:laxspectral} factorises as \begin{equation*} A(z,x)=\begin{pmatrix} u & 0\\ 0 & 1\end{pmatrix} A_1(r^2z,x)A_1(r\, z,x)A_1(z,x) \begin{pmatrix} u^{-1} & 0\\ 0 & 1\end{pmatrix}, \end{equation*} with \begin{equation*} A_1(z,x)=\begin{pmatrix} -i \,r \,x\,z & 1\\ -1 & -i\, r/x\, z \end{pmatrix}. \end{equation*} This means that any solution of \begin{equation}\label{eq:simpleqdif} Y(rz)=\begin{pmatrix} u & 0\\ 0 & 1\end{pmatrix} A_1(z,x)\begin{pmatrix} u^{-1} & 0\\ 0 & 1\end{pmatrix}Y(z), \end{equation} also defines a solution of the spectral equation. A classical result \cite{lecaine} shows that equation \eqref{eq:simpleqdif} can be solved in terms of Heine's $q$-hypergeometric functions. We can thus leverage the connection results by Watson \cite{watson}, see also \cite{gasper}[Section 4.3], to compute the connection matrix of the spectral equation. We find that the matrix function $\Phi_\infty$, defined in Lemma \ref{lem:solinf}, is given explicitly by \begin{align*} \Phi_\infty(z,t)&=(z^{-1};r)_\infty\begin{pmatrix} u & 0\\ 0 & 1\end{pmatrix} \widehat{\Phi}_\infty(z,x)\begin{pmatrix} u^{-1} & 0\\ 0 & 1\end{pmatrix},\\ \widehat{\Phi}_\infty(z,x)&=\begin{pmatrix} \hspace{11mm}\;_{2}\phi_1 \left[\begin{matrix} 1/x, -1/x \\ 1/x^2\end{matrix} ; r,\frac{1}{z} \right] & \frac{i\, x}{(1-r x^2)z} \;_{2}\phi_1 \left[\begin{matrix} r\,x, -r\,x \\ r^2 x^2\end{matrix} ; r,\frac{1}{z} \right] \vspace{1mm}\\ \frac{i\, x}{(r-x^2)z} \;_{2}\phi_1 \left[\begin{matrix} r/x, -r/x \\ r^2/x^2\end{matrix} ; r,\frac{1}{z} \right] & \hspace{8mm}\;_{2}\phi_1 \left[\begin{matrix} x, -x \\ x^2\end{matrix} ; r,\frac{1}{z} \right]\\ \end{pmatrix}. \end{align*} The matrix function $\Phi_0$, defined in Lemma \ref{lem:solzero}, is given by \begin{align*} \Phi_0(z,t)&=\frac{d}{(r z;r)_\infty}\begin{pmatrix} u & 0\\ 0 & 1\end{pmatrix} \widehat{\Phi}_0(z,x),\\ \widehat{\Phi}_0(z,x)&=\begin{pmatrix} \hspace{1.1mm}i\;_{2}\phi_1 \left[\begin{matrix} -1/x, -r \,x \\ -r\end{matrix} ; r,-r\, z \right] & -i \;_{2}\phi_1 \left[\begin{matrix} 1/x, r\,x \\ -r\end{matrix} ; r,-r\, z\right] \vspace{1mm}\\ \;_{2}\phi_1 \left[\begin{matrix} -x, -r/x \\ -r\end{matrix} ; r,-r\, z \right] & \hspace{4.3mm}\;_{2}\phi_1 \left[\begin{matrix} x, -r/x \\ -r\end{matrix} ; r,-r\, z\right]\\ \end{pmatrix}. \end{align*} The corresponding connection matrix is then \begin{align*} C(z,t)&=\widetilde{C}(z,x)\begin{pmatrix} d^{-1}u^{-1} & 0\\ 0 & d^{-1} \end{pmatrix},\\ \widetilde{C}(z,x)&=\begin{pmatrix} -i\,\theta_r(-r\,x\,z) & \theta_r(-r/x\,z)\\ +i\,\theta_r(+r\,x\,z) & \theta_r(+r/x\,z)\\ \end{pmatrix} \begin{pmatrix} \frac{(1/x,-1/x:r)_\infty}{(-1,1/x^2;r)_\infty} & 0\\ 0 & \frac{(x,-x:r)_\infty}{(-1,x^2;r)_\infty} \end{pmatrix}. \end{align*} The monodromy coordinates can now by computed directly. To this end, we note that $(x_1,x_2,x_3)=(r^{-1},r^{-2},r^{-3})$, so that \begin{equation*} \rho_k=\rho_k(x)=\pi\left[C(r^{-k},t)\right]=(-1)^k \frac{\theta_r(-x)}{\theta_r(+x)},\qquad x=t^{\frac{1}{3}}, \end{equation*} for $k=0,1,2$. In particular, we have \begin{equation*} \rho_k(r\,x)=-\rho_k(x)=\rho_k(1/x),\quad \rho_k(-1/x)=-1/\rho_k(x), \end{equation*} which confirms that the coordinates satisfy the $q$-difference equation \eqref{eq:rho_qdif} as well as symmetries \eqref{eq:rho_sym} and \eqref{eq:rho_sym_plus}. Furthermore, we note that the monodromy coordinates have three branches in the complex $t$-plane, each corresponding to a particular branch of the solution $f$. \begin{remark}Note that in light of Lemma \ref{lem:forbidden}, the only values of $x$ for which the coordinates lie on the curve \eqref{eq:forbidden_cubic}, are given by \begin{equation*} x=(-\tfrac{1}{2}\pm \tfrac{1}{2}\sqrt{3})r^n\qquad (n\in\mathbb{Z}), \end{equation*} which correspond to values of $t$ lying in $q^\mathbb{Z}$ and thus violate the non-resonance conditions \eqref{eq:conditionnonresonant}. \end{remark} \subsection{Solvable monodromy of the $q$-Okamoto rational solutions} In this section, we consider how to generate the monodromy coordinates of the whole family of rational solutions in Theorem \ref{thm:oka_rational}. We do so by applying translation elements $T_{1,2,3}$ in the affine Weyl symmetry group $(A_2+A_1)^{(1)}$, see \cite{kajiwaranoumiyamada2001}, which act on the parameters as \begin{align*} T_1:& \quad (a_0,a_1,a_2)\mapsto (q\, a_0, a_1/q,a_2),\\ T_2:& \quad (a_0,a_1,a_2)\mapsto (a_0, q\,a_1, a_2/q),\\ T_3:& \quad (a_0,a_1,a_2)\mapsto (a_0/q, a_1,q\,a_2). \end{align*} It was shown in \cite{joshinobu2016} that these translations act as Schlesinger transformations on the spectral equation \eqref{eq:laxspectral}. By methods similar to the derivation of equation \eqref{eq:rho_qdif}, it can be shown that these translations act on the monodromy coordinates as follows \begin{align*} T_1:& \quad (\rho_1,\rho_2,\rho_3)\mapsto (-\rho_1,-\rho_2,+\rho_3),\\ T_2:& \quad (\rho_1,\rho_2,\rho_3)\mapsto (-\rho_1,+\rho_2,-\rho_3),\\ T_3:& \quad (\rho_1,\rho_2,\rho_3)\mapsto (+\rho_1,-\rho_2,-\rho_3). \end{align*} For general $m,n\in\mathbb{Z}$, we claim that the monodromy coordinates corresponding to the rational solution in Theorem \ref{thm:oka_rational} are given by \begin{align} &\rho_1(x)=(-1)^{1+m+n}s(x), \nonumber\\ &\rho_2(x)=(-1)^{m}s(x), \qquad \hspace{1cm} s(x):=\frac{\theta_r(-x)}{\theta_r(+x)}.\label{eq:rhoexplicit}\\ &\rho_3(x)=(-1)^{1+n}s(x). \nonumber \end{align} We proceed to confirm the claim by checking that these formulas are consistent with equation \eqref{eq:p_explicit} in Theorem \ref{thm:solvable}. Recalling equations \eqref{eq:initiali}, which provide the rational solutions at $x=-i$, we find the initial conditions at $t=i$: \begin{equation*} (v_0,v_1,v_2)=(f_0(i),f_1(i),f_2(i))=((-1)^{1+m},(-1)^{1+m+n},(-1)^{1+n}). \end{equation*} Similarly, evaluating the expressions for the $\rho$-coordinates in equations \eqref{eq:rhoexplicit} at $x=-i$, leads to \begin{equation*} (\rho_1(-i),\rho_2(-i),\rho_3(-i))=((-1)^{m+n}i,(-1)^{m+1}i,(-1)^n i), \end{equation*} which agrees with equation \eqref{eq:p_explicit}. We conclude the section with some graphical representations of the pole distributions of a $q$-Okamoto rational solution, see Figure \ref{fig:pole_distributions}. \begin{figure}\captionsetup[subfigure]{labelformat=empty} \centering \begin{subfigure}[b]{0.46\textwidth} \centering \includegraphics[width=\textwidth]{sol3.pdf} \caption{$k=3$} \end{subfigure}\hfill \begin{subfigure}[b]{0.46\textwidth} \centering \includegraphics[width=\textwidth]{sol4.pdf} \caption{$k=4$} \end{subfigure} \begin{subfigure}[b]{0.46\textwidth} \centering \includegraphics[width=\textwidth]{sol5.pdf} \caption{$k=5$} \end{subfigure} \hfill \begin{subfigure}[b]{0.46\textwidth} \centering \includegraphics[width=\textwidth]{sol7.pdf} \caption{$k=7$} \end{subfigure} \begin{subfigure}[b]{0.46\textwidth} \centering \includegraphics[width=\textwidth]{sol10.pdf} \caption{$k=10$} \end{subfigure} \hfill \begin{subfigure}[b]{0.46\textwidth} \centering \includegraphics[width=\textwidth]{sol20.pdf} \caption{$k=20$} \end{subfigure} \caption{In these plots the roots of the polynomials occurring in the definition of the $q$-Okamoto rational solution in Theorem \ref{thm:oka_rational}, with $(m,n)=(4,7)$, are displayed, where the value of $q=r^3$ varies between the plots by $r=1-(1/2)^k$, with $k=3,4,5,7,10,20$. In each figure, the blue, green and red dots represent zeros of $Q_{m,n}(x)$, $Q_{m+1,n}(x)$ and $Q_{m+1,n+1}(x)$ respectively. } \label{fig:pole_distributions} \end{figure} \section{Explicit solvability of the linear problem at a reflection point}\label{sec:solve_linear} In this section we show that the linear problem is explicitly solvable at the reflection point $t_0=i$, for symmetric solutions. In particular, we will prove the following theorem in the end of Section \ref{subsec:construct_global}. \begin{theorem}\label{thm:solvable} Let $(f_0,f_1,f_2)$ be a symmetric solution of $q\Pfour(a)|_{t_0=i}$, invariant under $\mathcal{T}_-$, satisfying initial conditions \begin{equation*} (f_0(i),f_1(i),f_2(i))=(v_0,v_1,v_2), \end{equation*} so that (by Lemma \ref{lem:symmetric_solutions}), \begin{equation*} (v_0,v_1,v_2)\in \{(-1,-1,-1),(-1,1,1),(1,-1,1),(1,1,-1)\}. \end{equation*} Fix the auxiliary functions $u$ and $d$ by the initial conditions $u(i)=1$ and $d(i)=i$. Then, the connection matrix at $t=i$ is explicitly given by \begin{equation}\label{eq:connection_explicit} C(z,i)=2 c_0^3\begin{pmatrix} h(i\,z) & i\, h(-i\,z)\\ -h(-i\,z) & i\, h(i\,z) \end{pmatrix}, \end{equation} where the scalar $c_0$ equals \begin{equation*} c_0=\frac{\sqrt{i}\,\theta_q(i)}{\sqrt{2}\,\theta_q(-1)}=\frac{1}{2}\prod_{k=1}^\infty{ \frac{(1+q^ki)(1-q^ki)}{(1+q^k)^2}}, \end{equation*} and the function $h(z)$ is defined by \begin{align*} h(z)=&+\theta_q\bigg(+\frac{v_1}{x_1}z,-\frac{v_0}{x_2}z,+\frac{v_2}{x_3} z\bigg)-\theta_q\bigg(+\frac{v_1}{x_1}z,+\frac{v_0}{x_2}z,-\frac{v_2}{x_3} z\bigg)\\ &-\theta_q\bigg(-\frac{v_1}{x_1}z,-\frac{v_0}{x_2}z,-\frac{v_2}{x_3} z\bigg)-\theta_q\bigg(-\frac{v_1}{x_1}z,+\frac{v_0}{x_2}z,+\frac{v_2}{x_3} z\bigg), \end{align*} with \begin{equation*} (x_1,x_2,x_3)=(a_0^{-1},a_1/q,q^{-1}). \end{equation*} In particular, the corresponding values of the monodromy coordinates, $p_k=\rho_k(i)$, $k=1,2,3$, are given by \begin{equation}\label{eq:p_explicit} (p_1,p_2,p_3)=(-v_1i,v_0i,-v_2i). \end{equation} \end{theorem} \begin{remark} In the proof of Theorem \ref{thm:solvable}, we also obtain the following alternative expression for the connection matrix, \begin{equation*} C(z)=\sigma_1 C_0\left(\frac{v_1}{x_1} z\right) M C_0\left(-\frac{v_0}{x_2} z\right)MC_0\left(\frac{v_2}{x_3} z\right), \end{equation*} where $C_0(z)$, given in Proposition \ref{prop:connection}, is the connection matrix of a degree one Fuchsian system and the matrix $M$ is defined in equation \eqref{eq:defiM}. \end{remark} The spectral equation of the Lax pair \eqref{eq:laxpair} naturally comes in a factorised form. The fundamental reason that allows us to solve the linear problem at the reflection point $t=i$, for a symmetric solution as in Theorem \ref{thm:solvable}, is that the factors in this form `almost' commute. Namely, by fixing $u(i)=1$, we have \begin{equation*} A(z,i)=A_0\left(\frac{v_2z}{x_3}\right) A_0\left(\frac{v_0z}{x_2}\right) A_0\left(\frac{v_1z}{x_1}\right), \end{equation*} where \begin{equation*} A_0(z)=i\,\sigma_2+z\,\sigma_3, \end{equation*} and these factors satisfy the commutation relation, \begin{equation}\label{eq:commutation_relation} A_0(x)A_0(y)=A_0(-y)A_0(-x). \end{equation} This observation allows us to construct global solutions of the linear system \begin{equation*} Y(qz)=A(z,i)Y(z), \end{equation*} from solutions of the simpler system \begin{equation*} U(qz)=A_0(z)U(z), \end{equation*} which we will refer to as the model problem. In Section \ref{subsec:model_solve}, we solve this model problem, and in Section \ref{subsec:construct_global} we use this to construct global solutions of the spectral equation at $t=i$ and prove Theorem \ref{thm:solvable}. The model problem is solved in terms of basic hypergeometric functions, denoted for given parameter $a$, $0<p<1$ and $z\in\mathbb C$ by \[ _{0}\phi_1\left[\begin{matrix} \text{-} \\ a \end{matrix} ; p, z \right], \] whose mathematical properties can be found in \cite{gasper}. \subsection{The model problem}\label{subsec:model_solve} In this section, we study the model problem, \begin{equation*} U(qz)=A_0(z)U(z),\quad A_0(z)=i\,\sigma_2+z\sigma_3. \end{equation*} Firstly, we find an explicit expression for the canonical solution at $z=\infty$. \begin{lemma}\label{lem:model_sol_inf} There exists a unique matrix function $U_\infty(z)$, analytic on $\mathbb{C}^*$, which solves \begin{equation}\label{eq:power_series} U_\infty(qz)=z^{-1}A_0(z)U_\infty(z)\sigma_3,\qquad U_\infty(z)=I+\mathcal{O}(z^{-1})\quad (z\rightarrow \infty), \end{equation} explicitly given by \begin{equation*} U_\infty(z)=g_\infty(z)I+h_\infty(z)\sigma_1, \end{equation*} where $g_\infty(z)$ and $h_\infty(z)$ are the basic hypergeometric functions, \begin{align*} g_\infty(z)&=\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q \end{matrix} ; q^2,-\frac{q^3}{z^2} \right],\\ h_\infty(z)&=-\frac{q}{(q+1)z}\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q^3 \end{matrix} ; q^2,-\frac{q^5}{z^2} \right]. \end{align*} \end{lemma} \begin{proof} It is an elementary computation to show that \eqref{eq:power_series} has a unique formal power series solution around $z=\infty$. Furthermore, by using the defining formula, \begin{equation}\label{eq:hyper} \;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ b\end{matrix} ; p,x \right]=\sum_{n=0}^\infty \frac{p^{n(n-1)}}{(b;p)_n(p;p)_n}x^n, \end{equation} it is checked directly that this formal power series solution is indeed given by $U_\infty(z)$. Since, furthermore, the series \eqref{eq:hyper} has infinite radius of convergence, $U_\infty(z)$ is an analytic function on $\mathbb{CP}^1\setminus\{0\}$, which thus uniquely solves equation \eqref{eq:power_series}, and the lemma follows. \end{proof} We have a similar result near $z=0$. \begin{lemma} Define \begin{equation}\label{eq:defiM} M=\begin{pmatrix} 1 & -1\\ i & i \end{pmatrix}, \end{equation} so that $M^{-1}(i\,\sigma_2)M=i\,\sigma_3$. Then, there exists a unique matrix function $U_0(z)$, meromorphic on $\mathbb{C}$, which satisfies \begin{equation*} U_0(qz)=A_0(z)U_0(z)(i\,\sigma_3)^{-1},\qquad U_0(z)=M+\mathcal{O}(z)\quad (z\rightarrow 0), \end{equation*} explicitly given by \begin{equation*} U_0(z)=\frac{1}{(+z;q)_\infty(-z;q)_\infty}M\cdot (g_0(z)I+h_0(z)\sigma_2), \end{equation*} where \begin{align*} g_0(z)&=\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q \end{matrix} ; q^2,- q z^2\right],\\ h_0(z)&=\frac{z}{q+1}\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q^3 \end{matrix} ; q^2,-q^3 z^2 \right]. \end{align*} \end{lemma} \begin{proof} This is proven analogously to Lemma \ref{lem:model_sol_inf}. \end{proof} In the following proposition, we explicitly determine the connection matrix of the model problem. \begin{proposition}\label{prop:connection} The connection matrix \begin{equation}\label{eq:connection} C_0(z)=U_0(z)^{-1}U_\infty(z), \end{equation} is given by \begin{equation*} C_0(z)=c_0\left(\theta_q(+i z)\begin{pmatrix} 1 & 0\\ 0 & -i \end{pmatrix}+\theta_q(-i z)\begin{pmatrix} 0 & -i\\ -1 & 0 \end{pmatrix}\right), \end{equation*} where the scalar $c_0$ is given by \begin{equation*} c_0:=\frac{\sqrt{i}\,\theta_q(i)}{\sqrt{2}\,\theta_q(-1)}=\frac{1}{2}\prod_{k=1}^\infty{ \frac{(1+q^ki)(1-q^ki)}{(1+q^k)^2}}. \end{equation*} \end{proposition} \begin{proof} From the defining properties of $U_\infty(z)$ and $U_0(z)$, it follows that \begin{equation}\label{eq:sol_det} |U_\infty(z)|=(+z,q)_\infty (-z,q)_\infty,\quad |U_0(z)|=2 i(+q/z,q)_\infty^{-1} (-q/z,q)_\infty^{-1}. \end{equation} In particular, $C_0(z)$ is an analytic function on $\mathbb{C}^*$. Furthermore, it satisfies \begin{equation*} C_0(qz)=i\,z^{-1}\sigma_3C_0(z)\sigma_3, \end{equation*} and its entries are thus degree one $q$-theta functions, i.e. \begin{equation*} C_0(z)=\theta_q(+i z)\begin{pmatrix} c_{11} & 0\\ 0 & c_{22} \end{pmatrix}+\theta_q(-i z)\begin{pmatrix} 0 & c_{12}\\ c_{21} & 0 \end{pmatrix}, \end{equation*} for some $c_{ij}\in\mathbb{C}, 1\leq i,j\leq 2$. Now, observe that \begin{equation*} U_\infty(z)^{\diamond}=\sigma_3 U_\infty(z)\sigma_3,\quad U_0(z)^{\diamond}=i\,\sigma_3 U_0(z), \end{equation*} and therefore \begin{equation*} C_0(z)^{\diamond}=-i\,C_0(z)\sigma_3. \end{equation*} We thus find the following conditions on the coefficients, \begin{equation*} c_{11}=i\,c_{22},\quad c_{12}=i\,c_{21}. \end{equation*} Due to equations \eqref{eq:sol_det}, we have \begin{equation*} |C_0(z)|=\frac{1}{2i}\theta_q(+z)\theta_q(-z). \end{equation*} Evaluating this identity at $z=i$, gives \begin{equation*} -i\theta_q(-1)^2 c_{11}^2=\frac{1}{2i}\theta_q(+i)\theta_q(-i)=\frac{1}{2}\theta_q(i)^2, \end{equation*} and therefore $c_{11}^2=c_0^2$. Similarly, we obtain $c_{21}^2=c_0^2$, so that \begin{equation*} c_{11}=\epsilon_1 c_0,\quad c_{21}=\epsilon_2 c_0, \end{equation*} for some $\epsilon_{1,2}\in\{\pm 1\}$. Note that $\epsilon_{1,2}$ must be continuous functions of $q$ in the punctured unit disc $\{0<|q|<1\}$ and they are thus global constants. We now choose $0<q<1$, so that \begin{equation*} \overline{U_\infty(\overline{z})}=U_\infty(z),\quad \overline{U_0(\overline{z})}=-U_0(z)\sigma_1. \end{equation*} In particular, this means that \begin{equation*} \overline{C_0(\overline{z})}=-\sigma_1 C_0(z), \end{equation*} and, by noting that $\overline{c_0}=c_0$, we thus obtain $\epsilon_1=\epsilon_2$. It only remains to be checked that $\epsilon_1=1$. To this end, note that equation \eqref{eq:connection} implies the following connection result, \begin{equation*} g_\infty(z)=\frac{\epsilon_1 c_0}{(z^2,q^2)_\infty} \left[(\theta_q(i\, z)+\theta_q(-i\,z))g_0(z)-i(\theta_q(i\, z)-\theta_q(-i\,z))h_0(z)\right]. \end{equation*} Setting $z=i\,x$, with $0<x<\infty$, we thus have \begin{equation}\label{eq:positive_identity} g_\infty(i\,x)=\frac{\epsilon_1 c_0}{(-x^2,q^2)_\infty} \left[(\theta_q(-x)+\theta_q(x))g_0(z)+(\theta_q(-x)-\theta_q(x))(-i\,h_0(i\, x))\right]. \end{equation} We claim that each of the terms \begin{equation*} g_\infty(i\,x),\quad g_0(i\,x),\quad -i \,h_0(i\,x),\quad (-x^2,q)_\infty,\quad \theta_q(-x)\pm\theta_q(x), \end{equation*} is a real and positive function of $x$ on $(0,+\infty)$. For example, the inequality $(-x;q)_\infty>(+x;q)_\infty$, on the positive real line, follows almost directly from the definition of the $q$-Pochammer symbol, and thus \begin{equation*} b(x):=\theta_q(-x)-\theta_q(+x)>0, \end{equation*} on the positive real line. Therefore, also \begin{equation*} \theta_q(-x)+\theta_q(+x)=x\,b(q\,x)>0, \end{equation*} on the positive real line. Each of the hypergeometric series, $g_\infty(i\,x), g_0(i\,x), -i \,h_0(i\,x)>0$, on the positive real line, since all the coefficients in the different series are positive. Since $c_0>0$, equation \eqref{eq:positive_identity} can thus only hold if $\epsilon_1=+1$, and the proposition follows. \end{proof} \begin{corollary}\label{cor:connection} The explicit expression for the connection matrix in Proposition \ref{prop:connection}, yields the following connection formulas, \begin{align*} \;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q \end{matrix} ; q^2,-\frac{q^3}{z^2} \right]=&+ \frac{c_0(\theta_q(-i\, z)+\theta_q(i\, z))}{(z^2;q^2)_\infty}\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q \end{matrix} ; q^2,-q z^2\right]\\ &+ \frac{c_0\, i\, z(\theta_q(-i\, z)-\theta_q(i\, z))}{(1+q)(z^2;q^2)_\infty}\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q^3 \end{matrix} ; q^2,-q^3 z^2 \right], \\ \;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q^3 \end{matrix} ; q^2,-\frac{q^5}{z^2} \right]=&+ \frac{(1+q)c_0\, i\,z(\theta_q(-i\, z)-\theta_q(i\, z))}{q(z^2;q^2)_\infty}\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q \end{matrix} ; q^2,-q z^2\right]\\ &+ \frac{c_0\,z^2(\theta_q(-i\, z)+\theta_q(i\, z))}{q(z^2;q^2)_\infty}\;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ -q^3 \end{matrix} ; q^2,-q^3 z^2 \right], \end{align*} where the value of $c_0$ is given in Proposition \ref{prop:connection}. \end{corollary} \begin{remark} Note that the solutions to the model problem are essentially built out of Jackson $q$-Bessel functions of the second kind, \begin{equation*} J_\nu(x;p)=\frac{(p^{\nu+1};p)_\infty}{(p;p)_\infty}\left(\frac{x}{2}\right)^\nu \;_{0}\phi_1 \left[\begin{matrix} \text{-} \\ p^{\nu+1} \end{matrix} ; p,-\frac{x^2 p^{\nu+1}}{4} \right], \end{equation*} with $p=q^2$ and $\nu=\pm\tfrac{1}{2}$. In particular, we could have alternatively used the known connection results for these functions \cites{zhangbessel,moritabessel}, in conjunction with transformation formulas for $\;_{0}\phi_1$ hypergeometric functions \cite{gasper}, to obtain the connection formulas in Corollary \ref{cor:connection} and, consequently, Proposition \ref{prop:connection}. \end{remark} \subsection{Constructing global solutions}\label{subsec:construct_global} In this section, we construct solutions of the spectral equation at $t=i$ given by \begin{equation*} Y(qz)=A(z,i)Y(z),\quad A(z,i)=A_0\left(\frac{v_2z}{x_3}\right) A_0\left(\frac{v_0z}{x_2}\right) A_0\left(\frac{v_1z}{x_1}\right). \end{equation*} Motivated by the commutation relation \eqref{eq:commutation_relation}, we consider the ansatz \begin{equation}\label{eq:phiinf} \Phi_\infty(z)=U_\infty(r_1 z)U_\infty(r_2 z)U_\infty(r_3 z), \end{equation} for the matrix function $\Phi_\infty(z)$ defined in Lemma \ref{lem:solinf}, for some $r_1,r_2,r_3$ to be determined. Using the commutation relation \begin{equation*} U_\infty(xz)\sigma_3A_0(yz)=\sigma_3A_0(yz)U_\infty(xz), \end{equation*} we find \begin{align*} \Phi_\infty(qz)&=U_\infty(qr_1 z)U_\infty(qr_2 z)U_\infty(qr_3 z),\\ &=\frac{1}{r_1r_2r_3 z^3}A_0(r_1z)U_\infty(r_1z)\sigma_3 A_0(r_2z)U_\infty(r_2z)\sigma_3 A_0(r_3z)U_\infty(r_3z)\sigma_3\\ &=\frac{1}{r_1r_2r_3 z^3}A_0(r_1z)\sigma_3 A_0(r_2z)U_\infty(r_1z)\sigma_3 A_0(r_3z)U_\infty(r_2z)U_\infty(r_3z)\sigma_3\\ &=\frac{1}{r_1r_2r_3 z^3}A_0(r_1z)\sigma_3 A_0(r_2z)\sigma_3 A_0(r_3z)U_\infty(r_1z)U_\infty(r_2z)U_\infty(r_3z)\sigma_3\\ &=\frac{1}{r_1r_2r_3 i z^3}A_0(r_1z)A_0(-r_2z) A_0(r_3z)U_\infty(r_1z)U_\infty(r_2z)U_\infty(r_3z)(i\sigma_3)^{-1}. \end{align*} Therefore, if we set \begin{equation}\label{eq:defi_r} (r_1,r_2,r_3)=\left(\frac{v_2}{x_3},-\frac{v_0}{x_2},\frac{v_1}{x_1}\right), \end{equation} then $\Phi_\infty(z)$ solves \begin{equation*} \Phi_\infty(qz)= \frac{1}{qa_0^2a_2i}z^{-3}A(z,i)\Phi_\infty(z)(i\sigma_3)^{-1}. \end{equation*} Furthermore, note that $\Phi_\infty(z)=I+\mathcal{O}(z^{-1})$ as $z\rightarrow \infty$, so that our ansatz is indeed correct for the choice of $(r_1,r_2,r_3)$ above. Similarly, using the commutation relation \begin{equation*} U_0(xz)M^{-1}(i\,\sigma_2)A_0(yz)=(i\,\sigma_2)A_0(yz)U_0(xz)M^{-1}, \end{equation*} it follows that \begin{equation}\label{eq:phi0} \Phi_0(z)=U_0(r_1z)M^{-1}U_0(r_2z)M^{-1}U_0(r_3z)\sigma_1, \end{equation} satisfies \begin{align*} \Phi_0(qz)&=A(z,i)\Phi_0(z)(i\sigma_3)^{-1},\\ \Phi_0(z)&=M\sigma_1+\mathcal{O}(z)\quad (z\rightarrow 0), \end{align*} for the same choice of $(r_1,r_2,r_3)$. Furthermore, note that \begin{equation*} M\sigma_1=M_0, \end{equation*} if we choose $d(i)=i$ in equation \eqref{eq:A0iv}. Therefore, the formula for $\Phi_0(z)$ above is an explicit expression for the canonical matrix function at $z=0$ defined in Lemma \ref{lem:solzero}. We are now in a position to prove Theorem \ref{thm:solvable}. \begin{proof}[Proof of Theorem \ref{thm:solvable}] By definition, the connection matrix at $t=i$ is given by \begin{equation*} C(z,i)=\Phi_0(z)^{-1}\Phi_\infty(z), \end{equation*} where $\Phi_\infty(z)$ and $\Phi_0(z)$ are given by the explicit formulas \eqref{eq:phiinf} and \eqref{eq:phi0}. This yields, \begin{equation*} C(z)=\sigma_1 C_0(r_3 z)U_\infty(r_3 z)^{-1} M C_0(r_2 z)U_\infty(r_2 z)^{-1} M C_0(r_1 z)U_\infty(r_2 z) U_\infty(r_3 z), \end{equation*} where the constants $(r_1,r_2,r_3)$ are defined in equation \eqref{eq:defi_r} and $M$ is defined in equation \eqref{eq:defiM}. In order to simplify this expression, we use the following commutation relations, \begin{equation*} M \sigma_2=-\sigma_1 M,\quad C_0(z) \sigma_1=-\sigma_2 C_0(z), \end{equation*} so that, \begin{align*} MC_0(r_1 z)U_\infty(r_2 z)&=M C_0(r_1 z)(g(r_2 z)I+h(r_2 z)\sigma_1)\\ &=M(g(r_2 z)I-h(r_2 z)\sigma_2)C_0(r_1 z)\\ &=(g(r_2 z)I+h(r_2 z)\sigma_1)MC_0(r_1 z)\\ &=U_\infty(r_2 z)MC_0(r_1 z). \end{align*} In other words, $MC_0(r_1 z)$ and $U_\infty(r_2 z)$ commute and we thus obtain the following simpler expression for $C(z)$, \begin{equation*} C(z)=\sigma_1 C_0(r_3 z)U_\infty(r_3 z)^{-1} M C_0(r_2 z)MC_0(r_1 z) U_\infty(r_3 z). \end{equation*} It follows from the computation before, that $MC_0(r_{1,2} z)$ also commutes with $U_\infty(r_3 z)$, and we thus obtain \begin{equation}\label{eq:Cfactorised} C(z)=\sigma_1 C_0(r_3 z) M C_0(r_2 z)MC_0(r_1 z). \end{equation} It is now a direct computation that yields the explicit expression \eqref{eq:connection_explicit} for $C(z)$. The same holds true for the expressions for the monodromy coordinates \eqref{eq:p_explicit}, using equation \eqref{eq:connection_explicit}. Rather than going through these computations, we finish the proof of the theorem with an alternative method to compute e.g. $p_1$. Using the factorisation \eqref{eq:Cfactorised}, we find \begin{align*} p_1&=\pi\left[C(x_1)\right]\\ &=\pi\left[\sigma_1 C_0(r_3 x_1) M C_0(r_2 x_1)MC_0(r_1 x_1)\right]\\ &=\pi\left[\sigma_1 C_0(v_1) M C_0(-v_0 x_1/x_2)MC_0(v_2 x_1/x_3)\right]. \end{align*} Due to the non-resonance conditions \eqref{eq:conditionnonresonant}, neither $|C_0(-v_0 x_1/x_2)|$ nor $|C_0(v_2 x_1/x_3)|$ vanishes, so by identities \eqref{eq:pi_identities} for the $\pi(\cdot)$ operator, we obtain \begin{align*} p_1&=\pi\left[\sigma_1 C_0(v_1)\right]=1/\pi\left[C_0(v_1)\right]=-\frac{\theta_q(-i\, v_1)}{\theta_q(+i\, v_1)}=-\frac{\theta_q(q\,i\, v_1)}{\theta_q(+i\, v_1)}=-i\, v_1. \end{align*} Similar computations can be carried out of $p_{2,3}$ and the theorem follows. \end{proof} \section{Symmetric Solutions $q\Psix$} In this section, we consider the system known as the $q$-difference sixth Painlev\'e equation \begin{equation}\label{eq:qpvi} q\Psix:\ \begin{cases}\ f\overline{f}&=\dfrac{(\overline{g}-\kappa_0t)(\overline{g}-\kappa_0^{-1}t)}{(\overline{g}-\kappa_\infty)(\overline{g}-q^{-1}\kappa_\infty^{-1})},\\ \ g\overline{g}&=\dfrac{(f-\kappa_tt)(f-\kappa_t^{-1}t)}{q(f-\kappa_1)(f-\kappa_1^{-1})}, \end{cases} \end{equation} where $\kappa=(\kappa_0,\kappa_t,\kappa_1,\kappa_\infty)\in\mathbb C^4$ are given nonzero parameters and we have used the abbreviated notation $f=f(t)$, $g=g(t)$,$\overline{f}=f(qt)$, $\overline{g}=g(qt)$, for $t\in T$. We will refer to Equations \eqref{eq:qpvi} as $q\Psix$, to be concise. Letting $q\rightarrow 1$ in $q\Psix$, with $\kappa_j=q^{k_j}$ for $j=0,t,1,\infty$, under the assumption that $f\rightarrow u$ and $g\rightarrow (u-t)/(u-1)$, the system reduces to the classical sixth Painlev\'e equation, \begin{align*} u_{tt}=&\left(\frac{1}{u}+\frac{1}{u-1}+\frac{1}{u-t}\right)\frac{u_t^2}{2}-\left(\frac{1}{t}+\frac{1}{t-1}+\frac{1}{u-t}\right)u_t\\ &+\frac{u(u-1)(u-t)}{t^2(t-1)^2}\left(\alpha+\frac{\beta t}{u^2}+\frac{\gamma(t-1)}{(u-1)^2}+\frac{\delta t(t-1)}{(u-t)^2}\right), \end{align*} where \begin{equation*} \alpha=\frac{(2 k_\infty-1)^2}{2},\quad \beta=-2 k_0^2,\quad \gamma =2k_1^2,\quad \delta=\frac{1-4 k_t^2}{2}. \end{equation*} $\Psix$ has the following symmetries: \begin{equation*} T_{\text{VI}}: t\mapsto 1/t,\quad u\mapsto U=tu,\quad k_t \leftrightarrow k_1,\qquad (U(t)=tu(1/t)) \end{equation*} and \begin{equation*} t\mapsto 1-t,\quad u\mapsto U=1-u,\quad k_0 \leftrightarrow k_1. \end{equation*} We focus on $T_{\text{VI}}$. Its $q$-analog seems to be \begin{equation*} T_{\text{VI}}^q: t\rightarrow 1/t,\quad f\mapsto F=tf,\quad g\mapsto G=\frac{1}{q\overline{g}},\quad \kappa_t \leftrightarrow \kappa_1, \end{equation*} i.e. \begin{equation*} F(t)=tf(1/t),\quad G(t)=\frac{1}{q g(q/t)}. \end{equation*} Therefore, if we set $\kappa_t=\kappa_1$ in $q\Psix$ then $T_{\text{VI}}^q$ defines a symmetry of $q\Psix(\kappa)$ with $\kappa$ fixed. If we take a discrete-time solution $(f,g)$ of $q\Psix(\kappa,t_0)$, then \begin{equation*} F(q^mt_0^{-1})=q^mt_0^{-1}f(q^{-m}t_0),\quad G(q^mt_0^{-1})=\frac{1}{q g(q^{1-m}t_0)}, \end{equation*} defines a discrete-time solution of $q\Psix(\kappa,t_0^{-1})$. Thus, if we set $t_0=\pm 1$, then \begin{equation*} F(q^mt_0)=q^mt_0f(q^{-m}t_0),\quad G(q^mt_0)=\frac{1}{q g(q^{1-m}t_0)}, \end{equation*} defines a symmetry of $q\Psix(\kappa,t_0)$. The non-resonance conditions \begin{equation}\label{eq:non_res} \kappa_0^2,\kappa_t^2,\kappa_1^2,\kappa_\infty^2\notin q^\mathbb{Z},\qquad (\kappa_t\kappa_1)^{\pm 1}, (\kappa_t/\kappa_1)^{\pm 1}\notin t_0q^\mathbb{Z}. \end{equation} force us to set $t_0=-1$, as $\kappa_1=\kappa_t$, and we are then left with the conditions \begin{equation}\label{eq:non_res_red} \kappa_0^2,\kappa_t^2,\kappa_\infty^2\notin q^\mathbb{Z}. \end{equation} We thus focus on the symmetry \begin{equation}\label{eq:symmetryqpvi} F(q^mt_0)=q^mt_0f(q^{-m}t_0),\quad G(q^mt_0)=\frac{1}{q g(q^{1-m}t_0)},\quad t_0=-1,\quad \kappa_t=\kappa_1, \end{equation} and solutions of $q\Psix(\kappa,t_0)$ which are symmetric with respect to this symmetry. \subsection{A symmetry of the corresponding algebraic surface} \begin{definition}\label{def:modulispace} Define the quadratic polynomial \begin{equation*} T(p:\kappa,t_0)=T_{12}p_1p_2+T_{13}p_1p_3+T_{14}p_1p_4+T_{23}p_2p_3+T_{24}p_2p_4+T_{34}p_3p_4, \end{equation*} with coefficients given by \begin{align*} T_{12}&= \theta_q\left(\kappa_t^2,\kappa_1^2\right)\theta_q\left(\kappa_0\kappa_\infty^{-1}t_0,\kappa_0^{-1}\kappa_\infty^{-1}t_0\right)\kappa_\infty^2,\\ T_{34}&= \theta_q\left(\kappa_t^2,\kappa_1^2\right)\theta_q\left(\kappa_0\kappa_\infty t_0,\kappa_0^{-1}\kappa_\infty t_0\right),\\ T_{13}&=- \theta_q\left(\kappa_t\kappa_1^{-1}t_0,\kappa_t^{-1}\kappa_1t_0\right)\theta_q\left(\kappa_t\kappa_1\kappa_0^{-1}\kappa_\infty^{-1},\kappa_0\kappa_t\kappa_1\kappa_\infty^{-1}\right)\kappa_\infty^2,\\ T_{24}&=-\theta_q\left(\kappa_t\kappa_1^{-1}t_0,\kappa_t^{-1}\kappa_1t_0\right) \theta_q\left(\kappa_0\kappa_t\kappa_1\kappa_\infty,\kappa_t\kappa_1\kappa_\infty\kappa_0^{-1}\right),\\ T_{23}&= \theta_q\left(\kappa_t\kappa_1t_0,\kappa_t^{-1}\kappa_1^{-1}t_0\right)\theta_q\left(\kappa_t\kappa_\infty\kappa_0^{-1}\kappa_1^{-1},\kappa_0\kappa_t\kappa_\infty\kappa_1^{-1}\right)\kappa_1^2,\\ T_{14}&= \theta_q\left(\kappa_t\kappa_1t_0,\kappa_t^{-1}\kappa_1^{-1}t_0\right)\theta_q\left(\kappa_1\kappa_\infty\kappa_0^{-1}\kappa_t^{-1},\kappa_0\kappa_1\kappa_\infty\kappa_t^{-1}\right)\kappa_t^2. \end{align*} Note that $T$ is homogeneous of quad-degree $(1,1,1,1)$ in the variables $p=(p_1,p_2,p_3,p_4)$. Therefore, if we denote its homogeneous form by \begin{equation}\label{eq:defthom} T_{hom}(p_1^x,p_1^y,p_2^x,p_2^y,p_3^x,p_3^y,p_4^x,p_4^y)=p_1^yp_2^yp_3^yp_4^yT\left(\frac{p_1^x}{p_1^y},\frac{p_2^x}{p_2^y},\frac{p_3^x}{p_3^y},\frac{p_4^x}{p_4^y}\right), \end{equation} then, using homogeneous coordinates $p_k=[p_k^x: p_k^y]\in \mathbb P^1$, $1\le k\le 4$, the equation \begin{equation}\label{eq:Thom} T_{hom}(p_1^x,p_1^y,p_2^x,p_2^y,p_3^x,p_3^y,p_4^x,p_4^y)=0 \end{equation} defines a surface in $(\mathbb{P}^1)^4/\mathbb{C}^*$. We denote this surface by \begin{equation*} \mathcal{S}(\kappa,t_0)=\{[p]\in (\mathbb{P}^1)^4/\mathbb{C}^*:T(p:\kappa,t_0)=0\} . \end{equation*} \end{definition} Our second main result is given by the following theorem. \begin{theorem}\label{thm:main_moduli} Let $\kappa$ and $t_0$ be such that the non-resonance conditions \eqref{eq:non_res} are fulfilled. Then the image of the monodromy surface $\mathcal{M}(\kappa,t_0)$ under the mapping $\mathcal{P}$, is given by the surface $\mathcal{S}(\kappa,t_0)$ minus the closed curve \begin{equation}\label{eq:subvariety} \mathcal{X}(\kappa_t,\kappa_1,\kappa_\infty,t_0):=\bigcap_{\lambda_0\in\mathbb{C}^*}\mathcal{S}(\lambda_0,\kappa_t,\kappa_1,\kappa_\infty,t_0). \end{equation} Let us denote by $\mathcal{S}^*(\kappa,t_0)$ the space obtained by cutting aforementioned curve from $\mathcal{S}(\kappa,t_0)$, then the mapping \begin{equation*} \mathcal{M}(\kappa,t_0)\rightarrow \mathcal{S}^*(\kappa,t_0),\ \textrm{where}\ [C(z)] \mapsto \mathcal{P}([C(z)]), \end{equation*} is a bijection. \end{theorem} Under the following parameter transformation \begin{equation*} t_0\mapsto t_0^{-1}, \quad\kappa_t\leftrightarrow \kappa_1, \end{equation*} the coefficient $T_{ij}$ of the polynomial $T(p:\kappa,t_0)$ transform as follows, \begin{align*} &T_{12}\mapsto T_{34}t_0^{-2},\\ &T_{34}\mapsto T_{12}t_0^{-2},\\ &T_{13}\mapsto T_{13}t_0^{-2},\\ &T_{24}\mapsto T_{24}t_0^{-2},\\ &T_{14}\mapsto T_{23}t_0^{-2},\\ &T_{23}\mapsto T_{14}t_0^{-2}. \end{align*} In particular, the surface $\mathcal{S}^*(\kappa,t_0)$ is invariant under \begin{equation*} t_0\mapsto t_0^{-1},\quad \kappa_t\leftrightarrow \kappa_1,\quad (p_1,p_2,p_3,p_4)\mapsto c(p_3,p_4,p_1,p_2), \end{equation*} for any $c\in\mathbb{C}^*$. Setting $t_0=-1$, $\kappa_t=\kappa_1$ and \begin{equation*} c(p_3,p_4,p_1,p_2)=(p_1,p_2,p_3,p_4), \end{equation*} we find $c=\pm 1$ and the equation $T=0$ becomes \begin{equation*} T_{13}p_1^2+(T_{12}c+T_{14}+T_{23})p_1p_2+T_{24}p_2^2=0. \end{equation*} Furthermore, as the surface is defined within $(\mathbb{P}^1)^4/\mathbb{C}^*$, and clearly $p_2\neq 0,\infty$ for generic parameter values (as $T_{13},T_{24}\neq 0$), we may thus normalise $p_2$ to $p_2=1$, so that we end up with \begin{equation*} T_{13}p_1^2+(T_{12}c+T_{14}+T_{23})p_1+T_{24}=0. \end{equation*} We thus predict the existence of four symmetric solutions of $q\Psix(\kappa,t_0)$ with respect to the symmetry \eqref{eq:symmetryqpvi}, two for each choice of $c=\pm 1$. \section{Symmetries and the linear problem}\label{s:mono} In this section, we recall some essential aspects of the linear problem associated with $q\Pfour$ and study their interplay with the symmetries $\mathcal{T}_{\pm}$. In Section \ref{subsection:recaplinearproblem} we recall the Lax pair associated with $q\Pfour$ and lift the action of $\mathcal{T}_{\pm}$ to it. Then, in Section \ref{eq:symmetric_connect}, we introduce the connection matrix associated with the linear problem and derive how the symmetries act on it. Finally, in Section \ref{subsec:tyurin}, we compute how $\mathcal{T}_{\pm}$ transform certain monodromy coordinates and provide an alternative way to classify symmetric solutions. \subsection{The Lax pair}\label{subsection:recaplinearproblem} We recall the following Lax pair of $q\Pfour$, derived in \cite{joshinobu2016}, \begin{subequations}\label{eq:qLax} \begin{align} Y(q z, t)&=A(z, t)Y(z,t),\label{eq:A}\\ Y(z, q t)&=B(z, t)Y(z,t),\label{eq:B} \end{align} \end{subequations} where \begin{subequations}\label{eq:JNLax} \begin{align} \notag A:=&\begin{pmatrix} u & 0\\ 0 & 1 \end{pmatrix}\begin{pmatrix} -i\,q\frac{t}{f_2}z & 1\\ -1 & -\,i\,q\frac{f_2}{t} z \end{pmatrix} \begin{pmatrix} -\,i\,a_0a_2\frac{t }{f_0}z & 1\\ -1 & -\,i\,a_0a_2\frac{f_0}{t} z \end{pmatrix}\times\\ &\ \times\, \begin{pmatrix} -\,i\,a_0\frac{t}{f_1}z & 1\\ -1 & -\,i\,a_0\frac{f_1}{t} z \end{pmatrix}\begin{pmatrix} u^{-1} & 0\\ 0 & 1 \end{pmatrix},\label{eq:AJN}\\ B:=&\begin{pmatrix} 0 & -bu\\ b^{-1}u^{-1} & 0 \end{pmatrix}+ \begin{pmatrix} z & 0\\ 0 & 0 \end{pmatrix}\,,\label{eq:BJN} \end{align} \end{subequations} with \begin{equation}\label{eq:bb} b=\frac{t(1+a_1f_1(1+a_2f_2))}{i\,(qt^2-1)f_2}. \end{equation} We refer to the first equation of the Lax pair, equation \eqref{eq:laxspectral}, as the spectral equation. Compatibility of the Lax pair, \begin{equation}\label{eq:comp} A(z,qt)B(z,t)=B(qz,t)A(z,t), \end{equation} is equivalent to $(f_0,f_1,f_2)$ satisfying $q\Pfour(a)$ and $u$ satisfying the auxiliary equation \begin{equation}\label{eq:auxiliary} \frac{\overline{u}}{u}=b^2. \end{equation} We proceed to lift the symmetries $\mathcal{T}_{\pm}$ to this Lax pair. To this end, the following notation will be helpful. For any $2\times 2$ matrix $U$, we let $U^{\diamond}$ denotes the co-factor matrix, or adjugate transpose, of $U$. In other words, \begin{equation*} \begin{pmatrix} a & b\\ c & d \end{pmatrix}^{\diamond}=\begin{pmatrix} d & -c\\ -b & a \end{pmatrix}. \end{equation*} \begin{lemma} The symmetry $\mathcal{T}_+$ extends to the following symmetry of the Lax pair, \begin{align*} Y(z,t)&\mapsto \widetilde{Y}(z,t)=Y^\diamond(z,1/t),\\ A(z,t)&\mapsto \widetilde{A}(z,t)=A^\diamond(z,1/t),\\ B(z,t)&\mapsto \widetilde{B}(z,t)=B^T(z,1/(qt)), \end{align*} and, consequently, \begin{equation*} u(t)\mapsto \widetilde{u}(t)=\frac{1}{u(1/t)},\quad b(t)\mapsto \widetilde{b}(t)=-b(1/(qt)). \end{equation*} Similarly, the symmetry $\mathcal{T}_-$ extends to the following symmetry of the Lax pair, \begin{align*} Y(z,t)&\mapsto \widetilde{Y}(z,t)=r(z)\sigma_3Y^\diamond(z,-1/t),\\ A(z,t)&\mapsto \widetilde{A}(z,t)=-\sigma_3 A^\diamond(z,-1/t)\sigma_3,\\ B(z,t)&\mapsto \widetilde{B}(z,t)=\sigma_3B^T(z,-1/(qt))\sigma_3, \end{align*} where $r(z)$ any function that satisfies $r(qz)=-r(z)$, and, consequently, \begin{equation*} u\mapsto \widetilde{u}(t)=\frac{1}{u(-1/t)},\quad b(t)\mapsto \widetilde{b}(t)=b(-1/(qt)). \end{equation*} \end{lemma} \begin{proof} We only prove the extension of the first symmetry. The other one follows analogously. Let us denote $A(z,t)=\mathcal{A}(z,t,f_0,f_1,f_2,u)$ and $B(z,t)=\mathcal{B}(z,t,b,u)$ and consider the transformation \begin{equation*} \mathcal{T}:Y(z,t)\mapsto \widetilde{Y}(z,t)=Y^\diamond(z,1/t). \end{equation*} This transformation induces the following action on the Lax matrices, \begin{align*} A(z,t)&\mapsto \widetilde{A}(z,t)=A^\diamond(z,1/t),\\ B(z,t)&\mapsto \widetilde{B}(z,t)=B^T(z,1/(qt)). \end{align*} As $(UV)^\diamond=U^\diamond V^\diamond$, it follows that \begin{align*} A^\diamond(z,1/t)&=\mathcal{A}^\diamond(z,1/t,f_0(1/t),f_1(1/t),f_2(1/t),u(1/t))\\ &=\mathcal{A}(z,t,F_0(t),F_1(t),F_2(t),\widetilde{u}(t)), \end{align*} with \begin{equation*} \widetilde{u}(t)=\frac{1}{u(1/t)},\quad F_k(t)=\frac{1}{f_k(1/t)}\quad (k=0,1,2). \end{equation*} Note that this is consistent with the symmetry $\mathcal{T}_+$, so that $\mathcal{T}$ indeed defines an extension of $\mathcal{T}_+$. It remains to be checked that the action of $\mathcal{T}$ of $B(z,t)$ is consistent with its action on $A(z,t)$. That is, we need to ensure that \begin{equation}\label{eq:bconsistent} \mathcal{B}^T(z,1/(qt),b(1/(qt)),u(1/(qt)))=\mathcal{B}(z,t,\widetilde{b}(t),\widetilde{u}(t)), \end{equation} where, in acccordance with equation \eqref{eq:bb}, \begin{equation*} \widetilde{b}(t)=\frac{t(1+a_1F_1(t)(1+a_2F_2(t))}{i\,(qt^2-1)F_2(t)}. \end{equation*} Now, equation \eqref{eq:bconsistent} holds if and only if \begin{equation*} \widetilde{b}(t)\widetilde{u}(t)=-\frac{1}{b(1/(qt)),u(1/(qt))}. \end{equation*} By substituting the expression for $\widetilde{u}(t)$, it follows that this is equivalent to \begin{equation*} \widetilde{b}(t)=-\frac{u(1/t)}{b(1/(qt)),u(1/(qt))}. \end{equation*} By the auxiliary equation \eqref{eq:auxiliary}, we have $b^2=\overline{u}/u$, which simplifies the right-hand side, so that the identify to prove simply reads \begin{equation*} \widetilde{b}(t)=-b(1/(qt)). \end{equation*} The last equality follows by direct computation, using the $q\Pfour$ time-evolution equations. Finally, we note that the transformation $\mathcal{T}$ preserves the compatibility condition of the Lax pair \eqref{eq:comp}, which reaffirms the fact that $(F_0,F_1,F_2)$ is another solution of $q\Pfour$, and further shows that $\widetilde{u}$ solves the corresponding auxiliary equation. \end{proof} Now, consider any symmetric solution of $q\Pfour$ with respect to $\mathcal{T}_-$, then we can choose a corresponding solution $u$ of the auxiliary equation such that the Lax matrices have the symmetries \begin{align*} A(z,t)&=-\sigma_3 A^\diamond(z,-1/t)\sigma_3,\\ B(z,t)&=\sigma_3B^T(z,-1/(qt))\sigma_3. \end{align*} By specialising the first equation to $t=i$, we then find \begin{equation}\label{eq:symmetric_linear} A(z,i)=-\sigma_3 A^\diamond(z,i)\sigma_3. \end{equation} This provides another way to classify the symmetric solutions of $q\Pfour(a)|_{t_0=i}$, by computing all the coefficient matrices $A(z,i)$ that possess the symmetry \eqref{eq:symmetric_linear}. \subsection{The connection matrix} In this section, we introduce the connection matrix associated with the Lax pair and deduce how the symmetries $\mathcal{T}_{\pm}$ act on it. Firstly, we introduce a canonical solution at $z=\infty$ in the following lemma. \begin{lemma}\label{lem:solinf}[Lemma 3.3 in \cite{joshiroffelsenrhp}] For any fixed $t$, there exists a unique $2\times 2$ matrix $\Phi_\infty(z,t)$, meromorphic in $z$ on $\mathbb{C}^*$, such that \begin{align}\label{eq:Phiinfeqiv} \Phi_\infty(qz,t)&=\frac{1}{qa_0^2a_2i} z^{-3}A(z,t)\Phi_\infty(z,t)\begin{pmatrix} t^{-1} & 0\\ 0 & t \end{pmatrix},\\ \Phi_\infty(z,t)&=I+\mathcal{O}\left(z^{-1}\right)\quad (z\rightarrow \infty).\label{eq:Phiinfeqiv2} \end{align} In particular, \begin{equation*} Y_\infty(z,t)=\Phi_\infty(z,t)\begin{pmatrix} r_+(z,t) & 0\\ 0 & r_-(z,t) \end{pmatrix} \end{equation*} defines a solution of the spectral equation \eqref{eq:A}, for any choice of functions $r_{\pm}(z,t)$ satisfying \begin{equation*} \frac{r_{\pm}(qz,t)}{r_{\pm}(z,t)}=qa_0^2a_2iz^{-3} t^{\pm 1}. \end{equation*} \end{lemma} \begin{lemma}\label{lem:solzero}[Lemma 3.2 in \cite{joshiroffelsenrhp}] For any fixed $t$ and $d\in\mathbb{C}^*$, we have \begin{equation}\label{eq:A0iv} A(0)=M_0 \begin{pmatrix} i & 0\\ 0 & -i \end{pmatrix}M_0^{-1}, \textrm{ where } M_0:=d\begin{pmatrix} u & 0\\ 0 & 1 \end{pmatrix}\cdot\begin{pmatrix} i & -i\\ 1 & 1 \end{pmatrix}, \end{equation} and, there exists a unique $2\times 2$ matrix $\Phi_0(z,t)$, meromorphic in $z$ on $\mathbb{C}^*$, such that \begin{align}\label{eq:Phizeroeqiv} \Phi_0(qz,t)&=A(z,t)\Phi_0(z,t)\begin{pmatrix} -i & 0\\ 0 & i \end{pmatrix},\\ \Phi_0(z,t)&=M_0+\mathcal{O}\left(z\right),\ {\rm as}\ z\rightarrow 0.\nonumber \end{align} In particular, it follows that \begin{equation*} Y_0(z,t)=\Phi_0(z,t)r_0(z)^{\sigma_3}, \end{equation*} defines a solution of the spectral equation \eqref{eq:A}, for any choice of meromorphic function $r_0(z)$ satisfying $r_0(qz)=i\,r_0(z)$. \end{lemma} We define the corresponding connection matrix by \begin{equation}\label{eq:assodefiiv} C(z,t)=\Phi_0(z,t)^{-1}\Phi_\infty(z,t), \end{equation} which satisfies, see \cite{joshiroffelsenrhp}, for fixed $t$, \begin{enumerate}[label={{\rm (c.\arabic*)}},ref=c.\arabic*] \item $C(z,t)$ is analytic in $z$ on $\mathbb{C}^*$;\label{item:c1} \item $C(qz,t)=\frac{1}{qa_0^2a_2}z^{-3}\sigma_3C(z,t)t^{-\sigma_3}$;\label{item:c2} \item $|C(z,t)|=c\,\theta_q(a_0z,-a_0z,a_0a_2z,-a_0a_2z,qz,-qz)$, for some $c\neq 0$;\label{item:c3} \item $C(-z,t)=-\sigma_1C(z,t)\sigma_3$.\label{item:c4} \end{enumerate} It follows from the compatibility condition \eqref{eq:comp}, see \cite{joshiroffelsenrhp} for more details, that \begin{align*} \Phi_\infty(z,qt)&=B(z,t)\Phi_\infty(z,t)z^{-\sigma_3},\\ \Phi_0(z,qt)&=B(z,t)\Phi_0(z,t)\sigma_3, \end{align*} which yields the almost trivial time-evolution of the connection matrix, \begin{equation}\label{eq:connection_evolution} C(z,qt)=\sigma_3C(z,t)z^{-\sigma_3}, \end{equation} as well as the time-evolution of $d$ in Lemma \ref{lem:solzero}, \begin{equation}\label{eq:timeevolutiond} \frac{\overline{d}}{d}=\frac{i}{b}. \end{equation} The connection matrix encompasses the monodromy of the Lax pair. In particular, one can in principle uniquely reconstruct the linear system \eqref{eq:A} from the connection matrix by solving an associated Riemann-Hilbert problem. We will now extend the action of the symmetries to the connection matrix. \begin{lemma} The transformation $\mathcal{T}_+$ extends to the following symmetry of the canonical solutions and connection matrix, \begin{align*} \Phi_\infty(z,t)&\mapsto \widetilde{\Phi}_\infty(z,t)=\Phi_\infty^{\diamond}(z,1/t),\\ \Phi_0(z,t)&\mapsto \widetilde{\Phi}_0(z,t)=-i\,\Phi_0^{\diamond}(z,1/t)\sigma_1,\\ C(z,t)&\mapsto \widetilde{C}(z,t)=i\,\sigma_1C^{\diamond}(z,1/t). \end{align*} The transformation $\mathcal{T}_-$ extends to the following symmetry of the canonical solutions and connection matrix, \begin{align*} \Phi_\infty(z,t)&\mapsto \widetilde{\Phi}_\infty(z,t)=\sigma_3\Phi_\infty^{\diamond}(z,-1/t)\sigma_3,\\ \Phi_0(z,t)&\mapsto \widetilde{\Phi}_0(z,t)=i\,\sigma_3\Phi_0^{\diamond}(z,-1/t),\\ C(z,t)&\mapsto \widetilde{C}(z,t)=-i\,C^{\diamond}(z,1/t)\sigma_3. \end{align*} Furthermore, $\mathcal{T}_{\pm}$ act on $d$, defined in Lemma \ref{lem:solzero}, by \begin{equation*} d(t)\mapsto \widetilde{d}(t)=d(\pm 1/t)u(\pm 1/t). \end{equation*} \end{lemma} \begin{proof} We only prove the extension for $\mathcal{T}_-$. The extension of $\mathcal{T}_+$ is proven analogously. We first consider the canonical solution at $z=\infty$. In fact, by Lemma \ref{lem:solinf}, the matrix function $\Phi_\infty(z,t)$ is defined uniquely as the solution to \eqref{eq:Phiinfeqiv} and \eqref{eq:Phiinfeqiv2}. This means that the action of $\mathcal{T}_-$ on $\Phi_\infty(z,t)$ is already fixed by its action on the Lax matrix $A(z,t)$. To determine it explicitly, we first apply $t\mapsto -1/t$ to equation \eqref{eq:Phiinfeqiv}, which yields \begin{equation*} \Phi_\infty(qz,-1/t)=-\frac{1}{qa_0^2a_2i} z^{-3}A(z,-1/t)\Phi_\infty(z,-1/t)\begin{pmatrix} t & 0\\ 0 & t^{-1} \end{pmatrix}. \end{equation*} Next, applying $U\mapsto U^{\diamond}$ to both sides, we obtain \begin{equation*} \Phi_\infty^{\diamond}(qz,-1/t)=-\frac{1}{qa_0^2a_2i} z^{-3}A^{\diamond}(z,-1/t)\Phi_\infty^{\diamond}(z,t)\begin{pmatrix} t^{-1} & 0\\ 0 & t \end{pmatrix}. \end{equation*} Finally, multiplying both sides from the left and right by $\sigma_3$, we obtain \begin{equation*} \widetilde{\Phi}_\infty(qz,t)=\frac{1}{qa_0^2a_2i} z^{-3}\widetilde{A}(z,t)\widetilde{\Phi}_\infty(z,t)\begin{pmatrix} t^{-1} & 0\\ 0 & t \end{pmatrix}, \end{equation*} with \begin{equation*} \widetilde{A}(z,t)=-\sigma_3 A^\diamond(z,-1/t)\sigma_3,\qquad \widetilde{\Phi}_\infty(z,t)=\sigma_3\Phi_\infty^{\diamond}(z,-1/t)\sigma_3. \end{equation*} Note that, furthermore, the normalisation at $z=\infty$ is correct, namely $\widetilde{\Phi}_\infty(z,t)=I+\mathcal{O}(z^{-1})$ as $z\rightarrow \infty$. We conclude, from Lemma \ref{lem:solinf}, that $\mathcal{T}_-$ indeed sends $\Phi_\infty(z,t)$ to $\widetilde{\Phi}_\infty(z,t)$. We next consider the canonical solution at $z=0$. The matrix function $\Phi_0(z)$, see Lemma \ref{lem:solzero}, is only rigidly defined up to the choice of a scalar $d=d(t)$ which satisfies $\overline{d}/d=i/b$, see equation \eqref{eq:timeevolutiond}. So, in order to fix the action of the symmetry $\mathcal{T}_-$ on $\Phi_0(z)$, we first need to fix its action on $d$ in such a way that $\overline{d}/d=i/b$ remains to hold true. Namely, it is required that, if we let $d\mapsto \widetilde{d}$ under $\mathcal{T}_-$, then \begin{equation*} \frac{\widetilde{d}(qt)}{\widetilde{d}(t)}=\frac{i}{\widetilde{b}(t)}=-\frac{i}{b(-1/(qt))}. \end{equation*} We therefore set $\widetilde{d}(t)=d(-1/t)u(-1/t)$, so that indeed \begin{equation*} \frac{\widetilde{d}(qt)}{\widetilde{d}(t)}=\frac{d(-1/(qt))}{d(-1/t)}\frac{u(-1/(qt))}{u(-1/t)}=\frac{b(-1/(qt))}{i}\frac{1}{b(-1/(qt))^2}=-\frac{i}{b(-1/(qt))}. \end{equation*} By essentially repeating the computation for $\Phi_\infty(z)$ above, for $\Phi_0(z)$, one finds that \begin{equation*} \widetilde{\Phi}_0(z,t)=i\,\sigma_3\Phi_0^{\diamond}(z,-1/t), \end{equation*} defines a solution to, see equation \eqref{eq:Phizeroeqiv}, \begin{equation*} \widetilde{\Phi}_0(qz,t)=\widetilde{A}(z,t)\widetilde{\Phi}_0(z,t)\begin{pmatrix} -i & 0\\ 0 & i \end{pmatrix}. \end{equation*} Furthermore, direct evaluation of $ \widetilde{\Phi}_0(z,t)$ at $z=0$ gives \begin{align*} \widetilde{\Phi}_0(0,t)&=i\,\sigma_3\Phi_0^{\diamond}(0,-1/t),\\ &=i\, d(-1/t) \sigma_3 \begin{pmatrix} 1 & 0\\ 0 & u(-1/t) \end{pmatrix}\cdot\begin{pmatrix} 1 & -1\\ i & i \end{pmatrix},\\ &=d(-1/t) \begin{pmatrix} 1 & 0\\ 0 & u(-1/t) \end{pmatrix}\cdot\begin{pmatrix} i & -i\\ 1 & 1 \end{pmatrix}\\ &=\widetilde{d}(t)\begin{pmatrix} \widetilde{u}(t) & 0\\ 0 & 1 \end{pmatrix}\cdot\begin{pmatrix} i & -i\\ 1 & 1 \end{pmatrix}. \end{align*} It follows that $\mathcal{T}_-$ sends $\Phi_0(z,t)$ to $\widetilde{\Phi}_0(z,t)$. Finally, we compute the action of $\mathcal{T}_-$ on the connection matrix. Since $U\mapsto U^{\diamond}$ commutes with inversion, $U\mapsto U^{-1}$, we have \begin{align*} \widetilde{C}(z,t)&=\widetilde{\Phi}_0(z,t)^{-1}\widetilde{\Phi}_\infty(z,t)\\ &=\left[i\,\sigma_3\Phi_0^{\diamond}(z,-1/t)\right]^{-1}\sigma_3\Phi_\infty^{\diamond}(z,-1/t)\sigma_3\\ &=-i\left[\Phi_0^{\diamond}(z,-1/t)\right]^{-1}\Phi_\infty^{\diamond}(z,-1/t)\sigma_3\\ &=-i\, C^{\diamond}(z,-1/t)\sigma_3. \end{align*} This finishes the proof of the lemma. \end{proof} Now, let us take any symmetric solution of $q\Pfour$ with respect to $\mathcal{T}_-$, then we can choose a corresponding solution $u$ of the auxiliary equation, as well as $d$ satisfying \eqref{eq:timeevolutiond}, such that the connection matrix has the symmetry \begin{equation*} C(z,t)=-i\, C^{\diamond}(z,-1/t)\sigma_3. \end{equation*} By specialising this equation to $t=i$, we then find \begin{equation}\label{eq:symmetric_connect} C(z,i)=-i\, C^{\diamond}(z,i)\sigma_3. \end{equation} This provides yet a third way to classify symmetric solutions of $q\Pfour(a)|_{t_0=i}$, by classifying all connection matrices $C(z,i)$ with the symmetry \eqref{eq:symmetric_connect}. \subsection{Monodromy coordinates}\label{subsec:tyurin} In \cite{joshiroffelsenrhp}, we introduced a set of coordinates on the connection matrix, which are invariant under right-multiplication of the connection matrix by diagonal matrices. They are given by \begin{equation*} \rho_k(t)=\pi(C(x_k,t)),\quad (1\leq k\leq 3),\quad (x_1,x_2,x_3)=(a_0^{-1},a_1/q,q^{-1}), \end{equation*} where, for any rank one $2\times2$ matrix $R$, letting $r_1$ and $r_2$ be respectively its first and second row, $\pi(R)\in\mathbb{CP}^1$ is defined by \begin{equation*} r_1=\pi(R)r_2. \end{equation*} This yields three coordinates, $\rho=(\rho_1,\rho_2,\rho_3)\in(\mathbb{CP}^1)^3$, which satisfy the cubic equation, \begin{align}\label{eq:cubic} 0=&+\beta_0\left[\theta_q(t)\rho_1\rho_2\rho_3-\theta_q(-t)\right]\\ &-\beta_1\left[\theta_q(t)\rho_1-\theta_q(-t)\rho_2\rho_3\right]\nonumber\\ &+\beta_2\left[\theta_q(t)\rho_2-\theta_q(-t)\rho_1\rho_3\right]\nonumber\\ &-\beta_3\left[\theta_q(t)\rho_3-\theta_q(-t)\rho_1\rho_2\right].\nonumber \end{align} with coefficients given by \begin{align*} \beta_0&=\theta_q(+a_0,+a_1,+a_2),\\ \beta_1&=\theta_q(+a_0,+a_1,+a_2),\\ \beta_2&=\theta_q(+a_0,+a_1,+a_2),\\ \beta_3&=\theta_q(+a_0,+a_1,+a_2), . \end{align*} When considering solutions defined on a discrete $q$-spiral, i.e. $t\in q^\mathbb{Z} t_0$, the value of $p:=\rho(t_0)$ uniquely determines the corresponding solution $(f_0,f_1,f_2)$ of $q\Pfour(a)$ \cite{joshiroffelsenrhp}. In the following proposition, the action of the symmetries on the monodromy coordinates is determined. \begin{proposition}\label{prop:actioncoordinate} The symmetry $\mathcal{T}_+$ acts on the monodromy coordinates by \begin{equation*} \rho_k(t)\mapsto \widetilde{\rho}_k(t)=-\rho_k(1/t)\quad (k=1,2,3). \end{equation*} The symmetry $\mathcal{T}_-$ acts on the monodromy coordinates by \begin{equation*} \rho_k(t)\mapsto \widetilde{\rho}_k(t)=-\frac{1}{\rho_k(-1/t)}\quad (k=1,2,3). \end{equation*} \end{proposition} \begin{proof} To compute the action of the symmetries on the monodromy coordinates, we need some basic facts about the operator $\pi(\cdot)$. Firstly, given any rank one $2\times 2$ matrix $R$, and invertible $2\times 2$ matrix $N=(n_{ij})$, we have \begin{equation}\label{eq:pi_identities} \pi(RN)=\pi(R),\quad \pi(NR)=\chi_N(\pi(R)), \end{equation} where $\chi_N$ denotes the m\"obius transformation \begin{equation*} \chi_N(z)=\frac{n_{11}z+n_{12}}{n_{21}z+n_{22}}. \end{equation*} In particular, \begin{equation*} \pi(\sigma_1 R)=\chi_{\sigma_1}(\pi(R))=1/\pi(R). \end{equation*} Secondly, it is elementary to check that \begin{equation*} \pi(R^{\diamond})=-1/\pi(R). \end{equation*} We now compute, for transformation $\mathcal{T}_+$, \begin{align*} \widetilde{\rho}_k(t)&=\pi[\widetilde{C}(x_k,t)]=\pi[i\,\sigma_1C^{\diamond}(x_k,1/t)]=\pi[\sigma_1C^{\diamond}(x_k,1/t)]\\ &=1/\pi[C^{\diamond}(x_k,1/t)]=-\pi[C(x_k,1/t)]=-\rho_k(1/t). \end{align*} Similarly, for transformation $\mathcal{T}_-$, we have \begin{align*} \widetilde{\rho}_k(t)&=\pi[\widetilde{C}(x_k,t)]=\pi[-i\,C^{\diamond}(x_k,-1/t)\sigma_3]=\pi[C^{\diamond}(x_k,-1/t)]\\ &=-\frac{1}{\pi[C(x_k,-1/t)]}=-\frac{1}{\rho_k(-1/t)}, \end{align*} and the proposition follows. \end{proof} In the sequel, the following technical lemma will be of importance. Its proof is given in Appendix \ref{app:technical_lemma}. \begin{lemma}\label{lem:forbidden} Let $t_0$, with $t_0^2\notin q^{\mathbb{Z}}$, be inside the domain of a solution $f=(f_0,f_1,f_2)$ of $q\Pfour$. If $f(t)$ takes at least one non-singular value, i.e. a value in $(\mathbb{C}^*)^3$, at a point $t\in q^\mathbb{Z}t_0$, then the coordinates $p=\rho(t_0)$ cannot lie on the curve defined by the intersection of the following cubic equations in $(\mathbb{CP}^1)^3$, \begin{align}\label{eq:forbidden_cubic} 0=&+\beta_0 p_1p_2p_3-\beta_1 p_1+\beta_2 p_2-\beta_3 p_3,\\ 0=&+\beta_0-\beta_1 p_2p_3+\beta_2 p_1p_3-\beta_3 p_1p_2,\nonumber \end{align} with the same coefficients as the cubic \eqref{eq:cubic}. We note that points on this curve solve the cubic equation \eqref{eq:cubic} irrespective of the value of $t$. \end{lemma} Let us now take any solution $f$ of $q\Pfour(a)|_{t_0=i}$ on the $q$-spiral $q^\mathbb{Z}i$. To it, corresponds a unique triplet $p=(p_1,p_2,p_3)$, defined by $p_k:=\rho_k(i)$, $k=1,2,3$, which satisfies the cubic equation \begin{align*} 0=&+\theta_q(+a_0,+a_1,+a_2)\left(p_1p_2p_3-i\right)\\ &-\theta_q(-a_0,+a_1,-a_2)\left(p_1-i\,p_2p_3\right)\\ &+\theta_q(+a_0,-a_1,-a_2)\left(p_2-i\,p_1p_3\right)\\ &-\theta_q(-a_0,-a_1,+a_2)\left(p_3-i\,p_1p_2\right), \end{align*} as follows from the identity $\theta_q(-i)=i\,\theta_q(i)$, and does not lie on the curve defined by by equations \eqref{eq:forbidden_cubic}. Note that $\widetilde{f}=\mathcal{T}_-(f)$ defines another solution on the same domain $q^\mathbb{Z}i$, and its monodromy coordinates, $\widetilde{p}_k:=\widetilde{\rho}_k(i)$, $k=1,2,3$, are related to those of $f$ by \begin{equation*} \widetilde{p}_k=-1/p_k\quad (k=1,2,3). \end{equation*} In particular, $f$ is a symmetric solution if and only if $\widetilde{f}=f$, which in turn is equivalent to \begin{equation}\label{eq:coordinate_symmetric} p_k=-1/p_k\quad (k=1,2,3). \end{equation} In other words, symmetric solutions of $q\Pfour(a)|_{t_0=i}$ correspond to monodromy coordinates $p$ which satisfy the cubic equation above as well as \eqref{eq:coordinate_symmetric}. We proceed to compute four triples $p$ that satisfy these conditions. Firstly, equation \eqref{eq:coordinate_symmetric} has only two solutions in $\mathbb{CP}^1$, given by $\pm i$, and we may thus set $p_k=\epsilon_k i$, $\epsilon_k=\pm 1$, $k=1,2,3$. Substitution of these into the cubic shows that the latter is identically zero if the epsilons satisfy \begin{equation*} \epsilon_1\epsilon_2\epsilon_3=-1, \end{equation*} as in such a case \begin{equation*} p_1p_2p_3-i=p_j-i\,p_kp_l=0\qquad (\{j,k,l\}=\{1,2,3\}). \end{equation*} In particular, this gives us four solutions, \begin{equation}\label{eq:rhopossible} (p_1,p_2,p_3)\in\{(-i,-i,-i), (-i,i,i),(i,-i,i),(i,i,-i)\}, \end{equation} corresponding to the four symmetric solutions in Lemma \ref{lem:symmetric_solutions}. Whilst for generic values of the parameters, these are the only solutions to the cubic, it may so happen for special values of the parameters, that there is a choice of epsilons, with \begin{equation*} \epsilon_1\epsilon_2\epsilon_3=+1, \end{equation*} that also solves the cubic. But in such a case, a direct computation yields \begin{equation*} -\beta_0-\beta_1 \epsilon_1+\beta_2 \epsilon_2-\beta_3\epsilon_3=0, \end{equation*} and thus the point $(p_1,p_2,p_3)$ lies on the curve \eqref{lem:forbidden} and hence does not correspond to a solution of $q\Pfour$. In the next section, Section \ref{sec:solve_linear}, we derive which values of the coordinates in equation \eqref{eq:rhopossible} correspond to which initial conditions \begin{equation*} (f_0(i),f_1(i),f_2(i))\in \{(-1,-1,-1),(-1,1,1),(1,-1,1),(1,1,-1)\}. \end{equation*} We answer this question by explicitly solving the linear problem at the reflection point $t=i$ for each case; see Theorem \ref{thm:solvable}. \section{Symmetric Solutions}\label{s:symm} In this section, we first show that $q\Pfour$ remains invariant under the transformations given in Definition \ref{def:symmetry}. Then, in Section \ref{subsec:continuum}, we show that the transformations formally converge to a transformation of the fourth Painlev\'e equation under the continuum limit. Finally, in Section \ref{sec:classify_symmetric}, we classify solutions, symmetric with respect to $\mathcal{T}_-$. To show that $\mathcal{T}_{\pm}$ leave $q\Pfour$ invariant, note that these transformations map \begin{equation}\label{eq:symmonf} f_k\mapsto 1/F_k,\quad \overline{f}_k \mapsto 1/\underline{F}_k,\quad \underline{f}_k \mapsto 1/\overline{F}_k,\qquad (k=0,1,2). \end{equation} Taking $t\mapsto 1/t$ in $q\Pfour(a)$ we obtain \begin{equation*} \begin{cases}\displaystyle \underline{f}_0=\displaystyle a_0^{-1}a_2^{-1}f_2\,\frac{1+a_1^{-1}f_1(1+a_0^{-1}f_0)}{1+a_0^{-1}f_0(1+a_2^{-1}f_2)}, &\\ \underline{f}_1=\displaystyle a_0^{-1}a_1^{-1}f_0\,\frac{1+a_2^{-1}f_2(1+a_1^{-1}f_1)}{1+a_1^{-1}f_1(1+a_0^{-1}f_0)}, &\\ \underline{f}_2=\displaystyle a_1^{-1}a_2^{-1}f_1\,\frac{1+a_0^{-1}f_0(1+a_2^{-1}f_2)}{1+a_2^{-1}f_2(1+a_1^{-1}f_1)}. & \end{cases} \end{equation*} Using Equations \eqref{eq:symmonf} to replace lower-case variables by upper-case variables, we find another instance of $q\Pfour(a)$, with the same parameters. Recall that $q\Pfour$ has a symmetry group given by $(A_2+A_1)^{(1)}$ (see \cite[\S 4]{joshinobushi2016}). We note here that the transformations $\mathcal{T}_{\pm}$ are not given by the generators of the reflection group $(A_2+A_1)^{(1)}$, but one of them is related to an automorphism of the corresponding Dynkin diagram. To be precise, $\mathcal{T}_{+}$ is equivalent to $r$ in \cite[\S 4.2]{joshinobushi2016}. $\mathcal{T}_{-}$ is obtained from $\mathcal{T}_{+}$ by composition with the transformation that maps $t\mapsto -t$. \subsection{$\mathcal{T}_{\pm}$ and the continuum limit}\label{subsec:continuum} In Kajiwara et al. \cite{kajiwaranoumiyamada2001}, it was shown that, upon setting \begin{align*} f_k(t,\epsilon)&=-\exp\left({-\epsilon g_k(s)+\mathcal{O}(\epsilon^2)}\right)\quad (k=0,1,2),\\ t^2&=\exp\left(-\epsilon s\right),\\ a_k&=\exp\left(-\tfrac{1}{2}\epsilon^2 \alpha_k\right)\quad (k=0,1,2),\\ q&=\exp\left(-\tfrac{1}{2}\epsilon^2\right), \end{align*} and taking the limit $\epsilon\rightarrow 0$, $q\Pfour$ formally converges to the symmetric fourth Painlev\'e equation \begin{equation*} \ S\Pfour(\alpha):\begin{cases} \displaystyle g_0'=\alpha_0+g_0(g_1-g_2), &\\ \displaystyle g_1'=\alpha_1+g_1(g_2-g_0), &\\ \displaystyle g_2'=\alpha_2+g_2(g_0-g_1), &\\ \end{cases} \end{equation*} where \begin{equation*} g_0+g_1+g_2=s,\quad \alpha_0+\alpha_1+\alpha_2=1, \end{equation*} and $g'=g'(s)$ denotes differentiation with respect to $s$. Note that the independent $t$ variable is given by \begin{equation*} t=t(s;\epsilon)=\pm i\exp\left(-\epsilon s\right), \end{equation*} and satisfies \begin{equation*} t(-s;\epsilon)=c/t(s;\epsilon),\quad c=\pm 1. \end{equation*} Thus, for $k=0,1,2$, \begin{align*} F_k(t,\epsilon)&=1/f_k(c/t,\epsilon)\\ &=-\exp\left({+\epsilon \,g_k(-s)+\mathcal{O}(\epsilon^2)}\right)\\ &=-\exp\left({-\epsilon \,G_k(s)+\mathcal{O}(\epsilon^2)}\right), \end{align*} where \begin{equation*} G_k(s)=-g_k(-s)\quad (k=0,1,2). \end{equation*} Therefore, in the continuum limit as $\epsilon\rightarrow 0$, the symmetries of $q\Pfour$ in Definition \ref{def:symmetry}, formally converge to the following symmetry of $S\Pfour$, \begin{equation*} s\rightarrow -s,\quad g_k\rightarrow G_k=-g_k\quad (k=0,1,2). \end{equation*} \subsection{Symmetric Solutions}\label{sec:classify_symmetric} In this section, we restrict our attention to solutions with a domain given by a discrete $q$-spiral, $T=q^{\mathbb{Z}}t_0$. For the symmetric transformations given in Definition \ref{def:symmetry}, we require that $t\rightarrow c/t$, $c=\pm 1$, leaves this spiral invariant. This gives us four possible values for $t_0$, modulo $q^\mathbb{Z}$, determined by \begin{equation*} t_0=c/t_0,\quad c=\pm 1, \end{equation*} namely $t_0=1,i,-1,-i$. The formulation of the $q$-monodromy surface described in Section \ref{s:mono} requires the non-resonance conditions \begin{equation}\label{eq:conditionnonresonant} t_0^2,\pm a_0,\pm a_1,\pm a_2\notin q^\mathbb{Z}. \end{equation} This leads to two possible values, $t_0=\pm i$. As $q\Pfour(a)$ is invariant under $t\mapsto -t$, we restrict ourselves to considering $t_0=i$. For any solution $f=f(q^m i)$, $m\in\mathbb{Z}$, of $q\Pfour(a)|_{t_0=i}$, the symmetry \eqref{eq:symmetry1} shows that \begin{equation}\label{eq:symmetry_discrete} F_k(q^m i)=\frac{1}{f_k(q^{-m}i)},\quad (m\in\mathbb{Z},k=0,1,2), \end{equation} defines another solution of $q\Pfour(a)|_{t_0=i}$. \begin{definition} We call a solution $f=f(q^m i)$, $m\in\mathbb{Z}$ of $q\Pfour(a)|_{t_0=i}$ {\em symmetric} if it is invariant under the transformation \eqref{eq:symmetry_discrete}, i.e. if \begin{equation}\label{eq:sym_condition} f_k(q^m i)=\frac{1}{f_k(q^{-m}i)},\quad (m\in\mathbb{Z},k=0,1,2). \end{equation} \end{definition} Consider a symmetric solution $f=f(q^m i)$, $m\in\mathbb{Z}$. Specialising equation \eqref{eq:sym_condition} to $m=0$, shows that $v_k:=f_k(i)\in \mathbb{CP}^1$ satisfies $v_k=1/v_k$, for $k=0,1,2$. The only solutions to this equation are given by $v_k=\pm 1$. Thus $f$ is regular at $t=i$ and \begin{equation}\label{eq:initial_conditions_constraint} f_k(i)^2=1,\quad (k=0,1,2). \end{equation} Combining this observation with \begin{equation*} f_0(i)f_1(i)f_2(i)=-1, \end{equation*} we are led to four possible initial conditions at $m=0$, \begin{equation}\label{eq:symmic} (f_0(i),f_1(i),f_2(i))\in \{(-1,1,1),(1,-1,1),(1,1,-1),(-1,-1,-1)\}. \end{equation} Conversely, any of these initial conditions yields a symmetric solution of $q\Pfour(a)|_{t_0=i}$. To see this, recall that equation \eqref{eq:symmetry_discrete} yields, in general, another solution $F$ of $q\Pfour(a)|_{t_0=i}$. Due to \eqref{eq:initial_conditions_constraint}, $f$ and $F$ satisfy the same initial conditions at $m=0$. Therefore, they are the same solution and thus $f$ is a symmetric solution. This proves the following lemma. \begin{lemma}\label{lem:symmetric_solutions} $q\Pfour(a)|_{t_0=i}$ has precisely four symmetric solutions, which are all regular at $t=i$, each specified by its initial values at $m=0$, with the four possible initial conditions given by \begin{equation*} (f_0(i),f_1(i),f_2(i))=\begin{cases} (-1,1,1),\\ (1,-1,1),\\ (1,1,-1),\\ (-1,-1,-1). \end{cases} \end{equation*} \end{lemma} See Figure \ref{fig:numerics} for a plot of one the symmetric solutions. \begin{figure}[t] \centering \includegraphics[width=\textwidth]{symsol.png} \caption{Numerical display of the symmetric solution in Lemma \ref{lem:symmetric_solutions} with initial conditions $(f_0(i),f_1(i),f_2(i))=(-1,-1,-1)$. The values of $q^{-\frac{2}{3} m}f_k(q^m i)$, $k=0,1,2$, are displayed in respectively blue, orange and green, with $m$ ranging from -70 to 70 on the horizontal axis. The values of the parameters are $a_0=q^{\frac{9}{23}}$, $a_1=q^{\frac{8}{23}}$ and $a_2=q^{\frac{6}{23}}$, with $q=0.802$.} \label{fig:numerics} \end{figure} \begin{remark} It is instructive to compare this with the symmetric solutions of $S\Pfour(\alpha)$. In accordance with the definition of symmetric solutions of $\Pfour$, see Kaneko \cite{kaneko2005}, these are solutions $g$ of $S\Pfour(\alpha)$ that satisfy \begin{equation*} g_k(s)=-g_k(-s)\quad (k=0,1,2). \end{equation*} $S\Pfour(\alpha)$ has precisely four symmetric solutions. Three non-analytic at $s=0$, with Laurent series in a domain around $s=0$ given by \[ {\rm Case\ I:}\quad \begin{cases} g_0(s)&=-\alpha_0 s+\mathcal{O}\left(s^3\right),\\ g_1(s)&=+s^{-1}+\mathcal{O}\left(s\right),\\ g_2(s)&=-s^{-1}+\mathcal{O}\left(s\right), \end{cases} \] \[ {\rm Case\ II:}\quad \begin{cases} g_0(s)&=-s^{-1}+\mathcal{O}\left(s\right),\\ g_1(s)&=-\alpha_1 s+\mathcal{O}\left(s^3\right),\\ g_2(s)&=+s^{-1}+\mathcal{O}\left(s\right), \end{cases} \] \[ {\rm Case\ III:}\quad \begin{cases} g_0(s)&=+s^{-1}+\mathcal{O}\left(s\right),\\ g_1(s)&=-s^{-1}+\mathcal{O}\left(s\right),\\ g_2(s)&=-\alpha_2 s+\mathcal{O}\left(s^3\right), \end{cases} \] and one analytic at $s=0$, specified by \begin{equation*} {\rm Case\ IV:}\quad g_k(s)=\alpha_k s+\mathcal{O}\left(s^3\right)\quad (s\rightarrow 0), \end{equation*} for $k=0,1,2$. \end{remark}
{ "redpajama_set_name": "RedPajamaArXiv" }
1,315
Cells made by fusing a normal human muscle cell with a muscle cell from a person with Duchenne muscular dystrophy — a rare but fatal form of muscular dystrophy — were able to significantly improve muscle function when implanted into the muscles of a mouse model of the disease. The findings are reported by researchers from the University of Illinois at Chicago in Stem Cell Review and Reports. These cells, called "chimeric cells," are made by combining a normal donor cell containing a functioning copy of the gene for dystrophin — a structural muscle protein lacking in people with Duchenne muscular dystrophy — with a cell from a recipient with the disease. In a January 2018 paper in Stem Cell Reviews and Reports, the researchers used mouse donor and recipient cells to make chimeric cells that boosted dystrophin levels by 37 percent and improved muscle function when implanted into the muscles of a mouse model of Duchenne muscular dystrophy. The new cells had both donor and recipient characteristics and interacted with their surroundings like normal cells. The chimeric cells remained viable and produced dystrophin for 30 days. Now, the research group, led by Maria Siemionow MD, PhD, professor of orthopedic surgery in the UIC College of Medicine, report similar findings using human cells implanted in a mouse model of Duchenne muscular dystrophy. Siemionow: "Our results point to the long-term survival of these cells and helps establish the use of chimeric cells as a novel promising potential therapy for patients with Duchenne muscular dystrophy." Her team is looking forward to clinical trials in humans in the near future. People with the disease don't have the gene for dystrophin, a structural protein that helps keep muscle cells intact. Symptom onset is in early childhood, usually between ages 3 and 5. The disorder causes muscle weakness and loss of motor function and ultimately results in respiratory or cardiac failure and death. With advances in treatment, many with Duchenne muscular dystrophy live into their teens and 20s, and some into their 30s, but there is currently no cure for the disease. Promising treatments include gene therapy and stem cell therapy, but each has drawbacks. Gene therapy relies on delivering good copies of missing or dysfunctional genes to cells via viruses. Not only can cells become immune to viral infection, rendering the therapy ineffective, but there also is no guarantee that viruses will only infect the intended cells. Stem cell therapy, where cells that contain the dystrophin gene are implanted into a recipient, requires that the recipient take immunosuppressive drugs to prevent rejection. "This is not conventional stem cell therapy. We are restoring dystrophin in such a way that the recipient won't need to take anti-rejection therapy because the implanted chimeric cells can evade the recipient's immune system. In traditional stem cell therapy, the implanted cells are 100 percent 'other' and anti-rejection medicine is needed in order to prevent the host immune system from destroying those foreign cells." Maria Siemionow MD, PhD, Department of Surgery, Poznan University of Medical Sciences, Poznan, Poland; Professor of Orthopedic Surgery, University of Illinois at Chicago, Chicago, USA, and lead author of the paper. In contrast, chimeric cells are 50 percent 'self' — with many biochemical and genetic features of the recipient — and as such can trick the recipient's immune system into ignoring them. "The chimeric cells are just enough like the recipient's own cells that their immune system gives them a 'pass' so to speak," Siemionow explains. If such cells were to be used to treat a patient with Duchenne muscular dystrophy, then normal muscle cells from the recipient's father or close relative would be fused with muscle cells from the patient. Researchers fused muscle cells from patients with Duchenne muscular dystrophy with muscle cells from normal, healthy donors. In the lab, the chimeric cells were seen to express dystrophin. When the cells were implanted into the leg muscles of a mouse model of Duchenne muscular dystrophy, dystrophin levels rose approximately 20 percent of muscle fibers affected by the implanted cells at 90 days post-implantation, "enough to produce a significant improvement in muscle function." Krzysztof Siemionow MD, Assistant Professor of Orthopaedic Surgery and Neurosurgery, Chief of Spine Surgery, University of Illinois at Chicago, and a co-author on the paper. Duchenne Muscular Dystrophy (DMD) is a progressive and lethal disease caused by mutations of the dystrophin gene. Currently no cure exists. Stem cell therapies targeting DMD are challenged by limited engraftment and rejection despite the use of immunosuppression. There is an urgent need to introduce new stem cell-based therapies that exhibit low allogenic profiles and improved cell engraftment. In this proof-of-concept study, we develop and test a new human stem cell-based approach to increase engraftment, limit rejection, and restore dystrophin expression in the mdx/scid mouse model of DMD. We introduce two Dystrophin Expressing Chimeric (DEC) cell lines created by ex vivo fusion of human myoblasts (MB) derived from two normal donors (MBN1/MBN2), and normal and DMD donors (MBN/MBDMD). The efficacy of fusion was confirmed by flow cytometry and confocal microscopy based on donor cell fluorescent labeling (PKH26/PKH67). In vitro, DEC displayed phenotype and genotype of donor parent cells, expressed dystrophin, and maintained proliferation and myogenic differentiation. In vivo, local delivery of both DEC lines (0.5 × 106) restored dystrophin expression (17.27%±8.05—MBN1/MBN2 and 23.79%±3.82—MBN/MBDMD) which correlated with significant improvement of muscle force, contraction and tolerance to fatigue at 90 days after DEC transplant to the gastrocnemius muscles (GM) of dystrophin-deficient mdx/scid mice. This study establishes DEC as a potential therapy for DMD and other types of muscular dystrophies. Authors: Erzsebet Szilagyi, Krzysztof Siemionow MD, Enza Marchese, Ahlke Heydemann and Joanna Cwykiel of the University of Illinois at Chicago, and Jesus Garcia of Saint Louis University, Missouri, are co-authors of the paper. This work was supported by the UIC Chancellor's Innovation Fund Proof of Concept Award. Krzysztof Siemionow MD is CEO and shareholder of Dystrogen Therapeutics SA, the company holds a license for DEC Therapy. Maria Siemionow MD, PhD is CMO and shareholder of Dystrogen Therapeutics SA, the company holds a license for DEC Therapy. The authors declare a potential conflict of interest. M.S. is the inventor on the patent application filed by University of Illinois at Chicago related to chimeric cell therapy for Duchenne muscular dystrophy (WO/2016/201182). The authors JC, AH, JG, EM and ES have no financial conflict of interest. University of Illinois at Chicago has approved the Nepotism Disclosure and Management Plan for MS and KS. The authors JC, AH, JG, EM and ES do not have any non-financial conflict of interest. Fusion of myoblast cells from a normal donor and a DMD-affected donor, produce results suggesting fusion induces restoration of function of the dystrophin–glycoprotein complex (DGC). Image credit: University of Illinois at Chicago.
{ "redpajama_set_name": "RedPajamaC4" }
5,419
Author: Trevor Lynch January 27, 2023 Trevor Lynch 4 comments I am reviewing two films together because they don't merit stand-alone reviews, but I want to say something about them anyway. It is just a coincidence that they both star Brad Pitt. First, the good news. If you like Guy Ritchie's comic crime capers like Snatch or Lock, Stock, & Two Smoking Barrels or The Gentlemen, you will love David Leitch's Bullet Train. Guy Ritchie basically took Quentin Tarantino's formula of eccentric, wise-cracking criminals, non-linear narratives, and blood and guts, then purged it of all auteur pretensions. (more…) December 30, 2022 Trevor Lynch 13 comments Death on the Nile (1978 & 2022) There's a reason why Agatha Christie is the world's best-selling author. Her whodunnits are cleverly crafted, well-written, and highly entertaining. I also find them wholesomely Eurocentric, which is problematic these days. Death on the Nile (1937) is one of her best novels. A shot rings out onboard a luxurious Nile steamer. It is clearly a case of foul play. But the two prime suspects have airtight alibis. Moreover, practically everybody else on the ship had means, motive, and opportunity to do the deed. Even Hercule Poirot's famous gray cells are baffled . . . for time. (more…) December 8, 2022 Trevor Lynch 24 comments The Talented Miss Tarr Todd Field's Tár is the story of the rise — or perhaps I should say "social climb" — and fall of Lydia Tár, a pioneering ethnomusicologist, conductor, and the first female Music Director of the Berlin Philharmonic, who is brilliantly played by Cate Blanchett. Shot on location in New York and Berlin, Tár very effectively conjures up the world of contemporary classical music, from the concert halls and conservatories to the journalistic latrine flies. (more…) May 12, 2022 Trevor Lynch 1 comment Trevor Lynch's Classics of Right-Wing Cinema Edited by Greg Johnson San Francisco: Counter-Currents, 2022 There are three formats for Trevor Lynch's Classics of Right-Wing Cinema: (more…) January 3, 2022 Trevor Lynch 13 comments Larry and Andy Wachowski's The Matrix (1999) is a science fiction classic. The setting is a devastated Earth in the far future. The premise is that humanity has been enslaved by artificial intelligences. Human beings spend our lives in what are essentially coffins while mechanical vampires drain our energy. We don't know it, because we are asleep, dreaming that we are in a radically different world. This is the Matrix. Today we would call it a multiplayer online game. Like many dystopias, The Matrix is actually too optimistic. The Wachowski brothers thought the human race would have to be forced into the pods. (more…) December 24, 2021 Trevor Lynch 7 comments House of Gucci is a highly entertaining combination of comedy, tragedy, and farce, tracing the decline of the Gucci fashion empire from an Italian family business to a global capitalist brand. House of Gucci would have been the best Martin Scorsese movie in years — if it hadn't been directed by Ridley Scott. It has all the Scorsese touches: lots of Italians (albeit Italian-Italians rather than Italian-Americans), a plush running time, studies of characters who are seldom admirable but always interesting, (more…) You have to give the Left credit. They never take a day off. The eye of Sauron never blinks. They are frenzied and relentless in their attempts to overthrow our civilization. They softened us up for a long time, rotting away our character and identity by promoting vice, cynicism, and nihilism — all while playing the victim. Now that we are too weak to resist and too deracinated to care, they have launched a ferocious campaign of iconoclasm against our forefathers' heroes: Christopher Columbus, Thomas Jefferson, Robert E. Lee, etc. (more…) November 29, 2021 Trevor Lynch 3 comments Howard Hawks' Red River (1948) is one of the greatest Westerns. Red River has it all: charismatic performances by John Wayne and Montgomery Clift, a solid ensemble cast to back them up, a beautifully economical script, dramatic black-and- white cinematography, and a surprisingly good score from Dimitri Tiomkin, who had always struck me as a hack. All of these elements are masterfully drawn together by Hawks. His sense of pacing and visual drama never fails. He grabs your attention with stark contrasts between dark and light, vast landscapes and closeups. He'll sweep you up in action, then stop you dead in wonder. (more…) October 27, 2021 Trevor Lynch 9 comments Denis Villeneuve's Dune, Part I Denis Villeneuve's Dune, Part I is now in theatres. I can't recommend it. It isn't terrible. It is merely mediocre. I found it dull to the eyes, grating to the ears, and a drag on my patience. Villeneuve spends 156 minutes and only gets halfway through the novel. David Lynch told the whole story in 137 minutes. Of course audiences are willing to sit through long movies if they are really good: Peter Jackson's The Lord of the Rings trilogy, for instance. But this film isn't in that league. (more…) No Time to Die is an excellent Bond film. It belongs in the company of Casino Royale and Skyfall and quite self-consciously reaches for the heights of On Her Majesty's Secret Service, which is arguably the best Bond film ever. I was especially looking forward to No Time to Die because — although it is very much a minority opinion — my favorite Bond actor is Daniel Craig. (more…) October 4, 2021 Trevor Lynch 5 comments The Last Emperor When I first saw Bernardo Bertolucci's The Last Emperor (1987), it struck me as a remake of Doctor Zhivago. Both narratives begin in glamorous and archaic empires that fall to Communist revolutions. Of course, that could just be due to the fact that the Chinese Revolution was something of a remake of the Russian Revolution. But there are parallels specific to the two films, both of which depict Communism as recapitulating the old forms of despotism but as vulgar and brutal farces, stripped of all refinement. (more…) September 27, 2021 Trevor Lynch 7 comments David Lean's epic anti-Communist romance Doctor Zhivago (1965) is a great and serious work of art. Doctor Zhivago was initially panned by the critics — probably not because it is a bad film, but because it was very bad for Communism. Nevertheless, it was immensely popular. It is still one of the highest-grossing movies of all time, adjusted for inflation. It also won five Oscars — for Best Adapted Screenplay (Robert Bolt), Best Original Score (Maurice Jarre), Best Cinematography (Freddie Young), Best Art Direction, and Best Costume Design. (more…) 1 2 3 … 18 Next›
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
7,786
Le est une société de production indépendante japonaise, fondée en 1954 par les actrices Keiko Kishi, Yoshiko Kuga et Ineko Arima, et qui vise à garantir la liberté de travail des acteurs face aux contraintes des grands studios. Films produits 1955 : de Miyoji Ieki 1957 : de Masaki Kobayashi 1959-1961 : Trilogie de Masaki Kobayashi : 1959 : 1959 : 1961 : 1961 : de Minoru Shibuya 1962 : de Masaki Kobayashi 1962 : de Kinuyo Tanaka 1962 : de Susumu Hani 1962 : de Masashige Narusawa 1964 : de Masahiro Shinoda 1964 : de Masaki Kobayashi 1964 : de Gian Vittorio Baldi, Michel Brault, Jean Rouch et Hiroshi Teshigahara Notes et références Liens externes Société de production de cinéma ayant son siège au Japon Société de production et de distribution audiovisuelle fondée en 1954
{ "redpajama_set_name": "RedPajamaWikipedia" }
2,760
\section{Introduction} Consider the time-dependent Maxwell equation for the electric field $\boldsymbol E$ in a homogeneous medium \begin{equation}\label{ef} \partial^2_{t}\boldsymbol E(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E (\boldsymbol{x},t))= \boldsymbol F(\boldsymbol x, t),\quad \boldsymbol{x}\in \mathbb R^3,~ t>0, \end{equation} which is supplemented by the homogeneous initial conditions \begin{align}\label{ic} \boldsymbol E(\boldsymbol{x},0) = \partial_t \boldsymbol E(\boldsymbol{x},0) = 0, \quad \boldsymbol x \in \mathbb R^3. \end{align} We assume that the electrodynamic field is excited by a moving point source radiating over a finite time period. Specifically, the source function $\boldsymbol F$ is assumed to be given in the following form \begin{align*}\label{st} \boldsymbol F(\boldsymbol x, t)= \boldsymbol J(\boldsymbol x - \boldsymbol a(t))\,g(t), \end{align*} where $\boldsymbol J: \mathbb R^3\rightarrow \mathbb R^3$ is the source profile function, $g: \mathbb R_+\rightarrow \mathbb R$ the temporal function, and $\boldsymbol a:\mathbb R_+\rightarrow\mathbb R^3$ is the orbit function of the moving source. Hence the source term is assumed to be a product of the spatially moving source function $\boldsymbol J(\boldsymbol x - \boldsymbol a(t))$ and the temporal function $g(t)$. Physically, the spatially moving source function can be thought as an approximation of a pulsed signal which is transmitted by a moving antenna, whereas the temporal function is usually used to model the evolution of source magnitude in time. Throughout, we make the following assumptions: \begin{enumerate} \item The profile function $\boldsymbol J(\boldsymbol x)$ is compactly supported in $ B_{\hat R}: = \{\boldsymbol x : |\boldsymbol x| < \hat{R}\}$ for some $\hat{R}>0$; \item The source radiates only over a finite time period $[0, T_0]$ for some $T_0 > 0$, i.e., $g(t) = 0$ for $t\geq T_0$ and $t\leq 0$; \item The source moves in a bounded domain, i.e., $|\boldsymbol a(t)|< R_1$ for all $t\in \mathbb R_+$ and some $R_1>0$. \end{enumerate} These assumptions imply that the source term $\boldsymbol F$ is supported in $B_R\times(0,T_0)$ for $R>\hat R + R_1$. Unless otherwise stated, we always take $T:=T_0+\hat R + R_1 +R$ and set $\Gamma_R:=\{\boldsymbol x\in\mathbb R^3: |\boldsymbol x|=R\}$. Denote by $\boldsymbol\nu$ the unit normal vector on $\Gamma_R$ and let $\Gamma\subset\Gamma_R$ be an open subset with a positive Lebesgue measure. We study the inverse moving source problems of determining the profile function $\boldsymbol J(\boldsymbol x)$ and the orbit function $\boldsymbol a(t)$ from boundary measurements of the tangential trace of the electric field over a finite time interval, $\boldsymbol E(\boldsymbol x, t)\times \boldsymbol \nu|_{\Gamma \times [0,T]}$. Specifically, we consider the following two inverse problems: \begin{enumerate} \item[(i)] IP1. Assume that $\boldsymbol a(t)$ is known, the inverse problem is to determine $\boldsymbol J$ from the measurement $\boldsymbol E(\boldsymbol x, t)\times\boldsymbol\nu, \boldsymbol x\in\Gamma, t\in (0, T)$. \item[(ii)] IP2. Assume that $\boldsymbol J$ is a known vector function, the inverse problem is to determine $\boldsymbol a(t), t\in(0,T_0)$ from the measurement $\boldsymbol E(\boldsymbol x,t)\times\boldsymbol\nu, \boldsymbol x\in\Gamma, t\in (0, T)$. \end{enumerate} The IP1 is a linear inverse problem, whereas the IP2 is a nonlinear inverse problem. The time-dependent inverse source problems have attracted considerable attention \cite{ACY-EJAM04, Li2015, RS1989, Ya1998, Li2005, K1992, OPS}. However, the inverse moving source problems are rarely studied for the wave propagation. We refer to \cite{GF15} on the inverse moving source problems by using the time-reversal method and to \cite{PD89,PD91} for the inverse problems of moving obstacles. numerical methods can be found in \cite{NIO12-IP,WGLL} to identify the orbit of a moving acoustic point source. To the best of our knowledge, the uniqueness result is not available for the inverse moving source problem, which is the focuse of this paper. Recently, a Fourier method was proposed for solving inverse source problems for the time-dependent Lam\'e system \cite{BHKY} and the Maxwell system \cite{ZHLL}, where the source term is assumed to be the product of a spatial function and a temporal function. These work were motivated by the studies on the uniqueness and increasing stability in recovering compactly supported source terms with multiple frequency data \cite{BLLT2015,BLT2010,BLZ2017,LY,LY-JMAA,ZL-AA,ZL-AA}. It is known that there is no uniqueness for the inverse source problems with a single frequency data due to the existence of non-radiating sources \cite{AM-IP06}. In \cite{BHKY,ZHLL}, the idea was to use the Fourier transform and combine with Huygens' principle to reduce the time-dependent inverse problem into an inverse problem in the Fourier domain with multi-frequency data. The idea was further extended in \cite{HuKian} to handle the time-dependent source problems in elastodynamics where the uniqueness and stability were studied. In this paper, we use partial boundary measurements of dynamical Dirichlet data over a finite time interval to recover either the source profile function or the orbit function. In Sections \ref{sec:3} and \ref{sec:4.2}, we show that the ideas of \cite{BHKY,ZHLL} and \cite{HuKian} can be used to recover the source profile function as well as the moving trajectory which lies on a flat surface. For general moving orbit functions, we apply the moment theory to deduce the uniqueness under a priori assumptions on the path of the moving source, see Section \ref{subsec:4.1}. When the compactly supported temporal function shrinks to a Dirac distribution, we show in Section \ref{sec:5} that the data measured at four discrete receivers on a sphere is sufficient to uniquely determine the impulsive time point and to the source location. This work is a nontrivial extension of the Fourier approach from recovering the spatial sources to recovering the orbit functions. The latter is nonlinear and more difficult to handle. The rest of the paper is organized as follows. In Section \ref{sec:2}, we present some preliminary results concerning the regularity and well-posedness of the direct problem. Sections \ref{sec:3} and \ref{sec:4} are devoted to the uniqueness of IP1 and IP2, respectively. In Section \ref{sec:5}, we show the uniqueness to recover a Dirac distribution of the source function by using a finite number of receivers. \section{The direct problem}\label{sec:2} In addition to those assumptions given in the previous section, we give some additional conditions on the source functions: \[ \boldsymbol J\in H^2(\mathbb R^3), \quad \mbox{div}\,\boldsymbol J=0~ \text{ in }~ \mathbb R^3,\quad g\in C^1(\mathbb R_+), \quad \boldsymbol a\in C^1(\mathbb R_+). \] It follows from \cite{AM-IP06} that any source function can be decomposed into a sum of radiating and non-radiating parts. The non-radiating part cannot be determined and gives rise to the non-uniqueness issue. By the divergence-free condition of $\boldsymbol J$, we eliminate non-radiating sources in order to ensure the uniqueness of the inverse problem. Since the source term $\boldsymbol J$ has a compact support in $B_R\times(0,T)$, we may show the following result by Huygens' principle. \begin{lemm}\label{2.1} It holds that $\boldsymbol E (\boldsymbol x, t) = 0$ for all $\boldsymbol x \in B_R, t > T$. \end{lemm} The proof of Lemma \ref{2.1} is similar to that of Lemma 2.1 in \cite{ZHLL}. It states that the electric field $\boldsymbol E$ over $B_R$ must vanish after time $T$. This property of the electric field plays an important role in the mathematical justification of the Fourier approach. Noting $\nabla \cdot \boldsymbol J = 0$, taking the divergence on both sides of \eqref{ef}, and using the initial conditions \eqref{ic}, we have \[ \partial^2_t ( \nabla\cdot \boldsymbol E(\boldsymbol x, t) ) =0, \quad \boldsymbol x \in \mathbb R^3, ~ t>0 \] and \[ \nabla \cdot \boldsymbol E(\boldsymbol x, 0) = \partial_t ( \nabla \cdot \boldsymbol E(\boldsymbol x, 0))= 0. \] Therefore, $\nabla\cdot \boldsymbol E(\boldsymbol x, t) = 0$ for all $\boldsymbol x\in \mathbb R^3$ and $t>0$. In view of the identify $\nabla \times \nabla\times = - \Delta + \nabla\nabla$, we obtain from \eqref{ef}--\eqref{ic} that \begin{align}\label{we} \begin{cases} \partial^2_t\boldsymbol E(\boldsymbol{x},t) - \Delta \boldsymbol E(\boldsymbol{x},t)=\boldsymbol J(\boldsymbol x - \boldsymbol a(t))g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E(\boldsymbol{x},0) = \partial_t \boldsymbol E(\boldsymbol{x},0) = 0, &\quad \boldsymbol{x}\in \mathbb R^3. \end{cases} \end{align} We briefly introduce some notation on functional spaces with the time variable. Given the Banach space $X$ with norm $||\cdot||_X$, the space $C([0,T];X)$ consists of all continuous functions $f: [0,T]\rightarrow X$ with the norm \[ ||f||_{C([0,T];X)}:=\max_{t\in[0,T]} ||f(t,\cdot)||_X. \] The Sobolev space $W^{m,p}(0,T;X),$ where both $m$ and $p$ are positive integers such that $1\leq m < \infty, 1\leq p < \infty$, comprises all functions $f\in L^2(0,T;X)$ such that $\partial_t^k f, k=0,1,2,\cdots,m$ exist in the weak sense and belong to $L^p(0,T;X)$. The norm of $W^{m,p}(0,T;X)$ is given by \[ ||f||_{W^{m,p}(0,T;X)}:=\left(\int_0^T \sum_{k=0}^m ||\partial_t^k f(t, \cdot)||_X^p\right)^{1/p}. \] Denote $H^m = W^{m,2}$. Now we state the regularity of the solution for the initial value problem \eqref{we}. The proof follows similar arguments to the proof of Lemma 2.3 in \cite{ZHLL} by taking $p=2$. \begin{lemm}\label{re} The initial value problem \eqref{we} admits a unique solution $$\boldsymbol E \in C(0, T; H^{3}(\mathbb R^3))^3 \cap H^\tau(0,T; H^{2-\alpha+1}(\mathbb R^3))^3,\quad \alpha=1, 2, 3, $$ which satisfies \begin{align*}\label{regu} \|\boldsymbol E\|_{C(0, T; H^{3}(\mathbb R^3))^3} + \|\boldsymbol E\|_{H^\tau(0,T; H^{2-\tau+1}(\mathbb R^3))^3} \leq C\|g\|_{L^2(0, T)} \|\boldsymbol J\|_{H^2(\mathbb R^3)^3}, \end{align*} where $C$ is a positive constant depending on $R$. \end{lemm} Applying the Sobolev imbedding theorem, it follows from Lemma \ref{re} that \[ \boldsymbol E\in C([0,T];H^2(\mathbb R^3))^3\cap C^2([0,T];L^2(\mathbb R^3))^3. \] Denote by $\mathbb{I}$ the 3-by-3 identity matrix and by $H$ the Heaviside step function. Recall the Green tensor $\mathbb G(\boldsymbol{x}, t)$ to the Maxwell system (see e.g., \cite{ZHLL}) \begin{align*} \mathbb G(\boldsymbol{x}, t) = \frac{1}{4\pi |\boldsymbol x|} \delta'(|\boldsymbol x| - t) \mathbb I - \nabla \nabla^\top \Big( \frac{1}{4\pi |\boldsymbol x|} H( |\boldsymbol x|-t) \Big), \end{align*} which satisfies \begin{align*} &\partial^2_t \mathbb{G}(\boldsymbol{x},t) + \nabla \times( \nabla \times \mathbb{G}(\boldsymbol{x},t) )= - \delta(t)\delta(\boldsymbol x)\,\mathbb{I} \end{align*} with the homogeneous initial conditions: \[ \mathbb{G}(\boldsymbol{x},0) = \partial_t \mathbb{G}(\boldsymbol{x},0)=0, \quad |\boldsymbol x| \neq 0. \] Taking the Fourier transform of $\mathbb G(\boldsymbol{x}, t)$ with respect to the time variable yields \begin{align}\label{Grenn's tensor} \hat{\mathbb G} (\boldsymbol x, \kappa) = \Big( g(\boldsymbol x, \kappa)\mathbb I+\frac{1}{\kappa^2}\nabla \nabla^\top g(\boldsymbol x, \kappa) \Big), \end{align} which is known as the Green tensor to the reduced time-harmonic Maxwell system with the wavenumber $\kappa$. Here $g$ is the fundamental solution of the three-dimensional Helmholtz equation and is given by \[ g(\boldsymbol x, \kappa) = \frac{1}{4\pi}\frac{e^{{\rm i}\kappa|\boldsymbol x|}}{|\boldsymbol x|}. \] It is clearly to verify that $\hat{\mathbb G} (\boldsymbol x, \kappa)$ satisfies \[ \nabla\times(\nabla\times \hat{\mathbb G})-\kappa^2\hat{\mathbb G}= \delta(\boldsymbol x) \mathbb I, \quad\boldsymbol x\in\mathbb R^3,\; |\boldsymbol x|\neq 0. \] \section{Determination of the source profile function}\label{sec:3} In this section we consider \text{IP1}. Below we state the uniqueness result. The idea of the proof is to adopt the Fourier approach of \cite{ZHLL} to the case of a moving point source. \begin{theo}\label{us} Suppose that the orbit function $\boldsymbol a$ is given and that $\int_0^{T_0}g(t){\rm d}t\neq 0$. Then the source profile function $\boldsymbol J(\boldsymbol x)$ can be uniquely determined by the partial data set $\{\boldsymbol{E}(\boldsymbol{x},t)\times \boldsymbol\nu: \boldsymbol x\in \Gamma, t\in (0, T)\}$. \end{theo} \begin{proof} Assume that there are two functions $\boldsymbol J_1$ and $\boldsymbol J_2$ which satisfy \begin{align*} \begin{cases} \partial^2_{t}\boldsymbol E_1(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_1 (\boldsymbol{x},t))= \boldsymbol J_1(\boldsymbol x - \boldsymbol a(t))\,g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_1(\boldsymbol{x},0) = \partial_t \boldsymbol E_1(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3, \end{cases} \end{align*} and \begin{align*} \begin{cases} \partial^2_{t}\boldsymbol E_2(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_2 (\boldsymbol{x},t))= \boldsymbol J_2(\boldsymbol x - \boldsymbol a(t))\,g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_2(\boldsymbol{x},0) = \partial_t \boldsymbol E_2(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3. \end{cases} \end{align*} It suffices to show $\boldsymbol J_1(\boldsymbol x) = \boldsymbol J_2(\boldsymbol x)$ in $B_R$ if $\boldsymbol{E}_1(\boldsymbol{x},t)\times \boldsymbol\nu = \boldsymbol{E}_2(\boldsymbol{x},t)\times \boldsymbol\nu$ for all $x\in \Gamma, t \in (0, T)$. Let $\boldsymbol E = \boldsymbol{E}_1 - \boldsymbol{E}_2$ and \begin{align*} \boldsymbol f(\boldsymbol x, t)= \boldsymbol J_1(\boldsymbol x - \boldsymbol a(t))\,g(t) - \boldsymbol J_2(\boldsymbol x - \boldsymbol a(t))\,g(t). \end{align*} Then we have \begin{align*} \begin{cases} \partial^2_{t}\boldsymbol E(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E (\boldsymbol{x},t))= \boldsymbol f(\boldsymbol x, t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E(\boldsymbol{x},0) = \partial_t \boldsymbol E(\boldsymbol{x},0) = 0, & \quad \boldsymbol x \in \mathbb R^3, \\ \boldsymbol{E}(\boldsymbol{x}, t) \times \boldsymbol\nu = 0 , & \quad \boldsymbol x \in \Gamma, ~ t>0. \end{cases} \end{align*} Denote by $\hat{\boldsymbol E}(\boldsymbol{x}, \kappa)$ the Fourier transform of $\boldsymbol E(\boldsymbol x, t)$ with respect to the time $t$, i.e., \begin{align}\label{fourier} \hat{\boldsymbol E}(\boldsymbol{x}, \kappa) = \int_{\mathbb R} \boldsymbol{E}(\boldsymbol x, t)e^{-{\rm i}\kappa t}{\rm d}t, \quad \boldsymbol x\in B_R, ~ \kappa \in \mathbb R^{+}. \end{align} By Lemma \ref{2.1}, the improper integral on the right hand side of (\ref{fourier}) makes sense and it holds that \begin{align*} \hat{\boldsymbol E}(\boldsymbol{x}, \kappa) = \int_0^T \boldsymbol{E}(\boldsymbol x, t)e^{-{\rm i}\kappa t}{\rm d}t<\infty,\quad\boldsymbol x\in B_R,~\kappa>0. \end{align*} Hence \[ \hat{\boldsymbol E}(\boldsymbol{x}, \kappa)\times \boldsymbol\nu = 0, \quad\forall \boldsymbol x\in\Gamma, ~\kappa \in \mathbb R^{+}. \] Taking the Fourier transform of \eqref{ef} with respect to the time $t$, we obtain \begin{align}\label{eq:1} \nabla\times(\nabla\times \hat{\boldsymbol E})-\kappa^2\hat{\boldsymbol E}=\int_0^T\boldsymbol f(\boldsymbol x, t)e^{-{\rm i}\kappa t}{\rm d}t, \quad\boldsymbol x\in \mathbb R^3. \end{align} Since ${\rm supp}(\boldsymbol J) \subset B_{\hat{R}}$ and $|\boldsymbol a(t)|< R_1$, it is clear to note that $\hat{\boldsymbol E}$ is analytic with respect to $\boldsymbol x$ in a neighbourhood of $\Gamma_R\supseteq \Gamma$ and $\hat{\boldsymbol E}$ satisfies the Silver--M\"{u}ller radiation condition: \begin{equation*} \lim_{r\to \infty}((\nabla\times\hat{\boldsymbol E}) \times \boldsymbol x - {\rm i}\kappa r\hat{\boldsymbol E}) = 0, \quad r=|\boldsymbol x|, \end{equation*} for any fixed frequency $\kappa>0$. In fact, the radiation condition of $\hat{\boldsymbol E}$ can be straightforwardly derived from the expression of $\boldsymbol E$ in terms of the Green tensor $\mathbb G(\boldsymbol{x}, t)$ together with the radiation condition of $\hat{\mathbb G} (\boldsymbol x\,; \kappa)$. The details may be found in \cite{ZHLL}. Hence, we have $\hat{\boldsymbol E}(\boldsymbol{x}, \kappa)\times \boldsymbol\nu = 0$ on the whole boundary $\Gamma_R$. It follows from \eqref{Grenn's tensor} that \begin{align*}\label{eq:5} \hat{\boldsymbol E} (\boldsymbol x, \kappa) = \int_{\mathbb R^3} \hat{\mathbb G} (\boldsymbol x - \boldsymbol y, \kappa) \int_0^T\boldsymbol f(\boldsymbol y, t)e^{-{\rm i}\kappa t}{\rm d}t\,{\rm d}\boldsymbol y. \end{align*} Let $\hat{\boldsymbol E}\times\boldsymbol\nu$ and $\hat{\boldsymbol H}\times\boldsymbol\nu$ be the tangential trace of the electric and the magnetic fields in the frequency domain, respectively. In the Fourier domain, there exists a capacity operator $T: H^{-1/2}({\rm div}, \Gamma_R)\rightarrow H^{-1/2}({\rm div}, \Gamma_R)$ such that the following transparent boundary condition can be imposed on $\Gamma_R$ (see e.g., \cite{N-00}): \begin{equation}\label{mtbc1} \hat{\boldsymbol H}\times\boldsymbol\nu=T(\hat{\boldsymbol E}\times\boldsymbol\nu)\quad\text{on}~\Gamma_R. \end{equation} This implies that $\hat{\boldsymbol H}\times\boldsymbol\nu$ is uniquely determined by $\hat{\boldsymbol E}\times\boldsymbol\nu$ on $\Gamma_R$, provided $\hat{\boldsymbol H}$ and $\hat{\boldsymbol E}$ are radiating solutions. The transparent boundary condition \eqref{mtbc1} can be equivalently written as \begin{equation}\label{mtbc2} (\nabla\times\hat{\boldsymbol E})\times\boldsymbol\nu= {\rm i}\kappa T (\hat{\boldsymbol E}\times\boldsymbol\nu)\quad\text{on}~\Gamma_R. \end{equation} Next we introduce the functions $\hat{\boldsymbol{E}}^{\rm inc}$ and $\hat{\boldsymbol{H}}^{\rm inc}$ by \begin{equation}\label{mpw} \hat{\boldsymbol{E}}^{\rm inc}(x) = \boldsymbol{p}e^{{\rm i}\kappa\boldsymbol{x} \cdot \boldsymbol{d}}\quad\text{and}\quad \hat{\boldsymbol{H}}^{\rm inc}(x) = \boldsymbol{q}e^{{\rm i}\kappa\boldsymbol{x} \cdot \boldsymbol{d}}, \end{equation} where $\boldsymbol{d} \in \mathbb S^2$ is a unit vector and $\boldsymbol p, \boldsymbol q$ are two unit polarization vectors satisfying $\boldsymbol p\cdot\boldsymbol d =0, \boldsymbol q = \boldsymbol p \times \boldsymbol d $. It is easy to verify that $\hat{\boldsymbol{E}}^{\rm inc}$ and $\hat{\boldsymbol{H}}^{\rm inc}$ satisfy the homogeneous time-harmonic Maxwell equations in $\mathbb R^3$: \begin{equation}\label{epw} \nabla \times (\nabla \times \hat{\boldsymbol{E}}^{\rm inc}) - \kappa^2 \hat{\boldsymbol{E}}^{\rm inc} = 0 \end{equation} and \begin{equation}\label{hpw} \nabla \times (\nabla \times \hat{\boldsymbol{H}}^{\rm inc}) - \kappa^2 \hat{\boldsymbol{H}}^{\rm inc} = 0. \end{equation} Let $\boldsymbol\xi = -\kappa \boldsymbol d$ with $|\boldsymbol\xi|=\kappa\in (0, \infty)$. We have from \eqref{mpw} that $\hat{\boldsymbol{E}}^{\rm inc} =\boldsymbol{p} e^{-{\rm i}\boldsymbol\xi\cdot \boldsymbol x}$ and $\hat{\boldsymbol{H}}^{\rm inc} = \boldsymbol{q} e^{-{\rm i}\boldsymbol\xi\cdot \boldsymbol x}$. Multiplying both sides of \eqref{eq:1} by $\hat{\boldsymbol{E}}^{\rm inc}$ and using the integration by parts over $B_R$ and \eqref{epw}, we have from $\hat{\boldsymbol{E}}(\boldsymbol{x},\kappa) \times \boldsymbol\nu = 0$ on $\Gamma_R$ and the transparent boundary condition \eqref{mtbc2} that \begin{align}\label{eq:2} &\int_{B_R}\int_0^T \boldsymbol f(\boldsymbol x, t) e^{-{\rm i}\kappa t} \cdot \hat{\boldsymbol{E}}^{\rm inc} {\rm d}t\;{\rm d}\boldsymbol x \notag\\ = & \int_{B_R} (\nabla\times(\nabla\times \hat{\boldsymbol E})-\kappa^2\hat{\boldsymbol E}) \cdot \hat{\boldsymbol{E}}^{\rm inc}{\rm d}\boldsymbol x\notag\\ =&\int_{\Gamma_R} \nu\times (\nabla\times \hat{\boldsymbol{E}} )\cdot \hat{\boldsymbol{E}}^{\rm inc} -\nu\times (\nabla\times \hat{\boldsymbol{E}}^{\rm inc})\cdot \hat{\boldsymbol{E}} {\rm d}s\notag\\ =& -\int_{\Gamma_R} \left({\rm i}\kappa T(\hat{\boldsymbol{E}} \times \boldsymbol\nu) \cdot \hat{\boldsymbol{E}}^{\rm inc}+ (\hat{\boldsymbol{E}} \times \boldsymbol\nu)\cdot(\nabla \times \hat{\boldsymbol{E}}^{\rm inc})\right){\rm d}s \notag\\ =& 0. \end{align} Hence from \eqref{eq:2} we obtain \[ \int_{B_R}\int_0^T \boldsymbol{p}e^{- {\rm i}\boldsymbol{\xi} \cdot \boldsymbol{x}} \cdot g(t)\boldsymbol J_1(\boldsymbol x -\boldsymbol a(t))e^{-{\rm i}\kappa t}{\rm d}t{\rm d}\boldsymbol x = \int_{B_R}\int_0^T \boldsymbol{p}e^{- {\rm i}\boldsymbol{\xi} \cdot \boldsymbol{x}} \cdot g(t)\boldsymbol J_2(\boldsymbol x - \boldsymbol a(t))e^{-{\rm i}\kappa t}{\rm d}t{\rm d}\boldsymbol x. \] By Fubini's theorem, it is easy to obtain \begin{align}\label{eq:p} \boldsymbol{p} \cdot \hat{\boldsymbol J}_1(\kappa \boldsymbol d) \int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol d \cdot \boldsymbol a(t)}e^{-{\rm i}\kappa t}{\rm d}t = \boldsymbol{p} \cdot \hat{\boldsymbol J}_2(\kappa \boldsymbol d) \int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol d \cdot \boldsymbol a(t)}e^{-{\rm i}\kappa t}{\rm d}t. \end{align} Taking the limit $\kappa\rightarrow 0^+$ yields \[ \lim_{\kappa \rightarrow 0}\int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol d \cdot \boldsymbol a(t)}e^{-{\rm i}\kappa t}{\rm d}t = \int_0^T g(t){\rm d}t > 0. \] Hence, there exist a small positive constant $\delta$ such that for all $\kappa \in (0,\delta)$, \[ \int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol d \cdot \boldsymbol a(t)}e^{-{\rm i}\kappa t}{\rm d}t\neq 0, \] which together with (\ref{eq:p}) implies that \begin{align*} \boldsymbol{p} \cdot \hat{\boldsymbol J}_1(\kappa \boldsymbol d) = \boldsymbol{p} \cdot \hat{\boldsymbol J}_2(\kappa \boldsymbol d). \end{align*} Similarly, we may deduce from \eqref{hpw} and the integration by parts that \begin{align*} \boldsymbol{q} \cdot \hat{\boldsymbol J}_1(\kappa \boldsymbol d) = \boldsymbol{q} \cdot \hat{\boldsymbol J}_2(\kappa \boldsymbol d) \quad\mbox{for all}\; \boldsymbol d \in \mathbb S^2,\, \kappa \in (0,\delta). \end{align*} On the other hand, since $\boldsymbol J_i, ~i=1, 2$ is compactly supported in $B_{\hat{R}}$ and $\nabla_{\boldsymbol x} \cdot \boldsymbol J_i = 0$ in $B_{\hat{R}}$, we have \begin{align*} \int_{\mathbb R^3} \boldsymbol d e^{-{\rm i}\kappa \boldsymbol x \cdot \boldsymbol d} \cdot \boldsymbol J_i(\boldsymbol x) {\rm d} \boldsymbol x & =- \frac{1}{{\rm i}\kappa}\int_{B_{\hat{R}}}\nabla e^{-{\rm i}\kappa \boldsymbol x \cdot \boldsymbol d} \cdot \boldsymbol J_i(\boldsymbol x) {\rm d} \boldsymbol x \\ &= \frac{1}{{\rm i}\kappa}\int_{B_{\hat{R}}} e^{-{\rm i}\kappa \boldsymbol x \cdot \boldsymbol d} \nabla \cdot \boldsymbol J_i (\boldsymbol x) {\rm d}\boldsymbol x = 0. \end{align*} This implies that $\boldsymbol d \cdot \hat{\boldsymbol J}_i(\kappa \boldsymbol d) = 0.$ Since $\boldsymbol p, \boldsymbol q, \boldsymbol d$ are orthonormal vectors, they form an orthonormal basis in $\mathbb R^3$. It follows from the previous identities that \begin{align*} \hat{\boldsymbol J}_1(\kappa \boldsymbol d) &= \boldsymbol{p} \cdot \hat{\boldsymbol{J}}_1(\kappa\boldsymbol d)\boldsymbol{p} + \boldsymbol{q}\cdot \hat{\boldsymbol{J}}_1(\kappa\boldsymbol d)\boldsymbol{q} + \boldsymbol{d} \cdot \hat{\boldsymbol{J}}_1(\kappa\boldsymbol d) \boldsymbol{d}\\ & =\boldsymbol{p} \cdot \hat{\boldsymbol{J}}_2(\kappa\boldsymbol d)\boldsymbol{p} + \boldsymbol{q}\cdot \hat{\boldsymbol{J}}_2(\kappa\boldsymbol d)\boldsymbol{q} + \boldsymbol{d} \cdot \hat{\boldsymbol{J}}_2(\kappa\boldsymbol d) \boldsymbol{d}\\ & = \hat{\boldsymbol J}_2(\kappa \boldsymbol d) \end{align*} for all $\boldsymbol d \in \mathbb S^2$ and $\kappa \in (0,\delta)$. Noting that $\hat{\boldsymbol J}_i$, $i=1,2$, are analytical functions in $\mathbb R^3$, we obtain $\hat{\boldsymbol J}_1(\boldsymbol \xi) = \hat{\boldsymbol J}_2(\boldsymbol \xi)$ for all $\boldsymbol \xi \in \mathbb R^3$, which completes the proof by taking the inverse Fourier transform. \end{proof} \section{ Determination of moving orbit function}\label{sec:4} In this section, we assume that the source profile function $\boldsymbol J$ is given. To prove the uniqueness for \text{IP2}, we consider two cases: Case (i): The orbit $\{\boldsymbol a(t): t\in[0,T_0]\}\subset B_{R_1}\cap \mathbb R^3$ is a curve lying in three dimensions; Case (ii): $\{\boldsymbol a(t): t\in[0,T_0]\}\subset B_{R_1}\cap\Pi$, where $\Pi$ is a plane in three dimensions. The second case means that the path of the moving source lies on a bounded flat surface in three dimensions. Cases (i) and (ii) will be discussed separately in the subsequent two subsections. \subsection{Uniqueness to IP2 in case (i)}\label{subsec:4.1} Before stating the uniqueness result, we need an auxillary lemma. \begin{lemm}\label{moment} Let $f_1, f_2, g\in C^1[0, L]$ be functions such that \[ f^{\prime}_1>0, f^{\prime}_2>0, g>0 \mbox{ on } [0,L];\quad f_1(0)=f_2(0). \] In addition, suppose that \begin{align}\label{eq:f} \int_{0}^{L} f_1^n( s)g(s){\rm d} s = \int_{0}^{L} f_2^n( s)g(s){\rm d} s \end{align} for all integers $n = 0, 1, 2 \cdots$. Then it holds that $f_1 = f_2$ on $[0, L]$. \end{lemm} \begin{proof} Without loss of generality we assume that $f_1(0)=f_2(0)=0$. Otherwise, we may consider the functions $s\rightarrow f_j(s)-f_j(0)$ in place of $f_j$. To prove Lemma \ref{moment}, we first show $f_1(L)=f_2(L)$ and then apply the moment theory to get $f_1\equiv f_2$. Assume without loss of generality that $f_1(L)>f_2(L)$. Write $f_1(L) = c$ and ${\rm sup}_{x\in(0,L)}g(x) = M$. Since $f^{\prime}_1(s)>0$ and $f_1(0)=0$, we have $c>0$. Therefore, there exists sufficiently small positive numbers $\epsilon > 0$ and $\delta_1, \delta_2>0$ such that \begin{align*} f_1(s)\geq c - \delta_1,\; f_2(s)\leq c - 2\delta_1,\; g(s)\geq \delta_2\quad &\mbox{for all}\quad s \in [L - 2\epsilon, L-\epsilon],\\ f_1(s)>f_2(s)\quad&\mbox{for all}\quad s \in [L - 2\epsilon, L]. \end{align*} Using the above relations, we deduce from (\ref{eq:f}) that \begin{align*} 0&=\int_{0}^{L} f_1^n( s)g(s) - f_1^n( s)g(s){\rm d} s\\ &= \int_{L-\epsilon}^{L} f_1^n( s)g(s) - f_2^n( s)g(s){\rm d} s + \int_{L-2\epsilon}^{L-\epsilon} f_1^n( s)g(s) - f_2^n( s)g(s){\rm d} s \\ &\quad + \int_{0}^{L-2\epsilon}f_1^n( s)g(s) - f_2^n( s)g(s){\rm d} s\\ &\geq \int_{L-2\epsilon}^{L-\epsilon} f_1^n( s)g(s) - f_2^n( s)g(s){\rm d} s - \int_{0}^{L-2\epsilon}f_2^n( s)g(s){\rm d} s\\ &\geq \epsilon \delta_2\Big[(c - \delta_1)^n - (c - 2\delta_1)^n\Big] - (L - 2\epsilon)M(c - 2\delta_1)^n\\ &\geq (c - \delta_1)^n \Big[\epsilon \delta_2 - (\epsilon \delta_2 + (L - 2\epsilon)M)\Big(\frac{c - 2\delta_1}{c - \delta_1}\Big)^n\Big], \end{align*} which means that \[ (c - \delta_1)^n \Big[\epsilon \delta_2 - (\epsilon \delta_2 + (L - 2\epsilon)M)\Big(\frac{c - 2\delta_1}{c - \delta_1}\Big)^n\Big] \leq 0 \] for all integers $n = 0, 1, 2 \cdots$. However, since $\frac{c - 2\delta_1}{c - \delta_1}<1$, there exists a sufficiently large integer $N>0$ such that \[ \epsilon \delta_2 - (\epsilon \delta_2 + (L - 2\epsilon)M)\Big(\frac{c - 2\delta_1}{c - \delta_1}\Big)^N >0. \] Then we obtain \[ (c - \delta_1)^N \Big[\epsilon \delta_2 - (\epsilon \delta_2 + (L - 2\epsilon)M)\Big(\frac{c - 2\delta_1}{c - \delta_1}\Big)^N\Big] >0, \] which is a contradiction. Therefore, we obtain $f_1(L)=f_2(L)$. Denote $c = f_1(0) = f_2(0)$ and $d = f_1(L) = f_2(L)$. Since $f_j$ is monotonically increasing, the relation $\tau = f_j(s)$ implies that $s=f_j^{-1}(\tau)$ for all $s\in[0, L]$ and $\tau\in[c,d]$. Using the change of variables, we get \[ \int_{0}^{L} f_j^n(s)g(s){\rm d} s = \int_{c}^{d}\tau^n g\circ(f_j^{-1}(\tau)) (f_j^{-1})^{\prime}(\tau){\rm d}\tau,\quad j=1,2. \] Hence, it follows from (\ref{eq:f}) that \begin{align}\label{*} \int_{c}^{d}\tau^n {\rm d}\mu = \int_{c}^{d}\tau^n{\rm d}\nu, \end{align} where $\mu$ and $\nu$ are two Lebesgue measures such that \begin{align*} {\rm d}\mu = g\circ(f_1^{-1}(\tau)) (f_1^{-1})^{\prime}(\tau){\rm d}\tau,\\ {\rm d}\nu = g\circ(f_2^{-1}(\tau)) (f_2^{-1})^{\prime}(\tau) {\rm d}\tau. \end{align*} By the Stone--Weierstrass theorem, it is easy to note from \eqref{*} that ${\rm d}\mu = {\rm d}\nu$, which means \begin{align}\label{ws} g\circ(f_1^{-1}(\tau)) (f_1^{-1})^{\prime}(\tau) = g\circ(f_2^{-1}(\tau)) (f_2^{-1})^{\prime}(\tau)\quad \text{for all}~\tau \in [c, d]. \end{align} Introduce two functions \[ F_1(\tau) = \int^{f_1^{-1}(\tau)}_0 g(s){\rm d}s,\quad F_2(\tau) = \int^{f_2^{-1}(\tau)}_0 g(s){\rm d}s. \] Hence, from \eqref{ws} we deduce $F_1^{\prime}(\tau) = F_2^{\prime}(\tau)$ for $\tau\in [c,d]$. Moreover, since $f_1^{-1}(c) = f_2^{-1}(c)=0$, we have $F_1(c) = F_2(c)=0$ and then $F_1(\tau) = F_2(\tau)$ for $\tau\in [c,d]$, i.e., \begin{align}\label{ws1} \int^{f_1^{-1}(\tau)}_0 g(s){\rm d}s = \int^{f_2^{-1}(\tau)}_0 g(s){\rm d}s. \end{align} From \eqref{ws1}, it is easy to know that $f_1^{-1}(\tau) = f_2^{-1}(\tau)$ for all $\tau \in [c, d]$. Otherwise, suppose $f_1^{-1}(\tau_0) \neq f_2^{-1}(\tau_0)$ at some point $\tau_0 \in [c, d]$. Since $g(s)>0$ for all $s\in(0,L)$, we obtain that \[ \int^{f_1^{-1}(\tau_0)}_0 g(s){\rm d}s \neq \int^{f_2^{-1}(\tau_0)}_0 g(s){\rm d}s, \] which is a contradiction. Consequently, we obtain $f_1^{-1}=f_2^{-1}$ and thus $f_1(s) = f_2(s)$ for all $s\in [0,L]$. The proof is complete. \end{proof} Our uniqueness result for the determination of $\boldsymbol a$ is stated as follows. \begin{theo}\label{ut} Assume that $\boldsymbol a(0)=\boldsymbol O\in \mathbb R^3$ is located at the origin and that each component $a_j, j=1,2,3$ of $\boldsymbol a$ satisfies $|a^{\prime}_i(t)|<1$ for $t \in [0, T_0]$. Then the function $\boldsymbol a(t), t \in [0, T_0]$ can be uniquely determined by the data set $\{\boldsymbol{E}(\boldsymbol{x},t)\times \boldsymbol\nu: \boldsymbol x\in \Gamma, t\in (0, T)\}$. \end{theo} \begin{proof} Assume that there are two orbit functions $\boldsymbol a$ and $\boldsymbol b$ such that \begin{align*} \begin{cases} \partial^2_{t}\boldsymbol E_1(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_1 (\boldsymbol{x},t))= \boldsymbol J(x - \boldsymbol a(t))g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_1(\boldsymbol{x},0) = \partial_t \boldsymbol E_1(\boldsymbol{x},0) = 0, & \quad \boldsymbol x \in \mathbb R^3, \end{cases} \end{align*} and \begin{align*} \begin{cases} \partial^2_{t}\boldsymbol E_2(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_2 (\boldsymbol{x},t))= \boldsymbol J(x - \boldsymbol b(t))g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_2(\boldsymbol{x},0) = \partial_t \boldsymbol E_2(\boldsymbol{x},0) = 0, & \quad \boldsymbol x \in \mathbb R^3. \end{cases} \end{align*} Here we assume that $\bs b(0)=\bs O$ and $|b'_j(t)|<1$ for $t\in[0,t_0]$ and $j=1,2,3$. We need to show $\boldsymbol a(t) = \boldsymbol b(t)$ in $(0,T_0)$ if $\boldsymbol{E}_1(\boldsymbol{x},t)\times \boldsymbol\nu (\boldsymbol{x}) = \boldsymbol{E}_2(\boldsymbol{x},t)\times \boldsymbol\nu$ for $x\in \Gamma, t \in (0, T)$. For each unit vector $\boldsymbol{d}$, we can choose two unit polarization vectors $\boldsymbol p, \boldsymbol q$ such that $ \boldsymbol p\cdot\boldsymbol d=0, \boldsymbol q = \boldsymbol p \times \boldsymbol d $. Letting $\boldsymbol E = \boldsymbol E_1 - \boldsymbol E_2$ and following similar arguments as those of Theorem \ref{us}, we obtain \begin{align}\label{p} \boldsymbol p \cdot \hat{\boldsymbol J}(\kappa \boldsymbol d)\int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol{d}\cdot \boldsymbol a(t)}e^{-{\rm i}\kappa t}{\rm d}t = \boldsymbol p \cdot \hat{\boldsymbol J}(\kappa \boldsymbol d)\int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol{d}\cdot \boldsymbol b(t)}e^{-{\rm i}\kappa t}{\rm d}t, \end{align} \begin{align}\label{q} \boldsymbol q \cdot \hat{\boldsymbol J}(\kappa \boldsymbol d)\int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol{d}\cdot \boldsymbol a(t)}e^{-{\rm i}\kappa t}{\rm d}t = \boldsymbol q \cdot \hat{\boldsymbol J}(\kappa \boldsymbol d)\int_0^T g(t)e^{-{\rm i}\kappa \boldsymbol{d}\cdot \boldsymbol b(t)}e^{-{\rm i}\kappa t}{\rm d}t, \end{align} and \begin{align*}\label{d} \boldsymbol d\cdot \hat{\boldsymbol J}(\kappa \boldsymbol d) = 0, \end{align*} which means \[ \hat{\boldsymbol J}(\kappa \boldsymbol d) = \boldsymbol p \cdot \hat{\boldsymbol J}(\kappa \boldsymbol d) \boldsymbol p + \boldsymbol q \cdot \hat{\boldsymbol J}(\kappa \boldsymbol d) \boldsymbol q. \] Therefore, since $\boldsymbol J\neq 0$, for each unit vector $\boldsymbol d$ there exists a sequence $\{\kappa_j\}_{j=1}^{+\infty}$ such that $\lim_{j\rightarrow 0}\kappa_j = 0$ and for each $\kappa_j$, either $\boldsymbol p \cdot \hat{\boldsymbol J}(\kappa_j \boldsymbol d) \neq 0$ or $\boldsymbol q \cdot \hat{\boldsymbol J}(\kappa_j \boldsymbol d)\neq 0$. Hence from \eqref{p}--\eqref{q} we have \begin{align}\label{identity1} \int_0^T e^{-{\rm i}\kappa_j \boldsymbol{d}\cdot \boldsymbol a(t)}e^{-{\rm i}\kappa_j t}g(t){\rm d}t = \int_0^T e^{-{\rm i}\kappa_j \boldsymbol{d}\cdot \boldsymbol b(t)}e^{-{\rm i}\kappa_j t}g(t){\rm d}t, \quad j=1,2, \cdots. \end{align} Expanding $e^{-{\rm i}\kappa_j \boldsymbol{d}\cdot \boldsymbol a(t)}e^{-{\rm i}\kappa_j t}$ and $e^{-{\rm i}\kappa_j \boldsymbol{d}\cdot \boldsymbol a(t)}e^{-{\rm i}\kappa_j t}$ into power series with respect to $\kappa_j$, we write \eqref{identity1} as \begin{align}\label{ps} \sum_{n=0}^{\infty}\frac{\alpha_n}{n!}\kappa_j^n = \sum_{n=0}^{\infty}\frac{\beta_n}{n!}\kappa_j^n, \end{align} where \begin{align*} \alpha_n := \int_0^T (\boldsymbol{d}\cdot \boldsymbol a(t) + t)^n g(t){\rm d}t, \quad \beta_n:= \int_0^T (\boldsymbol{d}\cdot \boldsymbol b(t) + t)^n g(t){\rm d}t, \quad n = 1,2 \cdots. \end{align*} In view of the fact that $\mbox{supp}(g)\subset[0, T_0]$, we get \begin{align*} \alpha_n = \int_0^{T_0} (\boldsymbol{d}\cdot \boldsymbol a(t) + t)^n g(t){\rm d}t, \quad \beta_n= \int_0^{T_0} (\boldsymbol{d}\cdot \boldsymbol b(t) + t)^n g(t){\rm d}t, \quad n = 1,2 \cdots . \end{align*} Since \eqref{ps} holds for all $\kappa_j$ and $\lim_{j\rightarrow \infty}\kappa_j = 0$, it is easy to conclude that $\alpha_n = \beta_n$ for $n = 0,1,2 \cdots.$ Choosing $\boldsymbol d = (1,0,0)$, we have \[ ( a_1(t) + t)^{\prime} = 1 + a^{\prime}_1(t)>0,\quad ( b_1(t) + t)^{\prime} = 1 + b^{\prime}_1(t)>0, \quad a_1(0)=b_1(0). \] It follows from $\alpha_n = \beta_n$ and Lemma \ref{moment} that $a_1(t) = b_1(t)$ for $t\in [0, T_0]$. Similarly letting $\boldsymbol d = (0,1,0)$ and $\boldsymbol d = (0,0,1)$ we have $a_2(t) = b_2(t)$ and $a_3(t) = b_3(t)$ for $t\in [0, T_0]$, respectively, which proves that $\boldsymbol a(t) = \boldsymbol b(t)$ for $t \in [0,T_0]$. \end{proof} \begin{rema} In Theorem \ref{ut}, it states that we can only recover the function $\boldsymbol a(t)$ over the finite time period $[0, T_0]$ because the moving source radiates in this time period, i.e., $\mbox{supp}(g)=[0,T_0]$. The information of $\boldsymbol a(t)$ for $t>T_0$ cannot be retrieved. The monotonicity assumption $a_j'\geq 0$ for $j=1,2,3$ can be replaced by the following condition: there exist three linearly independent unit directions $\boldsymbol d_j, j=1,2,3$ such that \[ |\boldsymbol d_j\cdot \boldsymbol a' (t)|<1, \quad t\in[0,T_0],\;j=1,2,3. \] Note that this condition can always be fulfilled if the source moves along a straight line with the speed less than one. \end{rema} \subsection{Uniqueness to IP2 in case (ii)}\label{sec:4.2} For simplicity of notation, let $ \tilde{\boldsymbol x} = (x_1, x_2, 0)$ for $\boldsymbol x=(x_1,x_2,x_3)$ and $\mathbb R^2 = \{\boldsymbol x \in \mathbb R^3: x_3 = 0\}$. Let $\tilde{\bs a}(t)\in \mathbb R^2$ for all $t\in[0,T_0]$. In this subsection, we assume that \[ \bs F(\boldsymbol x, t)=\bs J (\tilde{\bs x}-\tilde{\bs a}(t))\,h(x_3)\,g(t),\quad \bs x\in \mathbb R^3,\, t\in \mathbb R_+, \] where $\bs J(\bs x)=(J_1(\tilde{\bs x}), J_2(\tilde{\bs x}),0)\in H^2 (\mathbb R^2)^3$ depends only on $\tilde{\bs x}$ and $h \in H^2(\mathbb R)$, ${\rm supp} (h) \subset (-\hat{R}, \hat{R})\sqrt{2}/2$. Moreover, we assume that $h$ does not vanish identically and \[ \mbox{supp}(\bs J)\subset\{\tilde{\bs x}\in \mathbb R^2: |\tilde{\bs x}|<\hat{R}\sqrt{2}/2\},\quad \nabla_{\tilde{\bs x}} \bs J(\tilde{\bs x})=0. \] The temporal function $g$ is defined the same as in the previous sections. The above assumptions imply that we still have $\mbox{supp}(\bs F)\subset B_{\hat{R}}\times[0,T_0]$ and $\mbox{div}\,\bs F=0$ in $\mathbb R^3$. We consider the inhomogeneous Maxwell system \begin{align}\label{mep3} \begin{cases} \partial^2_{t}\boldsymbol E(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E (\boldsymbol{x},t)) = \boldsymbol J(\tilde{\boldsymbol x} - \tilde{\boldsymbol a}(t))\,h(x_3)\,g(t), &\quad\boldsymbol x\in\mathbb R^3,\, t>0,\\ \boldsymbol E(\boldsymbol{x},0) = \partial_t \boldsymbol E(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3. \end{cases} \end{align} Since the equation \eqref{mep3} is a special case of \eqref{ef}, the results of Lemmas \ref{2.1} and \ref{re} also apply to this case. For our inverse problem, it is assumed that $\bs J\in \mathcal{A}$ is a given source function, where the admissible set \begin{align*} \mathcal{A} = \{\boldsymbol J=(J_1, J_2, 0): J_i(0)>J_i(\tilde{\boldsymbol x})~\text{~for~}~ i=1 ~\text{or} ~i= 2 ~\text{and~all}~\tilde{\boldsymbol x}\neq 0 \}. \end{align*} The $x_3$-dependent function $h$ is also assumed to be given. We point out that these a priori information of $\bs J$ and $h$ are physically reasonable, while $\bs J$ and $h$ can be regarded as approximation of the Dirac functions (for example, Gaussian functions) with respect to $\tilde{\bs x}$ and $x_3$, respectively. Our aim is to recover the unknown orbit function $\tilde{\boldsymbol a}(t)\in C^1([0, T_0])^2$ which has a upper bound $|\tilde{\boldsymbol a}(t)|\leq R_1$ for some $R_1>0$ and for all $t\in[0, T_0]$. Let $R > \hat{R} + R_1$ and $T = T_0 + R + \hat{R} + R_1.$ Below we prove that the tangential trace of the dynamical magnetic field on $\Gamma_R\times(0,T)$ can be uniquely determined by that of the electric field. It will be used in the subsequent uniqueness proof with the data measured on the whole surface $\Gamma_R$. \begin{lemm}\label{dtn} Assume that the electric field $\boldsymbol E\in C([0,T];H^2(\mathbb R^3))^3\cap C^2([0,T];L^2(\mathbb R^3))^3$ satisfies \[ \begin{cases} \partial^2_{t}\boldsymbol E(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E (\boldsymbol{x},t))= 0, &\quad |\boldsymbol x|>R,~ t\in (0,T),\\ \boldsymbol E(\boldsymbol{x},0) = \partial_t \boldsymbol E(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3. \end{cases} \] If $\boldsymbol E\times \boldsymbol \nu = 0$ on $\Gamma_R \times (0,T)$, then $(\nabla \times \boldsymbol E)\times \boldsymbol \nu = 0$ on $\Gamma_R \times (0,T)$. \end{lemm} \begin{proof} Let us assume that $\boldsymbol E\times \boldsymbol \nu = 0$ on $\Gamma_R \times (0,T)$ and consider $\boldsymbol V$ defined by $$ \boldsymbol V(\boldsymbol{x},t) =\int_0^t\boldsymbol E(\boldsymbol{x},s){\rm d}s,\quad (\boldsymbol x,t)\in \mathbb R^3 \times (0,T).$$ In view of \eqref{dtn} and the fact that $\boldsymbol E(\boldsymbol x, t)\times \boldsymbol \nu = 0$ on $\Gamma_R \times (0,T)$, we find \begin{align}\label{dtn2} \begin{cases} \partial^2_{t}\boldsymbol V(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol V (\boldsymbol{x},t))= 0, &\quad |\boldsymbol x|>R,~ t\in (0,T),\\ \boldsymbol V(\boldsymbol{x},0) = \partial_t \boldsymbol V(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3,\\ \partial_t\boldsymbol V(\boldsymbol{x},t)\times \boldsymbol \nu(x)=0, &\quad (\boldsymbol x,t)\in \Gamma_R \times (0,T). \end{cases} \end{align} We define the energy $\mathcal E$ associated to $\boldsymbol V$ on $\Omega:= \{x\in\mathbb R^3:\ |x|>R\}$ \[ \mathcal E(t):=\int_\Omega (|\partial_t\boldsymbol V(\boldsymbol{x},t)|^2+|\nabla_x\times \boldsymbol V(\boldsymbol{x},t)|^2){\rm d}\bs x,\quad t\in[0,T]. \] Since $\boldsymbol E\in C([0,T];H^2(\mathbb R^3))^3\cap C^2([0,T];L^2(\mathbb R^3))^3$, we have $$\boldsymbol V\in C([0,T];H^2(\mathbb R^3))^3\cap C^1([0,T];H^1(\mathbb R^3))^3\cap C^2([0,T];L^2(\mathbb R^3))^3.$$ It follows that $\mathcal E\in C^1([0,T])$. Moreover, we get $$\mathcal E'(t)=2\int_\Omega [\partial_t^2\boldsymbol V(x,t)\cdot \partial_t\boldsymbol V(\boldsymbol x,t) +(\nabla_x\times \boldsymbol V(\boldsymbol x,t))\cdot(\nabla_{\boldsymbol x}\times \partial_t\boldsymbol V(\boldsymbol x,t))]\, {\rm d}\boldsymbol x.$$ Integrating by parts in $\bs x\in\Omega$ and applying \eqref{dtn2}, we obtain \begin{align*} \mathcal E'(t)&=2\int_\Omega [\partial_t^2\boldsymbol V+\nabla_{\boldsymbol x}\times(\nabla_{\boldsymbol x}\times \boldsymbol V)] \cdot\partial_t\boldsymbol V(\boldsymbol x,t)\,{\rm d}\boldsymbol x\\ &\quad +2\int_{\Gamma_R}(\nabla_{\boldsymbol x}\times \boldsymbol V)\cdot(\nu\times \partial_t\boldsymbol V(\boldsymbol x,t)){\rm d}s\\ &=0. \end{align*} This proves that $\mathcal E$ is a constant function. Since \[ \mathcal E(0)=\int_\Omega (|\partial_t\boldsymbol V(\boldsymbol{x},0)|^2+|\nabla_x\times \boldsymbol V(\boldsymbol{x},0)|^2){\rm d}\bs x=0, \] we deduce $\mathcal E(t)=0$ for all $t\in[0,T]$. In particular, we have \[ \int_\Omega |\boldsymbol E(\boldsymbol{x},t)|^2\,{\rm d}\bs x=\int_\Omega |\partial_t\boldsymbol V(\boldsymbol{x},t)|^2\,{\rm d}\bs x\leq \mathcal E(t)=0,\quad t\in[0,T]. \] This proves that \[ \boldsymbol E(\boldsymbol{x},t)=0, \quad |\boldsymbol x|>R,~ t\in (0,T), \] which implies that $(\nabla \times \boldsymbol E)\times \boldsymbol \nu = 0$ on $\Gamma_R \times (0,T)$ and completes the proof. \end{proof} In the following lemma, we present a uniqueness result for recovering $\tilde{\bs a}$ from the tangential trace of the electric field measured on $\Gamma_R$. Our arguments are inspired by a recent uniqueness result \cite{HuKian} to inverse source problems in elastodynamics. Compared to the uniqueness result of Theorem \ref{ut}, the slow moving assumption of the source is not required in the following Theorem \ref{up}. \begin{theo}\label{up} Assume that $\boldsymbol J \in \mathcal{A}$ and the non-vanishing function $h$ are both known. Then the function $\tilde{\boldsymbol a}(t), t \in [0, T_0]$ can be uniquely determined by the data set $\{\boldsymbol{E}(\boldsymbol{x},t)\times \boldsymbol\nu: \boldsymbol x\in \Gamma_R, t\in (0, T)\}$. \end{theo} \begin{proof} Assume that there are two functions $\tilde{\boldsymbol a}$ and $\tilde{\boldsymbol b}$ such that \begin{align}\label{mep1} \begin{cases} \partial^2_{t}\boldsymbol E_1(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_1 (\boldsymbol{x},t))= \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol a}(t))h(x_3)g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_1(\boldsymbol{x},0) = \partial_t \boldsymbol E_1(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3, \end{cases} \end{align} and \begin{align}\label{mep2} \begin{cases} \partial^2_{t}\boldsymbol E_2(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_2 (\boldsymbol{x},t))= \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol b}(t))h(x_3)g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_2(\boldsymbol{x},0) = \partial_t \boldsymbol E_2(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3. \end{cases} \end{align} It suffices to show that $\tilde{\boldsymbol a}(t) = \tilde{\boldsymbol b}(t)$ in $(0,T_0)$ if $\boldsymbol{E}_1(\boldsymbol{x},t)\times \boldsymbol\nu = \boldsymbol{E}_2(\boldsymbol{x},t)\times \boldsymbol\nu$ for $x\in \Gamma_R, t \in (0, T)$. Denote $\boldsymbol E = \boldsymbol E_1 - \boldsymbol E_2$ and \begin{align*} \boldsymbol f(\tilde{\bs x}, t) &= \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol a}(t))g(t) - \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol b}(t))g(t). \end{align*} Subtracting \eqref{mep1} from \eqref{mep2} yields \begin{align} \begin{cases} \partial^2_{t}\boldsymbol E(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E (\boldsymbol{x},t))= \boldsymbol f(\tilde{\bs x}, t)h(x_3)g(t), &\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E(\boldsymbol{x},0) = \partial_t \boldsymbol E(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3. \end{cases} \end{align} Since $h$ does not vanish identically, we can always find an interval $\Lambda=(a_-,a_+)\subset \mathbb R_+$ such that \begin{equation}\label{h} \int_{-\hat{R}\sqrt{2}/2}^{\hat{R}\sqrt{2}/2} e^{\lambda x_3}h(x_3){\rm d}x_3\neq 0,\quad\forall \lambda\in \Lambda. \end{equation} Set $H:=\{(x_1, x_2): a_-^2< x_2^2-x_1^2< a_+^2, x_1>0, x_2>0\}$, which is an open set in $\mathbb R^2$. We choose a test function $\boldsymbol F(\boldsymbol x, t)$ of the form \[ \boldsymbol F(\boldsymbol x, t) = \tilde{\bs p}e^{-{\rm i}\kappa_1 t}e^{-{\rm i}\kappa_2 \tilde{\bs d}\cdot \tilde{\bs x}}e^{\sqrt{\kappa_2^2 - \kappa_1^2}x_3}, \] where $\tilde{\bs d}= (d_1, d_2,0)$ is a unit vector, $\tilde{\bs p}=(p_1, p_2, 0)$ is a unit vector orthogonal to $\tilde{\bs d}$, and $\kappa_1, \kappa_2$ are positive constants such that $(\kappa_1, \kappa_2)\in H$. It is easy to verify that \begin{align}\label{F} \partial^2_{t}\boldsymbol F(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol F (\boldsymbol{x},t)) = 0. \end{align} Since $\boldsymbol E(\boldsymbol x, t) \times \boldsymbol \nu = 0$ on $\Gamma_R$, from Lemma \ref{dtn}, we also have $(\nabla \times \boldsymbol E(\boldsymbol x, t))\times \boldsymbol \nu = 0$ on $\Gamma_R$. Consequently, multiplying both sides of the Maxwell system by $\boldsymbol F$ and using integration by parts over $[0, T] \times B_R,$ we can obtain from \eqref{F} that \begin{align*} & \int_0^{T}\int_{B_R}\boldsymbol f(\tilde{\bs x},t)h(x_3)\cdot \boldsymbol F(\boldsymbol x, t){\rm d}{\boldsymbol x}{\rm d}t\\ &=\int_0^{T}\int_{B_R} \Big(\partial^2_{t}\boldsymbol E(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E (\boldsymbol{x},t))\Big) \cdot \boldsymbol F(\boldsymbol x, t){\rm d}{\boldsymbol x}{\rm d}t\\ &=\int_0^{T}\int_{\Gamma_R} \boldsymbol \nu \times (\nabla \times \boldsymbol E(\boldsymbol x, t)) \cdot \boldsymbol F(\boldsymbol x, t) - \boldsymbol \nu \times (\nabla \times \boldsymbol F(\boldsymbol x, t)) \cdot \boldsymbol E(\boldsymbol x, t){\rm d}s{\rm d}t\\ &=\int_0^{T}\int_{\Gamma_R} \boldsymbol \nu \times (\nabla \times \boldsymbol E(\boldsymbol x, t)) \cdot \boldsymbol F(\boldsymbol x, t) - (\boldsymbol E(\boldsymbol x, t) \times \boldsymbol \nu) \cdot (\nabla \times \boldsymbol F(\boldsymbol x, t)) {\rm d}s{\rm d}t\\ & = 0. \end{align*} Note that in the last step we have used Lemma \ref{dtn}. Recalling the definition of $\bs F$ and $\bs f$, we obtain from the previous identity that \begin{align*} \Big(\int_{-\hat{R}\sqrt{2}/2}^{\hat{R}\sqrt{2}/2} e^{\sqrt{\kappa_2^2 - \kappa_1^2}x_3}h(x_3){\rm d}x_3\Big)~ \tilde{\bs p} \cdot \int_0^{T}\int_{B_{\hat{R}}}\boldsymbol f(\tilde{\bs x}, t)e^{-{\rm i}\kappa_1 t}e^{-{\rm i}\kappa_2 \tilde{\bs d}\cdot \tilde{\bs x}}{\rm d}\tilde{\bs x}{\rm d}t = 0. \end{align*} In view of (\ref{h}) and the choice of $\kappa_1, \kappa_2$, we get \begin{align*} \tilde{\bs p} \cdot \int_0^{T}\int_{B_{\hat{R}}}\boldsymbol f(\tilde{\bs x}, t)e^{-{\rm i}\kappa_1 t}e^{-{\rm i}\kappa_2 \tilde{\bs d}\cdot \tilde{\bs x}}{\rm d}\tilde{\bs x}{\rm d}t =0. \end{align*} For a vector $\boldsymbol v(\tilde{\bs x}, t) \in \mathbb R^3$, denote by $\hat{\boldsymbol v}(\boldsymbol \xi), \boldsymbol \xi \in \mathbb R^3$ the Fourier transform of $\boldsymbol v$ with respect to the variable $(\tilde{\bs x}, t)$, i.e., \[ \hat{\boldsymbol v}(\boldsymbol \xi) = \int_{\mathbb R^3}\boldsymbol v(\tilde{\bs x}, t) e^{-{\rm i}\boldsymbol \xi \cdot (\tilde{\bs x}, t)}{\rm d}\tilde{\bs x}{\rm d}t. \] Consequently, it holds that \begin{align*} \tilde{\bs p} \cdot \hat{\boldsymbol f}( \kappa_2\tilde{\bs d},\kappa_1) = 0 \end{align*} for all $\kappa_2 > \kappa_1 >0$ and $|\tilde{\boldsymbol d}| = 1.$ On the other hand, since $\nabla_{\tilde{\bs x}}\cdot \boldsymbol J = 0,$ we have $\nabla_{\tilde{\bs x}}\cdot \bs f = 0$. Hence, \begin{align*} &\quad\tilde{\bs d}\cdot \int_0^{T}\int_{B_{\hat{R}}}\bs f(\tilde{\bs x}, t)e^{-{\rm i}\kappa_1 t}e^{-{\rm i}\kappa_2 \tilde{\bs d}\cdot \tilde{\bs x}}{\rm d}\tilde{\bs x}{\rm d}t\\ &= -\frac{1}{{\rm i}\kappa_2}\int_0^{T}\int_{B_{\hat{R}}}\bs f(\tilde{\bs x}, t) \cdot \nabla_{\tilde{\bs x}} e^{-{\rm i}\kappa_2 \tilde{\bs d}\cdot \tilde{\bs x}}{\rm d}\tilde{\bs x}{\rm d}t\\ & = \frac{1}{{\rm i}\kappa_2}\int_0^{T}\int_{B_{\hat{R}}} \nabla_{\tilde{\bs x}}\cdot \bs f(\tilde{\bs x}, t)e^{-{\rm i}\kappa_2 \tilde{\bs d}\cdot \tilde{\bs x}}{\rm d}\tilde{\bs x}{\rm d}t\\ &=0, \end{align*} which means $\tilde{\bs d} \cdot \hat{\boldsymbol f}(\kappa_2 \tilde{\bs d}, \kappa_1) = 0$ for all $(\kappa_1,\kappa_2)\in H$ and $|\tilde{\bs d}| = 1.$ Since both $\tilde{\bs d}$ and $\tilde{\bs p}$ are orthonormal vectors in $\mathbb R^2$, they form an orthonormal basis in $\mathbb R^2$. Therefore we have \[ \hat{\boldsymbol f}(\kappa_2\tilde{\bs d},\kappa_1) = \tilde{\bs d} \cdot \hat{\boldsymbol f}(\kappa_2\tilde{\bs d},\kappa_1) \tilde{\bs d} + \tilde{\bs p} \cdot \hat{\boldsymbol f}(\kappa_2\tilde{\bs d},\kappa_1) \tilde{\bs p}= 0 \] for all $(\kappa_1,\kappa_2)\in H$ and $|\tilde{\bs d}| = 1.$ Since $\hat{\boldsymbol f}$ is analytic in $\mathbb R^3$ and $\{(\kappa_1, \kappa_2\tilde{\bs d}): (\kappa_1,\kappa_2)\in H , ~|\tilde{\bs d}|=1\}$ is an open set in $\mathbb R^3$, we have $\hat{\boldsymbol f}(\boldsymbol \xi) = 0$ for all $\boldsymbol \xi \in \mathbb R^3$, which means $\boldsymbol f(\tilde{\bs x}, t) \equiv 0$ and then \begin{align*} \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol a}(t))g(t) = \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol b}(t))g(t) \end{align*} for all $\tilde{\bs x} \in \mathbb R^2$ and $t>0.$ This particulary gives \begin{align}\label{idetityp} \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol a}(t))= \boldsymbol J(\tilde{\bs x} - \tilde{\boldsymbol b}(t))\quad\mbox{for all}\quad t\in (0, T_0),\;\; \tilde{\bs x}=(x_1, x_2, 0). \end{align} Assume that there exists one time point $t_0 \in (0, T_0)$ such that $\tilde{\boldsymbol a}(t_0) \neq \tilde{\boldsymbol b}(t_0)$. By choosing $\tilde{\bs x} = \tilde{\boldsymbol a}(t_0)$ we deduce from \eqref{idetityp} that \[ \boldsymbol J(0) = \boldsymbol J(\tilde{\boldsymbol a}(t_0) - \tilde{\boldsymbol b}(t_0)), \] which is a contradiction to our assumption that $\bs J\in \mathcal{A}$. This finishes the proof of $\tilde{\bs a}(t)=\tilde{\bs b}(t)$ for $t\in[0,T_0]$. \end{proof} \begin{rema} The proof of Theorem \ref{up} does not depend on the Fourier transform of the electromagnetic field in time, but it requires the data measured on the whole surface $\Gamma_R$. However, the Fourier approach presented in the proof of Theorems \ref{us} and \ref{ut} straightforwardly carries over to the proof of Theorem \ref{up} without any additional difficulties. Particulary, the result of Theorem \ref{up} remain valid with the partial data $\{\boldsymbol{E}(\boldsymbol{x},t)\times \boldsymbol\nu: \boldsymbol x\in \Gamma\subset \Gamma_R, t\in (0, T)\}$. \end{rema} \begin{rema} In the case of the scalar wave equation, \begin{align*} \begin{cases} \partial^2_{t}u(\boldsymbol{x},t) + \nabla\times(\nabla\times u (\boldsymbol{x},t))= J(\tilde{\bs x}-\tilde{\boldsymbol a}(t))\,h(x_3)\,g(t),&\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ u(\boldsymbol{x},0) = \partial_t u(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3, \end{cases} \end{align*} where $J: \mathbb R^2\rightarrow \mathbb R_+$ is a scalar function compactly supported on $\{(x_1,x_2)\in \mathbb R^2: x_1^2+x_2^2<\hat{R}^2 \}$. Then, following the same arguments as in the proof of Theorem \ref{up}, one can prove that $\tilde{\boldsymbol a}(t), t \in [0, T_0]$ can be uniquely determined by the data set $\{\boldsymbol{E}(\boldsymbol{x},t)\times \boldsymbol\nu: \boldsymbol x\in \Gamma\subset\Gamma_R, t\in (0, T)\}$. \end{rema} \section{Inverse moving source problem for a delta distribution}\label{sec:5} As seen in the previous sections, when the temporal function $g$ is supported on $[0, T_0]$, it is possible to recover the moving orbit function $\bs a(t)$ for $t\in[0, T_0]$. In this section we consider the case where the temporal function shrinks to the Dirac distribution $g(t)=\delta(t-t_0)$ with some unknown time point $t_0>0$. Our aim is to determine $t_0$ and $\bs a(t_0)$ from the electric data at a finite number of measurement points. Consider the following initial value problem of the time-dependent Maxwell equation \begin{align}\label{Max5} \begin{cases} \partial^2_{t}\boldsymbol E(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E (\boldsymbol{x},t))= -\boldsymbol J(x-\boldsymbol a(t))\delta(t-t_0),&\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E(\boldsymbol{x},0) = \partial_t \boldsymbol E(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3. \end{cases} \end{align} Since $\nabla \cdot \boldsymbol J=0$, the electric field $\boldsymbol E(\boldsymbol x)$ in this case can be expressed as \begin{align}\label{E} \boldsymbol E (\boldsymbol x, t) &= \int_0^{\infty} \int_{\mathbb R^3} {\mathbb G} ({\boldsymbol x - \boldsymbol y}, t - s) \boldsymbol J(\boldsymbol y - \boldsymbol a(s)) \delta(s-t_0){\rm d}\boldsymbol y {\rm d}s\notag\\ & = \int_0^{\infty} \int_{\mathbb R^3} \frac{1}{4\pi |\boldsymbol x - \boldsymbol y|} \delta(|\boldsymbol x - \boldsymbol y| - (t - s)) \boldsymbol J(\boldsymbol y - \boldsymbol a(s)) \delta(s-t_0){\rm d}\boldsymbol y {\rm d}s\notag\\ &\qquad - \int_0^{\infty} \int_{\mathbb R^3} \nabla_{\boldsymbol x} \nabla^\top_{\boldsymbol x} \Big( \frac{1}{4\pi |\boldsymbol x - \boldsymbol y|} H(|\boldsymbol x - \boldsymbol y|+s-t) \Big) \boldsymbol J(\boldsymbol y - \boldsymbol a(s)) \delta(s-t_0){\rm d}\boldsymbol y {\rm d}s\notag\\ & = \int_0^{\infty} \int_{\mathbb R^3} \frac{1}{4\pi |\boldsymbol x - \boldsymbol y|} \delta(|\boldsymbol x - \boldsymbol y| - (t - s)) \boldsymbol J(\boldsymbol y - \boldsymbol a(s)) \delta(s-t_0){\rm d}\boldsymbol y {\rm d}s\notag\\ &\qquad - \int_0^{\infty} \int_{\mathbb R^3} \nabla_{\boldsymbol y} \nabla^\top_{\boldsymbol y} \Big( \frac{1}{4\pi |\boldsymbol x - \boldsymbol y|} H(|\boldsymbol x - \boldsymbol y|+s-t) \Big) \boldsymbol J(\boldsymbol y - \boldsymbol a(s)) \delta(s-t_0){\rm d}\boldsymbol y {\rm d}s\notag\\ & = \int_{\mathbb R^3} \frac{1}{4\pi |\boldsymbol x - \boldsymbol y|} \delta(|\boldsymbol x - \boldsymbol y| - (t - t_0)) \boldsymbol J(\boldsymbol y - \boldsymbol a(t_0)) {\rm d}\boldsymbol y. \end{align} Before stating the main theorem of this section, we describe the strategy for the choice of four measurement points (or receivers) on the sphere $\Gamma_R$. The geometry is shown in Figure \ref{pg}. First, we choose arbitrarily three different points $\boldsymbol x_1, \boldsymbol x_2, \boldsymbol x_3 \in \Gamma_R$. Denote by $P$ the uniquely determined plane passing through $\boldsymbol x_1$, $\boldsymbol x_2$ and $\boldsymbol x_3$, and by $L$ the line passing through the origin and perpendicular to $P$. Obviously the straight line $L$ has two intersection points with $\Gamma_R$. Choose one of the intersection points with the longer distance to plane $P$ as the fourth point $\boldsymbol x_4$. If the two intersection points have the same distance to $P$, we can choose either one of them as $\boldsymbol x_4$. By our choice of $\bs x_j, j=1,2,3,4$, they cannot lie on one side of any plane passing through the origin, if the plane $P$ determined by $\bs x_j, j=1,2,3$ does not pass through the origin. \begin{figure} \centering \includegraphics[width=0.3\textwidth]{pg} \caption{Geometry of the four measurement points.} \label{pg} \end{figure} \begin{theo} Let the measurement positions $\boldsymbol x_j\in \Gamma_R$, $j=1,\cdots,4$ be given as above and let $\bs J$ be specified as in the introduction part. We assume additionally that ${\rm supp}(\boldsymbol J)= B_{\hat{R}}$ and there exists a small constant $\delta>0$ such that $|J_i(\boldsymbol x)|>0$ for all $ \hat{R} - \delta \leq |\boldsymbol x| \leq \hat{R}$ and $i=1, 2, 3$. Then both $t_0$ and $\boldsymbol a(t_0)$ can be uniquely determined by the data set $\{\boldsymbol{E}(\boldsymbol x_j,t): j =1,\cdots,4,\, t\in (0, T)\}$, where $T = t_0 + \hat{R}+R_1 + R$. \end{theo} \begin{proof} Analogously to Lemma \ref{2.1}, one can prove that $\boldsymbol E (\boldsymbol x, t) = 0$ for all $\boldsymbol x\in B_R$ and $t>T$. Taking the Fourier transform of $\boldsymbol E(\boldsymbol x, t)$ in \eqref{fourier} with respect to $t$ and making use of the representation of $\boldsymbol E$ in \eqref{E}, we obtain \begin{align}\label{FF} \hat{\boldsymbol E}(\boldsymbol x,\kappa) &= \int_{\mathbb R^3} \frac{e^{{\rm i}\kappa(t_0 + |\boldsymbol x- \boldsymbol y|)}}{|\boldsymbol x-\boldsymbol y|}\boldsymbol J(\boldsymbol y - \boldsymbol a(t_0)){\rm d}\boldsymbol y\notag\\ & = e^{{\rm i}\kappa t_0}\int_0^\infty e^{{\rm i}\kappa \rho} \frac{1}{\rho} \int_{\Gamma_{\rho}(\boldsymbol x)}\boldsymbol J(\boldsymbol y - \boldsymbol a(t_0)){\rm d}\boldsymbol y{\rm d}\rho, \end{align} where $\Gamma_{\rho}(\bs x):= \{\boldsymbol y\in \mathbb R^3: |\bs y-\boldsymbol x| = \rho\}$. Assume that there are two orbit functions $\boldsymbol a$ and $\boldsymbol b$ and two time points $t_0$ and $\tilde{t}_0$ such that \begin{align*} \begin{cases} \partial^2_{t}\boldsymbol E_1(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_1 (\boldsymbol{x},t))= -\boldsymbol J(x-\boldsymbol a(t))\delta(t-t_0),&\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_1(\boldsymbol{x},0) = \partial_t \boldsymbol E_1(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3, \end{cases} \end{align*} and \begin{align*} \begin{cases} \partial^2_{t}\boldsymbol E_2(\boldsymbol{x},t) + \nabla\times(\nabla\times\boldsymbol E_2 (\boldsymbol{x},t))= -\boldsymbol J(x-\boldsymbol b(t))\delta(t-\tilde{t}_0),&\quad \boldsymbol{x}\in \mathbb R^3,~ t>0,\\ \boldsymbol E_2(\boldsymbol{x},0) = \partial_t \boldsymbol E_2(\boldsymbol{x},0) = 0, &\quad \boldsymbol x \in \mathbb R^3. \end{cases} \end{align*} We need to prove $t_0=\tilde{t}_0$ and $\bs a(t_0)=\bs b(\tilde{t}_0)$ under the condition $\boldsymbol E_1(\boldsymbol x_j, t) = \boldsymbol E_2(\boldsymbol x_j, t)$ for $t \in [0, T]$ and $j=1,2,3,4$. Below we denote by $\bs x\in \Gamma_R$ one of the measurement points $\bs x_j$ ($j=1,\cdots,4$). Introduce the functions $\bs F, \bs F_a, \bs F_b$: $\mathbb R_+\rightarrow \mathbb R$ as follows: \begin{align*} \boldsymbol F(\rho) &= \frac{1}{\rho} \int_{\Gamma_{\rho}(\boldsymbol x)}\boldsymbol J(\boldsymbol y){\rm d}\boldsymbol y,\\ \boldsymbol F_a(\rho) &= \frac{1}{\rho} \int_{\Gamma_{\rho}(\boldsymbol x)}\boldsymbol J(\boldsymbol y - \boldsymbol a(t_0)){\rm d}\boldsymbol y,\\ \boldsymbol F_b(\rho) &= \frac{1}{\rho} \int_{\Gamma_{\rho}(\boldsymbol x)}\boldsymbol J(\boldsymbol y - \boldsymbol b(\tilde{t}_0)){\rm d}\boldsymbol y. \end{align*} Since $\text{supp}(\boldsymbol J)=B_{\hat{R}}$ and by our assumption, each component $J_j(\boldsymbol x)$ ($j=1,2,3$) is either positive or negative in a small neighborhood of $\Gamma_{\hat{R}}$, we can obtain that \begin{align}\label{supp} &\inf\{\rho\in\text{supp} (\boldsymbol F)\}=|\boldsymbol x|-\hat{R},\qquad \qquad \quad \sup\{\rho\in\text{supp} (\boldsymbol F)\}= |\boldsymbol x|+\hat{R},\notag\\ &\inf\{\rho\in\text{supp} (\boldsymbol F_a)\}= |\boldsymbol x - \boldsymbol a(t_0)|-\hat{R},\quad \sup\{\rho\in\text{supp} (\boldsymbol F_a)\}= |\boldsymbol x-\boldsymbol a(t_0)|+\hat{R},\notag\\ &\inf\{\rho\in\text{supp} (\boldsymbol F_b)\}= |\boldsymbol x-\boldsymbol b(\tilde{t}_0)|-\hat{R},\quad \sup\{\rho\in\text{supp} (\boldsymbol F_b)\}=|\boldsymbol x-\boldsymbol b(\tilde{t}_0)|+\hat{R}. \end{align} Since $\boldsymbol E_1(\boldsymbol x, t) = \boldsymbol E_2(\boldsymbol x, t), \, t \in [0, T]$ for some point $\boldsymbol x \in \partial B_R$, from \eqref{FF} we have \[ e^{{\rm i}\kappa t_0} \hat{\boldsymbol F_a}(\kappa) = e^{{\rm i}\kappa \tilde{t}_0} \hat{\boldsymbol F_b}(\kappa) \] for all $\kappa>0$, which means \begin{align}\label{eq:Fourier} \hat{\boldsymbol F_a}(\kappa) = e^{{\rm -i}\kappa (t_0 - \tilde{t}_0)}\hat{\boldsymbol F_b}(\kappa). \end{align} Recalling the property of the Fourier transform, \[ \widehat{\boldsymbol F_b(\rho- (t_0 - \tilde{t}_0))}(\kappa) = e^{{\rm -i}\kappa (t_0 - \tilde{t}_0)} \hat{\boldsymbol F_b}(\kappa), \] we deduce from (\ref{eq:Fourier}) that \[ \boldsymbol F_b(\rho - (t_0 - \tilde{t}_0)) = \boldsymbol F_a(\rho),\quad \rho\in \mathbb R^+. \] Particularly, \begin{align*} \inf\{\text{supp} (\boldsymbol F_b(\cdot- (t_0 - \tilde{t}_0)))\}=\inf\{\text{supp} (\boldsymbol F_a(\cdot))\},\\ \sup\{\text{supp} (\boldsymbol F_b(\cdot- (t_0 - \tilde{t}_0)))\}=\sup\{\text{supp} (\boldsymbol F_a(\cdot))\}. \end{align*} Therefore, we derive from \eqref{supp} that \begin{align*} |\boldsymbol x-\boldsymbol b(\tilde{t}_0)| - \hat{R} + (t_0 - \tilde{t}_0)= |\boldsymbol x-\boldsymbol a(t_0)|-\hat{R},\\ |\boldsymbol x-\boldsymbol b(\tilde{t}_0)| + \hat{R} + (t_0 - \tilde{t}_0) = |\boldsymbol x-\boldsymbol a(t_0)|+\hat{R}, \end{align*} which means \begin{align}\label{identity} |\boldsymbol x - \boldsymbol b(\tilde{t}_0)| - |\boldsymbol x - \boldsymbol a(t_0)| =\tilde{t}_0- t_0. \end{align} Physically, the right and left hand sides of the above identity represent the difference of the flight time between $\bs x$ and $\bs a(t_0)$, $\bs b(\tilde{t}_0)$. Note that the wave speed has been normalized to one for simplicity. Finally, we prove that the identity (\ref{identity}) cannot hold simultaneously for our choice of measurement points $\bs x_j\in\Gamma_R$ ($j=1,\cdots,4$). Obviously, the set $\{\boldsymbol x \in \mathbb R^3: ~|\boldsymbol x - \boldsymbol b(\tilde{t}_0)| - |\boldsymbol x - \boldsymbol a(t_0)| = t_0 - \tilde{t}_0\}$ represents one sheet of a hyperboloid. This implies that $\bs x_j$ ($j=1,2,3,4$) should be located on one half sphere of radius $R$ excluding the corresponding equator, which is a contradiction to our choice of $\bs x_j$. Then we have $t_0 = \tilde{t}_0$ and \eqref{identity} then becomes \begin{align*} |\boldsymbol x - \boldsymbol b(t_0)| - |\boldsymbol x - \boldsymbol a(t_0)| = 0. \end{align*} This implies that $\boldsymbol x_1, \boldsymbol x_2, \boldsymbol x_3, \boldsymbol x_4$ should be on the same plane. This is also a contradiction to our choice of $\boldsymbol x_i, \, i=1, \cdots, 4$. Then we have $\boldsymbol a(t_0) = \boldsymbol b(t_0)$. \end{proof} \begin{rema} If the source term on the right hand side of (\ref{Max5}) takes the form \[ \bs F(\bs x,t)=-\bs J(x-\bs a(t))\,\sum_{j=1}^m \delta(t-t_j), \] with the impulsive time points \[ t_1<t_2<\cdots<t_m,\quad |t_{j+1}-t_j|>R. \] One can prove that the set $\{(t_j, \bs a(t_j)): j=1,2,\cdots,m\}$ can be uniquely determined by $\{\boldsymbol{E}(\boldsymbol{x_j},t): j =1,\cdots,4,\, t\in (0, T)\}$, where $T = t_m + \hat{R}+R_1 + R$. In fact, for $2\leq j\leq m$, one can prove that $(t_j, \bs a(t_j))$ can be uniquely determined by $\{\boldsymbol{E}(\boldsymbol{x_j},t): j =1,\cdots,4,\, t\in (T_{j-1}, T_j)\}$, where $T_j=T_{j-1}+t_j$ and $T_1:=t_1 + \hat{R}+R_1 + R$. \end{rema} \section{Acknowledgement} The work of G. Hu is supported by the NSFC grant (No. 11671028) and NSAF grant (No. U1530401). The work of Y. Kian is supported by the French National Research Agency ANR (project MultiOnde) grant ANR-17-CE40-0029.
{ "redpajama_set_name": "RedPajamaArXiv" }
251
package com.fredwilby.math.misc; import java.awt.Color; import java.awt.Dimension; import java.awt.Graphics; import java.awt.Point; import java.awt.image.BufferedImage; import javax.swing.JFrame; import javax.swing.JPanel; public class UlamSpiral extends SpiralWindow { private boolean[] allPrimes; private static final Color center = new Color(249, 49, 49), edge = new Color(229, 139, 29); public UlamSpiral(int sideLength) { super(sideLength); } @Override public void setup() { allPrimes = getPrimesBelow(super.getSpiralLength() + 1); } @Override public Color getPoint(int pos) { if(isPrime(pos)) return Color.white; else return interpolate((double) pos/(double) super.getSpiralLength(), center, edge); } private int interpolate(double pos, int a, int b) { return (int) ((1d - pos) * a + pos * b); } private Color interpolate(double pos, Color a, Color b) { Color result = new Color(interpolate(pos, a.getRed(), b.getRed()), interpolate(pos, a.getGreen(), b.getGreen()), interpolate(pos, a.getBlue(), b.getBlue())); return result; } public boolean isPrime(int num) { return allPrimes[num]; } /** * Returns a upperb-large array of boolean that satisfy * prime[x] == true iff x is prime. Uses seive of eratosthenes. * */ public static boolean[] getPrimesBelow(int upperb) { boolean[] ints = new boolean[upperb]; /* initialize all values to true */ for(int x = 0; x < upperb; x++) { ints[x] = true; } /* 0, 1 are not prime */ ints[0] = false; ints[1] = false; /* eliminate all composites */ for(int x = 2; x < Math.sqrt(upperb); x++) { if(ints[x]) { for(int j = x*x; j < upperb; j += x) ints[j] = false; } } return ints; } public static void main(String[] args) { SpiralWindow.Show(new UlamSpiral(1000)); } }
{ "redpajama_set_name": "RedPajamaGithub" }
9,195
{"url":"https:\/\/mathematica.stackexchange.com\/questions\/82630\/is-mathematica-intended-to-be-used-to-do-lengthy-algebraic-calculations","text":"# Is Mathematica intended to be used to do lengthy algebraic calculations? [closed]\n\nThe last two days I spent improving my Mathematica skills regarding rather simple algebraic calculations:\n\n\u2022 discrete FT\n\u2022 splitting sums\n\u2022 combining sums\n\u2022 changing summation indices\n\u2022 replacing a sum with a KroneckerDelta: $\\delta_{nm} = \\frac{1}{N} \\sum\\limits_{k = 1}^N e^{2 \\pi i \\frac{k}{N}(n-m)}$\n\u2022 canceling symmetric sums over antisymmetric terms\n\u2022 inserting commutator-relations in equations\n\u2022 etc\n\nBut I'm far from being as fast as doing it by hand.\n\nUsing Simplify, Replace etc. and rules, to format equations takes quiet some time. I assume over time a collection of formating-rules will accelerate calculations. But even trivial calculations such as non-commutative products, together with commutations relations (see ladder operators in quantum mechanics) are a load of work in Mathematica! I just can not see that I will be as fast with Mathematica as by hand.\n\nSo my question is: Is Mathematica intended for doing lengthy algebraic calculations from start to finish, faster than, or at least not much slower than by hand?\n\nI started building a library of Replacement rules and TranformationFunctions. Is that the way to go? Do you have some other tips for improvement? A book or a collection of examples?\n\n\u2022 Could you give a specific example of a symbolic calculation you think takes longer by Mathematica than by hand? But in short, yes: Mathematica is superb for doing lengthy algebraic calculations from start to finish, and there are several important calculations in my career that I could have done only with Mathematica. \u2013\u00a0David G. Stork May 5 '15 at 8:20\n\u2022 [link]mathematica.stackexchange.com\/questions\/82596\/\u2026 [link]mathematica.stackexchange.com\/questions\/65471\/\u2026 [link]mathematica.stackexchange.com\/questions\/20540\/\u2026 are examples that are really trivial by hand, but to bring Mathematica to do them takes me rather long \u2013\u00a0user29242 May 5 '15 at 8:23\n\u2022 As given in the solution you accepted: Subscript[\u03d5, 1] == Subscript[\u03d5, II + 1] \/. Exp[a_] :> Simplify[Exp[a], Assumptions -> k \u2208 Integers]. Quick and easy! \u2013\u00a0David G. Stork May 5 '15 at 8:25\n\u2022 @David Yes, individual problems on their own are not the problem. It is that I have to use many of these formatting rules, which takes me at the moment at least 5-10 times longer than doing it by hand. I am aware that most likely this is just because I have too little experience with Mathematica, but the sort of simple problems I had issues with, made me question whether Mathemaica is intended for such use:) I'm glad to hear that you manage to use it this way, so my struggles won't be for nothing. Do you use Mathematica for most of your calculations or just for the ones, not doable by hand? \u2013\u00a0user29242 May 5 '15 at 8:36\n\u2022 is your problem that it takes you longer to write the input for Mathematica to do the calculation or that Mathematica itself is slow? Mathematica is definitely used for algebraic calculations which are too much work to do by hand in any chance (e.g. feyncalc), but it needs some experience and effort to make it perform these efficiently. For very demanding calculations, you might have to switch to specialiced packages though... \u2013\u00a0Albert Retey May 5 '15 at 13:27\n\nI do analytical calculations with Mma on the regular basis during already about 10 years in the area of theoretical solid state physics. Previously I did such analytical calculations by hand, now I do it in the on-screen regime only, without passing to the paper stage even for intermediate steps. Basing on my experience I can tell the following. The timing depends first of all upon ones personal flexibility with Mma. The more masterful are you, the faster it goes.\n\nHowever, even with a good level of the Mma mastering, if it is about really heavy and lengthily analytical calculations, it is faster to calculate once by hand, than by Mma.\n\nPlease understand me clearly, I do not mean such calculations where you may be satisfied by the application of the Simplifyor PowerExpand or alike, or even few of them at once, and that ends your calculations. If it is about application of these only, your time will only be taken by the typing, that is, three times nothing.\n\nI mean real cases when you have several heavy expressions, and you need to transform parts of these expressions in one way, other parts in another way, collapse some parts together, expand other parts, bring the expressions to a form desired by you, rather than Mma to compare, neglect some parts, apply some approximations to other parts and so on. I think each of us may pick up a good example from his own experience. That is the kind of things usually done in theoretical physics. Then it really takes some time to write all necessary Mma operators, and it often takes less time to do all this by hand, the more that we were trained to calculate by hand from childhood, and have mastered it.\n\nOK, but each of us, who made lengthily calculations, knows that in such calculations small errors pop up very soon. I mean such as \"+\" instead of \"-\" when you go to a new line, or missed factor of 2 somewhere, or like that. And in the end we get an incorrect result. So we need to recalculate. How many times? I told my PhD students to recalculate no less than 7 times. It was a good try-and-error figure in the time we did everything by hand.\n\nMma, in contrast\" does no such mistakes. So altogether it takes many fold less time to do it with Mma, then by hands.\n\nSo, have fun!","date":"2021-04-12 02:40:33","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 1, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.3335422873497009, \"perplexity\": 946.5590873051891}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2021-17\/segments\/1618038066568.16\/warc\/CC-MAIN-20210412023359-20210412053359-00190.warc.gz\"}"}
null
null
import time from django.shortcuts import get_object_or_404 from django.conf import settings from canvas import (models, experiments, session_utils, search, bgwork, economy, last_sticker, fact, util, stickers, browse, knobs) from canvas.api_decorators import api_decorator from canvas.exceptions import ServiceError, InsufficientPrivileges from canvas.forms import validate_and_clean_comment from canvas.models import Metrics, Comment, UserInfo from canvas.notifications.actions import Actions from canvas.redis_models import RateLimit, redis from canvas.view_guards import require_user urlpatterns = [] api = api_decorator(urlpatterns) @api('validate_post') def validate_comment(request, parent_comment=None, replied_comment=None, reply_content=None, category=None): """ Return {"success": True} if valid. """ validate_and_clean_comment( request.user, parent_comment=parent_comment, replied_comment=replied_comment, reply_content=reply_content, category=category, ) @api('post') @require_user def post_comment(request, anonymous=False, parent_comment=None, replied_comment=None, reply_content=None, category=None, fact_metadata={}, title=None, tags=[]): anonymous = bool(anonymous) # Remember the user's preference for anonymous posting. request.user.userinfo.post_anonymously = anonymous request.user.userinfo.save() replied_comment, parent_comment, reply_content, category, title = validate_and_clean_comment( request.user, parent_comment=parent_comment, replied_comment=replied_comment, reply_content=reply_content, category=category, title=title, ) comment = models.Comment.create_and_post( request, request.user, anonymous, category, reply_content, parent_comment=parent_comment, replied_comment=replied_comment, fact_metadata=fact_metadata, title=title, tags=tags, ) if parent_comment is None: key = 'posted_unvisited_threads' val = request.session.get(key, set()) val.add(comment.id) request.session[key] = val @bgwork.defer def create_footer(): if comment.footer.should_exist(): comment.footer.call_update_in_new_process() @bgwork.defer def credit_original_author(): if (not comment.reply_content or not comment.reply_content.is_remix() or not comment.reply_content.remix_of.first_caption): return original_author = comment.reply_content.remix_of.first_caption.author if original_author != comment.author: economy.credit_received_remix(original_author) @bgwork.defer def do_notify(): Actions.replied(request.user, comment) return {'comment': comment.details()} @api('replies') def get_replies(request, comment_id=0, replies_after_timestamp=0.): from apps.features import feature_flags as features op_id = int(comment_id) # Fudge the timestamp a bit to err on the side of too many replies which we'll dedupe, instead of clicking the # button and having nothing happening. fudge = 5 replies_after_timestamp = float(replies_after_timestamp) - fudge op = get_object_or_404(models.Comment, id=op_id) replies = [r.details() for r in op.replies.filter(models.Visibility.q_visible).filter(timestamp__gt=replies_after_timestamp).order_by('timestamp')] Metrics.get_new_replies.record(request, op=op_id, replies_after_timestamp=replies_after_timestamp) if features.thread_new(request): from apps.threads.jinja_tags import thread_new_comment html = u''.join(thread_new_comment({'request': request}, reply, ignore_lazy_load=True) for reply in replies) return {'replies': replies, 'html': html} return {'replies': replies} @api('mute') def mute_thread(request, comment_id): """ Mutes the op of a given comment, so that the user never receives any notifications pertaining to that thread. """ comment = get_object_or_404(models.Comment, pk=comment_id) request.user.redis.mute_thread(comment) @api('pin') @require_user def pin_comment(request, comment_id): """ Pin the thread this comment is a part of. """ comment = get_object_or_404(models.Comment, pk=comment_id) pin = comment.add_pin(request.user) if pin is not None: # If a reply was pinned, this will be the OP. pinned_comment = pin.comment request.user.redis.pinned_bump_buffer.bump(pinned_comment.id, time.time()) Metrics.pin.record(request, comment=pinned_comment.id) @api('unpin') @require_user def unpin_comment(request, comment_id): comment = get_object_or_404(models.Comment, pk=comment_id) comment.remove_pin(request.user) fact.record("unpin", request, {'comment': comment.id}) @api('flag') @require_user def flag_comment(request, comment_id=None, quest_id=None): comment_id = comment_id or quest_id comment = get_object_or_404(models.Comment, pk=comment_id) # If the user hits the flag rate limit, silently ignore it. prefix = 'user:%s:flag_limit:' % request.user.id def allowed(key, val): if request.user.is_staff: return True freq, timespan = val return RateLimit(prefix+key, freq, timespan).allowed() if not all(allowed(key, val) for key,val in knobs.FLAG_RATE_LIMITS.iteritems()): Metrics.flag_ratelimit.record(request, comment=comment.id) raise ServiceError('Flag rate limit exceeded.') else: flag = comment.add_flag(request.user, ip=request.META['REMOTE_ADDR']) if flag is not None: if settings.PROJECT == 'canvas': request.user.redis.hidden_comments.hide_comment(comment) Metrics.flag.record(request, comment=comment.id) if comment.anonymous: Metrics.flag_anonymous_post.record(request, comment=comment.id) try: flag_count = comment.details().flag_counts[0] except KeyError: flag_count = 0 auto_moderated = False if knobs.AUTO_DISABLE_FLAGGED_COMMENTS_THRESHOLD is not None: if (not comment.judged and flag_count == knobs.AUTO_DISABLE_FLAGGED_COMMENTS_THRESHOLD[comment.author.userinfo.trusted]): comment.visibility = models.Visibility.DISABLED comment.save() comment.visibility_changed() auto_moderated = True if (not auto_moderated and flag_count >= knobs.AUTO_CURATE_FLAGGED_COMMENTS_THRESHOLD[comment.author.userinfo.trusted] and not comment.judged): comment.visibility = models.Visibility.CURATED comment.save() comment.visibility_changed() auto_moderated = True if request.user.is_staff: comment.judged = False comment.save() return {'flag_counts': comment.details().flag_counts, 'flag_id': getattr(flag, 'id', None)} @api('unflag') @require_user def unflag_comment(request, flag_id): flag = get_object_or_404(models.CommentFlag, id=flag_id) comment = flag.comment if flag.user != request.user: raise InsufficientPrivileges() flag.undone = True flag.save() comment.details.force() fact.record("unflag", request, {'comment': comment.id}) return {'flag_counts': comment.details().flag_counts, 'flag_id': flag.id} @api('delete') @require_user def delete_comment(request, comment_id): comment = models.Comment.all_objects.get(id=comment_id) if not comment.author == request.user: raise ServiceError("Not comment author") comment.moderate_and_save(models.Visibility.UNPUBLISHED, request.user, undoing=True) Metrics.delete_post.record(request, comment=comment.id) @api('get_user_sticker') @require_user def get_user_sticker(request, comment_id): """ Returns whether or not a user has stickered a post. """ comment = get_object_or_404(models.Comment, pk=comment_id) sticker = bool(comment.get_user_sticker(request.user)) return { "sticker": sticker, } @api('moderate') @require_user def moderate_comment(request, comment_id, visibility, undoing=False): comment = get_object_or_404(models.Comment.all_objects, pk=comment_id) #TODO don't get attribs from user input without whitelisting or something first. visibility = getattr(models.Visibility, str(visibility.upper())) can_moderate = request.user.can_moderate_visibility if comment.visibility not in can_moderate or visibility not in can_moderate: raise InsufficientPrivileges() comment.moderate_and_save(visibility, request.user, undoing) return {'info': comment.admin_info} @api('mark_offtopic') @require_user def mark_offtopic_comment(request, comment_id, ot_hidden=False): comment = get_object_or_404(models.Comment.all_objects, pk=comment_id) comment.mark_offtopic(request.user, offtopic=ot_hidden)
{ "redpajama_set_name": "RedPajamaGithub" }
7,372
Q: Obter trajeto usando a localização do utilizador até ao Marker pré-definido(javascript google-mapsv3) Estou a utilizar a resposta que está na pergunta do seguinte link: pergunta E não estou a entender o que preciso de colocar na linha abaixo onde está o comentário: map = new google.maps.Map( /*creates Map variable*/ document.getElementById("map"), mapOptions /*Creates a new map using the passed optional parameters in the mapOptions parameter.*/); A: document.getElementById("map") Nesta parte do código vc coloca o id da div onde será feito o mapa, neste exemplo o id da div é "map". Você pode substituir pelo id da sua div. mapOptions Esses é um objeto com as opções do mapa que vc vai criar, vai passar o objeto que criou anteriormente no exemplo var mapOptions = //Sets map options { zoom: 15, //Sets zoom level (0-21) center: coords, //zoom in on users location mapTypeControl: true, //allows you to select map type eg. map or satellite navigationControlOptions: { style: google.maps.NavigationControlStyle.SMALL //sets map controls size eg. zoom }, mapTypeId: google.maps.MapTypeId.ROADMAP //sets type of map Options:ROADMAP, SATELLITE, HYBRID, TERRIAN }; Nesse caso está setando o zoom, centro e outras configurações do seu mapa. Sem os comentários ficaria apenas: map = new google.maps.Map(document.getElementById("map"), mapOptions); O exemplo só está comentando o que é cada informação. Apenas precisa passar a div correta e o objeto com as configurações que você precisa.
{ "redpajama_set_name": "RedPajamaStackExchange" }
1,746
\section{Introduction} In this paper we derive a Lie-type splitting integrator for abstract \emph{semilinear} boundary coupled systems, and prove first order error estimates for the time integrator by extending the results of \cite{CsEF} from the linear case. The main idea of our algorithm is to decouple the two nonlinear problems appearing in the original coupled system, while maintaining stability of the boundary coupling with the help of the abstract Dirichlet operator. We use techniques from operator semigroup theory to prove the first-order convergence in the following abstract setting. \medskip We consider the abstract semilinear boundary coupled systems of the form: \begin{equation}\label{eq:main0} \begin{cases} \begin{aligned} \dot u(t)&=A_m u(t) + \mathcal{F}_1(u(t),v(t))&&\text{ for } 0<t\leq t_{\operatornamewithlimits{max}},\quad u(0)=u_0\in E,\\ \dot v(t)&=B v(t) + \mathcal{F}_2(u(t),v(t))&&\text{ for } 0<t\leq t_{\operatornamewithlimits{max}},\quad v(0)=v_0\in F, \\ Lu(t)&=v(t) &&\text{ for } 0\leq t \leq t_{\operatornamewithlimits{max}}, & \end{aligned} \end{cases} \end{equation} where $A_m$, $B$ are linear operators on the Banach spaces $E$ and $F$, respectively, $\mathcal{F}_1$, $\mathcal{F}_2$ are suitable functions, and the two unknown functions $u$ and $v$ are related via the linear coupling operator $L$ acting between (subspaces of) $E$ and $F$. The subscript $m$ in $A_m$ refers to the fact that this operator is maximal in a certain sense, this and the bulk--surface terminology is further explained in Example~\ref{examp:Lip}. A typical setting would be that $L\colon E \to F$ is a \emph{trace-type operator} between the space $E$ (for the bulk dynamics) and the \emph{boundary} space $F$ (for the surface dynamics). The precise setting and assumptions for \eqref{eq:main0} will be described below. \medskip This abstract framework simultaneously includes problems which have been analysed on their own as well. For instance, abstract \emph{boundary feedback} systems, see \cite{DeschLasieckaSchappacher}, \cite{DeschMilotaSchappacher}, \cite{CENN} and the references therein, fit into the above abstract framework where the equations in $E$ and $F$ representing the bulk and boundary equations. Such examples arise, for instance, for the boundary control of partial differential equation systems, see \cite{LasieckaTriggianiI,LasieckaTriggianiII}, and \cite{KumpfNickel}, \cite[Section~3]{Engel_etal_2010}, and \cite[Section~3]{Adler_etal_2017}. These problems usually involve a bounded feedback operator acting on $u$, which can be easily incorporated into the nonlinear term $\mathcal{F}_2$ above. For regularity results we refer to these works. We further note, that semilinear parabolic equations with \emph{dynamic boundary conditions}, see \cite{Wen59,engel2005analyticity,GalG08,ColF,vazquez2011heat,Lie13,Racke2003cahn,Gal07,dynbc}, etc., and diffusion processes on \emph{networks} with boundary conditions satisfying ordinary differential equations in the vertices, see \cite{Mugnolo,MugnoloDiss,Sikolya_flows,MugnoloRomanelli,Mugnolo_book}, etc., both formally fit into this setting. In both cases, however, the feedback operator is unbounded. \medskip In this paper we propose, as a first step into this direction, a Lie splitting scheme for abstract semilinear boundary coupled systems, where the semilinear term $\mathcal{F}=(\mathcal{F}_1,\mathcal{F}_2)$ is locally Lipschitz (and might include feedback). An important feature of our splitting method is that it \emph{separates the flows on $E$ and $F$}, i.e.~separates the bulk and surface dynamics. This could prove to be a considerable computational advantage if the bulk and surface dynamics are fundamentally different (e.g.~fast and slow reactions, linear--nonlinear coupling, etc.). In general, splitting methods simplify (or even make possible) the numerical treatment of complex systems. If the operator on the right-hand side of the initial value problem can be written as a sum of at least two suboperators, the numerical solution is obtained from a sequence of simpler subproblems corresponding to the suboperators. We will use the Lie splitting, introduced in \cite{BagGod57}, which, from the functional analytic viewpoint, corresponds to the Lie--Trotter product formula, see \cite{Trotter}, \cite[Corollary~III.5.8]{EngelNagel}. Splitting methods have been widely used in practice and analysed in the literature, see for instance the survey article \cite{McLachlanQuispel_acta}, and see also, e.g., \cite{Strang68,JahnkeLubich,Thalhammer2008,HanO09} and \cite{Faou15,EO_1,EO_2,EO_3,Alonso18,Alonso19,Alonso21}, etc. The latter group lists references which overcome order reduction of splitting schemes occurring for problems different form the boundary coupled system \eqref{eq:main0}. In particular, for semilinear partial differential equations (PDEs) with dynamic boundary conditions, two bulk--surface splitting methods were proposed in \cite{dynbc}. The numerical experiments of Section~6.3 therein illustrate that both of the proposed splitting schemes suffer from order reduction. Recently, in \cite{dynbc_PDAE_splitting}, a first-order convergent bulk--surface Lie splitting scheme was proposed and analysed. In \cite{dynbc_PDAE_splitting} parabolic PDEs with dynamic boundary conditions were considered, proving that the splitting based fully discrete method converges to the spatially semi-discrete finite element solution. For results on semilinear problems in particular see \cite[Appendix~A]{dynbc_PDAE_splitting}. The following aspects separate the two approaches: Even though both methods are suitable for semilinear problems, here we consider abstract boundary coupled parabolic problems in a general operator theoretic setting, see \eqref{eq:main0} and Section~\ref{sec:num}, while \cite{dynbc_PDAE_splitting} considers a particular family of PDEs on Lipschitz domains, see \cite[Section~2]{dynbc_PDAE_splitting}. The two Lie splittings are derived via substantially different theoretical approaches: The one herein is derived using semigroup theory and exponential integrators in Banach spaces, see Section~\ref{sec:num}, in contrast the method in \cite{dynbc_PDAE_splitting} is derived based on the differential algebraic structure of the bulk--surface finite element semi-discretisation of a PDE (the resulting sub-flows are discretised using the implicit Euler method), see \cite[Section~4]{dynbc_PDAE_splitting}. Here, we assume local Lipschitz continuity of the nonlinearities, in \cite[Theorem~A.1]{dynbc_PDAE_splitting} global Lipschitz continuity and a mild CFL condition were assumed. Regularity requirements are comparable, for more details see Remark~\ref{remark:finalafterproof}. We note that both methods differ from the two splitting schemes proposed in \cite{dynbc}. We are not aware of any other splitting-type numerical approaches separating the ``bulk'' and ``boundary'' dynamics. In the present work we start by the variation of constants formula and apply the Lie splitting to approximate the appearing linear operator semigroups. More precisely, we will identify three linear suboperators: two describing the dynamics in the bulk and on the surface, respectively, and one corresponding to the coupling. Then, either the solutions to the linear subproblems are known explicitly, or can be efficiently obtained numerically. We will show that the proposed method is first-order convergent for boundary coupled semilinear problems, it does not suffer from order reduction, and is therefore promising for PDEs with dynamic boundary conditions, cf.~\cite{dynbc}, see the experiment in Section~\ref{section:numerics dynbc}. Due to the \emph{unbounded} boundary feedback operator, our present analysis does not apply to this situation, however, our numerical experiments show first order convergence. We strongly believe that the developed techniques presented in this work provide further insight into the behaviour of operator splitting schemes of such problems. This is strengthened by our numerical experiments. The convergence result is based on studying stability and consistency, using the procedure called Lady Windermere's fan from \cite[Section~II.3]{HairerWannerI}, however, these two issues cannot be separated as in most convergence proofs, since this would lead to sub-optimal error estimates. Instead, the error is rewritten using recursion formula which, using the parabolic smoothing property (see, e.g., \cite[Theorem~II.4.6 (c)]{EngelNagel}), leads to an induction process to ensure that the numerical solution stays within a strip around the exact solution. A particular difficulty lies in the fact that the numerical method for the linear subproblems needs to approximate a convolution term in the exact flow \cite{CsEF}, therefore the stability of these approximations cannot be merely established based on semigroup properties. Estimates from \cite{CsEF} together with new technical results yield an abstract first-order error estimate for semilinear problems (with a logarithmic factor in the time step), under suitable (local Lipschitz-type) conditions on the nonlinearities. By this analysis within the abstract setting we gain a deep operator theoretical understanding of these methods, which are applicable for all specific models (e.g.~mentioned above) fitting into the framework of \eqref{eq:main0}. Numerical experiments illustrate the proved error estimates, and an experiment for dynamic boundary conditions complement our theoretical results. \medskip The paper is organised as follows. In Section \ref{sec:num} we introduce the used functional analytic framework, and derive the proposed numerical method. We also state our main result, namely, the first-order convergence, the proof of which along with error estimates takes up Sections \ref{section:prep} and \ref{sec:proof}. Finally, Section~\ref{section:numerics} presents numerical experiments illustrating and complementing our theoretical results. \section{Setting and the numerical method}\label{sec:num} We consider two Banach spaces $E$ and $F$, sometimes referred to as the bulk and boundary space, respectively, over the complex field $\mathbb C$. The product space $E \times F$ is endowed with the sum norm, or any other equivalent norm, rendering it a Banach space and the coordinate projections bounded. Elements in the product space will be denoted by boldface letters, e.g.~$\bm u = (u,v)$ for $u\in E$ and $v\in F$. The norm on $E \times F$ is simply denoted by $\|\cdot\| = \|\cdot\|_E + \|\cdot\|_F$, on the other hand, for brevity, we will drop the subscript from the $E$ and $F$ norms, as it will be always clear from the context which norm is meant. We employ the usual convention for the operator norm as well. Then we treat the nonlinearities, derive the numerical method, and present the main result of the paper. \subsection*{General framework} We will now define the abstract setting for \emph{linear} boundary coupled systems, established in \cite{CENN}, i.e.~for \eqref{eq:main0} with $\mathcal{F}_1=0$ and $\mathcal{F}_2=0$. We will also list all our assumptions on the linear operators in \eqref{eq:main0}. The following general conditions---collected using Roman numerals---will be assumed throughout the paper: \begin{iiv} \item The (so-called maximal) operator $A_m\colon\mathrm{dom}(A_m)\subseteq E\to E$ is linear. \item The linear operator $L\colon\mathrm{dom}(A_m)\to F$ is surjective and bounded with respect to the graph norm of $A_m$ on $\mathrm{dom}(A_m)$. \item The restriction $A_0$ of $A_m$ to $\ker(L)$ generates a strongly continuous semigroup $T_0$ on $E$. The (linear) operator $A_0$ is invertible, i.e., $0\in\rho(A_0)$ the resolvent set of $A_0$, (cf.~\cite[Lemma~2.2]{CENN}). \item The (linear) operator $B$ generates a strongly continuous semigroup $S$ on $F$. \item The operator matrix $\vect{A_m}{L}\colon\mathrm{dom}(A_m)\to E\times F$ is closed. \end{iiv} We recall from \cite[Lemma 2.2]{CENN} that $L|_{\ker(A_m)}$ is invertible, and its inverse, often called the \emph{Dirichlet operator}, given by \begin{align}\label{eq:D} D_0 &:= L|_{\ker(A_m)}^{-1}\colon F\to\ker(A_m)\subseteq E , \end{align} is bounded, and (via $\ker(L) \subset \mathrm{dom}(A_m)$) that \[ \mathrm{dom}(A_m)=\mathrm{dom}(A_0)\oplus \ker(A_m) = \ker(L) \oplus \ker(A_m) . \] Note that the range of the Dirichlet operator $D_0$ is almost disjoint from the domain of $A_0$ (they intersect in $\{0\}$). Therefore no matter how regular the initial conditions are, the action of $D_0$ serves as a barrier, and will result in the logarithmic loss in the error estimate for exact solutions of arbitrary smoothness. Let us briefly recall the following example from \cite{CsEF} (see Examples 2.7 and 2.8 therein), which is also one of the main motivating examples of \cite{CENN}; we refer also to \cite{GeMit11, GeMit08, BeGeMi20} for facts concerning Lipschitz domains. \begin{example}[Bounded Lipschitz domains]\label{examp:Lip} Let $\Omega\subseteq \mathbb R^d$ be a bounded domain with Lipschitz boundary $\Gamma$, $E:=\mathrm{L}^2(\Omega)$ and $F:=\mathrm{L}^2(\Gamma)$. \begin{abc} \item Consider the following operators: $A_m=\Delta_\Omega$ with domain $\mathrm{dom}(A_m):=\{f: f\in \mathrm{H}^{1/2}(\Omega)\text{ with }\Delta_\Omega f\in \mathrm{L}^2(\Omega)\}$ (being the maximal, distributional Laplacian $A_m=\Delta_\Omega$ without boundary conditions), and $Lf=f|_{\Gamma}$ the Dirichlet trace of $f\in \mathrm{dom}(A_m)$ on $\Gamma$ (see, e.g., \cite[pp.{} 89--106]{McL00}). Then $L$ is surjective and actually has a bounded right-inverse $D_0$, which is the harmonic extension operator, i.e.~for any $v \in \mathrm{L}^2(\Gamma)$ the function $u = D_0 v$ solves (uniquely) the Poisson problem $\Delta_\Omega u = 0$ with inhomogeneous Dirichlet boundary condition $L u = v$. The operator $A_0$ is strictly negative, self-adjoint and generates the Dirichlet-heat semigroup $T_0$ on $E$. \item One can also consider the Laplace--Beltrami operator $B:=\Delta_{\Gamma}$ on $\mathrm{L}^2(\Gamma)$, which (with an appropriate domain) is also a strictly negative, self-adjoint operator, see \cite[Theorem 2.5]{GeMit11} or \cite{GeMiMiMi} for details. \end{abc} In summary, we see that the abstract framework of \cite{CENN}, hence of this paper, covers interesting cases of boundary coupled problems on bounded Lipschitz domains. \end{example} We now turn our attention towards the semigroup, and its generator, corresponding to the linear problem. Consider the linear operator \begin{equation}\label{eq:calA} \mathcal{A}:=\begin{pmatrix}A_m&0\\0& B\end{pmatrix} \quad \text{with} \quad \mathrm{dom}(\mathcal{A}):=\Big\{\vect{x}{y}\in\mathrm{dom}(A_m)\times\mathrm{dom}(B): Lx=y\Big\}. \end{equation} For $y\in \mathrm{dom}(B)$ and $t\geq 0$ define the convolution \begin{equation}\label{eq:Q0tdef} Q_0(t)y:=-\int_0^t T_0(t-s)D_0S(s)By\hspace*{1pt}\mathrm{d} s. \end{equation} For all $y\in\mathrm{dom}(B)$ we also define $Q(t)y$, and using integration by parts, see \cite{CENN}, we immediately write \begin{equation}\label{eq:Qtdef} Q(t)y:=-A_0\int_0^t T_0(t-s)D_0S(s)y\hspace*{1pt}\mathrm{d} s=Q_0(t)y+D_0S(t)y-T_0(t)D_0y. \end{equation} We see that $Q_0(t)\colon\mathrm{dom}(B)\to E$ and $Q(t)\colon\mathrm{dom}(B)\to E$ are both linear operators on $\mathrm{dom}(B)$ (and we note that they are bounded when $\mathrm{dom}(B)$ is endowed with the graph norm $\|\cdot\|_B := \|\cdot\| + \|B \cdot \|$) The next result, recalled from \cite{CENN}, characterizes the generator property of $\mathcal{A}$, which in turn is in relation with the well-posedness of \eqref{eq:main0}, see Section~1.1 in \cite{MugnoloDiss}. \begin{theorem}[{\cite[Theorem 2.7]{CENN}}]\label{thm:Engel} Within this setting, let the operators $\mathcal{A}$, $D_0$ be as defined in \eqref{eq:calA} and \eqref{eq:D}, and suppose that $A_0$ is invertible. The operator $\mathcal{A}$ is the generator of a $C_0$-semigroup if and only if for each $t\ge 0$ the operator $Q(t) \colon \mathrm{dom}(B) \to E$ extends to a bounded linear operator $Q(t)\colon F \to E$ with its operator norm satisfying \begin{equation} \label{eq:Qtb} \limsup_{t\downarrow 0}\|Q(t)\|<\infty. \end{equation} The semigroup $\mathcal{T}$ generated by $\mathcal{A}$ is then given as \begin{equation} \label{eq:calT} \mathcal{T}(t)=\begin{pmatrix}T_0(t)& Q(t)\\0 & S(t)\end{pmatrix}. \end{equation} \end{theorem} In other words, if the conclusion of Theorem~\ref{thm:Engel} holds, then the linear problem $\dot \bm u = \mathcal{A} \bm u$ is well-posed and the solution with initial value $\bm u_0 = (u_0,v_0)$ is given by the semigroup as $\mathcal{T}(t)\bm u_0$. We augment the list of general conditions (i)--(v) by further assuming: \begin{iiv}\setcounter{enumi}{5} \item Additionally to $A_0$ also operator $B$ is invertible. \item The operators $A_0$ and $B$ generate boun\-ded analytic semigroups. \end{iiv} The operators appearing in Example~\ref{examp:Lip} satisfy all of these conditions. \begin{remark} \label{remark:analytic remarks} \begin{abc} \item By Corollary 2.8 in \cite{CENN} the assumption in (vii) implies that $\mathcal{A}$ is the generator of an analytic $C_0$-semigroup on $E\times F$. \item The invertibility of $A_0$ or $B$ is merely a technical assumption which slightly simplifies the proofs and assumptions, avoiding a shifting argument. \item In principle, one can drop the assumption of $B$ being the generator of an analytic semigroup. In this case minor additional assumptions on the nonlinearity $\mathcal{F}$ are needed, and the error bound for the numerical method will look slightly differently. We will comment on this in Remark~\ref{remark:finalafterproof} below, after the proof of the main theorem. \item The fact that $A_0$ generates a bounded analytic semigroup $T_0$ implies the bound $\operatornamewithlimits{sup}_{t\geq0}\|tA_0T_0(t)\|\leq M$, see, e.g., \cite[Theorem~II.4.6 (c)]{EngelNagel}. \end{abc} \end{remark} For further details on analytic semigroups we refer to the monographs \cite{Pazy,Lunardi,EngelNagel,Haase}. \subsection*{The abstract semilinear problem} We now turn our attention to semilinear boundary coupled problems \eqref{eq:main0}. In particular we will give our precise assumptions related to the solutions of the semilinear problem, and to the nonlinearity $\mathcal{F}=(\mathcal{F}_1,\mathcal{F}_2)\colon \mathrm{dom}(\mathcal{F})\subseteq E\times F \to E \times F$. \begin{assumptions} \label{ass:solution} The function $\bm u:=(u,v)\colon[0,t_{\mathrm{max}}]\to E\times F$, $t_{\mathrm{max}}>0$, is a mild solution of the problem \eqref{eq:main0}, written on $E \times F$ as \begin{equation} \label{eq:abstract evolution equation} \dot \bm u = \mathcal{A} \bm u + \mathcal{F}(\bm u) , \end{equation} i.e.~it satisfies the variation of constant formula: \begin{equation}\label{eq:voc} \bm u(t) = \mathcal{T}(t)\bm u_0+\int_0^t\mathcal{T}(t-s)\mathcal{F}(\bm u(s))\hspace*{1pt}\mathrm{d} s. \end{equation} We further assume that the exact solution $\bm u$ has the following properties: \begin{numerA} \item \label{item:1} The function $\mathcal{F}:\Sigma\to E\times F$ is Lipschitz continuous on the strip, for an $R>0$, \begin{equation*} \Sigma:= \Sigma_R := \{\bm v\in E\times F: \|\bm u(t)-\bm v\|\leq R\text{ for some $t\in [0,t_{\mathrm{max}}]$}\}\subseteq \mathrm{dom}(\mathcal{F}) \end{equation*} around the exact solution with constant $\ell_{\Sigma}$. \item \label{item:2} The second component $\mathcal{F}_2:\Sigma\to \mathrm{dom}(B)$ is Lipschitz continuous on $\Sigma$, with constant $\ell_{\Sigma,B}$. \item \label{item:3} For each $t\in [0,t_{\mathrm{max}}]$ $v(t)=\bm u(t)|_2\in \mathrm{dom}(B^2)$, and $\operatornamewithlimits{sup}_{t\in[0,t_{\mathrm{max}}]}\|B^2v(t)\|<\infty$ (here $|_2$ denotes the projection onto the second component). \item \label{item:4} The second component along the solution satisfies $\mathcal{F}_2(\bm u(t))\in \mathrm{dom}(B^2)$ for each $t\in [0,t_{\mathrm{max}}]$, and $\operatornamewithlimits{sup}_{t\in[0,t_{\mathrm{max}}]}\|B^2\mathcal{F}_2(\bm u(t))\|<\infty.$ \item \label{item:5} Furthermore, $\mathcal{F}\circ \bm u$ is differentiable and $(\mathcal{F}\circ \bm u)'\in \mathrm{L}^1([0,t_{\mathrm{max}}];E \times F)$. % \end{numerA} \end{assumptions} The local Lipschitz continuity in strip is ensured if $\mathcal{F}$ is assumed to be locally Lipschitz continuous on bounded sets, see, e.g., \cite{HochbruckOstermann} and \cite{dynbc}. Later in the convergence analysis we will show that the numerical solution stays sufficiently close to the exact solution. We further comment on these assumptions, and their relation to those in \cite{dynbc_PDAE_splitting}, after the proof in Remark~\ref{remark:finalafterproof}. Later on in the convergence proof, we will directly reference these properties by their number ($\cdot$). \subsection*{The numerical method} We are now in the position to derive the numerical method. For a time step $\tau>0$, for all $t_n = n\tau\in[0,t_{\mathrm{max}}]$, we define the numerical approximation $\bm u_n=(u_n,v_n)$ to $\bm u(t_n)=(u(t_n),v(t_n))$ via the following steps. \begin{enumsteps} \item We approximate the integral in \eqref{eq:voc} by an appropriate quadrature rule. \item We approximate the semigroup operators $\mathcal{T}$ by using an operator splitting method. Due to its special form \eqref{eq:calT}, this includes the approximation of the convolution $Q_0$, defined in \eqref{eq:Qtdef}, by an operator $V$. The choice of $V$ is determined by the used splitting method, see \cite[Section~3]{CsEF} and below. \end{enumsteps} In what follows we describe the numerical method by using first-order approximations in \emph{Steps 1--2}, and show its first-order convergence. We note here that the application of a correctly chosen exponential integrator could be inserted as a preliminary step, see \cite{HochbruckOstermann}. Since it eliminates the integral's dependence on $\bm u(s)$, the quadrature rule simplifies in \emph{Step 1}. This approach, however, leads to the same numerical method as \emph{Steps 1--2}. \medskip Before proceeding as proposed, for all $\tau>0$, we rewrite formula \eqref{eq:voc} at $t=t_n=t_{n-1}+\tau$ as \begin{align} \label{eq:VOC} \bm u(t_n) = \mathcal{T}(\tau)\bm u(t_{n-1})+\int_0^\tau\mathcal{T}(\tau-s)\mathcal{F}(\bm u(t_{n-1}+s))\hspace*{1pt}\mathrm{d} s. \end{align} Now, according to \emph{Step 1}, we approximate the integral by the left rectangle rule leading to \begin{equation*} \bm u(t_n)\approx \mathcal{T}(\tau)\bm u(t_{n-1})+ \tau\mathcal{T}(\tau)\mathcal{F}(\bm u(t_{n-1}))= \mathcal{T}(\tau) \Big( \bm u(t_{n-1})+\tau\mathcal{F}(\bm u(t_{n-1})) \Big) , \end{equation*} for any $t_n = n\tau\in(0,t_{\mathrm{max}}]$. In \emph{Step 2}, we apply the Lie splitting, which, according to \cite{CsEF}, results in the approximation of the convolution operator $Q_0(t)$ by an appropriate $V(t)$ (to be specified later). Altogether, we approximate the semigroup operators $\mathcal{T}(\tau)$ by \begin{equation}\label{eq:def calTT} \bm{T}}%{\boldsymbol{T}(\tau) = \begin{pmatrix} T_0(\tau)&V(\tau) + D_0 S(\tau)-T_0(\tau)D_0\\0&S(\tau)\end{pmatrix}. \end{equation} We remark that $\bm{T}}%{\boldsymbol{T}(\tau)=\mathcal{R}_0^{-1}\mathbb{T}(\tau)\mathcal{R}_0$ holds with the notations introduced in \cite{CsEF}: \begin{equation*} \mathbb{T}(\tau)=\begin{pmatrix} T_0(\tau)&V(\tau)\\0&S(\tau) \end{pmatrix} \quad\text{and}\quad \mathcal{R}_0=\begin{pmatrix} I&-D_0\\0&I \end{pmatrix}. \end{equation*} This leads to the numerical method approximating $\bm u$ at time $t_n = n\tau \in [0,t_{\mathrm{max}}]$: \begin{equation} \label{eq:method1} \bm u_n := \bm{L}(\tau)(\bm u_{n-1}) := \bm{T}}%{\boldsymbol{T}(\tau)\big(\bm u_{n-1}+\tau\mathcal{F}(\bm u_{n-1})\big) , \end{equation} with $\bm u_0:=(u_0,v_0)$. The actual form of operator $V(\tau)$ depends on the underlying splitting method. Here, we will use the Lie splitting of the operator $\mathcal{A}_0:=\mathcal{R}_0\mathcal{A}\mathcal{R}_0^{-1}$, proposed in \cite[Section~3]{CsEF}. Notice that \begin{equation*} \mathcal{A}_0 = \begin{pmatrix}A_0&-D_0B\\0&B\end{pmatrix}\quad\text{with\quad $\mathrm{dom}(\mathcal{A}_0)=\mathrm{dom}(A_0)\times \mathrm{dom}(B)$}, \end{equation*} i.e., the similarity transformation $\mathcal{R}_0$, diagonalizes the domain of the formally diagonal operator $\mathcal{A}$ with non-diagonal domain by decoupling the two components, cf.{} \eqref{eq:calA}. \color{black} Indeed, $\vect{x}{y}\in\mathrm{dom}(\mathcal{A}_0)$ if and only if $\vect{x+D_0y}{y}=\mathcal{R}_0^{-1}\vect{x}{y}\in\mathrm{dom}(\mathcal{A})$, i.e., if $x+D_0y\in \mathrm{dom}(A_m)$, $L(x+D_0y)=y$ and $y\in \mathrm{dom}(B)$. These hold if and only if $x\in \mathrm{dom}(A_m)$ (since $D_0y\in \mathrm{dom}(A_m)$), $x\in \ker(L)$ (since $LD_0y=y$) and $y\in \mathrm{dom}(B)$; this proves that $\mathcal{A}_0$ has diagonal domain, and also the above form of $\mathcal{A}_0$ follows at once, since for $x\in \ker(L)$ one has $A_0x=A_mx$. Now the prize to be paid for this diagonalization of the domain \color{black} is the new unbounded term $-D_0B$ making $\mathcal{A}_0$ upper triangular. Notice also that the decoupling via the similarity transformation changes the diagonal term $A_m$ into $A_0$. This technique is an abstract operator theoretic version of homogenizing boundary conditions. Now, the splitting is given by $\mathcal{A}_0=:\mathcal{A}_1+\mathcal{A}_2+\mathcal{A}_3$ with \begin{equation*} \mathcal{A}_1 = \begin{pmatrix}A_0&0\\0&0\end{pmatrix}, \quad \mathcal{A}_2 = \begin{pmatrix}0&-D_0B\\0&0\end{pmatrix}, \quad \mathcal{A}_3 = \begin{pmatrix}0&0\\0&B\end{pmatrix}, \end{equation*} and $\mathrm{dom}(\mathcal{A}_1)=\mathrm{dom}(A_0)\times F$, $\mathrm{dom}(\mathcal{A}_2)=E\times\mathrm{dom}(B)$, $\mathrm{dom}(\mathcal{A}_3)=E\times\mathrm{dom}(B)$. It was shown in \cite[Prop.~3.2.]{CsEF} that the operator \emph{parts}, see \cite[Section II.2.3]{EngelNagel}, $\mathcal{A}_1|_{E\times \mathrm{dom}(B)}$, $\mathcal{A}_2|_{E\times \mathrm{dom}(B)}=\mathcal{A}_2$ and $\mathcal{A}_3|_{E\times \mathrm{dom}(B)}$ generate the strongly continuous semigroups\footnote{Note that the domain of definition of the part $\mathcal{A}_3|_{E\times \mathrm{dom}(B)}$ is $E\times \mathrm{dom}(B^2)$, and that, in fact, $\mathcal{A}_2|_{E\times \mathrm{dom}(B)}=\mathcal{A}_2$.} \begin{equation*} \mathcal{T}_1(\tau) = \begin{pmatrix}T_0(\tau)&0\\0&I\end{pmatrix}, \quad \mathcal{T}_2(\tau) = \begin{pmatrix}I&-\tau D_0B\\0&I\end{pmatrix}, \quad \mathcal{T}_3(\tau) = \begin{pmatrix}I&0\\0&S(\tau)\end{pmatrix} , \end{equation*} respectively, on $E\times\mathrm{dom}(B)$. Then the application of the Lie splitting as $\bm{T}}%{\boldsymbol{T}(\tau)=\mathcal{R}_0^{-1}\mathcal{T}_1(\tau)\mathcal{T}_2(\tau)\mathcal{T}_3(\tau)\mathcal{R}_0$ leads to the formula \eqref{eq:def calTT} with \begin{equation}\label{eq:def V} V (\tau)= -\tau T_0(\tau)D_0BS(\tau). \end{equation} Thus, the Lie splitting transfers the coupled linear problem into the sequence of simpler ones. First we solve the equation $\dot v=Bv$ on $\mathrm{dom}(B)$ by using the original initial condition $v_0$, then we propagate the solution by $\mathcal{T}_2(\tau)$, which serves as an initial condition to the homogeneous problem $\dot u=A_0u$ on $E$. To get an approximation at $t_n=n\tau$, the semilinear expressions and the terms coming from the ``diagonalisation'' should be treated. Then the whole process needs to be cyclically performed $n$ times. \medskip We note that the approximation $Q_0(\tau)\approx V(\tau)=-\tau T_0(\tau)D_0BS(\tau)$ can also be obtained by using an appropriate convolution quadrature, i.e.~by approximating $T_0(\tau-\xi)$ from the left (at $\xi=0$) and $S(\xi)$ from the right (at $\xi=\tau$). \medskip Upon plugging in the splitting approximation \eqref{eq:def V} into the convolution $Q_0(\tau)$, and by introducing the intermediate values \begin{subequations} \label{eq:methodcomp min D_0} \begin{equation} \begin{aligned} \widetilde u_n &= u_{n-1}+\tau \mathcal{F}_1(u_{n-1},v_{n-1}), \\ \widetilde v_n &= v_{n-1}+\tau \mathcal{F}_2(u_{n-1},v_{n-1}), \end{aligned} \end{equation} the method \eqref{eq:method1} reads componentwise as \begin{equation} \begin{aligned} u_n = &\ T_0(\tau) \Big( \widetilde u_{n} - D_0 \big( \widetilde v_{n} + \tau B v_{n} \big) \Big) + D_0 v_n , \\ v_n = &\ S(\tau) \widetilde v_n. \end{aligned} \end{equation} \end{subequations} This formulation only requires two applications of the Dirichlet operator $D_0$ per time step. We point out that the two terms with the Dirichlet operator can be viewed as correction terms which correct the boundary values of the bulk-subflow along the splitting method. \subsection*{The main result} We are now in the position to state the main result of this paper, which asserts first order (up to a logarithmic factor) error estimates for the approximations obtained by the splitting integrator \eqref{eq:method1} (with \eqref{eq:def V}), i.e.~\eqref{eq:methodcomp min D_0}, separating the bulk and surface dynamics in $E$ and $F$. \begin{theorem} \label{theorem:Lie} In the above setting, let $\bm u:[0,t_{\mathrm{max}}]\to E\times F$ be the solution of \eqref{eq:main0} subject to the conditions in Assumptions~\ref{ass:solution} and consider the approximations $\bm u_n$ at time $t_n$ determined by the splitting method \eqref{eq:method1} (with \eqref{eq:def V}), or written in componentwise form \eqref{eq:methodcomp min D_0}. Then there exists a $\tau_0>0$ and $C>0$ such that for any time step $\tau \leq \tau_0$ we have at time $t_n=n\tau \in [0,t_{\mathrm{max}}]$ the error estimate \begin{equation} \label{eq:Lie error estimate} \|\bm u(t_n)-\bm u_{n}\| \leq C \, \tau \, |\log(\tau)| . \end{equation} The constant $C>0$ is independent of $n$ and $\tau>0$, but depends on $t_{\mathrm{max}}$, on constants related to the semigroups $T_0$ and $S$, as well as on the exact solution $\bm u$. \end{theorem} The proof of this result will be given in Section \ref{sec:proof} below. In the next section we state and prove some preparatory and technical results needed for the error estimates. Recall that the splitting method \eqref{eq:method1}, written componentwise \eqref{eq:methodcomp min D_0}, decouples the bulk and surface flows, which can be extremely advantageous if the two subsystems behave in a substantially different manner. We remind that, when applied to PDEs with dynamic boundary conditions, naive splitting schemes suffer from order reduction, see \cite[Section~6]{dynbc}, and a correction in \cite{dynbc_PDAE_splitting}. We make the following remark about the logarithmic factor in the above error estimate. Inequality \eqref{eq:Lie error estimate} implies that for any $\varepsilon\in (0,1)$ we have $\|\bm u(t_n)-\bm u_{n}\| \leq C' \, \tau^{1-\varepsilon}$ with another constant $C'$. This amounts to saying that the proposed method has convergence order arbitrarily close to $1$, and in fact this is also what the numerical experiments show. Indeed, numerical experiments in Section~\ref{section:numerics} illustrate and complement the first-order error estimates of Theorem~\ref{theorem:Lie}, including an example with \emph{dynamic boundary conditions}, without any order reductions. \section{Preparatory results} \label{section:prep} In this section we collect some general technical results which will be used later on in the convergence proof. After a short calculation, or by using the results in Section~3 of \cite{CsEF}, we obtain \begin{align} \label{eq:powers of calTT} \bm{T}}%{\boldsymbol{T}(\tau)^k = &\ \begin{pmatrix} T_0(k\tau) & -T_0(k\tau) D_0 + D_0 S(k\tau) + V_k(\tau) \\ 0 & S(k\tau) \end{pmatrix} , \\ \nonumber \text{where} \qquad V_k(\tau) y = &\ \sum_{j=0}^{k-1} T_0((k-1-j)\tau) V(\tau) S(j\tau) y, \end{align} see~\cite[equation~(3.9)]{CsEF}. Now we are in the position to prove exponential bounds for the powers of $\bm{T}}%{\boldsymbol{T}(\tau)$. \begin{lemma}\label{lem:calTTpower} There exist a constant $M > 0$ such that for $\tau > 0$ and $\bm{T}}%{\boldsymbol{T}(\tau)$ defined in \eqref{eq:def calTT} (with \eqref{eq:def V}), and for any $(x,y) \in E \times \mathrm{dom}(B)$ and $k \in \mathbb N$ with $k\tau\in [0,t_{\mathrm{max}}]$ \begin{equation*} \|\bm{T}}%{\boldsymbol{T}(\tau)^k \vect{x}{y} \| \leq M \|\vect{x}{y}\| + M \|B y\| . \end{equation*} Moreover, if $S$ is a bounded analytic semigroup, then we have \begin{equation*} \|\bm{T}}%{\boldsymbol{T}(\tau)^k \vect{x}{y} \| \leq M (1+\log(k)) \|\vect{x}{y}\|. \end{equation*} \end{lemma} \begin{proof} For the sum norm on the product space $E\times F$, we have \begin{align*} \|\bm{T}}%{\boldsymbol{T}(\tau)^k \vect{x}{y} \| &= \|T_0(k\tau) x-T_0(k\tau) D_0 y+D_0 S(k\tau) y+V_k(\tau)y\| + \|S(k\tau)y\| \\ & \le \|T_0(k\tau) x\| + \|T_0(k\tau) D_0 y\| + \|D_0 S(k\tau) y\| + \|V_k(\tau)y\| + \|S(k\tau)y\|. \end{align*} The exponential boundedness of the semigroups $T_0$ and $S$, and the boundedness of $D_0$ directly yield \begin{align*} \|T_0(k\tau) x\| + \|T_0(k\tau) D_0 y\| + \|D_0 S(k\tau) y\| &\leq M \big( \|x\| + \|y\| \big) , \\ \text{and} \quad \|S(k\tau) y\| &\leq M \|y\|. \end{align*} It remains to bound the term $V_k(\tau) y$. We obtain \begin{align*} \|V_k(\tau) y\| \leq &\ \tau \sum_{j=0}^{k-1} \| T_0((k-1-j)\tau) T_0(\tau) D_0 B S(\tau) S(j\tau) y \| \\ \leq &\ \tau \sum_{j=0}^{k-1} \| T_0((k-j)\tau) D_0 S((j+1)\tau) B y \| \\ \leq &\ \tau \sum_{j=0}^{k-1} M_1 \|B y\| \leq t_{\mathrm{max}} M_1 \|B y\| \leq M \|B y\| , \end{align*} which completes the proof of the first statement \medskip If $S$ is a bounded analytic semigroup, then we improve the last estimate to \begin{align*} \|V_k(\tau)\| &= \sum\limits_{j=0}^{k-1}\|T_0\bigl((k-1-j)\tau\bigr)V(\tau)S(j\tau)\|\\ &= \tau\sum\limits_{j=0}^{k-1}\|T_0\bigl((k-j)\tau\bigr)\| \, \|D_0BS(\tau)S(j\tau)\|\\ &\leq M_1M_2\|D_0\| \, \tau \sum_{j=0}^{k-1}\frac{1}{(j+1)\tau}\leq M(1+\log(k)). \end{align*} By putting the estimates together, the assertions follows. \hfill \end{proof} We recall the following lemma from \cite{CsEF}. \begin{lemma}[{\cite[Lemma 4.4]{CsEF}}]\label{lem:loclieA} There is a $C\ge 0$ such that for every $\tau\in[0,t_{\mathrm{max}}]$, for any $s_0,s_1\in [0,\tau]$, and for every $y\in \mathrm{dom}(B^2)$ we have \begin{equation*} \Bigl\|\int_{0}^{\tau} T_0(\tau-s)A_0^{-1}D_0 S(s)By\hspace*{1pt}\mathrm{d} s-\tau T_0(\tau-s_0)A_0^{-1}D_0 S(s_1)By\Bigr\| \le C \tau^{2}(\|By\|+\|B^2 y\|). \end{equation*} \end{lemma} \noindent Using the above quadrature estimate we prove the following approximation lemma. \begin{lemma}\label{lem:delta1} For $(x,y)\in E\times\mathrm{dom}(B^2)$ and $j\in\mathbb N\setminus\{0\}$ we have \begin{equation*} \big\|\bm{T}}%{\boldsymbol{T}(\tau)^j \big( \mathcal{T}(\tau) - \bm{T}}%{\boldsymbol{T}(\tau) \big) \vect{x}{y} \big\|\le C \tau^2 \|A_0 T_0(j\tau)\| \, \big(\|By\|+\|B^2y\|\big). \end{equation*} \end{lemma} \begin{proof} Using the formula \eqref{eq:powers of calTT} for $\bm{T}}%{\boldsymbol{T}(\tau)^j$ and a direct computation for the difference $\mathcal{T}(\tau) - \bm{T}}%{\boldsymbol{T}(\tau)$, we obtain \begin{align*} &\ \bm{T}}%{\boldsymbol{T}(\tau)^j \big( \mathcal{T}(\tau) - \bm{T}}%{\boldsymbol{T}(\tau) \big) \vect{x}{y} \\ = &\ \bm{T}}%{\boldsymbol{T}(\tau)^j \ \bigg(- \int_0^\tau T_0(\tau-\xi) D_0 B S(\xi)y\hspace*{1pt}\mathrm{d}\xi + \tau T_0(\tau) D_0 B S(\tau)y \ , \ 0 \ \bigg)^\top \\ = &\ \bigg( - T_0(\tau)^j \bigg( \int_0^\tau T_0(\tau-\xi) D_0 B S(\xi)y\hspace*{1pt}\mathrm{d}\xi -\tau T_0(\tau) D_0 B S(\tau)y \bigg)\ , \ 0 \ \bigg)^\top \end{align*} for all $(x,y)\in E\times\mathrm{dom}(B)$. We can further rewrite the first component as \begin{align*} &\ T_0(j\tau) \bigg( \int_0^\tau T_0(\tau-\xi) D_0 B S(\xi)y\hspace*{1pt}\mathrm{d}\xi -\tau T_0(\tau) D_0 B S(\tau)y \bigg) \\ = &\ A_0 T_0(j\tau) \, \bigg( \int_0^\tau T_0(\tau-\xi) A_0^{-1}D_0 B S(\xi)y\hspace*{1pt}\mathrm{d}\xi -\tau T_0(\tau) A_0^{-1}D_0 B S(\tau)y \bigg). \end{align*} We have \begin{align*} &\ \big\| \bm{T}}%{\boldsymbol{T}(\tau)^j \big( \mathcal{T}(\tau) - \bm{T}}%{\boldsymbol{T}(\tau) \big) \vect{x}{y} \big\| \\ = &\ \bigg\| A_0 T_0(j\tau) \, \bigg( \int_0^\tau T_0(\tau-\xi) A_0^{-1}D_0 B S(\xi)y\hspace*{1pt}\mathrm{d}\xi -\tau T_0(\tau) A_0^{-1}D_0 B S(\tau)y\bigg) \bigg\| \\ \le &\ \|A_0 T_0(j\tau)\| \, \bigg\|\int_0^\tau T_0(\tau-\xi) A_0^{-1}D_0 B S(\xi)y\hspace*{1pt}\mathrm{d}\xi -\tau T_0(\tau) A_0^{-1}D_0 B S(\tau)y\bigg\|, \end{align*} therefore an application of Lemma~\ref{lem:loclieA} with $s_0=0$ and $s_1=\tau$ proves the assertion. \hfill \end{proof} \begin{lemma}\label{lem:firsttriv} For $t,s\in [0,t_{\mathrm{max}}]$ we have \begin{align*} \|A_0^{-1}T_0(t)-A_0^{-1}T_0(s)\|\leq M|t-s|. \end{align*} \end{lemma} \begin{proof} Resorting to the Taylor expansion we have for $x\in E$ that \begin{equation*} A_0^{-1}T_0(t)x-A_0^{-1}T_0(s)x=\int_s^t T_0(r)A_0^{-1}A_0x\hspace*{1pt}\mathrm{d} r=\int_s^t T_0(r)x\hspace*{1pt}\mathrm{d} r , \end{equation*} which readily implies $\|A_0^{-1}T_0(t)x-A_0^{-1}T_0(s)x\|\leq M\|x\||t-s|$, and hence the assertion. \hfill \end{proof} \begin{lemma}\label{lem:thirdtriv} Let $f\colon[0,t_{\mathrm{max}}]\to E$ be Lipschitz continuous and consider \begin{equation*} (T_0*f)(t):=\int_0^t T_0(t-r)f(r)\hspace*{1pt}\mathrm{d} r,\quad t\in [0,t_{\mathrm{max}}]. \end{equation*} Then for all $t,s\in[0,t_{\mathrm{max}}]$ we have \begin{equation*} \|(T_0*f)(t)-(T_0*f)(s)\|\leq C|t-s|\|f\|_\mathrm{Lip}. \end{equation*} \end{lemma} \noindent Here, by $\|\cdot\|_\mathrm{Lip}$ we denote the norm $\|f\|_\mathrm{Lip} := \|f\|_\infty + \ell_{\text{best}}(f)$, where $ \ell_{\text{best}}(f)\geq 0$ is the best Lipschitz constant of $f$. \begin{proof} For $t,s\in[0,t_{\mathrm{max}}]$, we have \begin{align*} & \big\| (T_0*f)(t)-(T_0*f)(s)\big\| = \Bigl\|\int_0^t T_0(r)f(t-r)\hspace*{1pt}\mathrm{d} r-\int_0^sT_0(r)f(s-r)\hspace*{1pt}\mathrm{d} r\Bigr\|\\ & \leq \int_0^s\|T_0(r)(f(t-r)-f(s-r))\|\hspace*{1pt}\mathrm{d} r+\int_s^t\|T_0(r)f(t-r)\|\hspace*{1pt}\mathrm{d} r\\ & \leq \Co_1 |t-s|s\|f\|_\mathrm{Lip}+\Co_1|t-s|\|f\|_\infty\leq C|t-s|\|f\|_\mathrm{Lip}. \end{align*} \hfill \end{proof} Let $\vert_1$ and $\vert_2$ denote the projection onto the first and second coordinate in $E\times F$. \begin{lemma}\label{lem:delta3} For $t_{\mathrm{max}}>0$ there is a $C\geq 0$ such that for every $(x,y)\in E\times\mathrm{dom}(B)$, $t,s\in [0,t_{\mathrm{max}}]$ we have \begin{align*} \bigl\|\big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\vert_1\bigr\|& \leq C \, (\|x\|+\|y\|+\|By\|), \\ \text{and} \qquad \bigl\|\big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\vert_2\bigr\| &\leq C\,|t-s|\|By\|. \end{align*} \end{lemma} \begin{proof} We have \begin{align*} \big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\vert_2=\int_s^{t}S(r)By\hspace*{1pt}\mathrm{d} r \end{align*} and the second asserted inequality follows at once. On the other hand, for the first component \begin{align*} &\big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\vert_1=T_0(t)x-T_0(s)x+Q(t)y-Q(s)y\\ &=T_0(t)x-T_0(s)x+D_0S(t)y-D_0S(s)y-T_0(t)D_0y+T_0(s)D_0y+Q_0(t)y-Q_0(s)y, \end{align*} and we obtain \begin{align*} \big\|\big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\vert_1\big\|\le 2M\|x\| + 4M\|D_0\|\|y\|+(|t|+|s|) M^2\|D_0\|\|By\|, \end{align*} and the first inequality is also proved. \hfill \end{proof} \begin{lemma}\label{lem:delta2} For $t_{\mathrm{max}}>0$ there is a $C\geq 0$ such that for every $(x,y)\in E\times\mathrm{dom}(B^2)$, $t,s\in [0,t_{\mathrm{max}}]$, $\tau>0$, $0 < j\tau\let_{\mathrm{max}}$ we have \begin{align*} \bigl\|\bm{T}}%{\boldsymbol{T}(\tau)^j\big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\bigr\| \leq& C\,|t-s|\|A_0T_0(j\tau)\| (\|x\|+\|y\|+\|By\|)\\ &+C \, |t-s| (\|By\|+\|B^2y\|). \end{align*} \end{lemma} \begin{proof} From \eqref{eq:powers of calTT} we obtain \begin{align*} \bm{T}}%{\boldsymbol{T}(\tau)^j\big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\vert_2= &\ \int_s^{t}S(j\tau+r)By\hspace*{1pt}\mathrm{d} r , \quad\qquad \text{and} \\ \bm{T}}%{\boldsymbol{T}(\tau)^j\big(\mathcal{T}(t)-\mathcal{T}(s)\big)\vect{x}{y}\vert_1 = &\ T_0(j\tau )\bigl(T_0(t)x-T_0(s)x+Q(t)y-Q(s)y\bigr) \\ &\ - T_0(j\tau ) D_0\int_s^{t}S(r)By\hspace*{1pt}\mathrm{d} r+D_0 S(j\tau ) \int_s^{t}S(r)By\hspace*{1pt}\mathrm{d} r + V_j(\tau) \int_s^{t}S(r)By\hspace*{1pt}\mathrm{d} r\\ = &\ I_1+I_2+I_3+I_4, \end{align*} where $I_1,\dots, I_4$ denote the four terms in the order of appearance. By Lemma \ref{lem:firsttriv} \begin{align*} \|I_1\|&\leq \|A_0 T_0(j\tau )\| \Bigl(\|A_0^{-1}(T_0(t)-T_0(s))\|\|x\|+ \|A_0^{-1}(Q(t)-Q(s))y\|\Bigr)\\ &\leq C \|A_0 T_0(j\tau )\| |t-s|\|x\|+\|A_0 T_0(j\tau )\|\|A_0^{-1}(Q(t)-Q(s))y\|, \end{align*} so we need to estimate $\|A_0^{-1}(Q(t)-Q(s))y\|$. Since $A_0^{-1}Q$ has the appropriate convolution form, Lemma \ref{lem:thirdtriv} implies \begin{align*} &\|A_0^{-1}(Q(t)-Q(s))y\| =\Bigl\| (T_0*D_0S)(t)-(T_0*D_0S)(s)\Bigr\|\leq \Co_1|t-s|\|D_0\|\|By\|. \end{align*} Altogether we obtain \begin{equation*} \|I_1\|\leq \Co_2|t-s| \|A_0 T_0(j\tau )\|(\|x\|+\|y\|+\|By\|). \end{equation*} For $I_2$ and $I_3$ we have \begin{equation*} \|I_2\|+\|I_3\|\leq \Co_3|t-s|\|By\|. \end{equation*} To estimate $I_4$ we recall from the proof of Lemma \ref{lem:calTTpower} that $\|V_j(\tau)z\|\leq \Co_4\|Bz\|$ (for $j\tau\leq [0,t_{\mathrm{max}}]$), so \begin{equation*} \|I_4\|\leq \Co_4 \Bigl\|B \int_s^{t}S(r)By\hspace*{1pt}\mathrm{d} r\Bigr \|\leq \Co_5|t-s| \|B^2y\|. \end{equation*} Finally, the estimates for $I_1,\dots,I_4$ together yield the assertion. \hfill \end{proof} \section{Proof of Theorem~\ref{theorem:Lie}} \label{sec:proof} The proof of our main result is based on a recursive expression for the global error, which involves the local error and some nonlinear error terms. The recursive formula is obtained using a procedure which is sometimes called Lady Windermere's fan \cite[Section~II.3]{HairerWannerI}; our approach is inspired by \cite{OPiazzolaWalach}, \cite[Chapter~3]{diss_Walach}. The local errors are weighted by $\bm{T}}%{\boldsymbol{T}(\tau)^j$, therefore a careful accumulation estimate---heavily relying on the parabolic smoothing property---is required. In order to estimate the locally Lipschitz nonlinear terms we have to ensure that the numerical solution remains in the strip $\Sigma$ (see Assumptions~\ref{ass:solution}). This will be shown using an induction process, which is outlined as follows: \begin{itemize} \item We shall find $\tau_0 > 0$ and a constant $C>0$ such that for any $0 < \tau \leq \tau_0$ if $\bm u_0, \bm u_1,\dots,\bm u_{n-1}$ belong to the strip $\Sigma$ and $t_{n}=n\tau\leq t_{\mathrm{max}}$, then \begin{equation*} \|\bm u(t_{n})-\bm u_{n}\|\leq C\tau |\log(\tau)| . \end{equation*} \item Since $C>0$ is a constant independent of $n$ and $\tau$, we can take $\tau_0>0$ sufficiently small such that for each $\tau \leq \tau_0$ we have $C\tau |\log(\tau)|\leq R$, the width of the strip $\Sigma$, therefore by the previous step we have $\bm u_{n} \in \Sigma$. \item Since $\bm u_0$ belongs to the strip and since $\tau_0$ and $C>0$ are independent of $n$, the proof can be concluded by induction. \end{itemize} Within the proof we will use the following conventions: The positive constant $M$ comes from bounds for any of the analytic semigroups $T_0$, $S$, or $\mathcal{T}$: For each $t \in (0,t_{\mathrm{max}}]$ \begin{equation} \label{eq:smoothing} \|T_0(t)\|,\|S(t)\|,\|\mathcal{T}(t)\|\leq M, \qquad \text{and} \qquad \|t \, A_0 \, T_0(t)\|\leq M . \end{equation} Here the last estimate is usually referred to as the parabolic smoothing property of analytic semigroups, cf.~Remark~\ref{remark:analytic remarks} (c). By $C>0$ we will denote a constant that is independent of the time step, but may depend on other constants (e.g.~parameters of the problem) and on the exact solution (hence on the initial condition). Within a proof we shall indicate a possible increment of such appearing constants by a subscript: $\Co_1,\Co_2,\dots$, etc. \begin{proof}[Proof of Theorem~\ref{theorem:Lie}] For the local Lipschitz continuity of the nonlinearity $\mathcal{F}$, we will prove that the numerical solution remains in the strip $\Sigma$ around the exact solution $\bm u(t)$ using an induction argument. We estimate the global error $\bm u(t_n)-\bm u_n$, at time $t_n=n\tau\in(0,t_{\mathrm{max}}]$, by expressing it using the local error $\mathrm e^{\textrm{loc}}_n = \bm u(t_n) - \bm{L}(\tau)(\bm u(t_{n-1}))$ as follows: \begin{align*} \bm u(t_n)-\bm u_n &= \bm u(t_n)-\bm{L}(\tau)\big(\bm u(t_{n-1})\big)+\bm{L}(\tau)\big(\bm u(t_{n-1})\big)-\bm{L}(\tau)\big(\bm u_{n-1}\big) \\ &= \mathrm e^{\textrm{loc}}_n+\bm{T}}%{\boldsymbol{T}(\tau)\big(\bm u(t_{n-1})+\tau\mathcal{F}(\bm u(t_{n-1}))\big)-\bm{T}}%{\boldsymbol{T}(\tau)\big(\bm u_{n-1}+\tau\mathcal{F}(\bm u_{n-1})\big) \\ &= \mathrm e^{\textrm{loc}}_n+\bm{T}}%{\boldsymbol{T}(\tau)\big(\bm u(t_{n-1})-\bm u_{n-1}\big)+\tau\bm{T}}%{\boldsymbol{T}(\tau)\varepsilon^{\mathcal{F}}_{n-1} , \end{align*} with the nonlinear difference term $\varepsilon^{\mathcal{F}}_n = \mathcal{F}(\bm u(t_n)) - \mathcal{F}(\bm u_n)$. By resolving the recursion we obtain \begin{equation} \label{eq:global error representation} \begin{aligned} \bm u(t_n)-\bm u_n &= \mathrm e^{\textrm{loc}}_n+\bm{T}}%{\boldsymbol{T}(\tau)\big(\bm u(t_{n-1})-\bm u_{n-1}\big)+\tau\bm{T}}%{\boldsymbol{T}(\tau)\varepsilon^{\mathcal{F}}_{n-1}\\ &= \mathrm e^{\textrm{loc}}_n + \bm{T}}%{\boldsymbol{T}(\tau)\mathrm e^{\textrm{loc}}_{n-1} + \bm{T}}%{\boldsymbol{T}(\tau)^2\big(\bm u(t_{n-2})-\bm u_{n-2}\big) + \tau \bm{T}}%{\boldsymbol{T}(\tau)^2 \varepsilon^{\mathcal{F}}_{n-2} + \tau \bm{T}}%{\boldsymbol{T}(\tau) \varepsilon^{\mathcal{F}}_{n-1} \\ &\hspace*{5.5pt}\vdots \\ &= \mathrm e^{\textrm{loc}}_n + \sum_{j=1}^{n-1} \bm{T}}%{\boldsymbol{T}(\tau)^j \mathrm e^{\textrm{loc}}_{n-j} + \tau \sum_{j=1}^n \bm{T}}%{\boldsymbol{T}(\tau)^j \varepsilon^{\mathcal{F}}_{n-j} + \bm{T}}%{\boldsymbol{T}(\tau)^n\big(\bm u(0)-\bm u_0\big). \end{aligned} \end{equation} Since we have $\bm u_0=\bm u(0)$, the last term vanishes. We now start the induction process. Let us assume that the error estimate \eqref{eq:Lie error estimate} holds for all $k \leq n - 1$ with $n \tau \leq t_{\mathrm{max}}$, i.e., for a $K>0$ independent of $\tau$ and $n$, we have \begin{equation} \label{eq:error estimates for the past} \text{for } k = 0, \dotsc, n - 1, \qquad \|\bm u(t_k)-\bm u_{k}\| \leq K \, \tau \, |\log(\tau)| . \end{equation} Below, we will show that the same error estimate also holds for $n$ as well. We note that, via $\bm u_0=\bm u(0)$, the assumed error estimate trivially holds for $n - 1 = 0$. \medskip We will now estimate the remaining terms of \eqref{eq:global error representation} in parts (i)--(iii), respectively. The estimates \eqref{eq:error estimates for the past} for the past values for $k$ only appear in part (iii). (i) We rewrite the local error $\mathrm e^{\textrm{loc}}_n$ by using the forms \eqref{eq:VOC} and \eqref{eq:method1} of the exact and approximate solutions, respectively, and by Taylor's formula and (A\ref{item:5}) as \begin{align} \nonumber \mathrm e^{\textrm{loc}}_n&=\bm u(t_n)-\bm{L}(\tau)\big(\bm u(t_{n-1})\big) \\ \nonumber &= \mathcal{T}(\tau)\bm u(t_{n-1})+\int_0^\tau\hskip-1.0ex\mathcal{T}(\tau-s)\mathcal{F}(\bm u(t_{n-1}+s))\hspace*{1pt}\mathrm{d} s - \bm{T}}%{\boldsymbol{T}(\tau)\big(\bm u(t_{n-1})+\tau\mathcal{F}(\bm u(t_{n-1}))\big) \\ \nonumber &= \mathcal{T}(\tau)\bm u(t_{n-1})+\int_0^\tau\mathcal{T}(\tau-s)\mathcal{F}(\bm u(t_{n-1}))\hspace*{1pt}\mathrm{d} s \\ \nonumber &\quad+ \int_0^\tau\mathcal{T}(\tau-s)\int_0^s(\mathcal{F}\circ\bm u)'(t_{n-1}+\xi)\hspace*{1pt}\mathrm{d}\xi\hspace*{1pt}\mathrm{d} s -\bm{T}}%{\boldsymbol{T}(\tau)\big(\bm u(t_{n-1})+ \tau\mathcal{F}(\bm u(t_{n-1}))\big) \\ \nonumber &= \big(\mathcal{T}(\tau)-\bm{T}}%{\boldsymbol{T}(\tau)\big)\big(\bm u(t_{n-1})+\tau\mathcal{F}(\bm u(t_{n-1}))\big) + \int_0^\tau\hskip-1.0ex\big(\mathcal{T}(\tau-s)-\mathcal{T}(\tau)\big) \mathcal{F}(\bm u(t_{n-1}))\hspace*{1pt}\mathrm{d} s \\ \label{eq:three terms}&\quad+ \int_0^\tau\mathcal{T}(\tau-s)\int_0^s(\mathcal{F}\circ\bm u)'(t_{n-1}+\xi)\hspace*{1pt}\mathrm{d}\xi\hspace*{1pt}\mathrm{d} s. \end{align} In what follows we will estimate the three terms separately. \medskip We will bound the first term by using the boundedness of the semigroups $T_0$ and $S$. Denote $(x,y)=\bm u(t_{n-1}) + \tau\mathcal{F}(\bm u(t_{n-1}))$ and write \begin{align*} & \big(\mathcal{T}(\tau)-\bm{T}}%{\boldsymbol{T}(\tau)\big)\vect xy\Bigr|_1 = \begin{pmatrix}0&Q_0(\tau)-V(\tau)\\0&0\end{pmatrix}\vect xy\Bigr|_1 \\ =&\ Q_0(\tau)y-V(\tau)y = -\int_0^\tau T_0(\tau-\xi)D_0BS(\xi)y\hspace*{1pt}\mathrm{d}\xi+\tau T_0(\tau)D_0BS(\tau)y. \end{align*} Whence we conclude \begin{equation*} \big\|\bigl(\mathcal{T}(\tau)-\bm{T}}%{\boldsymbol{T}(\tau)\big)\vect xy\bigr\| \le\tau 2M^2\|D_0\|\|By\|\le \Co_1 \tau \|B(v(t_{n-1}) + \tau\mathcal{F}_2(\bm u(t_{n-1})))\|. \end{equation*} The second term in \eqref{eq:three terms} can be estimated by Lemma \ref{lem:delta3}, and using (A\ref{item:4}), as \begin{align*} \int_0^\tau \Big\| \big(\mathcal{T}(\tau-s)-\mathcal{T}(\tau)\big)\mathcal{F}(\bm u(t_{n-1})) \Big\| \hspace*{1pt}\mathrm{d} s \leq & \Co_2\tau\big(\|\mathcal{F}(\bm u(t_{n-1}))\|+\|B\mathcal{F}_2(\bm u(t_{n-1}) )\|\big). \end{align*} \noindent While, using the exponential boundedness of $\mathcal{T}$ and (A\ref{item:5}), the third term in \eqref{eq:three terms} is directly bounded by \begin{align*} \int_0^\tau \int_0^s \Big\| \mathcal{T}(\tau-s)(\mathcal{F}\circ\bm u)'(t_{n-1}+\xi) \Big\| \hspace*{1pt}\mathrm{d}\xi \hspace*{1pt}\mathrm{d} s &\leq M\tau\| (\mathcal{F}\circ\bm u)'\|_{\mathrm{L}^1([t_{n-1},t_n])}\\ &\leq M\tau\| (\mathcal{F}\circ\bm u)'\|_{\mathrm{L}^1([0,t_{\mathrm{max}}])}. \end{align*} % % Therefore, we finally obtain for the local error that \begin{equation}\label{eq:final estimate for (i)} \| \mathrm e^{\textrm{loc}}_n \| \leq \Co_3 \tau. \end{equation} \medskip (ii) Since in each time step the local error is $\mathcal{O}(\tau)$ and we have $\mathcal{O}(1/\tau)$ time steps, a more careful analysis is needed for the the second term in \eqref{eq:global error representation}. We first rewrite this term by the variation of constants formula \eqref{eq:VOC} and the numerical method in the form \eqref{eq:method1}: \begin{equation} \label{eq:red} \begin{aligned} &\ \sum_{j=1}^{n-1} \bm{T}}%{\boldsymbol{T}(\tau)^j \mathrm e^{\textrm{loc}}_{n-j} =\sum_{j=1}^{n-1} \bm{T}}%{\boldsymbol{T}(\tau)^j \Big( \bm u(t_{n-j}) - \bm{T}}%{\boldsymbol{T}(\tau) \big( \bm u(t_{n-j-1}) + \tau \mathcal{F}(\bm u(t_{n-j-1})) \big) \Big) \\ = &\ \sum_{j=1}^{n-1} \bm{T}}%{\boldsymbol{T}(\tau)^j \big(\mathcal{T}(\tau) - \bm{T}}%{\boldsymbol{T}(\tau)\big) \bm u(t_{n-j-1}) \\ &+ \sum_{j=1}^{n-1}\bm{T}}%{\boldsymbol{T}(\tau)^j \, \Big( \! \int_0^\tau \! \mathcal{T}(\tau-s) \mathcal{F}(\bm u(t_{n-j-1}+s))\hspace*{1pt}\mathrm{d} s - \tau \bm{T}}%{\boldsymbol{T}(\tau) \mathcal{F}(\bm u(t_{n-j-1})) \Big) . \end{aligned} \end{equation} We rewrite the second term on the right-hand side of \eqref{eq:red} using Taylor's formula: \begin{align*} & \bm{T}}%{\boldsymbol{T}(\tau)^j \Big( \int_0^\tau \mathcal{T}(\tau-s) \mathcal{F}(\bm u(t_{n-j-1}+s))\hspace*{1pt}\mathrm{d} s - \tau \bm{T}}%{\boldsymbol{T}(\tau) \mathcal{F}(\bm u(t_{n-j-1})) \Big) \\ = &\ \bm{T}}%{\boldsymbol{T}(\tau)^j\int_0^\tau \Big(\mathcal{T}(\tau-s)\mathcal{F}(\bm u(t_{n-j-1}+s))-\bm{T}}%{\boldsymbol{T}(\tau)\mathcal{F}(\bm u(t_{n-j-1}))\Big)\hspace*{1pt}\mathrm{d} s \\ = &\ \bm{T}}%{\boldsymbol{T}(\tau)^j\Big(\int_0^\tau (\mathcal{T}(\tau-s)-\bm{T}}%{\boldsymbol{T}(\tau))\mathcal{F}(\bm u(t_{n-j-1})) \hspace*{1pt}\mathrm{d} s \\ &\phantom{\bm{T}}%{\boldsymbol{T}(\tau)^j\Big(} +\int_0^\tau\mathcal{T}(\tau-s)\int_0^s(\mathcal{F}\circ\bm u)'(t_{n-j-1}+\xi) \hspace*{1pt}\mathrm{d} \xi \hspace*{1pt}\mathrm{d} s \Big) \\ = &\ \int_0^\tau \hskip-1ex \! \bm{T}}%{\boldsymbol{T}(\tau)^j\big(\mathcal{T}(\tau-s)-\mathcal{T}(\tau)\big)\mathcal{F}(\bm u(t_{n-j-1}))\hspace*{1pt}\mathrm{d} s + \tau\bm{T}}%{\boldsymbol{T}(\tau)^j\big(\mathcal{T}(\tau)-\bm{T}}%{\boldsymbol{T}(\tau)\big)\mathcal{F}(\bm u(t_{n-j-1})) \\ &\quad+ \int_0^\tau\int_0^s\bm{T}}%{\boldsymbol{T}(\tau)^j\mathcal{T}(\tau-s)(\mathcal{F}\circ\bm u)'(t_{n-j-1}+\xi)\hspace*{1pt}\mathrm{d}\xi\hspace*{1pt}\mathrm{d} s. \end{align*} Combining the two identities above, for \eqref{eq:red} we obtain: \begin{equation} \label{eq:delta terms def} \begin{aligned} \sum_{j=1}^{n-1} \bm{T}}%{\boldsymbol{T}(\tau)^j \mathrm e^{\textrm{loc}}_{n-j} &= \sum_{j=1}^{n-1} \big( \delta_{1,j} + \delta_{2,j} + \delta_{3,j} \big) \\ \text{with} \qquad \delta_{1,j} &= \bm{T}}%{\boldsymbol{T}(\tau)^j\big(\mathcal{T}(\tau )- \bm{T}}%{\boldsymbol{T}(\tau) \big) \Big(\bm u(t_{n-j-1}) + \tau\mathcal{F}(\bm u(t_{n-j-1})) \Big) , \\ \delta_{2,j} &= \int_0^\tau \bm{T}}%{\boldsymbol{T}(\tau)^j\big(\mathcal{T}(\tau-s)-\mathcal{T}(\tau)\big)\mathcal{F}(\bm u(t_{n-j-1})) \hspace*{1pt}\mathrm{d} s , \\ \delta_{3,j} &= \int_0^\tau \int_0^s \bm{T}}%{\boldsymbol{T}(\tau)^j\mathcal{T}(\tau-s)(\mathcal{F}\circ\bm u)'(t_{n-j-1}+\xi) \hspace*{1pt}\mathrm{d}\xi \hspace*{1pt}\mathrm{d} s . \end{aligned} \end{equation} For the term $\delta_{1,j}$, upon setting $(x,y) = \bm u(t_{n-j-1}) + \tau\mathcal{F}(\bm u(t_{n-j-1}))$ in Lemma \ref{lem:delta1}, by (A\ref{item:3}), (A\ref{item:4}), we obtain the following estimate for $j = 1,\dotsc,n-1$: \begin{align} \label{eq:delta1 final estimate} \|\delta_{1,j}\| \le \Co_4\tau^2 \|A_0 T_0(j\tau)\| \Big(& \big\| B \big( v(t_{n-j-1}) + \tau \mathcal{F}_2(\bm u(t_{n-j-1})) \big) \big\| \\ \nonumber &+ \big\| B^2 \big( v(t_{n-j-1}) + \tau \mathcal{F}_2(\bm u(t_{n-j-1})) \big) \big\| \Big) . \end{align} For the term $\delta_{2,j}$, setting $(x,y)=\mathcal{F}(\bm u(t_{n-j-1}))$ in Lemma \ref{lem:delta2} by (A\ref{item:4}), we obtain the estimate for $j = 1,\dotsc,n-1$: \begin{equation} \label{eq:delta2 final estimate} \begin{aligned} \|\delta_{2,j}\|&\leq \Co_5\tau^2 \|A_0 T_0(j\tau)\| \Big( \|\mathcal{F}(\bm u(t_{n-j-1}))\|+\|B\mathcal{F}_2(\bm u(t_{n-j-1}))\| \Big) \\ &\qquad +\Co_6\tau^2 \Big( \|B\mathcal{F}_2(\bm u(t_{n-j-1}))\|+\|B^2\mathcal{F}_2(\bm u(t_{n-j-1}))\| \Big) . \end{aligned} \end{equation} The term $\delta_{3,j}$ is directly estimated by using Lemma~\ref{lem:calTTpower} and (A\ref{item:5}), for $j = 1,\dotsc,n-1$, as \begin{equation} \label{eq:delta3 final estimate} \begin{aligned} \|\delta_{3,j}\|& \leq \int_0^\tau \int_0^s \Co_{7}(1+\log(j)) \Big\| \mathcal{T}(\tau-s)(\mathcal{F}\circ\bm u)'(t_{n-j-1}+\xi) \Big\| \hspace*{1pt}\mathrm{d} \xi \hspace*{1pt}\mathrm{d} s \\ & \leq M \Co_{7}(1+\log(j)) \int_0^\tau \int_0^s \|(\mathcal{F}\circ\bm u)'(t_{n-j-1}+\xi)\| \hspace*{1pt}\mathrm{d} \xi \hspace*{1pt}\mathrm{d} s \\ & \leq \tau M \Co_{7}(1+\log(j)) \|(\mathcal{F}\circ\bm u)'\|_{\mathrm{L}^1([t_{n-j-1},t_{n-j}])}. \end{aligned} \end{equation} Finally, we combine the bounds \eqref{eq:delta1 final estimate}, \eqref{eq:delta2 final estimate}, \eqref{eq:delta3 final estimate}, respectively, for $\delta_{k,j}$, $k = 1,2,3$, then collecting the terms we obtain \begin{equation}\label{eq:final estimate for (ii)} \begin{aligned} &\ \bigg\| \sum_{j=1}^{n-1} \bm{T}}%{\boldsymbol{T}(\tau)^j \mathrm e^{\textrm{loc}}_{n-j} \bigg\| \le \sum_{j=1}^{n-1} \Big( \|\delta_{1,j}\|+\|\delta_{2,j}\|+\|\delta_{3,j}\| \Big) \\ \leq &\ \Co_8 \tau \sum_{j=1}^{n-1} \frac{1}{j} \, \Big( \|B v(t_{n-j-1})\| + \|B^2 v(t_{n-j-1})\| \Big)\\ &\ +\Co_8 \tau \sum_{j=1}^{n-1} \frac{1}{j} \, \Big(\|\mathcal{F}(\bm u(t_{n-j-1}))\| +\|B \mathcal{F}_2(\bm u(t_{n-j-1})) \|\Big)\\ &\ + \Co_9 \tau^2 \sum_{j=1}^{n-1} \Big( \|B\mathcal{F}_2(\bm u(t_{n-j-1}))\|+\|B^2\mathcal{F}_2(\bm u(t_{n-j-1}))\| \Big) \\ &\ + \Co_{10}\tau\log(n)\|(\mathcal{F}\circ u)'\|_{\mathrm{L}^1([0,t_{\mathrm{max}}])} \\ \leq &\ \Co_{11} (1+\log(n))\tau + \Co_{12} \tau \, \leq \, \Co_{13} \tau\log(n+1) , \end{aligned} \end{equation} where we have used the parabolic smoothing property \eqref{eq:smoothing} of the analytic semigroup $T_0$ to estimate the factor by $\|A_0 T_0(j\tau)\| \leq M / (j\tau)$. \medskip (iii) The errors in the nonlinear terms are estimated by using Lemma~\ref{lem:calTTpower} and the local Lipschitz continuity of $\mathcal{F}$ in the appropriate spaces (see (A\ref{item:1}) and (A\ref{item:2})), in combination with the bounds \eqref{eq:error estimates for the past} for the past, as \begin{equation}\label{eq:final estimate for (iii)} \begin{aligned} &\ \bigg\| \tau \sum_{j=1}^n \bm{T}}%{\boldsymbol{T}(\tau)^j \varepsilon^{\mathcal{F}}_{n-j} \bigg\| \leq\tau \sum_{j=1}^n \Big\| \bm{T}}%{\boldsymbol{T}(\tau)^j \big( \mathcal{F}(\bm u(t_{n-j})) - \mathcal{F}(\bm u_{n-j}) \big) \Big\| \\ \leq &\ \tau \sum_{j=1}^n M \big\| \mathcal{F}(\bm u(t_{n-j})) - \mathcal{F}(\bm u_{n-j}) \big\| + \tau \sum_{j=1}^n M \big\| B \big( \mathcal{F}_2(\bm u(t_{n-j})) - \mathcal{F}_2(\bm u_{n-j})\big) \big\| \\ \leq &\ \tau \sum_{k=0}^{n-1} M \ell_{\Sigma} \| \bm u(t_{k}) - \bm u_{k} \| + \tau \sum_{k=0}^{n-1} M \ell_{\Sigma,B} \| \bm u(t_{k}) - \bm u_{k} \| \leq \Co_{14}\tau \sum_{k=0}^{n-1} \| \bm u(t_{k}) - \bm u_{k} \| , \end{aligned} \end{equation} recalling that $\ell_{\Sigma}$ and $\ell_{\Sigma,B}$ are the Lipschitz constants on $\Sigma$, see Assumptions~\ref{ass:solution} (A\ref{item:1}) and (A\ref{item:2}). For the last inequality, we used here that $(\bm u_k)_{k=0}^{n-1}$ belongs to the strip $\Sigma$ so that the Lipschitz continuity of $\mathcal{F}$ can be used, see (A\ref{item:1}) and (A\ref{item:2}). The global error \eqref{eq:global error representation} is bounded by the combination of the estimates \eqref{eq:final estimate for (i)}, \eqref{eq:final estimate for (ii)}, and \eqref{eq:final estimate for (iii)} from (i)--(iii), which altogether yield \begin{equation} \label{eq:final estimate - pre Gronwall} \begin{aligned} \|\bm u(t_n) - \bm u_n\| \leq &\ \Co_3 \tau + \Co_{13}\log(n+1)\tau +\Co_{14} \tau \sum_{k=0}^{n-1} \| \bm u(t_{k}) - \bm u_{k} \| \\ \leq &\ \Co_{15}\log(n+1)\tau+\Co_{14} \tau \sum_{k=0}^{n-1} \| \bm u(t_{k}) - \bm u_{k} \| . \end{aligned} \end{equation} A discrete Gronwall inequality then implies \begin{equation} \label{eq:final estimate} \|\bm u(t_n) - \bm u_n\| \leq \Co_{15} \mathrm e^{\Co_{14} t_{\mathrm{max}} } \log(n+1) \tau \leq C|\log(\tau)| \tau , \end{equation} for $t_n=\tau n\in[0,t_{\mathrm{max}}]$, with the constant $C:=2\Co_{15}\mathrm e^{\Co_{14}t_{\mathrm{max}}}>0$. Then for a $\tau_0>0$ sufficiently small such that for each $\tau \leq \tau_0$ we have $C|\log(\tau)| \tau\leq R$, then $\bm u_{n}\in \Sigma$ and the error estimate \eqref{eq:Lie error estimate} is satisfied for $n$ as well. Hence \eqref{eq:error estimates for the past} holds even up to $n$ instead of $n-1$. Therefore, by induction, the proof of the theorem is complete. \hfill \end{proof} \begin{remark}\label{remark:finalafterproof} \begin{abc} \item Theorem~\ref{theorem:Lie} remains true, with an almost verbatim proof as above, if $B$ is merely assumed to be the generator of a $C_0$-semigroup. This requires the following additional condition: \vskip1ex \begin{numer} \item[(A5$'$)] The function $B\circ \mathcal{F}_2\circ \bm u$ is differentiable and $(B\circ \mathcal{F}_2\circ \bm u)'\in \mathrm{L}^1([0,t_{\mathrm{max}}];F)$. % \end{numer} \vskip1ex This is relevant only for the term $\delta_{3,j}$ in the inequality \eqref{eq:delta3 final estimate} when one applies the stability estimate from Lemma \ref{lem:calTTpower}. \item Time-dependent nonlinearities can also be allowed and the same error bound holds without essential modification of the previous proof. Of course, the conditions (A\ref{item:1}), (A\ref{item:2}), (A\ref{item:4}), and (A\ref{item:5}) in Assumption~\ref{ass:solution}, involving $\mathcal{F}$ and $\mathcal{F}_2$ need to be suitably modified. For example the functions $\mathcal{F}(t,\cdot)$ need to be uniformly Lipschitz for $t\in [0,t_{\mathrm{max}}]$ (and even this can be relaxed a little), and the function $f$ defined by $f(t):=\mathcal{F}(t,\bm u(t))$ needs to be differentiable, etc. \item The assumptions (A\ref{item:3}) and (A\ref{item:4}) involving the domain $\mathrm{dom}(B^2)$ may seem a little restrictive. However, in some applications these conditions are naturally satisfied: For example if $F$ is finite dimensional (such is the case for finite networks, see \cite{MugnoloRomanelli} or \cite{Sikolya_flows}). At the same time, these conditions seem to be optimal in this generality, and play a role only in the local error estimate of the Lie splitting, i.e., in Lemma \ref{lem:loclieA} and its applications. Indeed, at other places the conditions involving $\mathrm{dom}(B^2)$ are not needed. \item We would also like to point out that the assumptions (A\ref{item:3})--(A\ref{item:5}) are comparable to the assumptions required for \cite[Theorem~A.1]{dynbc_PDAE_splitting}, see, for instance, the second time derivatives in the last estimate of the proof therein. We also note that \cite[Appendix~A]{dynbc_PDAE_splitting} uses global Lipschitz assumptions. \end{abc} \end{remark} \section{Numerical experiments} \label{section:numerics} To illustrate and complement the error estimates of Theorem~\ref{theorem:Lie}, we have performed numerical experiments for Example~\ref{examp:Lip}. \color{black} In order to allow for a direct comparison with other works from the literature, we performed the same numerical experiments which were performed in \cite{dynbc} and \cite{dynbc_PDAE_splitting}. \color{black} Let $\Omega$ be the unit disk with boundary $\Gamma = \{ x =(x_1,x_2)\in \mathbb R^2 : \|x\|_2 = 1 \}$, with $\gamma$ denoting the trace operator, and $\textnormal{n}$ denoting the outward unit normal field. Let us consider the boundary coupled semilinear parabolic partial differential equation (PDE) system $u:\overline{\Omega} \times [0,t_{\operatornamewithlimits{max}}] \to \mathbb R$ and $v: [0,t_{\operatornamewithlimits{max}}] \times \Gamma \to \mathbb R$ satisfying \begin{equation} \label{eq:PDE for numerical experiments} \begin{cases} \begin{alignedat}{3} \partial_t u = &\ \Delta u + \mathcal{F}_1(u,v) + \varrho_1 & \qquad & \text{ in } \Omega , \\ \partial_t v = &\ \Delta_\Gamma v + \mathcal{F}_2(u,v) + \varrho_2 & \qquad & \text{ on } \Gamma , \\ \gamma u = &\ v & \qquad & \text{ on } \Gamma , \end{alignedat} \end{cases} \end{equation} where the two nonlinearities are specified later, and where the two inhomogeneities $\varrho_1$ and $\varrho_2$ are chosen such that the exact solutions are known to be $u(x,t) = \exp(-t) x_1^2 x_2^2$ and $v(x,t) = \exp(-t) x_1^2 x_2^2$ (which naturally satisfy $\gamma u = v$). The boundary coupled PDE system \eqref{eq:PDE for numerical experiments} fits into the abstract framework \eqref{eq:main0} in the sense of Example~\ref{examp:Lip}. We note that Theorem~\ref{theorem:Lie} still holds for \eqref{eq:PDE for numerical experiments} with the time-dependent inhomogeneities, see Remark~\ref{remark:finalafterproof}~(b). We performed numerical experiments using the splitting method \eqref{eq:method1}, written componentwise \eqref{eq:methodcomp min D_0}, which is applied to the bulk--surface finite element semi-discretisation, see \cite{ElliottRanner,dynbc}, of the weak form of \eqref{eq:PDE for numerical experiments}. The bulk--surface finite element semi-discretisation is based on a quasi-uniform triangulation $\Omega_h$ of the continuous domain $\Omega$, such that the discrete boundary $\Gamma_h = \partial \Omega_h$ is also a sufficient good approximation of $\Gamma$. By this construction the traces of the finite element basis functions in $\Omega_h$ naturally form a basis on the boundary $\Gamma_h$, i.e.~$\{\gamma_h \phi_j\}$ forms a boundary element basis on $\Gamma_h$. Since $\Omega \neq \Omega_h$, the numerical and exact solutions are compared using the lift $^\ell$, given by $\eta_h^\ell(x^\ell) = \eta_h(x)$, where $x^\ell \in \Omega$ is a suitable image of $x \in \Omega_h$, see \cite[Section~4.1.1]{ElliottRanner}. For more details we refer to \cite[Section~4 and 5]{ElliottRanner}, or \cite[Section~3]{dynbc}. Altogether this yields the matrix--vector formulation of the semi-discrete problem, for the nodal vectors $\mathbf{u}(t) \in \mathbb R^{N_\Omega}$ and $\mathbf{v}(t) \in \mathbb R^{N_\Gamma}$, \begin{equation} \label{eq:matrx-vector formulation} \begin{cases} \begin{aligned} \mathbf{M}_\Omega \dot \mathbf{u} + \mathbf{A}_\Omega \mathbf{u} = &\ \bm{\calF}_1(\mathbf{u},\mathbf{v}) + \bm{\varrho}_1 , \\ \mathbf{M}_\Gamma \dot \mathbf{v} + \mathbf{A}_\Gamma \mathbf{v} = &\ \bm{\calF}_2(\mathbf{u},\mathbf{v}) + \bm{\varrho}_2 , \\ \bm{\gamma} \mathbf{u} = &\ \mathbf{v} , \end{aligned} \end{cases} \end{equation} where $\mathbf{M}_\Omega$ and $\mathbf{A}_\Omega$ are the mass-lumped mass matrix and stiffness matrix for $\Omega_h$, and similarly $\mathbf{M}_\Gamma$ and $\mathbf{A}_\Gamma$ for the discrete boundary $\Gamma_h$, while the nonlinearities $\bm{\calF}_i$ and the inhomogeneities $\bm{\varrho}_i$ are defined accordingly. The discrete trace operator $\bm{\gamma} \in \mathbb R^{N_\Gamma \times N_\Omega}$ extracts the nodal values at the boundary nodes. For all these quantities we have used quadratures of sufficiently high order such that the quadrature errors are negligible compared to all other spatial errors. For mass lumping in this context, and for its spatial approximation properties, we refer to \cite[Section~3.6]{dynbc}. The two semigroups in \eqref{eq:methodcomp min D_0} are known, and are computed using the \verb|expmv| Matlab package of Al-Mohy and Higham \cite{expmv}, in the above matrix--vector formulation \eqref{eq:matrx-vector formulation} the (diagonal) mass matrices are transformed to the identity, i.e.~$\widetilde\mathbf{A}_\Omega = \mathbf{M}_\Omega^{-1} \mathbf{A}_\Omega$, and similarly for $\widetilde\mathbf{A}_\Gamma$, and all other terms. The numerical experiments were performed for this transformed system. In this setting the operator $D_0$ in \eqref{eq:D} corresponds to the harmonic extension operator, which we compute here by solving a Poisson problem with inhomogeneous Dirichlet boundary conditions. \subsection{Convergence experiments} We present two convergence experiments for the above boundary coupled PDE system, with nonlinearities: \begin{subequations} \label{eq:nonlinearities} \begin{alignat}{3} \label{eq:nonlinearities - A-C} \mathcal{F}_1(u,v) =&\ 0 \qquad \text{and} & \qquad \mathcal{F}_2(u,v) = &\ -v^3 + v, \\ \label{eq:nonlinearities - mixing} \mathcal{F}_1(u,v) =&\ u^2 \qquad \text{and} & \qquad \mathcal{F}_2(u,v) = &\ v \gamma u, \end{alignat} \end{subequations} i.e.~with an Allen--Cahn-type nonlinearity, and a mixing nonlinearity. This first nonlinearity was chosen since both \cite{dynbc} and \cite{dynbc_PDAE_splitting} have reported on numerical experiments for the same Allen--Cahn example $f_\Omega(u) = 0$ and $f_\Gamma(u) = -u^3 + u$, hence the numerical experiments here are directly comparable to those referenced above. The second nonlinearity was chosen since it introduces some mixing between the bulk and boundary variables $u$ and $v$. We note here that the our experiments only serve as an illustration to Theorem~\ref{theorem:Lie}---and as comparison to the literature---since the nonlinearities in \eqref{eq:nonlinearities} do not satisfy (A\ref{item:1})--(A\ref{item:5}). Using the splitting integrator \eqref{eq:method1}, in the form \eqref{eq:methodcomp min D_0}, we have solved the transformed system \eqref{eq:matrx-vector formulation} for a sequence of time steps $\tau_k = \tau_{k-1} / 2$ (with $\tau_0 = 0.2$) and a sequence of meshes with mesh width $h_k \approx h_{k-1} / \sqrt{2}$. In Figure~\ref{fig:convplot_Lie} and \ref{fig:convplot_Lie - A-C} we report on the $\mathrm{L}^\infty(\mathrm{L}^2(\Omega))$ and $\mathrm{L}^\infty(\mathrm{L}^2(\Gamma))$ errors of the two components for the two nonlinearities in \eqref{eq:nonlinearities}, comparing the (nodal interpolation of the) exact solutions and the numerical solutions. Here, analogously to the norm on $\mathrm{L}^\infty([0,T];X)$, for a sequence $(v_k)_{k=1}^N \subset X$ we set $\|v_k\|_{\mathrm{L}^\infty(X)} = \operatornamewithlimits{max}_{k=1,\dotsc,N} \|v_k\|_X$.) In the log-log plots we can observe that the temporal convergence order matches the predicted convergence rate $\mathcal{O}(\tau |\log(\tau)|)$ of Theorem~\ref{theorem:Lie}, note the dashed reference line $\mathcal{O}(\tau)$ (the factor $ |\log(\tau)|$ is naturally not observable). In the figures each line (with different marker and colour) corresponds to a fixed mesh width $h$, while each marker on the lines corresponds to a time step size $\tau_k$. The precise time steps and degrees of freedom values are reported in Figure~\ref{fig:convplot_Lie} and \ref{fig:convplot_Lie - A-C}. We are reporting on the fully discrete errors of the numerical solution on multiple spatial grids, to be able to observe clearly that the convergence order is not reduced in contrast to \cite{dynbc}, cf.~\cite[Figure~2]{dynbc} where the error curves are sliding upward with each spatial refinement. Evidently, this is not the case here. \begin{figure}[htbp] \includegraphics[width=\textwidth,clip,trim={70 5 70 5}] {figures/convplot_Lie_b_time_LinftyL2} \caption{Temporal convergence plot for the splitting scheme \eqref{eq:methodcomp min D_0} applied to the boundary coupled PDE system \eqref{eq:PDE for numerical experiments} with \eqref{eq:nonlinearities - mixing}, $\mathrm{L}^\infty(\mathrm{L}^2)$-norms of $u$ and $v$ components on the left- and right-hand sides, respectively.} \label{fig:convplot_Lie} \end{figure} \begin{figure}[htbp] \includegraphics[width=\textwidth]{figures/convplot_Lie_b_AC_time_LinftyL2} \caption{Temporal convergence plot for the splitting scheme \eqref{eq:methodcomp min D_0} applied to the boundary coupled PDE system \eqref{eq:PDE for numerical experiments} with Allen--Cahn-type nonlinearity \eqref{eq:nonlinearities - A-C}, $\mathrm{L}^\infty(\mathrm{L}^2)$-norms of $u$ and $v$ components on the left- and right-hand sides, respectively.} \label{fig:convplot_Lie - A-C} \end{figure} \subsection{Convergence experiments with dynamic boundary conditions} \label{section:numerics dynbc} We performed the same convergence experiment for a partial differential equation with \emph{dynamic boundary conditions}, cf.~\cite{dynbc,dynbc_PDAE_splitting}, let $u:\overline{\Omega} \times [0,t_{\mathrm{max}}] \to \mathbb R$ solve the problem \begin{equation} \label{eq:PDE dynbc for numerical experiments - classical form} \begin{cases} \begin{alignedat}{3} \partial_t u = &\ \Delta u + f_\Omega(u) + \varrho_1 & \qquad & \text{ in } \Omega , \\ \partial_t u = &\ \Delta_\Gamma u -\partial_\textnormal{n} u + f_\Gamma(u) + \varrho_2 & \qquad & \text{ on } \Gamma , \end{alignedat} \end{cases} \end{equation} using the same domain, exact solution, nonlinearities, etc.~as above. Problem~\eqref{eq:PDE dynbc for numerical experiments - classical form} is equivalently rewritten as a boundary coupled PDE system \eqref{eq:PDE for numerical experiments}, where the two nonlinearities are given by \begin{align*} \mathcal{F}_1(u,v) = f_\Omega(u) \quad \text{and} \quad \mathcal{F}_2(u,v) = -\partial_\textnormal{n} u + f_\Gamma(u) . \end{align*} That is, the the nonlinear term $\mathcal{F}_2$ incorporates the coupling through the Neumann trace $-\partial_\textnormal{n} u$. The numerical method \eqref{eq:method1}, written componentwise \eqref{eq:methodcomp min D_0}, is applied to this formulation with the nonlinearity $\mathcal{F}_2$ containing the Neumann trace operator. We again report on convergence test with the nonlinearities \eqref{eq:nonlinearities} in the roles of $f_\Omega$ and $f_\Gamma$. In Figure~\ref{fig:convplot_Lie - dynbc} and \ref{fig:convplot_Lie - dynbc - A-C} we report on the $\mathrm{L}^\infty(\mathrm{L}^2(\Omega))$ and $\mathrm{L}^\infty(\mathrm{L}^2(\Gamma))$ error of the bulk and surface errors for the two nonlinearities in \eqref{eq:nonlinearities}, comparing the (nodal interpolation of the) exact solutions and the numerical solutions. (Figure~\ref{fig:convplot_Lie - dynbc} is obtained exactly as it was described for Figure~\ref{fig:convplot_Lie}, the precise time steps and degrees of freedom values can be read off from the figure.) Although in this case, due to the unboundedness of the Neumann trace operator in $\mathcal{F}_2(u,v) = -\partial_\textnormal{n} u + f_\Gamma(u)$, the conditions of Theorem~\ref{theorem:Lie} are not satisfied, in Figure~\ref{fig:convplot_Lie - dynbc} we still observe a convergence rate $\mathcal{O}(\tau)$ (note the reference lines). Qualitatively we obtain the same plots for $\mathrm{L}^\infty(\mathrm{H}^1(\Omega))$ and $\mathrm{L}^\infty(\mathrm{H}^1(\Gamma))$ norms. Note that our splitting method does not suffer from any type of order reduction, in contrast to the splitting schemes proposed in \cite{dynbc}, see Figure~1 and 2 therein. In \cite{dynbc_PDAE_splitting} the same order reduction issue was overcome by a different approach, using a correction term. \begin{figure}[htbp] \includegraphics[width=\textwidth,clip,trim={70 5 70 5}] {figures/convplot_Lie_b_dynbc_time_LinftyL2} \caption{Temporal convergence plot for the splitting scheme applied to the PDE with dynamic boundary conditions \eqref{eq:PDE dynbc for numerical experiments - classical form} with \eqref{eq:nonlinearities - mixing}, $\mathrm{L}^\infty(\mathrm{L}^2)$-norms of $u$ and $\gamma u$ components on the left- and right-hand sides, respectively.} \label{fig:convplot_Lie - dynbc} \end{figure} \begin{figure}[htbp] \includegraphics[width=\textwidth] {figures/convplot_Lie_b_AC_dynbc_time_LinftyL2} \caption{Temporal convergence plot for the splitting scheme applied to the PDE with Allen--Cahn-type dynamic boundary condition \eqref{eq:PDE dynbc for numerical experiments - classical form} with \eqref{eq:nonlinearities - A-C}, $\mathrm{L}^\infty(\mathrm{L}^2)$-norms of $u$ and $\gamma u$ components on the left- and right-hand sides, respectively.} \label{fig:convplot_Lie - dynbc - A-C} \end{figure} \section*{Acknowledgments} The estimates within this paper were finalised during a Research in Pairs programme of all three authors at the Mathematisches Forschungsinstitut Oberwolfach (MFO). We are grateful for the Institute's support---and for its unparalleled inspiring atmosphere. \section*{Funding} Petra Csom\'os acknowledges the Bolyai János Research Scholarship of the Hungarian Academy of Sciences. The work of Bal\'azs Kov\'acs is funded by the Heisenberg Programme of the Deut\-sche For\-schungs\-ge\-mein\-schaft (DFG, German Research Foundation) -- Project-ID 446\-431602, and by the DFG Graduiertenkolleg 2339 \emph{IntComSin} -- Project-ID 321821685. The research was partially supported by the bilateral German-Hungarian Project \textit{CSITI -- Coupled Systems and Innovative Time Integrators} financed by DAAD and Tempus Public Foundation. This article is based upon work from COST Action CA18232 MAT-DYN-NET, supported by COST (European Cooperation in Science and Technology). \bibliographystyle{abbrvnat}
{ "redpajama_set_name": "RedPajamaArXiv" }
3
'use strict'; const fs = require('fs'); const path = require('path'); const assert = require('assert'); const eachLimit = require('async/eachLimit'); const rimraf = require('rimraf'); const unzip = require('unzip'); const sharp = require('../../'); const fixtures = require('../fixtures'); // Verifies all tiles in a given dz output directory are <= size const assertDeepZoomTiles = function (directory, expectedSize, expectedLevels, done) { // Get levels const levels = fs.readdirSync(directory); assert.strictEqual(expectedLevels, levels.length); // Get tiles const tiles = []; levels.forEach(function (level) { // Verify level directory name assert.strictEqual(true, /^[0-9]+$/.test(level)); fs.readdirSync(path.join(directory, level)).forEach(function (tile) { // Verify tile file name assert.strictEqual(true, /^[0-9]+_[0-9]+\.jpeg$/.test(tile)); tiles.push(path.join(directory, level, tile)); }); }); // Verify each tile is <= expectedSize eachLimit(tiles, 8, function (tile, done) { sharp(tile).metadata(function (err, metadata) { if (err) { done(err); } else { assert.strictEqual('jpeg', metadata.format); assert.strictEqual('srgb', metadata.space); assert.strictEqual(3, metadata.channels); assert.strictEqual(false, metadata.hasProfile); assert.strictEqual(false, metadata.hasAlpha); assert.strictEqual(true, metadata.width <= expectedSize); assert.strictEqual(true, metadata.height <= expectedSize); done(); } }); }, done); }; describe('Tile', function () { it('Valid size values pass', function () { [1, 8192].forEach(function (size) { assert.doesNotThrow(function () { sharp().tile({ size: size }); }); }); }); it('Invalid size values fail', function () { ['zoinks', 1.1, -1, 0, 8193].forEach(function (size) { assert.throws(function () { sharp().tile({ size: size }); }); }); }); it('Valid overlap values pass', function () { [0, 8192].forEach(function (overlap) { assert.doesNotThrow(function () { sharp().tile({ size: 8192, overlap: overlap }); }); }); }); it('Invalid overlap values fail', function () { ['zoinks', 1.1, -1, 8193].forEach(function (overlap) { assert.throws(function () { sharp().tile({ overlap: overlap }); }); }); }); it('Valid container values pass', function () { ['fs', 'zip'].forEach(function (container) { assert.doesNotThrow(function () { sharp().tile({ container: container }); }); }); }); it('Invalid container values fail', function () { ['zoinks', 1].forEach(function (container) { assert.throws(function () { sharp().tile({ container: container }); }); }); }); it('Valid layout values pass', function () { ['dz', 'google', 'zoomify'].forEach(function (layout) { assert.doesNotThrow(function () { sharp().tile({ layout: layout }); }); }); }); it('Invalid layout values fail', function () { ['zoinks', 1].forEach(function (layout) { assert.throws(function () { sharp().tile({ layout: layout }); }); }); }); it('Valid formats pass', function () { ['jpeg', 'png', 'webp'].forEach(function (format) { assert.doesNotThrow(function () { sharp().toFormat(format).tile(); }); }); }); it('Invalid formats fail', function () { ['tiff', 'raw'].forEach(function (format) { assert.throws(function () { sharp().toFormat(format).tile(); }); }); }); it('Prevent larger overlap than default size', function () { assert.throws(function () { sharp().tile({overlap: 257}); }); }); it('Prevent larger overlap than provided size', function () { assert.throws(function () { sharp().tile({size: 512, overlap: 513}); }); }); it('Deep Zoom layout', function (done) { const directory = fixtures.path('output.dzi_files'); rimraf(directory, function () { sharp(fixtures.inputJpg) .toFile(fixtures.path('output.dzi'), function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('undefined', typeof info.size); assertDeepZoomTiles(directory, 256, 13, done); }); }); }); it('Deep Zoom layout with custom size+overlap', function (done) { const directory = fixtures.path('output.512.dzi_files'); rimraf(directory, function () { sharp(fixtures.inputJpg) .tile({ size: 512, overlap: 16 }) .toFile(fixtures.path('output.512.dzi'), function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('undefined', typeof info.size); assertDeepZoomTiles(directory, 512 + 2 * 16, 13, done); }); }); }); it('Zoomify layout', function (done) { const directory = fixtures.path('output.zoomify.dzi'); rimraf(directory, function () { sharp(fixtures.inputJpg) .tile({ layout: 'zoomify' }) .toFile(fixtures.path('output.zoomify.dzi'), function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('number', typeof info.size); fs.stat(path.join(directory, 'ImageProperties.xml'), function (err, stat) { if (err) throw err; assert.strictEqual(true, stat.isFile()); assert.strictEqual(true, stat.size > 0); done(); }); }); }); }); it('Google layout', function (done) { const directory = fixtures.path('output.google.dzi'); rimraf(directory, function () { sharp(fixtures.inputJpg) .tile({ layout: 'google' }) .toFile(directory, function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('number', typeof info.size); fs.stat(path.join(directory, '0', '0', '0.jpg'), function (err, stat) { if (err) throw err; assert.strictEqual(true, stat.isFile()); assert.strictEqual(true, stat.size > 0); done(); }); }); }); }); it('Google layout with jpeg format', function (done) { const directory = fixtures.path('output.jpg.google.dzi'); rimraf(directory, function () { sharp(fixtures.inputJpg) .jpeg({ quality: 1 }) .tile({ layout: 'google' }) .toFile(directory, function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('number', typeof info.size); const sample = path.join(directory, '0', '0', '0.jpg'); sharp(sample).metadata(function (err, metadata) { if (err) throw err; assert.strictEqual('jpeg', metadata.format); assert.strictEqual('srgb', metadata.space); assert.strictEqual(3, metadata.channels); assert.strictEqual(false, metadata.hasProfile); assert.strictEqual(false, metadata.hasAlpha); assert.strictEqual(256, metadata.width); assert.strictEqual(256, metadata.height); fs.stat(sample, function (err, stat) { if (err) throw err; assert.strictEqual(true, stat.size < 2000); done(); }); }); }); }); }); it('Google layout with png format', function (done) { const directory = fixtures.path('output.png.google.dzi'); rimraf(directory, function () { sharp(fixtures.inputJpg) .png({ compressionLevel: 1 }) .tile({ layout: 'google' }) .toFile(directory, function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('number', typeof info.size); const sample = path.join(directory, '0', '0', '0.png'); sharp(sample).metadata(function (err, metadata) { if (err) throw err; assert.strictEqual('png', metadata.format); assert.strictEqual('srgb', metadata.space); assert.strictEqual(3, metadata.channels); assert.strictEqual(false, metadata.hasProfile); assert.strictEqual(false, metadata.hasAlpha); assert.strictEqual(256, metadata.width); assert.strictEqual(256, metadata.height); fs.stat(sample, function (err, stat) { if (err) throw err; assert.strictEqual(true, stat.size > 44000); done(); }); }); }); }); }); it('Google layout with webp format', function (done) { const directory = fixtures.path('output.webp.google.dzi'); rimraf(directory, function () { sharp(fixtures.inputJpg) .webp({ quality: 1 }) .tile({ layout: 'google' }) .toFile(directory, function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('number', typeof info.size); const sample = path.join(directory, '0', '0', '0.webp'); sharp(sample).metadata(function (err, metadata) { if (err) throw err; assert.strictEqual('webp', metadata.format); assert.strictEqual('srgb', metadata.space); assert.strictEqual(3, metadata.channels); assert.strictEqual(false, metadata.hasProfile); assert.strictEqual(false, metadata.hasAlpha); assert.strictEqual(256, metadata.width); assert.strictEqual(256, metadata.height); fs.stat(sample, function (err, stat) { if (err) throw err; assert.strictEqual(true, stat.size < 2000); done(); }); }); }); }); }); it('Write to ZIP container using file extension', function (done) { const container = fixtures.path('output.dz.container.zip'); const extractTo = fixtures.path('output.dz.container'); const directory = path.join(extractTo, 'output.dz.container_files'); rimraf(directory, function () { sharp(fixtures.inputJpg) .toFile(container, function (err, info) { if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('number', typeof info.size); fs.stat(container, function (err, stat) { if (err) throw err; assert.strictEqual(true, stat.isFile()); assert.strictEqual(true, stat.size > 0); fs.createReadStream(container) .pipe(unzip.Extract({path: path.dirname(extractTo)})) .on('error', function (err) { throw err; }) .on('close', function () { assertDeepZoomTiles(directory, 256, 13, done); }); }); }); }); }); it('Write to ZIP container using container tile option', function (done) { const container = fixtures.path('output.dz.containeropt.zip'); const extractTo = fixtures.path('output.dz.containeropt'); const directory = path.join(extractTo, 'output.dz.containeropt_files'); rimraf(directory, function () { sharp(fixtures.inputJpg) .tile({ container: 'zip' }) .toFile(container, function (err, info) { // Vips overrides .dzi extension to .zip used by container var below if (err) throw err; assert.strictEqual('dz', info.format); assert.strictEqual(2725, info.width); assert.strictEqual(2225, info.height); assert.strictEqual(3, info.channels); assert.strictEqual('number', typeof info.size); fs.stat(container, function (err, stat) { if (err) throw err; assert.strictEqual(true, stat.isFile()); assert.strictEqual(true, stat.size > 0); fs.createReadStream(container) .pipe(unzip.Extract({path: path.dirname(extractTo)})) .on('error', function (err) { throw err; }) .on('close', function () { assertDeepZoomTiles(directory, 256, 13, done); }); }); }); }); }); });
{ "redpajama_set_name": "RedPajamaGithub" }
2,377
import hbs from 'htmlbars-inline-precompile'; const SkinTypes = ['success', 'info', 'warning', 'error']; export default { title: 'Components/OSS::Alert', component: 'alert', argTypes: { skin: { description: 'Skin of the alert', table: { type: { summary: SkinTypes.join('|') }, defaultValue: { summary: 'info' } }, options: SkinTypes, control: { type: 'select' } }, title: { description: 'The value of the title', table: { type: { summary: 'string' }, defaultValue: { summary: '' } }, control: { type: 'text' } }, subtitle: { description: 'The value of the subtitle', table: { type: { summary: 'string' }, defaultValue: { summary: '' } }, control: { type: 'text' } }, plain: { description: 'When plain is true, a gray background color is displayed, otherwise a white one', table: { type: { summary: 'boolean' }, defaultValue: { summary: 'true' } }, control: { type: 'boolean' } }, closable: { description: 'When enabled, the alert can be closed by clicking on the cross icon', table: { type: { summary: 'boolean' }, defaultValue: { summary: 'false' } }, control: { type: 'boolean' } }, onClose: { type: { required: false }, description: 'Function to be called with the alert is closed', table: { type: { summary: 'onClose(): void' } } } }, parameters: { docs: { description: { component: 'Used for displaying a title and a subtitle in layouts.' } } } }; const DefaultUsageTemplate = (args) => ({ template: hbs` <OSS::Alert @skin={{this.skin}} @title={{this.title}} @subtitle={{this.subtitle}} /> `, context: args }); export const BasicUsage = DefaultUsageTemplate.bind({}); BasicUsage.args = { skin: 'info', title: 'Title', subtitle: 'I am a subtitle in the alert' }; const BasicUsageExtraContentTemplate = (args) => ({ template: hbs` <OSS::Alert @skin={{this.skin}} @title={{this.title}} @subtitle={{this.subtitle}} @plain={{this.plain}} @closable={{this.closable}}> <:extra-content> <div class="fx-row fx-gap-px-12"> <OSS::Link @label="Link1" /> <OSS::Link @label="Link2" /> </div> </:extra-content> </OSS::Alert> `, context: args }); export const UsageExtraContent = BasicUsageExtraContentTemplate.bind({}); UsageExtraContent.args = { skin: 'info', title: 'Title', subtitle: 'I am a subtitle in the alert', plain: true, closable: false };
{ "redpajama_set_name": "RedPajamaGithub" }
5,180
<?php use yii\helpers\Html; use yii\grid\GridView; /* @var $this yii\web\View */ /* @var $dataProvider yii\data\ActiveDataProvider */ $this->title = Yii::t('app', 'Country Datas'); $this->params['breadcrumbs'][] = $this->title; ?> <div class="country-data-index"> <h1><?= Html::encode($this->title) ?></h1> </div>
{ "redpajama_set_name": "RedPajamaGithub" }
2,453
'use strict'; var mocha = require('../lib/mocha'); module.exports = function (grunt) { grunt.registerMultiTask('mochacli', 'Run Mocha server-side tests.', function () { var done = this.async(); var options = this.options(); // Use the Grunt files format if the `files` option isn't set if (Array.isArray(options.files)) { options.files = grunt.file.expand(options.files); } else { options.files = this.filesSrc; } mocha(options, function (error) { done(options.force ? true : error); }); }); };
{ "redpajama_set_name": "RedPajamaGithub" }
4,891
{"url":"http:\/\/www.cfd-online.com\/W\/index.php?title=Yap_correction&diff=5753&oldid=5751","text":"# Yap correction\n\n(Difference between revisions)\n Revision as of 10:03, 25 May 2006 (view source)Jola (Talk | contribs) (just added the reference to start with)\u2190 Older edit Revision as of 10:55, 25 May 2006 (view source)Jola (Talk | contribs) Newer edit \u2192 Line 1: Line 1: + The Yap correction consists of a modifification of the epsilon equation in the form of an extra source term, $S_\\epsilon$, added to the right hand side of the epsilon equation. The source term can be written as: + + :$\\rho S_\\epsilon = 0.83 \\, \\rho \\, \\frac{\\epsilon^2}{k} \\, \\left(\\frac{k^{1.5}}{\\epsilon \\, l_e} - 1 \\right) \\, \\left(\\frac{k^{1.5}}{\\epsilon \\, l_e} \\right)^2$ + + Where + + :$l_e \\equiv c_\\mu^{-0.75} \\, \\kappa \\, y_n$ + + The Yap correction is active in nonequilibrium flows and tends to reduce the departure of the turbulence length scale from its local equilibrium level. + + Yap showed strongly improved results with the k-epsilon model in separated flows when using this extra source term. Launder [[#References|[Launder, B. E. (1993)]]] also recommends that this term should be used with the epsilon equation. + + The Yap source term contains the explicit distance to the nearest wall, $y_n$. In an unstructured 3D solver this distance is usually not available and it can be ambiguous how to compute it in more complex topologies. This makes the Yap correction most suitable for use in a structured code where the normal wall distance is readily available. + ==References== ==References== - {{reference-book|author=Yap, C. J.|year=1987|title=Turbulent Heat and Momentum Transfer in Recirculating and Impinging Flows|rest=PhD thesis, Faculty of Technology, University of Manchester}} + {{reference-paper|author=Launder, B. E.|year=1993|title=Modelling Convective Heat Transfer in Complex Turbulent Flows|rest=Engineering Turbulence Modeling and Experiments 2, Proceedings of the Second International Symposium, Florence, Italy, 31 May - 2 June 1993, Edited by W. Rodi and F. Martelli, Elsevier, 1993, ISBN 0444898026}} + + {{reference-book|author=Yap, C. J.|year=1987|title=Turbulent Heat and Momentum Transfer in Recirculating and Impinging Flows|rest=PhD Thesis, Faculty of Technology, University of Manchester, United Kingdom}}\n\n## Revision as of 10:55, 25 May 2006\n\nThe Yap correction consists of a modifification of the epsilon equation in the form of an extra source term, $S_\\epsilon$, added to the right hand side of the epsilon equation. The source term can be written as:\n\n$\\rho S_\\epsilon = 0.83 \\, \\rho \\, \\frac{\\epsilon^2}{k} \\, \\left(\\frac{k^{1.5}}{\\epsilon \\, l_e} - 1 \\right) \\, \\left(\\frac{k^{1.5}}{\\epsilon \\, l_e} \\right)^2$\n\nWhere\n\n$l_e \\equiv c_\\mu^{-0.75} \\, \\kappa \\, y_n$\n\nThe Yap correction is active in nonequilibrium flows and tends to reduce the departure of the turbulence length scale from its local equilibrium level.\n\nYap showed strongly improved results with the k-epsilon model in separated flows when using this extra source term. Launder [Launder, B. E. (1993)] also recommends that this term should be used with the epsilon equation.\n\nThe Yap source term contains the explicit distance to the nearest wall, $y_n$. In an unstructured 3D solver this distance is usually not available and it can be ambiguous how to compute it in more complex topologies. This makes the Yap correction most suitable for use in a structured code where the normal wall distance is readily available.\n\n## References\n\nLaunder, B. E. (1993), \"Modelling Convective Heat Transfer in Complex Turbulent Flows\", Engineering Turbulence Modeling and Experiments 2, Proceedings of the Second International Symposium, Florence, Italy, 31 May - 2 June 1993, Edited by W. Rodi and F. Martelli, Elsevier, 1993, ISBN 0444898026.\n\nYap, C. J. (1987), Turbulent Heat and Momentum Transfer in Recirculating and Impinging Flows, PhD Thesis, Faculty of Technology, University of Manchester, United Kingdom.","date":"2016-12-02 23:26:23","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 4, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.8497717976570129, \"perplexity\": 2456.0721350997055}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2016-50\/segments\/1480698540698.78\/warc\/CC-MAIN-20161202170900-00003-ip-10-31-129-80.ec2.internal.warc.gz\"}"}
null
null
Hey everyone, my book is finally here. I just got advanced copies of "From the Sandbox to the Corner Office", (http://www.sandboxbook.com) which includes 55 interviews I did with CEOs and leaders from all walks of life about the screw ups and missteps they've made during their careers, and the lessons they learned during childhood from parents who spanked them and the first jobs they held. It's weird finally having the book in my hand. It took about two years from the time I came up with the idea to right now – me sitting here, holding this book in my hand. Am I dreaming? A book, with chapters, and a tiny photo of me. I'm going to be in the library some day. Cool! My dad's birthday was this past Monday and this book would have made an awesome gift for him if he was still alive. He was always my biggest advocate, pushing me to try harder, to go after my dreams. I wish he was here to give me one of those I'm-so-proud-of-you hugs, the kind that stops your breathing for a second. There's a lot in the book that makes me think about my own childhood and work life. I have a whole chapter in my book about how the CEOs survived bad bosses during their careers. And yes, I have quite a few of those stories myself. One of the worst bosses I have ever had comes to mind right now as I look at the book sitting atop my desk. He was a mean-spirited unhappy individual who was a tyrant to his workers, but bleated like a sheep whenever the higher ups said Boo. Well buddy, turns out I did. Lesson learned – Don't listen to naysayers. Just follow your dreams and let them eat cake. Epilogue: Just in case the bad boss didn't catch my book on Amazon.com, I had my publisher send him a copy.
{ "redpajama_set_name": "RedPajamaC4" }
1,084
'U.S. has officially left the Paris Agreement' 7th Nov, 2020 The United States has officially withdrawn from the Paris Agreement, the landmark international accord to keep climate change in check and limit future greenhouse gas emissions. After a three-year delay, the US has become the first nation in the world to formally withdraw from the Paris climate agreement. President Trump announced the move in June 2017, but UN regulations meant that his decision only takes effect from now onwards. The delay is down to the complex rules that were built into the Paris agreement to cope with the possibility that a future US president might decide to withdraw the country from the deal. The US could re-join it in future, should a president choose to do so. What is Paris Agreement? The landmark deal, struck in 2015, aims to limit global warming to "well below" 2 °C above pre-industrial temperatures. The agreement came into force on November 4, 2016 and 189 countries have adopted it. The Paris accord requires countries to set their own voluntary targets for reducing greenhouse gases such as carbon dioxide, and to steadily increase those goals every few years. The only binding requirement is that nations have to accurately report on their efforts. Crucially, under the Paris agreement countries for the first time had declared national action plans known as 'Intended Nationally Determined Contributions' (INDC) outlining targets to cut greenhouse gas emissions. Though these are not legally binding, they are based on the principle of Common but Differentiated Responsibilities (CBDR), recognising that the obligations of developing countries have to be viewed in the context of their economic and social limitations. Under the agreement, developed countries had also made key commitments to provide finances for the Green Climate Fund, established under the United Nations Framework Convention on Climate Change (UNFCCC). This body approves funding for projects in countries that are vulnerable to the impacts of climate change in the form of storms, heat waves and extreme rainfall. What is the concern? The U.S. is currently the second-highest greenhouse gas emitter in the world. It's responsible for spewing more than 5 billion metric tons of carbon dioxide a year since 1990, to say nothing of other potent planet-warming gases, such as methane or hydrofluorocarbons. The country is number one in overall "historical" emissions, however: the source of 25 percent of all human-produced greenhouse gases that have collected in the atmosphere since the Industrial Revolution. The U.S. is now the only major country in the world not committed to the accord, which aims to keep global temperatures from rising more than 3.6 degrees Fahrenheit (2 degrees Celsius) above pre-industrial temperatures. Which countries are taking the lead on climate-change mitigation? China and the European Union have picked up the pieces. China to become carbon neutral (by 2060): In September, China, the world's top emitter of greenhouse gases, announced a bold plan to make its economy carbon neutral by 2060, using a combination of renewable energy, nuclear power and carbon capture. EU's Green Deal: Likewise, the EU's Green Deal, first announced in December 2019, sets out a road map for making the bloc carbon neutral by 2050. Compared with 1990 levels, the EU has already reduced its greenhouse-gas emissions by 24%. Legislation intended to achieve full carbon neutrality by the middle of the century is under discussion. Other major economies, such as Japan and South Korea, pledged last month to become carbon neutral by 2050, but haven't spelt out in detail how they will achieve it. In all, more than 60 countries worldwide — including all EU member states except Poland — have committed to achieving net-zero emissions by mid-century. What will the withdrawal mean in practice? While the US now represents around 15% of global greenhouse gas emissions, it remains the world's biggest and most powerful economy. So when it becomes the only country to withdraw from a global solution to a global problem it raises questions of trust. Although this has been a long time coming, there is still a palpable sense of disappointment for many Americans who believe that climate change is the biggest global challenge and the US should be leading the fight against it. The formal withdrawal has also re-opened old wounds for climate diplomats. What does this mean for India and its efforts to fight climate change? In 2015, India played a crucial role in shaping the agreement through the BRICS (Brazil, Russia, India, China, South Africa) and LMDC (Like-Minded Developing Countries) country groups. In October 2015, ahead of the annual Conference of Parties in Paris, India had announced its ambitious INDCs. It pledged a reduction in its emissions intensity of its Gross Domestic Product by 33 to 35 per cent by 2030, below 2005 levels. Crucially, it announced that by 2030, it would increase the share of non-fossil fuels in the installed energy capacity to 40 per cent. Further, it set a target of creating an additional carbon sink to absorb 2.5 to 3 billion tonnes of carbon dioxide by increasing its forest and tree cover by 2030. India's climate action goals will continue as per plan even as they termed the US exit as a move that would lead to problems in cutting emissions globally. How will it impact the climate? The world has already warmed 1.2 degrees Celsius (2.2 degrees Fahrenheit) since pre-industrial time, so the efforts are really about preventing another 0.3 to 0.7 degrees Celsius (0.5 to 1.3 degrees Fahrenheit) warming from now. "Having the U.S. pull out of Paris is likely to reduce efforts to mitigate, and therefore increase the number of people who are put into a life-or-death situation because of the impacts of climate change: this is clear from the science, What's next now? Parties to the Paris accord have agreed to update their targets for 2030 in line with the latest evidence on the world's remaining carbon budget. A special reportfrom the Intergovernmental Panel on Climate Change (IPCC) on keeping warming to 1.5 °C, completed in 2018, made clear that the climate targets that countries think they can meet are not sufficient to halt global warming. All remaining parties to the agreement must submit their new 2030 targets before the next major United Nations climate meeting, set to take place in Glasgow, UK, in November 2021. The US withdrawal, if it is sustained by the next administration, will inevitably cause some countries to reduce their level of effort on implementing existing commitments. Climate change is a very important issue and world action is needed. The world leaders need to come forward and be compliant with the Paris Agreement.
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
794
\section{Introduction} \label{intro} In this work, we consider the following system of stochastic integral equations on the plane with additive noise: \begin{align}\label{eqmainre1} X_{s,t}-X_{s,0}-X_{0,t}+X_{0,0}=\int_0^t\int_0^sb(\xi,\zeta,X_{\xi,\zeta})\mathrm{d}\xi\mathrm{d}\zeta+W_{s,t} \text{ for }(s,t)\in\mathbb{R}_+^2, \end{align} where $b:\mathbb{R}_+^2\times \mathbb{R}^d\to\mathbb{R}^d$ is Borel measurable satisfying some conditions that will be specified later and $W=(W_{s,t},(s,t)\in\mathbb{R}_+^2)$ is a $d$-dimensional Brownian sheet given on a filtered probability space $(\Omega,\mathcal{F},(\mathcal{F}_{s,t},(s,t)\in\mathbb{R}_+^2),\mathbb{P})$ with $\partial W=0$, where $\partial W$ stands for the restriction of $W$ to the boundary $\partial D=\{0\}\times\mathbb{R}_+\cup\mathbb{R}_+\times\{0\}$ of $D=\mathbb{R}_+^2$. We endow $D$ with the partial order ``$\preceq$" (respectively ``$\prec$") defined by $$ (s,t)\preceq(s^{\prime},t^{\prime})\text{ when }s\leq s^{\prime}\text{ and }t\leqt^{\prime}, $$ respectively $$ (s,t)\prec(s^{\prime},t^{\prime})\text{ when } s<s^{\prime}\text{ and }t<t^{\prime}. $$ Observe that \eqref{eqmainre1} is a particular case of the more general non-Markovian type equation \begin{align}\label{eqmainre2} & X_{s,t}-X_{s,0}-X_{0,t}+X_{0,0}\nonumber\\ &=\int_0^t\int_0^sb(\xi,\zeta,X_{\xi,\zeta})\mathrm{d}\xi\,\mathrm{d}\zeta+\int_0^t\int_0^sa(\xi,\zeta,X_{\xi,\zeta})\,\mathrm{d}W_{\xi,\zeta} \text{ for }(s,t)\in\mathbb{R}_+^2, \end{align} where $a:\,\mathbb{R}_+^2\times\mathbb{R}^d\to\mathbb{R}^d\times\mathbb{R}^d$ is a Borel measurable matrix function. Note that \eqref{eqmainre2} appears as an integral equation when one rewrites the following quasilinear stochastic hyperbolic differential equation \begin{align}\label{eqmainre2b} \frac{\partial^2 X_{s,t}}{\partial s\partial t}=b(s,t,X_{s,t})+a(s,t,X_{s,t})\frac{\partial^2 W_{s,t}}{\partial s\partial t}, \end{align} where the notation ``$\frac{\partial^2 W_{s,t}}{\partial s\partial t}$'' designates a white noise on $D$. As pointed out by Farr\'e and Nualart \cite{FaNu93} (see also \cite{QuTi07}), a formal $\frac{\pi}{4}$ rotation transforms \eqref{eqmainre2b} into a nonlinear stochastic wave equation. This idea, thanks to Walsh \cite{Wa78}, has been used by Carmona and Nualart \cite{CaNu88} to provide existence and uniqueness results for the 1-dimension stochastic wave equation \begin{align}\label{eqmainre2c} \frac{\partial^2 Y}{\partial t^2}(t,x)-\frac{\partial^2 Y}{\partial x^2}(t,x)=a(Y(t,x))\dot{W}(t,x)+b(Y(t,x)) \end{align} with some initial conditions $Y(0,\cdot)$ and $\dfrac{\partial Y}{\partial t}(0,\cdot)$, where $t$ varies in $\mathbb{R}_+$, $x$ varies in $\mathbb{R}$ and $\dot{W}$ denotes a white noise in time as well as in space. Reformulation of \eqref{eqmainre2c} using a $\frac{\pi}{4}$ rotation allows use of the rectangular increments of both $t$ and $x$ (see e.g. \cite[Section 1]{QuTi07}). The problem \eqref{eqmainre1} can also be interpreted as a noisy analog of the so-called Darboux problem given by \begin{align}\label{eqdarboux1} \frac{\partial^2y}{\partial s\partial t}=b\Big(s,t,y,\frac{\partial y}{\partial s},\frac{\partial y}{\partial t}\Big) \quad\text{for }(s,t)\in[0,T]\times[0,T], \end{align} with the initial conditions \begin{align}\label{eqdarboux2} y(0,t)=\sigma(t)\,\text{ on }[0,T]\,\text{ and }\,y(s,0)=\tau(s)\,\text{ on }[0,T], \end{align} where $\sigma$ and $\tau$ are absolutely continuous on $[0,T]$. Using Caratheodory's theory of differential equations, Deimling \cite{De70} proved an existence theorem for the system \eqref{eqdarboux1}-\eqref{eqdarboux2} when $b$ is Borel measurable in the first two variables and bounded and continuous in the last three variables. Existence and uniqueness of solutions to stochastic differential equations (SDEs) driven by a Brownian sheet has been widely studied. In the time homogeneous case, Cairoli \cite{Ca72} proved that \eqref{eqmainre2} has a unique strong solution when the coefficients are Lipschitz continuous. This result was generalised to the time dependent coefficients by Yeh \cite{Ye81} under an additional growth condition. Weak existence of solutions to \eqref{eqmainre2} was derived in \cite{Ye85} assuming that the coefficients are continuous, satisfy a growth condition and the initial value has moment of order six. In all of the above mentioned works, the coefficients are at least continuous. Nualart and Tindel \cite{NuTi97}, show that \eqref{eqmainre2} has a unique strong solution when the drift is nondecreasing and bounded. Their results were extended to SDEs driven by two parameter martingales in \cite{NuTi98} (see also \cite{CaNu88,FaNu93} for further extensions). In \cite{ENO03}, the authors generalised the above results to SDEs driven by a fractional Brownian sheet. In this work we are concerned with a different uniqueness question. In particular, we look at the notion of path-by-path uniqueness introduced by Davie \cite{Da07} (see also Flandoli \cite{Fla10}). Let $\mathcal{V}$, resp. $\partial \mathcal{V}$ be the space of continuous $\mathbb{R}^d$-valued functions on $D$, resp. $\partial D$. The following definition can be seen as a counterpart of \cite[Definition 1.5]{Fla10} in the case of two parameter processes. \begin{defi}\label{defipathbpath} We say that the path-by-path uniqueness of solutions to \eqref{eqmainre1} holds when there exists a full $\mathbb{P}$-measure set $\Omega_0\subset\Omega$ such that for all $\omega\in\Omega_0$ the following statement is true: there exists at most one function $y\in\mathcal{V}$ which satisfies $$\int_0^T\int_0^T|b(\xi,\zeta,y_{\xi,\zeta})|\mathrm{d}\xi \mathrm{d}\zeta<\infty,\text{ }\partial y=x,\text{ for some }x\in\partial \mathcal{V}\text{ and }T>0$$ and \begin{align}\label{eqmainpathbypath} y_{s,t}=x+\int_0^s\int_0^tb(\xi,\zeta,y_{\xi,\zeta})\mathrm{d}\xi \mathrm{d}\zeta+W_{s,t}(\omega),\text{ }\forall\,(s,t)\in[0,T]^2. \end{align} \end{defi} One of the motivations for studying path-by-path uniqueness comes from the regularisation by noise of random ODEs. For instance, let $v$ be a continuous function and let us consider the following one parameter equation in $\mathbb{ R}^d$ $$ X_t=X_0+\int_0^tb (s, X_s)\mathrm{d}s +v_t. $$ We know that there exists a unique solution to the above equation when $b$ is Lipschitz in $x$, uniformly in $t$, with uniform linear growth. Observe that uniqueness also holds when $b$ is only locally Lipschitz. Under some weak conditions on $b$ the corresponding equation without $v$ might be ill-posed or uniqueness could not be valid. For example when $b$ is merely bounded and measurable one may ask if there is a notion of uniqueness if $v$ has some specific features. In other words, can we find a path $v$ that regularises the equation? The result obtained in \cite{Da07} shows that when $b\in L^\infty$, the Brownian path regularises the drift $b$ in the sense of Definition \ref{defipathbpath}. In addition, as shown in \cite[Section 1.8.5]{BFGM14}, path-by-path uniqueness is much stronger than pathwise uniqueness. Indeed Shaposhnikov and Wresch \cite[Section 4]{ShWr20} exhibit SDEs such that strong solutions exist, pathwise uniqueness holds and path-by-path uniqueness fails to hold. This is another motivation for studying path-by-path uniqueness even when pathwise uniqueness holds. In the case of Brownian motion, when the drift is bounded and measurable, and the diffusion is reduced to the identity, the path-by-path uniqueness of equation \eqref{eqmainre2} was proved by Davie in \cite{Da07}. This result was extended in several directions. For non-constant diffusion, Davie in \cite{DavieM} proved path-by-path uniqueness of solution to \eqref{eqmainre2}, interpreting the equation in the rough path sense. In \cite{CG16}, the authors showed that path-by-path uniqueness holds if the Brownian motion is replaced by a $d$-dimensional fractional Brownian motion of Hurst parameter $H\in(0,1)$. It is also assumed that the drift $b$ can be merely a distribution as long as $H$ is sufficiently small. In \cite{Pri18}, Priola considered equations driven by a L\'evy process assuming that the drift is H\"older continuous (see \cite{Pri19} for the non-constant diffusion coefficient case). Path-by-path uniqueness is closely related to the regularisation by noise problem for ordinary (or partial) differential equations (ODEs or PDEs) which has recently drawn a lot of attention. Beck, Flandoli, Gubinelli and Maurelli \cite{BFGM14} proved a Sobolev regularity of solutions to the linear stochastic transport and continuity equations with drift in critical $L^p$ spaces. Such a result does not hold for the corresponding deterministic equations. Butkovsky and Mytnik \cite{BM16} analysed the regularisation by noise phenomenon for a non-Lipschitz stochastic heat equation and proved path-by-path uniqueness for any initial condition in a certain class of a set of probability one. Amine, Mansouri and Proske \cite{AMP20} investigated path-by-path uniqueness for transport equations driven by the fractional Brownian motion of Hurst index $H<1/2$ with bounded vector-fields. In \cite{CG16,GG21} the authors solved the regularisation by noise problem from the point of view of additive perturbations. In particular, Galeati and Gubinelli \cite{CG16} considered generic perturbations without any specific probabilistic setting. Amine, Ba{\~n}os and Proske \cite{ABP17a} constructed a new Gaussian noise of fractional nature and proved that it has a strong regularising effect on a large class of ODEs. More recently, Harang and Perkowski \cite{HP21} studied the regularisation by noise problem for ODEs with vector fields given by Schwartz distributions and proved that if one perturbs such an equation by adding an infinitely regularising path, then it has a unique solution. Kremp and Perkowski \cite{KP20a} looked at multidimensional SDEs with distributional drift driven by symmetric $\alpha$-stable L\'evy processes for $\alpha\in(1,2]$. In all of the above mentioned works, the driving noise considered are one parameter processes. In what follows, we make use of the Girsanov theorem to show that the path-by-path uniqueness in our setting is equivalent to the uniqueness of a random ODE on the plane. For any $x\in\partial \mathcal{V}$ and any $\omega$ such that the path $(s,t)\longmapsto W_{s,t}$ is continuous, we denote by $S(x,\omega)$ the set of functions in $\mathcal{V}$ that solve \eqref{eqmainpathbypath}. Under linear growth and monotonicity conditions on $b$, we prove that $S(x,\omega)$ has at most one element. By a vector translation argument, it suffices to show that $S(0,\omega)$ has no more than one element. As in \cite[Section 1]{Da07}, we show the path-by-path uniqueness on $D^1=[0,1]^2$. Precisely, we consider the integral equation \begin{align}\label{eqmainre1b} X_{s,t}-X_{s,0}-X_{0,t}+X_{0,0}=\int_0^t\int_0^sb(\xi,\zeta,X_{\xi,\zeta})\mathrm{d}\xi\mathrm{d}\zeta+W_{s,t} \text{ for }(s,t)\in D^1, \end{align} where the drift is of spatial linear growth. There is no loss of generality in reducing the problem to $D^1$ since we can repeat the argument on any square $[m,m+1]\times[\ell,\ell+1]$, $(m,\ell)\in\mathbb{N}^2$, $m>0$. We first suppose that $b$ is bounded and monotone. Let $\mathcal{V}^1$ be the space of continuous $\mathbb{R}^d$-valued functions on $D^1$ and let $\mathcal{V}^1_0$ be the space of functions $y\in\mathcal{V}^1$ with $\partial y=0$, where $\partial y$ is the restriction of $y$ to $\partial D^1$ ($\partial D^1=\{0\}\times[0,1]\cup[0,1]\times\{0\}$). Let $\mathbb{P}$ be the law of an $\mathbb{R}^d$-valued Brownian sheet on $D^1$ which vanishes on $\partial D^1$. The function $L$ given by \begin{align*} L(y)=\exp\Big(\int_0^1\int_0^1b(\xi,\zeta,y_{\xi,\zeta}) \mathrm{d}y_{\xi,\zeta}-\frac{1}{2}\int_0^1\int_0^1|b(\xi,\zeta,y_{\xi,\zeta})|^2\mathrm{d}\xi \mathrm{d}\zeta\Big) \end{align*} is well-defined for $\mathbb{P}$-a.e. $y\in \mathcal{V}^1_0$. Moreover, if $y\in \mathcal{V}^1_0$ is chosen random, with law $\mathrm{d}\widetilde{\mathbb{P}}=L\mathrm{d}\mathbb{P}$, then, by Girsanov theorem (see for example \cite{Ca72, DM15, Im88}), the path $W$ defined by \begin{align}\label{eqPathGirsanov} W_{s,t}=y_{s,t}-\int_0^s\int_0^tb(\xi,\zeta,y_{\xi,\zeta})\mathrm{d}\xi \mathrm{d}\zeta \end{align} has law $\mathbb{P}$. This means that $y$ is a solution to \eqref{eqmainre1b} with $W$ defined by \eqref{eqPathGirsanov}. Path-by-path uniqueness of solutions to \eqref{eqmainre1b} holds if and only if for $\widetilde{\mathbb{P}}$-a.e. $y\in \mathcal{V}^1_0$, $z=y$ is the only solution to \begin{align*} W_{s,t}=z_{s,t}-\int_0^s\int_0^tb(\xi,\zeta,z_{\xi,\zeta})\mathrm{d}\xi \mathrm{d}\zeta \end{align*} with $W$ given by \eqref{eqPathGirsanov}, which is equivalent to saying that for $\widetilde{\mathbb{P}}$-a.e. $y\in \mathcal{V}^1_0$, the only solution to \begin{align}\label{eqOnPathbyPath} u(s,t)=\int_0^s\int_0^t\{b(\xi,\zeta,y_{\xi,\zeta}+u(\xi,\zeta))-b(\xi,\zeta,y_{\xi,\zeta})\}\mathrm{d}\xi \mathrm{d}\zeta \end{align} is $u=0$ (see e.g. \cite[Section 1]{Da07}). Since $\widetilde{\mathbb{P}}$ is absolutely continuous with respect to $\mathbb{P}$, it is enough to show that, if $W$ is an $\mathbb{R}^d$-valued Brownian sheet, then, with probability one, there is no nontrivial solution $u\in \mathcal{V}^1_0$ of \begin{align*} u(s,t)=\int_0^s\int_0^t\{b(\xi,\zeta,W_{\xi,\zeta}+u(\xi,\zeta))-b(\xi,\zeta,W_{\xi,\zeta})\}\mathrm{d}\xi \mathrm{d}\zeta. \end{align*} This is the statement of Theorem \ref{maintheuniq2} which is extended to unbounded monotone drifts in Theorem \ref{maintheuniq1}. Our proof of Theorem \ref{maintheuniq2} relies on some estimates for an averaging operator along the sheet (see Lemma \ref{lem:PseudoMetric1}). This result plays a key role in the proof of a Gronwall type lemma (see Lemma \ref{lem:GronwallSheetd}) which enables us to prove path-by-path uniqueness of solutions to \eqref{eqmainre1}. The Yamada-Watanabe principle for one dimensional SDEs driven by Brownian sheets was derived in \cite{NuYe89} (see also \cite{Ye87}). More precisely, the authors show that combining weak existence and pathwise uniqueness yields existence of a unique strong solution in the two parameter setting. This result can be extended to the multidimensional case (see e.g. \cite[Remark 2]{Tu83}). When $b$ is of linear growth, we can show (see Lemma \ref{theqweak1}) that the SDE \eqref{eqmainre2} has a weak solution. The latter together with path by path uniqueness (and thus pathwise uniqueness) implies the existence of a unique strong solution to the SDE \eqref{eqmainre2} and therefore generalises some results in \cite{ENO03,NuTi97} to the multidimensional case. To the best of our knowledge, such a result has not been derived in the multidimensional case. The remainder of the paper is structured as follows. In Section \ref{defcon}, we recall some basic definitions and concepts. The main results are stated and proved in Section \ref{sectmasinres}. In section \ref{prelresul}, we prove some preliminary results whereas Section \ref {Auxrel} is devoted to the proof of a number of auxiliary results. \section{Basic definitions and concepts}\label{defcon} In this section we recall some basic definitions and concepts for SDEs on the plane. We start with the definitions of filtered probability space and $d$-dimensional Brownian sheet that can be found in \cite{NuYe89,Ye81}. \begin{defi} We call a filtered probability space any probability space $(\Omega,\mathcal{F},\mathbb{P})$ with a family $(\mathcal{F}_{s,t},(s,t)\in D)$ of sub-$\sigma$-algebras of $\mathcal{F}$ such that \begin{enumerate} \item $\mathcal{F}_{0,0}$ contains all null sets in $(\Omega,\mathcal{F},\mathbb{P})$, \item $\{\mathcal{F}_{s,t},(s,t)\in D\}$ is nondecreasing in the sense that $\mathcal{F}_{s,t}\subset\mathcal{F}_{s^{\prime},t^{\prime}}$ when $(s,t)\prec(s^{\prime},t^{\prime})$, \item $(\mathcal{F}_{s,t},(s,t)\in D)$ is a right-continuous system in the sense that $$ \mathcal{F}_{s,t}=\bigcap\limits_{(s^{\prime},t^{\prime})\prec(s,t)}\mathcal{F}_{s^{\prime},t^{\prime}}. $$ \end{enumerate} \end{defi} \begin{defi} We call a one-dimensional $(\mathcal{F}_{s,t})$-Brownian sheet on a filtered probability space $(\Omega,\mathcal{F},(\mathcal{F}_{s,t},(s,t)\in D),\mathbb{P})$ any real valued two-parameter stochastic process $W^{(0)}=(W^{(0)}_{s,t},(s,t)\in D)$ satisfying the following conditions: \begin{enumerate} \item $W^{(0)}$ is $(\mathcal{F}_{s,t},(s,t)\in D)$-adapted, i.e. $W^{(0)}_{s,t}$ is $\mathcal{F}_{s,t}$-measurable for every $(s,t)\in D$. \item Every sample function $(s,t)\longmapsto W^{(0)}_{s,t}(\omega)$ of $W^{(0)}$ is continuous on $D$. \item For every finite rectangle of the type $\Pi=]s,s^{\prime}]\times]t,t^{\prime}]\subset D$, the random variable $$W^{(0)}(\Pi):=W^{(0)}_{s^{\prime},t^{\prime}}-W^{(0)}_{s,t^{\prime}}-W^{(0)}_{s^{\prime},t}+W^{(0)}_{s,t}$$ is centered, Gaussian with variance $(s^{\prime}-s)(t^{\prime}-t)$ and independent of $\mathcal{F}_{s,1}\vee\mathcal{F}_{1,t}$. \end{enumerate} We call a $d$-dimensional Brownian sheet any $\mathbb{R}^d$-valued two-parameter process $W=(W^{(1)},\ldots,W^{(d)})$ such that $W^{(i)}$, $i=1,\ldots,d$ are independent one-dimensional Brownian sheets. \end{defi} In the following, we discuss the notions of weak and strong solutions to the SDE \eqref{eqmainre2} (see for example \cite[Section 2]{Ye81}). We start with the definition of a weak solution. \begin{defi} A weak solution to the SDE \eqref{eqmainre2} is a system $(\Omega,\mathcal{F},(\mathcal{F}_{s,t}),W,X=(X_{s,t}),\mathbb{P})$ such that \begin{enumerate} \item $(\Omega,\mathcal{F},(\mathcal{F}_{s,t},(s,t)\in D),\mathbb{P})$ is a filtered probability space, \item $W=(W_{s,t},(s,t)\in D)$ is a $d$-dimensional $(\mathcal{F}_{s,t})$-Brownian sheet with $\partial W=0$, \item $X$ is $(\mathcal{F}_{s,t})$-adapted, has continuous sample paths and, $\mathbb{P}$-a.s., \begin{align*} & X_{s,t}-X_{s,0}-X_{0,t}+X_{0,0}\\ &=\int_0^t\int_0^sb(\xi,\zeta,X_{\xi,\zeta})\mathrm{d}\xi\mathrm{d}\zeta+\int_0^t\int_0^sa(\xi,\zeta,X_{\xi,\zeta})\,\mathrm{d}W_{\xi,\zeta},\quad\forall\,(s,t)\in D. \end{align*} \end{enumerate} \end{defi} \begin{remark} When the drift $b$ satisfies a linear growth condition, weak existence holds for \eqref{eqmainre1b} (see Theorem \ref{theqweak1}). \end{remark} We now turn to the notion of strong solution. Let $\mathcal{B}(\mathcal{V})$ (respectively $\mathcal{B}(\partial \mathcal{V})$) be the $\sigma$-algebra of Borel sets in the space $\mathcal{V}$ (respectively $\partial \mathcal{V}$) of all continuous $\mathbb{R}^d$-valued functions on $D$ (respectively $\partial D$) with respect to the metric topology of uniform convergence on compact subsets of $D$. The subsequent definitions are borrowed from \cite{NuYe89}. \begin{defi} Let $\overline{\mathcal{B}(\mathcal{V})}$ be the completion of $\mathcal{B}(\mathcal{V})$ with respect to the Wiener measure $m_\mathcal{V}$ on $(\mathcal{V},\mathcal{B}(\mathcal{V}))$ concentrated on $\mathcal{V}_0$. For every $(s,t)\in D$, we denote by $\mathcal{B}_{s,t}(\mathcal{V})$ the $\sigma$-algebra generated by the cylinder sets of the type $\{w\in \mathcal{V};\,w(\xi,\zeta)\in E\}$ for some $(\xi,\zeta)\preceq(s,t)$ and $E\in\mathcal{B}(R^d)$ and by $\overline{\mathcal{B}_{s,t}(\mathcal{V})}$ the $\sigma$-algebra generated by $\mathcal{B}_{s,t}(\mathcal{V})$ and all the null sets in $(\mathcal{V},\overline{\mathcal{B}(\mathcal{V})},m_\mathcal{V})$. Let $\overline{\mathcal{B}(\partial \mathcal{V}\times \mathcal{V})}^{\lambda\times m_\mathcal{V}}$ be the completion of $\mathcal{B}(\partial \mathcal{V}\times \mathcal{V})$ with respect to the product measure $\lambda\times m_\mathcal{V}$ for any probability measure $\lambda$ on $\partial \mathcal{V}$. \end{defi} \begin{defi}\label{DefiClassTransf} Let $\mathbf{T}(\partial \mathcal{V}\times \mathcal{V})$ be the class of transformations $F$ of $\partial \mathcal{V}\times \mathcal{V}$ into $\mathcal{V}$ which satisfies the condition that for every probability measure $\lambda$ on $(\partial \mathcal{V},\mathcal{B}(\partial \mathcal{V}))$, there exists a transformation $F_{\lambda}$ of $\partial \mathcal{V}\times \mathcal{V}$ into $\mathcal{V}$ such that \begin{enumerate} \item $F_{\lambda}$ is $\overline{\mathcal{B}(\partial \mathcal{V}\times \mathcal{V})}^{\lambda\times m_\mathcal{V}}/\mathcal{B}(\mathcal{V})$ measurable, \item For every $x\in\partial \mathcal{V}$, $F_{\lambda}[x,\cdot]$ is $\overline{\mathcal{B}_{s,t}(\mathcal{V})}/\mathcal{B}_{s,t}(\mathcal{V})$ measurable, for every $(s,t)\in D$, \item There exists a null set $N_{\lambda}$ in $(\partial \mathcal{V},\mathcal{B}(\partial \mathcal{V}),\lambda)$ such that $F[x,w]=F_{\lambda}[x,w]$ for almost all $w$ in $(\mathcal{V},\overline{\mathcal{B}(\mathcal{V})},m_\mathcal{V})$ and all $x\in \partial \mathcal{V}\setminus N_{\lambda}$. \end{enumerate} \end{defi} \begin{defi} Let $(X,W)$ be a weak solution to the SDE \eqref{eqmainre2} on a filtered probability space $(\Omega,\mathcal{F},\{\mathcal{F}_{s,t},(s,t)\in D\},\mathbb{P})$ and let $\lambda$ be the probability distribution of $\partial X$. We call $(X,W)$ a strong solution to \eqref{eqmainre2} if there exists a transformation $F_{\lambda}$ of $\partial \mathcal{V}\times \mathcal{V}$ into $\mathcal{V}$ satisfying Conditions 1 and 2 of Definition \ref{DefiClassTransf} such that \begin{align*} X=F_{\lambda}[\partial X,W]\,\text{ }\mathbb{P}\text{-a.s. on }\Omega. \end{align*} \end{defi} Here is a well known concept of uniqueness associated to strong solutions of \eqref{eqmainre2} provided such solutions exist. \begin{defi} We say that the SDE \eqref{eqmainre2} has a unique strong solution if there exists $F\in\mathbf{T}(\partial \mathcal{V}\times \mathcal{V})$ such that, \begin{enumerate} \item if $(\Omega,\mathcal{F},(\mathcal{F}_{s,t},(s,t)\in D),\mathbb{P})$ is a filtered probability space on which an $\mathbb{R}^d$-valued $(\mathcal{F}_{s,t},(s,t)\in D)$-Brownian sheet $W$ with $\partial W=0$ exists, then for every continuous $(\mathcal{F}_{s,t},(s,t)\in D)$-adapted boundary process $Z$ on $(\Omega,\mathcal{F},(\mathcal{F}_{s,t},(s,t)\in D),\mathbb{P})$ whose probability distribution is denoted by $\lambda$, $(X,W)$ with $X=F(Z,W)$ is a weak solution of \eqref{eqmainre2} with $\partial X=Z$ $\mathbb{P}$-a.s. on $\Omega$. \item if $(X,W)$ is a weak solution of \eqref{eqmainre2} on a filtered probability space $(\Omega,\mathcal{F},(\mathcal{F}_{s,t},(s,t)\in D),\mathbb{P})$ and the probability distribution of $\partial X$ is denoted by $\lambda$, then $X=F_{\lambda}[\partial X,W]$ $\mathbb{P}$-a.s. on $\Omega$. \end{enumerate} \end{defi} There are two classical notions of uniqueness associated to weak solutions (see e.g. \cite[Definitions 1.2 and 1.7]{NuYe89}). \begin{defi} We say that the solution to the SDE \eqref{eqmainre2} is unique in the sense of probability distribution if whenever $(X,W)$ and $(X^{\prime},W^{\prime})$ are two solutions of \eqref{eqmainre2} on two possibly different filtered probability spaces and $\partial X=x=\partial X^{\prime}$ for some $x\in\partial \mathcal{V}$, then $X$ and $X^{\prime}$ have the same probability distribution on $(\mathcal{V},\mathcal{B}(\mathcal{V}))$. \end{defi} \begin{defi} We say that the pathwise uniqueness of solutions to the SDE \eqref{eqmainre2} holds if whenever $(X,W)$ and $(X^{\prime},W)$ with the same $W$ are two solutions to \eqref{eqmainre2} on the same probability space and $\partial X=\partial X^{\prime}$, then $X=X^{\prime}$ for $\mathbb{P}$-a.e. $\omega\in\Omega$. \end{defi} \section{Main results}\label{sectmasinres} In this section, we present the main results of this paper. We assume the following conditions on the drift: \begin{hyp}\label{hyp1}\leavevmode \begin{enumerate} \item $b:[0,1]^2\times \mathbb{R}^d\rightarrow \mathbb{R}^d$ is a Borel measurable function satisfying the spatial linear growth condition, that is, there exists a constant $M$ such that $$ |b(t,s,x)|\leq M(1+|x|) \text{ for all } x\in \mathbb{R}^d. $$ \item $b$ is componentwise nondecreasing in space, that is, each component $(b_i)_{1\leq i\leq d}$ is componentwise nondecreasing in space. More precisely for $x,y \in \mathbb{R}^d$, we have: $$ x\preceq y \Rightarrow b_i(x)\leq b_i(y), 1\leq i\leq d, $$ where $x\preceq y$ means $x_i\leq y_i$ for all $i\in\{1,\ldots,d\}$. \end{enumerate} \end{hyp} \begin{theorem}\label{maintheuniq1} Suppose $b$ satisfies Hypothesis \ref{hyp1}. Then for almost every Brownian sheet path $W$, there exists a unique continuous function $X :[0,1]^2\rightarrow \mathbb{R}^d$ satisfying \eqref{eqmainre1b}. \end{theorem} \begin{corollary} Suppose $b$ is as in Theorem \ref{maintheuniq1}. Then the SDE \eqref{eqmainre1b} admits a unique strong solution. \end{corollary} \begin{proof} It follows from the fact that under the conditions of the Corollary, \eqref{eqmainre1b} has a weak solution. In addition, since path-by-path uniqueness implies pathwise uniqueness (see \cite[Page 9, Section 1.8.4]{BFGM14}), the result follows from the Yamada-Watanabe type principle for SDEs driven by Brownian sheets (see e.g. Nualart and Yeh \cite{NuYe89}). \end{proof} The proof of Theorem \ref{maintheuniq1} relies on the following theorem \begin{theorem}\label{maintheuniq2} Suppose $b$ is as in Theorem \ref{maintheuniq1}. Suppose in addition that $b$ is uniformly bounded. Then for almost every Brownian sheet path $W$, there exists a unique continuous function $X :[0,1]^2\rightarrow \mathbb{R}^d$ satisfying \eqref{eqmainre1b}. \end{theorem} Recall that using the Girsanov theorem, path-by-path uniqueness holds if there exists $\Omega_1\subset\Omega$ with $\mathbb{P}(\Omega_1)=1$ such that for any $\omega\in\Omega_1$, there is no nontrivial solution $u \in C([0,1]^2,\mathbb{R}^d)$ to the following system of integral equations \begin{align}\label{eq:IntPathByPath} u(s,t)=\int_0^t\int_0^s\{b(\xi,\zeta,W_{\xi,\zeta}(\omega)+u(\xi,\zeta))-b(\xi,\zeta,W_{\xi,\zeta}(\omega))\}\mathrm{d}\xi\mathrm{d}\zeta,\text{ }\forall\,(s,t)\in[0,1]^2. \end{align} Let us also consider the set $\mathbf{Q}=[-1,1]^d$ and its dyadic decomposition. Recall that $x\in\mathbf{Q}$ is called a dyadic number if it is a rational with denominator a power of $2$. The next theorem is equivalent to Theorem \ref{maintheuniq2}. \begin{theorem}\label{theo:DavieSheetMonotoneD} Let $W:=\left(W_{s,t},(s,t)\in[0,1]^2\right)$ be a $d$-dimensional Brownian sheet defined on a filtered probability space $(\Omega,\mathcal{F},\mathbb{F},\mathbb{P})$, where $\mathbb{F}=(\mathcal{F}_{s,t};s,t\in[0,1])$. Let $b$ be as in Theorem \ref{maintheuniq2}. Then there exists $\Omega_1\subset\Omega$ with $\mathbb{P}(\Omega_1)=1$ such that for any $\omega\in\Omega_1$, $u=0$ is the unique solution in $\mathcal{V}_0$ to the system of integral equations \eqref{eq:IntPathByPath}. \end{theorem} The proof of Theorem \ref{theo:DavieSheetMonotoneD} is carried out in two main steps. In the first step, we use a two-parameter Wiener process to regularise \eqref{eq:IntPathByPath} on dyadic intervals. In the second step we show a Gronwall type lemma (see Lemma \ref{lem:GronwallSheetd}). The regularisation is as follows: For any positive integer $n$, we divide $[0,1]$ into $2^{n}$ intervals $I_{n,k}=]k2^{-n},(k+1)2^{-n}]$ and define $\varrho_{nkk^{\prime}}$ by \begin{align*} \varrho_{nkk^{\prime}}(x,y):=\int_{I_{n,k^{\prime}}}\int_{I_{n,k}}\{b(s,t,W_{s,t}+x)-b(s,t,W_{s,t}+y)\}\,\mathrm{d}t\mathrm{d}s. \end{align*} The next three lemmas whose proofs are given in Section \ref{Auxrel} provide an estimate for $\varrho_{nkk^{\prime}}(x,y)$ and $\varrho_{nkk^{\prime}}(0,x)$ for every dyadic numbers $x,y\in\mathbf{Q}$. Lemmas \ref{lem:PseudoMetric1} and \ref{lem:PseudoMetric2} are counterparts of Lemmas 3.1 and 3.2 in \cite{Da07} for the Brownian sheet. The proof of Lemma \ref{lem:PseudoMetric1} uses the local time-space integration formula for the Brownian sheet as given in \cite{BDM21}. Lemma \ref{lem:PseudoMetric3} follows from Lemma \ref{lem:PseudoMetric2} using the fact that the set of dyadic numbers is dense in $\mathbb{R}$ \begin{lemma}\label{lem:PseudoMetric1} Suppose $b:\,[0,1]^2\times\mathbb{R}^d\to\mathbb{R}$ is a Borel measurable function such that $|b(s,t,x)|\leq1$ everywhere on $[0,1]^2\times\mathbb{R}^d$. Then there exists a subset $\Omega_{1}$ of $\Omega$ with $\mathbb{P}(\Omega_{1})=1$ such that for all $\omega\in\Omega_1$, \begin{align*} |\varrho_{nkk^{\prime}}(x,y)(\omega)|\leq C_1(\omega)2^{-n}\Big[\sqrt{n}+\Big(\log^+\frac{1}{|x-y|}\Big)^{1/2}\Big]|x-y|\,\text{ on }\Omega_{1} \end{align*} for all dyadic numbers $x,\,y\in\mathbf{Q}$ and all choices of integers $n,\,k,\,k^{\prime}$ with $n\geq1$, $0\leq k,k^{\prime}\leq 2^n-1$, where $C_1(\omega)$ is a positive random constant that does not depend on $x$, $y$, $n$, $k$ and $k^{\prime}$. \end{lemma} \begin{lemma}\label{lem:PseudoMetric2} Suppose $b$ is as in Lemma \ref{lem:PseudoMetric1}. Then there exists a subset $\Omega_{2}$ of $\Omega$ with $\mathbb{P}(\Omega_{2})=1$ such that for all $\omega\in\Omega_2$, for any choice of $n,\,k,\,k^{\prime}$, and any choice of a dyadic number $x\in\mathbf{Q}$ \begin{align}\label{eq:coPseudoMetric2} \left|\varrho_{nkk^{\prime}}(0,x)(\omega)\right|\leq C_{2}(\omega)\sqrt{n}2^{-n}\Big(|x|+2^{-4^{n}}\Big), \end{align} where $C_2(\omega)$ is a positive random constant that does not depend on $x$, $n$, $k$ and $k^{\prime}$. \end{lemma} Observe that the proofs of the above two results do not require the monotonic argument on the drift $b$. \begin{lemma}\label{lem:PseudoMetric3} Suppose $b$ is as in Theorem \ref{maintheuniq2}. Let $\Omega_2$ be a subset of $\Omega$ such that, for any $\omega\in\Omega_2$, \eqref{eq:coPseudoMetric2} holds for every $n,\,k,\,k^{\prime}$, and every dyadic number $x\in\mathbf{Q}$. Then \begin{align*} \left|\varrho_{nkk^{\prime}}(0,x)(\omega)\right|\leq \widetilde{C}_{2}(\omega)\sqrt{n}2^{-n}\Big(|x|+2^{-4^{n}}\Big) \end{align*} for any $\omega\in\Omega_2$, any $n$, $k$, $k^{\prime}$, and any $x\in\mathbf{Q}$, where $\widetilde{C}_2(\omega)$ is a positive random constant that does not depend on $x$, $n$, $k$ and $k^{\prime}$. \end{lemma} The subsequent result is a Gronwall type lemma and constitutes the main result in the second step of the proof of Theorem \ref{theo:DavieSheetMonotoneD}. Its proof is found in Section 5. \begin{lemma}\label{lem:GronwallSheetd} Let $W:=\Big(W^{(1)}_{s,t},\ldots,W^{(d)}_{s,t};(s,t)\in[0,1]^2\Big)$ be a $d$-dimensional Brownian sheet defined on a filtered probability space $(\Omega,\mathcal{F},\mathbb{F},\mathbb{P})$, where $\mathbb{F}=(\mathcal{F}_{s,t};(s,t)\in[0,1]^2)$ and let the drift $b$ be as in Theorem \ref{maintheuniq2}. There exists $\Omega_1\subset\Omega$ with $\mathbb{P}(\Omega_1)=1$ and a positive random constant $C_1$ such that for any $\omega\in\Omega_1$, any sufficiently large positive integer $n$, any $(k,k^{\prime})\in\{1,2,\ldots,2^n\}^2$, any $\beta(n)\in\Big[2^{-4^{3n/4}},2^{-4^{2n/3}}\Big]$, and any solution $u$ to the system of integral equations \begin{align}\label{eq:DavieSheetGronwalld} &u_i(s,t)-u_i(s,0)-u_i(0,t)+u_i(0,0)\nonumber\\ &=\int_0^t\int_0^s\{b_i(\xi,\zeta,W_{\xi,\zeta}(\omega)+u(\xi,\zeta))-b_i(\xi,\zeta,W_{\xi,\zeta}(\omega))\}\mathrm{d}\xi\mathrm{d}\zeta, \text{ }\forall\,(s,t)\in[0,1]^2,\,\forall\,i, \end{align} satisfying \begin{equation}\label{eq:GronwallInitialVd} \max\{|u(s,0)|,|u(0,t)|\}\leq\beta(n),\quad\forall\,(s,t)\in[0,1]^2, \end{equation} we have \begin{align}\label{eq:GronwallSheetEstd} \max\{|\overline{u}^{(n)}(k,k^{\prime})|,|\underline{u}^{(n)}(k,k^{\prime})|\}\leq(3\sqrt{d})^{k+k^{\prime}-1}\Big(1+C_1(\omega)\sqrt{dn}2^{-n}\Big)^{k+k^{\prime}}\beta(n)\,\text{ on }\Omega_1, \end{align} where $\overline{u}^{(n)}(k,k^{\prime})=(\overline{u}^{(n)}_1(k,k^{\prime}),\ldots,\overline{u}^{(n)}_d(k,k^{\prime}))$, $\underline{u}^{(n)}(k,k^{\prime})=(\underline{u}^{(n)}_1(k,k^{\prime}),\ldots,\underline{u}^{(n)}_{\,d}(k,k^{\prime}))$, \begin{align*} \overline{u}^{(n)}_i(k,k^{\prime}):=\sup\limits_{(s,t)\in I_{n,k-1}\times I_{n,k^{\prime}-1}}\max\{0,u_i(s,t)\}=\sup\limits_{(s,t)\in I_{n,k-1}\times I_{n,k^{\prime}-1}}u_i^+(s,t),\quad\forall\,i \end{align*} and \begin{align*} \underline{u}^{(n)}_i(k,k^{\prime}):=\sup\limits_{(s,t)\in I_{n,k-1}\times I_{n,k^{\prime}-1}}\max\{0,-u_i(s,t)\}=\sup\limits_{(s,t)\in I_{n,k-1}\times I_{n,k^{\prime}-1}}u_i^-(s,t),\quad\forall\,i. \end{align*} \end{lemma} We are now ready to prove Theorem \ref{theo:DavieSheetMonotoneD}. \begin{proof}[Proof of Theorem \ref{theo:DavieSheetMonotoneD}] We choose $\Omega_1$, $C_1$, $\omega$, $n$ and $\beta(n)$ as in Lemma \ref{lem:GronwallSheetd}. Let $u$ be a solution to \eqref{eq:IntPathByPath}. We have $\max\{|u|(s,0),|u|(0,t)\}=0\leq\beta(n)\text{ for all }(s,t)\in[0,1]^2.$ Moreover, we deduce from (\ref{eq:GronwallSheetEstd}) that \begin{align}\label{eq:GrowllUniqBoundd} \sup\limits_{k,k^{\prime}\in\{0,1,2,\cdots,2^n\}}\max\left\{|\overline{u}^{(n)}(k,k^{\prime})|,|\underline{u}^{(n)}(k,k^{\prime})|\right\}\leq (4\sqrt{d})^{2^{n+1}}\beta(n) \end{align} for all $n$ satisfying $C_1(\omega)\sqrt{dn}2^{-n}\leq1/3$. Since the right side of \eqref{eq:GrowllUniqBoundd} converges to $0$ as $n$ goes to $\infty$, it holds $u(s,t)=0$ on $\Omega_1$ for all $(s,t)$. \end{proof} \begin{proof}[Proof of Theorem \ref{maintheuniq1}] For every positive integer $n$, consider the bounded and nondecreasing function $g_n:\,\mathbb{R}\to\mathbb{R}$ defined by $$g_n(a)= \begin{cases} a \text{ for }|a|<n,\\ n \text{ for } a\geq n,\\ -n \text{ for } a\leq - n. \end{cases} $$ Then for every $n$ and $i$, $g_n\circ b_i$ is a bounded and nondecreasing function. Let $b^{(n)}:\,[0,1]^2\times\mathbb{R}^d\to\mathbb{R}^d$ be the bounded and componentwise nondecreasing function given by $b^{(n)}_i(s,t,x)=g_n(b_i(s,t,x))$ for all $i$, all $(s,t)\in[0,1]^2$ and all $x\in\mathbb{R}^d$. We have $$|b^{(n)}(s,t,x)|\leq M(1+|x|),\quad\forall\,n,\,(s,t)\in[0,1]^2,\,x\in\mathbb{R}^d.$$ It follows from Theorem \ref{maintheuniq2} that for any $n$, there exists an event $\Omega_n$ of full measure, such that for any $\omega\in\Omega_n$, the system of integral equations \begin{align}\label{eq:syst1} X_{s,t}(\omega)=\int_0^t\int_0^sb^{(n)}(\xi,\zeta,X_{\xi,\zeta}(\omega))\mathrm{d}\xi \mathrm{d}\zeta+W_{s,t}(\omega),\quad(s,t)\in[0,1], \end{align} has a unique solution $(X_{s,t}^{(n)}(\omega),0\leq s,t\leq1)$. Moreover, we have \begin{align}\label{eq:abssyst1} \Big|X_{s,t}^{(n)}(\omega)\Big|\leq M\int_0^t\int_0^s\Big|X_{\xi,\zeta}^{(n)}(\omega)\Big|\mathrm{d}\xi \mathrm{d}\zeta+M+|W_{s,t}(\omega)|. \end{align} By the Gronwall inequality for integrals in the plane provided in \cite[Section 2]{Sno72} (see also \cite[Section 1]{Ra76}), it holds \begin{align}\label{ineq:Snow1} \Big|X_{s,t}^{(n)}(\omega)\Big|\leq M+|W_{s,t}(\omega)|+M\int_0^t\int_0^s\Big(M+|W_{\xi,\zeta}(\omega)|\Big)h(\xi,\zeta,s,t)\mathrm{d}\xi \mathrm{d}\zeta \end{align} for all $(s,t)\in[0,1]^2$, where $h$ is the unique solution to \begin{align}\label{eq:Snow1D} h(\xi,\zeta,s,t)=1+M\int_{\xi}^t\int_{\zeta}^sh(\eta,\gamma,s,t)\mathrm{d}\eta \mathrm{d}\gamma,\quad(\xi,\gamma)\in[0,s]\times[0,t]. \end{align} It is known (see for example \cite[Page 145]{Nu06}) that for every $(\xi,\zeta,s,t)$, $h(\xi,\zeta,s,t)=I_0\Big(2\sqrt{M(s-\xi)(t-\zeta)}\Big)$, where $I_0$ is the modified Bessel function of order zero. Since $h$ is nonnegative, we have \begin{align*} \sup\limits_{(s,t)\in[0,1]^2}\Big|X^{(n)}_{s,t}(\omega)\Big|\leq C_1^{\ast}\Big(M+\sup\limits_{(s,t)\in[0,1]^2}|W_{s,t}(\omega)|\Big), \end{align*} with \begin{align*} C_1^{\ast}=1+MI_{0}(2\sqrt{M}). \end{align*} Let $\Omega_{\infty}=\bigcap\limits_{n\geq1}\Omega_n$, then $\mathbb{P}(\Omega_{\infty})=1$. Fix $\omega\in\Omega_{\infty}$ and $n\geq1$ such that \begin{align}\label{eq:SolutionBound} (C_1^{\ast})^2M\Big(1+\sup\limits_{(s,t)\in[0,1]^2}|W_{s,t}(\omega)|\Big)\leq n. \end{align} Since $C_1^{\ast}\geq1+M$, we obtain \begin{align*} \sup\limits_{(s,t)\in[0,1]^2}\Big|b(s,t,X^{(n)}_{s,t}(\omega))\Big|&\leq M\Big(1+\sup\limits_{(s,t)\in[0,1]^2}\Big|X^{(n)}_{s,t}(\omega)\Big|\Big)\\ &\leq M\Big(1+C_1^{\ast}M+C_1^{\ast}\sup\limits_{(s,t)\in[0,1]^2}|W_{s,t}(\omega)|\Big)\leq n. \end{align*} As a consequence, $b^{(n)}(s,t,X^{(n)}_{s,t}(\omega))=b(s,t,X^{(n)}_{s,t}(\omega))$ for every $(s,t)\in[0,1]^2$. Hence $(X^{(n)}_{s,t}(\omega),0\leq s,t\leq1)$ is a solution to the system \begin{align}\label{eq:syst2} X_{s,t}(\omega)=\int_0^t\int_0^sb(\xi,\zeta,X_{\xi,\zeta}(\omega))\mathrm{d}\xi \mathrm{d}\zeta+W_{s,t}(\omega),\quad(s,t)\in[0,1]. \end{align} Let $(y_{s,t},0\leq s,t\leq1)$ be another solution to \eqref{eq:syst2} for the same $\omega\in\Omega_{\infty}$. Then, using once more Gronwall inequality for integrals on the plane, we obtain \begin{align*} \sup\limits_{(s,t)\in[0,1]^2}|y_{s,t}|\leq C_1^{\ast}\Big(M+\sup\limits_{(s,t)\in[0,1]^2}|W_{s,t}(\omega)|\Big). \end{align*} This implies that for $n$ in \eqref{eq:SolutionBound}, $(y_{s,t},0\leq s,t\leq1)$ is also a solution to \eqref{eq:syst1}. Since $\omega\in\Omega_n$, the system \eqref{eq:syst1} has a unique solution for this $\omega$. Thus, $y_{s,t}=X^{(n)}_{s,t}(\omega)$ for every $(s,t)\in[0,1]^2$ and uniqueness is proved. \end{proof} \section{Preliminary results}\label{prelresul} In order to prove the auxiliary lemmas provided in the previous section, we need some preliminary results that have been obtained by applying a local time-space integration formula for Brownian sheets (see \cite{BDM21} for related results). Let us first recall the notion of local time in the plane of the Brownian sheet. Let $(W^{(0)}_{s,t},(s,t)\in D)$ be a one dimensional Brownian sheet given on a filtered probability space. For $s$ fixed, $(W^{(0)}_{s,t},t\in[0,1])$ is a one dimensional Brownian motion and its local time process $(L_1^x(s,t);x\in\mathbb{R},t\geq0)$ is given by the Tanaka's formula (see for example \cite[Section 1]{Wa78}): \begin{align}\label{eq:TanakaSheet1} \int_0^t\mathbf{1}_{\{W^{(0)}_{s,u}\leq x\}}\mathrm{d}_uW^{(0)}_{s,u}=\frac{s}{2}L^x_1(s,t)-(W^{(0)}_{s,t}-x)^{-}+x^{+}. \end{align} For $s\in[0,1]$ fixed, let $\widehat{W}^{(0)}_{s,\cdot}$ be the time reversal process on $[0,1]$ of the Brownian motion $\widehat{W}^{(0)}_{s,\cdot}$ (i.e.,$\widehat{W}^{(0)}_{s,t}=W^{(0)}_{s,1-t}$) and let $(\widehat{L}^x_1(s,t);x\in\mathbb{R},0\leq t\leq1)$ be the local time process of $(\widehat{W}^{(0)}_{s,t},0\leq t\leq 1)$. Then the following holds \begin{align*} \widehat{L}^x_1(s,t)=L^x_1(s,1)-L^x_1(s,1-t). \end{align*} Next, we consider the local time process in the plane $L:=(L_{s,t}^x;x\in\mathbb{R},s\geq0,t\geq0)$ as defined in \cite[Section 2]{Wa78} (see also \cite[Section 6, Page 157]{CW75}) by \begin{align*} L^x_{s,t}:=\int_0^sL_1^x(\xi,t)\mathrm{d}\xi,\quad\forall\,x\in\mathbb{R},\,\forall\,(s,t)\in\mathbb{R}_+^2. \end{align*} Then it holds \begin{align}\label{eq:StoInt2DLocTime01} L^x_{s,t}=\int_0^s\int_{1-t}^1\mathbf{1}_{\{W^{(0)}_{\xi,u}\leq x\}}\frac{\mathrm{d}_uW^{(0)}_{\xi,u}}{\xi}\mathrm{d}\xi+\int_0^s\int_{0}^t\mathbf{1}_{\{\widehat{W}^{(0)}_{\xi,u}\leq x\}}\frac{\mathrm{d}_u\widehat{W}^{(0)}_{s,u}}{\xi}\mathrm{d}\xi,\quad\forall\,(s,t)\in[0,1]^2. \end{align} Let us now consider the norm $\Vert\cdot\Vert$ defined by \begin{align*} \Vert f\Vert:=&2\Big(\int_0^1\int_0^1\int_{\mathbb{R}}f^2(s,t,x)\exp\Big(-\frac{x^2}{2st}\Big)\frac{\mathrm{d}x\mathrm{d}s\mathrm{d}t}{\sqrt{2\pi st}}\Big)^{1/2}\\ &+\int_0^1\int_0^1\int_{\mathbb{R}}|xf(s,t,x)|\exp\Big(-\frac{x^2}{2st}\Big)\frac{\mathrm{d}x\mathrm{d}s\mathrm{d}t}{st\sqrt{2\pi st}}\\ =&2\Big(\int_0^1\int_0^1\mathbb{E}\Big[f^2(s,t,W^{(0)}_{s,t})\Big]\mathrm{d}s\mathrm{d}t\Big)^{1/2}+\int_0^1\int_0^1\mathbb{E}\Big[\Big|f(s,t,W^{(0)}_{s,t})\frac{W^{(0)}_{s,t}}{st}\Big|\Big] \mathrm{d}s\mathrm{d}t. \end{align*} Consider the set $\mathcal{H}$ of measurable functions $f$ on $[0,1]^2\times\mathbb{R}$ such that $\Vert f\Vert<\infty$. Endowed with $\Vert\cdot\Vert$, the space $\mathcal{H}$ is a Banach space. In the following, we define a stochastic integral over the space with respect to the local time for the elements of $\mathcal{H}$. This extends the definition in \cite{Ei00}. We say that $f_{\Delta}:\,[0,1]^2\times\mathbb{R}\to\mathbb{R}$ is an elementary function if there exist two sequences of real numbers $(x_i)_{0\leq i\leq n}$, $(f_{ijk};0\leq i\leq n,0\leq j\leq m, 0\leq k\leq\ell)$ and two subdivisions of $[0,1]$ $(s_j)_{0\leq j\leq m}$, $(t_k)_{0\leq k\leq \ell}$ such that \begin{align}\label{eq:ElemFunction} f_{\Delta}(s,t,x)=\sum\limits_{(x_i,s_j,t_k)\in\Delta}f_{ijk}\mathbf{1}_{(x_i,x_{i+1}]}(x)\mathbf{1}_{(s_j,s_{j+1}]}(s)\mathbf{1}_{(t_k,t_{k+1}]}(t), \end{align} where $\Delta=\{(x_i,s_j,t_k);0\leq i\leq n,0\leq j\leq m, 0\leq k\leq\ell\}$. \begin{defi} For a simple function $f_{\Delta}$ given in \eqref{eq:ElemFunction}, we define its integral with respect to $L$ as \begin{align*} \int_0^1\int_0^1\int_{\mathbb{R}}f_{\Delta}(s,t,x)\mathrm{d}L^x_{s,t}:=&\sum\limits_{(x_i,s_j,t_k)\in\Delta}f_{ijk}\Big(L^{x_{i+1}}_{s_{j+1},t_{k+1}}-L^{x_{i+1}}_{s_{j},t_{k+1}}-L^{x_{i}}_{s_{j+1},t_{k+1}}+L^{x_{i}}_{s_{j},t_{k+1}}\\ &\text{ }-L^{x_{i+1}}_{s_{j+1},t_{k}}+L^{x_{i+1}}_{s_{j},t_{k}}+L^{x_{i}}_{s_{j+1},t_{k}}-L^{x_{i}}_{s_{j},t_{k}}\Big). \end{align*} \end{defi} \begin{remark} Let $f$ be an element of $\mathcal{H}$ and let $(f_n)_{n\in\mathbb{N}}$ be a sequence of elementary functions converging to $f$ in $\mathcal{H}$. It is proved in \cite[Proposition 2.1]{BDM21} that the sequence $\left(\int_0^1\int_0^1\int_{\mathbb{R}}f_n(s,t,x)\mathrm{d}L^x_{s,t}\right)_{n\in\mathbb{N}}$ converges in $L^1(\Omega,\mathbb{P})$ and that the limit does not depend on the choice of the sequence $(f_n)_{n\in\mathbb{N}}$. This limit is called integral of $f$ with respect to $L$. Similar results were obtained in \cite{Ei00}. \end{remark} Let $f:\,[0,1]^2\times\mathbb{R}^d\to\mathbb{R}$ be a continuous function such that for any $(s,t)\in[0,1]^2$, $f(s,t,\cdot)$ is differentiable and for any $i\in\{1,\cdots,d\}$, the partial derivative $\partial_{x_i}f$ is continuous. We also know from \cite[Proposition 3.1]{BDM21} that for a $d$-dimensional Brownian sheet $\Big(W_{s,t}:=(W_{s,t}^{(1)},\cdots,W_{s,t}^{(d)});s\geq0,t\geq0\Big)$ defined on a filtered probability space and for any $(s,t)\in[0,1]^2$ and any $i\in\{1,\cdots,d\}$, we have \begin{align}\label{eq:EisenSheetdD01} &\int_0^s\int_0^t\partial_{x_i}f(\xi,u,W_{\xi,u})\mathrm{d}u\mathrm{d}\xi\notag\\ =&-\int_0^s\int_0^tf(\xi,u,W_{\xi,u})\frac{d_uW^{(i)}_{\xi,u}}{\xi}\mathrm{d}\xi-\int_0^s\int_{1-t}^1f(\xi,1-u,\widehat{W}_{\xi,u})\frac{d_uB^{(i)}_{\xi,u}}{\xi}\mathrm{d}\xi\nonumber\\ &+\int_0^s\int_{1-t}^1f(\xi,1-u,\widehat{W}_{\xi,u})\frac{\widehat{W}^{(i)}_{\xi,u}}{\xi(1-u)}\mathrm{d}u\mathrm{d}\xi, \end{align} where $\widehat{W}^{(i)}:=(\widehat{W}^{(i)}_{\xi,u};0\leq\xi,u\leq1)$ and $B^{(i)}:=(B^{(i)}_{\xi,u};0\leq\xi,u\leq1)$ is a standard Brownian sheet with respect to the filtration of $\widehat{W}^{(i)}$, independent of $(W^{(i)}_{s,1},s\geq0)$. The following result will be extensively used in this work and corresponds to \cite[Proposition 2.1]{Sh16} for the standard Wiener process. \begin{prop}\label{prop:DavieSheet1dd} Let $W:=\left(W^{(1)}_{s,t},\ldots,W^{(d)}_{s,t};(s,t)\in[0,1]^2\right)$ be a $\mathbb{R}^d$-valued Brownian sheet defined on a filtered probability space $(\Omega,\mathcal{F},\mathbb{F},\mathbb{P})$, where $\mathbb{F}=(\mathcal{F}_{s,t};s,t\in[0,1])$. Let $b\in\mathcal{C}\left([0,1]^2,\mathcal{C}^1(\mathbb{R}^d)\right)$, $\Vert b\Vert_{\infty}\leq1$. Let $(a,a^{\prime},\varepsilon,\varepsilon^{\prime})\in[0,1]^4$. Then there exist positive constants $\alpha$ and $C$ (independent of $\nabla_yb$, $a$, $a^{\prime}$, $\varepsilon$ and $\varepsilon^{\prime}$) such that \begin{align}\label{eq:DavieSheet0dd} \mathbb{E}\Big[\exp\Big(\alpha\varepsilon^{\prime} \varepsilon \Big|\int_0^1\int_0^1\nabla_yb\left(s,t,\widetilde{W}^{\varepsilon,\varepsilon^{\prime}}_{s,t}\right)\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\leq C. \end{align} Here $\nabla_yb$ denotes the gradient of $b$ with respect to the third variable, $|\cdot|$ is the usual norm on $\mathbb{R}^d$ and the $\mathbb{R}^d$-valued two-parameter Gaussian process $\widetilde{W}^{\varepsilon,\varepsilon^{\prime}}:=\Big(\widetilde{W}^{(\varepsilon,\varepsilon^{\prime},1)}_{s,t},\ldots,\widetilde{W}^{(\varepsilon,\varepsilon^{\prime},d)}_{s,t};(s,t)\in[0,1]^2\Big)$ is given by $$ \widetilde{W}^{(\varepsilon,\varepsilon^{\prime},i)}_{s,t}=W^{(i)}_{a^{\prime}+\varepsilon^{\prime} s,a+\varepsilon t}-W^{(i)}_{a^{\prime},a+\varepsilon t}-W^{(i)}_{a^{\prime}+\varepsilon^{\prime} s,a}+W^{(i)}_{a^{\prime},a}\quad\text{for all }i\in\{1,\ldots,d\}. $$ \end{prop} \begin{proof} The proof of \eqref{eq:DavieSheet0dd} is based on the local time-space integration formula \eqref{eq:EisenSheetdD01} and the Barlow-Yor inequality. Fix $(a,a^{\prime},\varepsilon,\varepsilon^{\prime})\in[0,1]^4$. Since $x\longmapsto e^{\alpha\varepsilon\varepsilon^{\prime} dx^2}$ is a convex function, we deduce from the Jensen inequality that \begin{align*} &\mathbb{E}\Big[\exp\Big(\alpha\varepsilon^{\prime} \varepsilon \Big|\int_0^1\int_0^1\nabla_yb\Big(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}\Big)\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\\ =&\mathbb{E}\Big[\exp\Big(\alpha\varepsilon^{\prime} \varepsilon \sum\limits_{i=1}^d\Big|\int_0^1\int_0^1\partial_{y_i}b\Big(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}\Big)\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\\ \leq&\frac{1}{d}\sum\limits_{i=1}^d\mathbb{E}\Big[\exp\Big(\alpha d\varepsilon^{\prime} \varepsilon\Big|\int_0^1\int_0^1\partial_{y_i}b\Big(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}\Big)\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]. \end{align*} In order to obtain \eqref{eq:DavieSheet0dd} it suffices to prove that for every $i\in\{1,2,\ldots,d\}$, there exist positive constants $\alpha=\alpha_i$ and $C=C_i$ such that \begin{align*} \mathbb{E}\Big[\exp\Big(\alpha \varepsilon \varepsilon^{\prime}\left|\int_0^1\int_0^1\partial_{y_i} b\Big(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}\Big)\mathrm{d}t\mathrm{d}s\Big|^2\Big)\right]\leq C. \end{align*} For every $i\in\{1,\ldots,d\}$, we apply \eqref{eq:EisenSheetdD01} to the standard $d$-dimensional Brownian sheet $\Big(Y_{s,t}:=(\varepsilon\varepsilon^{\prime})^{-1/2}\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t},(s,t)\in[0,1]^2\Big)$ and the function $f:\,[0,1]^2\times\mathbb{R}^d\to\mathbb{R}$ given by $f(s,t,y)=b\Big(s,t,\sqrt{\varepsilon\varepsilon^{\prime}}\,y\Big)$ to obtain \begin{align*} &\int_0^1\int_0^1\partial_{y_i}f(s,t,Y_{s,t})\mathrm{d}t\mathrm{d}s\\ =& -\int_0^1\int_0^1f(s,t,Y_{s,t})\frac{\mathrm{d}_tY^{(i)}_{s,t}}{s}\mathrm{d}s-\int_0^1\int_{0}^1f(s,1-t,Y_{s,1-t})\frac{\mathrm{d}_tB^{(i)}_{s,t}}{s}\mathrm{d}s\nonumber\\ &+\int_0^1\int_{0}^1f(s,1-t,Y_{s,1-t})\frac{Y^{(i)}_{s,1-t}}{s(1-t)}\mathrm{d}t\mathrm{d}s, \end{align*} where $(B^{(i)}_{s,t},0\leq s,t\leq1)$ denotes a standard Brownian sheet independent of the process $(Y^{(i)}_{s,1},0\leq s\leq 1)$. Hence, \begin{align*} &\sqrt{\varepsilon \varepsilon^{\prime}}\int_0^1\int_0^1\partial_{y_i}b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t})\mathrm{d}t\mathrm{d}s\\ =&-\int_0^1\int_0^1b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t})\frac{\mathrm{d}_tY^{(i)}_{s,t}}{s}\mathrm{d}s-\int_0^1\int_{0}^1b(s,1-t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,1-t})\frac{\mathrm{d}_tB^{(i)}_{s,t}}{s}\mathrm{d}s\\ &+\int_0^1\int_{0}^1b(s,1-t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,1-t})\frac{Y^{(i)}_{s,1-t}}{s(1-t)}\mathrm{d}t\mathrm{d}s\\ =&I_1+I_2+I_3. \end{align*} Using once more the convexity of the function $x\longmapsto e^{3\alpha x^2}$ for any $\alpha>0$, we obtain \begin{align*} &\mathbb{E}\Big[\exp\Big(\alpha \varepsilon \varepsilon^{\prime}\Big|\int_0^1\int_0^1\nabla_yb\Big(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}\Big)\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\notag\\ =&\mathbb{E}\Big[\exp\Big(\alpha (I_1+I_2+I_3)^2\Big)\Big]\\ \leq&\frac{1}{3}\Big(\mathbb{E}\Big[\exp(3\alpha I_1^2)\Big]+\mathbb{E}\Big[\exp(3\alpha I_2^2)\Big]+\mathbb{E}\Big[\exp(3\alpha I_3^2)\Big]\Big). \end{align*} Hence to get the desired estimate, we need to prove that for every $k\in\{1,2,3\}$, there exist positive constants $\alpha_k$ and $C_k$ such that $\mathbb{E}\left[\exp(\alpha_k I_k^2)\right]\leq C_k.$\\ For every $s\in]0,1]$, $\left(s^{-1/2}Y^{}_{s,v},0\leq v\leq1\right)$ is a standard Brownian motion with respect to the filtration $\mathcal{F}_{1,\cdot}:=(\mathcal{F}_{1,t},t\in[0,1])$. Therefore the process $$ \Big(M_{s,t}:=\int_{0}^tb(s,v,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,v})\mathrm{d}_v\left[\frac{Y^{}_{s,v}}{\sqrt{s}}\right],0\leq t\leq1\Big) $$ is an It\^o integral with respect to $\mathcal{F}_{1,\cdot}$ and thus a square-integrable $\mathcal{F}_{1,\cdot}$-martingale. In addition, for any constant $\alpha\in\mathbb{R}_+$, the following expansion formula holds \begin{align*} \mathbb{E}\Big[\exp\Big(\alpha I_1^2\Big)\Big] =\mathbb{E}\Big[\exp\Big(\alpha\Big|\int_0^1M_{s,1}^{}\frac{\mathrm{d}s}{\sqrt{s}}\Big|^2\Big)\Big]=\sum\limits_{m=0}^{\infty}\frac{\alpha^m\mathbb{E}\Big[\Big|\displaystyle\int_0^1M_{s,1}^{}\frac{\mathrm{d}s}{\sqrt{s}}\Big|^{2m}\Big]}{m!}. \end{align*} Moreover, by the Jensen inequality and the Barlow-Yor inequality applied to the martingale $(M_{s,t},t\in[0,1])$ (see for example \cite[Proposition 4.2]{BY82} and \cite[Appendix]{CK91}), there exists a universal constant $c_1$ (not depending on $m$) such that, \begin{align*} \mathbb{E}\Big[\Big|\int_0^1M_{s,1}^{}\frac{\mathrm{d}s}{\sqrt{s}}\Big|^{2m}\Big]&\leq4^m\int_0^1\mathbb{E}\Big[|M_{s,1}|^{2m}\Big]\frac{\mathrm{d}s}{2\sqrt{s}}\leq 4^m\int_0^1\mathbb{E}\Big[\Big(\sup\limits_{0\leq t\leq 1}|M_{s,t}|\Big)^{2m}\Big]\frac{\mathrm{d}s}{2\sqrt{s}}\\&\leq c_1^{2m}(8m)^m\int_0^1\mathbb{E}\Big[\langle M^{}_{s,\cdot}\rangle_1^m\Big]\frac{\mathrm{d}s}{2\sqrt{s}}\\ &\leq c_1^{2m}(8m)^m\int_0^1\mathbb{E}\Big[\Big(\int_{0}^{1}b^2(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t})\mathrm{d}t\Big)^m\Big]\frac{\mathrm{d}s}{2\sqrt{s}} \leq c_1^{2m}(8m)^m, \end{align*} since $\Vert b\Vert_{\infty}\leq 1$. Thus, \begin{align*} \mathbb{E}\Big[\exp\Big(\alpha I_1^2\Big)\Big] =\mathbb{E}\Big[\exp\Big(\alpha\Big|\int_0^1M_{s,1}^{}\frac{\mathrm{d}s}{\sqrt{s}}\Big|^2\Big)\Big]= \sum\limits_{m=0}^{\infty}\frac{\Big(8\alpha c_1^2\Big)^mm^m}{m!}. \end{align*} The above expression if finite for $\alpha$ such that $8\alpha c_1^2e<1$, i.e. $\alpha<1/8c_1^2e$ (by ratio test). Hence, there exists positive constants $\alpha_1$ and $C_1$ such that $$ \mathbb{E}\Big[\exp\Big(\alpha_1 I_1^2\Big)\Big]\leq C_1. $$ Similarly for \begin{align*} I_2=-\int_0^1\int_{0}^1b(s,1-t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,1-t})\mathrm{d}_tB^{(i)}_{s,t}\frac{\mathrm{d}s}{s}, \end{align*} there exists positive constants $\alpha_2$ and $C_2$ such that \begin{align*} \mathbb{E}\Big[\exp\Big(\alpha_2 I_2^2\Big)\Big] \leq\mathbb{E}\Big[\exp\Big(\alpha_2\Big|\int_0^1\int_{0}^1b(s,1-t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,1-t})\mathrm{d}_tB^{(i)}_{s,t}\frac{\mathrm{d}s}{s}\Big|^2\Big)\Big]\leq C_2. \end{align*} It remains to estimate the term $I_3$. By the Jensen inequality, we have \begin{align} \mathbb{E}\Big[\exp\Big(\frac{I_3^2}{64}\Big)\Big] =&\mathbb{E}\Big[\exp\Big\{\frac{1}{4}\Big(\int_0^1\int_{0}^1\frac{b(s,1-t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,1-t})Y^{(i)}_{s,1-t}}{\sqrt{s(1-t)}}\frac{\mathrm{d}t\mathrm{d}s}{4\sqrt{s(1-t)}}\Big)^2\Big\}\Big] \nonumber\\ \leq&\int_0^1\int_{0}^{1}\mathbb{E}\Big[\exp\Big\{\frac{1}{4}b^2(s,1-t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,1-t})\Big|\frac{Y^{(i)}_{s,1-t}}{\sqrt{s(1-t)}}\Big|^2\Big\}\Big]\frac{\mathrm{d}t\mathrm{d}s}{4\sqrt{s(1-t)}}\nonumber\\ \leq&\int_0^1\int_{0}^{1}\mathbb{E}\Big[\exp\Big(\frac{1}{4}\Big|\frac{Y^{(i)}_{s,1-t}}{\sqrt{s(1-t)}}\Big|^2\Big)\Big]\frac{\mathrm{d}t\mathrm{d}s}{4\sqrt{s(1-t)}}. \label{eq:EstimShap2} \end{align} Note that for every $(s,t)\in]0,1]\times[0,1[$, $\dfrac{Y^{(i)}_{s,1-t}}{\sqrt{s(1-t)}}$ is a standard normal random variable. Therefore \eqref{eq:EstimShap2} yields $$ \mathbb{E}\Big[\exp\Big(\frac{I_3^2}{64}\Big)\Big]\leq C_3. $$ The proof of \eqref{eq:DavieSheet0dd} is completed by taking $\alpha=\min(\frac{1}{64},\alpha_2,\alpha_3)$. \end{proof} For every $0\leq a< h\leq 1$, $0\leq a^{\prime}< h^{\prime}\leq 1$ and for $(x,y)\in\mathbb{R}^d$ define the function $\varrho$ by: $$ \varrho(x,y):=\int_{a^{\prime}}^{h^{\prime}}\int_a^h\Big\{b(\xi,\zeta,W_{\xi,\zeta}+x)-b(\xi,\zeta,W_{\xi,\zeta}+y)\Big\}\mathrm{d}\zeta\mathrm{d}\xi. $$ As a consequence of Proposition \ref{prop:DavieSheet1dd}, we have: \begin{corollary}\label{corol:DavieSheet1dds1} Let $b:[0,1]^2\times\mathbb{R}^d\to\mathbb{R}$ be a bounded and Borel measurable function such that $\Vert b\Vert_{\infty}\leq1$. Let $\alpha$, $C$ and $\widetilde{W}^{\varepsilon,\varepsilon^{\prime}}$ be defined as in Proposition \ref{prop:DavieSheet1dd}. Then the following two bounds are valid: \begin{enumerate} \item For every $(x,y)\in\mathbb{R}^{2d}$, $x\neq y$ and every $(\varepsilon,\varepsilon^{\prime})\in[0,1]^2$, we have \begin{align}\label{eq:DavieSheet02dd} \mathbb{E}\Big[\exp\Big(\frac{\alpha\varepsilon^{\prime} \varepsilon }{|x-y|^2}\Big|\int_0^1\int_0^1\left\{b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+x)-b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y)\right\}\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\leq C. \end{align} \item For any $(x,y)\in\mathbb{R}^2$ and any $\eta>0$, we have \begin{align}\label{eq:EstDavieSigma1} \mathbb{P}\left(|\varrho(x,y)|\geq\eta\sqrt{(h-a)(h^{\prime}-a^{\prime})}|x-y|\right) \leq Ce^{-\alpha\eta^2}. \end{align} \end{enumerate} \end{corollary} \begin{proof} We start by showing \eqref{eq:DavieSheet02dd}. Note that it is enough to show this when $b$ is compactly supported and differentiable. Indeed, if $b$ is not differentiable, then, since the set of compactly supported and differentiable functions is dense in $L^{\infty}([0,1]^2\times\mathbb{R}^d)$, there exists a sequence $(b_n,n\in\mathbb{N})$ of compactly supported and differentiable functions which converges a.e. to $b$ on $[0,1]^2\times\mathbb{R}^d$ and the desired result will follow from the Vitali's convergence theorem.\\ Using the mean value theorem and the Cauchy-Schwartz inequality, we have \begin{align*} &\Big|\int_0^1\int_0^1\Big\{b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+x)-b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y)\Big\}\mathrm{d}t\mathrm{d}s\Big|^2\\ =&\Big|\int_0^1\int_0^1\int_0^1\nabla_yb_{}(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y+\xi(x-y))\cdot(x-y)\mathrm{d}\xi \mathrm{d}t\mathrm{d}s\Big|^2\\ \leq&|x-y|^2\Big|\int_0^1\int_0^1\int_0^1\nabla_yb_{}(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y+\xi(x-y))\mathrm{d}\xi \mathrm{d}t\mathrm{d}s\Big|^2. \end{align*} Using the Minkowski inequality, the Jensen inequality and Proposition \ref{prop:DavieSheet1dd} applied to the function $(s,t,z)\longmapsto b(s,t,z+y+\xi(x-y))$, we obtain \begin{align} &\mathbb{E}\Big[\exp\Big(\frac{\alpha \varepsilon \varepsilon^{\prime}}{|x-y|^2}\Big|\int_0^1\int_0^1\Big\{b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+x)-b(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y)\Big\}\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\nonumber\\ =&\mathbb{E}\Big[\exp\Big(\frac{\alpha \varepsilon \varepsilon^{\prime}}{|x-y|^2}\Big|\int_0^1\int_0^1\int_0^1\nabla_yb(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y+\xi(x-y))\cdot(x-y)\mathrm{d}\xi \mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\nonumber\\ \leq&\mathbb{E}\Big[\exp\Big(\frac{\alpha \varepsilon \varepsilon^{\prime}}{|x-y|^2}\int_0^1\Big|\int_0^1\int_0^1\nabla_yb(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y+\xi(x-y))\cdot(x-y) \mathrm{d}t\mathrm{d}s\Big|^2\mathrm{d}\xi\Big)\Big]\nonumber\\ \leq& \int_0^1\mathbb{E}\Big[\exp\Big(\alpha \varepsilon \varepsilon^{\prime}\Big|\int_0^1\int_0^1\nabla_yb(s,t,\widetilde{W}^{\varepsilon^{\prime},\varepsilon}_{s,t}+y+\xi(x-y))\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\mathrm{d}\xi\leq C.\label{eq:DavieSheetEstgs} \end{align} This ends the proof of \eqref{eq:DavieSheet02dd}. As for the proof of \eqref{eq:EstDavieSigma1}, let $(x,y)\in\mathbb{R}^{2d}$ such that $x\neq y$ and set $\varepsilon=h-a$ and$\varepsilon^{\prime}=h^{\prime}-a^{\prime}$. Define $\widehat{b}$ by $\widehat{b}(s,t,x):=b(a^{\prime}+\varepsilon^{\prime} s,a+\varepsilon t,x)$ and additionally define the processes $\widetilde{W}^{\varepsilon^{\prime},\varepsilon}:=\Big(\widetilde{W}_{s,t}^{\varepsilon,\varepsilon^{\prime}},(s,t)\in[0,1]^2\Big)$ and $Z^{\varepsilon^{\prime},\varepsilon}:=\Big(Z_{s,t}^{\varepsilon^{\prime},\varepsilon},(s,t)\in[0,1]^2\Big)$, respectively by \begin{align*} \widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}=W_{a^{\prime}+\varepsilon^{\prime} s,a+\varepsilon t}-W_{a^{\prime},a+\varepsilon t}-W_{a^{\prime}+\varepsilon^{\prime} s,a}+W_{a^{\prime},a}, \end{align*} and \begin{align*} Z_{s,t}^{\varepsilon^{\prime},\varepsilon}=W_{a^{\prime},a+\varepsilon t}+W_{a^{\prime}+\varepsilon^{\prime} s,a}-W_{a^{\prime},a}. \end{align*} Then $\widetilde{W}^{\varepsilon^{\prime},\varepsilon}$ and $Z^{\varepsilon^{\prime},\varepsilon}$ are independent processes. To see this, observe that $Z^{\varepsilon^{\prime},\varepsilon}_{s,t}$ is $\mathcal{F}_{1,a}\vee\mathcal{F}_{a^{\prime},1}$-measurable for every $(s,t)\in[0,1]^2$ and $\widetilde{W}^{\varepsilon^{\prime},\varepsilon}$ is independent of $\mathcal{F}_{1,a}\vee\mathcal{F}_{a^{\prime},1}$. Using the change of variable $(\xi,\zeta):=(a^{\prime}+\varepsilon^{\prime} s,a+\varepsilon t)$, we obtain \begin{align*} \varrho(x,y)&=\int_{a^{\prime}}^{h^{\prime}}\int_a^h\Big\{b(\xi,\zeta,W_{\xi,\zeta}+x)-b(\xi,\zeta,W_{\xi,\zeta}+y)\Big\}\mathrm{d}\zeta \mathrm{d}\xi\\ =&\varepsilon\varepsilon^{\prime}\int_0^1\int_0^1\Big\{\widehat{b}(s,t,W_{a^{\prime}+\varepsilon^{\prime} s,a+\varepsilon t}+x)-\widehat{b}(s,t,W_{a^{\prime}+\varepsilon^{\prime} s,a+\varepsilon t}+y)\Big\}\mathrm{d}t\mathrm{d}s\\ =&\varepsilon\varepsilon^{\prime}\int_0^1\int_0^1\Big\{\widehat{b}(s,t,\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+Z_{s,t}^{\varepsilon^{\prime},\varepsilon}+x)-\widehat{b}(s,t,\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+Z_{s,t}^{\varepsilon,\varepsilon^{\prime}}+y)\Big\}\mathrm{d}t\mathrm{d}s. \end{align*} Taking the expectation on both sides after some operations and using the fact that $\widetilde{W}^{\varepsilon^{\prime},\varepsilon}$ and $Z^{\varepsilon^{\prime},\varepsilon}$ are independent, we hav \begin{align*} &\mathbb{E}\Big[\exp\Big(\frac{\alpha|\varrho(x,y)|^2}{\varepsilon\varepsilon^{\prime}|x-y|^2}\Big)\Big]\\ =&\mathbb{E}\Big[\exp\Big(\frac{\alpha\varepsilon\varepsilon^{\prime}}{|x-y|^2}\Big|\int_0^1\int_0^1\left\{\widehat{b}(s,t,\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+Z_{s,t}^{\varepsilon,\varepsilon^{\prime}}+x)-\widehat{b}(s,t,\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+Z_{s,t}^{\varepsilon,\varepsilon^{\prime}}+y)\right\}\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\\ =&\int \mathbb{E}\Big[\exp\Big(\frac{\alpha\varepsilon\varepsilon^{\prime}}{|x-y|^2}\Big|\int_0^1\int_0^1\Big\{\widehat{b}^z_{s,t}(\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+x)-\widehat{b}^z_{s,t}(\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+y)\Big\}\mathrm{d}t \mathrm{d}s\Big|^2\Big)\Big]\mathbb{P}_{Z^{\varepsilon,\varepsilon^{\prime}}}(\mathrm{d}z), \end{align*} where $\widehat{b}^z_{s,t}(w)=\widehat{b}(s,t,w+z_{s,t})$. Since $|\widehat{b}(s,t,w)|\leq1$ almost everywhere on $[0,1]^2\times\mathbb{R}^d$, we deduce from \eqref{eq:DavieSheet02dd} that \begin{align*} &\mathbb{E}\Big[\exp\Big(\frac{\alpha|\varrho(x,y)|^2}{\varepsilon\varepsilon^{\prime}|x-y|^2}\Big)\Big]\\ =&\int \mathbb{E}\Big[\exp\Big(\frac{\alpha\varepsilon\varepsilon^{\prime}}{|x-y|^2}\Big|\int_0^1\int_0^1\Big\{\widehat{b}^z_{s,t}(\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+x)-\widehat{b}^z_{s,t}(\widetilde{W}_{s,t}^{\varepsilon^{\prime},\varepsilon}+y)\Big\}\mathrm{d}t\mathrm{d}s\Big|^2\Big)\Big]\mathbb{P}_{Z^{\varepsilon,\varepsilon^{\prime}}}(\mathrm{d}z)\leq C. \end{align*} Therefore, by Chebychev inequality, we obtain \begin{align*} \mathbb{P}\Big(|\varrho(x,y)|\geq\eta\sqrt{\varepsilon\varepsilon^{\prime}}|x-y|\Big)\leq e^{-\alpha\eta^2}\mathbb{E}\Big[\exp\Big(\frac{\alpha|\varrho(x,y)|^2}{\varepsilon\varepsilon^{\prime}|x-y|^2}\Big)\Big]\leq Ce^{-\alpha\eta^2} \end{align*} for any $\eta>0$. This concludes the proof. \end{proof} \section{Proof of the auxiliary results}\label{Auxrel} In this section we prove the auxiliary results stated in Section \ref{sectmasinres}. Consider $\mathbf{Q}=[-1,1]^d$ and its dyadic decomposition. \subsection{Regularization by noise}\label{regbynoise} \begin{proof}[Proof of Lemma \ref{lem:PseudoMetric1}] Let $\mathcal{Q}$ denote the set of couples $(x,y)$ of dyadic numbers in $\mathbf{Q}$. For every integer $m\geq0$, we define $$\mathcal{Q}_{m}=\left\{(x,y)\in\mathcal{Q}:\,2^mx\in\mathbb{Z}^d,\,2^my\in\mathbb{Z}^d \right\}.$$ Then $\mathcal{Q}_{m}$ has no more than $2^{2d(m+2)}$ elements and we have $\mathcal{Q}=\bigcup\limits_{m\in\mathbb{N}}\mathcal{Q}_{m}$. Consider the set $\mathbf{E}_{\delta,n}$ defined by \begin{align*} \mathbf{E}_{\delta,n}:=&\left\{\omega\in\Omega:\,\text{there exist }k,k^{\prime}\in\{0,1,\ldots,2^n-1\},\text{ }m\in\mathbb{N}^{\ast},\text{ } \text{ and }(x,y)\in\mathcal{Q}_{m}\right.\\ &\qquad \text{ such that } |\varrho_{nkk^{\prime}}(x,y)|(\omega)\geq\delta(1+\sqrt{n}+\sqrt{m})2^{-n}|x-y|\} \end{align*} for every $n\in\mathbb{N}$, $\delta\in\mathbb{Q}_+$. Observe that \begin{align*} &\mathbf{E}_{\delta,n}\\ =&\bigcup_{k=0}^{2^n-1}\bigcup_{k^{\prime}=0}^{2^n-1}\bigcup_{m=0}^{\infty}\Big(\bigcup_{(x,y)\in\mathcal{Q}_{m}}\left\{\omega\in\Omega:\,|\varrho_{nkk^{\prime}}(x,y)|(\omega)\geq\delta(1+\sqrt{n}+\sqrt{m})2^{-n}|x-y|\right\}\Big). \end{align*} Define also $\mathbf{E}_{\delta}$ by $\mathbf{E}_{\delta}:=\bigcup\limits_{n=0}^{\infty}\mathbf{E}_{\delta,n}$. Then, we deduce from \eqref{eq:EstDavieSigma1} that \begin{align*} \mathbb{P}(\mathbf{E}_{\delta})&\leq\sum\limits_{n=0}^{\infty}\sum\limits_{k=0}^{2^n-1}\sum\limits_{k^{\prime}=0}^{2^n-1}\sum\limits_{m=0}^{\infty} \sum\limits_{(x,y)\in\mathcal{Q}_{m}}\mathbb{P}\left(|\varrho_{nkk^{\prime}}(x,y)|\geq \delta(1+\sqrt{n}+\sqrt{m})2^{-n}|x-y|\right)\\ &\leq 2^{4d}C \sum\limits_{n=0}^{\infty}\sum\limits_{m=0}^{\infty}2^{2n}2^{2dm}e^{-\alpha\delta^2(1+n+m)}, \end{align*} where $C$ and $\alpha$ are the deterministic constants in Proposition \ref{prop:DavieSheet1dd}. Moreover, $(\mathbf{E}_{\delta},\delta\in\mathbb{Q}_+)$ is a nonincreasing family and for $\delta\geq\delta_0:=\sqrt{2(d+1)\alpha^{-1}}$, we have \begin{align}\label{eq:EstlimPEdelta00e} \mathbb{P}(\mathbf{E}_{\delta})\leq 2^{4d}Ce^{-\alpha\delta^2}\,\sum\limits_{n=0}^{\infty}\sum\limits_{m=0}^{\infty}2^{-dn-2m}\leq2^{4d}C\,e^{-\alpha\delta^2}. \end{align} Therefore \begin{align*} \mathbb{P}\Big(\bigcap\limits_{\delta\in[\delta_0,\infty[\cap\mathbb{Q}}\mathbf{E}_{\delta}\Big)=\lim\limits_{\delta\to\infty}\mathbb{P}(\mathbf{E}_{\delta})=0. \end{align*} Let us now define $\Omega_{1}$ by $$ \Omega_{1}:=\bigcup\limits_{\delta\in[\delta_0,\infty[\cap\mathbb{Q}}\left(\Omega\setminus\mathbf{E}_{\delta}\right). $$ Then $\mathbb{P}(\Omega_{1})=1$ and for every $\omega\in\Omega_1$, there exists $\delta_{\omega}>0$ such that \begin{align}\label{eq:DaviePseudoMetricc00} |\varrho_{nkk^{\prime}}(x,y)(\omega)|<\delta_{\omega} 2^{-n}(1+\sqrt{n}+\sqrt{m})|x-y| \end{align} for all choices of $n$, $k$, $k^{\prime}$, $m$, and all choices of couples $(x,y)$ in $\mathcal{Q}_{m}$.\\ Now, fix $\omega\in\Omega_1$, choose two dyadic numbers $x$, $y$ in $\mathbf{Q}$ and define $m$ by \begin{align} m:=\inf\Big\{n\in \mathbb{N} \text{ s.t. }2^{-n}\leq \max_{1\leq i\leq d}|x_i-y_i|\Big\}. \end{align} For $r\geq m$, define $x_r=(2^{-r}\floor*{2^rx_1},\ldots,2^{-r}\floor*{2^rx_d})$ and $y_r=(2^{-r}\floor*{2^ry_1},\ldots,2^{-r}\floor*{2^ry_d})$, where $ \floor*{\cdot}$ is the integer part function. Observe that $(x_m,y_m)\in\mathcal{Q}_m$, $(x_r,x_{r+1})\in\mathcal{Q}_{r+1}$ and $(y_r,y_{r+1})\in\mathcal{Q}_{r+1}$. Since for any $i\in\{1,\ldots,d\}$, $|\floor*{2^mx_i}-\floor*{2^my_i}|\leq 1+2^m|x_i-y_i|$ and $(\floor*{2x_i}-2\floor*{x_i},\floor*{2y_i}-2\floor*{y_i})\in\{0,1\}^2$, we have $|x_m-y_m|\leq3\sqrt{d}\,2^{-m}$, $|x_{r+1}-x_r|\leq\sqrt{d}\,2^{-r-1}$ and $|y_{r+1}-y_r|\leq\sqrt{d}\,2^{-r-1}$. It follows from the definition of $\rho_{nk}$ that \begin{align}\label{eq:AddPropRho1} \varrho_{nkk^{\prime}}(x,y)=\varrho_{nkk^{\prime}}(x,x_m)+\varrho_{nkk^{\prime}}(x_m,y_m)+\varrho_{nkk^{\prime}}(y_m,y). \end{align} Moreover since $\varrho_{nkk^{\prime}}(x_m,x_m)=0$ and $\varrho_{nkk^{\prime}}(y_m,y_m)=0$, we obtain \begin{align*} \varrho_{nkk^{\prime}}(x_{q+1},x_m)=\sum\limits_{r=m}^{q}\rho_{nkk^{\prime}}(x_{r+1},x_{r})\,\text{ and }\varrho_{nkk^{\prime}}(y_m,y_{q+1})=\sum\limits_{r=m}^{q}\varrho_{nkk^{\prime}}(y_{r},y_{r+1}) \end{align*} for every integer $q\geq m+1$. In addition for some integer $q\geq m+1$, we have $x_r=x$ and $y_r=y$ for all $r\geq q$, therefore \begin{align*} \varrho_{nkk^{\prime}}(x,x_m)=\sum\limits_{r=m}^{\infty}\varrho_{nkk^{\prime}}(x_r,x_{r+1})\,\text{ and }\varrho_{nkk^{\prime}}(y_m,y)=\sum\limits_{r=m}^{\infty}\varrho_{nkk^{\prime}}(y_{r+1},y_{r}). \end{align*} It follows from (\ref{eq:AddPropRho1}) and (\ref{eq:DaviePseudoMetricc00}) that \begin{align*} &2^{n}|\varrho_{nkk^{\prime}}(x,y)(\omega)|\\ &\leq3\sqrt{d}\delta_{\omega}(1+\sqrt{n}+\sqrt{m})2^{-m}+2\sqrt{d}\delta_{\omega}\sum\limits_{r=m}^{\infty}(1+\sqrt{n}+\sqrt{r+1})2^{-r-1}\\ &\leq3\sqrt{d}\delta_{\omega}(1+\sqrt{n}+\sqrt{m})2^{-m}+2\sqrt{d}\delta_{\omega}\sqrt{n}\sum\limits_{r=m}^{\infty}2^{-r-1}+\frac{4\sqrt{d}\delta_{\omega}}{\sqrt{m+1}}\sum\limits_{r=m}^{\infty}(r+1)2^{-r-1}. \end{align*} Using the following facts: $\sum\limits_{r=m}^{\infty}2^{-r-1}=2^{-m}$, $\sum\limits_{r=m}^{\infty}r2^{-r+1}=(m+1)2^{-m+2}$, $2^{-m}\leq\max\limits_{1\leq i\leq d}|x_i-y_i|\leq2^{-m+1}$, $|x-y|\leq\sqrt{d}\max\limits_{1\leq i\leq d}|x_i-y_i|\leq\sqrt{d}\,|x-y|$ and $n\geq1$, we obtain \begin{align*} &2^{n}|\varrho_{nkk^{\prime}}(x,y)(\omega)|\nonumber\\ \leq& 24\sqrt{d}\delta_{\omega}(1+\sqrt{n}+\sqrt{m})2^{-m}\leq 48d\delta_{\omega} \Big[\sqrt{n}+\Big(\log^+\frac{1}{|x-y|}\Big)^{1/2}\Big]|x-y|.\nonumber\\ \end{align*} Choosing $C_1(\omega)=48d\delta_{\omega}$ yields the desired result. \end{proof} \begin{proof}[Proof of Lemma \ref{lem:PseudoMetric2}] It suffices to show that there exists a subset $\widetilde{\Omega}_1$ of $\Omega$ with $\mathbb{P}(\widetilde{\Omega}_1)=1$ and a positive random constant $\widetilde{C}_1$ such that for any $\omega\in\widetilde{\Omega}_1$, any $n\in\mathbb{N}^{\ast}$, any $k,\,k^{\prime}\in\{0,1,\cdots,2^n-1\}$ and any dyadic number $x\in\mathbf{Q}$ with $\max\limits_{1\leq i\leq d}|x_i|\geq2^{-2^{2n+1}}$, \begin{align}\label{EqPseudoMetric2} |\varrho_{nkk^{\prime}}(x,0)(\omega)|\leq \widetilde{C}_1 (\omega)\sqrt{n}2^{-n}\Big(|x|+2^{-4^{n}}\Big). \end{align} In fact, using Lemma \ref{lem:PseudoMetric1}, there exist a subset $\Omega_1$ of $\Omega$ with $\mathbb{P}(\Omega_1)=1$ and a positive random constant $C_1$ such that for any $\omega\in\Omega_{1}$, any $n$, $k$, $k^{\prime}$ and any dyadic number $x\in\mathbf{Q}$ with $\max\limits_{1\leq i\leq d}|x_i|<2^{-2^{2n+1}}$, we have \begin{align*} |\varrho_{nkk^{\prime}}(x,0)(\omega)|\leq & C_1(\omega)2^{-n}\Big(\sqrt{n}+\Big(\log^+\frac{1}{|x|}\Big)^{1/2}\Big)|x|\\ \leq &C_1(\omega)2^{-n}\sqrt{n}\,|x|+ \sqrt[4]{d}C_1(\omega)2^{-n}\,2^{-4^{n}}\Big(|x|\log^+\frac{1}{|x|}\Big)^{1/2} \\ \leq& C_1(\omega)\Big(1+\sqrt[4]{dC_0^2}\Big)\sqrt{n}2^{-n}\Big(|x|+2^{-4^{n}}\Big) \leq C_{1,1}(\omega)\sqrt{n}2^{-n}\Big(|x|+2^{-4^{n}}\Big), \end{align*} where $C_0=\sup_{\xi\in]0,1]}\xi\log^+(1/\xi)$ and $C_{1,1}(\omega)=2C_{1}(\omega)\left(1+\sqrt[4]{dC_0^2}\right)$. The required result follows by choosing $\Omega_2=\Omega_1\cap\widetilde{\Omega}_1$ and $C_2=\max\{C_1,\widetilde{C}_1\}$.\\ Let us now prove that \eqref{EqPseudoMetric2} holds. Define the following three sets: \begin{align*} \mathcal{O}_q:=&\{y\in\mathbf{Q}:\,\max\limits_{1\leq i\leq d}|y_i|\leq 2^{-q}\},\notag\\ \mathcal{D}_q:=&\left\{(y,z)\in\mathcal{O}_q^2 \text{ such that there exists } r\in\mathbb{N},\,r\geq q\text{ s.t. }2^ry\in\mathbb{Z}^d, 2^rz\in\mathbb{Z}^d\right\}, \end{align*} and for $r\geq q$, $$ \mathcal{D}_{q,r}=\left\{(y,z)\in\mathcal{O}_q^2:\,2^ry\in\mathbb{Z}^d,\,2^rz\in\mathbb{Z}^d\right\}. $$ Observe that $\mathcal{D}_{q,r}$ has no more than $2^{4d}\times2^{2d(r-q)}$ elements and $$\mathcal{D}_q=\bigcup\limits_{r=q}^{\infty}\mathcal{D}_{q,r}.$$ In addition, define \begin{align*} \mathbf{F}_{\delta,n}:=&\left\{\omega\in\Omega:\,\text{for some }k\in\{0,1,\cdots,2^n-1\},\text{ }q\in\{0,1,\cdots,2^{2n+1}\},\text{ }r\geq q,\text{ and }\right.\\ &\quad\left.(y,z)\in\mathcal{D}_{q,r}\text{ one has } \left|\varrho_{nkk^{\prime}}(y,z)\right|(\omega)\geq\delta2^{-n}(\sqrt{n}+\sqrt{r-q})|y-z|\right\} \end{align*} for every $n\in\mathbb{N}^{\ast}$ and $\delta>0$. Then \begin{align*} &\mathbf{F}_{\delta,n}=\\ &\bigcup_{k=0}^{2^n-1}\bigcup_{k^{\prime}=0}^{2^n-1}\bigcup\limits_{q=0}^{2^{2n+1}}\bigcup_{r=q}^{\infty}\Big(\bigcup_{(y,z)\in\mathcal{D}_{q,r}}\left\{\omega\in\Omega:\,\left|\varrho_{nkk^{\prime}}(y,z)\right|(\omega)\geq\delta2^{-n}(\sqrt{n}+\sqrt{r-q})|y-z|\right\}\Big). \end{align*} Let $\mathbf{F}_{\delta}$ be defined by $\mathbf{F}_{\delta}:=\bigcup\limits_{n=1}^{\infty}\mathbf{F}_{\delta,n}$. Next we show that $\mathbb{P}(\mathbf{F}_{\delta})$ tends to $0$ as $\delta$ goes to $\infty$. By the definition of $\mathbf{F}_{\delta}$ and using \eqref{eq:EstDavieSigma1}, we have \begin{align*} \mathbb{P}(\mathbf{F}_{\delta}) \leq&\sum\limits_{n=1}^{\infty}\sum\limits_{k=0}^{2^n-1} \sum\limits_{k^{\prime}=0}^{2^n-1}\sum\limits_{q=0}^{2^{2n+1}}\sum\limits_{r=q}^{\infty}\sum\limits_{(y,z)\in\mathcal{D}_{q,r}}\mathbb{P}\left(\left|\varrho_{nkk^{\prime}}(y,z)\right|\geq \delta 2^{-n}(\sqrt{n}+\sqrt{r-q})|y-z|\right)\\ \leq& 2^{4d}C\sum\limits_{n=1}^{\infty}\sum\limits_{q=0}^{2^{2n+1}}\sum\limits_{r=q}^{\infty}2^{2n}2^{2d(r-q)}e^{-\alpha\delta^2(n+r-q)}\\ \leq& 2^{4d+2}C \sum\limits_{n=1}^{\infty}\sum\limits_{r=0}^{\infty}2^{4n+2dr}e^{-\alpha\delta^2(n+r)}\\ =&4^{2d+1}C \sum\limits_{n=0}^{\infty}\sum\limits_{r=0}^{\infty}2^{4n+2dr}e^{-\alpha\delta^2(1+n+r)}, \end{align*} where $C$ and $\alpha$ are the deterministic constants in Proposition \ref{prop:DavieSheet1dd}. For $\delta\geq\delta^{\ast}:=\sqrt{2(d+2)\alpha^{-1}}$, \begin{align*} \mathbb{P}(\mathbf{F}_{\delta})&\leq4^{2d+1}Ce^{-\alpha\delta^2} \sum\limits_{n=0}^{\infty}\sum\limits_{r=0}^{\infty}2^{4n+r}2^{-\alpha\delta^2(n+r)}\\ &\leq4^{2d+1}Ce^{-\alpha\delta^2} \sum\limits_{n=0}^{\infty}\sum\limits_{r=0}^{\infty}2^{-2dn-4r}\leq4^{2d+1}Ce^{-\alpha\delta^2}. \end{align*} It follows that $\mathbb{P}(\mathbf{F}_{\delta})$ tends to $0$ as $\delta$ goes to $\infty$. Define $\widetilde{\Omega}_14=$ by $$ \widetilde{\Omega}_1:=\bigcup\limits_{\delta\in[\delta^{\ast},\infty[\cap\mathbb{Q}}(\Omega\setminus\mathbf{F}_{\delta}). $$ Observe that $(\mathbf{F}_{\delta},\delta\in[\delta^{\ast},\infty[\cap\mathbb{Q})$ is a nonincreasing family. Then \begin{align*} \mathbb{P}\left(\widetilde{\Omega}_1\right)=1-\lim\limits_{\delta\to\infty}\mathbb{P}(F_{\delta})=1 \end{align*} and for every $\omega\in\widetilde{\Omega}_1$, there exists $\overline{\delta}_{\omega}>0$ such that \begin{align}\label{eq:PseudoMetric2} \left|\varrho_{nkk^{\prime}}(y,z)(\omega)\right|<\overline{\delta}_{\omega}(\sqrt{n}+\sqrt{r-q})2^{-n}|y-z| \end{align} for all choices of $n$, $k$, $k^{\prime}$, $q\in\{0,1,\ldots,2^{n+1}\}$, $r\geq q$ and couples $(y,z)$ in $\mathcal{D}_{q,r}$. Now, let $m$ be the largest nonnegative integer $m$ such that $x\in\mathcal{O}_m$, i.e.$2^{-m-1}<\max\limits_{1\leq i\leq d}|x_i|\leq2^{-m}$. For $r\geq m$ define $x_r=(x_{1,r},\ldots,x_{d,r})$, where $x_{i,r}=2^{-r}\floor*{2^rx_i}$. Then $(0,x_m)\in\mathcal{D}_{m,m}$ and for every $r\geq m$, $(x_r,x_{r+1})\in\mathcal{D}_{m,r+1}$. Moreover, $|x_m-0|\leq \sqrt{d}2^{-m}$ and for every $r\geq m$, $|x_r-x_{r+1}|\leq\sqrt{d}\,2^{-r-1}$. We deduce from \eqref{eq:AddPropRho1}, \eqref{eq:PseudoMetric2} and the inequality $\sum\limits_{r=0}^{\infty}\sqrt{r}2^{-r}\leq 4$ that \begin{align} 2^{n}\Big|\varrho_{nkk^{\prime}}(x,0)(\omega)\Big|&\leq 2^{n} \Big(\Big|\varrho_{nkk^{\prime}}(x_m,0)(\omega)\Big|+ \sum\limits_{r=m}^{\infty}\Big|\varrho_{nkk^{\prime}}(x_{r+1},x_r)(\omega)\Big|\Big)\nonumber\\ \leq&\overline{\delta}_{\omega}\sqrt{dn}2^{-m}+\sqrt{d}\overline{\delta}_{\omega}\sum\limits_{r=m}^{\infty}\left(\sqrt{n}+\sqrt{r-m}\right)2^{-r-1}\nonumber\\ \leq&6\overline{\delta}_{\omega}\sqrt{dn} 2^{-m}\leq 12\overline{\delta}_{\omega}\sqrt{dn}|x|\leq 12\overline{\delta}_{\omega}\sqrt{dn}\Big(|x|+2^{-4^{n}}\Big).\nonumber \end{align} The proof of \eqref{EqPseudoMetric2} is completed by choosing $\widetilde{C}_1=12\sqrt{d}\,\overline{\delta}_{\omega}$. \end{proof} \begin{proof}[Proof of Lemma \ref{lem:PseudoMetric3}] Define $\varrho_{nkk^{\prime}}^+:=\max\{0,\varrho_{nkk^{\prime}}\}$, $\varrho_{nkk^{\prime}}^-:=\max\{0,-\varrho_{nkk^{\prime}}\}$, $x^+:=(x^+_1,\ldots,x^+_d)$ and $x^-:=(x^-_1,\ldots,x^-_d)$, where $x_i^+=\max\{0,x_i\}$ and $x_i^-=\max\{0,-x_i\}$ for every $i\in\{1,\cdots,d\}$. Consider the sequence $(x^+_r)_{r\in\mathbb{N}}=(x^+_{r,1},\ldots, x^+_{r,d})_{r\in\mathbb{N}}$ in $\mathbf{Q}$ defined by $x^+_{r,i}:=1-\floor*{(1-x^+_i)2^r}2^{-r},\,\,i=1,\ldots,d$. Observe that $(x^+_r,r\in\mathbb{N})$ is a coordinatewise nonincreasing sequence of dyadic numbers in $\mathbf{Q}$ converging to $x^+$. It follows from the hypothesis on $b$ and \eqref{eq:coPseudoMetric2} that \begin{align*} \varrho^+_{nkk^{\prime}}(x,0)(\omega)\leq\varrho_{nkk^{\prime}}(x^+_r,0)(\omega)\leq C_2(\omega)\sqrt{n}2^{-n}\Big(|x^+_r|+2^{-4^n}\Big)\text{ for all }n,\,k,\,k^{\prime},\,r. \end{align*} Similarly for $(x^-_r)_{r\in\mathbb{N}}=(x^-_{r,1},\ldots, x^-_{r,d})_{r\in\mathbb{N}}$ defined by $x^-_{r,i}:=1-\floor*{(1-x^-_i)2^r}2^{-r},\,\,i=1,\ldots,d$, we also have \begin{align*} \varrho^-_{nkk^{\prime}}(x,0)(\omega)\leq-\varrho_{nkk^{\prime}}(-x^-,0)(\omega)\leq-\varrho_{nkk^{\prime}}(-x^-_r,0)(\omega)\leq C_2(\omega)\sqrt{n}2^{-n}\Big(|x^-_r|+2^{-4^n}\Big)\text{ for all }n,\,k,\,k^{\prime},\,r. \end{align*} Hence, \begin{align*} |\varrho_{nkk^{\prime}}(x,0)(\omega)|=\varrho^+_{nkk^{\prime}}(x,0)(\omega)+\varrho^-_{nkk^{\prime}}(x,0)(\omega)\leq C_2(\omega)\sqrt{n}2^{-n}\Big(|x^+_r|+|x^-_r|+2\times2^{-4^n}\Big)\text{ for all }n,\,k,\,k^{\prime},\,r. \end{align*} Thus, by taking the limit as $r$ goes to $\infty$, we get \begin{align*} |\varrho_{nkk^{\prime}}(x,0)(\omega)|\leq 2C_2(\omega)\sqrt{n}2^{-n}\Big(|x|+2^{-4^n}\Big)\text{ for all }n,\,k,\,k^{\prime}. \end{align*} Taking $\widetilde{C}_2(\omega)=2C_2(\omega)$ gives the desired result. \end{proof} \subsection{A Gronwall type inequality} The second and last step to prove the uniqueness result is the version of the Gronwall inequality given in Lemma \ref{lem:GronwallSheetd}. Recall that $$u_i^{+}=\max\{0,u_i\},\,\,u_i^{-}=\max\{0,-u_i\}$$ and set $u^{+}=\left(u_1^{+},\ldots,u_d^{+}\right)$ and $u^{-}=\left(u_1^{-},\ldots,u_d^{-}\right)$. \begin{proof}[Proof of Lemma \ref{lem:GronwallSheetd}] Using Lemmas \ref{lem:PseudoMetric2} and \ref{lem:PseudoMetric3}, there exists a subset $\Omega_{2}$ of $\Omega$ with $\mathbb{P}(\Omega_{2})=1$ such that for all $\omega\in\Omega_2$, we have \begin{align}\label{eq:coPseudoMetricc3d} \left|\varrho_{nkk^{\prime}}^{(i)}(0,x)(\omega)\right|:=&\Big|\int_{I_{n,k}}\int_{I_{n,k^{\prime}}}\{b_i(\xi,\zeta,W_{\xi,\zeta}(\omega)+x)-b_i(\xi,\zeta,W_{\xi,\zeta}(\omega))\}\mathrm{d}\xi\mathrm{d}\zeta\Big|\nonumber\\&\leq \widetilde{C}_{2,i}(\omega)\sqrt{n}2^{-n}\left(|x|+\beta(n)\right)\leq\widetilde{C}_{2}(\omega)\sqrt{n}2^{-n}\left(|x|+\beta(n)\right)\,\text{ on }\Omega_{2} \end{align} for all $i\in\{1,\ldots,d\}$, all integers $n,\,k,\,k^{\prime}$ with $n\geq1$, $0\leq k,k^{\prime}\leq 2^n-1$ and all $x\in\mathbf{Q}$, where $\widetilde{C}_2(\omega)=\max\{\widetilde{C}_{2,i}(\omega),\,i=1,\ldots,d\}$. Let $\omega\in\Omega_2$ and let $u$ be a solution to \eqref{eq:DavieSheetGronwalld} satisfying \eqref{eq:GronwallInitialVd}. Choose $n\in\mathbb{N}^{\ast}$ such that $\widetilde{C}_2(\omega)\sqrt{dn}2^{-n}\leq1/2$ and split the set $[0,1]\times[0,1]$ onto $4^n$ squares $I_{n,k}\times I_{n,k^{\prime}}$. Since $u\preceq u^{+}$ and for $i\in\{1,\cdots,d\},\,b_i$, is componentwise nondecreasing, we deduce from \eqref{eq:DavieSheetGronwalld} that for every $(s,t)\in I_{n,k}\times I_{n,k^{\prime}}$ and every $i\in\{1,\cdots,d\}$: \begin{align*} &u_i(s,t)-u_i(s,\kp2^{-n})-u_i(k2^{-n},t)+u_i(2^{-n}(k,k^{\prime}))\\ &=\int_{k2^{-n}}^{s}\int_{\kp2^{-n}}^{t}\{b_i(\xi,\zeta,W_{\xi,\zeta}(\omega)+u(\xi,\zeta))-b_i(\xi,\zeta,W_{\xi,\zeta}(\omega))\}\mathrm{d}\xi\mathrm{d}\zeta\\ &\leq\int_{k2^{-n}}^{s}\int_{\kp2^{-n}}^{t}\{b_i(\xi,\zeta,W_{\xi,\zeta}(\omega)+u^{+}(\xi,\zeta))-b_i(\xi,\zeta,W_{\xi,\zeta}(\omega))\}\mathrm{d}\xi\mathrm{d}\zeta. \end{align*} Then, using the fact that $\max\{0,x+y\}\leq\max\{0,x\}+\max\{0,y\}$ and using once more 2. in Hypothesis \ref{hyp1}, we obtain \begin{align*} u_i^{+}(s,t)&\leq \max\{0,u_i(s,\kp2^{-n})+u_i(k2^{-n},t)-u_i(2^{-n}(k,k^{\prime}))\}\\ &\qquad+\int_{k2^{-n}}^{s}\int_{\kp2^{-n}}^{t}\{b_i(\xi,\zeta,W_{\xi,\zeta}(\omega)+u^{+}(\xi,\zeta))-b_i(\xi,\zeta,W_{\xi,\zeta}(\omega))\}\mathrm{d}\xi\mathrm{d}\zeta. \end{align*} As a consequence, \begin{align}\label{eq:SheetEstuPlusd} u_i^{+}(s,t)\leq u_i^{+}(s,\kp2^{-n})+u_i^{+}(k2^{-n},t)+u_i^{-}(2^{-n}(k,k^{\prime})) +\varrho^{(i)}_{nkk^{\prime}}\Big(0,\overline{u}^{(n)}(k+1,k^{\prime}+1)\Big) \end{align} for all $(s,t)\in I_{n,k}\times I_{n,k^{\prime}}$, where $\overline{u}^{(n)}=\Big(\overline{u}^{(n)}_1,\ldots,\overline{u}^{(n)}_d\Big)$. Similarly, it can be shown that \begin{align}\label{eq:SheetEstMinusd} u_i^{-}(s,t)\leq u_i^{-}(s,\kp2^{-n})+u_i^{-}(k2^{-n},t)+u_i^{+}(2^{-n}(k,k^{\prime})) -\varrho^{(i)}_{nkk^{\prime}}\Big(0,-\underline{u}^{(n)}(k+1,k^{\prime}+1)\Big) \end{align} for all $(s,t)\in I_{n,k}\times I_{n,k^{\prime}}$, where $\underline{u}^{(n)}=\Big(\underline{u}^{(n)}_1,\ldots,\underline{u}^{(n)}_d\Big)$. We also have the following claim: \textbf{Claim}: For all $k\in\{1,2,\cdots,2^n\}$, we have \begin{align}\label{eq:Sheet1DEstOun} \max\Big\{|\overline{u}^{(n)}(k,1)|,|\overline{u}^{(n)}(1,k)|\Big\}\leq 3^kd^{k/2}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+1}\beta(n) \end{align} and \begin{align}\label{eq:Sheet1DEstUun} \max\Big\{|\underline{u}^{(n)}(k,1)|,|\underline{u}^{(n)}(1,k)|\Big\}\leq 3^kd^{k/2}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+1}\beta(n), \end{align} where $|\cdot|$ denotes the usual norm in $\mathbb{R}^d$ \begin{proof}[Proof of the \textbf{Claim}] We will only prove \eqref{eq:Sheet1DEstOun} by induction and the proof of \eqref{eq:Sheet1DEstUun} will follow analogously. Let $(s,t)\in I_{n,0}\times I_{n,0}$. Since $\max\{|u|(0,0),|u|(s,0),|u|(0,t)\}\leq\beta(n)$, using \eqref{eq:SheetEstuPlusd} and \eqref{eq:coPseudoMetricc3d}, we have \begin{align*} u_i^{+}(s,t)\leq3\beta(n)+\varrho^{(i)}_{n11}\Big(0,\overline{u}^{(n)}(1,1)\Big)\leq3\beta(n)+ \widetilde{C}_{2}(\omega)\sqrt{n}2^{-n}\Big(|\overline{u}^{(n)}(1,1)|+\beta(n)\Big). \end{align*} By the definition of $\overline{u}^{(n)}$ and the Euclidean norm \begin{align*} |\overline{u}^{(n)}(1,1)|\leq 3\sqrt{d}\beta(n)+\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\left(|\overline{u}^{(n)}(1,1)|+\beta(n)\right). \end{align*} Then, since $(1-\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n})^{-1}\leq 1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}$, we have \begin{align} |\overline{u}^{(n)}(1,1)|\leq& \Big(3\sqrt{d}+\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)\beta(n)\notag\\ \leq&3\sqrt{d}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^2\beta(n). \end{align} Now, let $k\in\{1,\ldots,2^n-1\}$ and by induction suppose \begin{align}\label{eq:SheetInductionHypd} \max\Big\{|\overline{u}^{(n)}(k,1)|,|\overline{u}^{(n)}(1,k)|\Big\}\leq 3^kd^{k/2}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+1}\beta(n). \end{align} Let $(s,t)\in I_{n,k}\times I_{n,0}$. Since $\max\{|u|(s,0),|u|(q2^{-n},0)\}\leq\beta(n)$, and using once more \eqref{eq:SheetEstuPlusd}, we have \begin{align*} u_i^{+}(s,t)&\leq 2\beta(n)+u_i^{+}(k2^{-n},t)+\varrho^{(i)}_{nk1}(0,\overline{u}^{(n)}(k+1,1))\\ &\leq 2\beta(n)+\overline{u}^{(n)}_i(k,1)+\widetilde{C}_{2}(\omega)\sqrt{n}2^{-n}(|\overline{u}^{(n)}(k+1,1)|+\beta(n))\text{ for every }i. \end{align*} Hence \begin{align*} \overline{u}^{(n)}_i(k+1,1)\leq 2\beta(n)+\overline{u}^{(n)}_i(k,1)+\widetilde{C}_{2}(\omega)\sqrt{n}2^{-n}(|\overline{u}^{(n)}(k+1,1)|+\beta(n)) \text{ for every }i. \end{align*} As a consequence, \begin{align*} |\overline{u}^{(n)}(k+1,1)|\leq2\sqrt{d}\beta(n)+|\overline{u}^{(n)}(k,1)|+\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}(|\overline{u}^{(n)}(k+1,1)|+\beta(n)), \end{align*} yielding to \begin{align*} |\overline{u}^{(n)}(k+1,1)|\leq \left(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\right)\left(2\sqrt{d}\beta(n)+|\overline{u}^{(n)}(k,1)|+\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\beta(n)\right). \end{align*} Using $\widetilde{C}_{2}(\omega)\sqrt{n}2^{-n}\leq1$, we deduce from \eqref{eq:SheetInductionHypd} that \begin{align}\label{eq:SheetInductionHypS1Ad} |\overline{u}^{(n)}(k+1,1)|&\leq\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)\Big[3^kd^{k/2}(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n})^{k+1}+3\sqrt{d}\Big]\beta(n)\nonumber\\ &\leq \Big(3^kd^{k/2}+3\sqrt{d}\Big)\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+2}\beta(n)\nonumber\\ &\leq3^{k+1}d^{(k+1)/2}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+2}\beta(n). \end{align} It can also be shown analogously that \begin{align}\label{eq:SheetInductionHypS1Bd} |\overline{u}^{(n)}(1,k+1)|\leq 3^{k+1}d^{(k+1)/2}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+2}\beta(n). \end{align} This ends the proof of \eqref{eq:Sheet1DEstOun}. \end{proof} Now we prove by induction that $k,k^{\prime}\in\{1,\ldots,2^n\}$, \begin{align*} \max\left\{|\overline{u}^{(n)}(k,k^{\prime})|,|\underline{u}^{(n)}(k,k^{\prime})|\right\}\leq \left(3\sqrt{d}\right)^{k+k^{\prime}-1}\left(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\right)^{k+k^{\prime}}\beta(n). \end{align*} We deduce from \eqref{eq:Sheet1DEstOun} and \eqref{eq:Sheet1DEstUun} that \eqref{eq:GronwallSheetEstd} holds for all couples $(1,k)$, $(k,1)$, $k\in\{1,2,\ldots,2^n\}$. Fix $(k,k^{\prime})\in\{1,2,\ldots,2^n\}$ and suppose \eqref{eq:GronwallSheetEstd} holds for $(k,k^{\prime})$, $(k+1,k^{\prime})$ and $(k,k^{\prime}+1)$. It follows from (\ref{eq:SheetEstuPlusd}) that for every $(s,t)\in I_{n,k}\times I_{n,k^{\prime}}$ and every $i\in\{1,\ldots,d\}$, \begin{align*} u_i^{+}(s,t)\leq u_i^{+}(2^{-n}k,t)+u_i^{+}(s,2^{-n}k^{\prime})+u_i^{-}(2^{-n}k,2^{-n}k^{\prime})+\varrho^{(i)}_{nkk^{\prime}}\left(0,\overline{u}^{(n)}(k+1,k^{\prime}+1)\right) \end{align*} and by \eqref{eq:coPseudoMetricc3d}, \begin{align*} &\overline{u}^{(n)}_i(k+1,k^{\prime}+1)\\ &\leq \overline{u}^{(n)}_i(k,k^{\prime}+1)+\overline{u}^{(n)}_i(k+1,k^{\prime})+\underline{u}^{(n)}_i(k,k^{\prime})+\widetilde{C}_{2}(\omega)\sqrt{n}2^{-n}\Big(|\overline{u}^{(n)}(k+1,k^{\prime}+1)|+\beta(n)\Big). \end{align*} Hence \begin{align*} &|\overline{u}^{(n)}(k+1,k^{\prime}+1)|\\ &\leq |\overline{u}^{(n)}(k,k^{\prime}+1)|+|\overline{u}^{(n)}(k+1,k^{\prime})|+|\underline{u}^{(n)}(k,k^{\prime})|+\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big(|\overline{u}^{(n)}(k+1,k^{\prime}+1)|+\beta(n)\Big), \end{align*} that is \begin{align*} &(1-\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n})|\overline{u}^{(n)}(k+1,k^{\prime}+1)|\\ &\leq |\overline{u}^{(n)}(k,k^{\prime}+1)|+|\overline{u}^{(n)}(k+1,k^{\prime})|+|\underline{u}^{(n)}(k,k^{\prime})|+\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\beta(n). \end{align*} Since \eqref{eq:GronwallSheetEstd} holds for $(k,k^{\prime})$, $(k+1,k^{\prime})$ and $(k,k^{\prime}+1)$, we obtain \begin{align*} &(1-\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n})|\overline{u}^{(n)}(k+1,k^{\prime}+1)|\\ \leq&\Big\{2(3\sqrt{d})^{k+k^{\prime}}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+k^{\prime}+1}\\ &+(3\sqrt{d})^{k+k^{\prime}-1}\Big(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big)^{k+k^{\prime}}+\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\Big\}\beta(n)\\ \leq&\left(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\right)^{k+k^{\prime}+1}\Big(2(3\sqrt{d})^{k+k^{\prime}}+(3\sqrt{d})^{k+k^{\prime}-1}+1\Big)\beta(n). \end{align*} Using the inequalities $$(1-\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n})^{-1}\leq(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n})$$ and $$2(3\sqrt{d})^{k+k^{\prime}}+(3\sqrt{d})^{k+k^{\prime}-1}+1\leq (3\sqrt{d})^{k+k^{\prime}+1},$$ we have \begin{align*} |\overline{u}^{(n)}(k+1,k^{\prime}+1)|\leq\left(3\sqrt{d}\right)^{k+k^{\prime}+1}\left(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\right)^{k+k^{\prime}+2}\beta(n). \end{align*} Similarly, we show that \begin{align*} |\underline{u}^{(n)}(k+1,k^{\prime}+1)|\leq\left(3\sqrt{d}\right)^{k+k^{\prime}+1}\left(1+2\widetilde{C}_{2}(\omega)\sqrt{dn}2^{-n}\right)^{k+k^{\prime}+2}\beta(n). \end{align*} The proof is completed by choosing $C_1=2\widetilde{C}_2$. \end{proof}
{ "redpajama_set_name": "RedPajamaArXiv" }
9,973
{"url":"https:\/\/codegolf.meta.stackexchange.com\/questions\/2140\/sandbox-for-proposed-challenges?page=50&tab=votes","text":"# What is the Sandbox?\n\nThis \"Sandbox\" is a place where Code Golf users can get feedback on prospective challenges they wish to post to the main page. This is useful because writing a clear and fully specified challenge on the first try can be difficult. There is a much better chance of your challenge being well received if you post it in the Sandbox first.\n\nSee the Sandbox FAQ for more information on how to use the Sandbox.\n\n## Get the Sandbox Viewer to view the sandbox more easily\n\nTo add an inline tag to a proposal use shortcut link syntax with a prefix: [tag:king-of-the-hill]\n\n\u2022 Comment: while this problem is solvable in polynomial time, I guess the code-golf submissions are going to take exponential time. \u2013\u00a0user202729 Jul 16 at 6:40\n\u2022 @user202729 Do you actually have a polynomial tome algorithm? \u2013\u00a0Ad Hoc Garf Hunter Jul 16 at 12:23\n\u2022 Yes. -- -- -- -- -- -- \u2013\u00a0user202729 Jul 16 at 13:29\n\u2022 @user202729 What is it? \u2013\u00a0Ad Hoc Garf Hunter Jul 16 at 13:34\n\u2022 Iterate over substrings of the string, then check if it satisfies with f(left, right, prefix) = (can eraser[:prefix] be formed from string[left:right] by repeated erase operations?) At most this is O(n^6). \u2013\u00a0user202729 Jul 16 at 13:38\n\u2022 I cannot understand your notation so I do not understand your algorithm, but I will say it seems to me that checking whether an eraser erases a string should na\u00efvely take O(2^n) since in strings like \"ototoo\" it matters which \"oto\" you erase first thus you have to branch between the possible choices. \u2013\u00a0Ad Hoc Garf Hunter Jul 16 at 14:22\n\u2022 The notation is like Python, string[left:right] is character from left..right (inclusive), eraser[:prefix] is eraser[0:prefix], characters are 0-indexed. \u2013\u00a0user202729 Jul 16 at 14:32\n\u2022 It's possible to compute each f(left, right, prefix) value from O(n) other values (dynamic programming) and there's only O(n^3) possible parameters. \u2013\u00a0user202729 Jul 16 at 14:33\n\u2022 @user202729 Ok, It looked like python but it didn't make any sense as python code, might you actually write this in python? It still doesn't make a whole lot of sense and even then feels like it should be O(2^n) because of \"can [...] be formed from [...] by repeated erase operations?\" seems to be an O(2^n) check to me. \u2013\u00a0Ad Hoc Garf Hunter Jul 16 at 14:37\n\u2022 f=lambda left, right, prefix: string[left:right]==eraser[:prefix] or (left!=right and (string[right-1]==eraser[prefix-1] and f(left, right-1, prefix-1) or f(left, right, len(eraser) or any(f(left, middle, prefix) and f(middle, right, 0) for middle in range(left+1, right)))), something like that, with caching. \u2013\u00a0user202729 Jul 16 at 14:42\n\u2022 Looks like this problem (or a similar one) has already appeared somewhere else. See codeforces.com\/blog\/entry\/14090 \u2013\u00a0user202729 Jul 16 at 14:46\n\u2022 @user202729 Ok so I've spent a little while unpacking that algoirthm in the blog post and it seems to be O(2^n) unless there is some invariant I am missing. I will say I still do not have the slightest understanding of your algorithm. \u2013\u00a0Ad Hoc Garf Hunter Jul 16 at 15:22\n\u2022 About the blog: if you understood it then there is no way it can be 2^n because there are only n^2 different states (possible parameter values) of the dp function . \u2013\u00a0user202729 Jul 17 at 2:44\n\u2022 @user202729 The issue is that calculating a cell is not contsant time sometimes we are required to solve the entire problem again on a smaller string to fill in a cell. You can make schemes where the number of these cells is linear witht he size of the program, hence exponential time overall. however at this point I have found a dynamic programming algo that does this in O(n^4), so it doesn't matter much to me any more. \u2013\u00a0Ad Hoc Garf Hunter Jul 17 at 3:23\n\n## Ant Storage Labyrinth code-golfmatrixarray-manipulationgrid\n\n### Description\n\nUsing a simplified model, the place where ants store their food can be thought of as an $$\\n\\times n\\$$ matrix. Each entry of the matrix is an integer that encodes how full that specific spot is, according to the following correspondence:\n\n\u2022 0 denotes an empty spot (the ants can add two more units of food),\n\u2022 1 denotes a half-filled spot (the ants can add one more unit of food),\n\u2022 2 denotes a filled spot (no more food can be stored in there).\n\nImagine an ant carrying $$\\f\\$$ units of food, that enters the \"storage room\" at a specific position (row $$\\i\\$$, column $$\\j\\$$ of the matrix). The ant can move one unit left, right, up or down with each step, and it can drop $$\\2-q\\$$ units of food at each spot it walks over (where $$\\q\\$$ is the initial capacity of that spot \u2013 either 0, 1 or 2 as described above). Your task is to find the length of the shortest path the ant can choose in order to store all $$\\f\\$$ units of food.\n\n### Example\n\nLet's say that the ant carries $$\\4\\$$ units and enters the following storage room ($$\\6\\times 6\\$$ matrix) at position $$\\(3,3)\\$$ (1-indexed):\n\n$$\\left[\\begin{matrix}0&2&2&2&2&2\\\\2&1&2&2&2&1\\\\1&2&\\color{red}{1}&2&1&1\\\\2&1&2&2&2&2\\\\2&2&2&2&2&2\\\\1&2&2&1&2&2\\\\\\end{matrix}\\right]$$\n\nIt drops $$\\1\\$$ unit right where it starts ($$\\3\\$$ left), then it has four optimal choices:\n\n\u2022 3 moves to the right, and 1 up,\n\n$$\\longrightarrow\\left[\\begin{matrix}0&2&2&2&2&2\\\\2&1&2&2&2&1\\\\1&2&\\color{green}{2}&\\color{red}{2}&1&1\\\\2&1&2&2&2&2\\\\2&2&2&2&2&2\\\\1&2&2&1&2&2\\\\\\end{matrix}\\right]\\longrightarrow\\left[\\begin{matrix}0&2&2&2&2&2\\\\2&1&2&2&2&1\\\\1&2&\\color{green}{2}&\\color{green}{2}&\\color{red}{1}&1\\\\2&1&2&2&2&2\\\\2&2&2&2&2&2\\\\1&2&2&1&2&2\\\\\\end{matrix}\\right]\\longrightarrow\\left[\\begin{matrix}0&2&2&2&2&2\\\\2&1&2&2&2&1\\\\1&2&\\color{green}{2}&\\color{green}{2}&\\color{green}{2}&\\color{red}{1}\\\\2&1&2&2&2&2\\\\2&2&2&2&2&2\\\\1&2&2&1&2&2\\\\\\end{matrix}\\right]\\\\\\longrightarrow\\left[\\begin{matrix}0&2&2&2&2&2\\\\2&1&2&2&2&\\color{red}{1}\\\\1&2&\\color{green}{2}&\\color{green}{2}&\\color{green}{2}&\\color{green}{2}\\\\2&1&2&2&2&2\\\\2&2&2&2&2&2\\\\1&2&2&1&2&2\\\\\\end{matrix}\\right]\\longrightarrow\\left[\\begin{matrix}0&2&2&2&2&2\\\\2&1&2&2&2&\\color{green}{2}\\\\1&2&\\color{green}{2}&\\color{green}{2}&\\color{green}{2}&\\color{green}{2}\\\\2&1&2&2&2&2\\\\2&2&2&2&2&2\\\\1&2&2&1&2&2\\\\\\end{matrix}\\right]$$\n\n\u2022 2 moves to the left, and 2 up,\n\n\u2022 1 move up, 2 left, and one up,\n\n\u2022 1 move up, 1 left, 1 up, 1 left.\n\nAll of these require $$\\4\\$$ steps, so the final answer is $$\\\\boxed{4}\\$$.\n\n## Test cases\n\nIn progress. I need help coming up with interesting test cases \/ maybe a verification program.\n\n Question Posted\nQuestion Posted\n\n\n\u2022 So what's the scoring citeria? \u2013\u00a0HighlyRadioactive Jul 18 at 23:57\n\u2022 @HighlyRadioactive The maximum string length found between the RNA representation of MN908947.3 and the DNA or RNA representation of some other non-coronavirus organism. Or the maximum length multiplied by three of the maximum string found in common between the representation of a protein of MN908947.3 and that of a living non-coronavirus organism. \u2013\u00a0user58988 Jul 19 at 2:36\n\u2022 Then a random brute-force solution would win as long as it's acturate. \u2013\u00a0HighlyRadioactive Jul 19 at 2:41\n\u2022 Or is this not a code-challenge, but a programming puzzle? \u2013\u00a0HighlyRadioactive Jul 19 at 2:41\n\u2022 Yes possible is a programming puzzle, code is only for find string equal ... but strings are long and the algo seems to me at last O(n^2) \u2013\u00a0user58988 Jul 19 at 3:13\n\u2022 Code Golf Stack Exchange is a site for recreational programming competitions, not general programming questions. Challenges must have an objective scoring criterion, and it is highly recommended to first post proposed challenges in the Sandbox. \u2013\u00a0HighlyRadioactive Jul 19 at 3:15\n\u2022 Obiective score exist, i explain it above for the remain free of downvote that \u2013\u00a0user58988 Jul 19 at 3:21\n\u2022 What program would win then? \u2013\u00a0HighlyRadioactive Jul 19 at 3:22\n\u2022 The winner is the one who finds in GenBak the genetic code or a protein of a being that is not a coronavirus (but it can be a virus), that has L genomic lenght as calculate above for genome or for proteine, more big respect to sarscov19 virus (the one name MN908947.3 in GenBank) ). \u2013\u00a0user58988 Jul 19 at 3:23\n\u2022 How would multiple programs compete? \u2013\u00a0HighlyRadioactive Jul 19 at 3:25\n\n## The ASCII character countdown! answer-chainingrestricted-source\n\nYour task is simple: Choose any printable ASCII character that's not chosen in the previous answers. And then, you need to print your chosen character in your program to standard output. (You can ONLY print your chosen character, without printing other garbage to STDOUT)\n\n## The catch\n\nLet's say you picked x as your chosen character, and your answer is the answer numbered y. You have to insert y x's into the previous source code, at any position you like. For the first answer, the previous answer is the empty program.\n\n## An example\n\nAnswers have to start with the number 1. So for example, I chose the character #, and I posted a 1 byte answer in \/\/\/ that prints the # mark.\n\n#\n\n\nAnd then, the second answer (numbered 2) has to insert 2 of their picked x character into the previous source code, such that the modified code will print their x character. So assume this is written in Keg:\n\nx#x\n\n\nAnd then, the third answer has to do the same, and so on, until 95 is reached.\n\n## The winning criterion & other rules\n\n\u2022 The first user whose answer stays without a succeeding answer for a month wins the challenge. If that's not satisfied, the first person who reaches the number 95 wins the challenge.\n\u2022 You are not allowed to put any other character in your code other than printable ASCII characters.\n\u2022 You need to wait for an hour before posting a chaining answer.\n\u2022 The answers are allowed to be in different languages.\n\u2022 Each submission doesn't have to be in a unique language.\n\u2022 You could only insert y x's into the source code.\n\u2022 Can the answers be in different langauges? \u2013\u00a0fireflame241 Jul 20 at 4:03\n\u2022 What is the motivation for the number 95? \u2013\u00a0fireflame241 Jul 20 at 4:03\n\u2022 This isn't a radiation hardening challenge, as those require programs to still work \/ do something different if any single character is removed. \u2013\u00a0Lyxal Jul 21 at 9:15\n\u2022 @fireflame241 Because there are 95 ASCII characters of course... \u2013\u00a0user202729 Jul 21 at 12:50\n\u2022 Must we only insert y xs, or may we also insert other (printable ASCII) characters apart from our chosen character? If the latter, are the additional characters limited to those not already used in previous answers? \u2013\u00a0Dingus Jul 21 at 15:02\n\u2022 \"I chose the character ?\" -> \"I chose the character #\"? \u2013\u00a0user202729 Jul 22 at 6:10\n\u2022 \"has to insert their picked x character into the previous source code,\" -> edit this part too. \u2013\u00a0user202729 Jul 22 at 6:11\n\u2022 @Dingus Now you may only insert y xs. \u2013\u00a0user92069 Jul 23 at 0:56\n\u2022 \"I chose the character ?\" has crept back in. Other than that it's clear now. (Seems difficult too, but maybe not in the golfing langs - I don't know.) \u2013\u00a0Dingus Jul 23 at 2:18\n\n# Error Once, Hello World Twice\n\nYour task here is to write a Hello World program that, (no, this is not Do X Without Y!) contains two exact copies of the same string. to avoid trivial solutions like print \"Hello World!\"# your program must error out with only one copy.\n\nThis is code-golf, so shortest answer in bytes wins.\n\n## Sandbox\n\n\u2022 Wording?\n\u2022 Tags?\n\u2022 Length?\n\u2022 Interesting enough to be posted?\n\u2022 I double the source code, you print hello world? (I'm not saying this is a dupe, I'm asking if that accurately summaries the challenge.) \u2013\u00a0Lyxal Jul 25 at 11:28\n\u2022 @Lyxal Yep. (15chars) \u2013\u00a0HighlyRadioactive Jul 25 at 12:04\n\u2022 What if, rather than erroring out with one copy, make it so that it's valid if it prints out anything other than \"Hello world\"? \u2013\u00a0Beefster Jul 30 at 16:40\n\u2022 @Beefster Maybe... But that's probably not what I'm intending. I might consider later. \u2013\u00a0HighlyRadioactive Jul 31 at 10:25\n\u2022 @HighlyRadioactive this also reminds me of my 2 cats in a quine challenge from a while ago. My main concern here is that \"erroring out\" is nebulous and different for every language. You could also make it so that the program must print nothing unless it's duplicated. \u2013\u00a0Beefster Jul 31 at 16:13\n\n# Successive operator sequences code-golfmatharithmetic\n\nA successive operator sequence (made up terminology) is a sequence of the form $$\\a(n + 1) = a(n) \\text{ op } n\\$$ where op cycles through a set of operators and $$\\a(n)\\$$ represents the $$\\n\\$$th term of the sequence.\n\nFor examples, if we set the operators to addition, multiplication and subtraction and $$\\a(1) = 1\\$$. then we will get the following sequence (which is also A047908):\n\na(1) = 1\na(2) = a(1) + 1 = 1 + 1 = 2\na(3) = a(2) * 2 = 2 * 2 = 4\na(4) = a(3) - 3 = 4 - 3 = 1\na(5) = a(4) + 4 = 1 + 4 = 5\na(6) = a(5) * 5 = 5 * 5 = 25\n\n\nWrite a program\/function to output the $$\\n\\$$th term of a successive operator sequence given its initial term and operators.\n\n\u2022 multiplication\n\u2022 subtraction\n\u2022 integer division (rounded towards negative infinity)\n\n## Input Format\n\nThe operators are inputted as a string or array of character where each character represents an operator, you may choose your own mapping of character to operator.\n\n## Scoring\n\nThis is so shortest bytes wins.\n\n## Testcases\n\n# first term, operators, n -> nth term\n0, [\"+\", \"-\", \"*\", \"\/\"], 6 -> 4\n1, [\"+\", \"*\", \"-\"], 1 -> 1\n1, [\"+\", \"*\", \"-\"], 3 -> 4\n1, [\"+\", \"*\", \"-\"], 10 -> 199\n1, [\"*\", \"+\", \"-\"], 7 -> -1\n50, [\"*\", \"+\", \"-\"], 1 -> 50\n50, [\"*\", \"+\", \"-\"], 4 -> 49\n-10, [\"*\", \"\/\", \"-\"], 5 -> -32\n-10, [\"*\", \"\/\", \"-\"], 3 -> -5\n1, [\"+\", \"+\", \"*\"], 5 -> 16\n2, [\"+\", \"*\"], 5 -> 36\n0, [\"+\"], 3 -> 3\n\n\nInspired by the sequence A047908\n\n\u2022 Suggested test cases: only one operation; duplicate operations (like [\"+\",\"+\",\"-\"]); more than 4 operations. Also, should integer division round toward zero, toward negative infinity, or something else? \u2013\u00a0Zgarb Jul 18 at 19:10\n\u2022 Does each string have to be one byte? \u2013\u00a0fireflame241 Jul 19 at 19:26\n\u2022 @fireflame, they have to be a single character not a single byte. \u2013\u00a0Mukundan314 Jul 20 at 15:23\n\u2022 Why rounding division towards negative infinity? A lot of languages round integer division towards zero and this will add complexity just to do that. Notice that A047908 doesn't use division at all so why add it and make it a problem? Maybe even make it optional which way your answer does it as long as it's stated. \u2013\u00a0Noodle9 Jul 27 at 17:59\n\n# CoGo Rally\n\nThere's a game called Robo Rally, in which players \"program\" their robots five moves ahead, then simultaneously perform the moves, one at a time. The robots move over a \"factory floor\" grid, with the aim being to reach certain points on the board, in sequence, before the other robots do the same.\n\n# Game Rules\n\nFor the purposes of this challenge, the rules will be simplified as follows:\n\n\u2022 Each robot starts with 6 lives\n\u2022 Each robot has a different, randomly assigned starting position (out of a fixed set of starting positions)\n\u2022 The aim of the game is to reach all three checkpoints in the assigned order, before any other robot does the same.\n\n## Movement Options\n\nEach turn, your robot can make any one of the following movements:\n\n\u2022 Rotate Clockwise 90 degrees\n\u2022 Rotate Counter-clockwise 90 degrees\n\u2022 Rotate 180 degrees\n\u2022 Move Forward One\n\u2022 Move Forward Two\n\u2022 Move Forward Three [can only be used once until the next checkpoint is met]\n\u2022 Reverse One (and stay facing the same way)\n\u2022 Stay Still and gain 1 life, up to the maximum of 6\n\nYour moves are pre-programmed in blocks of five, so choose carefully! The board may well be in a very different state in five moves time to what you think it will be.\n\nAdditionally, each movement is assigned a priority from 1-100. When you choose your block of five movements (you may use each movement any number of times, except the \"move forward three\", to form your five total movements) and the order they will occur in, you are also given five random numbers 1-100 to assign - one to each movement. Higher numbers will take priority where movements would cause two robots to enter the same space, for example.\n\n## Board Items\n\nThe board contains the following items:\n\n\u2022 Floor - the default tile on the board. No special effect.\n\u2022 Walls - block a robot's path. If a robot moves forward or backward into a wall, it wastes that move (i.e. stays still, but doesn't gain a life). If the robot used \"Move Forward Two\", for example, it may be possible that the Robot can only move Forward One, and then stops infront of a wall, wasting the second part of the movement.\n\u2022 Laser gun - fire in a straight line in a specific direction until they hit a wall or a robot. If a robot is ontop of a laser gun, it will be hit but the laser won't fire further. While moving forward two or three, a robot may pass over the path of a laser gun without being affected by it.\n\u2022 Conveyor Belts - at the end of a turn (single movement option), a conveyor belt will move the robot one space in the direction the conveyor is pointing. Doesn't block lasers. Conveyor belts NEVER ROTATE ROBOTS, even if they move the robot in a different direction to the one it is facing. While moving forward two or three, a robot may move over a conveyor belt without being affected by it.\n\u2022 Checkpoints (1,2,3) - act as a save point on the Robot's path and also heals all of a robot's lives and resets their use of the \"Move Forward Three\" action, the first time the checkpoint is visited. Checkpoints must be visited sequentially to be activated. Acts as a piece of floor in all other respects. Robots must END THEIR TURN ON THE CHECKPOINT, after interaction with other Robots; and not just pass over it.\n\u2022 Holes - move the robot back to the previously visited checkpoint, or start position. Robot loses half its remaining life, rounded down. Holes act immediately, as soon as the robot enters the space - it doesn't wait for the \"board interactions\" part of the turn order.\n\n## Interactions\n\nObjects interact as follows:\n\n\u2022 If a Robot moves into a space where another robot already exists, the other robot is shoved (moved) in the direction that the first robot was moving, one space; unless there is a wall or laser in the way. This effect may stack if multiple robots are in a line (i.e. all robots are shoved one space). This may cause a robot to fall into a hole or onto a conveyor belt.\n\u2022 Moving off the edge of the board has the same effect as moving into a hole\n\u2022 If a Laser fires and hits a robot, the robot stops the laser beam, and takes one damage.\n\u2022 If a robot is facing another robot in a straight line with nothing blocking in between (i.e. no walls or other robots), the target robot takes 1 damage\n\u2022 Therefore If two robots are facing towards each other with nothing blocking in between (i.e. no walls or other robots), both robots take one damage.\n\n## Turn Order\n\n1. determine (program) 5 movement options\n2. determine Priorities (1-100) for these five turns\n3. The programmed actions occur:\na. The first movement occurs for each player, in priority order from highest to lowest. Holes are acted on immediately (a robot cannot pass over a hole).\nb. Robot Interactions are resolved (e.g. if one robot shoves another one)\nc. Board Items act (lasers, conveyor belts, checkpoints)\ni. If a robot loses all of its lives, it returns to the previous checkpoint (or start) with half lives (rounded up) and must sit out the remainder of the round d. Robots fire\ni. If a robot loses all of its lives, it returns to the previous checkpoint (or start) with half lives (rounded up) and must sit out the remainder of the round e. Repeat for the remaining 4 movements\n4. Repeat until one robot has reached all three checkpoints sequentially, or all robots have lost their lives\n\n# The Challenge\n\nYour robot must take the board (as a 2D array), and a seed for the Random number generator; and play the game on the given board.\n\nThe board is guaranteed to be solveable (there will always be a path from the start to each of the checkpoints)\n\n# Sample Board\n\nThe above board would be represented in an array as follows:\n\n[0,0,0,0,0,0,0,0,0,0,0,0]\n[0,0,0,0,0,0,0,0,0,0,0,0]\n[0,0,0,0,0,0,LU,0,0,0,0,0]\n[0,0,0,0,0,LL,2,LR,0,0,W,0]\n[H,CL,CL,CL,CL,CL,CL,CL,CL,CL,0,0]\n[0,0,0,0,0,CR,CR,CR,CR,CR,CR,H]\n[0,W,0,0,0,0,0 ,0,0,0,0,0]\n[0,W,0,0,0,0,W,0,W,0,0,0]\n[1,W,0,0,0,0,CR,CR,CD,0,W,3]\n[0,W,CR,CR,CR,0,CU,H,CD,W,0,0]\n[0,LL,CR,CR,CR,CR,CU,CU,CL,0,0,0]\n[0,0,S,S,S,S,0,0,W,0,0,0]\n\n\nWhere\n\nCx = Conveyor (x=Up, Down, Left, Right)\nLx = Laser gun (x=Up, Down, Left, Right)\nS = Start\n1,2,3 = Checkpoints\nW = Wall\nH = Hole\n0 = Floor\n\n\n\n# Sandbox Questions\n\nShould this be , where you implement your robot in the least code possible; or , or something else? If KotH, I've never set one before so some advice would be appreciated!\n\n\u2022 (if this is code golf) is it guaranteed that there exists a solution on every boards? Or only boards such that a solution exists are valid input? \u2013\u00a0user202729 Jul 28 at 10:38\n\u2022 Whether KotH or codegolf, the board will always be solvable (i.e. In all cases all of the checkpoints will be accessible, and there will be at least one path from any starting point to each of the checkpoints) \u2013\u00a0simonalexander2005 Jul 28 at 10:40\n\n# Posted: Legendre's (Unsolved) Conjecture\n\n\u2022 I did post such a challenge once which was well-received, though with language restriction. But posing an unsolved problem as a challenge directly is always risky as you already wrote. Also, a challenge being \"simplistic\" isn't a problem by itself, but involving prime numbers might be a problem, as it gives very little room for golfing in most languages (either requiring trial division boilerplate or having a built-in). \u2013\u00a0Bubbler Jul 28 at 4:20\n\u2022 Regarding the last point -- yes, there was similar challenges before -- and if it stays unsolved for long-enough you can assume that it won't be proven while people are still interested in the challenge. And if someone, while trying to solve the challenge, manages to prove the conjecture then it is good. \u2013\u00a0user202729 Jul 28 at 10:41\n\u2022 No, not KC. -- -- \u2013\u00a0user202729 Jul 28 at 10:42\n\n# The Dungeon Number Sequence code-golfnumberbase-conversion\n\n### Introduction\n\nThe dungeon numbers are introduced by Numberphile, denoting a chain of base conversions. A dungeon number is denoted in the form $$a_{b_{c_{d_\\cdots}}}$$ where all numbers involved are integers with at least two digits. When interpreting the values, each base conversion $$\\a_b\\$$ is treated as from base $$\\b\\$$ to base-10.\n\nThere are two types of dungeons, one starting from $$\\10\\$$ to $$\\n\\$$ from top to bottom, i.e. $$10_{11_{12_{\\cdots_n}}}$$ increasing $$\\1\\$$ for each deeper layer, and one starting from $$\\n\\$$ to $$\\10\\$$ from top to bottom, i.e. $$n_{(n-1)_{(n-2)_{\\cdots_{10}}}}$$ decreasing $$\\1\\$$ for each deeper layer. Each dungeon has two interpretations, top down, i.e. $$(((10_{11})_{12})_\\cdots)_n$$, and bottom up, i.e. $$10_{(11_{(12_{(\\cdots_n)})})}$$, producing 4 dungeon number sequences in total.\n\n### Example\n\nConsidering $$10_{(11_{(12_{13})})}$$. The conversion is bottom up. First $$\\12_{13}\\$$ is converted to $$\\15_{10}\\$$. Then $$\\11_{15}\\$$ is converted to $$\\16_{10}\\$$. Finally $$\\10_{16}\\$$ is converted to $$\\16_{10}\\$$, and this is the value for $$\\n=13\\$$.\n\n### Challenge\n\nWrite a program or function, given an integer $$\\n>=10\\$$ as input, output either the value of the dungeon number sequence at $$\\n\\$$, or the whole sequence from $$\\10\\$$ up to $$\\n\\$$ inclusive. You may choose any sequence from the 4 sequences, but you must state which you have chosen. You must not hardcode the values; your code must work theoretically for all integer $$\\n>=10\\$$.\n\n### Values\n\nn 10 11 12 13 14 15 16 17 18 19 20\n---------------------------------------------------------------------------------\nType 1 (((10_11)_12)_...)_n 10 11 13 16 20 30 48 76 132 420 1640\nType 2 10_(11_(12_(..._n))) 10 11 13 16 20 25 31 38 46 55 65\nType 3 (((n_(n-1))_(n-2))_...)_10 10 11 13 16 20 28 45 73 133 348 4943\nType 4 n_((n-1)_((n-2)_(..._10))) 10 11 13 16 20 25 31 38 46 55 110\n\n\n### Sample IO\n\n\u2022 Type 1 ($$\\(((10_{11})_{12})_\\cdots)_n\\$$)\n\n15 => 30\n20 => 1640\n25 => 19563802363305\n\n\u2022 Type 2 ($$\\10_{(11_{(12_{(\\cdots_n)})})}\\$$)\n\n15 => 25\n20 => 65\n25 => 943\n\n\u2022 Type 3 ($$\\(((n_{(n-1)})_{(n-2)})_\\cdots)_{10}\\$$)\n\n15 => 28\n20 => 4943\n25 => 1092759075796059\n\n\u2022 Type 4 ($$\\n_{((n-1)_{((n-2)_{(\\cdots_{10})})})}\\$$)\n\n15 => 25\n20 => 110\n25 => 3577\n\n\n### Winning Criteria\n\nThis is a challenge, so shortest code for each language wins. No default loopholes.\n\n# Where are the traps? code-golfnumbersequence\n\n### Background Partially copied from my related challenge\n\nThe trapped knight sequence is a finite integer sequence of length 2016, starting from 1, and has the following construction rules:\n\n1. Write a number spiral in the following manner:\n17 16 15 14 13 ...\n18 5 4 3 12 ...\n19 6 1 2 11 ...\n20 7 8 9 10 ...\n21 22 23 24 25 ...\n1. Place a knight on 1.\n2. Move the knight to the grid with the smallest number it can go that has not been visited before, according to the rules of chess (i.e. 2 units vertically and 1 unit horizontally, or vice versa).\n3. Repeat until the knight gets stuck.\n\nIt is known that the sequence ends at 2084 where the knight is trapped. But here is a twist. Suppose a knight can step back to the previous grid whenever it is stuck, and choose the grid with the next smallest number possible. By doing so, the sequence can be further extended until it is stuck again at 2720. Then, the knight steps back and choose another path, which further extends the sequence until it is stuck again at 3325...\n\nThen, we call these numbers at which the knight is being trapped \"traps\". So we now know that the first few traps are at 2084, 2720, 3325, ... and it continues to infinity.\n\n### Challenge\n\nWrite a shortest program or function, receiving an integer $$\\N\\$$ as input, output the first $$\\N\\$$ traps in the extended trapped knight sequence.\n\n### Values\n\nThe first 100 terms of the sequence are as follows.\n\n 2084, 2720, 3325, 3753, 7776, 5632, 7411, 8562, 14076, 8469,\n9231, 22702, 14661, 21710, 21078, 25809, 27112, 24708, 19844, 26943,\n26737, 32449, 31366, 45036, 37853, 37188, 43318, 62095, 67401, 68736,\n70848, 62789, 63223, 69245, 85385, 52467, 71072, 68435, 76611, 84206,\n81869, 70277, 81475, 83776, 70767, 84763, 99029, 82609, 103815, 86102,\n93729, 100614, 108039, 82111, 99935, 85283, 109993, 119856, 119518, 116066,\n109686, 92741, 124770, 92378, 104657, 125102, 107267, 107246, 117089, 117766,\n99295, 121575, 98930, 117390, 123583, 112565, 122080, 111612, 111597, 97349,\n105002, 130602, 133509, 153410, 127138, 143952, 153326, 157774, 122534, 136542,\n163038, 134778, 140186, 162865, 171044, 159637, 171041, 174368, 184225, 152988\n\n\n### Winning Criteria\n\nThe shortest code of each language wins. Restrictions on standard loopholes apply.\n\n# Posted: Antisymmetry of a Matrix\n\n\u2022 Mathematica: AntisymmetricMatrixQ (of course, a non-built-in solution can be much shorter). \u2013\u00a0my pronoun is monicareinstate Jul 30 at 13:12\n\n# Identify the tonic from a key signature\n\n## Objective\n\nGiven a key signature in major, output its tonic.\n\n## Input\n\nAn integer from -14 to +14, inclusive. Its absolute value is the numbers of flats\/sharps. Negative number represents flats, and positive number represents sharps. Note that theoretical keys are also considered.\n\n## Mapping\n\nNote the use of Unicode characters \u266d(U+266D; music flat sign), \u266f(U+266F; music sharp sign), \ud834\udd2a(U+1D12A; musical symbol double sharp), and \ud834\udd2b(U+1D12B; musical symbol double flat).\n\n-14 \u2192 C\ud834\udd2b\n-13 \u2192 G\ud834\udd2b\n-12 \u2192 D\ud834\udd2b\n-11 \u2192 A\ud834\udd2b\n-10 \u2192 E\ud834\udd2b\n-9 \u2192 B\ud834\udd2b\n-8 \u2192 F\u266d\n-7 \u2192 C\u266d\n-6 \u2192 G\u266d\n-5 \u2192 D\u266d\n-4 \u2192 A\u266d\n-3 \u2192 E\u266d\n-2 \u2192 B\u266d\n-1 \u2192 F\n0 \u2192 C\n1 \u2192 G\n2 \u2192 D\n3 \u2192 A\n4 \u2192 E\n5 \u2192 B\n6 \u2192 F\u266f\n7 \u2192 C\u266f\n8 \u2192 G\u266f\n9 \u2192 D\u266f\n10 \u2192 A\u266f\n11 \u2192 E\u266f\n12 \u2192 B\u266f\n13 \u2192 F\ud834\udd2a\n14 \u2192 C\ud834\udd2a\n\nOutput must be a string. Whitespaces are permitted everywhere.\n\n## Rule\n\n\u2022 Invalid inputs fall in don't care situation.\n\u2022 \"Or a sequence of bytes representing a string in some existing encoding\"? (I think this should be the default, but I don't remember seeing any meta post about it) \u2013\u00a0user202729 Aug 4 at 6:06\n\n# Surround a string with \"friendliness pellets\" code-golf\n\nInput a String and surround it with a ellipse of alternating \"friendliness pellets\"(0)\n\nIdea originally from Lyxal.\n\n# Challenge\n\nGiven a single line String of length $$\\<100\\$$, print the string with an ellipse of alternating pellets(0) around it. The ellipse must be 11 lines in height.\n\nThe first line of the ellipse must have at least 1 pellet.\n\nThe middle line of the ellipse must be at least 13 characters long. There must be a padding of one space on each side of the text.\n\nStrings smaller than 9 characters must be padded with spaces equally on both sides to fit the above specification. The right side is allowed to have one extra space if the string is of even length.\n\nThe template for the ellipse is as follows:\n\n 00000..... 6 spaces\n0 4 spaces\n0 2 spaces\n0 1 space\n0 no spaces\n\n\nIf the string's length is greater than or equal to 9; the first line must have $$\\\\text{length}-8\\$$ pellets.\n\n# Example Input and Output\n\nInput:\n\nHello World!\n\nOutput:\n\n 0000\n0 0\n0 0\n0 0\n0 0\n0 Hello World! 0\n0 0\n0 0\n0 0\n0 0\n0000\n\n\nInput\n\n0\n\nOutput\n\n 0\n0 0\n0 0\n0 0\n0 0\n0 0 0\n0 0\n0 0\n0 0\n0 0\n0\n\n\nInput\n\nThe quick brown fox\n\nOutput\n\n 00000000000\n0 0\n0 0\n0 0\n0 0\n0 the quick brown fox 0\n0 0\n0 0\n0 0\n0 0\n00000000000\n\n\nInput\n\nIn this world, it's KILL or BE killed\n\nOutput\n\n 00000000000000000000000000000\n0 0\n0 0\n0 0\n0 0\n0 In this world, it's KILL or BE killed 0\n0 0\n0 0\n0 0\n0 0\n00000000000000000000000000000\n\n\nInput\n\nhi there\n\nOutput\n\n 0\n0 0\n0 0\n0 0\n0 0\n0 hi there 0\n0 0\n0 0\n0 0\n0 0\n0\n\n\n# Example code\n\na=[4,2,1,0] # space length to create circle\n\nstr=gets.chomp;\nl = str.length;\n# print first line of pellets\nprint \" \"*6\nif l<=9 then puts \"0\" else puts \"0\"*(l-8) end\n\n# initial pattern\nfor n in a do\nprint \" \"*n +\"0\"+\" \"*(5-n)\nprint \" \" if l<=9\nprint \" \"*(l-8) if l>9\nputs \" \"*(5-n) +\"0\"\n\nend\n\n# display string with spaces\nif l<9 then puts \"0\"+\" \"*((11-l)\/2).floor + str + \" \"*((12-l)\/2).ceil + \"0\" else puts \"0 #{str} 0\" end\n\n#initial pattern but reversed\nfor n in a.reverse do\nprint \" \"*n +\"0\"+\" \"*(5-n)\nprint \" \" if l<=9\nprint \" \"*(l-8) if l>9\nputs \" \"*(5-n) +\"0\"\nend\n\n# last line(same as first line)\nprint \" \"*6\nif l<=9 then puts \"0\" else puts \"0\"*(l-8) end\n\n\n\u2022 Suggested test case: In this world, it's KILL or BE killed. Also, a reference program would be a good addition. \u2013\u00a0Lyxal Aug 5 at 9:11\n\u2022 Done! hysterical Flowey laughter \u2013\u00a0Razetime Aug 5 at 10:54\n\u2022 Setting a maximum number of characters would be unambiguous, rather than 'length lesser than your console's width'. \u2013\u00a0Dingus Aug 5 at 10:57\n\u2022 I made the threshold to be lesser than 100. \u2013\u00a0Razetime Aug 5 at 11:01\n\u2022 This is exactly how I imagined the challenge would look like. Good job! I look forward to seeing you post it when it's time to do so! \u2013\u00a0Lyxal Aug 5 at 11:01\n\u2022 The specific rules that define the ellipses should be described explicitly, not inferred from either the test cases or the example code. For instance, it appears that all ellipses are expected to be 11 lines high, but this is nowhere stated. \u2013\u00a0Dingus Aug 5 at 11:23\n\u2022 Ok, I fixed that in the question. \u2013\u00a0Razetime Aug 5 at 11:25\n\u2022 (not a problem with the challenge, just a general comment) The circle looks ugly... (you can change the challenge to be \"draw an ASCII art of a you circle surrounding something -- with some circle-drawing algorithm or specification -- but I think there's already some similar challenge? Besides, the current version is easier) \u2013\u00a0user202729 Aug 5 at 11:38\n\u2022 I'm not sure whether one exists. Bresenham's Algorithm geeksforgeeks.org\/bresenhams-circle-drawing-algorithm exists, but I feel like that would be a very different type of question. \u2013\u00a0Razetime Aug 5 at 11:45\n\u2022 The ellipse spec is still not detailed enough. It looks like you have set spacing rules for each line - what are they? Is it allowed to make the ellipse wider than the minimum size needed to contain the string? \u2013\u00a0Dingus Aug 5 at 13:09\n\u2022 I added an ellipse template, annd padding rules. \u2013\u00a0Razetime Aug 6 at 2:12\n\u2022 \u2013\u00a0Dingus Aug 7 at 12:35\n\u2022 Yes, very close, but not exactly the same. \u2013\u00a0Razetime Aug 9 at 4:52\n\u2022 Sure, the specific shapes\/characters are different. But the underlying challenge of surrounding a string with an ASCII shape (a horizontally and vertically symmetric one, at that) is the same. \u2013\u00a0Dingus Aug 9 at 23:37\n\n## Non-ASCII Hello World code-golfrestricted-sourcehello-world\n\nInspired by this post\n\n## Background\n\nUsually, people accuse modern golfing languages for looking like Unicode line noise. Some of them ban all unicode characters in the submissions' source code in their challenges, in order to allow only practical languages to appear among their submissions.\n\nLet's do the other way around: We'll ban all printable ASCII characters and only allow unicode to appear in the source code (which very effectively bans all practical languages, since I'm a practical language hater).\n\nYour task is basically outputting Hello, World!, but none of the printable ASCII characters may appear in your source code.\n\n## Rules\n\n\u2022 By printable ASCII, I mean all characters with the codepoints in the range of [32, 127].\n\n\u2022 Tabs (or the char with the codepoint 8, depending on your language's codepage) and newlines (or the char with the codepoint 10, depending on your language's codepage) don't count as printable, therefore they may appear in the source code.\n\n\u2022 This does seem to kill the hopes of a few esolangs as well. \u2013\u00a0Razetime Aug 9 at 4:51\n\n# LaTeX Fractions\n\nInspired by a TeX SE question.\n\nLaTeX uses \\frac{a}{b} to represent a\/b, which is very unintuitive. Now you have a piece of paper (as in \"research paper\") which happens to use the a\/b format, and your task is to convert it to the LaTeX format.\n\n[to be continued]\n\n\u2022 @RahulVerma Nested fractions? \u2013\u00a0HighlyRadioactive Aug 10 at 13:17\n\n# Posted: Poker for Two king-of-the-hillcard-games\n\nPosted on main here.\n\n\u2022 or would it be better for my controller to follow poker etiquette by not revealing any card that isn't in a showdown?: When I've played poker (albeit digitally) the winner has the choice whether they show or hide their cards. That way, people can show if they were serious about their hand or hide the fact they bluffed. Allowing this system would also potentially add another interesting aspect to the challenge: do I reveal my \"hand\" or not. \u2013\u00a0Lyxal Aug 3 at 7:17\n\u2022 Also, I recommend you deal with replacement - that's how usual poker works: the deck is shuffled after each round. \u2013\u00a0Lyxal Aug 3 at 7:19\n\u2022 This game has no draws, so why shuffle after each round? That practically nullifies the effect of \"no replacement\" and has the bad effect of quantising the game to c possibilities for each bot's card. If you want each round's cards returned to the pack to be shuffled for the next round, you might as well deal floats in the range 0.0 to 1.0. (Or ints 0...c-1 with a very large c.) \u2013\u00a0Rosie F Aug 4 at 6:19\n\u2022 @Lyxal It seems to me that, if a player were allowed to reveal or not reveal their card, \"not revealing\" dominates \"revealing\", so nobody would choose to reveal, so I might as well just not reveal, and save everyone the bother of indicating their choice. Any objections? \u2013\u00a0Rosie F Aug 4 at 6:22\n\n# De-interleave log lines\n\nYou've inherited a server that runs several apps which all output to the same log.\n\nYour task is to de-interleave the lines of the log file by source. Fortunately, each line begins with a tag that indicates which app it is from.\n\n## Logs\n\nEach line will look something like this:\n\n[app_name] Something horrible happened!\n\n\nApp tags are always between square brackets and will contain only alphanumeric characters and underscores. All lines will have an app tag and the app tag will always be the first thing on the line.\n\n## Example\n\nAn entire log might look like this:\n\n[weather] Current temp: 83F\n[barkeep] Fish enters bar\n[barkeep] Fish orders beer\n[stockmarket] PI +3.14\n[barkeep] Fish leaves bar\n[weather] 40% chance of rain detected\n\n\nWhich should output three different logs:\n\n[weather] Current temp: 83F\n[weather] 40% chance of rain detected\n\n[barkeep] Fish enters bar\n[barkeep] Fish orders beer\n[barkeep] Fish leaves bar\n\n[stockmarket] PI +3.14\n\n\nYou are not given the names of the app tags ahead of time. You must determine them only by analyzing the log file.\n\n## Rules and Scoring\n\n\u2022 This is , so shortest code wins.\n\u2022 Standard rules and loopholes apply\n\u2022 Use any convenient IO format, provided that each line is represented as a string, not a parsed tag + message.\n\n## Write a compiler\/interpreter for ...\n\nInspired by the lisp challenge here.\nIt is a series of puzzles.\n\nI don't like to see a simple eval solution, so:\n\n\u2022 interpreting the language is fine\n\u2022 translating the language to a different language is fine.\n\nI think this is specific for each language.\n\nOnly the syntax and the basic commands.\nAlso specific.\n\nWinning criteria should not be code golf.\nThe goal should be that you can \"learn\" an other language by looking at the code.\n\nLanguages that might be good candidates:\n\n\u2022 Lisp\n\u2022 APL\n\u2022 J\n\u2022 Whitespace\n\u2022 Forth\n\u2022 This only works for languages which are small and well defined. BF fits those criteria. Whitespace does too. The others may not. Lisp and Forth have so many dialects that you would have to specify exactly which dialect to support; Lisp, Forth, APL and J might have too many built-ins to fit in an answer: there are character limits. \u2013\u00a0Peter Taylor May 12 '13 at 15:16\n\u2022 You don't have to provide all the built-ins, but that is why it is here. \u2013\u00a0Johannes Kuhn May 12 '13 at 15:38\n\u2022 What defines the \"basic commands\"? \u2013\u00a0ASCIIThenANSI Aug 31 '15 at 17:54\n\u2022 I don't know? Maybe that you can do the basic stuff with it like +,-,print,... \u2013\u00a0Johannes Kuhn Aug 31 '15 at 18:22\n\u2022 I suggest a programmer can implement the tiniest subset of those languages in order to be Turing-complete, as these are non-trivial subsets that can theoretically simulate the rest of the language... \u2013\u00a0user85052 Jun 28 '19 at 4:17\n\u2022 Which human is learning the programming language by looking at the code? \u2013\u00a0MilkyWay90 Aug 26 '19 at 3:23\n\n# Find Maximum number of 4+ letter words from Scabble Tiles\n\nThe challenge is to find the most words with 4 or more letters you can make with one set of scrabble tiles.\n\nThe tile distribution is as follows:\n\n2 Blank Tiles\nA 9 N 6 +====+===========+\nB 2 O 8 | 01 | K J X Q Z |\nC 2 P 2 | 02 | B C M P F |\nD 4 Q 1 | 02 | H V W Y * |\nE 12 R 6 | 03 | G |\nF 2 S 4 | 04 | L S U D |\nG 3 T 6 | 06 | N R T |\nH 2 U 4 | 08 | O |\nI 9 V 2 | 09 | A I |\nJ 1 W 2 | 12 | E |\nK 1 X 1 +====+===========+\nL 4 Y 2\nM 2 Z 1\n\n\nValid words are any words that are 4+ that are available in this file, the official scrabble dictionary.\n\nTiles cannot be used twice. This means you can only have 1 word with a K, J, X, Q, and\/or Z unless you use a blank tile to represent one of these letters.\n\nI'm not sure how I'd do scoring on this. I want shorter code to score better, but I don't want a short piece of code that finds a lot less words to score better than a longer piece that finds many more words.\n\n\u2022 Meh. I don't like dependency on external files; are we allowed to load it, or even embed it into the source code? \u2013\u00a0John Dvorak Dec 17 '13 at 20:00\n\u2022 as for finding more vs. shorter code, you could demand all words be found \u2013\u00a0John Dvorak Dec 17 '13 at 20:19\n\u2022 @JanDvorak Any way to use it. It's a text version of the official scrabble dictionary, it seemed to be the most fitting word list for the task. \"All words being found\" might be hard, considering there are probably many combinations of words that would deplete all the tiles. It's a maximum of 25 words, (25 words, 4 letters each, 100 tiles), but I don't know if it's possible to use all tiles with just 4 letter words. After so many words, you might not have enough tiles to make an actual word, which means you'd either have to go back or accept that you're not using all the tiles. \u2013\u00a0Rob Dec 17 '13 at 20:23\n\u2022 As currently described, this is a no-input task, which means that the answer can be precomputed and then the program only needs to decompress it. Consider rewriting it to take input (either of the word list or of the tiles available). \u2013\u00a0Peter Taylor Dec 18 '13 at 8:01\n\u2022 I suggest taking a list of tiles as input, loading the list of words from a predefined file and requiring all combinations \/ best combination to be found. Of course, if the input is the full list of tiles, the computation is going to take ages. I might allow preprocessing the word list outside the program itself (up to a certain point; a linearithmic growth?) \u2013\u00a0John Dvorak Dec 18 '13 at 8:32\n\u2022 I suggest modifying this so that input is a list of tiles, limited to a full rack or less (therefore 4-7 tiles, since our minimum word length is 4). Input should be assumed to be valid based on the standard set of tiles (e.g.: it wont' have something like 3 J's or 4 G's). This would have some practical use for a player in a scrabble game to figure out their next move (though it does not take into account tiles available to them which are already on the board). \u2013\u00a0Iszi Dec 18 '13 at 21:14\n\u2022 Alternative mode: Input is a list of tiles, maximum 96 (so that at least 4 are remaining in the set). Output only includes words (minimum 4 letters) which can be created without those tiles. This would be interesting as it provides words that may yet be created (though, again, not taking into account usable tiles on the board) at a given point in the game. \u2013\u00a0Iszi Dec 18 '13 at 21:15\n\u2022 Output needs to be decided as either a list of all possible words, or only the highest-scoring word(s). Another enhancement may be to require that the list be sorted descending in order of score (if output is all words), then ascending alphabetically. There's no reason to take each program's output into account for scoring. Since everyone is expected to use the same dictionary, all programs' outputs should be identical (except perhaps in sorting, if that's left out of the spec). So, this should be Code Golf. \u2013\u00a0Iszi Dec 18 '13 at 21:15\n\u2022 It's also worth noting that, as currently written, the task could just be to filter the given dictionary down to words which have 4 or more letters. By its very nature, the Scrabble dictionary should already exclude any words that cannot be made with a Scrabble set. \u2013\u00a0Iszi Dec 18 '13 at 21:18\n\u2022 @Iszi it's not \"what are all the words you can make\", it's \"what are all the words you can make, where every letter used depletes a tile\". There's a max of 25 words if you can use all 100 tiles. \u2013\u00a0Rob Dec 19 '13 at 16:40\n\u2022 I think I misunderstood the problem, then. I thought it was \"all the words possible using a set of tiles\" not \"all the words possible, using only one set of tiles\". Still, my point about code golf remains. There is an absolute maximum to the number of words (each with 4 or more letters) you can make with a single Scrabble set, and a finite number of permutations which can be used to hit that maximum. Every program written with this goal should end up with the same (or nominally similar) output. \u2013\u00a0Iszi Dec 19 '13 at 16:56\n\n# Test for Irreducible Complexity (Check for Redundant Characters)\n\nI may need some additional help coming up with the full spec for this competition. As of right now, this is just a concept.\n\nMany interesting questions, such as the \"42\" question in this sandbox, involve finding the longest program which is not reducible. This means that no set of characters can be removed and still allow the program to function as desired.\n\nThe basic idea is that your program will test a Base Program to make sure that it contains no redundant characters. The input will consist of:\n\n\u2022 Expected Output\n\nYour program will simply evaluate all possible subsequences of the Base Program and verify that none of them give the Expected Output.\n\nThis challenge actually has a utility value to several other challenges. For example, it verifies the results of a \"longest non-reducible\"-type challenge. In addition, it could make sure that a golfed solution cannot be golfed further.\n\nI assume that the winning criteria will be fastest program, as cycling through all the possibilities takes a long time.\n\n## Problems\n\nA sequence of length N has 2^N subsequences. Even if each evaluation is done very quickly, it might be unfeasible to test any program with more than 20 or so characters in a reasonable amount of time.\n\n\u2022 Problem: some subsequences of legitimate answers may be pretty dangerous to the environment. You don't want to eval just everything. \u2013\u00a0John Dvorak Dec 23 '13 at 16:59\n\u2022 @JanDvorak Yes that actually is a serious problem. To what extent is it possible to fix that? \u2013\u00a0PhiNotPi Dec 23 '13 at 17:04\n\u2022 Forbidding any program with dangerous subsequences? :-) \u2013\u00a0John Dvorak Dec 23 '13 at 17:05\n\u2022 A more reasonable (but very difficult) solution would be the requirement to implement a sandbox. \u2013\u00a0John Dvorak Dec 23 '13 at 17:07\n\u2022 Even without dangerous behavior, the halting problem will be an issue: it's hard to tell whether a shortened program will terminate at all, especially for every conceivable input. \u2013\u00a0MvG Jan 7 '14 at 23:49\n\n# Popularity Contest: Implementation of a Hash Table\n\nCreate a class in some OOP language for a hash table that supports getting, setting, and removing values. You can't use the built in hash table\/dictionary\/map implementation. Highest votes in one week wins.\n\nA key is any valid string. A value is any valid string, number, or boolean.\n\nExample functionality:\n\nhash.set(\"key\",\"value\");\nhash.get(\"key\"); \/\/ returns \"value\"\nhash.set(\"key\", 1234);\nhash.get(\"key\"); \/\/ returns 1234\nhash.set(\"key2\",hash.get(\"key\"));\nhash.get(\"key2\"); \/\/ returns 1234\nhash.delete(\"key\");\nhash.get(\"key\"); \/\/ returns null\/undefined\/none\/etc. or throws an error\nhash.get(\"key2\"); \/\/ still returns 1234\n\n\nDefinition of a hash table (from Wikipedia):\n\nIn computing, a hash table (also hash map) is a data structure used to implement an associative array, a structure that can map keys to values. A hash table uses a hash function to compute an index into an array of buckets or slots, from which the correct value can be found.\n\nThe hash table cannot be simply an array that is searched in linear time. It must be an actual hash table that uses a hash function to map the keys to the value.\n\n\u2022 Popularity contest and shortest don't mix. That aside, the spec is too vague. What is a \"value\"? What assumptions can be made about hashcodes? If the language makes all types nullable, should null be permitted as a key? What should the type be in languages which have co- and contravariance? And for that matter, what qualifies as a \"hash table\", bearing in mind that people will try to exploit any loophole? \u2013\u00a0Peter Taylor Jan 2 '14 at 23:16\n\u2022 @PeterTaylor Thank you for the feedback! Please see my edits, and let me know what you think. Could you meant about co\/contravaraince? I looked at the wikipedia article about it but I'm not really sure how that has anything to do with this question. \u2013\u00a0hkk Jan 2 '14 at 23:37\n\u2022 I think it's still vulnerable to the loophole of \"I have a hashtable with one bucket\" (i.e. it's really a list of (key, value) pairs which I traverse in linear time). The thing about variance is to do with static typing of the elements of the map. E.g. in Java Map<String, Integer>'s get method has signature public Integer get(Object); in C#, a Dictionary<string, int>'s Get method has signature public int Get(string). The edited version makes it clear enough that the hashtable isn't expected to be genericised. \u2013\u00a0Peter Taylor Jan 3 '14 at 0:08\n\n# Wordlist detector\n\nYou are to write a program which, given a list of words, constructs a regular expression to match all these words but nothing else. Both your program and the constructed regular expressions are to be as short as possible.\n\n## Input and Output\n\nInput comes on standard input and consists of one line giving n, the total number of words, followed by n lines with one word each. The number of words will be less than 1000, the length of each word less than 30. Words will consist only of lower case ASCII letters, i.e. a-z. You may choose to ignore the first line and use EOF instead to end the list.\n\nOutput shall be written to standard output. It consists of a single line, giving a POSIX extended regular expression to match these words and no others. Since input for this regex is not restricted to letters only, elements like . or [^\u2026] won't make too much sense, which limits the language in a natural way. You may choose whether you want to terminate the line with a newline or not. Programs may choose to print multiple lines of output, in which case only the last one will be used for scoring. So you might print intermediate results and continue searching for improvements.\n\n## Test cases\n\nEach submission may be accompanied by one regular expression. When scoring the submissions, I'll use this regular expression to reconstruct a word list from it. The code to do this reconstruction can be found at the end of this post. The reconstructed word list must fit the input specification above in terms of word count and length. It would be nice if your own program would be able to regenerate that regular expression from the word list, but that is not a strict requirement. But please don't paste bogus programs just to submit a challenging regular expression, though.\n\nThese test cases will be collected and fed to all programs for scoring.\n\n## Scoring\n\nThe final score of each program will be the program size plus the size of all its generated regular expressions for the inputs collected from submitted answers, including the example from this question. So short code which produces too long results might get beaten by longer code which generates shorter expressions.\n\nDoes this still qualify as ?\n\nSubmissions which generate an incorrect regular expression for one of the test cases will be disqualified, as will those which don't terminate in the allotted time. You can use the input reconstruction program below to check whether a produced regular expression does encode the correct word list.\n\n## Requirements\n\nAll submissions are welcome, but in order to include your submission in the tournament, it must be executable with reasonable effort on my Linux machine. It shouldn't depend on any exotic libraries, or any specialized ones which take too much work away from your own program. It must operate in reasonable time, say no more than five minutes per input. Your output must be reproducible, so if you use randomization at some point, please seed the randomizer, and please don't terminate an improove loop by a timer measuring execution time or some such.\n\n## Tournament times\n\nI'll run the first major tournament two weeks after posting this question. I'll include a table of the results in this question. I'll try to run tournaments repeatedly as late submissions arrive, but I'll not promise any regular schedule.\n\n## Example\n\nAn very simple example application would be in Python 3 (53 chars):\n\nprint('|'.join(input() for i in range(int(input()))))\n\n\nAnd here is a test case which could be posted along with the program, although this program obviously doesn't generate exactly this concise output:\n\nbann?ana|ap(fel|ple)|s[ou]n|[hs](a|ou)nd\n\n\nThe expansion of that expression could be turned into the following example input, which need not be posted as part of an answer since it can be deduced from the regular expression:\n\n10\nbanana\nbannana\napfel\napple\nson\nsun\nhand\nhound\nsand\nsound\n\n\n## Regex expander program\n\nAnd here is a program to turn regular expressions into word lists, again written in Python 3.\n\n#!\/bin\/env python3\nconcat = set(('',))\naltin = set(('',))\naltout = set()\nprev = None\nstack = []\nregex = iter(input())\nfor ch in regex:\nif ch == '(':\nstack.append((concat, altin, altout))\naltin = concat\naltout = set()\nprev = None\nelif ch == ')':\nconcat.update(altout)\nprev, altin, altout = stack.pop()\nelif ch == '|':\naltout.update(concat)\nconcat = altin\nelif ch == '[':\nch = regex.__next__()\ncls = []\nwhile ch != ']':\nif ch == '-':\ncrange = range(ord(cls[-1]), ord(regex.__next__()) + 1)\ncls.extend(map(chr, crange))\nelse:\ncls.append(ch)\nch = regex.__next__()\nprev = concat\nconcat = set(w + c for w in prev for c in cls)\nelif ch == '?':\nconcat.update(prev)\nprev = None\nelif ch >= 'a' and ch <= 'z':\nprev = concat\nconcat = set(w + ch for w in prev)\nelse:\nraise Exception(\"Illegal input\")\nif stack:\nraise Exception(\"Unclosed group\")\nconcat.update(altout)\nwords = sorted(concat)\nprint(len(words))\nprint('\\n'.join(words))\n\n\nThis is restricted to the part of regular expression syntax which I expect for this answer. If you have good reason to use something I did not consider, feel free to do so although I will likely have to update this code to cope with it. If you find a bug, please let me know.\n\n\u2022 This is just Meta regex golf under the constraint that the two lists between them cover all possible words. Given that some people are tackling that existing question on that basis, this would qualify for closing as a duplicate. \u2013\u00a0Peter Taylor Jan 8 '14 at 8:45\n\n## Code-Golf: Write a number as an expression that's as short as possible\n\nThe goal of this code-golf is to create a program that takes a number as input (using STDIN, command line arguments, or prompting for input), and outputs that number, but written as an expression that's as short as possible. So, 10000 should become 10^4. If there is no way to write an expression that's shorter than the number, then output just the number.\n\n### Other rules\n\n1. No network access.\n2. You're not allowed to execute an external program.\n3. Only use the operators +, -, *, \/ and ^ (that's raising power, not XOR).\n4. Order of operations must be taken in account. Use parentheses if necessary.\n5. This is a code golf, so the code with the smallest amount of characters wins.\n6. The input will always be smaller than 2^32.\n\n### Test cases\n\n500000000 --> 5*10^8 or 10^9\/2\n999999 --> 10^6-1\n10 --> 10\n4294967295 --> 2^32-1\n16384 --> 2^14\n\n\n## Rhymalator\n\n(at the point, it's just something that came to me before i wake up, so it may need some adjusting, and i'd like some feedback as to if this could be fun)\n\nThe code challenge is to write a program that takes as input a calculation in Reverse Polish Notation and outputs the result. It must at least implement + - * \/. It So far so easy, but to make it fun and \"artistic\", the following restriction applies:\n\n\u2022 The source code must rhyme when read. Example in PHP\n\n$iterator = str_split($a);\nforeach ($iterator as$key=>$value){ if ($key > 3){\n++$virtue; } } (the rhyme is on value-virtue) \u2022 Lines whitout readable characters count as whitespace (the two lines with } in the example) \u2022 How does that example rhyme...? \u2013 Doorknob Jan 25 '14 at 12:54 \u2022 @DoorknobofSnow well, i'm not really a poet, that's why i propose it as a challenge for others :p. if you have a better example i'll replace it \u2013 Einacio Jan 27 '14 at 15:58 # Implement Kalah code-golf The game of Kalah is a two-player board game in the Mancala family. Your implementation must: \u2022 Identify the active player (\"Player 1\" or \"Player 2\") \u2022 Display board state (in format specified below) \u2022 Accept input to allow that player to move (using index system below) \u2022 Announce a winner (\"Player N wins\") # Overview Each player has a line of six spaces, called houses, and one additional space called a store. Each space holds seeds, which move from house to house in a counter-clockwise direction. The objective is to fill your store with seeds. You must represent the board in the following two-row format with stores offset, where HH is a house and SS is a store: SS HH HH HH HH HH HH HH HH HH HH HH HH SS The top row represents the number of seeds in player #1's spaces, and the bottom row represents the seeds in player #2's spaces. The S in each row is the respective player's store (player #1's is top-left, #2's is bottom right). Single-digit values should include a leading space. In this challenge, user-input will identify each house numerically. Use a left-to-right, indexed-from-one scheme for both sides: S 1 2 3 4 5 6 1 2 3 4 5 6 S Note that the players' stores are not numbered, because seeds placed in the store never move out. ## Rules Wikipedia has a good summary of the game and its rules: 1. At the beginning of the game, three seeds are placed in each house. 2. Each player controls the six houses and their seeds on his\/her side of the board. His\/her score is the number of seeds in the store to his\/her right. [Clarification: from our perspective, player 1's store is to the left, player 2's store is to the right.] 3. Players take turns sowing their seeds. On a turn, the player removes all seeds from one of the houses under his\/her control. Moving counter-clockwise, the player drops one seed in each house in turn, including the player's own store but not his\/her opponent's. 4. If the last sown seed lands in the player's store, the player gets an additional move. There is no limit on the number of moves a player can make in his\/her turn. 5. If the last sown seed lands in an empty house owned by the player, and the opposite house contains seeds, both the last seed and the opposite seeds are captured and placed into the player's store. [Clarification: moves that end on an opponent's empty house end normally without a capture.] 6. When one player no longer has any seeds in any of his\/her houses, the game ends. The other player moves all remaining seeds to his\/her store, and the player with the most seeds in his\/her store wins. # Example (Parenthetical text should not appear in actual output.) Player 1 0 3 3 3 3 3 3 3 3 3 3 3 3 0 > 2 (prompt arrow and line break are purely optional) Player 2 1 1 0 3 3 3 3 4 3 3 3 3 3 0 > 4 Player 2 (P2 gets a bonus turn from rule #4) 1 0 3 3 3 3 3 4 3 3 0 4 4 1 > 5 Player 1 1 0 3 3 3 4 4 4 3 3 0 0 5 2 > 4 Player 1 (P1 captures P2's seeds in space 1) 6 0 4 4 0 4 4 0 3 3 0 0 5 2 ... Player 2 12 0 0 10 0 1 0 0 0 0 0 0 1 13 > 6 Player 1 wins (because the non-finishing players gets all remaining seeds on their side, it's 23-14) Meta question: Would this be improved by removing some of the rules? \u2022 Do the players run the game once and then take it in turns to take moves, with the process ending only when the game ends? Or do they run the program once per move? \u2013 Peter Taylor Jan 30 '14 at 10:06 [This is the first time I'm using the sandbox. I want to get feedback\/suggestions before posting the question.] Make a spider web (standard, orb type) that fills frame in the ratio of n:m, where n, m are input integers. You may use the example below as a model (but you don't need to use labels). Your web should have multiple radii, at least 4 of which attach directly to the frame. The remaining radii should attach to the outer outline (perimeter) of the web. The web should have at least 15 radii. The mesh spacing should be more or less uniform spacing (although occasional weaving mistakes\" or crossings are encouraged and will receive a bonus). This is code-golf, so the shortest code (minus bonuses) wins. Bonuses (to be removed from the number of characters in your code). Bonuses are awarded for the following features that reflect the architecture of an actual web (as opposed to a perfectly symmetric rendering). They are somewhat greater than usual as an incentive for attention to detail and realism. -mesh spiral instead of concentric circles: 40 pts -assymmetric web: 31 pts. (e.g. height of capture area greater than width) -irregularly spaced radii: 42 pts -distinct segments between radii (straight or crooked, but not the arc of a circle): 32 pts -outer and inner outline clearly distinct from the spiral: 41 pts -irregular outer outline: 20 pts -2 or more easily observable reverses in spiral: 40 The accept will be awarded on Feb. 20, 2014. \u2022 If there are bonuses then it isn't code-golf, by definition. It's not clear what output formats are acceptable. I'm not sure what you mean by \"distinct segments between radii\". \"2 or more easily observable reverses\" seems problematic: the ease of observing reverses is subjective, and might in addition depend on input and\/or on the random numbers obtained. The weighting for the bonuses seems very arbitrary: is there any justification for it? \u2013 Peter Taylor Feb 3 '14 at 11:49 \u2022 Re: bonuses, I should probably decide on the features I want included in the web, thereby eliminating bonuses altogether. Distinct segments means that there should be 2 straight mesh segments between radius n and radius n+2 (not sure whether this should be required in instructions to be updated.) Will give reverses more thought. \u2013 DavidC Feb 3 '14 at 12:02 ## Write a PHP Code Golfer code-challenge Since my currently daily programming is in PHP, I tend to try the challenges on the site using that language, but frequently I large program because of the verbosity of the language. And then I have to strip it for presentation... But this is not a tips question, it's an eviscerating challenge. The objective is to write a program in the language of your choice that takes a PHP file and outputs a golfed valid PHP file with the same functionality. The scoring will be the average reduction in percent of the result of running the program with 3 selected files (not yet selected, I was thinking of some open source library) The output file should run on at least 5.4 (so shorthand arrays, function dereference, traits are available) Since the score is the difference between the ungolfed and golfed files, techniques beyond minifying are encouraged, such as using code subtitution, eval, compression,$\\$ (variable variables), dereferencing...\n\nScoring example: The 3 sources have 450, 1200 and 3500 chars respectively\n\nresults lenghts: 250, 1000, 3300\nreduction: 200, 200, 200 (44%, 17%, 6%) average: 22%\n\nresults lenghts: 350, 1050, 3150\nreduction: 100, 150, 350 (22%, 13%, 10%) average: 15%\n\nIn this case Answer 1 would win, even tough both answers got the same total reduction (-600 chars)\n\n\u2022 It's a specialisation of codegolf.stackexchange.com\/q\/3652\/194 , so would likely be closed as a duplicate. \u2013\u00a0Peter Taylor Feb 4 '14 at 22:44\n\u2022 @PeterTaylor I saw it. is similar, but I include an objetive goal and score. have any idea on how to make it more unique? \u2013\u00a0Einacio Feb 5 '14 at 2:43\n\u2022 \"Making it shorter\" is too broad, can I just delete some comments? If not, can I only shorten one variable and it's ok. It's not very interesting like this... \u2013\u00a0Fabinout Feb 5 '14 at 9:56\n\u2022 @Fabinout the objective is golfing the code. If you only remove some characters, I doubt you'll get a good score \u2013\u00a0Einacio Feb 5 '14 at 15:27\n\u2022 Alright, the criterion is the size of the output source code. good clarification. \u2013\u00a0Fabinout Feb 5 '14 at 15:55\n\u2022 Sum the bytes with the percents or separately? Also, no matter what sources you choose, make sure to paste the code into your questions; who knows when the code in the library will change? \u2013\u00a0Justin Feb 6 '14 at 19:11\n\u2022 i'll edit the bit about scoring (with examples) tomorrow (when i come back to work). I'll post the test sources as a pastebin, but I'll wait to choose them until the question is polished enough and someone consider it interesting enough \u2013\u00a0Einacio Feb 6 '14 at 19:34\n\u2022 Is there anyone more with questions? is still possible that it will be marked as a duplicate? or can i choose the sources and publish it? \u2013\u00a0Einacio Feb 13 '14 at 19:22\n\n# Create diagonal code\n\nYour task is to create a program that outputs d=s*sqrt(2).\n\nSpecs:\n\n\u2022 Your program must be at least 4 lines long;\n\n\u2022 d=s*sqrt(2) cannot be hardcoded as is (so using ascii, compression, encoding, etc. is allowed and encouraged);\n\n\u2022 For each line of code n, pick up the nth character. The string obtained this way must be a valid program in a programming language of your choice, that must be different from the one you used for the main program. The obtained program must compile successfully, but it can throw errors, exceptions, etc.;\n\n\u2022 If at the nth line there is no nth character, you can consider that character as a whitespace or a newline. This cannot be done for the first 4 lines, which must be long at least n non-whitespace characters.\n\n\u2022 Your main program must end successfully (no errors, exceptions, etc.);\n\n\u2022 Internet access is forbidden;\n\n\u2022 Most upvoted answer in 2 weeks wins.\n\nHappy coding!\n\nI was unsure about making this a with several bonuses (polyglot answer, secondary program still valid, etc...).\n\n### Some bonuses for the code-challenge version:\n\n+15 for any other hidden answer;\n+5 for every hidden answer that runs and ends successfully, without any problem;\n+15 for every hidden answer that is a polyglot;\n\nWhich version would you prefer? Is there something you would change\/improve in this question?\n\nI personally like the one, but the KISS principle (Keep it simple, stupid!) reminds me that I may be wrong.\n\n\u2022 It's trivial to make the diagonal program be just whitespace (many scripting languages will accept this as a program) or H (valid program in H9Q+). \u2013\u00a0Peter Taylor Feb 26 '14 at 9:26\n\u2022 Nowhere does it say that the diagonal program must output your magic string: it doesn't even have to execute correctly. Your amendment doesn't really fix things: I can now have the second line be #H, the third be #HH, etc. \u2013\u00a0Peter Taylor Feb 26 '14 at 9:37\n\u2022 You're right; Don't know why, on a second read I messed up the meaning of your comment. Anyway, I suppose this excludes code-challenge unless I\/we don't find a way to avoid such trivial solutions. I guess popularity-contest would still be ok, since more interesting solutions could be found, right? \u2013\u00a0Vereos Feb 26 '14 at 9:41\n\u2022 I think my views on popularity-contest in general are well known. On further reflection, there are enough languages in which any string of bytes is a valid program that I don't think this question can work as is. If you want to save it, I think you need to look at doing something like a very difficult double-quine. \u2013\u00a0Peter Taylor Feb 26 '14 at 9:49\n\u2022 Thinking about quines and diagonals (which was the \"spirit\" of the question), what about a sort of mini-quine? The main program would have to display d=s*sqrt(2) only, and its diagonal must reproduce the code used to display the magic string (no comments allowed). It could be tagged code-golf or code-challenge. \u2013\u00a0Vereos Feb 26 '14 at 11:04\n\n# Create a Karnaugh-map calculator\n\nGiven an input of a truth table, generate a corresponding K-map.\n\nInput:\n\nInput will be of the form 10110001 where each bit is a row of a truth table. Count from the left to the right; so that input would be a table of:\n\ni2i1i0 f\n0 0 0|1\n0 0 1|0\n0 1 0|1\n0 1 1|1\n1 0 0|0\n1 0 1|0\n1 1 0|0\n1 1 1|1\n\nMax 4 variables will be inputted\n\nK-maps (a small explanation):\n\nK-maps are a way of simplifying boolean-algebra expressions.\n\nLet's say we have 4 variables: a, b, c, d. Let the truth-table be 1110101001111111 (and the columns on the truth table be labeled, from left to right: a, b, c, d). Arrange the variables like so:\n\n cd\nab\\ 00 01 11 10\n00\n01\n11\n10\n\n\nNote the grey-code counting scheme.\n\nFill in the table with the corresponding values from the truth table:\n\n cd\nab\\ 00 01 11 10\n00 1 1 0 1\n01 1 0 0 1\n11 0 1 1 1\n10 1 1 1 1\n\n\nGroup the values in rectangles whose dimensions are the largest possible powers of two. Note that this table signifies a torus, so wrap over the left and right edges.\n\nThe expression for the truth table is the ors of the and of the unchanging elements. For this, that would be:\n\nPurple group: \u00acb \u2227 \u00acc (for 0's, make them 1 by notting the value)\nGreen group: \u00aca \u2227 \u00acd\nBlack group: a \u2227 d\nBlue group: b \u2227 \u00acd\n\nExpression: (\u00acb \u2227 \u00acc) \u2228 (\u00aca \u2227 \u00acd) \u2228 (a \u2227 d) \u2228 (b \u2227 \u00acd)\n\nOutput:\n\n\u2022 Generate a 2D K-map (for more variables, add on either side) and show the grouping. K-map must be of the form I used. For less variables, remove rows or columns and change the list on the top left corner.\n\u2022 assume alphabetical ordering on the variables, that is, the first variable is a, second: b, third: c, and so on.\n\u2022 Also show the expression. Rather than use the unicode characters, the following is permissible:\n\n~ instead of \u00ac\n\n\u2022 Although @Howard's concern is partially answered by \"rectangles whose dimensions are the largest possible powers of two\", it's not obvious to me why you haven't also circled the entire row 10 and the bottom-right quadrant. \u2013\u00a0Peter Taylor Feb 26 '14 at 9:29\n\u2022 Also for higher number of variables you have to either go to n dimensional K-maps or you won't find all possible rectangles (they are no longer adjacent in the matrix). \u2013\u00a0Howard Feb 26 '14 at 9:38\n\u2022 @PeterTaylor In priority: Biggest rectangles, then least number. That is a big rectangle, but it is redundant with the others because every 1 in it is already circled. \u2013\u00a0Justin Feb 26 '14 at 16:44\n\u2022 For the expression: rather than using A and V, why not * and +? That's fairly conventional use of field notation to represent GF(2). \u2013\u00a0Peter Taylor Feb 26 '14 at 17:11\n\u2022 Ahem. OR is, of course, not the same as + in GF(2). But * and +` is still the conventional notation for operations over the Boolean semiring. \u2013\u00a0Peter Taylor Feb 28 '14 at 15:31","date":"2020-08-15 17:45:06","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 1, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 55, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.3483719229698181, \"perplexity\": 1674.998520647086}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2020-34\/segments\/1596439740929.65\/warc\/CC-MAIN-20200815154632-20200815184632-00267.warc.gz\"}"}
null
null
<?php class Twitter { // internal constant to enable/disable debugging const DEBUG = false; // url for the twitter-api const API_URL = 'https://api.twitter.com/1.1'; const SECURE_API_URL = 'https://api.twitter.com'; // port for the twitter-api const API_PORT = 443; const SECURE_API_PORT = 443; // current version const VERSION = '2.3.1'; /** * A cURL instance * * @var resource */ private $curl; /** * The consumer key * * @var string */ private $consumerKey; /** * The consumer secret * * @var string */ private $consumerSecret; /** * The oAuth-token * * @var string */ private $oAuthToken = ''; /** * The oAuth-token-secret * * @var string */ private $oAuthTokenSecret = ''; /** * The timeout * * @var int */ private $timeOut = 10; /** * The user agent * * @var string */ private $userAgent; // class methods /** * Default constructor * * @param string $consumerKey The consumer key to use. * @param string $consumerSecret The consumer secret to use. */ public function __construct($consumerKey, $consumerSecret) { $this->setConsumerKey($consumerKey); $this->setConsumerSecret($consumerSecret); } /** * Default destructor */ public function __destruct() { if($this->curl != null) curl_close($this->curl); } /** * Format the parameters as a querystring * * @param array $parameters The parameters. * @return string */ private function buildQuery(array $parameters) { // no parameters? if(empty($parameters)) return ''; // encode the keys $keys = self::urlencode_rfc3986(array_keys($parameters)); // encode the values $values = self::urlencode_rfc3986(array_values($parameters)); // reset the parameters $parameters = array_combine($keys, $values); // sort parameters by key uksort($parameters, 'strcmp'); // loop parameters foreach ($parameters as $key => $value) { // sort by value if(is_array($value)) $parameters[$key] = natsort($value); } // process parameters foreach ($parameters as $key => $value) { $chunks[] = $key . '=' . str_replace('%25', '%', $value); } // return return implode('&', $chunks); } /** * All OAuth 1.0 requests use the same basic algorithm for creating a * signature base string and a signature. The signature base string is * composed of the HTTP method being used, followed by an ampersand ("&") * and then the URL-encoded base URL being accessed, complete with path * (but not query parameters), followed by an ampersand ("&"). Then, you * take all query parameters and POST body parameters (when the POST body is * of the URL-encoded type, otherwise the POST body is ignored), including * the OAuth parameters necessary for negotiation with the request at hand, * and sort them in lexicographical order by first parameter name and then * parameter value (for duplicate parameters), all the while ensuring that * both the key and the value for each parameter are URL encoded in * isolation. Instead of using the equals ("=") sign to mark the key/value * relationship, you use the URL-encoded form of "%3D". Each parameter is * then joined by the URL-escaped ampersand sign, "%26". * * @param string $url The URL. * @param string $method The method to use. * @param array $parameters The parameters. * @return string */ private function calculateBaseString($url, $method, array $parameters) { // redefine $url = (string) $url; $parameters = (array) $parameters; // init var $pairs = array(); $chunks = array(); // sort parameters by key uksort($parameters, 'strcmp'); // loop parameters foreach ($parameters as $key => $value) { // sort by value if(is_array($value)) $parameters[$key] = natsort($value); } // process queries foreach ($parameters as $key => $value) { // only add if not already in the url if (substr_count($url, $key . '=' . $value) == 0) { $chunks[] = self::urlencode_rfc3986($key) . '%3D' . self::urlencode_rfc3986($value); } } // buils base $base = $method . '&'; $base .= urlencode($url); $base .= (substr_count($url, '?')) ? '%26' : '&'; $base .= implode('%26', $chunks); $base = str_replace('%3F', '&', $base); // return return $base; } /** * Build the Authorization header * @later: fix me * * @param array $parameters The parameters. * @param string $url The URL. * @return string */ private function calculateHeader(array $parameters, $url) { // redefine $url = (string) $url; // divide into parts $parts = parse_url($url); // init var $chunks = array(); // process queries foreach ($parameters as $key => $value) { $chunks[] = str_replace( '%25', '%', self::urlencode_rfc3986($key) . '="' . self::urlencode_rfc3986($value) . '"' ); } // build return $return = 'Authorization: OAuth realm="' . $parts['scheme'] . '://' . $parts['host'] . $parts['path'] . '", '; $return .= implode(',', $chunks); // prepend name and OAuth part return $return; } /** * Make an call to the oAuth * @todo refactor me * * @param string $method The method. * @param array[optional] $parameters The parameters. * @return array */ private function doOAuthCall($method, array $parameters = null) { // redefine $method = (string) $method; // append default parameters $parameters['oauth_consumer_key'] = $this->getConsumerKey(); $parameters['oauth_nonce'] = md5(microtime() . rand()); $parameters['oauth_timestamp'] = time(); $parameters['oauth_signature_method'] = 'HMAC-SHA1'; $parameters['oauth_version'] = '1.0'; // calculate the base string $base = $this->calculateBaseString( self::SECURE_API_URL . '/oauth/' . $method, 'POST', $parameters ); // add sign into the parameters $parameters['oauth_signature'] = $this->hmacsha1( $this->getConsumerSecret() . '&' . $this->getOAuthTokenSecret(), $base ); // calculate header $header = $this->calculateHeader( $parameters, self::SECURE_API_URL . '/oauth/' . $method ); // set options $options[CURLOPT_URL] = self::SECURE_API_URL . '/oauth/' . $method; $options[CURLOPT_PORT] = self::SECURE_API_PORT; $options[CURLOPT_USERAGENT] = $this->getUserAgent(); if (ini_get('open_basedir') == '' && ini_get('safe_mode' == 'Off')) { $options[CURLOPT_FOLLOWLOCATION] = true; } $options[CURLOPT_RETURNTRANSFER] = true; $options[CURLOPT_TIMEOUT] = (int) $this->getTimeOut(); $options[CURLOPT_SSL_VERIFYPEER] = false; $options[CURLOPT_SSL_VERIFYHOST] = false; $options[CURLOPT_HTTPHEADER] = array('Expect:'); $options[CURLOPT_POST] = true; $options[CURLOPT_POSTFIELDS] = $this->buildQuery($parameters); // init $this->curl = curl_init(); // set options curl_setopt_array($this->curl, $options); // execute $response = curl_exec($this->curl); $headers = curl_getinfo($this->curl); // fetch errors $errorNumber = curl_errno($this->curl); $errorMessage = curl_error($this->curl); // error? if ($errorNumber != '') { throw new Exception($errorMessage, $errorNumber); } // init var $return = array(); // parse the string parse_str($response, $return); // return return $return; } /** * Make the call * * @param string $url The url to call. * @param array[optional] $parameters Optional parameters. * @param bool[optional] $authenticate Should we authenticate. * @param bool[optional] $method The method to use. Possible values are GET, POST. * @param string[optional] $filePath The path to the file to upload. * @param bool[optional] $expectJSON Do we expect JSON. * @param bool[optional] $returnHeaders Should the headers be returned? * @return string */ private function doCall( $url, array $parameters = null, $authenticate = false, $method = 'GET', $filePath = null, $expectJSON = true, $returnHeaders = false ) { // allowed methods $allowedMethods = array('GET', 'POST'); // redefine $url = (string) $url; $parameters = (array) $parameters; $authenticate = (bool) $authenticate; $method = (string) $method; $expectJSON = (bool) $expectJSON; // validate method if (!in_array($method, $allowedMethods)) { throw new Exception( 'Unknown method (' . $method . '). Allowed methods are: ' . implode(', ', $allowedMethods) ); } // append default parameters $oauth['oauth_consumer_key'] = $this->getConsumerKey(); $oauth['oauth_nonce'] = md5(microtime() . rand()); $oauth['oauth_timestamp'] = time(); $oauth['oauth_token'] = $this->getOAuthToken(); $oauth['oauth_signature_method'] = 'HMAC-SHA1'; $oauth['oauth_version'] = '1.0'; // set data $data = $oauth; if(!empty($parameters)) $data = array_merge($data, $parameters); // calculate the base string $base = $this->calculateBaseString( self::API_URL . '/' . $url, $method, $data ); // based on the method, we should handle the parameters in a different way if ($method == 'POST') { // file provided? if ($filePath != null) { // build a boundary $boundary = md5(time()); // process file $fileInfo = pathinfo($filePath); // set mimeType $mimeType = 'application/octet-stream'; if ($fileInfo['extension'] == 'jpg' || $fileInfo['extension'] == 'jpeg') { $mimeType = 'image/jpeg'; } elseif($fileInfo['extension'] == 'gif') $mimeType = 'image/gif'; elseif($fileInfo['extension'] == 'png') $mimeType = 'image/png'; // init var $content = '--' . $boundary . "\r\n"; // set file $content .= 'Content-Disposition: form-data; name=image; filename="' . $fileInfo['basename'] . '"' . "\r\n"; $content .= 'Content-Type: ' . $mimeType . "\r\n"; $content .= "\r\n"; $content .= file_get_contents($filePath); $content .= "\r\n"; $content .= "--" . $boundary . '--'; // build headers $headers[] = 'Content-Type: multipart/form-data; boundary=' . $boundary; $headers[] = 'Content-Length: ' . strlen($content); // set content $options[CURLOPT_POSTFIELDS] = $content; } // no file else $options[CURLOPT_POSTFIELDS] = $this->buildQuery($parameters); // enable post $options[CURLOPT_POST] = true; } else { // add the parameters into the querystring if(!empty($parameters)) $url .= '?' . $this->buildQuery($parameters); $options[CURLOPT_POST] = false; } // add sign into the parameters $oauth['oauth_signature'] = $this->hmacsha1( $this->getConsumerSecret() . '&' . $this->getOAuthTokenSecret(), $base ); $headers[] = $this->calculateHeader($oauth, self::API_URL . '/' . $url); $headers[] = 'Expect:'; // set options $options[CURLOPT_URL] = self::API_URL . '/' . $url; $options[CURLOPT_PORT] = self::API_PORT; $options[CURLOPT_USERAGENT] = $this->getUserAgent(); if (ini_get('open_basedir') == '' && ini_get('safe_mode' == 'Off')) { $options[CURLOPT_FOLLOWLOCATION] = true; } $options[CURLOPT_RETURNTRANSFER] = true; $options[CURLOPT_TIMEOUT] = (int) $this->getTimeOut(); $options[CURLOPT_SSL_VERIFYPEER] = false; $options[CURLOPT_SSL_VERIFYHOST] = false; $options[CURLOPT_HTTP_VERSION] = CURL_HTTP_VERSION_1_1; $options[CURLOPT_HTTPHEADER] = $headers; // init if($this->curl == null) $this->curl = curl_init(); // set options curl_setopt_array($this->curl, $options); // execute $response = curl_exec($this->curl); $headers = curl_getinfo($this->curl); // fetch errors $errorNumber = curl_errno($this->curl); $errorMessage = curl_error($this->curl); // return the headers if($returnHeaders) return $headers; // we don't expext JSON, return the response if(!$expectJSON) return $response; // replace ids with their string values, added because of some // PHP-version can't handle these large values $response = preg_replace('/id":(\d+)/', 'id":"\1"', $response); // we expect JSON, so decode it $json = @json_decode($response, true); // validate JSON if ($json === null) { // should we provide debug information if (self::DEBUG) { // make it output proper echo '<pre>'; // dump the header-information var_dump($headers); // dump the error var_dump($errorMessage); // dump the raw response var_dump($response); // end proper format echo '</pre>'; } // throw exception throw new Exception('Invalid response.'); } // any errors if (isset($json['errors'])) { // should we provide debug information if (self::DEBUG) { // make it output proper echo '<pre>'; // dump the header-information var_dump($headers); // dump the error var_dump($errorMessage); // dump the raw response var_dump($response); // end proper format echo '</pre>'; } // throw exception if (isset($json['errors'][0]['message'])) { throw new Exception($json['errors'][0]['message']); } elseif (isset($json['errors']) && is_string($json['errors'])) { throw new Exception($json['errors']); } else throw new Exception('Invalid response.'); } // any error if (isset($json['error'])) { // should we provide debug information if (self::DEBUG) { // make it output proper echo '<pre>'; // dump the header-information var_dump($headers); // dump the raw response var_dump($response); // end proper format echo '</pre>'; } // throw exception throw new Exception($json['error']); } // return return $json; } /** * Get the consumer key * * @return string */ private function getConsumerKey() { return $this->consumerKey; } /** * Get the consumer secret * * @return string */ private function getConsumerSecret() { return $this->consumerSecret; } /** * Get the oAuth-token * * @return string */ private function getOAuthToken() { return $this->oAuthToken; } /** * Get the oAuth-token-secret * * @return string */ private function getOAuthTokenSecret() { return $this->oAuthTokenSecret; } /** * Get the timeout * * @return int */ public function getTimeOut() { return (int) $this->timeOut; } /** * Get the useragent that will be used. Our version will be prepended to yours. * It will look like: "PHP Twitter/<version> <your-user-agent>" * * @return string */ public function getUserAgent() { return (string) 'PHP Twitter/' . self::VERSION . ' ' . $this->userAgent; } /** * Set the consumer key * * @param string $key The consumer key to use. */ private function setConsumerKey($key) { $this->consumerKey = (string) $key; } /** * Set the consumer secret * * @param string $secret The consumer secret to use. */ private function setConsumerSecret($secret) { $this->consumerSecret = (string) $secret; } /** * Set the oAuth-token * * @param string $token The token to use. */ public function setOAuthToken($token) { $this->oAuthToken = (string) $token; } /** * Set the oAuth-secret * * @param string $secret The secret to use. */ public function setOAuthTokenSecret($secret) { $this->oAuthTokenSecret = (string) $secret; } /** * Set the timeout * * @param int $seconds The timeout in seconds. */ public function setTimeOut($seconds) { $this->timeOut = (int) $seconds; } /** * Get the useragent that will be used. Our version will be prepended to yours. * It will look like: "PHP Twitter/<version> <your-user-agent>" * * @param string $userAgent Your user-agent, it should look like <app-name>/<app-version>. */ public function setUserAgent($userAgent) { $this->userAgent = (string) $userAgent; } /** * Build the signature for the data * * @param string $key The key to use for signing. * @param string $data The data that has to be signed. * @return string */ private function hmacsha1($key, $data) { return base64_encode(hash_hmac('SHA1', $data, $key, true)); } /** * URL-encode method for internal use * * @param mixed $value The value to encode. * @return string */ private static function urlencode_rfc3986($value) { if (is_array($value)) { return array_map(array(__CLASS__, 'urlencode_rfc3986'), $value); } else { $search = array('+', ' ', '%7E', '%'); $replace = array('%20', '%20', '~', '%25'); return str_replace($search, $replace, urlencode($value)); } } // Timeline resources /** * Returns the 20 most recent mentions (tweets containing a users's @screen_name) for the authenticating user. * The timeline returned is the equivalent of the one seen when you view your mentions on twitter.com. * This method can only return up to 800 tweets. * * @param int[optional] $count Specifies the number of tweets to try and retrieve, up to a maximum of 200. The value of count is best thought of as a limit to the number of tweets to return because suspended or deleted content is removed after the count has been applied. We include retweets in the count, even if include_rts is not supplied. * @param string[optional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param string[optional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @param bool[optional] $contributorDetails This parameter enhances the contributors element of the status response to include the screen_name of the contributor. By default only the user_id of the contributor is included. * @param bool[optional] $includeEntities The entities node will be disincluded when set to false. * @return array */ public function statusesMentionsTimeline( $count = null, $sinceId = null, $maxId = null, $trimUser = null, $contributorDetails = null, $includeEntities = null ) { // build parameters $parameters = null; $parameters['include_rts'] = 'true'; if ($count != null) { $parameters['count'] = (int) $count; } if ($sinceId != null) { $parameters['since_id'] = (string) $sinceId; } if ($maxId != null) { $parameters['max_id'] = (string) $maxId; } if ($trimUser != null) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } if ($contributorDetails != null) { $parameters['contributor_details'] = ($contributorDetails) ? 'true' : 'false'; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/mentions_timeline.json', $parameters, true ); } /** * Returns a collection of the most recent Tweets posted by the user indicated by the screen_name or user_id parameters. * User timelines belonging to protected users may only be requested when the authenticated user either "owns" the timeline or is an approved follower of the owner. * The timeline returned is the equivalent of the one seen when you view a user's profile on twitter.com. * This method can only return up to 3,200 of a user's most recent Tweets. Native retweets of other statuses by the user is included in this total, regardless of whether include_rts is set to false when requesting this resource. * * @param string[optional] $userId The ID of the user for whom to return results for. Helpful for disambiguating when a valid user ID is also a valid screen name. * @param string[optional] $screenName The screen name of the user for whom to return results for. Helpful for disambiguating when a valid screen name is also a user ID. * @param string[optional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param int[optional] $count Specifies the number of tweets to try and retrieve, up to a maximum of 200 per distinct request. The value of count is best thought of as a limit to the number of tweets to return because suspended or deleted content is removed after the count has been applied. We include retweets in the count, even if include_rts is not supplied. * @param string[optional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @param bool[optional] $excludeReplies This parameter will prevent replies from appearing in the returned timeline. Using exclude_replies with the count parameter will mean you will receive up-to count tweets — this is because the count parameter retrieves that many tweets before filtering out retweets and replies. * @param bool[optional] $contributorDetails This parameter enhances the contributors element of the status response to include the screen_name of the contributor. By default only the user_id of the contributor is included. * @param bool[optional] $includeRts When set to false, the timeline will strip any native retweets (though they will still count toward both the maximal length of the timeline and the slice selected by the count parameter). Note: If you're using the trim_user parameter in conjunction with include_rts, the retweets will still contain a full user object. * @return array */ public function statusesUserTimeline( $userId = null, $screenName = null, $sinceId = null, $count = null, $maxId = null, $trimUser = null, $excludeReplies = null, $contributorDetails = null, $includeRts = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($sinceId != null) { $parameters['since_id'] = (string) $sinceId; } if ($count != null) { $parameters['count'] = (int) $count; } if ($maxId != null) { $parameters['max_id'] = (string) $maxId; } if ($trimUser != null) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } if ($excludeReplies != null) { $parameters['exclude_replies'] = ($excludeReplies) ? 'true' : 'false'; } if ($contributorDetails != null) { $parameters['contributor_details'] = ($contributorDetails) ? 'true' : 'false'; } if ($includeRts != null) { $parameters['include_rts'] = ($includeRts) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/user_timeline.json', $parameters ); } /** * Returns the 20 most recent statuses, including retweets if they exist, posted by the authenticating user and the user's they follow. This is the same timeline seen by a user when they login to twitter.com. * This method is identical to statusesFriendsTimeline, except that this method always includes retweets. * * @param int[optional] $count Specifies the number of records to retrieve. Must be less than or equal to 200. Defaults to 20. * @param string[optional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param string[optional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @param bool[optional] $excludeReplies This parameter will prevent replies from appearing in the returned timeline. Using exclude_replies with the count parameter will mean you will receive up-to count tweets — this is because the count parameter retrieves that many tweets before filtering out retweets and replies. * @param bool[optional] $contributorDetails This parameter enhances the contributors element of the status response to include the screen_name of the contributor. By default only the user_id of the contributor is included. * @param bool[optional] $includeEntities The entities node will be disincluded when set to false. * @return array */ public function statusesHomeTimeline( $count = null, $sinceId = null, $maxId = null, $trimUser = null, $excludeReplies = null, $contributorDetails = null, $includeEntities = null ) { // build parameters $parameters = null; if ($count != null) { $parameters['count'] = (int) $count; } if ($sinceId != null) { $parameters['since_id'] = (string) $sinceId; } if ($maxId != null) { $parameters['max_id'] = (string) $maxId; } if ($trimUser != null) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } if ($excludeReplies != null) { $parameters['exclude_replies'] = ($excludeReplies) ? 'true' : 'false'; } if ($contributorDetails != null) { $parameters['contributor_details'] = ($contributorDetails) ? 'true' : 'false'; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/home_timeline.json', $parameters, true ); } /** * Returns the most recent tweets authored by the authenticating user that have recently been retweeted by others. This timeline is a subset of the user's GET statuses/user_timeline. * * @param int[optional] $count Specifies the number of records to retrieve. Must be less than or equal to 100. If omitted, 20 will be assumed. * @param string[optional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param string[optional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @param bool[optional] $includeEntities The tweet entities node will be disincluded when set to false. * @param bool[optional] $includeUserEntities The user entities node will be disincluded when set to false. * @return array */ public function statusesRetweetsOfMe( $count = null, $sinceId = null, $maxId = null, $trimUser = null, $includeEntities = null, $includeUserEntities = null ) { // build parameters $parameters = null; if ($count != null) { $parameters['count'] = (int) $count; } if ($sinceId != null) { $parameters['since_id'] = (string) $sinceId; } if ($maxId != null) { $parameters['max_id'] = (string) $maxId; } if ($trimUser != null) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($includeUserEntities != null) { $parameters['include_user_entities'] = ($includeUserEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/retweets_of_me.json', $parameters, true ); } // Tweets resources /** * Returns up to 100 of the first retweets of a given tweet. * * @param string $id The numerical ID of the desired status. * @param int[optional] $count Specifies the number of records to retrieve. Must be less than or equal to 100. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @return array */ public function statusesRetweets($id, $count = null, $trimUser = null) { // build parameters $parameters = null; if ($count != null) { $parameters['count'] = (int) $count; } if ($trimUser != null) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/retweets/' . (string) $id . '.json', $parameters ); } /** * Returns a single Tweet, specified by the id parameter. The Tweet's author will also be embedded within the tweet. * * @param string $id The numerical ID of the desired Tweet. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @param bool[optional] $includeMyRetweet When set to true, any Tweets returned that have been retweeted by the authenticating user will include an additional current_user_retweet node, containing the ID of the source status for the retweet. * @param bool[optional] $includeEntities The entities node will be disincluded when set to false. * @return array */ public function statusesShow( $id, $trimUser = null, $includeMyRetweet = null, $includeEntities = null ) { // build parameters $parameters['id'] = (string) $id; if ($trimUser != null) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } if ($includeMyRetweet != null) { $parameters['include_my_retweet'] = ($includeMyRetweet) ? 'true' : 'false'; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/show.json', $parameters, true ); } /** * Destroys the status specified by the required ID parameter. The authenticating user must be the author of the specified status. Returns the destroyed status if successful. * * @param string $id The numerical ID of the desired status. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @return array */ public function statusesDestroy($id, $trimUser = null) { // build parameters $parameters = null; if($trimUser != null) $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; // make the call return (array) $this->doCall( 'statuses/destroy/' . (string) $id . '.json', $parameters, true, 'POST' ); } /** * Updates the authenticating user's status. A status update with text identical to the authenticating user's text identical to the authenticating user's current status will be ignored to prevent duplicates. * * @param string $status The text of your status update, typically up to 140 characters. URL encode as necessary. t.co link wrapping may effect character counts. There are some special commands in this field to be aware of. For instance, preceding a message with "D " or "M " and following it with a screen name can create a direct message to that user if the relationship allows for it. * @param string[optional] $inReplyToStatusId The ID of an existing status that the update is in reply to. Note: This parameter will be ignored unless the author of the tweet this parameter references is mentioned within the status text. Therefore, you must include @username, where username is the author of the referenced tweet, within the update. * @param float[optional] $lat The latitude of the location this tweet refers to. This parameter will be ignored unless it is inside the range -90.0 to +90.0 (North is positive) inclusive. It will also be ignored if there isn't a corresponding long parameter. * @param float[optional] $long The longitude of the location this tweet refers to. The valid ranges for longitude is -180.0 to +180.0 (East is positive) inclusive. This parameter will be ignored if outside that range, if it is not a number, if geo_enabled is disabled, or if there not a corresponding lat parameter. * @param string[optional] $placeId A place in the world. These IDs can be retrieved from GET geo/reverse_geocode. * @param bool[optional] $displayCoordinates Whether or not to put a pin on the exact coordinates a tweet has been sent from. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @return array */ public function statusesUpdate( $status, $inReplyToStatusId = null, $lat = null, $long = null, $placeId = null, $displayCoordinates = null, $trimUser = null ) { // build parameters $parameters['status'] = (string) $status; if ($inReplyToStatusId != null) { $parameters['in_reply_to_status_id'] = (string) $inReplyToStatusId; } if ($lat != null) { $parameters['lat'] = (float) $lat; } if ($long != null) { $parameters['long'] = (float) $long; } if ($placeId != null) { $parameters['place_id'] = (string) $placeId; } if ($displayCoordinates != null) { $parameters['display_coordinates'] = ($displayCoordinates) ? 'true' : 'false'; } if ($trimUser) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/update.json', $parameters, true, 'POST' ); } /** * Retweets a tweet. Returns the original tweet with retweet details embedded. * * @param string $id The numerical ID of the desired status. * @param bool[optional] $trimUser When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object. * @return array */ public function statusesRetweet($id, $trimUser = null) { $parameters = null; if ($trimUser != null) { $parameters['trim_user'] = ($trimUser) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'statuses/retweet/' . $id . '.json', $parameters, true, 'POST' ); } /** * Not implemented yet */ public function statusesUpdateWithMedia() { throw new Exception('Not Implemented'); } /** * @param string[optional] $id The Tweet/status ID to return embed code for. * @param string[optional] $url The URL of the Tweet/status to be embedded. * @param int[optional] $maxwidth The maximum width in pixels that the embed should be rendered at. This value is constrained to be between 250 and 550 pixels. Note that Twitter does not support the oEmbed maxheight parameter. Tweets are fundamentally text, and are therefore of unpredictable height that cannot be scaled like an image or video. Relatedly, the oEmbed response will not provide a value for height. Implementations that need consistent heights for Tweets should refer to the hide_thread and hide_media parameters below. * @param bool[optional] $hideMedia Specifies whether the embedded Tweet should automatically expand images which were uploaded via POST statuses/update_with_media. When set to true images will not be expanded. Defaults to false. * @param bool[optional] $hideThread Specifies whether the embedded Tweet should automatically show the original message in the case that the embedded Tweet is a reply. When set to true the original Tweet will not be shown. Defaults to false. * @param bool[optional] $omitScript Specifies whether the embedded Tweet HTML should include a <script> element pointing to widgets.js. In cases where a page already includes widgets.js, setting this value to true will prevent a redundant script element from being included. When set to true the <script> element will not be included in the embed HTML, meaning that pages must include a reference to widgets.js manually. Defaults to false. * @param string[optional] $align Specifies whether the embedded Tweet should be left aligned, right aligned, or centered in the page. Valid values are left, right, center, and none. Defaults to none, meaning no alignment styles are specified for the Tweet. * @param string[optional] $related A value for the TWT related parameter, as described in Web Intents. This value will be forwarded to all Web Intents calls. * @param string[optional] $lang Language code for the rendered embed. This will affect the text and localization of the rendered HTML. * @return array */ public function statusesOEmbed( $id = null, $url = null, $maxwidth = null, $hideMedia = null, $hideThread = null, $omitScript = null, $align = null, $related = null, $lang = null ) { if ($id == null && $url == null) { throw new Exception('Either id or url should be specified.'); } // build parameters $parameters = null; if ($id != null) { $parameters['id'] = (string) $id; } if ($url != null) { $parameters['url'] = (string) $url; } if ($maxwidth != null) { $parameters['maxwidth'] = (int) $maxwidth; } if ($hideMedia != null) { $parameters['hide_media'] = ($hideMedia) ? 'true' : 'false'; } if ($hideThread != null) { $parameters['hide_thread'] = ($hideThread) ? 'true' : 'false'; } if ($omitScript != null) { $parameters['omit_script'] = ($omitScript) ? 'true' : 'false'; } if ($align != null) { $parameters['align'] = (string) $align; } if ($related != null) { $parameters['related'] = (string) $related; } if ($lang != null) { $parameters['lang'] = (string) $lang; } // make the call return (array) $this->doCall( 'statuses/oembed.json', $parameters ); } // Search resources /** * Returns tweets that match a specified query. * * @param string $q A UTF-8, URL-encoded search query of 1,000 characters maximum, including operators. Queries may additionally be limited by complexity. * @param string[optional] $geocode Returns tweets by users located within a given radius of the given latitude/longitude. The location is preferentially taking from the Geotagging API, but will fall back to their Twitter profile. The parameter value is specified by "latitude,longitude,radius", where radius units must be specified as either "mi" (miles) or "km" (kilometers). Note that you cannot use the near operator via the API to geocode arbitrary locations; however you can use this geocode parameter to search near geocodes directly. A maximum of 1,000 distinct "sub-regions" will be considered when using the radius modifier. * @param string[optional] $lang Restricts tweets to the given language, given by an ISO 639-1 code. Language detection is best-effort. * @param string[optional] $locale Specify the language of the query you are sending (only ja is currently effective). This is intended for language-specific consumers and the default should work in the majority of cases. * @param string[optional] $resultType Specifies what type of search results you would prefer to receive. The current default is "mixed." Valid values include: mixed: Include both popular and real time results in the response, recent: return only the most recent results in the response, popular: return only the most popular results in the response. * @param int[optional] $count The number of tweets to return per page, up to a maximum of 100. Defaults to 15. This was formerly the "rpp" parameter in the old Search API. * @param string[optional] $until Returns tweets generated before the given date. Date should be formatted as YYYY-MM-DD. Keep in mind that the search index may not go back as far as the date you specify here. * @param string[optional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param string[optional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param bool[optional] $includeEntities The entities node will be disincluded when set to false. * @return array */ public function searchTweets( $q, $geocode = null, $lang = null, $locale = null, $resultType= null, $count = null, $until = null, $sinceId = null, $maxId = null, $includeEntities = null ) { $parameters['q'] = (string) $q; if ($geocode !== null) { $parameters['geocode'] = (string) $geocode; } if ($lang !== null) { $parameters['lang'] = (string) $lang; } if ($locale !== null) { $parameters['locale'] = (string) $locale; } if ($resultType !== null) { $parameters['result_type'] = (string) $resultType; } if ($count !== null) { $parameters['count'] = (int) $count; } if ($until !== null) { $parameters['until'] = (string) $until; } if ($sinceId !== null) { $parameters['since_id'] = (string) $sinceId; } if ($maxId !== null) { $parameters['max_id'] = (string) $maxId; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } return (array) $this->doCall( 'search/tweets.json', $parameters ); } // Streaming resources /** * Not implemented yet */ public function statusesFilter() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function statusesSample() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function statusesFirehose() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function user() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function site() { throw new Exception('Not implemented'); } // Direct Messages resources /** * Returns the 20 most recent direct messages sent to the authenticating user. Includes detailed information about the sender and recipient user. You can request up to 200 direct messages per call, up to a maximum of 800 incoming DMs. * Important: This method requires an access token with RWD (read, write & direct message) permissions. Consult The Application Permission Model for more information. * * @param string[optional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param string[optional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param int[optional] $count Specifies the number of direct messages to try and retrieve, up to a maximum of 200. The value of count is best thought of as a limit to the number of Tweets to return because suspended or deleted content is removed after the count has been applied. * @param int[optional] $page Specifies the page of results to retrieve. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function directMessages( $sinceId = null, $maxId = null, $count = null, $page = null, $includeEntities = null, $skipStatus = null ) { // build parameters $parameters = array(); if ($sinceId != null) { $parameters['since_id'] = (string) $sinceId; } if ($maxId != null) { $parameters['max_id'] = (string) $maxId; } if ($count != null) { $parameters['count'] = (int) $count; } if ($page != null) { $parameters['page'] = (int) $page; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'direct_messages.json', $parameters, true ); } /** * Returns the 20 most recent direct messages sent by the authenticating user. Includes detailed information about the sender and recipient user. You can request up to 200 direct messages per call, up to a maximum of 800 outgoing DMs. * Important: This method requires an access token with RWD (read, write & direct message) permissions. Consult The Application Permission Model for more information. * * @param string[optional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param string[optional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param int[optional] $count Specifies the number of records to retrieve. Must be less than or equal to 200. * @param int[optional] $page Specifies the page of results to retrieve. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @return array */ public function directMessagesSent( $sinceId = null, $maxId = null, $count = null, $page = null, $includeEntities = null ) { // build parameters $parameters = array(); if ($sinceId != null) { $parameters['since_id'] = (string) $sinceId; } if ($maxId != null) { $parameters['max_id'] = (string) $maxId; } if ($count != null) { $parameters['count'] = (int) $count; } if ($page != null) { $parameters['page'] = (int) $page; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'direct_messages/sent.json', $parameters, true ); } /** * * @param string $id The ID of the direct message. * @return array */ public function directMessagesShow($id) { // build parameters $parameters['id'] = (string) $id; // make the call return (array) $this->doCall( 'direct_messages/show.json', $parameters, true ); } /** * Destroys the direct message specified in the required ID parameter. The authenticating user must be the recipient of the specified direct message. * Important: This method requires an access token with RWD (read, write & direct message) permissions. Consult The Application Permission Model for more information. * * @param string $id The ID of the direct message to delete. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @return array */ public function directMessagesDestroy($id, $includeEntities = null) { // build parameters $parameters['id'] = (string) $id; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'direct_messages/destroy.json', $parameters, true, 'POST' ); } /** * Sends a new direct message to the specified user from the authenticating user. Requires both the user and text parameters and must be a POST. Returns the sent message in the requested format if successful. * * @param string[optional] $userId The ID of the user who should receive the direct message. Helpful for disambiguating when a valid user ID is also a valid screen name. * @param string[optional] $screenName The screen name of the user who should receive the direct message. Helpful for disambiguating when a valid screen name is also a user ID. * @param string $text The text of your direct message. Be sure to URL encode as necessary, and keep the message under 140 characters. * @return array */ public function directMessagesNew( $userId = null, $screenName = null, $text ) { // validate if ($userId == null && $screenName == null) { throw new Exception('One of user_id or screen_name are required.'); } // build parameters $parameters['text'] = (string) $text; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } // make the call return (array) $this->doCall( 'direct_messages/new.json', $parameters, true, 'POST' ); } // Friends & Followers resources /** * Returns a cursored collection of user IDs for every user the specified user is following (otherwise known as their "friends"). * At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues. Results are given in groups of 5,000 user IDs and multiple "pages" of results can be navigated through using the next_cursor value in subsequent requests. See Using cursors to navigate collections for more information. * This method is especially powerful when used in conjunction with GET users/lookup, a method that allows you to convert user IDs into full user objects in bulk. * * @param string[optional] $userId The ID of the user for whom to return results for. * @param string[optional] $screenName The screen name of the user for whom to return results for. * @param string[optional] $cursor Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filtered out after connections are queried. If no cursor is provided, a value of -1 will be assumed, which is the first "page." The response from the API will include a previous_cursor and next_cursor to allow paging back and forth * @param bool[optional] $stringifyIds Many programming environments will not consume our Tweet ids due to their size. Provide this option to have ids returned as strings instead. * @return array */ public function friendsIds( $userId = null, $screenName = null, $cursor = null, $stringifyIds = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($cursor != null) { $parameters['cursor'] = (string) $cursor; } if ($stringifyIds !== null) { $parameters['stringify_ids'] = ((bool) $stringifyIds) ? 'true' : 'false'; } // make the call return (array) $this->doCall('friends/ids.json', $parameters, true); } /** * Returns a cursored collection of user IDs for every user following the specified user. * At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues. Results are given in groups of 5,000 user IDs and multiple "pages" of results can be navigated through using the next_cursor value in subsequent requests. See Using cursors to navigate collections for more information. * This method is especially powerful when used in conjunction with GET users/lookup, a method that allows you to convert user IDs into full user objects in bulk. * * @param string[optional] $userId The ID of the user for whom to return results for. * @param string[optional] $screenName The screen name of the user for whom to return results for. * @param string[optional] $cursor Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filtered out after connections are queried. If no cursor is provided, a value of -1 will be assumed, which is the first "page." The response from the API will include a previous_cursor and next_cursor to allow paging back and forth * @param bool[optional] $stringifyIds Many programming environments will not consume our Tweet ids due to their size. Provide this option to have ids returned as strings instead. * @return array */ public function followersIds( $userId = null, $screenName = null, $cursor = null, $stringifyIds = true ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($cursor != null) { $parameters['cursor'] = (string) $cursor; } $parameters['stringify_ids'] = ((bool) $stringifyIds) ? 'true' : 'false'; // make the call return (array) $this->doCall('followers/ids.json', $parameters, true); } /** * Returns the relationships of the authenticating user to the comma-separated list of up to 100 screen_names or user_ids provided. * Values for connections can be: following, following_requested, followed_by, none. * * @param mixed[optional] $userIds An array of user IDs, up to 100 are allowed in a single request. * @param mixed[optional] $screenNames An array of screen names, up to 100 are allowed in a single request. * @return array */ public function friendshipsLookup($userIds = null, $screenNames = null) { // redefine $userIds = (array) $userIds; $screenNames = (array) $screenNames; // validate if (empty($userIds) && empty($screenNames)) { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if (!empty($userIds)) { $parameters['user_id'] = implode(',', $userIds); } if (!empty($screenNames)) { $parameters['screen_name'] = implode(',', $screenNames); } // make the call return (array) $this->doCall('friendships/lookup.json', $parameters, true); } /** * Returns a collection of numeric IDs for every user who has a pending request to follow the authenticating user. * * @param string[optional] $cursor Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filtered out after connections are queried. If no cursor is provided, a value of -1 will be assumed, which is the first "page." * @param bool[optional] $stringifyIds Many programming environments will not consume our Tweet ids due to their size. Provide this option to have ids returned as strings instead. * @return array */ public function friendshipsIncoming($cursor = null, $stringifyIds = true) { // build parameters $parameters = null; if($cursor != null) $parameters['cursor'] = (string) $cursor; $parameters['stringify_ids'] = ((bool) $stringifyIds) ? 'true' : 'false'; // make the call return (array) $this->doCall( 'friendships/incoming.json', $parameters, true ); } /** * Returns a collection of numeric IDs for every protected user for whom the authenticating user has a pending follow request. * * @param string[optional] $cursor Causes the list of connections to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filtered out after connections are queried. If no cursor is provided, a value of -1 will be assumed, which is the first "page." * @param bool[optional] $stringifyIds Many programming environments will not consume our Tweet ids due to their size. Provide this option to have ids returned as strings instead. * @return array */ public function friendshipsOutgoing($cursor = null, $stringifyIds = true) { // build parameters $parameters = null; if($cursor != null) $parameters['cursor'] = (string) $cursor; $parameters['stringify_ids'] = ((bool) $stringifyIds) ? 'true' : 'false'; // make the call return (array) $this->doCall( 'friendships/outgoing.json', $parameters, true ); } /** * Allows the authenticating users to follow the user specified in the ID parameter. * Returns the befriended user in the requested format when successful. Returns a string describing the failure condition when unsuccessful. If you are already friends with the user a HTTP 403 may be returned, though for performance reasons you may get a 200 OK message even if the friendship already exists. * Actions taken in this method are asynchronous and changes will be eventually consistent. * * @param string[optional] $userId The ID of the user for whom to befriend. * @param string[optional] $screenName The screen name of the user for whom to befriend. * @param bool[optional] $follow Enable notifications for the target user. * @return array */ public function friendshipsCreate( $userId = null, $screenName = null, $follow = false ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } $parameters['follow'] = ($follow) ? 'true' : 'false'; // make the call return (array) $this->doCall( 'friendships/create.json', $parameters, true, 'POST' ); } /** * Allows the authenticating user to unfollow the user specified in the ID parameter. * Returns the unfollowed user in the requested format when successful. Returns a string describing the failure condition when unsuccessful. * Actions taken in this method are asynchronous and changes will be eventually consistent. * * @param string[optional] $userId The ID of the user for whom to unfollow. * @param string[optional] $screenName The screen name of the user for whom to unfollow. * @return array */ public function friendshipsDestroy($userId = null, $screenName = null) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } // make the call return (array) $this->doCall( 'friendships/destroy.json', $parameters, true, 'POST' ); } /** * Allows one to enable or disable retweets and device notifications from the specified user. * * @param string[optional] $userId The ID of the user for whom to befriend. * @param string[optional] $screenName The screen name of the user for whom to befriend. * @param bool[optional] $device Enable/disable device notifications from the target user. * @param bool[optional] $retweets Enable/disable retweets from the target user. * @return array */ public function friendshipsUpdate( $userId = null, $screenName = null, $device = null, $retweets = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($device !== null) { $parameters['device'] = ((bool) $device) ? 'true' : 'false'; } if ($retweets !== null) { $parameters['retweets'] = ((bool) $retweets) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'friendships/update.json', $parameters, true, 'POST' ); } /** * Returns detailed information about the relationship between two arbitrary users. * * @param string[optional] $sourceId The user_id of the subject user. * @param string[optional] $sourceScreenName The screen_name of the subject user. * @param string[optional] $targetId The screen_name of the subject user. * @param string[optional] $targetScreenName The screen_name of the target user. * @return array */ public function friendshipsShow( $sourceId = null, $sourceScreenName = null, $targetId = null, $targetScreenName = null) { // validate if ($sourceId == '' && $sourceScreenName == '') { throw new Exception('Specify an sourceId or a sourceScreenName.'); } if ($targetId == '' && $targetScreenName == '') { throw new Exception('Specify an targetId or a targetScreenName.'); } // build parameters if ($sourceId != null) { $parameters['source_id'] = (string) $sourceId; } if ($sourceScreenName != null) { $parameters['source_screen_name'] = (string) $sourceScreenName; } if ($targetId != null) { $parameters['target_id'] = (string) $targetId; } if ($targetScreenName != null) { $parameters['target_screen_name'] = (string) $targetScreenName; } // make the call return (array) $this->doCall('friendships/show.json', $parameters); } /** * Returns a cursored collection of user objects for every user the specified user is following (otherwise known as their "friends"). * At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues. Results are given in groups of 20 users and multiple "pages" of results can be navigated through using the next_cursor value in subsequent requests. See Using cursors to navigate collections for more information. * * @param string[optional] $userId The ID of the user for whom to return results for. * @param string[optional] $screenName The screen name of the user for whom to return results for. * @param int[optional] $cursor Causes the results to be broken into pages of no more than 20 records at a time. If no cursor is provided, a value of -1 will be assumed, which is the first "page." * @param bool[optional] $includeEntities The user object entities node will be disincluded when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function friendsList( $userId = null, $screenName = null, $cursor = null, $includeEntities = null, $skipStatus = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($cursor !== null) { $parameters['cursor'] = (int) $cursor; } if ($includeEntities !== null) { $parameters['include_user_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'friends/list.json', $parameters, true ); } /** * Returns a cursored collection of user objects for users following the specified user. * At this time, results are ordered with the most recent following first — however, this ordering is subject to unannounced change and eventual consistency issues. Results are given in groups of 20 users and multiple "pages" of results can be navigated through using the next_cursor value in subsequent requests. See Using cursors to navigate collections for more information. * * @param string[optional] $userId The ID of the user for whom to return results for. * @param string[optional] $screenName The screen name of the user for whom to return results for. * @param int[optional] $cursor Causes the results to be broken into pages of no more than 20 records at a time. If no cursor is provided, a value of -1 will be assumed, which is the first "page." * @param bool[optional] $includeEntities The user object entities node will be disincluded when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function followersList( $userId = null, $screenName = null, $cursor = null, $includeEntities = null, $skipStatus = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($cursor !== null) { $parameters['cursor'] = (int) $cursor; } if ($includeEntities !== null) { $parameters['include_user_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'followers/list.json', $parameters, true ); } // User resources /** * Returns settings (including current trend, geo and sleep time information) for the authenticating user. * * @return array */ public function accountSettings() { // make the call return (array) $this->doCall( 'account/settings.json', null, true ); } /** * Returns an HTTP 200 OK response code and a representation of the requesting user if authentication was successful; returns a 401 status code and an error message if not. Use this method to test if supplied user credentials are valid. * * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @param bool[optional] $skipStatus When set to true, statuses will not be included in the returned user objects. * @return array */ public function accountVerifyCredentials( $includeEntities = null, $skipStatus = null ) { // build parameters $parameters = null; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'account/verify_credentials.json', $parameters, true ); } /** * Updates the authenticating user's settings. * * @param string[optional] $trendLocationWoeId The Yahoo! Where On Earth ID to use as the user's default trend location. Global information is available by using 1 as the WOEID. The woeid must be one of the locations returned by trendsAvailable. * @param bool[optional] $sleepTimeEnabled When set to true, will enable sleep time for the user. Sleep time is the time when push or SMS notifications should not be sent to the user. * @param string[optional] $startSleepTime The hour that sleep time should begin if it is enabled. The value for this parameter should be provided in ISO8601 format (i.e. 00-23). The time is considered to be in the same timezone as the user's time_zone setting. * @param string[optional] $endSleepTime The hour that sleep time should end if it is enabled. The value for this parameter should be provided in ISO8601 format (i.e. 00-23). The time is considered to be in the same timezone as the user's time_zone setting. * @param string[optional] $timeZone The timezone dates and times should be displayed in for the user. The timezone must be one of the Rails TimeZone names. * @param string[optional] $lang The language which Twitter should render in for this user. The language must be specified by the appropriate two letter ISO 639-1 representation. Currently supported languages are provided by helpLanguages. * @return array */ public function accountSettingsUpdate( $trendLocationWoeId = null, $sleepTimeEnabled = null, $startSleepTime = null, $endSleepTime = null, $timeZone = null, $lang = null ) { // build parameters if ($trendLocationWoeId !== null) { $parameters['trend_location_woeid'] = (string) $trendLocationWoeId; } if ($sleepTimeEnabled !== null) { if ((bool) $sleepTimeEnabled) { $parameters['sleep_time_enabled'] = 'true'; } else { $parameters['sleep_time_enabled'] = 'false'; } } if ($startSleepTime !== null) { $parameters['start_sleep_time'] = (string) $startSleepTime; } if ($endSleepTime !== null) { $parameters['end_sleep_time'] = (string) $endSleepTime; } if ($timeZone !== null) { $parameters['time_zone'] = (string) $timeZone; } if ($lang !== null) { $parameters['lang'] = (string) $lang; } // make the call return (array) $this->doCall( 'account/settings.json', $parameters, true, 'POST' ); } /** * Sets which device Twitter delivers updates to for the authenticating user. Sending none as the device parameter will disable SMS updates. * * @return array * @param string $device Must be one of: sms, none. * @param bool[optional] $includeEntities When set to true, each tweet will include a node called "entities,". This node offers a variety of metadata about the tweet in a discreet structure, including: user_mentions, urls, and hashtags. While entities are opt-in on timelines at present, they will be made a default component of output in the future. See Tweet Entities for more detail on entities. */ public function accountUpdateDeliveryDevice( $device, $includeEntities = null ) { // build parameters $parameters['device'] = (string) $device; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'account/update_delivery_device.json', $parameters, true, 'POST' ); } /** * Sets values that users are able to set under the "Account" tab of their settings page. Only the parameters specified will be updated. * * @return array * @param string[optional] $name Full name associated with the profile. Maximum of 20 characters. * @param string[optional] $url URL associated with the profile. Will be prepended with "http://" if not present. Maximum of 100 characters. * @param string[optional] $location The city or country describing where the user of the account is located. The contents are not normalized or geocoded in any way. Maximum of 30 characters. * @param string[optional] $description A description of the user owning the account. Maximum of 160 characters. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @param bool[optional] $skipStatus When set to true, statuses will not be included in the returned user objects. */ public function accountUpdateProfile($name = null, $url = null, $location = null, $description = null, $includeEntities = null, $skipStatus = null) { // build parameters $parameters = null; if ($name != null) { $parameters['name'] = (string) $name; } if ($url != null) { $parameters['url'] = (string) $url; } if ($location != null) { $parameters['location'] = (string) $location; } if ($description != null) { $parameters['description'] = (string) $description; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'account/update_profile.json', $parameters, true, 'POST' ); } /** * Updates the authenticating user's profile background image. * * @return array * @param string $image The path to the background image for the profile. Must be a valid GIF, JPG, or PNG image of less than 800 kilobytes in size. Images with width larger than 2048 pixels will be forceably scaled down. * @param bool[optional] $tile Whether or not to tile the background image. If set to true the background image will be displayed tiled. The image will not be tiled otherwise. * @param bool[optional] $includeEntities When set to true each tweet will include a node called "entities,". This node offers a variety of metadata about the tweet in a discreet structure, including: user_mentions, urls, and hashtags. */ public function accountUpdateProfileBackgroundImage($image, $tile = false, $includeEntities = null) { // validate if (!file_exists($image)) { throw new Exception('Image (' . $image . ') doesn\'t exists.'); } // build parameters $parameters = null; if($tile) $parameters['tile'] = 'true'; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'account/update_profile_background_image.json', $parameters, true, 'POST', $image ); } /** * Sets one or more hex values that control the color scheme of the authenticating user's profile page on twitter.com. * Each parameter's value must be a valid hexidecimal value, and may be either three or six characters (ex: #fff or #ffffff). * * @return array * @param string[optional] $profileBackgroundColor Profile background color. * @param string[optional] $profileTextColor Profile text color. * @param string[optional] $profileLinkColor Profile link color. * @param string[optional] $profileSidebarFillColor Profile sidebar's background color. * @param string[optional] $profileSidebarBorderColor Profile sidebar's border color. * @param bool[optional] $includeEntities When set to true each tweet will include a node called "entities,". This node offers a variety of metadata about the tweet in a discreet structure, including: user_mentions, urls, and hashtags. */ public function accountUpdateProfileColors( $profileBackgroundColor = null, $profileTextColor = null, $profileLinkColor = null, $profileSidebarFillColor = null, $profileSidebarBorderColor = null, $includeEntities = null ) { // validate if ($profileBackgroundColor == '' && $profileTextColor == '' && $profileLinkColor == '' && $profileSidebarFillColor == '' && $profileSidebarBorderColor == '' ) { throw new Exception('Specify a profileBackgroundColor, profileTextColor, profileLinkColor, profileSidebarFillColor or a profileSidebarBorderColor.'); } // build parameters if ($profileBackgroundColor != null) { $parameters['profile_background_color'] = (string) $profileBackgroundColor; } if ($profileTextColor != null) { $parameters['profile_text_color'] = (string) $profileTextColor; } if ($profileLinkColor != null) { $parameters['profile_link_color'] = (string) $profileLinkColor; } if ($profileSidebarFillColor != null) { $parameters['profile_sidebar_fill_color'] = (string) $profileSidebarFillColor; } if ($profileSidebarBorderColor != null) { $parameters['profile_sidebar_border_color'] = (string) $profileSidebarBorderColor; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'account/update_profile_colors.json', $parameters, true, 'POST' ); } /** * Updates the authenticating user's profile image. * * @return array * @param string $image The path to the avatar image for the profile. Must be a valid GIF, JPG, or PNG image of less than 700 kilobytes in size. Images with width larger than 500 pixels will be scaled down. * @param bool[optional] $includeEntities When set to true each tweet will include a node called "entities,". This node offers a variety of metadata about the tweet in a discreet structure, including: user_mentions, urls, and hashtags. */ public function accountUpdateProfileImage($image, $includeEntities = null) { // validate if (!file_exists($image)) { throw new Exception('Image (' . $image . ') doesn\'t exists.'); } // build parameters $parameters = null; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'account/update_profile_image.json', $parameters, true, 'POST', $image ); } /** * Not implemented yet * @param int[optional] $cursor Causes the results to be broken into pages of no more than 20 records at a time. If no cursor is provided, a value of -1 will be assumed, which is the first "page." * @param bool[optional] $includeEntities The user object entities node will be disincluded when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function blocksList( $cursor = null, $includeEntities = null, $skipStatus = null ) { // build parameters $parameters = null; if ($cursor !== null) { $parameters['cursor'] = (int) $cursor; } if ($includeEntities !== null) { $parameters['include_user_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'blocks/list.json', $parameters, true ); } /** * Returns an array of numeric user ids the authenticating user is blocking. * * @param string[optional] $cursor Causes the list of IDs to be broken into pages of no more than 5000 IDs at a time. The number of IDs returned is not guaranteed to be 5000 as suspended users are filtered out after connections are queried. If no cursor is provided, a value of -1 will be assumed, which is the first "page." * @param bool[optional] $stringifyIds Many programming environments will not consume our ids due to their size. Provide this option to have ids returned as strings instead. * @return array */ public function blocksIds($cursor = null, $stringifyIds = null) { // build parameters $parameters = null; if ($cursor != null) { $parameters['cursor'] = (string) $cursor; } if ($stringifyIds !== null) { $parameters['stringify_ids'] = ((bool) $stringifyIds) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'blocks/ids.json', $parameters, true ); } /** * Blocks the specified user from following the authenticating user. In addition the blocked user will not show in the authenticating users mentions or timeline (unless retweeted by another user). If a follow or friend relationship exists it is destroyed. * * @param string[optional] $userId The ID of the potentially blocked user. Helpful for disambiguating when a valid user ID is also a valid screen name. * @param string[optional] $screenName The screen name of the potentially blocked user. Helpful for disambiguating when a valid screen name is also a user ID. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function blocksCreate( $userId = null, $screenName = null, $includeEntities = null, $skipStatus = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'blocks/create.json', $parameters, true, 'POST' ); } /** * Un-blocks the user specified in the ID parameter for the authenticating user. Returns the un-blocked user in the requested format when successful. If relationships existed before the block was instated, they will not be restored. * * @param string[optional] $userId The ID of the potentially blocked user. Helpful for disambiguating when a valid user ID is also a valid screen name. * @param string[optional] $screenName The screen name of the potentially blocked user. Helpful for disambiguating when a valid screen name is also a user ID. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function blocksDestroy( $userId = null, $screenName = null, $includeEntities = null, $skipStatus = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'blocks/destroy.json', $parameters, true, 'POST' ); } /** * Returns fully-hydrated user objects for up to 100 users per request, as specified by comma-separated values passed to the user_id and/or screen_name parameters. * * @param mixed[optional] $userIds An array of user IDs, up to 100 are allowed in a single request. * @param mixed[optional] $screenNames An array of screen names, up to 100 are allowed in a single request. * @param bool[optional] $includeEntities The entities node that may appear within embedded statuses will be disincluded when set to false. * @return array */ public function usersLookup( $userIds = null, $screenNames = null, $includeEntities = null ) { // redefine $userIds = (array) $userIds; $screenNames = (array) $screenNames; // validate if (empty($userIds) && empty($screenNames)) { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if (!empty($userIds)) { $parameters['user_id'] = implode(',', $userIds); } if (!empty($screenNames)) { $parameters['screen_name'] = implode(',', $screenNames); } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall('users/lookup.json', $parameters, true); } /** * Returns a variety of information about the user specified by the required user_id or screen_name parameter. * The author's most recent Tweet will be returned inline when possible. * * @param string[optional] $userId The screen name of the user for whom to return results for. Either a id or screen_name is required for this method. * @param string[optional] $screenName The ID of the user for whom to return results for. Either an id or screen_name is required for this method. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @return array */ public function usersShow( $userId = null, $screenName = null, $includeEntities = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : '0'; } // make the call return (array) $this->doCall('users/show.json', $parameters); } /** * Run a search for users similar to the Find People button on Twitter.com; the same results returned by people search on Twitter.com will be returned by using this API. * Usage note: It is only possible to retrieve the first 1000 matches from this API. * * @param string $q The search query to run against people search. * @param int[optional] $page Specifies the page of results to retrieve. * @param int[optional] $count The number of potential user results to retrieve per page. This value has a maximum of 20. * @param bool[optional] $includeEntities The entities node will be disincluded from embedded tweet objects when set to false. * @return array */ public function usersSearch( $q, $page = null, $count = null, $includeEntities = null ) { // build parameters $parameters['q'] = (string) $q; if($page != null) $parameters['page'] = (int) $page; if($count != null) $parameters['count'] = (int) $count; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall('users/search.json', $parameters, true); } /** * Returns a collection of users that the specified user can "contribute" to. * * @param string[optional] $userId The ID of the user for whom to return results for. * @param string[optional] $screenName The screen name of the user for whom to return results for. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function usersContributees( $userId = null, $screenName = null, $includeEntities = null, $skipStatus = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'users/contributees.json', $parameters ); } /** * Returns a collection of users who can contribute to the specified account. * * @param string[optional] $userId The ID of the user for whom to return results for. * @param string[optional] $screenName The screen name of the user for whom to return results for. * @param bool[optional] $includeEntities The entities node will not be included when set to false. * @param bool[optional] $skipStatus When set to either true, t or 1 statuses will not be included in the returned user objects. * @return array */ public function usersContributors( $userId = null, $screenName = null, $includeEntities = null, $skipStatus = null ) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } if ($skipStatus !== null) { $parameters['skip_status'] = ($skipStatus) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'users/contributors.json', $parameters ); } /** * Removes the uploaded profile banner for the authenticating user. * * @return bool */ public function accountRemoveProfileBanner() { $return = (array) $this->doCall( 'account/remove_profile_banner.json', null, true, 'POST', null, false, true ); return ($return['http_code'] == 200); } /** * Not implemented yet */ public function accountUpdateProfileBanner() { throw new Exception('Not implemented'); } /** * Returns a map of the available size variations of the specified user's profile banner. If the user has not uploaded a profile banner, a HTTP 404 will be served instead. * * @param string[optional] $userId The ID of the user for whom to return results for. Helpful for disambiguating when a valid user ID is also a valid screen name. * @param string[optional] $screenName The screen name of the user for whom to return results for. Helpful for disambiguating when a valid screen name is also a user ID. * @return array */ public function usersProfileBanner($userId = null, $screenName = null) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if($userId != null) $parameters['user_id'] = (string) $userId; if($screenName != null) $parameters['screen_name'] = (string) $screenName; return (array) $this->doCall( 'users/profile_banner.json', $parameters, true ); } // Suggested users resources /** * Access the users in a given category of the Twitter suggested user list. * It is recommended that applications cache this data for no more than one hour. * * @param string $slug The short name of list or a category. * @param string[optional] $lang Restricts the suggested categories to the requested language. The language must be specified by the appropriate two letter ISO 639-1 representation. Currently supported languages are provided by the helpLanguages API request. Unsupported language codes will receive English (en) results. * @return array */ public function usersSuggestionsSlug($slug, $lang = null) { $parameters = null; if($lang != null) $parameters['lang'] = (string) $lang; return (array) $this->doCall( 'users/suggestions/' . (string) $slug . '.json', $parameters, true ); } /** * Access to Twitter's suggested user list. This returns the list of suggested user categories. The category can be used in usersSuggestionsSlug to get the users in that category. * * @param string[optional] $lang Restricts the suggested categories to the requested language. The language must be specified by the appropriate two letter ISO 639-1 representation. Currently supported languages are provided by the helpLanguages API request. Unsupported language codes will receive English (en) results. * @return array */ public function usersSuggestions($lang = null) { $parameters = null; if($lang != null) $parameters['lang'] = (string) $lang; return (array) $this->doCall( 'users/suggestions.json', $parameters, true ); } /** * Access the users in a given category of the Twitter suggested user list and return their most recent status if they are not a protected user. * * @param string $slug The short name of list or a category * @return array */ public function usersSuggestionsSlugMembers($slug) { return (array) $this->doCall( 'users/suggestions/' . (string) $slug . '/members.json', null, true ); } // Favorites resources /** * Returns the 20 most recent Tweets favorited by the authenticating or specified user. * * @param string[otpional] $userId The ID of the user for whom to return results for. * @param string[otpional] $screenName The screen name of the user for whom to return results for. * @param int[optional] $count Specifies the number of records to retrieve. Must be less than or equal to 200. Defaults to 20. * @param string[otpional] $sinceId Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available. * @param string[otpional] $maxId Returns results with an ID less than (that is, older than) or equal to the specified ID. * @param bool[optional] $includeEntities The entities node will be omitted when set to false. * @return array */ public function favoritesList( $userId = null, $screenName = null, $count = 20, $sinceId = null, $maxId = null, $includeEntities = null) { // validate if ($userId == '' && $screenName == '') { throw new Exception('Specify an userId or a screenName.'); } // build parameters $parameters = null; if($userId != null) $parameters['user_id'] = (string) $userId; if($screenName != null) $parameters['screen_name'] = (string) $screenName; if($count != null) $parameters['count'] = (int) $count; if($sinceId != null) $parameters['since_id'] = (string) $sinceId; if($maxId != null) $parameters['max_id'] = (string) $maxId; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall('favorites/list.json', $parameters, true); } /** * Un-favorites the status specified in the ID parameter as the authenticating user. Returns the un-favorited status in the requested format when successful. * This process invoked by this method is asynchronous. The immediately returned status may not indicate the resultant favorited status of the tweet. A 200 OK response from this method will indicate whether the intended action was successful or not. * * @return array * @param string $id The numerical ID of the desired status. * @param bool[optional] $includeEntities The entities node will be omitted when set to false. */ public function favoritesDestroy($id, $includeEntities = null) { // build parameters $parameters['id'] = (string) $id; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'favorites/destroy.json', $parameters, true, 'POST' ); } /** * Favorites the status specified in the ID parameter as the authenticating user. Returns the favorite status when successful. * This process invoked by this method is asynchronous. The immediately returned status may not indicate the resultant favorited status of the tweet. A 200 OK response from this method will indicate whether the intended action was successful or not. * * @param string $id The numerical ID of the desired status. * @param bool[optional] $includeEntities The entities node will be omitted when set to false. * @return array */ public function favoritesCreate($id, $includeEntities = null) { // build parameters $parameters['id'] = (string) $id; if ($includeEntities !== null) { $parameters['include_entities'] = ($includeEntities) ? 'true' : 'false'; } // make the call return (array) $this->doCall( 'favorites/create.json', $parameters, true, 'POST' ); } // Lists resources /** * Not implemented yet */ public function listsList() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsStatuses() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsMembersDestroy() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsMemberships() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsSubscribers() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsSubscribersCreate() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsSubscribersShow() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsSubscribersDestroy() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsMembersCreateAll() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsMembersShow() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsMembers() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsMembersCreate() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsDestroy() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsUpdate() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsCreate() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsShow() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listSubscriptions() { throw new Exception('Not implemented'); } /** * Not implemented yet */ public function listsMembersDestroyAll() { throw new Exception('Not implemented'); } // Saved Searches resources /** * Returns the authenticated user's saved search queries. * * @return array */ public function savedSearchesList() { // make the call return (array) $this->doCall('saved_searches/list.json', null, true); } /** * Retrieve the information for the saved search represented by the given id. The authenticating user must be the owner of saved search ID being requested. * * @return array * @param string $id The ID of the saved search. */ public function savedSearchesShow($id) { // make the call return (array) $this->doCall( 'saved_searches/show/' . (string) $id . '.json', null, true ); } /** * Create a new saved search for the authenticated user. A user may only have 25 saved searches. * * @return array * @param string $query The query of the search the user would like to save. */ public function savedSearchesCreate($query) { // build parameters $parameters['query'] = (string) $query; // make the call return (array) $this->doCall( 'saved_searches/create.json', $parameters, true, 'POST' ); } /** * Destroys a saved search for the authenticating user. The authenticating user must be the owner of saved search id being destroyed. * * @return array * @param string $id The ID of the saved search. */ public function savedSearchesDestroy($id) { return (array) $this->doCall( 'saved_searches/destroy/' . (string) $id . '.json', null, true, 'POST' ); } // Geo resources /** * Returns all the information about a known place. * * @param string $id A place in the world. These IDs can be retrieved from geo/reverse_geocode. * @return array */ public function geoId($id) { // build parameters $parameters = null; // make the call return (array) $this->doCall( 'geo/id/' . (string) $id . '.json', $parameters ); } /** * Given a latitude and a longitude, searches for up to 20 places that can be used as a place_id when updating a status. * This request is an informative call and will deliver generalized results about geography. * * @param float $lat The latitude to search around. This parameter will be ignored unless it is inside the range -90.0 to +90.0 (North is positive) inclusive. It will also be ignored if there isn't a corresponding long parameter. * @param float $long The longitude to search around. The valid ranges for longitude is -180.0 to +180.0 (East is positive) inclusive. This parameter will be ignored if outside that range, if it is not a number, if geo_enabled is disabled, or if there not a corresponding lat parameter. * @param string[optional] $accuracy A hint on the "region" in which to search. If a number, then this is a radius in meters, but it can also take a string that is suffixed with ft to specify feet. If this is not passed in, then it is assumed to be 0m. If coming from a device, in practice, this value is whatever accuracy the device has measuring its location (whether it be coming from a GPS, WiFi triangulation, etc.). * @param string[optional] $granularity This is the minimal granularity of place types to return and must be one of: poi, neighborhood, city, admin or country. If no granularity is provided for the request neighborhood is assumed. Setting this to city, for example, will find places which have a type of city, admin or country. * @param int[optional] $maxResults A hint as to the number of results to return. This does not guarantee that the number of results returned will equal max_results, but instead informs how many "nearby" results to return. Ideally, only pass in the number of places you intend to display to the user here. * @return array */ public function geoReverseGeoCode( $lat, $long, $accuracy = null, $granularity = null, $maxResults = null ) { // build parameters $parameters['lat'] = (float) $lat; $parameters['long'] = (float) $long; if ($accuracy != null) { $parameters['accuracy'] = (string) $accuracy; } if ($granularity != null) { $parameters['granularity'] = (string) $granularity; } if ($maxResults != null) { $parameters['max_results'] = (int) $maxResults; } // make the call return (array) $this->doCall('geo/reverse_geocode.json', $parameters); } /** * Search for places that can be attached to a statuses/update. Given a latitude and a longitude pair, an IP address, or a name, this request will return a list of all the valid places that can be used as the place_id when updating a status. * Conceptually, a query can be made from the user's location, retrieve a list of places, have the user validate the location he or she is at, and then send the ID of this location with a call to POST statuses/update. * This is the recommended method to use find places that can be attached to statuses/update. Unlike GET geo/reverse_geocode which provides raw data access, this endpoint can potentially re-order places with regards to the user who is authenticated. This approach is also preferred for interactive place matching with the user. * * @param float[optional] $lat The latitude to search around. This parameter will be ignored unless it is inside the range -90.0 to +90.0 (North is positive) inclusive. It will also be ignored if there isn't a corresponding long parameter. * @param float[optional] $long The longitude to search around. The valid ranges for longitude is -180.0 to +180.0 (East is positive) inclusive. This parameter will be ignored if outside that range, if it is not a number, if geo_enabled is disabled, or if there not a corresponding lat parameter. * @param string[optional] $query Free-form text to match against while executing a geo-based query, best suited for finding nearby locations by name. Remember to URL encode the query. * @param string[optional] $ip An IP address. Used when attempting to fix geolocation based off of the user's IP address. * @param string[optional] $granularity This is the minimal granularity of place types to return and must be one of: poi, neighborhood, city, admin or country. If no granularity is provided for the request neighborhood is assumed. Setting this to city, for example, will find places which have a type of city, admin or country. * @param string[optional] $accuracy A hint on the "region" in which to search. If a number, then this is a radius in meters, but it can also take a string that is suffixed with ft to specify feet. If this is not passed in, then it is assumed to be 0m. If coming from a device, in practice, this value is whatever accuracy the device has measuring its location (whether it be coming from a GPS, WiFi triangulation, etc.). * @param int[optional] $maxResults A hint as to the number of results to return. This does not guarantee that the number of results returned will equal max_results, but instead informs how many "nearby" results to return. Ideally, only pass in the number of places you intend to display to the user here. * @param string[optional] $containedWithin This is the place_id which you would like to restrict the search results to. Setting this value means only places within the given place_id will be found. Specify a place_id. For example, to scope all results to places within "San Francisco, CA USA", you would specify a place_id of "5a110d312052166f" * @param array[optional] $attributes This parameter searches for places which have this given street address. There are other well-known, and application specific attributes available. Custom attributes are also permitted. This should be an key-value-pair-array. * @return array */ public function geoSearch( $lat = null, $long = null, $query = null, $ip = null, $granularity = null, $accuracy = null, $maxResults = null, $containedWithin = null, array $attributes = null ) { // build parameters $parameters = array(); if ($lat != null) { $parameters['lat'] = (float) $lat; } if ($long != null) { $parameters['long'] = (float) $long; } if ($query != null) { $parameters['query'] = (string) $query; } if ($ip != null) { $parameters['ip'] = (string) $ip; } if ($accuracy != null) { $parameters['accuracy'] = (string) $accuracy; } if ($granularity != null) { $parameters['granularity'] = (string) $granularity; } if ($maxResults != null) { $parameters['max_results'] = (int) $maxResults; } if ($containedWithin != null) { $parameters['contained_within'] = (string) $containedWithin; } if ($attributes != null) { foreach ($attributes as $key => $value) { $parameters['attribute:' . $key] = (string) $value; } } // make the call return (array) $this->doCall('geo/search.json', $parameters); } /** * Locates places near the given coordinates which are similar in name. * Conceptually you would use this method to get a list of known places to choose from first. Then, if the desired place doesn't exist, make a request to POST geo/place to create a new one. * The token contained in the response is the token needed to be able to create a new place. * * @param float $lat The latitude to search around. This parameter will be ignored unless it is inside the range -90.0 to +90.0 (North is positive) inclusive. It will also be ignored if there isn't a corresponding long parameter. * @param float $long The longitude to search around. The valid ranges for longitude is -180.0 to +180.0 (East is positive) inclusive. This parameter will be ignored if outside that range, if it is not a number, if geo_enabled is disabled, or if there not a corresponding lat parameter. * @param string $name The name a place is known as. * @param string[optional] $containedWithin This is the place_id which you would like to restrict the search results to. Setting this value means only places within the given place_id will be found. Specify a place_id. For example, to scope all results to places within "San Francisco, CA USA", you would specify a place_id of "5a110d312052166f" * @param array[optional] $attributes This parameter searches for places which have this given street address. There are other well-known, and application specific attributes available. Custom attributes are also permitted. * @return array */ public function geoSimilarPlaces( $lat, $long, $name, $containedWithin = null, array $attributes = null ) { // build parameters $parameters['lat'] = (float) $lat; $parameters['long'] = (float) $long; $parameters['name'] = (string) $name; if ($containedWithin != null) { $parameters['contained_within'] = (string) $containedWithin; } if ($attributes != null) { foreach ($attributes as $key => $value) { $parameters['attribute:' . $key] = (string) $value; } } // make the call return (array) $this->doCall('geo/similar_places.json', $parameters); } /** * Creates a new place at the given latitude and longitude. * * @param string $name The name a place is known as. * @param string $containedWithin The place_id within which the new place can be found. Try and be as close as possible with the containing place. For example, for a room in a building, set the contained_within as the building place_id. * @param string $token The token found in the response from geo/similar_places. * @param float $lat The latitude the place is located at. This parameter will be ignored unless it is inside the range -90.0 to +90.0 (North is positive) inclusive. It will also be ignored if there isn't a corresponding long parameter. * @param float $long The longitude the place is located at. The valid ranges for longitude is -180.0 to +180.0 (East is positive) inclusive. This parameter will be ignored if outside that range, if it is not a number, if geo_enabled is disabled, or if there not a corresponding lat parameter. * @param array[optional] $attributes This parameter searches for places which have this given street address. There are other well-known, and application specific attributes available. Custom attributes are also permitted. This should be an key-value-pair-array. * @return array */ public function geoPlace( $name, $containedWithin, $token, $lat, $long, array $attributes = null ) { // build parameters $parameters['name'] = (string) $name; $parameters['contained_within'] = (string) $containedWithin; $parameters['token'] = (string) $token; $parameters['lat'] = (float) $lat; $parameters['long'] = (float) $long; if ($attributes != null) { foreach ($attributes as $key => $value) { $parameters['attribute:' . $key] = (string) $value; } } // make the call return (array) $this->doCall( 'geo/create.json', $parameters, true, 'POST' ); } // Trends resources /** * Returns the top 10 trending topics for a specific WOEID, if trending information is available for it. * The response is an array of "trend" objects that encode the name of the trending topic, the query parameter that can be used to search for the topic on Twitter Search, and the Twitter Search URL. * This information is cached for 5 minutes. Requesting more frequently than that will not return any more data, and will count against your rate limit usage. * * @param string $id The Yahoo! Where On Earth ID of the location to return trending information for. Global information is available by using 1 as the WOEID. * @param string[optional] $exclude Setting this equal to hashtags will remove all hashtags from the trends list. * @return array */ public function trendsPlace($id, $exclude = null) { // build parameters $parameters['id'] = (string) $id; if ($exclude != null) { $parameters['exclude'] = (string) $exclude; } return (array) $this->doCall( 'trends/place.json', $parameters ); } /** * Returns the locations that Twitter has trending topic information for. * The response is an array of "locations" that encode the location's WOEID (a Yahoo! Where On Earth ID) and some other human-readable information such as a canonical name and country the location belongs in. * The WOEID that is returned in the location object is to be used when querying for a specific trend. * * @param float[optional] $lat If passed in conjunction with long, then the available trend locations will be sorted by distance to the lat and long passed in. The sort is nearest to furthest. * @param float[optional] $long If passed in conjunction with lat, then the available trend locations will be sorted by distance to the lat and long passed in. The sort is nearest to furthest. * @return array */ public function trendsAvailable($lat = null, $long = null) { // build parameters $parameters = null; if($lat != null) $parameters['lat_for_trends'] = (float) $lat; if($long != null) $parameters['long_for_trends'] = (float) $long; // make the call return (array) $this->doCall('trends/available.json', $parameters); } /** * Returns the locations that Twitter has trending topic information for, closest to a specified location. * The response is an array of "locations" that encode the location's WOEID and some other human-readable information such as a canonical name and country the location belongs in. * * @param float[optional] $lat If provided with a long parameter the available trend locations will be sorted by distance, nearest to furthest, to the co-ordinate pair. The valid ranges for longitude is -180.0 to +180.0 (West is negative, East is positive) inclusive. * @param float[optional] $long If provided with a lat parameter the available trend locations will be sorted by distance, nearest to furthest, to the co-ordinate pair. The valid ranges for longitude is -180.0 to +180.0 (West is negative, East is positive) inclusive. * @return array */ public function trendsClosest($lat = null, $long = null) { // build parameters $parameters = null; if($lat != null) $parameters['lat'] = (float) $lat; if($long != null) $parameters['long'] = (float) $long; // make the call return (array) $this->doCall('trends/closest.json', $parameters); } // Spam Reporting resources /** * The user specified in the id is blocked by the authenticated user and reported as a spammer. * * @param string[optional] $screenName The ID or screen_name of the user you want to report as a spammer. Helpful for disambiguating when a valid screen name is also a user ID. * @param string[optional] $userId The ID of the user you want to report as a spammer. Helpful for disambiguating when a valid user ID is also a valid screen name. * @return array */ public function reportSpam($screenName = null, $userId = null) { // validate if ($userId == '' && $screenName == '') { throw new Exception('One of these parameters must be provided.'); } // build parameters if ($userId != null) { $parameters['user_id'] = (string) $userId; } if ($screenName != null) { $parameters['screen_name'] = (string) $screenName; } // make the call return (array) $this->doCall( 'users/report_spam.json', $parameters, true, 'POST' ); } // OAuth resources /** * Allows a Consumer application to use an OAuth request_token to request user authorization. This method is a replacement fulfills Secion 6.2 of the OAuth 1.0 authentication flow for applications using the Sign in with Twitter authentication flow. The method will use the currently logged in user as the account to for access authorization unless the force_login parameter is set to true * REMARK: This method seems not to work @later * * @param bool[optional] $force Force the authentication. */ public function oAuthAuthenticate($force = false) { throw new Exception('Not implemented'); // build parameters $parameters = null; if((bool) $force) $parameters['force_login'] = 'true'; // make the call return $this->doCall('/oauth/authenticate.oauth', $parameters); } /** * Will redirect to the page to authorize the applicatione * * @param string $token The token. */ public function oAuthAuthorize($token) { header('Location: ' . self::SECURE_API_URL . '/oauth/authorize?oauth_token=' . $token); } /** * Allows a Consumer application to exchange the OAuth Request Token for an OAuth Access Token. * This method fulfills Secion 6.3 of the OAuth 1.0 authentication flow. * * @param string $token The token to use. * @param string $verifier The verifier. * @return array */ public function oAuthAccessToken($token, $verifier) { // init var $parameters = array(); $parameters['oauth_token'] = (string) $token; $parameters['oauth_verifier'] = (string) $verifier; // make the call $response = $this->doOAuthCall('access_token', $parameters); // set some properties if (isset($response['oauth_token'])) { $this->setOAuthToken($response['oauth_token']); } if (isset($response['oauth_token_secret'])) { $this->setOAuthTokenSecret($response['oauth_token_secret']); } // return return $response; } /** * Allows a Consumer application to obtain an OAuth Request Token to request user authorization. * This method fulfills Secion 6.1 of the OAuth 1.0 authentication flow. * * @param string[optional] $callbackURL The callback URL. * @return array An array containg the token and the secret */ public function oAuthRequestToken($callbackURL = null) { // init var $parameters = null; // set callback if ($callbackURL != null) { $parameters['oauth_callback'] = (string) $callbackURL; } // make the call $response = $this->doOAuthCall('request_token', $parameters); // validate if (!isset($response['oauth_token'], $response['oauth_token_secret'])) { throw new Exception(implode(', ', array_keys($response))); } // set some properties if (isset($response['oauth_token'])) { $this->setOAuthToken($response['oauth_token']); } if (isset($response['oauth_token_secret'])) { $this->setOAuthTokenSecret($response['oauth_token_secret']); } // return return $response; } // Help resources /** * Returns the current configuration used by Twitter including twitter.com slugs which are not usernames, maximum photo resolutions, and t.co URL lengths. * It is recommended applications request this endpoint when they are loaded, but no more than once a day. * * @return array */ public function helpConfiguration() { // make the call return $this->doCall( 'help/configuration.json' ); } /** * Returns the list of languages supported by Twitter along with their ISO 639-1 code. The ISO 639-1 code is the two letter value to use if you include lang with any of your requests. * * @return array */ public function helpLanguages() { // make the call return $this->doCall( 'help/languages.json' ); } /** * Returns Twitter's Privacy Policy * * @return array */ public function helpPrivacy() { // make the call return $this->doCall( 'help/privacy.json' ); } /** * Returns the Twitter Terms of Service in the requested format. These are not the same as the Developer Rules of the Road. * * @return array */ public function helpTos() { // make the call return $this->doCall( 'help/tos.json' ); } /** * Returns the current rate limits for methods belonging to the specified resource families. * Each 1.1 API resource belongs to a "resource family" which is indicated in its method documentation. You can typically determine a method's resource family from the first component of the path after the resource version. * This method responds with a map of methods belonging to the families specified by the resources parameter, the current remaining uses for each of those resources within the current rate limiting window, and its expiration time in epoch time. It also includes a rate_limit_context field that indicates the current access token context. * You may also issue requests to this method without any parameters to receive a map of all rate limited GET methods. If your application only uses a few of methods, please explicitly provide a resources parameter with the specified resource families you work with. * * @param array $resources A comma-separated list of resource families you want to know the current rate limit disposition for. For best performance, only specify the resource families pertinent to your application. * @return string */ public function applicationRateLimitStatus(array $resources = null) { $parameters = null; if (!empty($resources)) { $parameters['resources'] = implode(',', $resources); } // make the call return $this->doCall( 'application/rate_limit_status.json', $parameters ); } }
{ "redpajama_set_name": "RedPajamaGithub" }
4,091
Note: You are currently viewing documentation for Moodle 1.9. Up-to-date documentation for the latest stable version is available here: XAMPP171 Install folder.png. This page was last modified on 21 June 2009, at 03:17.
{ "redpajama_set_name": "RedPajamaC4" }
8,089
\section*{Acknowledgment} We gratefully acknowledge the effort of the CESR staff in providing us with excellent luminosity and running conditions. This work was supported by the National Science Foundation and the U.S. Department of Energy.
{ "redpajama_set_name": "RedPajamaArXiv" }
2,165
When we moved into the country, there was no cable television. We decided on Starchoice satellite TV at that time and generally things went well. There were weather? related outages many times per year, sometimes at the very worst of times (February 1, 2003 – The shuttle Columbia disaster). Since then the subscription price has gone up, much faster than inflation. About 1 year ago it had reached over $120 and we said enough! We then attempted to cut back on various packages and choices and in the end, the amount was even more than before. This was because of there pricing scheme..always trying to get you to go for just a little bit bigger package. A year later, it was still over $100/month and we were entering into the spring and summer seasons of being outdoors most of the time and not watching TV. So it got axed. So far, three weeks later, no harm no foul, no bad afteraffects. We did decide to try out Netflix.ca and at $8/mo it has turned out to be an excellent choice. The simple ability of it remembering where we left off when binge-watching a particular series is great. IN the past, we would have to rewatch bits and pieces of episodes to try and decide where we were. and some things we are watching for the 1st time: Glee, Buffy the Vampire Slayer and more. Future series to watch that we never have before include: Lost, Mad Men, Breaking Bad and again, a lot more. The local cable tv company now does service our area, but try as you might, you cannot get prices from their website on TV packages. Very frustrating. Sometimes one does not want to expose oneself to a marketing person, no matter how much you may be interested. Eastlink! We are talking about you! Put your prices out in clear easy to find text!
{ "redpajama_set_name": "RedPajamaC4" }
96
Pavao Rudan, hrvaški zdravnik, antropolog, pedagog in akademik, * 15. december 1942, Zagreb. Rudan je predavatelj na Medicinski fakulteti in na Naravoslovno-matematični fakulteti v Zagrebu; je član Hrvaške akademije znanosti in umetnosti, bivše Jugoslovanske akademije znanosti in umetnosti in Akademije za medicinske znanosti Hrvaške. Glej tudi seznam hrvaških zdravnikov seznam hrvaških pedagogov seznam hrvaških akademikov seznam hrvaških antropologov seznam članov Hrvaške akademije znanosti in umetnosti Rudan, Pavao Rudan, Pavao Rudan, Pavao Rudan, Pavao Rudan, Pavao Rudan, Pavao Rudan, Pavao Rudan, Pavao Rudan, Pavao Hrvaški univerzitetni učitelji
{ "redpajama_set_name": "RedPajamaWikipedia" }
3,205
""" Call this like 'python install-script-gen.py'; to generate the python environment for this tool Based on example script: https://github.com/socialplanning/fassembler/blob/master/fassembler/create-venv-script.py """ import os, sys import subprocess import re here = os.path.dirname(os.path.abspath(__file__)) if not here.endswith("/"): here += "/" base_dir = os.path.dirname(here) script_name = os.path.join(base_dir, 'install-script.py') try: import virtualenv except ImportError, e: print 'Error: Virtualenv is not installed, please run the following first:' print 'sudo pip install virtualenv' sys.exit() EXTRA_TEXT = """ import shutil, sys def adjust_options(options, args): if not args: return # caller will raise error # We're actually going to build the venv in a subdirectory base_dir = args[0] args[0] = join(base_dir, 'venv') def after_install(options, home_dir): base_dir = os.path.dirname(home_dir) file_content = open('dependencies.txt') file_content = file_content.readlines() dependencies = [] for line in file_content: if line.strip() != '': dependencyListFull = [a.strip().replace(\"'\", '').replace('\"', '') for a in line.split(',')] dependencyList = {} for dependencyStr in dependencyListFull: dependencyList[dependencyStr.split(':')[0].strip()] = dependencyStr.split(':')[1].strip() dependencies.append(dependencyList) for dependency in dependencies: cwdDir = home_dir if dependency['cwd'] != 'home_dir': cwdDir = dependency['cwd'] parameters = [a.strip() for a in dependency['parms'].split(' ')] programPath = os.path.abspath(join(home_dir, 'bin', dependency['cmd'])) fullProgramArray = [programPath] + parameters call_subprocess(fullProgramArray, cwd=os.path.abspath(cwdDir), filter_stdout=filter_python_develop, show_stdout=False) def fs_ensure_dir(dir): if not os.path.exists(dir): logger.info('Creating directory %s' % dir) os.makedirs(dir) def filter_python_develop(line): if not line.strip(): return Logger.DEBUG for prefix in ['Searching for', 'Reading ', 'Best match: ', 'Processing ', 'Moving ', 'Adding ', 'running ', 'writing ', 'Creating ', 'creating ', 'Copying ']: if line.startswith(prefix): return Logger.DEBUG return Logger.NOTIFY """ def main(): # Generate installation script text = virtualenv.create_bootstrap_script(EXTRA_TEXT, python_version='2.7.9') # Save script if it has been changed if os.path.exists(script_name): f = open(script_name) cur_text = f.read() f.close() else: cur_text = '' print 'Updating %s' % script_name if cur_text == 'text': print 'No update' else: print 'Script changed; updating...' f = open(script_name, 'w') f.write(text) f.close() print 'Filename: ' + script_name # Execute script (hacky, should be imported instead) print 'Executing installation script...' subprocess.call(['python', script_name, 'bin']) # Destroy script (will get re-created if this file runs again) print 'Removing installation script...' os.remove(script_name) if __name__ == '__main__': main()
{ "redpajama_set_name": "RedPajamaGithub" }
958
There are about 10 plans available. Go to that link to access each plan in any of the options above. In order to make the readings come out evenly, four major books of the Bible are included twice in the schedule: the Psalms (the Bible's hymnal), Isaiah (the grandest of the OT prophets), Luke (one of the four biblical Gospels), and Romans (the heart of the Bible's theology of salvation). The list of readings from the Psalms and the Wisdom Literature begins and ends with special readings that are especially appropriate for the opening and closing of the year. The list of readings from the Pentateuch and the History of Israel proceeds canonically through the five books of Moses and then chronologically through the history of the OT, before closing the year with the sufferings of Job. The list of readings from the Chronicles and the Prophets begins with the Chronicler's history of the people of God from Adam through the exile, followed by the Major and Minor Prophets, which are organized chronologically rather than canonically. I plan to print out this PDF, which is designed to be cut into four bookmarks that can be placed at the appropriate place in your Bible reading. If you like this plan, you may want to pick up a copy of the Daily Reading Bible (available in hardcover and paperback). It's not in the style where the Bible itself is rearranged by readings. Rather, it is a normal Bible, except that there are marginal notations that indicate where you are to start and stop reading. If you go with this route, I'd recommend D.A. Carson's For the Love of God (vol. 1 and vol. 2 are available–vols. 3 and 4 are forthcoming). Carson's introduction and preface–which includes a layout of the calendar–are available for free online. Since there are four readings each day, it's easy to modify this one so that you read through the Bible once in two years, by reading just the first two readings each day for the first year and the second two readings each day for the second year. With this plan you read through the entire Bible once. To prevent the frustration of falling behind, which most of us tend to do when following a Bible reading plan, each month of this plan gives you only 25 readings. Since you'll have several "free days" each month, you could set aside Sunday to either not read at all or to catch up on any readings you may have missed in the past week. If you finish the month's readings by the twenty-fifth, you could use the final days of the month to study passages that challenged or intrigued you. the second reading is about a chapter a day of the wisdom literature and Isaiah. As with the Discipleship Journal Plan, there are only 25 readings a month, allowing for catch-up and/or reflection.
{ "redpajama_set_name": "RedPajamaC4" }
1,760
Online Short Term Loans - Quick, Simple & Paperless! With the economy the way it is, money's tight for many people these days and traditional lending institutions have become very choosy when deciding to give credit – essentially you need more security and higher credit rating to even be considered for a loan. Luckily for many of us who struggle with unexpected expenses, there are a host of online short loan providers that will step in to help where larger banks won't! These online short term loan providers have different business models which allows them to make loans accessible to people without a perfect credit history. The amount you can borrow is also lower – most providers will offer short term loans of up to R 8 000 – and as the name suggests, the loans are generally repayable in much shorter time periods. Why would anyone want to take a short-term loan online? Because life is unpredictable and you might face an unexpected expense that needs to be met – like say you need and emergency operation – or you have other financial dues that you need to meet so that they don't impact your overall credit score – like an overdue retail account. With online short term loan providers you have the facility to meet these expenses. What makes online short term loans so attractive is the extremely easy approval process. You simply visit the website and fill out the application form which normally takes about 5-10 minutes. And that's it! No paperwork, branch visits or queues! Secondly, because short term loan providers have different rating criteria, you are more likely to get approved than by a traditional lender. For those with imperfect credit scores, this is a huge benefit! And since the lender knows that there is often a quick turn around required, applications are reviewed instantly and the money can be in your account in less than a day! This quick disbursement feature further makes short term loans the best choice when you need cash in a hurry! To apply for an online short term loan, all you need is to fill in all the columns required with your information and hit a button to submit your application to the lending company. Short term loans are short term credit and should be repaid as soon as possible! The normal repayment is the next payday, but some providers offer longer periods to about 90 days. However, always remember that it is in your best interest to pay these loans as soon as possible and make sure you specify a date where you can guarantee that the funds will be in your account. You could possibly face steep charges and potential negative impact on your credit score if the lender is unable to extract the funds from your account on the assigned repayment date! Fantastic website you've gotten right here. Thank you very much for the interesting blog.Highly reccomend!
{ "redpajama_set_name": "RedPajamaC4" }
1,175
If you are moving interstate, the chances are you don't want to be driving behind the removalists truck the entire way. No, you want to get to your new home quickly and efficiently, feeling refreshed and ready to tackle the somewhat daunting task of setting up your life in a new location. And that's where our car relocation removalists enter the scene. At Central Victoria Removals we know that shifting interstate is a challenge. You have to pack up your household, leave your support network and start all over again. The details are endless and so is the pressure. But by using a trusted transport removalist you can rest assured that your car will be ready for you when you need it – no fuss, no stress and no need for you to navigate hours of driving when you're feeling fatigued from organising your move. We are experienced car relocation removalists and take a professional approach to loading, transporting and unloading your vehicle. It doesn't matter whether it's the family station wagon, a luxury vehicle, a classic model or an off-road warrior, we'll get it to its new destination safely, efficiently and at a competitive price. We can also transport other vehicles including golf carts and motorbikes. Whether it's one vehicle or several, we are the team for you. And because we offer a reliable tracking system, you can keep up to date with your vehicle's progress at any time during the interstate journey. Central Victoria Removals strives to deliver the best results for every client. We want to know your expectations and needs when it comes to car relocation and then we work hard to meet them. If you would like an obligation-free quote, then turn to the car relocation removalists that people trust – Central Victoria Removals. Please contact us for more information.
{ "redpajama_set_name": "RedPajamaC4" }
4,294
{"url":"https:\/\/ijnetworktoolcanon.co\/canon-ij-network-tool-windows-7\/","text":"# Canon IJ Network Tool Windows 7\n\n## Canon IJ Network Tool Windows 7\n\nCanon IJ Network Tool Windows 7\n\nCanon IJ Network Tool\u00a0Download Support for OS\u00a0Windows\u00a0and Mac \u2013\u00a0Canon IJ Network Tool\u00a0Setup device is a utility that allows you to screen and modify the community settings within the instrument.\u00a0Canon IJ Network Tool Windows 7\u00a0Canon Network Tools\u00a0It\u2019s put in in the event the machine is ready\n\nIJ Network\u00a0Driver Ver. 2.5.7\u00a0\/\u00a0Network Tool\u00a0Ver. 2.5.7\u00a0(Windows\u00a010\/8,1\/8\/Vista\/XP\/2000 32-64bit) This file is the LAN driver for\u00a0Canon IJ Network\u00a0. With this setup, you can print from the\u00a0Canon IJ Networkprinter that is connected through a\u00a0network\u00a0Canon IJ Network Tool Windows 7\n\nThe\u00a0Canon IJ Network Tool Windows 7\u00a0is an application that allows you to easily scan photos, documents, etc. You can complete the scan at the same time only by clicking on the appropriate icon in the\u00a0IJ\u00a0Scan Utility main screen Scan using\u00a0Canon IJ\u00a0Scan Utility in\u00a0Canon\u00a0PIXMA Printer\n\ncanon ij network tool\u00a0free download \u2013\u00a0Canon IJ\u00a0Printer Driver\u00a0Canon\u00a0iP4200,\u00a0Canon IJ\u00a0Printer Driver\u00a0Canon\u00a0iP5200,\u00a0Canon IJ\u00a0Printer Driver\u00a0Canon\u00a0iP6600D, and many more programs\n\nCanon IJ Network\u00a0Driver Ver. 2.5.7\u00a0\/\u00a0Network Tool\u00a0Ver. 2.5.7\u00a0(Windows) This file is the LAN driver for\u00a0Canon IJ Network. With this setup, you can print from the\u00a0Canon IJ Network\u00a0printer that is connected through a\u00a0network\n\nIn\u00a0Windows 7Windows\u00a0Vista, or\u00a0Windows\u00a0XP, click Start (Start) and select All Programs,\u00a0CanonUtilities,\u00a0IJ Network Tool, and then\u00a0IJ Network Tool. Note: To use the machine through a LAN, make sure you have the equipment needed for the connection type, such as the access point or LAN cable\u00a0Canon IJ Network Tool Windows 7\n\nIf\u00a0IJ Network Tool\u00a0is not displayed on the Start screen, select the Search charm, then search for \u201cIJ Network Tool\u00a0\u201c. In\u00a0Windows 7\u00a0,\u00a0Windows\u00a0Vista , or\u00a0Windows\u00a0XP , click Start and select All programs ,\u00a0Canon\u00a0Utilities ,\u00a0IJ Network Tool\u00a0, and then\u00a0IJ Network Tool\n\nIJ Network\u00a0Driver Ver. 2.5.7\u00a0\/\u00a0Network Tool\u00a0Ver. 2.5.7\u00a0(Windows) \u2013 This particular applications is the LAN driver for\u00a0Canon IJ Network. With this specific set up, you\u2019ll be able to print from the\u00a0Canon IJ Network\u00a0printer which is linked through a\u00a0network\n\n10,ij network tool windows\u00a010,scangear\u00a0canon\u00a0download\u00a0windows\u00a010,ij network\u00a0scanner ex2,scangear\u00a0canon windows\u00a010,canon network tool windows\u00a010,scangear\u00a0windows\u00a010 64 bit,10 2 5\u00a07,IJ\u00a0Scan Utility windows10\n\nCanon IJ Network Tool Windows\u00a010 \u2013 ,\u00a0Canon\u00a0Pixma\u00a0IJ\u00a0Setup Printer and Wireless Setup Solutions Drivers Downloads, Firmware & Software For\u00a0Windows, Mac Os and Linux. Easily scan documents to your\u00a0Windows\u00a0computer with the\u00a0Canon IJ\u00a0Scan Utility to\u00a0network\u00a0connection, set up the\u00a0networkenvironment from\u00a0IJ\u00a0Scan Utility\u00a0Canon IJ Network Tool Windows 7\n\nWith this established up, you could publish from the\u00a0Canon IJ Network\u00a0ink-jet printer that is hooked up via a\u00a0network.Utility that allows you to show and also make the\u00a0network\u00a0settings on the ink-jet printer engine. as well as could be defined when the equipment is mounted. appropriate for\u00a0Windows\u00a08.1\/ 8\/7\/Vista\/ XP\/Server as well as Mac OS X\u00a07\n\nIJ Network\u00a0Driver Ver. 2.5.7\u00a0\/\u00a0Network Tool\u00a0Ver. 2.5.7\u00a0(Windows\u00a010\/8,1\/8\/Vista\/XP\/2000 32-64bit) This file is the LAN driver for\u00a0Canon IJ Network\u00a0. With this setup, you can print from the\u00a0Canon IJ Networkprinter that is connected through a\u00a0network\n\nIn\u00a0Windows 7Windows\u00a0Vista, or\u00a0Windows\u00a0XP, click Start and select All programs,\u00a0Canon\u00a0Utilities,\u00a0IJ Network Tool, and then\u00a0IJ Network Tool. Depending on the printer you are using, an administrator password is already specified for the printer at the time of purchase\n\nIJ Network\u00a0Driver Ver. 2.5.7\u00a0\/\u00a0Network Tool\u00a0Ver. 2.5.7\u00a0(Windows\u00a010\/8,1\/8\/Vista\/XP\/2000 32-64bit) This file is the LAN driver for\u00a0Canon IJ Network\u00a0. With this setup, you can print from the\u00a0Canon IJ Networkprinter that is connected through a\u00a0network\u00a0Canon IJ Network Tool Windows 7\n\nCanon Ij Network\u00a0Setup\u00a0Windows 7\u00a0\u2013\u00a0Canon Ij Network\u00a0Setup\u00a0Windows 7\u00a0is actually an app that allows you to quickly scan pictures, documents, etc. Easy one-click scanning saves your time. Only off the brand, you will certainly have a smooth viewing from what the application does\n\n### Canon IJ Network Tool Windows 7 Hyperlink\n\nManual instruction all Canon Printers\n\nCanon IJ Network Tool Windows 7","date":"2019-06-16 23:00:02","metadata":"{\"extraction_info\": {\"found_math\": false, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 0, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.8580679893493652, \"perplexity\": 3575.9654792149536}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 20, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2019-26\/segments\/1560627998325.55\/warc\/CC-MAIN-20190616222856-20190617004856-00153.warc.gz\"}"}
null
null
Ruggedisedcomputers can be easily used in a harsh working environment and extreme temperature. In fact, these types of devices are being utilised in military operations. This is because it is designed to be more durable to withstand rough handling and severe wear-and-tear. But,whilst it is true that these computing systems may work effectively, maintaining a military operation is also tough. With its high level of military applications, panel PCs can be more efficient with the right peripheral devices. And, one of which is integrating an industrial-grade keyboard. An excellent peripheral solution for military computing systems is the 72-key illuminated industrial keyboard withtrackerball. Its LED backlighting feature allows readability even under tough ambient conditions. So,expect that this keyboard can perform its functions properly in military operations. But, why should the military industry take advantage of this type of industrial keyboard for a military setup? Good questionbecause this blog will showcase its varying features which make it suitable for different military operation. Technology is really gaining a momentum in the military industry. Majority of its departments are making use of industrial PCs to ensure well-functioned processes. Not only that, it also improves the efficiency of operations to streamline communication and information flow. But, upgrading these PCs with remarkable peripheral solutions can also further increases the advantages of having these systems.Say,an embedded computer that is equipped with a72-key ruggedised keyboardcan help enhance any military application.So, it creates an ergonomic typing feedback and navigation system due to the integrated pointing device.Also, with its multiple interface options, it can be compatible with many standardisedcomputer enclosures. Dispensing of information is highly critical for efficient military operations so it is essential to accurately encode data. But, panel PCs can be equipped with a 72-key industrial keyboard which bears a mechanical switch technology. This means that a key only needs to be pressed halfway for it to register. With its distinct, mechanical feedback, it requires less effortof whichuserscan identifyright away if a key has been pressed successfully. Situations requiring a speedy response arealso commonplace in the military.So, it is crucial that programs can benavigatedeasily and accurately for swift task execution. Fortunately,theintegratedtrackerballofthe rugged 72-key keyboard features 200 pulses/ball revolutions.Hence, military personnel can easily conduct various field tasksbecause this device offersaccuracy and efficiency. Typically, any equipment used in the military should be easy to configure and setup.That is why ourruggedisedkeyboards offermultiple placement options: cased, bezel, rear or flush mount.Therefore,itwill beconvenient to install in different military operations – whether in the command centre or onboard military vehicle setup.Likewise, operativescan also utilise the device even in a varying environment. But, toachieve these pre-requisites, operatives must use toughandrobust computing systems. However, in an ever-changing field, it isalso essentialto further upgrade computing technologies to get the most advantage.A great monitoringsolutioncould beembedded PCs equipped with the 72-key industrial keyboard to improve the execution of military tasks. Call anIC manufacturertodayandstart upgradingits peripheral devicesfor military usage.
{ "redpajama_set_name": "RedPajamaC4" }
7,831
''' Catches errors in m2t video files via ffmpeg. ''' import subprocess import os import json import argparse import time import ififuncs import bitc def parse_args(): ''' Parse command line arguments. ''' parser = argparse.ArgumentParser( description='Catches errors in m2t files via ffmpeg.' ' Written by Kieran O\'Leary.' ) parser.add_argument( 'input', help='Input directory' ) parsed_args = parser.parse_args() return parsed_args def main(): ''' Launches the commands that generate the CSV error report ''' args = parse_args() source = args.input csv_filename = os.path.join( ififuncs.make_desktop_logs_dir(), time.strftime("%Y-%m-%dT%H_%M_%S_videoerrors.csv") ) print('Report stored as %s' % csv_filename) if not os.path.isfile(csv_filename): ififuncs.create_csv(csv_filename, ['filename', 'start_time', 'timestamp', 'error', 'notes']) for root, _, filenames in os.walk(source): for filename in filenames: if filename.endswith('.m2t'): with open(csv_filename, 'r') as fo: if not filename in fo.read(): try: start_time = bitc.getffprobe('start_time', 'stream=start_time', os.path.join(root, filename)).rsplit()[0] json_output = subprocess.check_output(['ffprobe', '-sexagesimal', os.path.join(root, filename), '-show_error', '-show_log', '16', '-show_frames', '-of', 'json']) errors = False ffprobe_dict = json.loads(json_output) for values in ffprobe_dict: for more in ffprobe_dict[values]: if 'logs' in more: errors = True print(more['pkt_pts_time'], more['logs']) ififuncs.append_csv(csv_filename, [filename, start_time, more['pkt_pts_time'], more['logs'], '']) if errors == False: ififuncs.append_csv(csv_filename, [filename, start_time, 'no errors', 'no errors', '']) except subprocess.CalledProcessError: ififuncs.append_csv(csv_filename, [filename, start_time, 'script error - process file manually', '', '']) print('Report stored as %s' % csv_filename) if __name__ == '__main__': main()
{ "redpajama_set_name": "RedPajamaGithub" }
5,459
{"url":"https:\/\/www.eng-tips.com\/viewthread.cfm?qid=340352","text":"\u00d7\nINTELLIGENT WORK FORUMS\nFOR ENGINEERING PROFESSIONALS\n\nAre you an\nEngineering professional?\nJoin Eng-Tips Forums!\n\u2022 Talk With Other Members\n\u2022 Be Notified Of Responses\n\u2022 Keyword Search\nFavorite Forums\n\u2022 Automated Signatures\n\u2022 Best Of All, It's Free!\n\n*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.\n\n#### Posting Guidelines\n\nPromoting, selling, recruiting, coursework and thesis posting is forbidden.\n\n# Y U no speak right?3\n\n## Y U no speak right?\n\n(OP)\nI understand that this is an international forum, we give much latitude to those who speak English as a second or third language. What I don't understand is why someone would expect to be taken seriously when they post something in teenage text language. I consider it at least an order of magnitude worse than ALL CAPS. We're professionals here, our clients\/employers would never tolerate something this sloppy.\n\nTerry\nKI6FCI\n\n### RE: Y U no speak right?\n\nOr, as I was discussing with my supervisor the other day, when reviewing resumes and cover letters is not the time to discern that the applicant is not working in their native language; that should have to wait for the interview. When you're looking to make a good first impression it should be good; if you know English is a weak spot get some help for those important documents.\n\n### RE: Y U no speak right?\n\nIt is a capital mistake to theorise before one has data. Insensibly one begins to twist facts to suit theories, instead of theories to suit facts. (Sherlock Holmes - A Scandal in Bohemia.)\n\n### RE: Y U no speak right?\n\nThere are many resume's that only deserve to be thrown in the bin and never thought of again. I got one last year that had pretty good English until one of the last sections where he lapsed into text-speak. I came really close to sending him a rejection letter written all in text-speak, but I didn't figure he'd understand the sarcasm so I just binned it.\n\nDavid Simpson, PE\nMuleShoe Engineering\n\n\"Belief\" is the acceptance of an hypotheses in the absence of data.\n\"Prejudice\" is having an opinion not supported by the preponderance of the data.\n\"Knowledge\" is only found through the accumulation and analysis of data.\nThe plural of anecdote is not \"data\"\n\n### RE: Y U no speak right?\n\nI set my phone to accept no text messages.\u00a0\u00a0Anyone who sends me an e-mail message with text-speak in it gets it back with a string of random-letter 3- and 4- character words and real acronyms for my reply such as:\n\nluhs ftd aspca nom dlx cpa\n\nAnybody who hands me a written report with text-speak in it gets either terminated if already presented to a client or final-warninged if not yet sent.\n\nDid I just make up a new term, \"final-warninged?\"\n\nSide note on sending urgent text messages rather than phoning to talk:\n\nMy daughter Christina had offered to baby-sit a pregnant neighbor's 2-year-old whenever she went into labor and headed for the hospital. The big night came, and miss about-to-deliver SENT A TEXT MESSAGE at 2:00 AM to Christina to say she's on the way to the hospital, please hurry over.\u00a0\u00a0Little son is alone in the house and sleeping.\n\nAsleep herself, Christina didn't hear the small \"beep\" of a text arrival.\u00a0\u00a0She would've heard the phone ring, though.\u00a0\u00a0She kept it right by her bed.\u00a0\u00a0Expectant father TEXT-MESSAGED five times during the night, asking if little son is doing OK.\u00a0\u00a0Each message got a little nastier since Christina wasn't answering back.\n\nUpon awakening in the AM, she saw the text notices on her phone and ran to the new mom's house to care for the little son.\n\nWhen she heard the story, new mom exploded all over Christina for \"letting her down.\"\n\nI had to go visit new mom and instruct her in the art of dialing for a voice call.\n\nBest to you,\n\nGoober Dave\n\nHaven't see the forum policies?\u00a0\u00a0Do so now: Forum Policies\n\n### RE: Y U no speak right?\n\nI get frustrated when my children start in with a string of questions by text message. One question is ok, but when it leads to 4 or 5, calling is easier and quicker. I have also told them that if they want a reply immediately, phone, don't text. I am partially deaf and don't always hear the one buzz of the phone when a text message arrives.\n\n\"Wildfires are dangerous, hard to control, and economically catastrophic.\"\n\nBen Loosli\n\n### RE: Y U no speak right?\n\n(OP)\nI very much prefer text messages to voice mail. Luckily for me, I don't know anyone who uses text-speak. If they tried that with me they'd be final-warninged! (Thanks for the word, Dave!)\n\nA good text message is concise, precise, is quickly read, and omits superfluous information. A typical voice mail message drags on for a minute or more informing me of the price of tea in China, snowpack in Wyoming, and, oh yeah, the reason somebody called, followed by a recitation of the callers phone number in 1.538 seconds.\n\nObviously time sensitive information (like emergency babysitting) needs to be handled live, person to person. I find the lack of dependance on time, i.e. both parties being available at the same time to speak directly, is something that makes life much easier.\n\nTerry\nKI6FCI\n\n### RE: Y U no speak right?\n\nI agree on those points of text-messaging, HowDidYouBreakThat. It does have its plus side.\n\nTo me, another bad aspect of text-messaging is that it implies availability on weekends and nights to the people with whom I work. \"I'll just text him, he can look at his leisure instead of interrupting his dinner with a call.\"\n\nThe point is, when I quit work for the day or go on vacation, I'm not available for work.\n\nIt's nice being in non-connected land. No text available on our phones, actual buttons instead of touch-screen, and no mobile internet. My closest cohort is of the same mind. He still has rotary-dial AT&T phones at home. Yes, he still pays the rent to the phone company too.\n\nOK, I've drifted away from the topic. No more, except to add that y'all should all get a Samsung Rugby 2 phone. Mine has been dropped in a glass of Diet Coke, a toilet, and on concrete. No problem. It even survived the disinfectant after the toilet incident. It meets military spec for survivability.\n\nBest to you,\n\nGoober Dave\n\nHaven't see the forum policies? Do so now: Forum Policies\n\n### RE: Y U no speak right?\n\n#### Quote (DRWeig)\n\nThe point is, when I quit work for the day or go on vacation, I'm not available for work.\n\nI agree 100%. When we got our latest GM he asked our HR for my cell phone number who emailed me. My response was \"That's why I don't have one.\" I fail to understand why they will respect a land line (it's VOIP so not exactly stone age) but think it's OK to call\/text a cell number 24\/7. When I go on vacation I go someplace with no electricity, phones or cell reception. When asked how to reach me I give them an outfitters number on mainland and tell them I stop in once a week for gas & groceries.\n\n----------------------------------------\n\nThe Help for this program was created in Windows Help format, which depends on a feature that isn't included in this version of Windows.\n\n### RE: Y U no speak right?\n\nI got some new business cards made up a while back. It was only last week that I noticed my personal mobile\/cell phone number is on them. I put that number on my personal info page on the company intranet as an \"emergency only, personal mobile number\". If I get a call in the small hours from Korea, I'll not be impressed.\n\n- Steve\n\n### RE: Y U no speak right?\n\nI called up a sales rep (based in Chicago) once who sounded extremely groggy when I got him on his cell. Turned out he was in Korea. He was not nearly as amused as I was.\n\n----------------------------------------\n\nThe Help for this program was created in Windows Help format, which depends on a feature that isn't included in this version of Windows.\n\nYuck.\n\nI've been in Korea when I got US calls. $4.00 per minute! Best to you, Goober Dave Haven't see the forum policies? Do so now: Forum Policies ### RE: Y U no speak right? Two days into my trip to in Brisbane in December, I got a text from AT&T that my current data charges were$2000 and if I didn't contact them they would turn off my phone. I called them and they said \"we have a plan we can put you on while you're out of the country that costs $60 for some (very large) number of MB and since they bill hasn't been printed we can make it retroactive\". On that plan for$60 for a month I also got 800 text messages and 600 photo text messages included (they were $1.25 and$3.95 respectively). Most of those outrageous charges are holdovers from the days of telegraph.\n\nDavid Simpson, PE\nMuleShoe Engineering\n\n\"Belief\" is the acceptance of an hypotheses in the absence of data.\n\"Prejudice\" is having an opinion not supported by the preponderance of the data.\n\"Knowledge\" is only found through the accumulation and analysis of data.\nThe plural of anecdote is not \"data\"\n\n### RE: Y U no speak right?\n\nThanks for that, David!\n\nBest to you,\n\nGoober Dave\n\nHaven't see the forum policies? Do so now: Forum Policies\n\n### RE: Y U no speak right?\n\n(OP)\nWe've departed from the original topic, but it's a good discussion. This morning I ordered a new cell phone from Verizon, a Motorola RAZR HD. Since California charges sales tax on the full value of an item, not the sale price, the sales tax on my $99.95 phone was$51.00. ($599.00 list price) I knew this was coming, but it didn't show up until the very last confirmation page, on the very last line. They get customers excited about upgrading to the latest & greatest, then tack on the 'oh, by the way' CA sales tax at the last possible moment. I can't fault Verizon for the way sales tax is calculated in CA, but I do fault them for how it is presented. Terry KI6FCI ### RE: Y U no speak right? You have to wonder how many people get to that$51 line and say \"no thank you\". So instead of the $5 that any other state would get California gets zero. And they can't figure out why the state is broke. Cell phones are the worst for this kind of deep discount to get you to sign a contract (which then adds the discount back in over 24 months at 8%\/month--you do the math). Horrible thing about the CA tax is that they start out charging you for the undiscounted price and then they tax every line of your bill so you pay at least 200% of the official sales tax number (probably closer to 300%). David Simpson, PE MuleShoe Engineering \"Belief\" is the acceptance of an hypotheses in the absence of data. \"Prejudice\" is having an opinion not supported by the preponderance of the data. \"Knowledge\" is only found through the accumulation and analysis of data. The plural of anecdote is not \"data\" ### RE: Y U no speak right? Belgium's sales tax is 21%, and they're talking about raising it. I wouldn't complain too loud if I were you. NX 7.5.5.4 with Teamcenter 8 on win7 64 Intel Xeon @3.2GHz 8GB RAM Nvidia Quadro 2000 ### RE: Y U no speak right? Actually it's called a VAT (Value Added Tax), and while it has the appearance of being a 'Sales Tax', it's significantly different, often in subtle ways: http:\/\/www.economywatch.com\/business-and-economy\/d... John R. Baker, P.E. Product 'Evangelist' Product Engineering Software Siemens PLM Software Inc. Industry Sector Cypress, CA Siemens PLM: UG\/NX Museum: To an Engineer, the glass is twice as big as it needs to be. ### RE: Y U no speak right? I knew that was what you were talking about (called BTW in Belgium) but decided to copy the actual American person in stead of using what I learned in high school. NX 7.5.5.4 with Teamcenter 8 on win7 64 Intel Xeon @3.2GHz 8GB RAM Nvidia Quadro 2000 ### RE: Y U no speak right? DRWeig #### Quote: Anybody who hands me a written report with text-speak in it gets either terminated if already presented to a client or final-warninged if not yet sent. Are you serious? People really submit reports with text speak in them? Bill ### RE: Y U no speak right? \"Are you serious? People really submit reports with text speak in them? \" Sure, why not? People write reports with abbreviations and acronyms that in them, that are only understood by a select few. What's the difference? ### RE: Y U no speak right? In our industry it's called 'jargon', and while we try to avoid it as much as possible (it raises heck when you have to provide translated versions, in 10 different languages, of your user documentation\/help files as well as the software's menus and dialogs) it's sometimes an impossible task. John R. Baker, P.E. Product 'Evangelist' Product Engineering Software Siemens PLM Software Inc. Industry Sector Cypress, CA Siemens PLM: UG\/NX Museum: To an Engineer, the glass is twice as big as it needs to be. ### RE: Y U no speak right? I do use Three Letter Acronyms (TLA) in my reports but I always make sure that I spell it out in the first usage. Texting goes way beyond technical jargon. ---------------------------------------- The Help for this program was created in Windows Help format, which depends on a feature that isn't included in this version of Windows. ### RE: Y U no speak right? Sorry, but jargon and TLAs are not text speak. Are we talking about the same moronic use of single letters and things like 'l8r' for later? Tenpenny - do you use text speak in reports? Bill ### RE: Y U no speak right? WGJ, Yes, I've had two writers in the past few years put these in reports destined for a client: ATEOTD B4 2B IMHO I think there were more in those reports, but I don't know -- they were flung back to the authors before I read another page. The whole report wasn't in text-speak. It seems that when they're typing fast, text-happy people can lapse into that silly mode. Best to you, Goober Dave Haven't see the forum policies? Do so now: Forum Policies ### RE: Y U no speak right? Well, good for you, Dave. Crap like that doesn't do any good for client relationships, should it become public, and shouldn't be tolerated if it is a company\/corporate document that gets recorded. Bill ### RE: Y U no speak right? I have to admit I find my self doing it. I don't think I have ever sent anything company related. I edit my reports first. I am bad for using U for you or UR for you are.. ### RE: Y U no speak right? Our library is scanning reports and meeting minutes from way back (early 60's). They are all in modern day English. No txt spk anywhere. - Steve ### RE: Y U no speak right? My girlfriend is an English teacher (9th through 12th grade). They regularly submit reports with texting abbreviations AND, get this, emoticons! If her classes are representative of the aggregate, our children are in some trouble. In Russia building design you! ### RE: Y U no speak right? OMG emoticons! I don't even know that ATEOTD stands for. The world is coming to an end. ---------------------------------------- The Help for this program was created in Windows Help format, which depends on a feature that isn't included in this version of Windows. ### RE: Y U no speak right? I had to google it. At The End Of The Day - another well-worn cliche. I have returned technical papers submitted for peer review that contained unexplained acronyms and cliches asking for the papers to be rewritten. ### RE: Y U no speak right? Thanks GrahamBennett, you stopped me from another long tirade. Instead, I'll keep it concise. Bizness Buzzwords and Bizness Buzzword phrases are grounds for severe discipline IMHO. I'm going back to work now so I can continue to look at the 50,000-foot view, focus on my core strengths, and build a framework from which I can ping other engineers and share best practices. Best to you, Goober Dave Haven't see the forum policies? Do so now: Forum Policies ### RE: Y U no speak right? ### RE: Y U no speak right? (OP) Bingo! Terry KI6FCI ### RE: Y U no speak right? Keep your paradigms synergistic Dave. David Simpson, PE MuleShoe Engineering \"Belief\" is the acceptance of an hypotheses in the absence of data. \"Prejudice\" is having an opinion not supported by the preponderance of the data. \"Knowledge\" is only found through the accumulation and analysis of data. The plural of anecdote is not \"data\" ### RE: Y U no speak right? Good one, David. Best to you, Goober Dave Haven't see the forum policies? Do so now: Forum Policies ### RE: Y U no speak right? AlL cApS iS a StAtE oF mInD in fact i consider caps unnecesary for the entire english language. why the F do we need caps when there is a \".\" symbol most people with broken english speak better than I or possibly you would in theirs. engineering majors usually don't take additional languages and maybe they should. Well at least that's my 2 lowercase letters. or cents if you like numerals so much Take em or leave em. In Unix ass AsS aSS and ASS and the other two Upper\/Lowercase combos can all exist in a directory in Windows they are not case sensitive so you'd have issues. \"It's not the size of the Forum that matters, It's the Quality of the Posts\" Michael Cole Boston, MA CSWP, CSWI, CSWTS Follow me on !w\u00a1#$%\n@ TrajPar - @ mcSldWrx2008\n= ProE = SolidWorks\n\n### RE: Y U no speak right?\n\n#### Quote (mjcole)\n\nin fact i consider caps unnecesary for the entire english language. why the F do we need caps when there is a \".\" symbol\nQuite a hasty conclusion. For one, punctuation does not assist in scanning text for proper names and nouns. The proper name \"Peter the Great\" does not have the same meaning when the letters are not capitalized.\n\nIn Russia building design you!\n\n### RE: Y U no speak right?\n\nHow many people take typing in school these days? I took it back in the days of manual typewriters and typing in time to music.\n\nIf you cannot type, it takes a long time to get your ideas into a computer in a reasonable time. This is still a necessary skill.\n\n--\nJHG\n\n### RE: Y U no speak right?\n\nTouch typing, vs hunt and peck. We've done this topic to death in this place.\n\nA friend of mine, recently gone away, had a brain tumour, which made communication difficult. He was always a brilliant typist, but found that only one side was working right. So it limited his vocabulary (his joke).\n\n- Steve\n\n### RE: Y U no speak right?\n\nI can honestly say that the one class I took in high school where the skills I learned I know I will use every day of my life was typing, and back when I took it, 1965, we learned on manual typewriters and the class was virtually 100% girls (I think there was only one other guy besides me). I went to a small public high school (30 in my graduating class) in Northern Michigan and by the time I got to my senior year I had taken all the classes that the school offered and so during my last semester I took typing and a couple of correspondence course, basic electronics and drafting (pretty common in that part of the country and during that era to offer 'advanced' topics by correspondence course to seniors preparing for college).\n\nJohn R. Baker, P.E.\nProduct 'Evangelist'\nProduct Engineering Software\nSiemens PLM Software Inc.\nIndustry Sector\nCypress, CA\nSiemens PLM:\nUG\/NX Museum:\n\nTo an Engineer, the glass is twice as big as it needs to be.\n\n### RE: Y U no speak right?\n\n(OP)\nWell, now CalTrans (California Department of Transportation) is doing it. Tonight I saw an electronic sign \"Freeway subject 2 closure\". I hope everyone who reads that sign is fluent in English (not a chance in Southern California).\n\nTerry\nKI6FCI\n\n### RE: Y U no speak right?\n\n2\nThey've closed Subject 2 on the Freeway?\n\nI didn't realize that California regulated conversations as well as conservation. Wow, you even have to be careful what you talk about.\n\n### RE: Y U no speak right?\n\nOh dear TenPenny. Your post had me laughing so much my sides hurt.\n\n### RE: Y U no speak right?\n\nDitto. Coffee up nasal passages.\n\n----------------------------------------\n\nThe Help for this program was created in Windows Help format, which depends on a feature that isn't included in this version of Windows.\n\n### RE: Y U no speak right?\n\nSome subjects are too distracting to drivers. Subjects 1 and 3 are okay, but subject 2 gets people so riled they cause collisions.\n\n### RE: Y U no speak right?\n\n(OP)\nSubject 2 is now open for discussion again. Tonight the same sign read 'Freeway maybe closed'(Didn't catch the times).\n\nMaybe it's open, maybe it's not...\n\nTerry\nKI6FCI\n\n### RE: Y U no speak right?\n\nPerhaps someone was just trying to save space as those signs have a limited number of displayed characters.\n\nJohn R. Baker, P.E.\nProduct 'Evangelist'\nProduct Engineering Software\nSiemens PLM Software Inc.\nIndustry Sector\nCypress, CA\nSiemens PLM:\nUG\/NX Museum:\n\nTo an Engineer, the glass is twice as big as it needs to be.\n\n### RE: Y U no speak right?\n\nWhat was Subject 1? ---- don't mention Subject 1\n\nBill\n\n### RE: Y U no speak right?\n\n(OP)\nSubject 1 is classified.\n\nIt was a three line sign. If 'freeway' fit on the top line, 'may be' would have fit in the middle. Seems that they couldn't be bothered to read what they just typed.\n\nTerry\nKI6FCI\n\n### RE: Y U no speak right?\n\nI mentioned subject 1 once, but I think I got away with it.\n\nNX 7.5.5.4 with Teamcenter 8 on win7 64\nIntel Xeon @3.2GHz\n8GB RAM\n\n### RE: Y U no speak right?\n\nTerry - keep an eye open for the boys in the black suits and dark glasses......they know where you post.\n\nBill\n\n#### Red Flag This Post\n\nPlease let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.\n\n#### Red Flag Submitted\n\nThank you for helping keep Eng-Tips Forums free from inappropriate posts.\nThe Eng-Tips staff will check this out and take appropriate action.\n\n#### Resources\n\nLow-Volume Rapid Injection Molding With 3D Printed Molds\nLearn methods and guidelines for using stereolithography (SLA) 3D printed molds in the injection molding process to lower costs and lead time. Discover how this hybrid manufacturing process enables on-demand mold fabrication to quickly produce small batches of thermoplastic parts. Download Now\nExamine how the principles of DfAM upend many of the long-standing rules around manufacturability - allowing engineers and designers to place a part\u00e2\u20ac\u2122s function at the center of their design considerations. Download Now\nTaking Control of Engineering Documents\nThis ebook covers tips for creating and managing workflows, security best practices and protection of intellectual property, Cloud vs. on-premise software solutions, CAD file management, compliance, and more. Download Now\n\nClose Box\n\n# Join Eng-Tips\u00ae Today!\n\nJoin your peers on the Internet's largest technical engineering professional community.\nIt's easy to join and it's free.\n\nHere's Why Members Love Eng-Tips Forums:\n\n\u2022 Talk To Other Members\n\u2022 Notification Of Responses To Questions\n\u2022 Favorite Forums One Click Access\n\u2022 Keyword Search Of All Posts, And More...\n\nRegister now while it's still free!","date":"2023-01-26 22:48:34","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.19504500925540924, \"perplexity\": 5193.842263985899}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2023-06\/segments\/1674764494826.88\/warc\/CC-MAIN-20230126210844-20230127000844-00840.warc.gz\"}"}
null
null
GM Report Center Stage+ Player(s) Breon Borders, Josh Reynolds, Nate Brooks Breon Borders One of Two DBs Released A starter in five games last season, the well-traveled veteran remained a backup despite numerous lineup changes this season. David Boclair NASHVILLE – When the Tennessee Titans needed help at cornerback in 2020, they turned to Breon Borders for a time. When they needed help at the same position ths season, they turned to pretty much everyone else. Tuesday, they turned him loose. The Titans released Borders along with free-agent wide receiver Josh Reynolds. They also released defensive back Nate Brooks from their practice squad. At present, the 53-man roster includes just four cornerbacks, Jackrabbit Jenkins, Chris Jackson, Greg Mabin and Elijah Molden. A fifth, Kristian Fulton, has spent the last four weeks on injured reserve, which means he is eligible to return at any time. Borders played in each of the nine games thus far in 2021 but remained a little-used reserve even as injury issues piled up at that position. When Fulton and Caleb Farley went on injured reserve in consecutive weeks, Mabin was signed off the Arizona practice squad and immediately installed as a starter. When Mabin sat out Sunday's game at Los Angeles with an injury, Jackson got the call to start. All told, Borders has been on the field with the defense for 52 snaps. He registered four tackles with two passes defensed. Julio a Proven Playoff Playmaker Thursday Injury Report: No Players Ruled Out Adjusted Ticket Policy Aims to Limit Bengals Fans The 26-year-old started five games for the Titans from early November until early December last season and appeared in one other before he ended up on injured reserve. In that limited stint, he made 27 tackles, one tackle for loss and was credited with five passes defensed and drew praise from the coaches for his effort. "I love (Borders') competitiveness," coach Mike Vrabel said during training camp. "I love his attitude, his willingness to learn and work and compete. … He does it like we coach it and certainly enjoy having him in here every day and learning. He is one of those guys that comes into the building ready to go, and he has a level of toughness to him and a competitive spirit that we like." Undrafted out of Duke in 2017, this is the ninth time in his career, the second by the Titans. He also has been cut by the Raiders (2017), Buffalo (2018), Houston (2018), Jacksonville (2019), Washington (2020), Pittsburgh (2020) and Miami (2020). Of his 27 career games played, 15 have been with Tennessee, as have five of his six starts. "He fits our culture in that regard with what we are looking for from our players," defensive coordinator Shane Bowen said during the preseason. "Day in and day out we know what we are going to get, there aren't going to be any surprises. There might be times he gets beat, I get it, everybody gets beat. But at the same time, he is going to try and do what he is coached to do, and he is going to play hard." Chances are, he is going to have to try to fit in somewhere else. Stay up to date with breaking news, statistical analysis and commentary on the Tennessee Titans. By John Glennon By David Boclair Henry's Workload: How Much is Too Much? Titans Revel in Rarity of Postseason Streak Wednesday Injury Report: Two Added, Sit Out Practice Cornerback Goes on COVID List This Receiver Took a Different Route
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
8,536
/*~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ______ ______ ______ __ __ __ ______ /\ == \ /\ __ \ /\__ _\ /\ \/ / /\ \ /\__ _\ \ \ __< \ \ \/\ \ \/_/\ \/ \ \ _"-. \ \ \ \/_/\ \/ \ \_____\ \ \_____\ \ \_\ \ \_\ \_\ \ \_\ \ \_\ \/_____/ \/_____/ \/_/ \/_/\/_/ \/_/ \/_/ This is a sample Microsoft Bot Framework bot built with Botkit. This bot demonstrates many of the core features of Botkit: * Connect to the Microsoft Bot Framework Service * Receive messages based on "spoken" patterns * Reply to messages * Use the conversation system to ask questions * Use the built in storage system to store and retrieve information for a user. # RUN THE BOT: Follow the instructions in the "Getting Started" section of the readme-botframework.md file to register your bot. Run your bot from the command line: app_id=<MY APP ID> app_password=<MY APP PASSWORD> node botframework_bot.js [--lt [--ltsubdomain LOCALTUNNEL_SUBDOMAIN]] Use the --lt option to make your bot available on the web through localtunnel.me. # USE THE BOT: Find your bot inside Skype to send it a direct message. Say: "Hello" The bot will reply "Hello!" Say: "who are you?" The bot will tell you its name, where it running, and for how long. Say: "Call me <nickname>" Tell the bot your nickname. Now you are friends. Say: "who am I?" The bot will tell you your nickname, if it knows one for you. Say: "shutdown" The bot will ask if you are sure, and then shut itself down. Make sure to invite your bot into other channels using /invite @<my bot>! # EXTEND THE BOT: Botkit has many features for building cool and useful bots! Read all about it here: -> http://howdy.ai/botkit ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/ var Botkit = require('../lib/Botkit.js'); var os = require('os'); var commandLineArgs = require('command-line-args'); var localtunnel = require('localtunnel'); const ops = commandLineArgs([ {name: 'lt', alias: 'l', args: 1, description: 'Use localtunnel.me to make your bot available on the web.', type: Boolean, defaultValue: false}, {name: 'ltsubdomain', alias: 's', args: 1, description: 'Custom subdomain for the localtunnel.me URL. This option can only be used together with --lt.', type: String, defaultValue: null}, ]); if(ops.lt === false && ops.ltsubdomain !== null) { console.log("error: --ltsubdomain can only be used together with --lt."); process.exit(); } var controller = Botkit.botframeworkbot({ debug: true }); var bot = controller.spawn({ appId: process.env.app_id, appPassword: process.env.app_password }); controller.setupWebserver(process.env.port || 3000, function(err, webserver) { controller.createWebhookEndpoints(webserver, bot, function() { console.log('ONLINE!'); if(ops.lt) { var tunnel = localtunnel(process.env.port || 3000, {subdomain: ops.ltsubdomain}, function(err, tunnel) { if (err) { console.log(err); process.exit(); } console.log("Your bot is available on the web at the following URL: " + tunnel.url + '/botframework/receive'); }); tunnel.on('close', function() { console.log("Your bot is no longer available on the web at the localtunnnel.me URL."); process.exit(); }); } }); }); controller.hears(['hello', 'hi'], 'message_received', function(bot, message) { controller.storage.users.get(message.user, function(err, user) { if (user && user.name) { bot.reply(message, 'Hello ' + user.name + '!!'); } else { bot.reply(message, 'Hello.', function(err) { console.error(err); }); } }); }); controller.hears(['call me (.*)'], 'message_received', function(bot, message) { var matches = message.text.match(/call me (.*)/i); var name = matches[1]; controller.storage.users.get(message.user, function(err, user) { if (!user) { user = { id: message.user, }; } user.name = name; controller.storage.users.save(user, function(err, id) { bot.reply(message, 'Got it. I will call you ' + user.name + ' from now on.'); }); }); }); controller.hears(['what is my name', 'who am i'], 'message_received', function(bot, message) { controller.storage.users.get(message.user, function(err, user) { if (user && user.name) { bot.reply(message,'Your name is ' + user.name); } else { bot.reply(message,'I don\'t know yet!'); } }); }); controller.hears(['shutdown'],'message_received',function(bot, message) { bot.startConversation(message,function(err, convo) { convo.ask('Are you sure you want me to shutdown?',[ { pattern: bot.utterances.yes, callback: function(response, convo) { convo.say('Bye!'); convo.next(); setTimeout(function() { process.exit(); },3000); } }, { pattern: bot.utterances.no, default: true, callback: function(response, convo) { convo.say('*Phew!*'); convo.next(); } } ]); }); }); controller.hears(['uptime','identify yourself','who are you','what is your name'],'message_received',function(bot, message) { var hostname = os.hostname(); var uptime = formatUptime(process.uptime()); bot.reply(message,'I am a bot! I have been running for ' + uptime + ' on ' + hostname + '.'); }); function formatUptime(uptime) { var unit = 'second'; if (uptime > 60) { uptime = uptime / 60; unit = 'minute'; } if (uptime > 60) { uptime = uptime / 60; unit = 'hour'; } if (uptime != 1) { unit = unit + 's'; } uptime = uptime + ' ' + unit; return uptime; }
{ "redpajama_set_name": "RedPajamaGithub" }
3,094
{"url":"https:\/\/solvedlib.com\/under-what-conditions-will-the-flow-through-a,151614","text":"# Under what conditions will the flow through a cvergent-divergent nozzle become choked? What happens to the...\n\n###### Question:\n\nUnder what conditions will the flow through a cvergent-divergent nozzle become choked? What happens to the mass flow rate when exit pressure is decreased on a choked nozzle?\n\n#### Similar Solved Questions\n\n##### Location A is 2.50 m to the right of a pointcharge q. Location B lies on thesame line and is 3.50 m to the right of the charge. The potentialdifference VB - VA =43.0 V. What is the magnitude and sign of the charge?\nLocation A is 2.50 m to the right of a point charge q. Location B lies on the same line and is 3.50 m to the right of the charge. The potential difference VB - VA = 43.0 V. What is the magnitude and sign of the charge?...\n##### Evaluate the double integral : JR (1+x2+y2)2 dA where R is given by : 1 <x2+y2 < 6\nEvaluate the double integral : JR (1+x2+y2)2 dA where R is given by : 1 <x2+y2 < 6...\n##### Danic] takes his two doge Pauli thc Foinler and Newton thc Ncwloundland. Out to lield and lets them loose excrcisc: Both dogs sprint . 4wuy dillerent dircctions while Danicl stands still Ftom Daniel's point of view, Newton runs due north al 3,40 mls; but from Pauli s point Vicw Newlon appears to be moving a \/,30 m\/s due eusl_ Whal Pauli's velocity relative lo Danicl; Tw?Givc your ansWcr unit vcclor nMalion. where north taken to be the positive y direclion and est is the positive x - d\nDanic] takes his two doge Pauli thc Foinler and Newton thc Ncwloundland. Out to lield and lets them loose excrcisc: Both dogs sprint . 4wuy dillerent dircctions while Danicl stands still Ftom Daniel's point of view, Newton runs due north al 3,40 mls; but from Pauli s point Vicw Newlon appears ...\n##### The accompanying figure shows a portion of the graph of a twice-differentiable function $y=f(x) .$ At each of the five labeled points, classify $y^{\\prime}$ and $y^{\\prime \\prime}$ as positive, negative, or zero. (Check your book to see figure)\nThe accompanying figure shows a portion of the graph of a twice-differentiable function $y=f(x) .$ At each of the five labeled points, classify $y^{\\prime}$ and $y^{\\prime \\prime}$ as positive, negative, or zero. (Check your book to see figure)...\n##### The figure below shows schematic cross-section through developing baroclinic distur- bance_ The centers of high and low pressure at the ground are denoted by H and L; while the wavy solid line suggests the gcometry of the 500 hPa pressure surface At the instant shown in the figure the geopoteutial associated with the disturbance is d(r,: Y,P) = Do(p) - Ufo y cos IL 3f sin kz +T Do 3 po po where po 1000 hPa and where fo and U are both positive constants_ The function Do(p) is the background geo\nThe figure below shows schematic cross-section through developing baroclinic distur- bance_ The centers of high and low pressure at the ground are denoted by H and L; while the wavy solid line suggests the gcometry of the 500 hPa pressure surface At the instant shown in the figure the geopoteutial ...\n##### Fovide 4 mechanism for the reaction shown brlnHzsoa heal\nFovide 4 mechanism for the reaction shown brln Hzsoa heal...\n##### The 2420 - $\\mu$ F capacitor in Fig. 28.25 is initially charged to $250 \\mathrm{V}$ (a) Describe how you would manipulate switches $A$ and $B$ to transfer all the energy from the 2420 - $\\mu$ F capacitor to the $605-\\mu \\mathrm{F}$ capacitor. Include the times you would throw the switches. (b) What will be the voltage across the 605 -\\muF capacitor once you've finished? FIGURE CANT COPY\nThe 2420 - $\\mu$ F capacitor in Fig. 28.25 is initially charged to $250 \\mathrm{V}$ (a) Describe how you would manipulate switches $A$ and $B$ to transfer all the energy from the 2420 - $\\mu$ F capacitor to the $605-\\mu \\mathrm{F}$ capacitor. Include the times you would throw the switches. (b) Wha...\n##### A sphere of radius R has total charge Q. The volume charge density (C\/m^{3}) within the...\nA sphere of radius R has total charge Q. The volume charge density (C\/m^{3}) within the sphere is\u00a0\u00a0\u00a0\u00a0\u00a0 $$\\rho=\\rho_{0}(1-(r^{2}\/R^{2}))$$ \u00a0\u00a0\u00a0\u00a0 This charge desity decreases quadratically from\u00a0\u00a0\u00a0\u00a0\u00a0 $$\\rho_{0}$$ \u00a0\u00a0\u00a0&nb...\n##### Moving to another question will save this response. Question 34 Another name for antidiuretic hormone is...\nMoving to another question will save this response. Question 34 Another name for antidiuretic hormone is A. intermedin B. oxytocin vasopressin aldosterone...\n##### Question 8 (1 point) A25.00 mL solution of an unknown base is titrated with 0.100 M HCL The initial pH is 11.,72 The midpoint of the titration occurs at pH equal t0 10,63. of0.10 M HCI The equivalence point 0f the titration occurs after 16,25 mL have been added The pH at this point is equal to 6,02 data thal You are provided which of the following statements are true? Based on the0The unknown base Is weak base-The uriknown buse Is strone basc\nQuestion 8 (1 point) A25.00 mL solution of an unknown base is titrated with 0.100 M HCL The initial pH is 11.,72 The midpoint of the titration occurs at pH equal t0 10,63. of0.10 M HCI The equivalence point 0f the titration occurs after 16,25 mL have been added The pH at this point is equal to 6,02...\n##### Ttion I4 4 Whal Does k Teil Us Part 2 0adempl; lelCheck my workCaaraanswer all parts.The equilibrium constant K for the reactionHzg) + COzg) = H,Olg) coG) 142at 16509C . Initially 0,86 conceutratiou Iol Hz and 0.86 mol cOr: each species at are injected into & 5,3 equilibriun Lflask Calculate Equilibrhtm concentration of Hz:Eqquilibriur coukentration of cOz:Eqqihbcitan concentration ~of Hzo:Eratnbria cencentratlon of CO:\nttion I4 4 Whal Does k Teil Us Part 2 0 adempl; lel Check my work Caara answer all parts. The equilibrium constant K for the reaction Hzg) + COzg) = H,Olg) coG) 142at 16509C . Initially 0,86 conceutratiou Iol Hz and 0.86 mol cOr: each species at are injected into & 5,3 equilibriun Lflask Calcula...\n##### A 30 mL sample which appeared to be a clear, colorless liquid was distilled by simple...\nA 30 mL sample which appeared to be a clear, colorless liquid was distilled by simple distillation (using a heating mantle and variac as the heat source). When the first drop of liquid was observed the temperature was 77\u00b0C and the temperature remained in the range of 77\u00b0C to 80\u00b0C while t...\n##### Sihoit that definition the of the derivative derivative f(z) MOHS WORK 2(z +2)2 using 8\nSihoit that definition the of the derivative derivative f(z) MOHS WORK 2 (z +2)2 using 8...\n##### Find an equation for the graph sketched belowf(z)\nFind an equation for the graph sketched below f(z)...\n##### Dix Solve the differential equation 2mdx+ Mx = 0, dt-where x(0) = 0,dx0 = ~M_(20 marks\ndix Solve the differential equation 2mdx+ Mx = 0, dt- where x(0) = 0,dx0 = ~M_ (20 marks...\n##### Find the inverse Laplace transform of each ofthe following functionsa. F(8) = 84 ( 82 + 9)f(t) = L I{F(s)}(t) =dw48b. G(8) (s _ 2)2(82 + 36)g(t) = L '{F(8)}(t) =dw\nFind the inverse Laplace transform of each ofthe following functions a. F(8) = 84 ( 82 + 9) f(t) = L I{F(s)}(t) = dw 48 b. G(8) (s _ 2)2(82 + 36) g(t) = L '{F(8)}(t) = dw...\n##### 0\/3 points Previous AnswersSCalccc4 A.1.031.3.Find polar forms for ZW, z\/w, and 1\/z by first putting 2 and w into polar form 2v3 2i .W =-l+1191 lx9t FW = 4v 2 COS + isin 12 126| ~ 1\n0\/3 points Previous Answers SCalccc4 A.1.031. 3. Find polar forms for ZW, z\/w, and 1\/z by first putting 2 and w into polar form 2v3 2i .W =-l+1 191 lx9t FW = 4v 2 COS + isin 12 12 6| ~ 1...\n##### Faralld Jd Suics Circuits PISW ChS DFMONSTRATION O QHIMS LAW TRFFHGTHW MSU he calculated; Other quantities ure measured in class demonstration:) prIm( \"pntItIe MUS( (Hod Wineadlescent bulbs are wired in parallel. Tnve 57 orr) =l \"Cold\" resistmnee fa 57W bulb:Input voltage: Total circuit current: Voltage across each bulb: 1X6.-0Ms Current through each bulb:_ On-resistance of each bulb (Ohm's Law): 142 Total circuit resistance (RTow):hm L 262Three 57 W incandescent bulbs are wi\nFaralld Jd Suics Circuits PISW ChS DFMONSTRATION O QHIMS LAW TRFFHGTHW MSU he calculated; Other quantities ure measured in class demonstration:) prIm( \"pntItIe MUS( (Hod Wineadlescent bulbs are wired in parallel. Tnve 57 orr) =l \"Cold\" resistmnee fa 57W bulb: Input voltage: Total circ...\n##### Suppose logz ( (9) and logz (8) = b. Use the change-of-base formula along with properties of logarithms to rewtite each expression in terms of andlogs(7)Previewsyntax erfor\nSuppose logz ( (9) and logz (8) = b. Use the change-of-base formula along with properties of logarithms to rewtite each expression in terms of and logs(7) Preview syntax erfor...\n##### Holdup Bank has an issue of preferred stock with a $5.65 stated dividend that just sold... Holdup Bank has an issue of preferred stock with a$5.65 stated dividend that just sold for $93 per share. What is the bank's cost of preferred stock? (Do not round intermediate calculations and enter your answer as a percent rounded to 2 decimal places, e.g., 32.16.) Cost of preferred stock %... 1 answer ##### Ayayai Corp. has these accounts at December 31: Common Stock,$10 par, 4,500 shares issued, $45,000;... Ayayai Corp. has these accounts at December 31: Common Stock,$10 par, 4,500 shares issued, $45,000; Paid-in Capital in Excess of Par Value$18,000; Retained Earnings $43,000; and Treasury Stock, 400 shares,$8,800. Prepare the stockholders\u2019 equity section of the balance sheet. Ayayai Corp. ...\nYour answer is partially correct. The following information is available for Marigold Bowling Alley at December 31, 2022. $129,000 14,460 4,800$100,000 5,290 42,480 18,240 13,200 Buildings Accounts Receivable Prepaid Insurance Cash Equipment Land Insurance Expense Depreciation Expense Interest Expe...","date":"2022-10-05 10:09:21","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 1, \"mathjax_asciimath\": 1, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.5943611264228821, \"perplexity\": 8132.02119793834}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2022-40\/segments\/1664030337595.1\/warc\/CC-MAIN-20221005073953-20221005103953-00628.warc.gz\"}"}
null
null
MLB Analayst Gregg Zaun Fired From Sportsnet Due To Sexual Misconduct - uSports.org MLB Analayst Gregg Zaun Fired From Sportsnet Due To Sexual Misconduct Toronto Blue Jays catcher Greg Zaun against the Tampa Bay Devil Rays April 6, 2007 in St. Petersburg. The Rays beat the Jays 6 - 5. (Photo by A. Messerschmidt/Getty Images) by Pablo MenaDecember 1, 2017, 5:51 pmDecember 1, 2017, 5:51 pmDecember 1, 2017, 5:51 pmDaily Digest, News, Z-Home Slider > Major League Baseball analyst Gregg Zaun has been fired from Sportsnet due to "inappropriate behaviour and comments" toward female employees. Blue Jays analyst Gregg Zaun sexual harassment news Rogers Media President Rick Brace said in a statement Thursday that the company would terminate the contract of the 46-year-old Toronto Blue Jays analyst effective immediately. "This week, we received complaints from multiple female employees at Sportsnet regarding inappropriate behaviour by Gregg Zaun in the workplace," the statement said. "After investigating the matter, we decided to terminate his contract, effective immediately. This type of behaviour completely contradicts our standards and our core values. We believe in a professional workplace where all employees feel comfortable and respected. We are grateful to our employees who spoke with us and we will take every measure to protect their privacy." Zaun, a former Blue Jays catcher, started a part-time broadcasting career with Sportsnet following the 2006 season. He originally inked a two-year contract as an MLB studio analyst with Sportsnet in 2011 and continued working with the network until his firing. He played 16 MLB seasons, including five years in Toronto from 2004-2008. He won a World Series with the Florida Marlins in 1997. Zaun's termination comes in the wake of a string of dismissals of other prominent journalists or Hollywood celebrities for sexual harassment or assault. Allegations of misconduct have also surfaced in the political arena. Among the most recently accused famous men are Alabama Senate candidate Roy Moore, CBS and PBS anchor Charlie Rose and Today Show co-host Matt Lauer. Zaun, who called himself "the Manalyst," was mocked on Twitter in 2012 after he tweeted an offensive comment about women in a Toronto nightclub. This April, Zaun lambasted Blue Jays pitcher Marcus Stroman for being overly animated on the mound during a series against the Los Angeles Angels. The right-hander said on Twitter: "Outside opinions are irrelevant. Especially when they come from sources with zero credibility" when a fan tweeted at Stroman about Zaun's comments. Zaun was also alleged in 2007 to have taken performance-enhancing drugs, although he later denied those claims. Zaun was scheduled to speak a fundraiser for the University of the Fraser Valley baseball program in Abbotsford, B.C., in February, but organizers released a statement Thursday saying they were pulling him from the event. "In light of the allegations of inappropriate behavior in the workplace against Zaun which led to his termination by Sportsnet today, UFV Baseball is seeking a new speaker for the event, which will proceed as scheduled," the statement said. Toronto Blue Jays catcher Greg Zaun against the Tampa Bay Devil Rays April 6, 2007 in St. Petersburg. The Rays beat the Jays 6 – 5. (Photo by A. Messerschmidt/Getty Images) Blue Jays analyst fired Gregg Zaun MLB sexual misconduct Click here for the Best Sports Instagram Photos Slideshow Padres Sign Nelson Cruz To One-Year, $1 Million Deal Red Sox Finally Retain Franchise Player With Rafael Devers Deal The Dodgers Can't Save Noah Syndergaard
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
5,856
Q: \section, subsection title between table I use \section, \subsection on my doc. I insert \section (and \subsection) before this command \begin{table}[] \centering \begin{tabular}{@{}llr@{}} \toprule that create a table. I have the same block for 3 table. What I obtain are: two table, then the name of section and sub section and, at last, the third table. Why do the name of section and subsection are in the middle of the tabs?
{ "redpajama_set_name": "RedPajamaStackExchange" }
970
A missing five year-old boy has been found dead inside a parked car in a compound at Ishiuzor, Egbu Community, in Owerri North council area of Imo State. According to TheNation, the boy was found dead at a compound in the neighbourhood where he was sent to buy sachet water. "He was sent to buy pure water at a particular compound in the neighbourhood. The boy never came back. A search party was launched for the boy and he was never found till after five days. His corpse was eventually found on the fifth day at the same compound where he was sent to buy pure water," a source told TheNation. The parents of the boy alleges that the woman who sells provision at the compound has answers to the death of their son. However, the police spokesperson, Orlando Ikeokwu, confirmed the death of the child. Ikeokwu, also disclosed that the couple who sells provisions at the compound where the boy was found dead had been arrested and the matter transferred to the state police command in Owerri, the state capital. Bibiyobra: Monday, 11 January 2021 at 1/11/2021 09:07:00 am Beautiful Corper Arrested For Killing A Man In Akwa Ibom (Graphic Photos)
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
9,374
{"url":"https:\/\/mathematica.stackexchange.com\/questions\/233736\/how-to-define-function-in-mathematica","text":"# How to define function in Mathematica\n\nI have a 3 by 3 symbolic matrix M(x,y,z).\n\nQuestion:1\n\nFirst, I want to find its eigenvalues and eigenvectors. After that I want to make each eigenvalue and eigenvector a function of x,y, and z i.e.\n\n(*long expression to calcualte M[kx_,ky_,kz_]*)\n{vals, vecs} = Eigensystem[M[x, y, z]];\n(*I want to get expression like\ne1[x_,y_,z_]:=first_eigenvalue;\nv1[x_,y_,z_]:=first_eigenvector; same for remaining*)\n\n\nI tried e1[x_,y_,z_]:=vals[[1]], it does not work.\n\nQuestion:2\n\nat some point, I want to take ConjugateTranspose[] of v1 (or v2, v3). Assuming that like MATLAB, Mathematica also give eigenvector in the column, I defined v1 as vecs2 = Transpose[vecs]; v1=[[1]]; Now, when I try ConjugateTranpose[v1]; it gives an erorr that The first two levels ... can't be transposed\n\n\u2022 e1 = Function[{x, y, z}, Evaluate[vals]]; v1 = Function[{x, y, z}, Evaluate[vecs]]; You can then use them like functions for example e1[a,b,c] or v1[1,2,3] will substitute the x,y,z values for the arguments. Oct 29, 2020 at 20:22\n\u2022 e1[x_, y_, z_] = vals[[1]] and v1[x_,y_,z_] = vecs[[1]] works. I suggest you learn about immediate and delayed assignments and how they differ. Oct 29, 2020 at 21:14","date":"2022-08-14 08:44:34","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 0, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 1, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.3335074186325073, \"perplexity\": 2665.951751477309}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2022-33\/segments\/1659882572021.17\/warc\/CC-MAIN-20220814083156-20220814113156-00666.warc.gz\"}"}
null
null
var API_ENDPOINT = window.serverData.apiEndpoint; var MAX_RESULTS = window.serverData.maxResults; var WebhookInboxViewer = angular.module('WebhookInboxViewer', []); WebhookInboxViewer.factory("Pollymer", function($q, $rootScope) { var count = 0; return { create: function() { // -1 maxTries indicates infinite calls. var req = new Pollymer.Request({maxTries: -1, errorCodes:'500,502-599'}); var id = ++count; console.log("Pollymer " + id + " created"); return { post: function(url) { return this.start('POST', url); }, get: function(url) { return this.start('GET', url); }, start: function(method, url) { console.log("Pollymer " + id + "> start (" + method + ")"); var d = $q.defer(); req.on('error', function(reason) { console.log("Pollymer " + id + "< error"); d.reject({code: -1, result: reason}); $rootScope.$apply(); }); req.on('finished', function(code, result, headers) { console.log("Pollymer " + id + "< finished (" + code + ")"); if (code >= 200 && code < 300) { d.resolve({code: code, result: result, headers: headers}); } else { d.reject({code: code, result: result, headers: headers}); } $rootScope.$apply(); }); req.start(method, url); d.promise.always(function() { req.off('error'); req.off('finished'); }); return d.promise; }, abort: function() { console.log("Pollymer " + id + "< abort"); req.abort(); } }; } } }); WebhookInboxViewer.controller("HomeCtrl", function ($scope, $window, Pollymer) { $scope.webhookId = ""; var openInbox = function(id) { $window.location.href = "/view/" + id + "/"; }; $scope.create = function() { $scope.creating = true; var url = API_ENDPOINT + "/create/"; var pollymer = Pollymer.create(); var poll = pollymer.post(url); poll.then(function(result) { $scope.creating = false; var result = result.result; openInbox(result.id); }, function(reason) { $scope.error = true; }); }; }); WebhookInboxViewer.controller("WebhookInboxCtrl", function ($scope, $window, $route, Pollymer) { $scope.inbox = { updatesCursor: null, historyCursor: null, newestId: null, entries: [], pendingEntries: [], liveUpdates: true, fetching: false, pollingUpdates: false, error: false }; $scope.webhookEndpoint = ""; var webhookId = $window.serverData.webhookId; $scope.animationMode = "static"; $scope.getAnimationType = function() { return "animate-" + $scope.animationMode; }; var itemToViewModel = function(item) { item.dateTime = Date.parse(item.created); return item; }; var handlePastFetch = function(url) { $scope.inbox.fetching = true; var pollymer = Pollymer.create(); var poll = pollymer.get(url); poll.always(function() { $scope.inbox.fetching = false; }); poll.then(function(result) { var items = result.result.items; if ("last_cursor" in result.result) { $scope.inbox.historyCursor = result.result.last_cursor; } else { $scope.inbox.historyCursor = -1; } for(var i = 0; i < items.length; i++) { var entry = itemToViewModel(items[i]); $scope.animationMode = "static"; $scope.inbox.entries.push(entry); } }, function() { $scope.inbox.error = true; }); return poll; }; $scope.toggleAuto = function() { if (!$scope.inbox.liveUpdates) { $scope.flushPendingEntriesNonLive(); } $scope.inbox.liveUpdates = !$scope.inbox.liveUpdates; } $scope.flushPendingEntriesLive = function() { $scope.animationMode = "live"; var entry = $scope.inbox.pendingEntries.pop(); $scope.inbox.entries.unshift(entry); $scope.$apply(); }; $scope.flushPendingEntriesNonLive = function() { $scope.animationMode = "nonlive"; $scope.inbox.entries = $scope.inbox.pendingEntries.concat($scope.inbox.entries); $scope.inbox.pendingEntries = []; }; var longPollymer = null; var longPoll = function(id) { var url = API_ENDPOINT + "/i/" + webhookId + "/items/?order=created"; if (id) { url += "&since=id:" + id; } else if ($scope.inbox.updatesCursor) { url += "&since=cursor:" + $scope.inbox.updatesCursor; } $scope.inbox.pollingUpdates = true; longPollymer = longPollymer || Pollymer.create(); var poll = longPollymer.get(url); poll.always(function() { $scope.inbox.pollingUpdates = false; }); poll.then(function(result) { if (result.result === "") { return; } $scope.inbox.updatesCursor = result.result.last_cursor; var items = result.result.items; for(var i = 0; i < items.length; i++) { var entry = itemToViewModel(items[i]); $scope.inbox.pendingEntries.unshift(entry); } }); poll.then(function() { longPoll(); }) }; var stopLongPoll = function() { if (longPollymer != null) { longPollymer.abort(); longPollymer = null; } }; var initial = function() { var url = API_ENDPOINT + "/i/" + webhookId + "/items/?order=-created&max=" + MAX_RESULTS; // initial load var poll = handlePastFetch(url); poll.then(function(result) { var prefix = ""; if (API_ENDPOINT.substring(0, 2) == "//") { prefix = "http:"; } $scope.webhookEndpoint = prefix + API_ENDPOINT + "/i/" + webhookId + "/"; var id = ("result" in result && "items" in result.result && result.result.items.length) ? result.result.items[0].id : null; longPoll(id); }); }; $scope.webhookInboxUrl = function() { if ($scope.webhookEndpoint.length == 0) { return ""; } return $scope.webhookEndpoint + "in/"; }; $scope.history = function() { var url = API_ENDPOINT + "/i/" + webhookId + "/items/?order=-created&max=" + MAX_RESULTS + "&since=cursor:" + $scope.inbox.historyCursor; // History get handlePastFetch(url); }; $scope.copy = function() { var endPoint = $scope.webhookEndpoint; // No way to do this using pure javascript. }; // Set up the table update worker that flushes pending entries // when live updates are on. var tableUpdateWorker = function() { if ($scope.inbox.liveUpdates && $scope.inbox.pendingEntries.length > 0) { $scope.flushPendingEntriesLive(); } $window.setTimeout(function() {tableUpdateWorker();}, 120); }; tableUpdateWorker(); // Perform initial load initial(); });
{ "redpajama_set_name": "RedPajamaGithub" }
9,568
Q: Is my PDO query safe from SQL injection I'm fairly new to PDO and wondering if my query below is safe from SQL injection. I'll be using this method throughout the site if so. // make connection to DB $db = new PDO('mysql:host='.$dateBaseHost.';dbname='.$dateBaseName, $dateBaseUsername, $dateBasePassword); $db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); //simple query and binding with results $query = $db->prepare(" SELECT * FROM `profile` WHERE `fullname` = :fullname "); $search = (isset($_GET['search']) === true) ? $_GET['search'] : '' ; // ? : shorthand for if else // bind parameters - avoids SQL injection $query->bindValue(':fullname', $search); //try... if not catch exception try { // run the query $query->execute(); $rows = $query->fetchAll(PDO::FETCH_ASSOC); echo '<pre>', print_r($rows, true),'</pre>'; } catch (PDOException $e){ sendErrorMail($e->getMessage(), $e->getFile(), $e->getLine()); } A: Yes - parameterized queries are safe from injection when used in this way. A: As long as you use prepared statements properly, you're safe from injection. but as soon as you DIRECTLY insert any external data into a query, even if it's otherwise a prepared statement, e.g. INSERT INTO $table VALUES (:param) you're vulnerable - $table can be subverted in this case, even though you're using a prepared statement. Anyone who tells you simply switching mysql->PDO or mysqli will make you safer is a flat out WRONG. You can be just as vulnerable to injection attacks with either library. A: You should also $db->setAttribute(PDO::ATTR_EMULATE_PREPARES, false); By default it uses emulated mode, which merely does what mysql_real_escape_string does. In some edge cases, you're still vulnerable to SQL injection. A: yes, it's fairly safe but whole script could be improved: if (isset($_GET['search']) { // make connection to DB $opt = array( PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION, PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC ); $dsn = "mysql:host=$dateBaseHost;dbname=$dateBaseName;charset=$dateBaseCharset"; $db = new PDO($dsn, $dateBaseUsername, $dateBasePassword, $opt); //simple query and binding with results $query = $db->prepare("SELECT * FROM profile WHERE fullname = ?"); $query->execute(array($_GET['search'])); $rows = $query->fetchAll(); echo '<pre>', print_r($rows, true),'</pre>'; } * *you need to set errmode as a connection option *never use try..catch to handle error message. if you want to have a email on every error (which is just crazy), you have to set up my_exception handler() for this. *setting search to empty string doesn't make any sense *connect to PDO should be moved so separate file (not shown) *charset have to be set in DSN
{ "redpajama_set_name": "RedPajamaStackExchange" }
5,130
\section{Introduction} Complex problems can be solved in real-world applications by carefully designing Deep Reinforcement Learning (DRL) models by taking high dimensional input data and producing discrete or continuous outputs. It is challenging to build a agent using sensory data capable of controlling and acting in an environment. The environment is also complex and primarily unknown to the acting agent. The agent needs to learn the underlying distribution of the state and action spaces, and the distribution changes as the agent encounters new data from an environment. Previously reinforcement learning algorithms \cite{q_learning92, td-gammon, pg_sutton_99, nat_ac, dpg} were presented with lower constraint problems to demonstrate the algorithms effectiveness. However, these systems were not well generalized for high dimensional inputs; thus, they could not meet the requirements of practical applications. Recently, DRL has had success in CNN based vision-based problems \cite{atari, human-lavel, double_q}. They have successfully implemented DRL methods that learn to control based on image pixel. Although the image-based DRL methods have enjoyed considerable success, they are memory intensive during training as well as deployment. Since they require a massive amount of memory, they are not suitable for implementation in mobile devices or mid-range autonomous robots for training and deployment. All modern reinforcement learning algorithms use replay buffer for sampling uncorrelated data for online training in mainly off-policy algorithms. Experience replay buffer also improves the data efficiency \cite{replay_99} during data sampling. Since the use of neural networks in various DRL algorithms is increasing, it is necessary to stabilize the neural network with uncorrelated data. That is why the experience replay buffer is a desirable property of various reinforcement learning algorithms. The first successful implementation of DRL in high dimensional observation space, the Deep Q-learning \cite{atari}, used a replay buffer of $10^6$ size. After that, \cite{double_q, ddpg, maddpg, soft_ac}, to name a few, have solved complex high dimensional problems but still use a replay buffer of the same size. Experience replay buffer suffers from two types of issues. One is to choose the size of the replay buffer, and the second is the method of sampling data from the buffer. \cite{priotized_replay, hindsight_replay, deeper_replay} consider the latter problem to best sample from the replay buffer. But the favorable size for the replay buffer remains unknown. Although \cite{deeper_replay} points out that the learning algorithm is sensitive to the size of the replay buffer, they have not come up with a better conclusion on the size of the buffer. In this paper, we tackle the memory usage of DRL algorithms by implementing a modified approach for image preprocessing and replay buffer size. Although we want the agent to obtain a decent score, we are more concerned about memory usage. We choose a Deep Q-Network (DQN) \cite{atari} for our algorithm with some variations. Our objective is to design a DRL model that can be implemented on mobile devices during training and deployment. To be deployed on mobile devices, memory consumption must be minimized as traditional DRL model with visual inputs sometimes need half a terabyte of memory. We achieve low memory consumption by preprocessing the visual image data and tuning the replay buffer size with other hyperparameters. Then, we evaluate our model in our simulation environment using the classical control game named Snake.\textsuperscript{*} The results show that our model can achieve similar performance as other DRL methods. \section{Related Work} The core idea of reinforcement learning is the sequential decision making process involving some agency that learns from the experience and acts on uncertain environments. After the development of a formal framework of reinforcement learning, many algorithms have been introduced such as, \cite{q_learning92, td-gammon, pg_sutton_99, nat_ac, dpg}. Q-learning \cite{q_learning92} is a model-free asynchronous dynamic programming algorithm of reinforcement learning. Q-learning proposes that by sampling all the actions in states and iterating the action-value functions repeatedly, convergence can be achieved. The Q-learning works perfectly on limited state and action space while collapsing with high dimensional infinite state space. Then, \cite{atari} proposes their Deep Q-network algorithm that demonstrates significant results with image data. Among other variations, they use a convolutional neural network and replay buffer. Double Q-learning \cite{double_q_10} is applied with DQN to overcome the overestimation of the action-value function and is named Deep Reinforcement Learning with Double Q-Learning (DDQN) \cite{double_q}. DDQN proposes another neural network with the same structure as DQN but gets updated less frequently. Refined DQN \cite{autonomous} proposes another DRL method that involves a carefully designed reward mechanism and a dual experience replay structure. Refined DQN evaluate their work by enabling their agent to play the snake game. The experience replay buffer is a desirable property of modern DRL algorithms. It provides powerful, model-free, off-policy DRL algorithms with correlated data and improves data efficiency \cite{replay_99} during data sampling. DQN \cite{atari} shows the power of replay buffer in sampling data. DQN uses the size $10^6$ for replay buffer. After that, \cite{double_q, autonomous, ddpg, maddpg, soft_ac}, among others, have shown their work with the same size and structure as the replay buffer. Schaul et al. propose an efficient sampling strategy in their prioritized experience replay (PER) \cite{priotized_replay}. PER shows that instead of sampling data uniform-randomly, the latest data gets the most priority; hence the latest data have more probability of being selected, and this selection method seems to improve results. \cite{deeper_replay} shows that a large experience replay buffer can hurt the performance. They also propose that when sampling data to train DRL algorithms, the most recent data should the appended to the batch. \section{Method} Our objective is to reduce memory usage during training time while achieving the best performance possible. The replay memory takes a considerable amount of memory, as described later. We try to achieve memory efficiency by reducing the massive replay buffer requirement with image preprocessing and the buffer size. The buffer size is carefully chosen so that the agent has the necessary information to train well and achieves a moderate score. We use a slight variation of the deep Q-learning algorithm for this purpose. \begin{table}[!t] \renewcommand{\arraystretch}{1.3} \caption{Reward Mechanism for Snake Game} \centering \begin{tabular}{ccc} \hline \textbf{Moves}&\textbf{Rewards}&\textbf{Results} \\ Eats an apple & +1 & Score Increase \\ Hits with wall or itself & -1 & End of episode \\ Not eats or hits wall or itself & -0.1 & Continue playing games \\ \hline \end{tabular} \label{tab_reward_snake} \end{table} \begin{table}[!t] \renewcommand{\arraystretch}{1.3} \caption{Memory Requirement for Different Pixel Data} \centering \begin{tabular}{cccc} \hline \textbf{}&\textbf{RGB}&\textbf{Grayscale}&\textbf{Binary} \\ \textbf{Data Type} & float & float & int \\ \textbf{Size (kB)} & 165.375 & 55.125 & 6.890 \\ \textbf{Memory Save \% w.r.t. RGB} & 0\% & 67\% & 96\% \\ \textbf{Memory Save \% w.r.t. Grayscale} & - & 0\% & 87.5\% \\ \hline \end{tabular} \label{tab_image_memory} \end{table} \subsection{Image Preprocessing}\label{preproscessing} The agent gets the RGB values in the 3-D array format from the games' environments. We convert the RGB array into grayscale because it would not affect the performance~\cite{image-colorization} and it saves three times of memory. We resize the grayscale data into $84\times84$ pixels. Finally, for more memory reduction, we convert this resized grayscale data into binary data (values only with 0 and 1). The memory requirement for storing various image data (scaled-down between 0 and 1) is given in Table~\ref{tab_image_memory}. Table~\ref{tab_image_memory} shows that it saves around 67\% from converting RGB into grayscale and around 96\% from converting RBG into binary. Also, the memory requirement reduces by around 87.5\% converting from grayscale into binary. Visual pixel data transformation with preprocessing is given in Fig. \ref{prepros}. The preprocessing method is presented using a flowchart in Fig.~\ref{diagram_prepros}. \begin{figure}[!t] \centering \subfloat[Before preprocessing] {\includegraphics[trim={2.5cm 0 2.5cm 0},clip,width=1.5in]{fig_1a.pdf} \label{prepros_before}} \hfil \subfloat[After preprocessing] {\includegraphics[trim={2.5cm 0 2.5cm 0},clip,width=1.5in]{fig_2a.pdf} \label{prepros_after}} \caption{Visual image data before and after preprocessing} \label{prepros} \end{figure} \begin{figure}[!b] \centering \includegraphics[width=\linewidth]{fig_3.pdf} \caption{Diagram of image preprocessing} \label{diagram_prepros} \end{figure} \subsection{Game Selection and Their Environments} The use-case of our target applications is less complex tasks. For this reason, we implemented the classical Snake game \cite{snake} in the 'pygame' module. The game screen is divided into a $12\times12$ grid. The resolution for the game is set to $252\times252$. The initial snake size is 3. The controller has four inputs to navigate. Table~\ref{tab_reward_snake} shows the valid actions and respective reward for the snake game environment. \subsection{Reinforcement Learning Preliminary} Any reinforcement learning or sequential decision-making problem can be formulated with Markov Decision Processes (MDPs). An MDP is a triplet $M = ( \mathcal{X, A, P}_0)$, where $\mathcal{X}$ is a set of valid states, $\mathcal{A}$ is a set of valid actions, and $\mathcal{P}_0$ is transition probability kernel that maps $\mathcal{X \times A}$ into next state transition probability. For a deterministic system, the state transition is defined as, \begin{equation} \label{eq-state_transition} s_{t+1} = f(s_t, a_t) \end{equation} The reward is defined as, \begin{equation} \label{eq-reward_transition} r_t = R(s_t, a_t) \end{equation} The cumulative reward over a trajectory or episode is called the return, $R(\tau)$. The equation for discounted return is given below, \begin{equation} \label{eq-discounted_return} R(\tau) = \sum_{t=0}^{\infty} \gamma^t r_t \end{equation} \subsection{Deep Q-Learning} The goal of the RL agent is to maximize the expected return. Following a policy $\pi$, the expected return, $J(\pi)$, is defined as, \begin{equation} \label{eq-expected_return} J(\pi) = \underset{\tau \sim \pi}{\mathbb{E}} [R(\tau)] \end{equation} The optimal action-value or q function $Q^*(s, a)$ maximizes the expected return by taking any action at state $s$ and acting optimally in the following states. \begin{equation} \label{eq-optimal_action_value} Q^*(s,a) = \max_{\pi} \underset{\tau \sim \pi}{\mathbb{E}} [R(\tau) | s_0 = s, a_0 = a] \end{equation} For finding out the optimal actions based on an optimal action-value function at time $t$, the $Q^*$ must satisfy the Bellman Equation, which is, \begin{equation} \label{eq-bellman_op_action_value} Q^*(s,a) = \underset{s' \sim \rho}{\mathbb{E}} \left[ r(s,a) + \gamma \max_{a'} Q^*(s', a') \right] \end{equation} The optimal action-value function gives rise to optimal action $a^*(s)$. The $a^*(s)$ can be described as, \begin{equation} \label{eq-optimal_action} a^*(s) = \arg \max_{a} Q^*(s,a) \end{equation} For training an optimal action-value function, sometimes a non-linear function approximator like neural network~\cite{atari} is used. We used a convolutional neural network. \begin{table}[!t] \caption{The architecture of Neural Network} \centering \begin{tabular}{ccccccc} \hline \textbf{Layer}&\textbf{Filter}&\textbf{Stride}&\textbf{Layer}&\textbf{Acti-}&\textbf{Zero}&\textbf{Output} \\ \textbf{Name} & & & &\textbf{vation} &\textbf{Padd} & \\ Input & & & & & & 84*84*4 \\ Conv1 & 8*8 & 4 & 32 & ReLU & Yes & 21*21*32 \\ M. Pool & 2*2 & 2 & & & Yes & 11*11*32 \\ Conv2 & 4*4 & 2 & 64 & ReLU & Yes & 6*6*64 \\ M. Pool & 2*2 & 2 & & & Yes & 3*3*64 \\ B. Norm & & & & & & 3*3*64 \\ Conv3 & 3*3 & 2 & 128 & ReLU & Yes & 2*2*128 \\ M. Pool & 2*2 & 2 & & & Yes & 1*1*128 \\ B. Norm & & & & & & 1*1*128 \\ Flatten & & & & & & 128 \\ FC & & & 512 & ReLU & & 512 \\ FC & & & 512 & ReLU & & 512 \\ Output & & &No. of & Linear & &No. of \\ & & &actions & & & actions\\ \hline \multicolumn{7}{l}{\textsuperscript{M. Pool = Max Pooling, B. Norm = Batch Normalization, FC = Fully Connected}} \end{tabular} \label{tab_neural} \end{table} \begin{table}[!t] \caption{Memory Requirement Experience Replay} \centering \begin{tabular}{cccc} \hline \textbf{}&\textbf{RGB}&\textbf{Grayscale}&\textbf{Binary} \\ \textbf{Memory Usage (GB)} & 1261.71 & 420.57 & 2.628 \\ \textbf{Memory Save \% w.r.t. RGB} & 0\% & 67\% & 99.7\% \\ \textbf{Memory Save \% w.r.t. Grayscale} & - & 0\% & 99.4\% \\ \hline \end{tabular} \label{tab_replay_memory} \end{table} \begin{figure}[!b] \centering \includegraphics[trim={0 15cm 3cm 4cm},clip,width=\linewidth, height=5cm]{fig_4.pdf} \caption{Structure of experience replay memory and flowchart} \label{replay_mem} \end{figure} \begin{figure*}[t] \centering \includegraphics[trim={0 12cm 5cm 3cm},clip,height=0.70\textwidth, width=\textwidth]{fig_5.pdf} \caption{The deep reinforcement learning design structure of our model} \label{full_design} \end{figure*} \subsection{Neural Network} The action-value function is iteratively updated to achieve the optimal action-value function. The neural network used to approximate the action-value function and update at each iteration is called Q-network. We train the Q-network, parameterized by $\theta$, by minimizing a loss function $L_i(\theta_i)$ at $i th$ iteration. \begin{equation} \label{eq-loss_function} L_i(\theta_i) = \underset{s,a \sim \rho}{\mathbb{E}} \left[ (y_i - Q(s,a; \theta_i))^2 \right] \end{equation} where $y_i = \underset{s' \sim \rho}{\mathbb{E}} \left[ r(s,a) + \gamma \underset{a'}{\max} Q'(s', a';\theta'_{k}) \right]$ is the target for that update. Here $Q'$ is another Q-network with the same shape as Q-network but with a frozen parameter called target Q-network for training stability parameterized by $\theta'_k$. We train the Q-network by minimizing this loss function~(\ref{eq-loss_function}) w.r.t. the parameter $\theta_i$. We use Adam~\cite{adam} optimizer for fast convergence. Our convolutional neural network structure is shown in Table \ref{tab_neural}. \subsection{Experience Replay Buffer}\label{replay} As our focus is to keep memory requirements as low as possible during training, choosing the size of the replay buffer is one of the critical design decisions. The size of the replay buffer directly alters the requirement of memory necessity. We use a replay buffer of size 50,000, requiring less memory (only 5\%) than \cite{atari, double_q, autonomous}, which use a replay buffer of size 1,000,000. \cite{atari, double_q, autonomous} store grayscale data into a replay buffer. Table \ref{tab_replay_memory} shows that we use 99.4\% less memory compared to these works. The replay buffer stores data in FIFO (first in, first out) order so that the buffer contains only the latest data. We present the complete cycle of the experience replay buffer in Fig \ref{replay_mem}. Fig. \ref{full_design} illustrates our complete design diagram. \section{Experiments} \subsection{Training} For training our model, we take a random batch of 32 experiences from the replay buffer at each iteration. Our model has two convolutional neural networks (online DQN and target DQN) sharing the same structure but does not sync automatically. The weights of the target network are frozen so that it cannot be trained. The state history from the mini-batch is fed into the Online DQN. The DQN outputs the Q-values, $Q(s_t,a_t)$. \begin{equation} \label{eq6} Loss=[y_t-Q(s_t,a_t)]^2 \end{equation} The $y_t$ is calculated from the target Q-network. We are passing the next-state value to the target Q-network, and for each next-state in the batch, we get Q-value, respectively. That is our $max_{a'}Q(s',a')$ value in the below equation. \begin{equation} \label{eq7} y_t=R_{t+1}+\gamma max_{a'} Q(s',a') \end{equation} The $\gamma$ is the discount factor, which is one of many hyperparameters we are using in our model. Initially, we set $\gamma$ value to 0.99. The $R_{t+1}$ is the reward in each experience tuple. So, we get the $y_t$ value. The loss function is generated by putting these values in \eqref{eq6}. Then, we use this loss function to backpropagate our Online DQN with an 'Adam' optimizer. Adam optimizer is used instead of classical stochastic gradient descent for more speed. The target DQN is synced with online DQN at every 10,000 steps. The values of hyperparameters we choose are listed in Table~\ref{tab_hyperparameter}. \subsection{Results and Comparisons} \begin{figure}[!t] \centering \subfloat[Score vs. episode graph] {\includegraphics[width=0.48\linewidth]{ScoreEpisodeOur.png} \label{fig-res_our_score}} \subfloat[Reward vs. episode graph] {\includegraphics[width=0.48\linewidth]{RewardEpisodeOur.png} \label{fig-res_our_reward}} \caption{Results of our agent playing Snake game during training} \label{fig-res_our} \end{figure} \begin{figure}[!t] \centering \subfloat[Score vs. episode graph] {\includegraphics[width=0.48\linewidth]{ScoreEpisodeBaseline.png} \label{fig-res_baseline_score}} \subfloat[Reward vs. episode graph] {\includegraphics[width=0.48\linewidth]{RewardEpisodeBaseline.png} \label{fig-res_baseline_reward}} \caption{Results of baseline DQN model playing Snake game during training} \label{fig-res_baseline} \end{figure} \begin{figure}[!b] \centering \subfloat[Score comparison] {\includegraphics[width=0.48\linewidth]{ScoreEpisode.png} \label{fig-res_compare_score}} \subfloat[Reward comparison] {\includegraphics[width=0.48\linewidth]{RewardEpisode.png} \label{fig-res_compare_reward}} \caption{Comparison between our model and baseline DQN model} \label{fig-res_compare} \end{figure} We allow DRL agents to play 140,000 episodes of games to match the training results presented in \cite{autonomous}. We train one agent with our method and another with the DQN method presented in \cite{atari}, we refer to \cite{atari} as the baseline DQN model. Next, we compare our model with the baseline DQN model \cite{atari} and the refined DQN model \cite{autonomous}. The results of training the snake game with our model are shown in Fig. \ref{fig-res_our}. Fig. \ref{fig-res_our}\subref{fig-res_our_score} shows the game's score with our model during training. Fig. \ref{fig-res_our}\subref{fig-res_our_reward} shows that even though our reward mechanism is simpler than the refined DQN model, the agent maximizes the cumulative reward optimally. In section \ref{replay} we showed that our model is more memory efficient than the baseline DQN model and the refined DQN model during training. In this section we show that despite low memory usage, our model can achieve similar if not better results than the baseline and refined DQN models. Fig. \ref{fig-res_baseline} displays the baseline DQN results during training on the snake game. In Fig. \ref{fig-res_compare} we present the score and reward comparison between our model and the baseline DQN model. The blue line in Fig. \ref{fig-res_compare}\subref{fig-res_compare_score} represents our model's score, and the purple line represents the score of the baseline DQN model. During 140,000 numbers of training episodes, our model remains better at episode score though it requires fewer resources. Fig. \ref{fig-res_compare}\subref{fig-res_compare_reward} demonstrates that our model is capable of achieving higher cumulative rewards than the baseline DQN model. \begin{figure}[!t] \centering \subfloat[Score graph of Refined DQN (graph taken from~\cite{autonomous})] {\includegraphics[trim={0 0 0 0},clip,width=0.47\linewidth]{fig_10a.pdf} \label{our_and_refined_refined}} \subfloat[Score graph of our model] {\includegraphics[height=3.5cm,width=0.47\linewidth]{ScoreEpisodeOur.png} \label{our_and_refined_our}} \caption{Comparison between Refined DQN model and our model} \label{our_and_refined} \end{figure} \begin{figure}[!t] \centering \subfloat[Refined DQN score (Taken from~\cite{autonomous})] {\includegraphics[trim={0 0 0 0},clip,width=0.48\linewidth]{fig_11a.pdf} \label{our_and_refined_test_refined}} \hfil \subfloat[Our model's score] {\includegraphics[trim={0 0 0 1cm},clip,height=3.25cm,width=0.48\linewidth]{fig_11b.pdf} \label{our_and_refined_test_our}} \caption{Testing evaluation by playing random 50 episodes game} \label{our_and_refined_test} \end{figure} \begin{table}[!b] \caption{List of Performance comparison of Different Agents} \centering \begin{tabular}{cc} \hline \textbf{Performance}&\textbf{Score} \\ Human Average & 1.98 *\\ Baseline Average & 0.26 *\\ Refined DQN Average & 9.04 *\\ \textbf{Our Average} &\textbf{9.53} \\ Human Best & 15 *\\ Baseline Best & 2 *\\ Refined DQN Best & 17 *\\ \textbf{Our Best} &\textbf{20}\\ \hline \multicolumn{2}{l}{* Data taken from~\cite{autonomous}} \end{tabular} \label{tab_performance_list} \end{table} We also compare the results between our model and the refined DQN model \cite{autonomous}. Refined DQN follows a dual experience replay memory architecture and a complex reward mechanism. However, our model surpasses their score. Since their game is similar to ours, we compare our results with the results provided in their paper. Fig.~\ref{our_and_refined}\subref{our_and_refined_refined} shows the results presented in \cite{autonomous}, and Fig.~\ref{our_and_refined}\subref{our_and_refined_our} is our model's results during training. By comparing Fig.~\ref{our_and_refined}\subref{our_and_refined_refined} and Fig.~\ref{our_and_refined}\subref{our_and_refined_our}, we can safely say that our model achieves better scores despite having a simple replay buffer, a simple reward mechanism, and less memory consumption. Fig.~\ref{our_and_refined_test}\subref{our_and_refined_test_refined} and Fig.~\ref{our_and_refined_test}\subref{our_and_refined_test_our} show scores of random 50 episodes during testing of refined DQN and our model, respectively. Table \ref{tab_performance_list} summarizes the scores provided in the refined DQN and our model. We can identify from Table \ref{tab_performance_list} that their refined DQN average is 9.04, while ours is 9.53, and their refined DQN best score is 17, while ours is 20. So, we can see that our model also performs better in the training and testing phase. \begin{table}[ht] \renewcommand{\arraystretch}{1.3} \caption{List of Hyperparameters} \centering \begin{tabular}{ccc} \hline \textbf{Hyperparameter}&\textbf{Value}&\textbf{Description} \\ Discount Factor & 0.99 & $\gamma$-value in max Q-function \\ Initial Epsilon & 1.0 & Exploration epsilon initial value \\ Final Epsilon & 0.01 & Exploration final epsilon value \\ Batch size & 32 & Mini batch from replay memory \\ Max step & 10,000 & Maximum number of steps \\ & & allowed per episode \\ Learning Rate & 0.0025 & Learning rate for Adam optimizer \\ Clip-Norm & 1.0 & Clipping value for Adam optimizer \\ Random Frames & 50,000 & Number of random initial steps \\ Epsilon greedy & 500,000 & Number of frames in which initial \\ frames & & epsilon will be equal final epsilon \\ Experience Replay & 50,000 & Capacity of experience replay \\ Memory & & memory \\ Update of DQN & 4 & The number of steps after each \\ & & update of DQN takes place \\ Update Target & 10,000 & The number of steps after the \\ DQN & & Target and Online DQN sync \\ \hline \end{tabular} \label{tab_hyperparameter} \end{table} \section{Conclusion} In this paper, we have shown that better image preprocessing and constructing a better mechanism for replay buffer can reduce memory consumption on DRL algorithms during training. We have also demonstrated that using our method, the performance of the DRL agent on a lower constraint application is entirely similar, if not better. We combined our method with the DQN (with some modification) algorithm to observe the method's effectiveness. Our presented design requires less memory and a simple CNN. We established that our method's result is as good as other DRL approaches for the snake game autonomous agent. \section*{Acknowledgment} This work was supported by North South University research grant CTRG-21-SEPS-18. The authors would like to gratefully acknowledge that the computing resources used in this work was housed at the National University of Sciences and Technology (NUST), Pakistan. The cooperation was pursued under the South Asia Regional Development Center (RDC) framework of the Belt \& Road Aerospace Innovation Alliance (BRAIA). \bibliographystyle{IEEEtran}
{ "redpajama_set_name": "RedPajamaArXiv" }
7,238
Henderson's Boys 4: Grey Wolves (Paperback) By Robert Muchamore #5: Henderson's Boys 5: The Prisoner (Paperback): $10.99 #6: Henderson's Boys 6: One Shot Kill (Paperback): $10.99 #7: Henderson Boys 7: Scorched Earth (Paperback): $10.99 Spring, 1941. German submarines are prowling the North Atlantic, sinking ships filled with the food, fuel and weapons that Britain needs to survive. With the Royal Navy losing the war at sea, six young agents must sneak into Nazi-occupied Europe and sabotage a submarine base on France's western coast. If the submarines aren't stopped, the British people will starve. Robert Muchamore was born in Islington in 1972 and spent thirteen years working as a private investigator. He loves Arsenal and watching people fall down holes. He hates swimming and getting chased by cows. He was inspired to start writing by his nephews' complaints about the lack of anything for them to read! The CHERUB series has now become a number one bestseller in several countries. For more information, go to www.muchamore.com. Publisher: Hachette Children's Series: Hendersons Boys Minimum Grade Level: K There wasn't a boring chapter—The Guardian The action hurtles along at break-neck speed—NATE Classroom A must-read for all teenagers—Woman's Way Muachamore just keeps on improving when you think he can't!—Harry Griffiths, aged 14, First News Muchamore is single-handedly turning a lot of young boys back on to reading—Bournemouth Daily Echo 'Muchamore's plain, punchy,often funny style ... is highly effective. This clever, tense novel is a great way of getting bored boys interested in history.' (The Escape)—Amanda Craig, The Times 'It has the feel of something quite big and satisfying...Muchamore's voice is fresh and direct.' (The Escape)—The Daily Telegraph Mixes espionage and gritty realism when dealing with children in the midst of a war—Waterstones Quarterly, March 2009 'This book was un-putdownable. It gripped me from start to finish, and was just as good as the CHERUB series, if not better.' (The Escape)—Aaron, 14, First News Praise for books in the CHERUB series: 'Punchy, exciting, glamorous and, what's more, you'll completely wish it was true.'—The Sunday Express A stunning read for anyone, a real gem in the Henderson's Boys series that has already flown off the shelves.—First News The action hurtles along at break-neck speed.—NATE
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
1,180
fresh air and office windows overlooking soothing greenery. Prestigious training session rooms in central Kraków, fit for the 21st century. Well designed, air conditioned Offoffice office space can accommodate a number of training sessions meetings and conferences at the same time. Classroom, cinema of "U-shape" room arrangements are available. Rooms are spread across various floors, so that the participants do not get into each other's way. A projector, screen, whiteboards and markets are all available. You do not have to pay extra for coffee breaks. rest in the Relax Zone. 34 ergonomic desks are at your disposal together with two, professionally soundproofed, air-conditioned telephone booths. Offoffice is an ideal place for freelancers, sole traders and project teams. Find out for yourselves – come and see us! Your first day with us is free!
{ "redpajama_set_name": "RedPajamaC4" }
8,360
<?php # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/cloud/channel/v1/entitlements.proto namespace Google\Cloud\Channel\V1\Entitlement; use UnexpectedValueException; /** * Indicates the current provisioning state of the entitlement. * * Protobuf type <code>google.cloud.channel.v1.Entitlement.ProvisioningState</code> */ class ProvisioningState { /** * Default value. This state doesn't show unless an error occurs. * * Generated from protobuf enum <code>PROVISIONING_STATE_UNSPECIFIED = 0;</code> */ const PROVISIONING_STATE_UNSPECIFIED = 0; /** * The entitlement is currently active. * * Generated from protobuf enum <code>ACTIVE = 1;</code> */ const ACTIVE = 1; /** * The entitlement is currently suspended. * * Generated from protobuf enum <code>SUSPENDED = 5;</code> */ const SUSPENDED = 5; private static $valueToName = [ self::PROVISIONING_STATE_UNSPECIFIED => 'PROVISIONING_STATE_UNSPECIFIED', self::ACTIVE => 'ACTIVE', self::SUSPENDED => 'SUSPENDED', ]; public static function name($value) { if (!isset(self::$valueToName[$value])) { throw new UnexpectedValueException(sprintf( 'Enum %s has no name defined for value %s', __CLASS__, $value)); } return self::$valueToName[$value]; } public static function value($name) { $const = __CLASS__ . '::' . strtoupper($name); if (!defined($const)) { throw new UnexpectedValueException(sprintf( 'Enum %s has no value defined for name %s', __CLASS__, $name)); } return constant($const); } } // Adding a class alias for backwards compatibility with the previous class name. class_alias(ProvisioningState::class, \Google\Cloud\Channel\V1\Entitlement_ProvisioningState::class);
{ "redpajama_set_name": "RedPajamaGithub" }
4,371
Do you remember the time before the invention of mobile phones? How inconvenient it was to find a public phone when you needed to call someone! Think about the days before the Internet was available. Do you remember how difficult it was to find information using the encyclopaedia? With technology, we are empowered to do more, save time and enjoy greater convenience! Today, we can do so much more with the mobile phones other than merely calling and doing simple web surfing. We can participate in social media, shop for great online deals or avoid queues by transacting online. By learning some basic digital skills, you will be digitally ready to benefit from the myriad of digital services on-the-go. You can learn how to easily get from one place to another, listen to songs that you grew up with, transfer money to your friend, sell things you don't need and pay with your mobile phones at shops. How about using digital social media platforms like WhatsApp and Facebook to connect with friends and family? Would you like to post a self-made video onto YouTube and share it with the world? With the many interesting digital applications available today, the possibilities are endless. Do you think you are digitally-ready? Test yourself! Perhaps you are already quite confident of your digital skills. Why not try some of these questions from our Basic Digital Skills Quiz to find out how digitally ready you are?
{ "redpajama_set_name": "RedPajamaC4" }
1,087
The Scottish Nation, 1700-2000 / Tom Devine For at least the first half of the twentieth century, Scottish history could be said to have stopped in 1707. The history of the Scottish nation was the history of Bruce, Wallace and the Douglases; of knights in armour, cross-border warfare and corrupt priests. Margaret Thatcher: Complete Public Statements 1945-1990 / ed. Christopher Collins 'The Oratory of Triumph' Prime Ministers and the Rule Book / Amy Baker It is one of those quirky features of our ancient, but constantly changing, Constitution that one particular Cabinet Office document may warrant such an extensive enquiry. However, Amy Baker's Prime Ministers and the Rule Book rises to the challenge and produces a convincing and illuminating study. A Man and an Institution: Sir Maurice Hankey, the Cabinet Secretariat and the Custody of Cabinet Secrecy / John F. Naylor A Man and an Institution is in reality three books combined into one. It is, first, a contribution to a biography of Sir Maurice Hankey, the first Cabinet Secretary; second, a history of the origins of the Cabinet Office and its development until Hankey's retirement in 1938; and third, an account of how the Cabinet Office came to be the guardian of official secrecy. The Cabinet Papers 1915-1978 Online / In December 1916 the new British prime minister, David Lloyd George, sought to overcome the problems of waging the First World War through an unwieldy Cabinet by establishing a smaller, streamlined mechanism, the War Cabinet. He also set up a secretariat, the cabinet office, which would be overseen by the cabinet secretary, Maurice Hankey, and his deputy, Tom Jones. Governing Post-War Britain: The Paradoxes of Progress, 1951-1973 / Glen O'Hara In Joseph Heller's 1979 novel Good As Gold, the hapless protagonist, college professor and would-be public intellectual Bruce Gold, writes a light-hearted magazine article entitled 'Nothing Succeeds As Planned'. He sends a copy to his contact at the White House, the ineffable Ralph Newsome, who is delighted with it. 'I can't tell you how you're boggling our minds', Newsome tells Gold. A History of the Labour Party / Andrew Thorpe Andrew Thorpe's fourth edition of A History of the British Labour Party provides a much needed update to what has become one of the leading volumes on the Labour Party since its first edition in 1997. The book, spanning 412 pages, provides an engaging read into the history of the Labour Party. UK Parliamentary Papers: House of Commons / The parliamentary papers of the UK are one of the most important sources for the history of the UK and its former colonies in the 18th and 19th centuries, in their original form a series of thousands of printed reports. Remaking Policy: Scale, Pace, and Political Strategy in Health Care Reform / Carolyn Hughes Tuohy These days, expenditure on health amounts on average to some 9 per cent of gross domestic product in the prosperous nations of the West. Whether through direct taxation, social security, social health insurance or private means, it's a substantial amount. (-) Remove 20th Century filter 20th Century Medieval (1) Apply Medieval filter Australasia and Pacific (1) Apply Australasia and Pacific filter Political History (10) Apply Political History filter Medicine (2) Apply Medicine filter Art and Architecture (1) Apply Art and Architecture filter International History (1) Apply International History filter Palaeography and Diplomatic (1) Apply Palaeography and Diplomatic filter
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
8,147
{-# LANGUAGE PatternSynonyms #-} -- For HasCallStack compatibility {-# LANGUAGE ImplicitParams, ConstraintKinds, KindSignatures #-} {-# OPTIONS_GHC -fno-warn-unused-imports #-} module JSDOM.Generated.WebGL2RenderingContext (bufferDataPtr, bufferData, bufferSubData, bufferDataView, bufferSubDataView, copyBufferSubData, getBufferSubData, blitFramebuffer, framebufferTextureLayer, getInternalformatParameter, getInternalformatParameter_, invalidateFramebuffer, invalidateSubFramebuffer, readBuffer, renderbufferStorageMultisample, texStorage2D, texStorage3D, texImage3D, texSubImage3DView, texSubImage3D, copyTexSubImage3D, compressedTexImage3D, compressedTexSubImage3D, getFragDataLocation, getFragDataLocation_, uniform1ui, uniform2ui, uniform3ui, uniform4ui, uniform1uiv, uniform2uiv, uniform3uiv, uniform4uiv, uniformMatrix2x3fv, uniformMatrix3x2fv, uniformMatrix2x4fv, uniformMatrix4x2fv, uniformMatrix3x4fv, uniformMatrix4x3fv, vertexAttribI4i, vertexAttribI4iv, vertexAttribI4ui, vertexAttribI4uiv, vertexAttribIPointer, vertexAttribDivisor, drawArraysInstanced, drawElementsInstanced, drawRangeElements, drawBuffers, clearBufferiv, clearBufferuiv, clearBufferfv, clearBufferfi, createQuery, createQuery_, deleteQuery, isQuery, isQuery_, beginQuery, endQuery, getQuery, getQuery_, getQueryParameter, getQueryParameter_, createSampler, createSampler_, deleteSampler, isSampler, isSampler_, bindSampler, samplerParameteri, samplerParameterf, getSamplerParameter, getSamplerParameter_, fenceSync, fenceSync_, isSync, isSync_, deleteSync, clientWaitSync, clientWaitSync_, waitSync, getSyncParameter, getSyncParameter_, createTransformFeedback, createTransformFeedback_, deleteTransformFeedback, isTransformFeedback, isTransformFeedback_, bindTransformFeedback, beginTransformFeedback, endTransformFeedback, transformFeedbackVaryings, getTransformFeedbackVarying, getTransformFeedbackVarying_, pauseTransformFeedback, resumeTransformFeedback, bindBufferBase, bindBufferRange, getIndexedParameter, getIndexedParameter_, getUniformIndices, getUniformIndices_, getActiveUniforms, getActiveUniforms_, getUniformBlockIndex, getUniformBlockIndex_, getActiveUniformBlockParameter, getActiveUniformBlockParameter_, getActiveUniformBlockName, getActiveUniformBlockName_, uniformBlockBinding, createVertexArray, createVertexArray_, deleteVertexArray, isVertexArray, isVertexArray_, bindVertexArray, pattern READ_BUFFER, pattern UNPACK_ROW_LENGTH, pattern UNPACK_SKIP_ROWS, pattern UNPACK_SKIP_PIXELS, pattern PACK_ROW_LENGTH, pattern PACK_SKIP_ROWS, pattern PACK_SKIP_PIXELS, pattern COLOR, pattern DEPTH, pattern STENCIL, pattern RED, pattern RGB8, pattern RGBA8, pattern RGB10_A2, pattern TEXTURE_BINDING_3D, pattern UNPACK_SKIP_IMAGES, pattern UNPACK_IMAGE_HEIGHT, pattern TEXTURE_3D, pattern TEXTURE_WRAP_R, pattern MAX_3D_TEXTURE_SIZE, pattern UNSIGNED_INT_2_10_10_10_REV, pattern MAX_ELEMENTS_VERTICES, pattern MAX_ELEMENTS_INDICES, pattern TEXTURE_MIN_LOD, pattern TEXTURE_MAX_LOD, pattern TEXTURE_BASE_LEVEL, pattern TEXTURE_MAX_LEVEL, pattern MIN, pattern MAX, pattern DEPTH_COMPONENT24, pattern MAX_TEXTURE_LOD_BIAS, pattern TEXTURE_COMPARE_MODE, pattern TEXTURE_COMPARE_FUNC, pattern CURRENT_QUERY, pattern QUERY_RESULT, pattern QUERY_RESULT_AVAILABLE, pattern STREAM_READ, pattern STREAM_COPY, pattern STATIC_READ, pattern STATIC_COPY, pattern DYNAMIC_READ, pattern DYNAMIC_COPY, pattern MAX_DRAW_BUFFERS, pattern DRAW_BUFFER0, pattern DRAW_BUFFER1, pattern DRAW_BUFFER2, pattern DRAW_BUFFER3, pattern DRAW_BUFFER4, pattern DRAW_BUFFER5, pattern DRAW_BUFFER6, pattern DRAW_BUFFER7, pattern DRAW_BUFFER8, pattern DRAW_BUFFER9, pattern DRAW_BUFFER10, pattern DRAW_BUFFER11, pattern DRAW_BUFFER12, pattern DRAW_BUFFER13, pattern DRAW_BUFFER14, pattern DRAW_BUFFER15, pattern MAX_FRAGMENT_UNIFORM_COMPONENTS, pattern MAX_VERTEX_UNIFORM_COMPONENTS, pattern SAMPLER_3D, pattern SAMPLER_2D_SHADOW, pattern FRAGMENT_SHADER_DERIVATIVE_HINT, pattern PIXEL_PACK_BUFFER, pattern PIXEL_UNPACK_BUFFER, pattern PIXEL_PACK_BUFFER_BINDING, pattern PIXEL_UNPACK_BUFFER_BINDING, pattern FLOAT_MAT2x3, pattern FLOAT_MAT2x4, pattern FLOAT_MAT3x2, pattern FLOAT_MAT3x4, pattern FLOAT_MAT4x2, pattern FLOAT_MAT4x3, pattern SRGB, pattern SRGB8, pattern SRGB8_ALPHA8, pattern COMPARE_REF_TO_TEXTURE, pattern RGBA32F, pattern RGB32F, pattern RGBA16F, pattern RGB16F, pattern VERTEX_ATTRIB_ARRAY_INTEGER, pattern MAX_ARRAY_TEXTURE_LAYERS, pattern MIN_PROGRAM_TEXEL_OFFSET, pattern MAX_PROGRAM_TEXEL_OFFSET, pattern MAX_VARYING_COMPONENTS, pattern TEXTURE_2D_ARRAY, pattern TEXTURE_BINDING_2D_ARRAY, pattern R11F_G11F_B10F, pattern UNSIGNED_INT_10F_11F_11F_REV, pattern RGB9_E5, pattern UNSIGNED_INT_5_9_9_9_REV, pattern TRANSFORM_FEEDBACK_BUFFER_MODE, pattern MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS, pattern TRANSFORM_FEEDBACK_VARYINGS, pattern TRANSFORM_FEEDBACK_BUFFER_START, pattern TRANSFORM_FEEDBACK_BUFFER_SIZE, pattern TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN, pattern RASTERIZER_DISCARD, pattern MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS, pattern MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS, pattern INTERLEAVED_ATTRIBS, pattern SEPARATE_ATTRIBS, pattern TRANSFORM_FEEDBACK_BUFFER, pattern TRANSFORM_FEEDBACK_BUFFER_BINDING, pattern RGBA32UI, pattern RGB32UI, pattern RGBA16UI, pattern RGB16UI, pattern RGBA8UI, pattern RGB8UI, pattern RGBA32I, pattern RGB32I, pattern RGBA16I, pattern RGB16I, pattern RGBA8I, pattern RGB8I, pattern RED_INTEGER, pattern RGB_INTEGER, pattern RGBA_INTEGER, pattern SAMPLER_2D_ARRAY, pattern SAMPLER_2D_ARRAY_SHADOW, pattern SAMPLER_CUBE_SHADOW, pattern UNSIGNED_INT_VEC2, pattern UNSIGNED_INT_VEC3, pattern UNSIGNED_INT_VEC4, pattern INT_SAMPLER_2D, pattern INT_SAMPLER_3D, pattern INT_SAMPLER_CUBE, pattern INT_SAMPLER_2D_ARRAY, pattern UNSIGNED_INT_SAMPLER_2D, pattern UNSIGNED_INT_SAMPLER_3D, pattern UNSIGNED_INT_SAMPLER_CUBE, pattern UNSIGNED_INT_SAMPLER_2D_ARRAY, pattern DEPTH_COMPONENT32F, pattern DEPTH32F_STENCIL8, pattern FLOAT_32_UNSIGNED_INT_24_8_REV, pattern FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING, pattern FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE, pattern FRAMEBUFFER_ATTACHMENT_RED_SIZE, pattern FRAMEBUFFER_ATTACHMENT_GREEN_SIZE, pattern FRAMEBUFFER_ATTACHMENT_BLUE_SIZE, pattern FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE, pattern FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE, pattern FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE, pattern FRAMEBUFFER_DEFAULT, pattern DEPTH_STENCIL_ATTACHMENT, pattern DEPTH_STENCIL, pattern UNSIGNED_INT_24_8, pattern DEPTH24_STENCIL8, pattern UNSIGNED_NORMALIZED, pattern DRAW_FRAMEBUFFER_BINDING, pattern READ_FRAMEBUFFER, pattern DRAW_FRAMEBUFFER, pattern READ_FRAMEBUFFER_BINDING, pattern RENDERBUFFER_SAMPLES, pattern FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER, pattern MAX_COLOR_ATTACHMENTS, pattern COLOR_ATTACHMENT1, pattern COLOR_ATTACHMENT2, pattern COLOR_ATTACHMENT3, pattern COLOR_ATTACHMENT4, pattern COLOR_ATTACHMENT5, pattern COLOR_ATTACHMENT6, pattern COLOR_ATTACHMENT7, pattern COLOR_ATTACHMENT8, pattern COLOR_ATTACHMENT9, pattern COLOR_ATTACHMENT10, pattern COLOR_ATTACHMENT11, pattern COLOR_ATTACHMENT12, pattern COLOR_ATTACHMENT13, pattern COLOR_ATTACHMENT14, pattern COLOR_ATTACHMENT15, pattern FRAMEBUFFER_INCOMPLETE_MULTISAMPLE, pattern MAX_SAMPLES, pattern HALF_FLOAT, pattern RG, pattern RG_INTEGER, pattern R8, pattern RG8, pattern R16F, pattern R32F, pattern RG16F, pattern RG32F, pattern R8I, pattern R8UI, pattern R16I, pattern R16UI, pattern R32I, pattern R32UI, pattern RG8I, pattern RG8UI, pattern RG16I, pattern RG16UI, pattern RG32I, pattern RG32UI, pattern VERTEX_ARRAY_BINDING, pattern R8_SNORM, pattern RG8_SNORM, pattern RGB8_SNORM, pattern RGBA8_SNORM, pattern SIGNED_NORMALIZED, pattern PRIMITIVE_RESTART_FIXED_INDEX, pattern COPY_READ_BUFFER, pattern COPY_WRITE_BUFFER, pattern COPY_READ_BUFFER_BINDING, pattern COPY_WRITE_BUFFER_BINDING, pattern UNIFORM_BUFFER, pattern UNIFORM_BUFFER_BINDING, pattern UNIFORM_BUFFER_START, pattern UNIFORM_BUFFER_SIZE, pattern MAX_VERTEX_UNIFORM_BLOCKS, pattern MAX_FRAGMENT_UNIFORM_BLOCKS, pattern MAX_COMBINED_UNIFORM_BLOCKS, pattern MAX_UNIFORM_BUFFER_BINDINGS, pattern MAX_UNIFORM_BLOCK_SIZE, pattern MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS, pattern MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS, pattern UNIFORM_BUFFER_OFFSET_ALIGNMENT, pattern ACTIVE_UNIFORM_BLOCKS, pattern UNIFORM_TYPE, pattern UNIFORM_SIZE, pattern UNIFORM_BLOCK_INDEX, pattern UNIFORM_OFFSET, pattern UNIFORM_ARRAY_STRIDE, pattern UNIFORM_MATRIX_STRIDE, pattern UNIFORM_IS_ROW_MAJOR, pattern UNIFORM_BLOCK_BINDING, pattern UNIFORM_BLOCK_DATA_SIZE, pattern UNIFORM_BLOCK_ACTIVE_UNIFORMS, pattern UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES, pattern UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER, pattern UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER, pattern INVALID_INDEX, pattern MAX_VERTEX_OUTPUT_COMPONENTS, pattern MAX_FRAGMENT_INPUT_COMPONENTS, pattern MAX_SERVER_WAIT_TIMEOUT, pattern OBJECT_TYPE, pattern SYNC_CONDITION, pattern SYNC_STATUS, pattern SYNC_FLAGS, pattern SYNC_FENCE, pattern SYNC_GPU_COMMANDS_COMPLETE, pattern UNSIGNALED, pattern SIGNALED, pattern ALREADY_SIGNALED, pattern TIMEOUT_EXPIRED, pattern CONDITION_SATISFIED, pattern WAIT_FAILED, pattern SYNC_FLUSH_COMMANDS_BIT, pattern VERTEX_ATTRIB_ARRAY_DIVISOR, pattern ANY_SAMPLES_PASSED, pattern ANY_SAMPLES_PASSED_CONSERVATIVE, pattern SAMPLER_BINDING, pattern RGB10_A2UI, pattern TEXTURE_SWIZZLE_R, pattern TEXTURE_SWIZZLE_G, pattern TEXTURE_SWIZZLE_B, pattern TEXTURE_SWIZZLE_A, pattern GREEN, pattern BLUE, pattern INT_2_10_10_10_REV, pattern TRANSFORM_FEEDBACK, pattern TRANSFORM_FEEDBACK_PAUSED, pattern TRANSFORM_FEEDBACK_ACTIVE, pattern TRANSFORM_FEEDBACK_BINDING, pattern COMPRESSED_R11_EAC, pattern COMPRESSED_SIGNED_R11_EAC, pattern COMPRESSED_RG11_EAC, pattern COMPRESSED_SIGNED_RG11_EAC, pattern COMPRESSED_RGB8_ETC2, pattern COMPRESSED_SRGB8_ETC2, pattern COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2, pattern COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2, pattern COMPRESSED_RGBA8_ETC2_EAC, pattern COMPRESSED_SRGB8_ALPHA8_ETC2_EAC, pattern TEXTURE_IMMUTABLE_FORMAT, pattern MAX_ELEMENT_INDEX, pattern NUM_SAMPLE_COUNTS, pattern TEXTURE_IMMUTABLE_LEVELS, pattern VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE, pattern TIMEOUT_IGNORED, WebGL2RenderingContext(..), gTypeWebGL2RenderingContext) where import Prelude ((.), (==), (>>=), return, IO, Int, Float, Double, Bool(..), Maybe, maybe, fromIntegral, round, realToFrac, fmap, Show, Read, Eq, Ord, Maybe(..)) import qualified Prelude (error) import Data.Typeable (Typeable) import Data.Traversable (mapM) import Language.Javascript.JSaddle (JSM(..), JSVal(..), JSString, strictEqual, toJSVal, valToStr, valToNumber, valToBool, js, jss, jsf, jsg, function, asyncFunction, new, array, jsUndefined, (!), (!!)) import Data.Int (Int64) import Data.Word (Word, Word64) import JSDOM.Types import Control.Applicative ((<$>)) import Control.Monad (void) import Control.Lens.Operators ((^.)) import JSDOM.EventTargetClosures (EventName, unsafeEventName, unsafeEventNameAsync) import JSDOM.Enums -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bufferData Mozilla WebGL2RenderingContext.bufferData documentation> bufferDataPtr :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLsizeiptr -> GLenum -> m () bufferDataPtr self target size usage = liftDOM (void (self ^. jsf "bufferData" [toJSVal target, integralToDoubleToJSVal size, toJSVal usage])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bufferData Mozilla WebGL2RenderingContext.bufferData documentation> bufferData :: (MonadDOM m, IsBufferDataSource srcData) => WebGL2RenderingContext -> GLenum -> Maybe srcData -> GLenum -> m () bufferData self target srcData usage = liftDOM (void (self ^. jsf "bufferData" [toJSVal target, toJSVal srcData, toJSVal usage])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bufferSubData Mozilla WebGL2RenderingContext.bufferSubData documentation> bufferSubData :: (MonadDOM m, IsBufferDataSource srcData) => WebGL2RenderingContext -> GLenum -> GLintptr -> Maybe srcData -> m () bufferSubData self target dstByteOffset srcData = liftDOM (void (self ^. jsf "bufferSubData" [toJSVal target, integralToDoubleToJSVal dstByteOffset, toJSVal srcData])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bufferData Mozilla WebGL2RenderingContext.bufferData documentation> bufferDataView :: (MonadDOM m, IsArrayBufferView data') => WebGL2RenderingContext -> GLenum -> data' -> GLenum -> GLuint -> Maybe GLuint -> m () bufferDataView self target data' usage srcOffset length = liftDOM (void (self ^. jsf "bufferData" [toJSVal target, toJSVal data', toJSVal usage, toJSVal srcOffset, toJSVal length])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bufferSubData Mozilla WebGL2RenderingContext.bufferSubData documentation> bufferSubDataView :: (MonadDOM m, IsArrayBufferView srcData) => WebGL2RenderingContext -> GLenum -> GLintptr -> srcData -> GLuint -> Maybe GLuint -> m () bufferSubDataView self target dstByteOffset srcData srcOffset length = liftDOM (void (self ^. jsf "bufferSubData" [toJSVal target, integralToDoubleToJSVal dstByteOffset, toJSVal srcData, toJSVal srcOffset, toJSVal length])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.copyBufferSubData Mozilla WebGL2RenderingContext.copyBufferSubData documentation> copyBufferSubData :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLenum -> GLintptr -> GLintptr -> GLsizeiptr -> m () copyBufferSubData self readTarget writeTarget readOffset writeOffset size = liftDOM (void (self ^. jsf "copyBufferSubData" [toJSVal readTarget, toJSVal writeTarget, integralToDoubleToJSVal readOffset, integralToDoubleToJSVal writeOffset, integralToDoubleToJSVal size])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getBufferSubData Mozilla WebGL2RenderingContext.getBufferSubData documentation> getBufferSubData :: (MonadDOM m, IsArrayBufferView dstData) => WebGL2RenderingContext -> GLenum -> GLintptr -> dstData -> Maybe GLuint -> Maybe GLuint -> m () getBufferSubData self target srcByteOffset dstData dstOffset length = liftDOM (void (self ^. jsf "getBufferSubData" [toJSVal target, integralToDoubleToJSVal srcByteOffset, toJSVal dstData, toJSVal dstOffset, toJSVal length])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.blitFramebuffer Mozilla WebGL2RenderingContext.blitFramebuffer documentation> blitFramebuffer :: (MonadDOM m) => WebGL2RenderingContext -> GLint -> GLint -> GLint -> GLint -> GLint -> GLint -> GLint -> GLint -> GLbitfield -> GLenum -> m () blitFramebuffer self srcX0 srcY0 srcX1 srcY1 dstX0 dstY0 dstX1 dstY1 mask filter = liftDOM (void (self ^. jsf "blitFramebuffer" [toJSVal srcX0, toJSVal srcY0, toJSVal srcX1, toJSVal srcY1, toJSVal dstX0, toJSVal dstY0, toJSVal dstX1, toJSVal dstY1, toJSVal mask, toJSVal filter])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.framebufferTextureLayer Mozilla WebGL2RenderingContext.framebufferTextureLayer documentation> framebufferTextureLayer :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLenum -> GLuint -> GLint -> GLint -> m () framebufferTextureLayer self target attachment texture level layer = liftDOM (void (self ^. jsf "framebufferTextureLayer" [toJSVal target, toJSVal attachment, toJSVal texture, toJSVal level, toJSVal layer])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getInternalformatParameter Mozilla WebGL2RenderingContext.getInternalformatParameter documentation> getInternalformatParameter :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLenum -> GLenum -> m JSVal getInternalformatParameter self target internalformat pname = liftDOM ((self ^. jsf "getInternalformatParameter" [toJSVal target, toJSVal internalformat, toJSVal pname]) >>= toJSVal) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getInternalformatParameter Mozilla WebGL2RenderingContext.getInternalformatParameter documentation> getInternalformatParameter_ :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLenum -> GLenum -> m () getInternalformatParameter_ self target internalformat pname = liftDOM (void (self ^. jsf "getInternalformatParameter" [toJSVal target, toJSVal internalformat, toJSVal pname])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.invalidateFramebuffer Mozilla WebGL2RenderingContext.invalidateFramebuffer documentation> invalidateFramebuffer :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> [GLenum] -> m () invalidateFramebuffer self target attachments = liftDOM (void (self ^. jsf "invalidateFramebuffer" [toJSVal target, toJSVal (array attachments)])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.invalidateSubFramebuffer Mozilla WebGL2RenderingContext.invalidateSubFramebuffer documentation> invalidateSubFramebuffer :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> [GLenum] -> GLint -> GLint -> GLsizei -> GLsizei -> m () invalidateSubFramebuffer self target attachments x y width height = liftDOM (void (self ^. jsf "invalidateSubFramebuffer" [toJSVal target, toJSVal (array attachments), toJSVal x, toJSVal y, toJSVal width, toJSVal height])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.readBuffer Mozilla WebGL2RenderingContext.readBuffer documentation> readBuffer :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> m () readBuffer self src = liftDOM (void (self ^. jsf "readBuffer" [toJSVal src])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.renderbufferStorageMultisample Mozilla WebGL2RenderingContext.renderbufferStorageMultisample documentation> renderbufferStorageMultisample :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLsizei -> GLenum -> GLsizei -> GLsizei -> m () renderbufferStorageMultisample self target samples internalformat width height = liftDOM (void (self ^. jsf "renderbufferStorageMultisample" [toJSVal target, toJSVal samples, toJSVal internalformat, toJSVal width, toJSVal height])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.texStorage2D Mozilla WebGL2RenderingContext.texStorage2D documentation> texStorage2D :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLsizei -> GLenum -> GLsizei -> GLsizei -> m () texStorage2D self target levels internalformat width height = liftDOM (void (self ^. jsf "texStorage2D" [toJSVal target, toJSVal levels, toJSVal internalformat, toJSVal width, toJSVal height])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.texStorage3D Mozilla WebGL2RenderingContext.texStorage3D documentation> texStorage3D :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLsizei -> GLenum -> GLsizei -> GLsizei -> GLsizei -> m () texStorage3D self target levels internalformat width height depth = liftDOM (void (self ^. jsf "texStorage3D" [toJSVal target, toJSVal levels, toJSVal internalformat, toJSVal width, toJSVal height, toJSVal depth])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.texImage3D Mozilla WebGL2RenderingContext.texImage3D documentation> texImage3D :: (MonadDOM m, IsArrayBufferView pixels) => WebGL2RenderingContext -> GLenum -> GLint -> GLint -> GLsizei -> GLsizei -> GLsizei -> GLint -> GLenum -> GLenum -> Maybe pixels -> m () texImage3D self target level internalformat width height depth border format type' pixels = liftDOM (void (self ^. jsf "texImage3D" [toJSVal target, toJSVal level, toJSVal internalformat, toJSVal width, toJSVal height, toJSVal depth, toJSVal border, toJSVal format, toJSVal type', toJSVal pixels])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.texSubImage3D Mozilla WebGL2RenderingContext.texSubImage3D documentation> texSubImage3DView :: (MonadDOM m, IsArrayBufferView pixels) => WebGL2RenderingContext -> GLenum -> GLint -> GLint -> GLint -> GLint -> GLsizei -> GLsizei -> GLsizei -> GLenum -> GLenum -> Maybe pixels -> m () texSubImage3DView self target level xoffset yoffset zoffset width height depth format type' pixels = liftDOM (void (self ^. jsf "texSubImage3D" [toJSVal target, toJSVal level, toJSVal xoffset, toJSVal yoffset, toJSVal zoffset, toJSVal width, toJSVal height, toJSVal depth, toJSVal format, toJSVal type', toJSVal pixels])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.texSubImage3D Mozilla WebGL2RenderingContext.texSubImage3D documentation> texSubImage3D :: (MonadDOM m, IsTexImageSource source) => WebGL2RenderingContext -> GLenum -> GLint -> GLint -> GLint -> GLint -> GLenum -> GLenum -> source -> m () texSubImage3D self target level xoffset yoffset zoffset format type' source = liftDOM (void (self ^. jsf "texSubImage3D" [toJSVal target, toJSVal level, toJSVal xoffset, toJSVal yoffset, toJSVal zoffset, toJSVal format, toJSVal type', toJSVal source])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.copyTexSubImage3D Mozilla WebGL2RenderingContext.copyTexSubImage3D documentation> copyTexSubImage3D :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLint -> GLint -> GLint -> GLint -> GLint -> GLint -> GLsizei -> GLsizei -> m () copyTexSubImage3D self target level xoffset yoffset zoffset x y width height = liftDOM (void (self ^. jsf "copyTexSubImage3D" [toJSVal target, toJSVal level, toJSVal xoffset, toJSVal yoffset, toJSVal zoffset, toJSVal x, toJSVal y, toJSVal width, toJSVal height])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.compressedTexImage3D Mozilla WebGL2RenderingContext.compressedTexImage3D documentation> compressedTexImage3D :: (MonadDOM m, IsArrayBufferView data') => WebGL2RenderingContext -> GLenum -> GLint -> GLenum -> GLsizei -> GLsizei -> GLsizei -> GLint -> GLsizei -> Maybe data' -> m () compressedTexImage3D self target level internalformat width height depth border imageSize data' = liftDOM (void (self ^. jsf "compressedTexImage3D" [toJSVal target, toJSVal level, toJSVal internalformat, toJSVal width, toJSVal height, toJSVal depth, toJSVal border, toJSVal imageSize, toJSVal data'])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.compressedTexSubImage3D Mozilla WebGL2RenderingContext.compressedTexSubImage3D documentation> compressedTexSubImage3D :: (MonadDOM m, IsArrayBufferView data') => WebGL2RenderingContext -> GLenum -> GLint -> GLint -> GLint -> GLint -> GLsizei -> GLsizei -> GLsizei -> GLenum -> GLsizei -> Maybe data' -> m () compressedTexSubImage3D self target level xoffset yoffset zoffset width height depth format imageSize data' = liftDOM (void (self ^. jsf "compressedTexSubImage3D" [toJSVal target, toJSVal level, toJSVal xoffset, toJSVal yoffset, toJSVal zoffset, toJSVal width, toJSVal height, toJSVal depth, toJSVal format, toJSVal imageSize, toJSVal data'])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getFragDataLocation Mozilla WebGL2RenderingContext.getFragDataLocation documentation> getFragDataLocation :: (MonadDOM m, ToJSString name) => WebGL2RenderingContext -> Maybe WebGLProgram -> name -> m GLint getFragDataLocation self program name = liftDOM ((self ^. jsf "getFragDataLocation" [toJSVal program, toJSVal name]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getFragDataLocation Mozilla WebGL2RenderingContext.getFragDataLocation documentation> getFragDataLocation_ :: (MonadDOM m, ToJSString name) => WebGL2RenderingContext -> Maybe WebGLProgram -> name -> m () getFragDataLocation_ self program name = liftDOM (void (self ^. jsf "getFragDataLocation" [toJSVal program, toJSVal name])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform1ui Mozilla WebGL2RenderingContext.uniform1ui documentation> uniform1ui :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLuint -> m () uniform1ui self location v0 = liftDOM (void (self ^. jsf "uniform1ui" [toJSVal location, toJSVal v0])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform2ui Mozilla WebGL2RenderingContext.uniform2ui documentation> uniform2ui :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLuint -> GLuint -> m () uniform2ui self location v0 v1 = liftDOM (void (self ^. jsf "uniform2ui" [toJSVal location, toJSVal v0, toJSVal v1])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform3ui Mozilla WebGL2RenderingContext.uniform3ui documentation> uniform3ui :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLuint -> GLuint -> GLuint -> m () uniform3ui self location v0 v1 v2 = liftDOM (void (self ^. jsf "uniform3ui" [toJSVal location, toJSVal v0, toJSVal v1, toJSVal v2])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform4ui Mozilla WebGL2RenderingContext.uniform4ui documentation> uniform4ui :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLuint -> GLuint -> GLuint -> GLuint -> m () uniform4ui self location v0 v1 v2 v3 = liftDOM (void (self ^. jsf "uniform4ui" [toJSVal location, toJSVal v0, toJSVal v1, toJSVal v2, toJSVal v3])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform1uiv Mozilla WebGL2RenderingContext.uniform1uiv documentation> uniform1uiv :: (MonadDOM m, IsUint32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> Maybe value -> m () uniform1uiv self location value = liftDOM (void (self ^. jsf "uniform1uiv" [toJSVal location, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform2uiv Mozilla WebGL2RenderingContext.uniform2uiv documentation> uniform2uiv :: (MonadDOM m, IsUint32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> Maybe value -> m () uniform2uiv self location value = liftDOM (void (self ^. jsf "uniform2uiv" [toJSVal location, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform3uiv Mozilla WebGL2RenderingContext.uniform3uiv documentation> uniform3uiv :: (MonadDOM m, IsUint32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> Maybe value -> m () uniform3uiv self location value = liftDOM (void (self ^. jsf "uniform3uiv" [toJSVal location, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniform4uiv Mozilla WebGL2RenderingContext.uniform4uiv documentation> uniform4uiv :: (MonadDOM m, IsUint32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> Maybe value -> m () uniform4uiv self location value = liftDOM (void (self ^. jsf "uniform4uiv" [toJSVal location, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniformMatrix2x3fv Mozilla WebGL2RenderingContext.uniformMatrix2x3fv documentation> uniformMatrix2x3fv :: (MonadDOM m, IsFloat32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLboolean -> Maybe value -> m () uniformMatrix2x3fv self location transpose value = liftDOM (void (self ^. jsf "uniformMatrix2x3fv" [toJSVal location, toJSVal transpose, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniformMatrix3x2fv Mozilla WebGL2RenderingContext.uniformMatrix3x2fv documentation> uniformMatrix3x2fv :: (MonadDOM m, IsFloat32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLboolean -> Maybe value -> m () uniformMatrix3x2fv self location transpose value = liftDOM (void (self ^. jsf "uniformMatrix3x2fv" [toJSVal location, toJSVal transpose, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniformMatrix2x4fv Mozilla WebGL2RenderingContext.uniformMatrix2x4fv documentation> uniformMatrix2x4fv :: (MonadDOM m, IsFloat32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLboolean -> Maybe value -> m () uniformMatrix2x4fv self location transpose value = liftDOM (void (self ^. jsf "uniformMatrix2x4fv" [toJSVal location, toJSVal transpose, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniformMatrix4x2fv Mozilla WebGL2RenderingContext.uniformMatrix4x2fv documentation> uniformMatrix4x2fv :: (MonadDOM m, IsFloat32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLboolean -> Maybe value -> m () uniformMatrix4x2fv self location transpose value = liftDOM (void (self ^. jsf "uniformMatrix4x2fv" [toJSVal location, toJSVal transpose, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniformMatrix3x4fv Mozilla WebGL2RenderingContext.uniformMatrix3x4fv documentation> uniformMatrix3x4fv :: (MonadDOM m, IsFloat32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLboolean -> Maybe value -> m () uniformMatrix3x4fv self location transpose value = liftDOM (void (self ^. jsf "uniformMatrix3x4fv" [toJSVal location, toJSVal transpose, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniformMatrix4x3fv Mozilla WebGL2RenderingContext.uniformMatrix4x3fv documentation> uniformMatrix4x3fv :: (MonadDOM m, IsFloat32Array value) => WebGL2RenderingContext -> Maybe WebGLUniformLocation -> GLboolean -> Maybe value -> m () uniformMatrix4x3fv self location transpose value = liftDOM (void (self ^. jsf "uniformMatrix4x3fv" [toJSVal location, toJSVal transpose, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.vertexAttribI4i Mozilla WebGL2RenderingContext.vertexAttribI4i documentation> vertexAttribI4i :: (MonadDOM m) => WebGL2RenderingContext -> GLuint -> GLint -> GLint -> GLint -> GLint -> m () vertexAttribI4i self index x y z w = liftDOM (void (self ^. jsf "vertexAttribI4i" [toJSVal index, toJSVal x, toJSVal y, toJSVal z, toJSVal w])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.vertexAttribI4iv Mozilla WebGL2RenderingContext.vertexAttribI4iv documentation> vertexAttribI4iv :: (MonadDOM m, IsInt32Array v) => WebGL2RenderingContext -> GLuint -> Maybe v -> m () vertexAttribI4iv self index v = liftDOM (void (self ^. jsf "vertexAttribI4iv" [toJSVal index, toJSVal v])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.vertexAttribI4ui Mozilla WebGL2RenderingContext.vertexAttribI4ui documentation> vertexAttribI4ui :: (MonadDOM m) => WebGL2RenderingContext -> GLuint -> GLuint -> GLuint -> GLuint -> GLuint -> m () vertexAttribI4ui self index x y z w = liftDOM (void (self ^. jsf "vertexAttribI4ui" [toJSVal index, toJSVal x, toJSVal y, toJSVal z, toJSVal w])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.vertexAttribI4uiv Mozilla WebGL2RenderingContext.vertexAttribI4uiv documentation> vertexAttribI4uiv :: (MonadDOM m, IsUint32Array v) => WebGL2RenderingContext -> GLuint -> Maybe v -> m () vertexAttribI4uiv self index v = liftDOM (void (self ^. jsf "vertexAttribI4uiv" [toJSVal index, toJSVal v])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.vertexAttribIPointer Mozilla WebGL2RenderingContext.vertexAttribIPointer documentation> vertexAttribIPointer :: (MonadDOM m) => WebGL2RenderingContext -> GLuint -> GLint -> GLenum -> GLsizei -> GLintptr -> m () vertexAttribIPointer self index size type' stride offset = liftDOM (void (self ^. jsf "vertexAttribIPointer" [toJSVal index, toJSVal size, toJSVal type', toJSVal stride, integralToDoubleToJSVal offset])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.vertexAttribDivisor Mozilla WebGL2RenderingContext.vertexAttribDivisor documentation> vertexAttribDivisor :: (MonadDOM m) => WebGL2RenderingContext -> GLuint -> GLuint -> m () vertexAttribDivisor self index divisor = liftDOM (void (self ^. jsf "vertexAttribDivisor" [toJSVal index, toJSVal divisor])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.drawArraysInstanced Mozilla WebGL2RenderingContext.drawArraysInstanced documentation> drawArraysInstanced :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLint -> GLsizei -> GLsizei -> m () drawArraysInstanced self mode first count instanceCount = liftDOM (void (self ^. jsf "drawArraysInstanced" [toJSVal mode, toJSVal first, toJSVal count, toJSVal instanceCount])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.drawElementsInstanced Mozilla WebGL2RenderingContext.drawElementsInstanced documentation> drawElementsInstanced :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLsizei -> GLenum -> GLintptr -> GLsizei -> m () drawElementsInstanced self mode count type' offset instanceCount = liftDOM (void (self ^. jsf "drawElementsInstanced" [toJSVal mode, toJSVal count, toJSVal type', integralToDoubleToJSVal offset, toJSVal instanceCount])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.drawRangeElements Mozilla WebGL2RenderingContext.drawRangeElements documentation> drawRangeElements :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLuint -> GLuint -> GLsizei -> GLenum -> GLintptr -> m () drawRangeElements self mode start end count type' offset = liftDOM (void (self ^. jsf "drawRangeElements" [toJSVal mode, toJSVal start, toJSVal end, toJSVal count, toJSVal type', integralToDoubleToJSVal offset])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.drawBuffers Mozilla WebGL2RenderingContext.drawBuffers documentation> drawBuffers :: (MonadDOM m) => WebGL2RenderingContext -> [GLenum] -> m () drawBuffers self buffers = liftDOM (void (self ^. jsf "drawBuffers" [toJSVal (array buffers)])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.clearBufferiv Mozilla WebGL2RenderingContext.clearBufferiv documentation> clearBufferiv :: (MonadDOM m, IsInt32Array value) => WebGL2RenderingContext -> GLenum -> GLint -> Maybe value -> m () clearBufferiv self buffer drawbuffer value = liftDOM (void (self ^. jsf "clearBufferiv" [toJSVal buffer, toJSVal drawbuffer, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.clearBufferuiv Mozilla WebGL2RenderingContext.clearBufferuiv documentation> clearBufferuiv :: (MonadDOM m, IsUint32Array value) => WebGL2RenderingContext -> GLenum -> GLint -> Maybe value -> m () clearBufferuiv self buffer drawbuffer value = liftDOM (void (self ^. jsf "clearBufferuiv" [toJSVal buffer, toJSVal drawbuffer, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.clearBufferfv Mozilla WebGL2RenderingContext.clearBufferfv documentation> clearBufferfv :: (MonadDOM m, IsFloat32Array value) => WebGL2RenderingContext -> GLenum -> GLint -> Maybe value -> m () clearBufferfv self buffer drawbuffer value = liftDOM (void (self ^. jsf "clearBufferfv" [toJSVal buffer, toJSVal drawbuffer, toJSVal value])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.clearBufferfi Mozilla WebGL2RenderingContext.clearBufferfi documentation> clearBufferfi :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLint -> GLfloat -> GLint -> m () clearBufferfi self buffer drawbuffer depth stencil = liftDOM (void (self ^. jsf "clearBufferfi" [toJSVal buffer, toJSVal drawbuffer, toJSVal depth, toJSVal stencil])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createQuery Mozilla WebGL2RenderingContext.createQuery documentation> createQuery :: (MonadDOM m) => WebGL2RenderingContext -> m WebGLQuery createQuery self = liftDOM ((self ^. jsf "createQuery" ()) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createQuery Mozilla WebGL2RenderingContext.createQuery documentation> createQuery_ :: (MonadDOM m) => WebGL2RenderingContext -> m () createQuery_ self = liftDOM (void (self ^. jsf "createQuery" ())) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.deleteQuery Mozilla WebGL2RenderingContext.deleteQuery documentation> deleteQuery :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLQuery -> m () deleteQuery self query = liftDOM (void (self ^. jsf "deleteQuery" [toJSVal query])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isQuery Mozilla WebGL2RenderingContext.isQuery documentation> isQuery :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLQuery -> m GLboolean isQuery self query = liftDOM ((self ^. jsf "isQuery" [toJSVal query]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isQuery Mozilla WebGL2RenderingContext.isQuery documentation> isQuery_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLQuery -> m () isQuery_ self query = liftDOM (void (self ^. jsf "isQuery" [toJSVal query])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.beginQuery Mozilla WebGL2RenderingContext.beginQuery documentation> beginQuery :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> Maybe WebGLQuery -> m () beginQuery self target query = liftDOM (void (self ^. jsf "beginQuery" [toJSVal target, toJSVal query])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.endQuery Mozilla WebGL2RenderingContext.endQuery documentation> endQuery :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> m () endQuery self target = liftDOM (void (self ^. jsf "endQuery" [toJSVal target])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getQuery Mozilla WebGL2RenderingContext.getQuery documentation> getQuery :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLenum -> m WebGLQuery getQuery self target pname = liftDOM ((self ^. jsf "getQuery" [toJSVal target, toJSVal pname]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getQuery Mozilla WebGL2RenderingContext.getQuery documentation> getQuery_ :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLenum -> m () getQuery_ self target pname = liftDOM (void (self ^. jsf "getQuery" [toJSVal target, toJSVal pname])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getQueryParameter Mozilla WebGL2RenderingContext.getQueryParameter documentation> getQueryParameter :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLQuery -> GLenum -> m JSVal getQueryParameter self query pname = liftDOM ((self ^. jsf "getQueryParameter" [toJSVal query, toJSVal pname]) >>= toJSVal) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getQueryParameter Mozilla WebGL2RenderingContext.getQueryParameter documentation> getQueryParameter_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLQuery -> GLenum -> m () getQueryParameter_ self query pname = liftDOM (void (self ^. jsf "getQueryParameter" [toJSVal query, toJSVal pname])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createSampler Mozilla WebGL2RenderingContext.createSampler documentation> createSampler :: (MonadDOM m) => WebGL2RenderingContext -> m WebGLSampler createSampler self = liftDOM ((self ^. jsf "createSampler" ()) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createSampler Mozilla WebGL2RenderingContext.createSampler documentation> createSampler_ :: (MonadDOM m) => WebGL2RenderingContext -> m () createSampler_ self = liftDOM (void (self ^. jsf "createSampler" ())) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.deleteSampler Mozilla WebGL2RenderingContext.deleteSampler documentation> deleteSampler :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSampler -> m () deleteSampler self sampler = liftDOM (void (self ^. jsf "deleteSampler" [toJSVal sampler])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isSampler Mozilla WebGL2RenderingContext.isSampler documentation> isSampler :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSampler -> m GLboolean isSampler self sampler = liftDOM ((self ^. jsf "isSampler" [toJSVal sampler]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isSampler Mozilla WebGL2RenderingContext.isSampler documentation> isSampler_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSampler -> m () isSampler_ self sampler = liftDOM (void (self ^. jsf "isSampler" [toJSVal sampler])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bindSampler Mozilla WebGL2RenderingContext.bindSampler documentation> bindSampler :: (MonadDOM m) => WebGL2RenderingContext -> GLuint -> Maybe WebGLSampler -> m () bindSampler self unit sampler = liftDOM (void (self ^. jsf "bindSampler" [toJSVal unit, toJSVal sampler])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.samplerParameteri Mozilla WebGL2RenderingContext.samplerParameteri documentation> samplerParameteri :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSampler -> GLenum -> GLint -> m () samplerParameteri self sampler pname param = liftDOM (void (self ^. jsf "samplerParameteri" [toJSVal sampler, toJSVal pname, toJSVal param])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.samplerParameterf Mozilla WebGL2RenderingContext.samplerParameterf documentation> samplerParameterf :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSampler -> GLenum -> GLfloat -> m () samplerParameterf self sampler pname param = liftDOM (void (self ^. jsf "samplerParameterf" [toJSVal sampler, toJSVal pname, toJSVal param])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getSamplerParameter Mozilla WebGL2RenderingContext.getSamplerParameter documentation> getSamplerParameter :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSampler -> GLenum -> m JSVal getSamplerParameter self sampler pname = liftDOM ((self ^. jsf "getSamplerParameter" [toJSVal sampler, toJSVal pname]) >>= toJSVal) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getSamplerParameter Mozilla WebGL2RenderingContext.getSamplerParameter documentation> getSamplerParameter_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSampler -> GLenum -> m () getSamplerParameter_ self sampler pname = liftDOM (void (self ^. jsf "getSamplerParameter" [toJSVal sampler, toJSVal pname])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.fenceSync Mozilla WebGL2RenderingContext.fenceSync documentation> fenceSync :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLbitfield -> m WebGLSync fenceSync self condition flags = liftDOM ((self ^. jsf "fenceSync" [toJSVal condition, toJSVal flags]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.fenceSync Mozilla WebGL2RenderingContext.fenceSync documentation> fenceSync_ :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLbitfield -> m () fenceSync_ self condition flags = liftDOM (void (self ^. jsf "fenceSync" [toJSVal condition, toJSVal flags])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isSync Mozilla WebGL2RenderingContext.isSync documentation> isSync :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> m GLboolean isSync self sync = liftDOM ((self ^. jsf "isSync" [toJSVal sync]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isSync Mozilla WebGL2RenderingContext.isSync documentation> isSync_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> m () isSync_ self sync = liftDOM (void (self ^. jsf "isSync" [toJSVal sync])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.deleteSync Mozilla WebGL2RenderingContext.deleteSync documentation> deleteSync :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> m () deleteSync self sync = liftDOM (void (self ^. jsf "deleteSync" [toJSVal sync])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.clientWaitSync Mozilla WebGL2RenderingContext.clientWaitSync documentation> clientWaitSync :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> GLbitfield -> GLuint64 -> m GLenum clientWaitSync self sync flags timeout = liftDOM ((self ^. jsf "clientWaitSync" [toJSVal sync, toJSVal flags, integralToDoubleToJSVal timeout]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.clientWaitSync Mozilla WebGL2RenderingContext.clientWaitSync documentation> clientWaitSync_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> GLbitfield -> GLuint64 -> m () clientWaitSync_ self sync flags timeout = liftDOM (void (self ^. jsf "clientWaitSync" [toJSVal sync, toJSVal flags, integralToDoubleToJSVal timeout])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.waitSync Mozilla WebGL2RenderingContext.waitSync documentation> waitSync :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> GLbitfield -> GLuint64 -> m () waitSync self sync flags timeout = liftDOM (void (self ^. jsf "waitSync" [toJSVal sync, toJSVal flags, integralToDoubleToJSVal timeout])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getSyncParameter Mozilla WebGL2RenderingContext.getSyncParameter documentation> getSyncParameter :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> GLenum -> m JSVal getSyncParameter self sync pname = liftDOM ((self ^. jsf "getSyncParameter" [toJSVal sync, toJSVal pname]) >>= toJSVal) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getSyncParameter Mozilla WebGL2RenderingContext.getSyncParameter documentation> getSyncParameter_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLSync -> GLenum -> m () getSyncParameter_ self sync pname = liftDOM (void (self ^. jsf "getSyncParameter" [toJSVal sync, toJSVal pname])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createTransformFeedback Mozilla WebGL2RenderingContext.createTransformFeedback documentation> createTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> m WebGLTransformFeedback createTransformFeedback self = liftDOM ((self ^. jsf "createTransformFeedback" ()) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createTransformFeedback Mozilla WebGL2RenderingContext.createTransformFeedback documentation> createTransformFeedback_ :: (MonadDOM m) => WebGL2RenderingContext -> m () createTransformFeedback_ self = liftDOM (void (self ^. jsf "createTransformFeedback" ())) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.deleteTransformFeedback Mozilla WebGL2RenderingContext.deleteTransformFeedback documentation> deleteTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLTransformFeedback -> m () deleteTransformFeedback self id = liftDOM (void (self ^. jsf "deleteTransformFeedback" [toJSVal id])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isTransformFeedback Mozilla WebGL2RenderingContext.isTransformFeedback documentation> isTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLTransformFeedback -> m GLboolean isTransformFeedback self id = liftDOM ((self ^. jsf "isTransformFeedback" [toJSVal id]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isTransformFeedback Mozilla WebGL2RenderingContext.isTransformFeedback documentation> isTransformFeedback_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLTransformFeedback -> m () isTransformFeedback_ self id = liftDOM (void (self ^. jsf "isTransformFeedback" [toJSVal id])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bindTransformFeedback Mozilla WebGL2RenderingContext.bindTransformFeedback documentation> bindTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> Maybe WebGLTransformFeedback -> m () bindTransformFeedback self target id = liftDOM (void (self ^. jsf "bindTransformFeedback" [toJSVal target, toJSVal id])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.beginTransformFeedback Mozilla WebGL2RenderingContext.beginTransformFeedback documentation> beginTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> m () beginTransformFeedback self primitiveMode = liftDOM (void (self ^. jsf "beginTransformFeedback" [toJSVal primitiveMode])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.endTransformFeedback Mozilla WebGL2RenderingContext.endTransformFeedback documentation> endTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> m () endTransformFeedback self = liftDOM (void (self ^. jsf "endTransformFeedback" ())) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.transformFeedbackVaryings Mozilla WebGL2RenderingContext.transformFeedbackVaryings documentation> transformFeedbackVaryings :: (MonadDOM m, ToJSString varyings) => WebGL2RenderingContext -> Maybe WebGLProgram -> [varyings] -> GLenum -> m () transformFeedbackVaryings self program varyings bufferMode = liftDOM (void (self ^. jsf "transformFeedbackVaryings" [toJSVal program, toJSVal (array varyings), toJSVal bufferMode])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getTransformFeedbackVarying Mozilla WebGL2RenderingContext.getTransformFeedbackVarying documentation> getTransformFeedbackVarying :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLProgram -> GLuint -> m WebGLActiveInfo getTransformFeedbackVarying self program index = liftDOM ((self ^. jsf "getTransformFeedbackVarying" [toJSVal program, toJSVal index]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getTransformFeedbackVarying Mozilla WebGL2RenderingContext.getTransformFeedbackVarying documentation> getTransformFeedbackVarying_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLProgram -> GLuint -> m () getTransformFeedbackVarying_ self program index = liftDOM (void (self ^. jsf "getTransformFeedbackVarying" [toJSVal program, toJSVal index])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.pauseTransformFeedback Mozilla WebGL2RenderingContext.pauseTransformFeedback documentation> pauseTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> m () pauseTransformFeedback self = liftDOM (void (self ^. jsf "pauseTransformFeedback" ())) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.resumeTransformFeedback Mozilla WebGL2RenderingContext.resumeTransformFeedback documentation> resumeTransformFeedback :: (MonadDOM m) => WebGL2RenderingContext -> m () resumeTransformFeedback self = liftDOM (void (self ^. jsf "resumeTransformFeedback" ())) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bindBufferBase Mozilla WebGL2RenderingContext.bindBufferBase documentation> bindBufferBase :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLuint -> Maybe WebGLBuffer -> m () bindBufferBase self target index buffer = liftDOM (void (self ^. jsf "bindBufferBase" [toJSVal target, toJSVal index, toJSVal buffer])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bindBufferRange Mozilla WebGL2RenderingContext.bindBufferRange documentation> bindBufferRange :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLuint -> Maybe WebGLBuffer -> GLintptr -> GLsizeiptr -> m () bindBufferRange self target index buffer offset size = liftDOM (void (self ^. jsf "bindBufferRange" [toJSVal target, toJSVal index, toJSVal buffer, integralToDoubleToJSVal offset, integralToDoubleToJSVal size])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getIndexedParameter Mozilla WebGL2RenderingContext.getIndexedParameter documentation> getIndexedParameter :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLuint -> m JSVal getIndexedParameter self target index = liftDOM ((self ^. jsf "getIndexedParameter" [toJSVal target, toJSVal index]) >>= toJSVal) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getIndexedParameter Mozilla WebGL2RenderingContext.getIndexedParameter documentation> getIndexedParameter_ :: (MonadDOM m) => WebGL2RenderingContext -> GLenum -> GLuint -> m () getIndexedParameter_ self target index = liftDOM (void (self ^. jsf "getIndexedParameter" [toJSVal target, toJSVal index])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getUniformIndices Mozilla WebGL2RenderingContext.getUniformIndices documentation> getUniformIndices :: (MonadDOM m, ToJSString uniformNames) => WebGL2RenderingContext -> Maybe WebGLProgram -> [uniformNames] -> m Uint32Array getUniformIndices self program uniformNames = liftDOM ((self ^. jsf "getUniformIndices" [toJSVal program, toJSVal (array uniformNames)]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getUniformIndices Mozilla WebGL2RenderingContext.getUniformIndices documentation> getUniformIndices_ :: (MonadDOM m, ToJSString uniformNames) => WebGL2RenderingContext -> Maybe WebGLProgram -> [uniformNames] -> m () getUniformIndices_ self program uniformNames = liftDOM (void (self ^. jsf "getUniformIndices" [toJSVal program, toJSVal (array uniformNames)])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getActiveUniforms Mozilla WebGL2RenderingContext.getActiveUniforms documentation> getActiveUniforms :: (MonadDOM m, IsUint32Array uniformIndices) => WebGL2RenderingContext -> Maybe WebGLProgram -> Maybe uniformIndices -> GLenum -> m Int32Array getActiveUniforms self program uniformIndices pname = liftDOM ((self ^. jsf "getActiveUniforms" [toJSVal program, toJSVal uniformIndices, toJSVal pname]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getActiveUniforms Mozilla WebGL2RenderingContext.getActiveUniforms documentation> getActiveUniforms_ :: (MonadDOM m, IsUint32Array uniformIndices) => WebGL2RenderingContext -> Maybe WebGLProgram -> Maybe uniformIndices -> GLenum -> m () getActiveUniforms_ self program uniformIndices pname = liftDOM (void (self ^. jsf "getActiveUniforms" [toJSVal program, toJSVal uniformIndices, toJSVal pname])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getUniformBlockIndex Mozilla WebGL2RenderingContext.getUniformBlockIndex documentation> getUniformBlockIndex :: (MonadDOM m, ToJSString uniformBlockName) => WebGL2RenderingContext -> Maybe WebGLProgram -> uniformBlockName -> m GLuint getUniformBlockIndex self program uniformBlockName = liftDOM ((self ^. jsf "getUniformBlockIndex" [toJSVal program, toJSVal uniformBlockName]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getUniformBlockIndex Mozilla WebGL2RenderingContext.getUniformBlockIndex documentation> getUniformBlockIndex_ :: (MonadDOM m, ToJSString uniformBlockName) => WebGL2RenderingContext -> Maybe WebGLProgram -> uniformBlockName -> m () getUniformBlockIndex_ self program uniformBlockName = liftDOM (void (self ^. jsf "getUniformBlockIndex" [toJSVal program, toJSVal uniformBlockName])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getActiveUniformBlockParameter Mozilla WebGL2RenderingContext.getActiveUniformBlockParameter documentation> getActiveUniformBlockParameter :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLProgram -> GLuint -> GLenum -> m JSVal getActiveUniformBlockParameter self program uniformBlockIndex pname = liftDOM ((self ^. jsf "getActiveUniformBlockParameter" [toJSVal program, toJSVal uniformBlockIndex, toJSVal pname]) >>= toJSVal) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getActiveUniformBlockParameter Mozilla WebGL2RenderingContext.getActiveUniformBlockParameter documentation> getActiveUniformBlockParameter_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLProgram -> GLuint -> GLenum -> m () getActiveUniformBlockParameter_ self program uniformBlockIndex pname = liftDOM (void (self ^. jsf "getActiveUniformBlockParameter" [toJSVal program, toJSVal uniformBlockIndex, toJSVal pname])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getActiveUniformBlockName Mozilla WebGL2RenderingContext.getActiveUniformBlockName documentation> getActiveUniformBlockName :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLProgram -> GLuint -> m JSVal getActiveUniformBlockName self program uniformBlockIndex = liftDOM ((self ^. jsf "getActiveUniformBlockName" [toJSVal program, toJSVal uniformBlockIndex]) >>= toJSVal) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.getActiveUniformBlockName Mozilla WebGL2RenderingContext.getActiveUniformBlockName documentation> getActiveUniformBlockName_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLProgram -> GLuint -> m () getActiveUniformBlockName_ self program uniformBlockIndex = liftDOM (void (self ^. jsf "getActiveUniformBlockName" [toJSVal program, toJSVal uniformBlockIndex])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.uniformBlockBinding Mozilla WebGL2RenderingContext.uniformBlockBinding documentation> uniformBlockBinding :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLProgram -> GLuint -> GLuint -> m () uniformBlockBinding self program uniformBlockIndex uniformBlockBinding = liftDOM (void (self ^. jsf "uniformBlockBinding" [toJSVal program, toJSVal uniformBlockIndex, toJSVal uniformBlockBinding])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createVertexArray Mozilla WebGL2RenderingContext.createVertexArray documentation> createVertexArray :: (MonadDOM m) => WebGL2RenderingContext -> m WebGLVertexArrayObject createVertexArray self = liftDOM ((self ^. jsf "createVertexArray" ()) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.createVertexArray Mozilla WebGL2RenderingContext.createVertexArray documentation> createVertexArray_ :: (MonadDOM m) => WebGL2RenderingContext -> m () createVertexArray_ self = liftDOM (void (self ^. jsf "createVertexArray" ())) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.deleteVertexArray Mozilla WebGL2RenderingContext.deleteVertexArray documentation> deleteVertexArray :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLVertexArrayObject -> m () deleteVertexArray self vertexArray = liftDOM (void (self ^. jsf "deleteVertexArray" [toJSVal vertexArray])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isVertexArray Mozilla WebGL2RenderingContext.isVertexArray documentation> isVertexArray :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLVertexArrayObject -> m GLboolean isVertexArray self vertexArray = liftDOM ((self ^. jsf "isVertexArray" [toJSVal vertexArray]) >>= fromJSValUnchecked) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.isVertexArray Mozilla WebGL2RenderingContext.isVertexArray documentation> isVertexArray_ :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLVertexArrayObject -> m () isVertexArray_ self vertexArray = liftDOM (void (self ^. jsf "isVertexArray" [toJSVal vertexArray])) -- | <https://developer.mozilla.org/en-US/docs/Web/API/WebGL2RenderingContext.bindVertexArray Mozilla WebGL2RenderingContext.bindVertexArray documentation> bindVertexArray :: (MonadDOM m) => WebGL2RenderingContext -> Maybe WebGLVertexArrayObject -> m () bindVertexArray self vertexArray = liftDOM (void (self ^. jsf "bindVertexArray" [toJSVal vertexArray])) pattern READ_BUFFER = 3074 pattern UNPACK_ROW_LENGTH = 3314 pattern UNPACK_SKIP_ROWS = 3315 pattern UNPACK_SKIP_PIXELS = 3316 pattern PACK_ROW_LENGTH = 3330 pattern PACK_SKIP_ROWS = 3331 pattern PACK_SKIP_PIXELS = 3332 pattern COLOR = 6144 pattern DEPTH = 6145 pattern STENCIL = 6146 pattern RED = 6403 pattern RGB8 = 32849 pattern RGBA8 = 32856 pattern RGB10_A2 = 32857 pattern TEXTURE_BINDING_3D = 32874 pattern UNPACK_SKIP_IMAGES = 32877 pattern UNPACK_IMAGE_HEIGHT = 32878 pattern TEXTURE_3D = 32879 pattern TEXTURE_WRAP_R = 32882 pattern MAX_3D_TEXTURE_SIZE = 32883 pattern UNSIGNED_INT_2_10_10_10_REV = 33640 pattern MAX_ELEMENTS_VERTICES = 33000 pattern MAX_ELEMENTS_INDICES = 33001 pattern TEXTURE_MIN_LOD = 33082 pattern TEXTURE_MAX_LOD = 33083 pattern TEXTURE_BASE_LEVEL = 33084 pattern TEXTURE_MAX_LEVEL = 33085 pattern MIN = 32775 pattern MAX = 32776 pattern DEPTH_COMPONENT24 = 33190 pattern MAX_TEXTURE_LOD_BIAS = 34045 pattern TEXTURE_COMPARE_MODE = 34892 pattern TEXTURE_COMPARE_FUNC = 34893 pattern CURRENT_QUERY = 34917 pattern QUERY_RESULT = 34918 pattern QUERY_RESULT_AVAILABLE = 34919 pattern STREAM_READ = 35041 pattern STREAM_COPY = 35042 pattern STATIC_READ = 35045 pattern STATIC_COPY = 35046 pattern DYNAMIC_READ = 35049 pattern DYNAMIC_COPY = 35050 pattern MAX_DRAW_BUFFERS = 34852 pattern DRAW_BUFFER0 = 34853 pattern DRAW_BUFFER1 = 34854 pattern DRAW_BUFFER2 = 34855 pattern DRAW_BUFFER3 = 34856 pattern DRAW_BUFFER4 = 34857 pattern DRAW_BUFFER5 = 34858 pattern DRAW_BUFFER6 = 34859 pattern DRAW_BUFFER7 = 34860 pattern DRAW_BUFFER8 = 34861 pattern DRAW_BUFFER9 = 34862 pattern DRAW_BUFFER10 = 34863 pattern DRAW_BUFFER11 = 34864 pattern DRAW_BUFFER12 = 34865 pattern DRAW_BUFFER13 = 34866 pattern DRAW_BUFFER14 = 34867 pattern DRAW_BUFFER15 = 34868 pattern MAX_FRAGMENT_UNIFORM_COMPONENTS = 35657 pattern MAX_VERTEX_UNIFORM_COMPONENTS = 35658 pattern SAMPLER_3D = 35679 pattern SAMPLER_2D_SHADOW = 35682 pattern FRAGMENT_SHADER_DERIVATIVE_HINT = 35723 pattern PIXEL_PACK_BUFFER = 35051 pattern PIXEL_UNPACK_BUFFER = 35052 pattern PIXEL_PACK_BUFFER_BINDING = 35053 pattern PIXEL_UNPACK_BUFFER_BINDING = 35055 pattern FLOAT_MAT2x3 = 35685 pattern FLOAT_MAT2x4 = 35686 pattern FLOAT_MAT3x2 = 35687 pattern FLOAT_MAT3x4 = 35688 pattern FLOAT_MAT4x2 = 35689 pattern FLOAT_MAT4x3 = 35690 pattern SRGB = 35904 pattern SRGB8 = 35905 pattern SRGB8_ALPHA8 = 35907 pattern COMPARE_REF_TO_TEXTURE = 34894 pattern RGBA32F = 34836 pattern RGB32F = 34837 pattern RGBA16F = 34842 pattern RGB16F = 34843 pattern VERTEX_ATTRIB_ARRAY_INTEGER = 35069 pattern MAX_ARRAY_TEXTURE_LAYERS = 35071 pattern MIN_PROGRAM_TEXEL_OFFSET = 35076 pattern MAX_PROGRAM_TEXEL_OFFSET = 35077 pattern MAX_VARYING_COMPONENTS = 35659 pattern TEXTURE_2D_ARRAY = 35866 pattern TEXTURE_BINDING_2D_ARRAY = 35869 pattern R11F_G11F_B10F = 35898 pattern UNSIGNED_INT_10F_11F_11F_REV = 35899 pattern RGB9_E5 = 35901 pattern UNSIGNED_INT_5_9_9_9_REV = 35902 pattern TRANSFORM_FEEDBACK_BUFFER_MODE = 35967 pattern MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 35968 pattern TRANSFORM_FEEDBACK_VARYINGS = 35971 pattern TRANSFORM_FEEDBACK_BUFFER_START = 35972 pattern TRANSFORM_FEEDBACK_BUFFER_SIZE = 35973 pattern TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 35976 pattern RASTERIZER_DISCARD = 35977 pattern MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 35978 pattern MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 35979 pattern INTERLEAVED_ATTRIBS = 35980 pattern SEPARATE_ATTRIBS = 35981 pattern TRANSFORM_FEEDBACK_BUFFER = 35982 pattern TRANSFORM_FEEDBACK_BUFFER_BINDING = 35983 pattern RGBA32UI = 36208 pattern RGB32UI = 36209 pattern RGBA16UI = 36214 pattern RGB16UI = 36215 pattern RGBA8UI = 36220 pattern RGB8UI = 36221 pattern RGBA32I = 36226 pattern RGB32I = 36227 pattern RGBA16I = 36232 pattern RGB16I = 36233 pattern RGBA8I = 36238 pattern RGB8I = 36239 pattern RED_INTEGER = 36244 pattern RGB_INTEGER = 36248 pattern RGBA_INTEGER = 36249 pattern SAMPLER_2D_ARRAY = 36289 pattern SAMPLER_2D_ARRAY_SHADOW = 36292 pattern SAMPLER_CUBE_SHADOW = 36293 pattern UNSIGNED_INT_VEC2 = 36294 pattern UNSIGNED_INT_VEC3 = 36295 pattern UNSIGNED_INT_VEC4 = 36296 pattern INT_SAMPLER_2D = 36298 pattern INT_SAMPLER_3D = 36299 pattern INT_SAMPLER_CUBE = 36300 pattern INT_SAMPLER_2D_ARRAY = 36303 pattern UNSIGNED_INT_SAMPLER_2D = 36306 pattern UNSIGNED_INT_SAMPLER_3D = 36307 pattern UNSIGNED_INT_SAMPLER_CUBE = 36308 pattern UNSIGNED_INT_SAMPLER_2D_ARRAY = 36311 pattern DEPTH_COMPONENT32F = 36012 pattern DEPTH32F_STENCIL8 = 36013 pattern FLOAT_32_UNSIGNED_INT_24_8_REV = 36269 pattern FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 33296 pattern FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 33297 pattern FRAMEBUFFER_ATTACHMENT_RED_SIZE = 33298 pattern FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 33299 pattern FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 33300 pattern FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 33301 pattern FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 33302 pattern FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 33303 pattern FRAMEBUFFER_DEFAULT = 33304 pattern DEPTH_STENCIL_ATTACHMENT = 33306 pattern DEPTH_STENCIL = 34041 pattern UNSIGNED_INT_24_8 = 34042 pattern DEPTH24_STENCIL8 = 35056 pattern UNSIGNED_NORMALIZED = 35863 pattern DRAW_FRAMEBUFFER_BINDING = 36006 pattern READ_FRAMEBUFFER = 36008 pattern DRAW_FRAMEBUFFER = 36009 pattern READ_FRAMEBUFFER_BINDING = 36010 pattern RENDERBUFFER_SAMPLES = 36011 pattern FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 36052 pattern MAX_COLOR_ATTACHMENTS = 36063 pattern COLOR_ATTACHMENT1 = 36065 pattern COLOR_ATTACHMENT2 = 36066 pattern COLOR_ATTACHMENT3 = 36067 pattern COLOR_ATTACHMENT4 = 36068 pattern COLOR_ATTACHMENT5 = 36069 pattern COLOR_ATTACHMENT6 = 36070 pattern COLOR_ATTACHMENT7 = 36071 pattern COLOR_ATTACHMENT8 = 36072 pattern COLOR_ATTACHMENT9 = 36073 pattern COLOR_ATTACHMENT10 = 36074 pattern COLOR_ATTACHMENT11 = 36075 pattern COLOR_ATTACHMENT12 = 36076 pattern COLOR_ATTACHMENT13 = 36077 pattern COLOR_ATTACHMENT14 = 36078 pattern COLOR_ATTACHMENT15 = 36079 pattern FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 36182 pattern MAX_SAMPLES = 36183 pattern HALF_FLOAT = 5131 pattern RG = 33319 pattern RG_INTEGER = 33320 pattern R8 = 33321 pattern RG8 = 33323 pattern R16F = 33325 pattern R32F = 33326 pattern RG16F = 33327 pattern RG32F = 33328 pattern R8I = 33329 pattern R8UI = 33330 pattern R16I = 33331 pattern R16UI = 33332 pattern R32I = 33333 pattern R32UI = 33334 pattern RG8I = 33335 pattern RG8UI = 33336 pattern RG16I = 33337 pattern RG16UI = 33338 pattern RG32I = 33339 pattern RG32UI = 33340 pattern VERTEX_ARRAY_BINDING = 34229 pattern R8_SNORM = 36756 pattern RG8_SNORM = 36757 pattern RGB8_SNORM = 36758 pattern RGBA8_SNORM = 36759 pattern SIGNED_NORMALIZED = 36764 pattern PRIMITIVE_RESTART_FIXED_INDEX = 36201 pattern COPY_READ_BUFFER = 36662 pattern COPY_WRITE_BUFFER = 36663 pattern COPY_READ_BUFFER_BINDING = 36662 pattern COPY_WRITE_BUFFER_BINDING = 36663 pattern UNIFORM_BUFFER = 35345 pattern UNIFORM_BUFFER_BINDING = 35368 pattern UNIFORM_BUFFER_START = 35369 pattern UNIFORM_BUFFER_SIZE = 35370 pattern MAX_VERTEX_UNIFORM_BLOCKS = 35371 pattern MAX_FRAGMENT_UNIFORM_BLOCKS = 35373 pattern MAX_COMBINED_UNIFORM_BLOCKS = 35374 pattern MAX_UNIFORM_BUFFER_BINDINGS = 35375 pattern MAX_UNIFORM_BLOCK_SIZE = 35376 pattern MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 35377 pattern MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 35379 pattern UNIFORM_BUFFER_OFFSET_ALIGNMENT = 35380 pattern ACTIVE_UNIFORM_BLOCKS = 35382 pattern UNIFORM_TYPE = 35383 pattern UNIFORM_SIZE = 35384 pattern UNIFORM_BLOCK_INDEX = 35386 pattern UNIFORM_OFFSET = 35387 pattern UNIFORM_ARRAY_STRIDE = 35388 pattern UNIFORM_MATRIX_STRIDE = 35389 pattern UNIFORM_IS_ROW_MAJOR = 35390 pattern UNIFORM_BLOCK_BINDING = 35391 pattern UNIFORM_BLOCK_DATA_SIZE = 35392 pattern UNIFORM_BLOCK_ACTIVE_UNIFORMS = 35394 pattern UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 35395 pattern UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 35396 pattern UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 35398 pattern INVALID_INDEX = 4294967295 pattern MAX_VERTEX_OUTPUT_COMPONENTS = 37154 pattern MAX_FRAGMENT_INPUT_COMPONENTS = 37157 pattern MAX_SERVER_WAIT_TIMEOUT = 37137 pattern OBJECT_TYPE = 37138 pattern SYNC_CONDITION = 37139 pattern SYNC_STATUS = 37140 pattern SYNC_FLAGS = 37141 pattern SYNC_FENCE = 37142 pattern SYNC_GPU_COMMANDS_COMPLETE = 37143 pattern UNSIGNALED = 37144 pattern SIGNALED = 37145 pattern ALREADY_SIGNALED = 37146 pattern TIMEOUT_EXPIRED = 37147 pattern CONDITION_SATISFIED = 37148 pattern WAIT_FAILED = 37149 pattern SYNC_FLUSH_COMMANDS_BIT = 1 pattern VERTEX_ATTRIB_ARRAY_DIVISOR = 35070 pattern ANY_SAMPLES_PASSED = 35887 pattern ANY_SAMPLES_PASSED_CONSERVATIVE = 36202 pattern SAMPLER_BINDING = 35097 pattern RGB10_A2UI = 36975 pattern TEXTURE_SWIZZLE_R = 36418 pattern TEXTURE_SWIZZLE_G = 36419 pattern TEXTURE_SWIZZLE_B = 36420 pattern TEXTURE_SWIZZLE_A = 36421 pattern GREEN = 6404 pattern BLUE = 6405 pattern INT_2_10_10_10_REV = 36255 pattern TRANSFORM_FEEDBACK = 36386 pattern TRANSFORM_FEEDBACK_PAUSED = 36387 pattern TRANSFORM_FEEDBACK_ACTIVE = 36388 pattern TRANSFORM_FEEDBACK_BINDING = 36389 pattern COMPRESSED_R11_EAC = 37488 pattern COMPRESSED_SIGNED_R11_EAC = 37489 pattern COMPRESSED_RG11_EAC = 37490 pattern COMPRESSED_SIGNED_RG11_EAC = 37491 pattern COMPRESSED_RGB8_ETC2 = 37492 pattern COMPRESSED_SRGB8_ETC2 = 37493 pattern COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 37494 pattern COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 37495 pattern COMPRESSED_RGBA8_ETC2_EAC = 37496 pattern COMPRESSED_SRGB8_ALPHA8_ETC2_EAC = 37497 pattern TEXTURE_IMMUTABLE_FORMAT = 37167 pattern MAX_ELEMENT_INDEX = 36203 pattern NUM_SAMPLE_COUNTS = 37760 pattern TEXTURE_IMMUTABLE_LEVELS = 33503 pattern VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE = 35070 pattern TIMEOUT_IGNORED = 18446744073709551615
{ "redpajama_set_name": "RedPajamaGithub" }
9,471
{"url":"https:\/\/mammothmemory.net\/maths\/maths-basics\/maths-vocabulary-and-expressions\/isosceles.html","text":"# Isosceles\n\nA triangle in which two sides have the same length.\n\nRemember to spell isosceles with an SOS in the word.\n\nI sock em in these\u00a0(isosceles) (in of a\u00a0pair\u00a0of socks the\u00a0same length) but I need to send out an SOS for another pair of socks (spelt with an SOS).\n\nExamples\n\nAn isosceles triangle with two sides same length giving two angles at 50\u00b0 and one at 80\u00b0.\n\nAn isosceles triangle with two sides same length giving two angles at 65\u00b0 and one at 50\u00b0.\n\nAn isosceles triangle with two sides same length giving two angles at 59\u00b0 and one at 62\u00b0.\n\nA\u00a0right angled\u00a0triangle can be an\u00a0isosceles\u00a0as long as two of the sides are the same length.\n\nA triangle with two angles the same will be an\u00a0isosceles\u00a0triangle.\n\nNOTE:\n\nIsosceles triangles have two internal angles that are the same and one which is different.","date":"2020-09-25 07:11:28","metadata":"{\"extraction_info\": {\"found_math\": false, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 0, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.8632991313934326, \"perplexity\": 802.3826891915099}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2020-40\/segments\/1600400222515.48\/warc\/CC-MAIN-20200925053037-20200925083037-00794.warc.gz\"}"}
null
null
package org.springframework.boot.autoconfigure.velocity; import java.io.File; import java.io.StringWriter; import java.util.Locale; import javax.servlet.http.HttpServletRequest; import org.apache.velocity.Template; import org.apache.velocity.VelocityContext; import org.apache.velocity.app.VelocityEngine; import org.junit.After; import org.junit.Before; import org.junit.Rule; import org.junit.Test; import org.springframework.boot.test.EnvironmentTestUtils; import org.springframework.boot.test.OutputCapture; import org.springframework.boot.web.servlet.view.velocity.EmbeddedVelocityViewResolver; import org.springframework.context.annotation.AnnotationConfigApplicationContext; import org.springframework.mock.web.MockHttpServletRequest; import org.springframework.mock.web.MockHttpServletResponse; import org.springframework.mock.web.MockServletContext; import org.springframework.test.util.ReflectionTestUtils; import org.springframework.web.context.support.AnnotationConfigWebApplicationContext; import org.springframework.web.servlet.View; import org.springframework.web.servlet.resource.ResourceUrlEncodingFilter; import org.springframework.web.servlet.support.RequestContext; import org.springframework.web.servlet.view.AbstractTemplateViewResolver; import org.springframework.web.servlet.view.velocity.VelocityConfigurer; import org.springframework.web.servlet.view.velocity.VelocityViewResolver; import static org.hamcrest.Matchers.containsString; import static org.hamcrest.Matchers.equalTo; import static org.hamcrest.Matchers.instanceOf; import static org.hamcrest.Matchers.is; import static org.hamcrest.Matchers.notNullValue; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertThat; /** * Tests for {@link VelocityAutoConfiguration}. * * @author Andy Wilkinson * @author Stephane Nicoll */ public class VelocityAutoConfigurationTests { @Rule public OutputCapture output = new OutputCapture(); private AnnotationConfigWebApplicationContext context = new AnnotationConfigWebApplicationContext(); @Before public void setupContext() { this.context.setServletContext(new MockServletContext()); } @After public void close() { if (this.context != null) { this.context.close(); } } @Test public void defaultConfiguration() { registerAndRefreshContext(); assertThat(this.context.getBean(VelocityViewResolver.class), notNullValue()); assertThat(this.context.getBean(VelocityConfigurer.class), notNullValue()); } @Test public void nonExistentTemplateLocation() { registerAndRefreshContext( "spring.velocity.resourceLoaderPath:" + "classpath:/does-not-exist/"); this.output.expect(containsString("Cannot find template location")); } @Test public void emptyTemplateLocation() { new File("target/test-classes/templates/empty-directory").mkdir(); registerAndRefreshContext("spring.velocity.resourceLoaderPath:" + "classpath:/templates/empty-directory/"); } @Test public void defaultViewResolution() throws Exception { registerAndRefreshContext(); MockHttpServletResponse response = render("home"); String result = response.getContentAsString(); assertThat(result, containsString("home")); assertThat(response.getContentType(), equalTo("text/html;charset=UTF-8")); } @Test public void customContentType() throws Exception { registerAndRefreshContext("spring.velocity.contentType:application/json"); MockHttpServletResponse response = render("home"); String result = response.getContentAsString(); assertThat(result, containsString("home")); assertThat(response.getContentType(), equalTo("application/json;charset=UTF-8")); } @Test public void customCharset() throws Exception { registerAndRefreshContext("spring.velocity.charset:ISO-8859-1"); assertThat(this.context.getBean(VelocityConfigurer.class).getVelocityEngine() .getProperty("input.encoding"), equalTo((Object) "ISO-8859-1")); } @Test public void customPrefix() throws Exception { registerAndRefreshContext("spring.velocity.prefix:prefix/"); MockHttpServletResponse response = render("prefixed"); String result = response.getContentAsString(); assertThat(result, containsString("prefixed")); } @Test public void customSuffix() throws Exception { registerAndRefreshContext("spring.velocity.suffix:.freemarker"); MockHttpServletResponse response = render("suffixed"); String result = response.getContentAsString(); assertThat(result, containsString("suffixed")); } @Test public void customTemplateLoaderPath() throws Exception { registerAndRefreshContext( "spring.velocity.resourceLoaderPath:classpath:/custom-templates/"); MockHttpServletResponse response = render("custom"); String result = response.getContentAsString(); assertThat(result, containsString("custom")); } @Test public void disableCache() { registerAndRefreshContext("spring.velocity.cache:false"); assertThat(this.context.getBean(VelocityViewResolver.class).getCacheLimit(), equalTo(0)); } @Test public void customVelocitySettings() { registerAndRefreshContext( "spring.velocity.properties.directive.parse.max.depth:10"); assertThat( this.context.getBean(VelocityConfigurer.class).getVelocityEngine() .getProperty("directive.parse.max.depth"), equalTo((Object) "10")); } @Test public void renderTemplate() throws Exception { registerAndRefreshContext(); VelocityConfigurer velocity = this.context.getBean(VelocityConfigurer.class); StringWriter writer = new StringWriter(); Template template = velocity.getVelocityEngine().getTemplate("message.vm"); template.process(); VelocityContext velocityContext = new VelocityContext(); velocityContext.put("greeting", "Hello World"); template.merge(velocityContext, writer); assertThat(writer.toString(), containsString("Hello World")); } @Test public void renderNonWebAppTemplate() throws Exception { AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext( VelocityAutoConfiguration.class); try { VelocityEngine velocity = context.getBean(VelocityEngine.class); StringWriter writer = new StringWriter(); Template template = velocity.getTemplate("message.vm"); template.process(); VelocityContext velocityContext = new VelocityContext(); velocityContext.put("greeting", "Hello World"); template.merge(velocityContext, writer); assertThat(writer.toString(), containsString("Hello World")); } finally { context.close(); } } @Test public void usesEmbeddedVelocityViewResolver() { registerAndRefreshContext("spring.velocity.toolbox:/toolbox.xml"); VelocityViewResolver resolver = this.context.getBean(VelocityViewResolver.class); assertThat(resolver, instanceOf(EmbeddedVelocityViewResolver.class)); } @Test public void registerResourceHandlingFilterDisabledByDefault() throws Exception { registerAndRefreshContext(); assertEquals(0, this.context.getBeansOfType(ResourceUrlEncodingFilter.class).size()); } @Test public void registerResourceHandlingFilterOnlyIfResourceChainIsEnabled() throws Exception { registerAndRefreshContext("spring.resources.chain.enabled:true"); assertNotNull(this.context.getBean(ResourceUrlEncodingFilter.class)); } @Test public void allowSessionOverride() { registerAndRefreshContext("spring.velocity.allow-session-override:true"); AbstractTemplateViewResolver viewResolver = this.context .getBean(VelocityViewResolver.class); assertThat((Boolean) ReflectionTestUtils.getField(viewResolver, "allowSessionOverride"), is(true)); } private void registerAndRefreshContext(String... env) { EnvironmentTestUtils.addEnvironment(this.context, env); this.context.register(VelocityAutoConfiguration.class); this.context.refresh(); } public String getGreeting() { return "Hello World"; } private MockHttpServletResponse render(String viewName) throws Exception { VelocityViewResolver resolver = this.context.getBean(VelocityViewResolver.class); View view = resolver.resolveViewName(viewName, Locale.UK); assertThat(view, notNullValue()); HttpServletRequest request = new MockHttpServletRequest(); request.setAttribute(RequestContext.WEB_APPLICATION_CONTEXT_ATTRIBUTE, this.context); MockHttpServletResponse response = new MockHttpServletResponse(); view.render(null, request, response); return response; } }
{ "redpajama_set_name": "RedPajamaGithub" }
1,224
Belposto is sourced from a variety of Italian winemaking regions. The new wines showcase prominent varietals from Chile and Argentina. The Terroir Series falls in the super-premium tier. Ride share services like Uber and Lyft have brought high rewards for the on-premise. The new red blend is aged in Bourbon barrels. MillerCoors' Tenth and Blake unit is an incubator for emerging beer brands.
{ "redpajama_set_name": "RedPajamaC4" }
4,604
{"url":"https:\/\/meta.mathoverflow.net\/questions\/2651\/how-to-correct-an-erroneous-edit","text":"# how to correct an erroneous edit\n\n\"Black adder\" edited my answer to a question asking for a proof of noether normalization. the edit was nicely done, except in the next to last sentence a change was made from \"\u2264 d\" to \"less than d\", which introduces an error. I do not know how to either fix it or message the editor of the question. Or perhaps, in some languages \"less than\" means \u2264?\n\n\u2022 You must mean here: mathoverflow.net\/a\/92434\/2926 I fixed it for you, but please check. (BlackAdder evidently meant to be helpful and also asked in the edit summary to check that no errors were introduced in his\/her edit.) \u2013\u00a0Todd Trimble Dec 15 '15 at 17:16\n\u2022 I see now however someone has also edited the original question until it is nonsense when combined with my answer! I.e. Miles Reid wrote two books, one with a difficult proof of NN, his commutative algebra book, and another one with an easier proof, his UAG book. The original question complained about the one in the algebra book. The answer I gave is the easier proof in the geometry book. So now the question and answer are rather puzzling! I.e. I now seem to be providing the same argument that was objected to! subsequent editing poses an interesting challenge to historical accuracy. \u2013\u00a0roy smith Dec 15 '15 at 17:34\n\u2022 There was no recent edit, and all edits after the original were minor typo corrections. Evidently your answer was helpful anyway even if you think you merely reproduced Reid's UAG proof, so maybe different words were all it took. The OP by the way seems to have a deleted account and I don't think will be returning, so all puzzlement aside, let's let the answer stand. Your efforts were and are appreciated. :-) \u2013\u00a0Todd Trimble Dec 15 '15 at 17:43\n\u2022 I am not sure what you refer to. The question was not edited at all after you gave the answer. All edits happened before and in any case they seem minimal. All version of every post are available in the revision history I mentioned [except in very very rare cases, or when only present for less than five minutes]. For the specific case see: mathoverflow.net\/posts\/92354\/revisions \u2013\u00a0user9072 Dec 15 '15 at 17:43\n\u2022 you are right. i misread the date of the last edit of the question. now i am puzzled as to how my answer helped. perhaps as you say, just the fact my notes were written to be especially clear to my class helped. \u2013\u00a0roy smith Dec 15 '15 at 17:57\n\n## 1 Answer\n\nTo make a minor fix to an edit that took effect one proceeds as for a general edit of the post, that is one selects \"edit\" just below the post, makes the necessary change, and saves it.\n\nIt is possible to message editors of a post using the usual @user-syntax for comments; that is one writes a comment starting (or at least containing) @username where username is the the editor's displayname (without space). In fact, it suffices to use the first three (or more) characters too, but it needs to be the start of the displayname, so I could notify you with @roy or @roysmith or @roysm yet not with @smith).\n\nFor completeness let me add it is also possible to undo an edit completely. To this end go to the revision history of the post (clicking the timestamp in the middle at the end of the post; note if the post was not edited it is not there so for example on this meta post it is not present [indeed on your meta-post it is meanwhile present]). There you see all old versions. Look for the one you want to go to and click \"rollback\" there.\n\n\u2022 I thought there was a lower bound on the amount of changes the system accepts as an edit. If so, just fixing $<$ to $\\le$ may well be impossible. \u2013\u00a0Emil Je\u0159\u00e1bek Dec 16 '15 at 9:36\n\u2022 There is only a lower bound for suggested edits, not for edits. Thus, a user wishing to correct an edit to their post will never face any restriction of this form. (A third user without the edit-privilege indeed might face this problem, but there is no difference between fixing an edit and any other minor edit, which was the information I meant to convey.) \u2013\u00a0user9072 Dec 16 '15 at 10:21\n\u2022 All right, I stand corrected. \u2013\u00a0Emil Je\u0159\u00e1bek Dec 16 '15 at 10:56","date":"2020-06-05 16:50:21","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.7861886024475098, \"perplexity\": 851.1793361244571}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": false}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2020-24\/segments\/1590348502097.77\/warc\/CC-MAIN-20200605143036-20200605173036-00515.warc.gz\"}"}
null
null
St. Dominic Catholic Elementary School menu We will achieve our school vision within a collaborative faith-based learning environment where children are challenged with innovative and authintic inquiry-based tasks that nohor their individual needs. The St. Dominic community strives to develop positive engaging relationships that encourage students to become reflective global citizens. Parish Information: Parish Name - St. Dominic Savio Parish Parish Website - http://stdominicsavio.ca/ Sacramental Preparation: St. Dominic School is happy to work in partnership with St. Dominic Savio Parish and other schools in our St. Dominic Family to support parents and children in preparing for the Sacraments of First Reconciliation and First Communion. Information regarding Sacramental Preparation Sessions Religious Education: All of the Schools in the Edmonton Catholic School District use a Religious Education Program that is prescribed by our Alberta Bishops and provided through the National Office for Religious Education in Ottawa. The Program ranges from Kindergarten to Grade Twelve, and offers students with an overview of our Catholic faith as well as grade specific themes. Our School Namesake: St. Dominic Our school is named after St. Dominic. Dominic Savio was born in Italy in 1842. Dominic became a student of John Bosco in a home for neglected boys. One of the objectives of the home was to find candidates for the priesthood, a call Dominic felt as a young man. Although he was only a boy, Dominic lived a very full life dedicated to helping others. He was known for his cheerfulness, friendliness, and good advice. At an early age, Dominic organized a group of people called the Company of the Immaculate Conception to help John Bosco. Dominic's group was very poor, but they worked tirelessly to help make John Bosco's work a success. At the age of fifteen, Dominic developed tuberculosis, and died. During his life, Dominic wrote letters to his friends about his joy in helping poor and homeless children. He described how he and his group carried out their duties in a positive manner, and always tried to do their best. Sharing his joy with others was a major focus in Dominic's young life. Pope John XXIII said that Dominic Savio has a message for everyone. It applies equally to children, young people and adults. It is a message of goodness and simplicity of life. Saint Dominic is a model for young people who want to help others. All celebrations can be found on the Calendar.
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
7,523
Table of Contents Title Page Copyright Page CHAPTER I - The Mysterious Dancer CHAPTER II - A Startling Call CHAPTER III - An Enlightening Scene CHAPTER IV - Stage Gossip CHAPTER V - Moonlight Sleuthing CHAPTER VI - The Witch CHAPTER VII - An Actress's Threat CHAPTER VIII - The Alarming Rehearsal CHAPTER IX - Shadowing CHAPTER X - An Excited Patron CHAPTER XI - The Incriminating Mark CHAPTER XII - Puppet Snatcher CHAPTER XIII - A Surprising Command CHAPTER XIV - Nancy's New Role CHAPTER XV - Curtain Call! CHAPTER XVI - Aliases CHAPTER XVII - The Chase CHAPTER XVIII - The Hollow Laugh CHAPTER XIX - A Puppeteer's Secret CHAPTER XX - An Amazing Revelation **THE CLUE OF THE DANCING PUPPET** WHEN the eerie performances of a life-size puppet begin to haunt the old Van Pelt estate, where an amateur acting group —the Footlighters—have their theater, Nancy Drew is called upon to unravel the baffling mystery. From the moment the pretty detective and her friends Bess and George arrive at the mansion, the dancing puppet puzzle is further complicated by Tammi Whitlock, the Footlighters' temperamental leading lady, and Emmet Calhoun a Shakespearean actor. Nancy's search of the mansion's dark, musty attic for clues to the weird mystery starts a frightening chain reaction. A phone call from a stranger with a witchlike, cackling voice warns her to "Get out !" Next, an encounter with two jewel theft suspects adds another perplexing angle to the puzzle. Finally, when Nancy sees the life-size puppet flitting across the moonlit lawn and chases it, she learns that someone with a sinister motive is determined to keep her from solving the case. Is it one of the Footlighters? Or is it an outsider? Unknowingly, Nancy places herself in even greater danger when she is persuaded to perform in the Footlighters' current show. As the young detective unravels the threads of this tangled mystery, Carolyn Keene fans will follow Nancy from clue to clue in spine-tingling excitement. _The puppet's left hand lowered menacingly_ Copyright **©** 1990, 1962 by Simon & Schuster, Inc. All rights reserved. Published by Grosset & Dunlap, Inc., a member of The Putnam & Grosset Group, New York. Published simultaneously in Canada. S.A. NANCY DREW MYSTERY STORIES® is a registered trademark of Simon & Schuster, Inc. GROSSET & DUNLAP is a trademark of Grosset & Dunlap, Inc. eISBN : 978-1-101-07740-5 2008 Printing <http://us.penguingroup.com> **CHAPTER I** _**The Mysterious Dancer**_ "I WONDER why Dad sent for me," Nancy said to Mr. Drew's pleasant secretary, as she waited in the outer room of his law offices. Miss Johnson smiled. "I would guess it's some kind of a mystery your father wants you to solve. He'll soon be finished with the client he has in there. Tell me, how are Bess and George?" Nancy, titian blond and attractive, chuckled. "At the moment Bess is—well, stage-struck. She has been reducing in order to get a part in one of the Footlighters' plays." "Oh, the amateur group," said Miss Johnson. "Yes. Bess belongs to it and has been trying to interest George and me," Nancy replied. "But I thought it might tie me down too much if a mystery came along for me to work on. And George has been busy playing in a series of tennis tournaments." George Fayne, a bright-eyed, athletic girl, and pretty Bess Marvin were cousins. They often found themselves involved in mysteries with Nancy Drew, who was their closest friend. At this moment Miss Johnson's desk phone buzzed. She picked it up. "Yes, Mr. Drew." The secretary turned to Nancy. "Your father wants you to come in and meet his client. He's an actor," she added. "An actor!" Nancy echoed, intrigued. She arose and entered her father's office. Mr. Drew kissed his daughter, then he said, "Nancy, I'd like to present Mr. Hamilton Spencer." Nancy shook hands with the tall, slender man. She guessed from his graying hair that he was about sixty years of age. His voice was deep and resonant, and he had a winning smile. "Mr. Spencer is a professional actor, Nancy," Mr. Drew went on. "He and his wife have been engaged by the Footlighters to coach their plays. I met Mr. and Mrs. Spencer when I was asked to draw up their contract." Nancy listened attentively, but she was sure this information was not the reason her father had asked her to come downtown. To Mr. Spencer, she said, "My friend Bess Marvin tells me the old Van Pelt estate, which was given to the Footlighters, is ideal for your performances." "Yes, it is," Mr. Spencer replied. "The first floor of the house is given over to offices and dressing rooms. Mrs. Spencer and I and a friend live on the second floor. The large hay barn is our theater." As he paused, looking at Mr. Drew, the lawyer smiled. "Please tell Nancy your story. Since she's an amateur detective, I think this mystery would intrigue her." Mr. Spencer reddened a bit, and Nancy sensed he was embarrassed to think that a girl of eighteen might solve a mystery which was baffling a man of his years and experience. "For several months after we moved to the Footlighters' new home," he began, "everything was peaceful. Then recently a strange occurrence has been repeated several times. I must confess it has my wife and me jittery. At night a life-size puppet in ballet costume has been seen dancing in various places—on the lawn, on the deserted stage, even on the flat roof of a shed." "It sounds fantastic," Nancy remarked. "Are you sure this isn't a real person?" "Indeed I am," Mr. Spencer answered. "I've been an actor for enough years to differentiate between live actors and artificial ones. I don't know how she is operated, but this dancer is a puppet all right—of the marionette type. What I want to know is, where does she come from and _why?"_ "Have you ever followed the puppet?" Nancy asked Mr. Spencer. "Oh, yes, twice. But before I could get near her, she disappeared. That ghostly dancer is getting me down. I can't sleep. Something has to be done!" Mr. Drew interrupted the actor, who was showing signs of becoming unnerved by his own recital. "Nancy, the Spencers feel that there must be something behind this strange performance—perhaps even some sinister plot against the Footlighters." Mr. Spencer nodded vigorously. "Common sense tells me there _must_ be. Nancy, would you be willing to come out to the estate and stay with us awhile? From what your father has told me, you might be able to bring about an end to this strange drama." Nancy turned to her father. "You know I'd love to go," she said. "Is it all right with you, Dad?" Mr. Drew smiled. "I'll give my consent on one condition—that Bess and George go with you. George Fayne, a girl, is Bess Marvin's cousin," he explained to Mr. Spencer. "My wife Margo and I would be very happy to have all three girls as our guests," Mr. Spencer said quickly. He rose to leave. "Nancy, will you ask your friends and phone me their answer this evening? And please don't disappoint me." As the actor put his hand on the doorknob, he said, "This whole thing must be kept very confidential." He snapped the fingers of his free hand. "I have it! Nancy and George must join the Footlighters. Then no one will question their reason for being around the estate." Mr. Spencer had barely left when Miss Johnson announced that another client was waiting. "I'll see him in a minute," Mr. Drew told her. Then he turned to Nancy. "Just one word of advice, young lady. Be careful! You know, you're the only detective I have!" Nancy laughed, kissed her father, and said, "See you at supper?" "Yes. And I'll be starved. Tell Hannah to prepare one of her super-duper dinners." Hannah Gruen was the pleasant, faithful housekeeper who had managed the Drew household and helped to rear Nancy since she was three. At that time Mrs. Drew had passed away from a sudden illness. As soon as Nancy reached home she phoned Bess and George, inviting them to supper and suggesting they come early, as she had something important to tell them. When they accepted, Nancy and Mrs. Gruen discussed the menu. "Let's cook the roast that's in the refrigerator," Nancy suggested. "And have strawberry shortcake for dessert with all the trimmings. Oh, I forgot. Bess is dieting. We'd better change that to apple snow pudding with thin custard sauce." Nancy offered to set the table and had just finished when the bell rang. Bess and George arrived together. George literally dragged Nancy into the living room. "Out with it! Something important's brewing!" she exclaimed. Nancy laughed, then told the story of the mysterious dancing puppet. George frowned, puzzled. Bess drew in a deep breath. She gave a mock shiver, then burst out: "How divine! Imagine living in the same house with a real actor and actress!" "And a supernatural one," George reminded her cousin. "But Nancy didn't say the dancing puppet came into the house," Bess argued. "The puppet may enter any time. She's already been in the theater," George teased. Nancy interrupted to ask, "Can you girls come with me? I promised to let Mr. Spencer know tonight." "Of course." "You bet." At once, Nancy called the actor, who was delighted. "We'll expect you tomorrow afternoon," he told her. "Margo and I don't brunch until one. We're late sleepers on account of the night shows." When Nancy returned, she told George about the plan to have them join the Footlighters. "Wonderful!" Bess exclaimed. "You'll love it. And, Nancy, you'll get a part right away. You often had the lead in the school plays." "No, thanks. I'm going to the estate to do some detective work. I'll sign up to help paint scenery." George grinned. "I couldn't recite a nursery rhyme. Put me down for odd jobs like scene shifting—my muscles are hard!" Bess went to the phone and called Janet Wood, the secretary of the Footlighters' membership committee. "There's to be a meeting tonight," said Janet, who was a good friend of Bess's. "I'll bring the application blanks to Nancy's house and wait while they fill them out. Then I'll hand the cards over to the committee tonight to be voted on. But Nancy and George will get in. Don't worry." Janet Wood arrived in half an hour. Nancy and George filled out the cards, and Bess and Janet acted as sponsors. "I'm thrilled that you're joining," said Janet, as she was leaving. "I'll call you tonight after the meeting." True to her promise, Janet phoned Bess at Nancy's house soon after ten. The one-sided conversation lasted a long while. Finally Bess returned to the living room. "You'll get formal notices in the mail," she said without enthusiasm. "But you're in." George snorted. "You seem about as happy over it as an actress who didn't pass her screen test." "I'm puzzled," Bess admitted. "Since you're new members, perhaps I shouldn't tell you. But because you're also detectives, I will." Bess revealed that the membership committee, including the president and Janet, consisted of seven men and women. One of them, Tammi Whitlock, had spoken very forcefully against admitting Nancy and George. "You don't know Tammi. She's rather new here in River Heights," Bess explained. "Been here about six months. Tammi came from California and is living in town with an aunt. She's our leading lady at the moment, and I must say she's an excellent actress." "But why would she vote against _us?"_ George queried. "I could see where she might not want any competition in the acting line, and she may have heard about Nancy's ability from the others. But of course Nancy didn't sign up for that. So why the big objection from Tammi?" Nancy had no comment other than to say she was eager to meet Tammi Whitlock and find out the reason for her objections, if possible. "There's a performance tomorrow night," Bess said. "We have only four a week. You can meet Tammi after the show. Well, let's get home, George. Shall we be ready to start about three o'clock tomorrow, Nancy? And will you pick us up in your convertible?" "Sure thing," Nancy promised, as she saw her friends to the door. Promptly at three o'clock the next day, Nancy picked up the girls, and Bess directed her along one of the tree-shaded roads on the outskirts of River Heights. Several old houses, set well back from the road, could be glimpsed through the heavy growth of trees and shrubbery. "Next driveway on your left," Bess said presently. At the entrance an artistic wooden plaque hanging from a tree announced: THE FOOTLIGHTERS The long, tree-lined driveway curved to the right, then to the left. Ahead, beyond a wide lawn, stood a large white three-story house of the early nineteen hundred period. The windows on the main floor were long, narrow, and shuttered. On the second floor, there were many bays and dormers, each with a carved arch above it. Nancy parked near the front porch, which extended across the front of the house, and the girls carried their bags into the wide center hall. Mr. Spencer, smiling broadly, came down the stairs and was introduced to George. "Mighty glad you're here," he said in welcome. "My wife is out, and I have to run over to the theater immediately. But I'll show you to your rooms first." He took Nancy's bag, telling the other girls he would come back for theirs. The steep stairway led to a long hallway on the second floor, with bedrooms on each side and a rear stairway down to the kitchen. "Margo and I have the front room," Mr. Spencer said. "You girls will have this one, which also faces the front, and the one opposite, which overlooks the rear gardens. This door"—he pointed to a third door in the center of the hall—"hides a stairway to the attic. I've never been up there"—his eyes twinkled—"but, Nancy, I'm sure that's one place you'll want to investigate." "There's one more door—at the end of the hall near the kitchen stairway," George remarked. "Is that where your friend sleeps?" "Yes. Emmet Calhoun is over at the theater right now. Well, make yourselves at home, girls. See you later." He left them. Nancy chose the rear bedroom, which gave her a good view of the playhouse. It was a large red barn with a smaller wing. To one side of the building was a wide parking area. The girls began to unpack their belongings. In a few minutes Nancy was settled. "I'm going to follow Mr. Spencer's hint and take a peek at the attic," she said to the others. She walked to the door, opened it, and ascended the steps. In the cousins' room, Bess giggled. "Nancy just can't wait to get started on her mystery. I'd like to have a little fun first." "Like doing what—playing hide-and-seek in the haymow?" George scoffed. At this moment the girls heard a loud thump in the attic. It was followed immediately by a second one. Bess and George ran to the attic stairway. "Nancy! Are you all right?" they called anxiously. There was no answer. **CHAPTER II** _**A Startling Call**_ "SOMETHING has happened to Nancy!" Bess exclaimed fearfully. George was already racing up the attic stairway. "I'm afraid so," she muttered. With Bess at her heels, George reached the large, cluttered attic. Three small windows, dusty and full of cobwebs, let in just enough light for the girls to see Nancy lying unconscious on the floor. They rushed to her side. "Oh, Nancy!" Bess wailed. George, who was more practical-minded, felt Nancy's pulse. "It's strong," she reported. "This is a temporary blackout. Nancy must have hit her head." Both girls looked around. Nearby lay a doll's trunk. It was upside down and spread open. Directly above it was a wide beam. "Maybe this trunk fell off the beam and hit Nancy," Bess suggested. "It doesn't look heavy enough to knock anyone out," George replied. "Bess, run downstairs and get some cold water and a towel." Bess hastened off on the first-aid errand and soon returned with the water. George bathed Nancy's forehead with the wet towel. In a few seconds the young detective opened her eyes. "Thank goodness you're all right," Bess said. "Do you know what hit you?" "N-no," Nancy answered weakly. "Whatever it was hit me from the back." George, sure that something heavier than the doll trunk had injured Nancy, was searching the attic floor. Not far from where her friend lay, she made a discovery. "Look!" she exclaimed. "A cannon ball! I guess this is what did it," she went on thoughtfully. "It's not covered with dust like everything else up here, so it must have been inside the trunk." Nancy sat up and smiled wryly. "I guess I'm lucky it only hit me a glancing blow." George was angry. "Whoever put a cannon ball in a doll's trunk must have been crazy!" Before she had time to go on with her tirade, the girls were startled to hear the stairs creak. "Sh-h," Nancy warned in a whisper. "Let's see who's coming up." To their astonishment no one appeared. "Someone was eavesdropping," Nancy said. She rose and hurried to the stairway. Seeing no one, she descended quickly, with Bess and George following. Nobody was in sight on the second floor. "Bess, run down the front stairway and find out if anyone is around," George ordered. "I'll take the back stairs. Nancy, _you'd_ better take it easy." Nancy needed no second urging. She was feeling very dizzy and went to lie down on her bed. Bess and George returned in a few minutes to report that no one seemed to be in the house. "Old houses are sometimes squeaky," George remarked. "Maybe no one was on the stairs after all." At this moment she looked at Nancy, who was very white. Worried, George recommended that they call a doctor. Nancy tried to protest, but was overruled. "Where's the phone?" George asked Bess. "I don't know," Bess said. "Anyway, I think I should go and get Mr. and Mrs. Spencer." She hurried off and in a few minutes returned with the couple. Margo Spencer, about forty years old, blond, and attractive, was extremely concerned about what had happened. She agreed that the Drews' family physician should be called. "Our phone is on a table in the lower hall," she said. "I guess you didn't notice it because I always keep a large bouquet of flowers there." George put in the call, then returned to the second floor. As she started down the hall, a man came up the rear stairway. He was tall, broad-shouldered, and had thick, curly, graying hair. His eyes were deep-set and penetrating. As he walked past Nancy's bedroom, Mr. Spencer called, "Hi, Cally old boy!" He turned to the three girls. "I'd like you to meet my friend Emmet Calhoun. Cally old boy is a Shakespearean actor. Right now he's looking for another show. Meanwhile, he's helping us coach." He gave Mr. Calhoun the details of Nancy's accident. "Most unfortunate!" the actor said dramatically. "Those beautiful eyes—they might have been closed forever!" Striking a dramatic pose, Cally old boy began to quote a Shakespearean verse: _" 'From women's eyes this doctrine I derive:_ _They sparkle still the right Promethean fire;_ _They are the books, the arts, the academes, That show, contain, and nourish all the world.'"_ "Thank you," said Nancy, smiling. Bess's eyes sparkled. "That's from _Love's Labour's Lost,_ isn't it?" she asked. Mr. Calhoun beamed. "Yes, it is, my dear. It is regrettable that most young people cannot quote from the Bard. We can learn so much from Shakespeare." Mrs. Spencer took the actor by the arm and went with him to the door. "Come, Cally," she said. "Let's leave the girls alone. Nancy should rest." The girls were a bit amused at her diplomacy. They saw at once that Cally old boy might easily become a bore! "Here comes the doctor," Bess said presently. She was glancing out the window at the parking lot. Doctor Black examined Nancy's head thoroughly, then said she would be all right in a few hours. "You are to eat nothing but broth and crackers, and rest for five or six hours," the doctor said sternly. Bess went to the kitchen, found some concentrated bouillon, and arranged Nancy's prescribed diet on a small tray. Soon after eating the soup, Nancy fell asleep. About ten o'clock that evening she awakened completely refreshed. Finding Bess and George in their room, she announced she would like to go over to the playhouse to see the rest of the show. Bess and George agreed, but paused to comb their hair first. Nancy waited a moment for them, then started ahead down the front stairway. As she reached the first floor, the phone rang. _"I'm the dancing puppet! Go away!" the caller_ _cackled in a witchlike tone_ "I'll answer it," she thought, and went over to the hall table. "Hello?" she said, just as Bess and George walked up to her. A woman's shrill voice asked, "Is Nancy Drew there?" "This is Nancy Drew speaking. Who is this?" The voice at the other end, obviously disguised, cried out loudly in a cackling, witchlike tone, "I'm the dancing puppet. If you know what's good for you, Nancy Drew, you'll leave me alone. Get out! Go away!" The speaker hung up. Nancy's expression had become one of complete amazement. When she relayed the message to Bess and George, they, too, looked stunned and worried. But in a moment all three girls regained their composure. "Who was it, do you suppose?" Bess asked. "Some girl who plays the part of the puppet?" Nancy shook her head. "Mr. Spencer assured me that the puppet is not alive." "It was probably the puppeteer," George guessed. "Perhaps," Nancy conceded. "Or it might just be someone playing a joke." "This is no joke, Nancy," Bess declared. "I think it is all part of a plot against either the Spencers or the Footlighters. Now that you're in the group, that unidentified woman is your enemy too!" "That might be," Nancy agreed. "And it is just possible that the doll trunk with the cannon ball in it didn't just fall off the beam above my head." Bess looked aghast. "You mean that someone sneaked up to the attic and deliberately knocked you out?" "I'm inclined to think so," Nancy said. "And I intend to find out who it was!" She asked the other girls if they knew whether or not there was a phone extension in the house which the "puppet" might have used. "Mr. Spencer didn't say," George answered. The girls searched but found none. Nancy suggested that perhaps there was an extension out in the theater, but she found that the phone in the theater was in a booth and had a different number from the one in the house. "There's no telling where that mysterious call was dialed from," she said. "The speaker might have been nearby, or at a distance." By this time Bess was thoroughly alarmed. Grabbing Nancy's arm, she looked at her and said, "We haven't been here one night yet, and awful things are happening! Nancy, the case isn't worth it. Let's do as that caller said. Let's leave!" **CHAPTER III** _**An Enlightening Scene**_ ALTHOUGH Bess pleaded, Nancy would not consent either to leave the Van Pelt estate or to give up trying to solve the mystery of the dancing puppet. Bess shrugged. "I suppose it's no use, but I admit I'm worried." She gave Nancy a searching look. "Probably you already have a hunch about this whole case." Nancy laughed. "A hunch, Bess, but not one good clue." Bess and George demanded to know what the hunch was. "It's possible there is hidden jealousy between the pros and certain of the amateurs," Nancy told them. In a whisper she added, "I think we should watch everybody. The Spencers seem like fine people, but there may be some angle not noticeable on the surface. One of the amateurs may be trying to drive the pros out of here. On the other hand, the pros may be trying to get control and turn the theater into an entirely professional one." Nancy suggested that the girls separate and each do some sleuthing. "Bess, suppose you keep an eye on Tammi. George, will you watch the comings and goings to the house? I'll wander around the theater." The girls agreed. As Nancy walked toward the big red barn, she told herself she would phone her father and have him look up the record of each of the pros. "Maybe I'd better ask him to do the same with the amateurs," she thought. When she entered the theater Nancy was amazed to see how well equipped it was. On the paneled walls hung lovely paintings by local amateur artists. The stage was spacious and the scenery attractive. The audience half filled the place. Nancy slid into a vacant seat in the last row and in a few moments became fascinated with the Civil War play in progress. Some time had passed before she reminded herself she had come to do some sleuthing. The acting had been so excellent and the play so interesting that she had completely forgotten her work. But suddenly Nancy felt too weary to do anything but sit still. "Anyway," she told herself, "the first logical bit of detective work might be just to watch the amateur performance closely." Presently the leading man, young Bob Simpson, walked on stage. He was about twenty years of age, very tall and dark, with darting, flirtatious eyes. After a short time, he was joined by Tammi Whitlock, who looked very attractive in her neat, trim bodice, long skirt, and ruffled silk bonnet. As Nancy watched the stage, something suddenly dawned on her. The characters were doing a love scene, which Bob Simpson was playing convincingly, yet still only as an actor. Tammi, on the other hand, was putting almost too much into the lines, and it became evident to Nancy that the leading lady was very much interested in the leading man. "I'm sure the feeling isn't mutual," Nancy decided, as the scene changed. The play ended soon afterward, and the amateur performers took many curtain calls before the extremely enthusiastic audience. Nancy made her way backstage. She was just in time to meet Bess, who whispered, "Wasn't Tammi _something_ in that love scene? She certainly overplayed it. I'm glad Bob didn't fall for it. I just don't care for that girl—and I don't think Mr. Spencer does, either." "What makes you say that?" Nancy asked eagerly. Bess reported that when the show was over, Tammi had _waylaid_ Bob and impishly repeated some of the lines from the love scene. Bob had reddened, but before he could reply, Mr. Spencer had marched up to Tammi. "Wow! Did he bawl her out!" Bess said. "He told Tammi she was making the performance seem like a grade school skit!" Nancy smiled as she and Bess walked back to the house. One by one the actors and actresses, having changed clothes and removed their make-up, appeared in the hall. Most of them went directly to the parking lot and left. Others remained to talk. Bob Simpson had been among the first to leave, possibly avoiding Tammi. Within half an hour everyone had left. Nancy and her friends got bottles of soda from the refrigerator and went up to Nancy's room. "Well, George," said Nancy, "what's your report?" "Nothing to do with the dancing puppet," George replied. "But I have a couple of other interesting items to tell you. There was a regular battle between Tammi and Mr. Spencer just before you girls came into the house. He said to her, 'Young woman, keep your personal feelings out of this theater!' " "And what did Tammi say?" Bess asked quickly. Her cousin grinned. "For a second I thought she was going to hit him, but all she said to Mr. Spencer was, 'And suppose you stay out of my personal affairs!' " Bess was thoughtful a moment, then said, "Nancy, it just might be that Tammi is a jealous person. I'm certain she has heard enough about you to be afraid you'd give her some competition with Bob Simpson, and that's why she didn't vote to have you join the Footlighters." George laughed. "Bess, don't ever tell that to Ned Nickerson," she said, referring to Nancy's special date. Nancy blushed a bit, then asked George what else had happened. "I don't know if this has any significance," George answered, "but during the performance, two of the actresses came out and went into a dressing room. Pretty soon I heard one of them crying." "Oh, what a shame!" Bess said sympathetically. "Did you find out why?" George said the one who was crying was a girl named Kathy Cromwell. "She's Tammi's understudy," Bess told the others. "But she has a part in this play," said Nancy. "And she's very good, too." "Yes, she is," Bess agreed. "But only in her own part. Every time she rehearses the lines of Tammi's part, she freezes or gets them mixed up. Poor Kathy! She's a sweet girl—not a bit like Tammi. In fact, quite shy, except on the stage." Nancy reminded George that she had not yet told them why Kathy was crying. "Did it have anything to do with Tammi?" she asked. "I don't know. It could have," George answered. "The only thing I heard her say was, 'I can't stand it another minute!' The girl who was with her said, 'Oh, Kathy, please—don't let her get you down!' " Bess's eyes flashed. "I'll bet anything they were talking about Tammi. Well, I'll keep my eyes and ears open next time I'm backstage." Nancy had already started to undress, since she had had a long and exciting day. Bess and George said good night and left her. She slept soundly and did not waken until eight o'clock the following morning. When she left her room to take a shower, Nancy discovered that the door to Bess and George's room was open. "They must be downstairs," she told herself. "I'll hurry." Nancy bathed and dressed quickly. She found her friends in the kitchen getting breakfast. Three good-mornings were said at once, and George added, "Ham and eggs?" "Umm—sounds perfect!" Nancy admitted. The three girls sat down at a large, round table in a bay window of the kitchen. They ate heartily, enjoying a few leisure minutes, then washed the dishes and put them away. "What's first on the agenda?" George asked Nancy. "I'd like to investigate the theater when no one's in it," Nancy answered. Bess offered to straighten up their rooms. "You girls go on ahead. I'll join you later," she said. George laughed. "You won't have to make that offer twice," she exclaimed. "I'll take sleuthing with Nancy any time to bedmaking!" The two girls stepped out to the kitchen stoop and walked underneath the covered arbor which led to a side door of the theater. The arbor was used by the actors to get back and forth to their dressing rooms. Grapevines climbed lazily over the trellis, giving the walk an artistic appearance. The barn door opened into one side of the stage, where scenery stood piled against the rear wall. The opening set of the current play was already in place. Curious, Nancy and George gazed about but saw nothing unusual. "Let's try the small barn," Nancy suggested. They went outside and walked over to a sliding door that opened into the attached building. Inside was a small floor area with stables to the right. On the left, where the building adjoined the stage was a loft filled with hay. Nancy's eyes fell on a ladder leading to the hayloft. "Maybe this place holds a clue to the mystery," she said hopefully. "Let's go up and see." George followed her, and together the girls began to probe the hay. Presently George cried out, "Nancy—I've hit something!" **CHAPTER IV** _**Stage Gossip**_ STUMBLING across the hay, Nancy wondered what George had located. "It's hard and heavy," George told her. Nancy helped her friend pull the hay aside. "If this thing had been hidden much deeper, it would have fallen between the mow poles to the floor below," George said. Finally the object was revealed. It proved to be a heavy wooden chest. "This is like lead!" George remarked. She tried to lift the lid of the box but failed. Nancy took a turn. She frowned. "There's no lock on this, but the box simply won't open." For several minutes the girls took turns trying to pry open the mysterious little chest, without success. Suddenly Nancy said, "This reminds me of a box I once saw in the River Heights Museum. The attendant there showed me how to open the secret lock." Deftly she felt along the back, pressing hard with one thumb. To her delight, she struck the right spot. The lid of the chest flew up! The two girls gazed within, then looked at each other completely astonished. The box contained two small cannon balls! "There is just space in here for a third one!" George exclaimed. "That third one must have been the very ball that hit you yesterday." "Which would seem to prove," Nancy added, "that somebody sneaked up with it to the attic when no one was in sight, and hurled it at me." The statement alarmed George. She began to look around fearfully and whispered, "Do you suppose anyone is hiding under the hay?" "We'll soon find out," said Nancy, getting up from her kneeling position. "Let's take a look." Once more the girls began kicking the hay that covered the entire loft. They found no one in hiding. "I suppose we should remove this chest before someone else can do any damage with its contents," suggested Nancy. But the two girls found the chest too heavy and awkward to carry. "Maybe it would be better if we get that cannon ball out of the attic and bring it here to see if it matches these," the young detective decided. "And if it does," George said, "we'll have one clue." She and Nancy hurried down the ladder and back to the house. Bess was amazed to hear what the girls had found and went with them to the attic. "Do you think the person who threw the cannon ball is also connected with the puppet mystery?" she asked Nancy. "I can't say," Nancy answered. "Not enough evidence to go on yet. By the way, let's not all face in the same direction in case another attacker is up here." George stood guard at the head of the stairway, while Bess kept a sharp lookout for anyone who might be lurking in the attic. Nancy searched for the cannon ball. "Why, it's gone!" she cried out. "Gone!" the others echoed. George added, "I guess the person who threw it is clever enough to remove any evidence against him." "You're right," Nancy agreed. "We'll really have to be on our toes to catch this culprit!" As the girls gathered at the top of the stairway, she added in a whisper, "I suggest we don't go back to the haymow now, but watch it tonight. We may learn more then." Nancy further suggested that the girls not tell the Spencers or anyone else what they had discovered so far. "I'd like to pick up more clues first," she said. By noontime the Spencers and Emmet Calhoun appeared, ready for brunch. Margo was vivacious and humorous, laughing about the way she kept house. "Everything out of a can or the freezer," she said. "Paper plates and cups on all occasions. A cleaning woman comes every other day," she explained. "Our hours are too uncertain for us to have a full-time maid." Nancy smiled. "You have a well-stocked refrigerator and pantry," she remarked. "Nobody should ever go hungry here." She fixed a tasty fruit salad, while Bess and George helped Margo warm tomato soup and broil hamburgers. Dessert was a cake from a River Heights bakery. Conversation during luncheon was confined exclusively to the activities of the theater. There was laughter and banter among the three professionals, and though the girls did not understand the many innuendoes that passed between the Spencers and Emmet Calhoun, they thoroughly enjoyed what Mr. Spencer called "backstage gossip." Cally old boy from time to time quoted from Shakespeare. Often he would rise from the table and speak with dramatic gestures. Once, when the conversation turned to the fact that this professional group was living on a former farm far removed from the Broadway theater atmosphere, he quoted: _" 'And this our life, exempt from public_ _haunt,_ _Finds tongues in trees, books in the_ _running brooks,_ _Sermons in stones, and good in every_ _thing.' "_ Bess's eyes had grown wide. How she wished she could act as dramatically as Emmet Calhoun! She told him this, adding, "I'm trying hard. Maybe someday I'll have a part in a play." The actor was enormously pleased by her flattering remark. "I suppose you girls know that quotation was from As You Like It," he said. Mr. Spencer laughed. "Don't coax Cally old boy to recite too much. I think he knows every line in every Shakespearean play, and if you don't watch out, he'll be reciting them _all_ to you!" When the meal was over, the girls offered to tidy up. Without hesitation Margo accepted. "I really should go into town and do some shopping," she said. "There's no performance tonight, you know, so that will give me time to finish my errands." "If you girls are looking for a job," Mr. Spencer added, "there is some scenery to be painted for our next production." "When is that show going on?" Bess asked. Secretly she was hoping she might be given a small part. "It's supposed to start week after next," the actor answered, "but things aren't going very well at rehearsals. I don't know what's the matter with the Footlighters. They're doing a pretty good job in the current play; but the one coming up—well, not one of the people chosen for the parts has caught on except Tammi Whitlock." "I watched her last night," Nancy spoke up, glad to hear more about the amateur actress. "I thought she did a marvelous job." "Oh, Tammi is talented, but she's too egotistical about her ability," Mr. Spencer said. "Besides, she's kind of a troublemaker. If she weren't so good, I wouldn't give her any part at all." "Troublemaker?" Nancy repeated, hoping to learn more. Mr. Spencer said she was not well liked by the other actors and actresses. "She tries to lord it over everybody," he explained, "and is sarcastic and unkind in her remarks to the people who do not learn so quickly as she does." Suddenly the girls realized that Margo was looking intently at Emmet Calhoun. She seemed to be telegraphing a message to him. Mr. Spencer, feeling perhaps that he had gone far enough in his confidences, stopped speaking abruptly. Margo arose from the table and Mr. Spencer and Cally old boy left the house. When the girls were alone, Bess said, "What did you make of all that, Nancy?" "You'll be surprised when I tell you," Nancy replied. "I have an idea Emmet Calhoun is very fond of Tammi Whitlock." "What on earth gave you that idea?" George asked. "A little signal that Cally old boy seemed to be getting from Margo. I thought Mr. Calhoun was going to come to Tammi's defense, but Margo seemed to be warning him not to." Bess sighed. "You're probably right, Nancy. But I'd like to bet that Tammi is no more interested in Cally old boy than I am." The three girls worked hard that afternoon on a large piece of scenery which was to represent a tree-surrounded lake with swans floating on it. Finally paint and brushes were put away. The girls ate their supper alone, and in a low voice Nancy told of a plan she had in mind. "Let's take my car and pretend we're going to town. We'll park it on the side road and then sneak back here to spy on the place." "You mean watch the hayloft?" George asked. "Yes, and," Nancy added with a chuckle, "we _may_ see the dancing puppet!" As soon as it was dark the three friends drove off. Nancy went about half a mile from the Van Pelt estate, then turned into a narrow dirt road. She pulled the car far over onto the shoulder, and turned off the lights. "Somebody is coming up in back of us," George remarked. "We'd better not get out until the car passes." The girls sat still. "Duck!" Nancy ordered. "We can't risk being seen!" They huddled together with their faces toward their knees. In a few seconds the oncoming car, instead of passing, rammed right into the convertible. There was a crash of glass! The three girls blacked out! **CHAPTER V** _**Moonlight Sleuthing**_ FOR SEVERAL seconds Nancy and her friends remained unconscious. The person who had rammed the convertible took advantage of the time. The car backed up, then whizzed ahead. Finally Nancy came to and raised herself up. The other car was out of sight. "Oh, my head!" she thought, knowing she had hit the steering wheel. Nevertheless, she turned her attention to Bess and George, who by this time also were sitting upright. "Are you hurt?" she asked. George said she was all right, except for a lump on her forehead where she had hit the dashboard. Bess rubbed the back of her neck. "I feel as if my head were on crooked," she said, trying to be cheerful. "How about you, Nancy?" George asked. "Do we go on sleuthing, or shall we give it up for tonight?" "I think we'd better give up the sleuthing—at least for now," Nancy replied. "I have a strong hunch that the person who ran into us did it on purpose. There was plenty of room to pass." George suggested that the driver might have been ill or sleepy. Nancy admitted this could be true. "In any case, I think the whole thing should be reported to Chief McGinnis." Bess and George nodded in agreement. Before driving off, the girls got out of the convertible and inspected the damage to the car. The rear bumper needed straightening, the trunk compartment was dented, and paint was chipped off in spots. "This is a sturdy bus," George commented. "That whack we got was enough to smash in the rear of most cars." Nancy patted the fender. "I'm pretty fond of this old convertible," she said, smiling. She drove directly to police headquarters in River Heights. To her delight, Chief McGinnis was there. When she reported to her old friend what had happened, the officer frowned. "I'll send an alarm out for that crazy driver at once," he said. The chief looked intently at Nancy. "Do you have some theory as to who it is?" "Nothing definite," the girl detective answered. "But I have a feeling that driver might have run into me on purpose—to keep me from working on a mystery I've become interested in." "Another mystery, eh?" the middle-aged, good-natured officer asked. He had great admiration for what Nancy already had accomplished, and often told her teasingly that he hoped someday she might become a detective on his force. "I guess this case may be another game between you and me to see who'll find the culprit first!" Since the chief's phone was ringing, Nancy had no chance to reply. She said a hurried good-by, and the girls left his office. Nancy drove directly to a garage in town which had twenty-four-hour service. The young man on night duty had attended high school with her. She and her father considered him an excellent mechanic and always brought their car work to him. "Hi, Joe!" Nancy called as she drove in. "Would you have time to straighten the rear bumper on this car? Somebody out on the road got frisky and rammed into me." Joe walked over and looked at the damage. "That's a shame, Nancy. I can straighten the bumper, but I wouldn't have time tonight to get out that dent, or do any painting." "Do what you can," Nancy told him. "How long do you think it will take?" "Oh, an hour, maybe." "Okay," said Nancy. "I'll go home in the meantime and pick up the car later. And, Joe—let me know if anyone brings in a car for headlight and fender repair, would you?" Joe nodded as the girls walked out of the garage. Nancy turned to Bess and George, saying, "We can pick up a snack at the house. I want to ask Dad to get a full report on the Spencers and Emmet Calhoun." The girls found Hannah Gruen preparing a meal for Mr. Drew, who had arrived home late and had not yet had supper. After an affectionate greeting for his daughter, and a hello to Bess and George, he asked, "Nancy, what's the bruise on your head from? And are you giving up your case so soon?" Nancy's eyes twinkled. "Why, Dad, I'm here because I just couldn't stay away from you. Besides, we girls are starving. Professional actors and actresses like the Spencers don't eat much, I guess, so I miss Hannah's cooking." Bess and George began to laugh, as they found both Mr. Drew and Mrs. Gruen taking the last part of Nancy's remarks seriously. "I'll get you a nice big dinner right away," the kindly housekeeper offered. "I'm afraid," said Nancy, "that you've caught me in a great big fib. We'll just have some cookies—or cake—and milk," she said. "What I really came home for was to ask you, Dad, to find out all you can about Mr. and Mrs. Spencer and a Shakespearean actor named Emmet Calhoun, who has been staying out at the Van Pelt estate and helping to coach the Footlighters." "I'll be happy to do that," the lawyer responded. "And now suppose you bring Hannah and me up to date on what has happened out at the Footlighters' theater." After the three girls had told the whole story, their listeners gaped in astonishment. "It sounds like a dangerous case," Hannah said worriedly. "Maybe too dangerous for you to continue, Nancy." "I must admit that things have happened unexpectedly," Nancy replied, "but I think that since I've been alerted, I'll avoid letting the unexpected happen again." Mr. Drew put an arm around his daughter's shoulder. "I'm afraid, my dear, trying to do that is asking for the impossible. But I beg of you, be careful." It was now his chance to do a little teasing. He turned to Bess and George. "I hereby appoint you guardians of one Nancy Drew, detective." "We accept the assignment," George and Bess said in unison, making low bows. Mr. Drew drove the girls back to the garage. When they reached it, they found that Joe had finished his work. Nancy thanked him for the quick service, paid him, and drove off. When the girls reached the parking lot of the Van Pelt estate, they were surprised to find that the mansion was in complete darkness. "I guess the Spencers figured we were not coming back tonight," Bess remarked, as she climbed out of the car. Then, as another thought struck her, she said worriedly, "Maybe everybody has gone away and we can't get in." "I have a surprise for you," Nancy said. "Margo Spencer gave me a key to the front door." "Thank goodness," said George. The girls let themselves in and went directly to their rooms. As Nancy was about to pull down the shades at her windows, she looked out onto the dark grounds. She noticed the moon was rising. "It will be quite light pretty soon," she told herself. "I think I'll go outdoors and look around for a while. Maybe the dancing puppet will perform." Nancy left her bedside light on. She picked up a flashlight and went downstairs. Noiselessly the girl detective made her way through the kitchen and let herself out the back door. By this time the moon had gone behind a cloud, but it was light enough for her to see the steps of the rear stoop. Nancy went outside the trellis to a clump of bushes where she intended to hide. From this vantage point she could see the lawn and the stage-door end of the trellis. As she walked around the dump of bushes, Nancy ran full tilt into a shadowy figure! "Oh!" she cried, startled. Nancy instantly clicked on her light and shone it into the other person's face. "Mr. Spencer!" "Nancy! Well, for Pete's sake," the actor said. "What's the big idea?" Nancy apologized and told him why she was there. Mr. Spencer chuckled. "We had the same idea," he confessed. "Let's watch together," Nancy suggested. "I'm hoping that as soon as these dark clouds pass and the moon lights up the lawn, we may see the puppet." It seemed an eternity to Nancy before the black cloud had moved away. But little by little the moon began to peep from behind it. In a few moments the scene was almost as bright as daylight. At the same instant, Nancy and Mr. Spencer heard running footsteps. Looking intently ahead, they saw a girl emerge from behind the barn theater. Recognition was impossible at this distance. The girl ran toward the road. "Shall we follow her?" Nancy asked excitedly. Mr. Spencer grabbed Nancy's arm. "Look!" he whispered tensely. "Over there, on the far side of the lawn!" Nancy's eyes popped wide in amazement. "It's the dancing puppet!" she gasped. **CHAPTER VI** _**The Witch**_ THE life-size puppet had come out of the stage-door entrance. It was dressed in a frilly ballet costume, and the blond hair was curly and dose cropped. "One thing is certain," Nancy told herself. "This is a puppet, not a live person." Mr. Spencer whispered, "Now is our chance to catch that thing!" He began to run toward the mysterious figure. Nancy followed and caught up to him. But before they had gone far, the dancing puppet jerked around suddenly and returned inside the door, which slammed shut. When Nancy and the actor reached it, they found the door locked. Mr. Spencer looked at her. "You see what I mean!" he cried excitedly. "It's supernatural! I tell you, this is a ghost with a brain!" "It certainly seems so," Nancy agreed. "How can we get into the theater?" Mr. Spencer said they would need a key but he had none with him. "I'll hurry to the house and get one," he said. "Are you afraid to wait here alone?" Nancy smiled. "Of course not, but do hurry!" The actor sped off across the lawn and into the kitchen. He was gone so long that Nancy felt precious time was being lost. Finally Mr. Spencer returned and unlocked the stage-door entrance. It was pitch dark inside. He snapped on lights. "Now where did that puppet go?" he asked, looking all around but seeing no sign of it. "How many other doors are there?" Nancy asked. "The only other one is the main entrance," Mr. Spencer told her. They walked through the theater to inspect it. "Locked!" Mr. Spencer said. "And bolted from the inside!" "Then no one came out this way," Nancy said thoughtfully. "And there are no windows—the theater is air-conditioned. Let's make a thorough search," she proposed. Nancy and Mr. Spencer looked in and behind every seat in the theater, back of all scenery, and in closets. The puppet was not there. Nancy was extremely puzzled. Aloud she said, "If I weren't so practical, I'd think that dancing figure evaporated into thin air." "Well," Mr. Spencer said, "we've lost our chance for tonight, I guess. We may as well go back to the house." On the way, he added, "I'm glad you saw the dancing puppet, Nancy. You know now that it wasn't a figment of my imagination." Nancy asked him if the strange apparition had ever caused any damage. "No," Mr. Spencer replied, "I can't say it has. What worries me most is that the story will leak out and people will be afraid to come to our performances." "A few might," Nancy answered. "But a good many people might come out of curiosity. However, the only times you've seen the dancing puppet are late at night. Isn't that true?" "Yes." "Then, if I had to guess why the puppet is here," Nancy said, "I'd say it's to scare you and your wife and Mr. Calhoun away from the property." As she prepared for bed, Nancy kept mulling this thought over in her mind. It was evident that somebody was back of the strange performance. But what was the reason? And why should anyone want to frighten people out of the house? Was there something hidden in the house? The following morning Nancy told Bess and George of her strange adventure and suggested that the three girls go back to the stage and hunt for a secret entrance to the attached barn. "You figure that's the only way the puppet could have been hidden from you?" George asked. "Yes." By ten o'clock Nancy and the cousins were standing on the empty stage gazing at the rear wall. Seeing no opening, they began shifting scenery to take a look. But they found no door or sliding panel. "Maybe there's an opening up higher," George suggested. "There might have been a ladder to it, which has been removed." One of the props for the current Civil War play was an old farm wagon. George climbed up into it and gazed above her head. Suddenly she called, "I think I've found the door!" The other girls climbed into the wagon and confirmed George's finding. Above them was indeed a door with an inconspicuous handle. "You think the person with the puppet went through there?" Bess asked. "How could anybody ? We can't even reach it from here." Nancy suggested that the person might have had an accomplice to help him. By standing in the hands of one man, the other, holding the puppet, could have been lifted up to the door. "Let's try that!" she proposed. She made a cup of her hands and lifted George high. George reached the door and opened it. "Goes into the haymow," she told the others. She pulled herself up into it. A moment later she said, "Here's the answer. A ladder!" She lowered it to the floor of the stage, and Nancy and Bess climbed up nimbly to join her. "Let's pull the ladder up and put it where George found it," Nancy proposed. "We don't want to leave any trace of our having been here." She and Bess hauled up the ladder, then Bess swung the door shut. The girls gazed around but saw no one. The puppet was not in evidence. "It's my guess the person escaped out of this barn and went off with the puppet," Bess spoke up. "You could be right," Nancy agreed. Then she added in a whisper, "But the puppet may be hidden here. Before we look, we'd better make sure no one's around." While Bess and George walked to the edge of the haymow and looked down, Nancy went back to see that the door to the stage was tightly closed. Suddenly the girls heard a deep voice intoning on the stage. The three stood electrified. The next moment they recognized the voice as that of Emmet Calhoun. Nancy opened the door as the actor began to quote from Shakespeare's _King Richard III._ _"'My conscience hath a thousand several_ _tongues,_ _And every tongue brings in a several tale,_ _And every tale condemns me for a_ _villain!' "_ Bess grabbed Nancy's arm. "He's the one!" she said. "His conscience is bothering him, and he's trying to get rid of his feeling this way!" "Sh!" George warned, as Cally old boy went on: _"'O **,** what may man within him hide,_ _Though angel on the outward side!' "_ Emmet Calhoun did not recite any more. He gazed around the stage, then went outside. "Wasn't that something!" George said, chuckling. Bess did not smile. "That's from _Measure for Measure,"_ she murmured. She looked at Nancy and asked, "Do you think he's involved in this mystery?" "It's a possibility," Nancy answered. "He is a strange person," she said. George suggested that the mystery might be some kind of a joke. Bess gave her a withering look. "Joke! Nancy gets knocked on the head and somebody runs into her car?" Nancy agreed with Bess. "One thing's sure," she said. "We'll need a lot more dues before we can decide anything." The girls made sure no one was hiding in the hay barn, then they began their hunt for the mysterious dancing puppet. "Let's each take a section of the hay," Nancy proposed. Bess and George chose the two far sides, while Nancy remained in the center. The three girls were silent as they scuffed through the loose hay and parted it with their hands. About five minutes later Nancy's foot kicked against a hard object. "Something here!" she sang out. The other girls rushed to her side, and together they unearthed the hidden object. "Another puppet!" Nancy exclaimed in amazement. "Bess, will you go stand near the ladder and tell me if anyone comes into the barn? Nobody must know that we've found this!" As Bess moved several feet away from the others, Nancy held up the life-size puppet. It was dressed in traditional witch clothes. "Who on earth hid this?" George cried out. The others could not answer her. Nancy instantly recalled the telephone call she had received on the day of their arrival—when the high-pitched, witchlike voice had claimed to be the dancing puppet. Now she wondered if the person who had called was the owner of this witch as well as the dancing puppet. _"Who on earth hid this?" George cried out_ Aloud Nancy said, "I believe we've discovered the hiding place for the ballet puppet, but we've come too late to find it." George had a sudden idea and rushed to the spot where the chest of cannon balls had been buried. They were gone! The girls looked at one another. "Now what?" Bess asked. **CHAPTER VII** _**An Actress's Threat**_ WITH deft fingers, Nancy was already examining the witch puppet. Carefully she removed each garment and laid it on the hay. Bess remarked, "It has a horrible face. What was the dancing puppet's face like, Nancy?" "I caught only a glimpse of it," Nancy replied, "but I think it was more girlish. This one, you notice, has a long, sharp nose." "Yes," George spoke up, and added, "I'll bet our detective is hunting for hidden springs or some other type of mechanism that makes this old lady work." Nancy admitted this. The puppet was well jointed to make it execute all kinds of movements. But it had no springs, rods, or levers with which to manipulate it. "There's no sign of an opening any place," Nancy remarked. She began to re-dress the figure. Bess kept peering over the edge of the haymow while George, from time to time, looked down through the open door to the stage to report if anyone appeared. No one did. Nancy, meanwhile, was mulling over the subject of the life-size puppets. Had they belonged to the Van Pelt family, or had they been brought here recently? If the latter, why? Finally she finished dressing the witch and hid it under the hay in the exact spot where she had found it. "We've searched this place pretty thoroughly," she said to her friends. "I think our next search should be in the attic of the house. There's a lot of stuff in that place we haven't examined yet." When the girls walked into the old mansion, they found that the Spencers were just starting brunch. They greeted the girls affably, and Margo added, _"How_ do you manage to get up so early in the morning? It would kill me!" Nancy chuckled. "Just habit, I guess," she answered. "You know it's said, 'The early bird catches the worm,' and I figure if I get out early enough in the morning, I may catch a villain or two!" The Spencers laughed, but before they had a chance to retort, Emmet Calhoun walked in. He was pounding his chest. "Nothing like a good morning constitutional," he said. "Now I'm ready for breakfast." Since there was no food for him on the table and he did not move toward the kitchen, Bess kindly offered to fix him some breakfast. He beamed and said he would help. But before he had a chance to follow Bess, Tammi Whitlock walked into the dining room. "Good morning, Tammi," the others greeted her, and Emmet Calhoun gave her a wide smile. Tammi scowled. "What's good about it?" she asked. "Well, I may as well tell you why I'm here. Mr. Spencer, I want to talk to you about the next play—the one that's in rehearsal now. You know as well as I do that everything's been going wrong. "That's because you won't take any advice. I know young people better than you do. If you don't listen to me, the show is going to be a real flop—and that will be the end of your job with the Footlighters!" Hamilton Spencer looked stunned. The young woman's impudence held him speechless for a moment. Tammi took advantage of the situation. With each utterance against him and the play, she became more dramatic, until she was fairly shrieking. Finally the actor rose from his chair and faced her, his eyes blazing: "Tammi Whitlock, I've told you before to keep your personal feelings and ideas out of this theater! I'm not afraid of losing my job. Don't forget that there must be a vote on the subject by the whole group. I admit the cast is not doing very well in the rehearsals, but your suggestions on how to run them are a lot of rubbish. Now I'll thank you not to bring up the subject again!" Nancy and George, embarrassed, escaped to the kitchen to help Bess. Emmet Calhoun, seated at a table there, was smiling as if thoroughly enjoying the whole thing. "I like people with fire," he said. "Tammi's beautiful when she's angry." The actor grinned. "Wish I could say the same for Hamilton Spencer." Calhoun rose in his chair, and folding his arms, quoted from Othello: _"'O! beware, my lord, of jealousy;_ _It is the green-eyed monster which doth_ _mock_ _The meat it feeds on.' "_ Suddenly George began to laugh, saying, "We don't have to go to the theater to see a good play. Just come to the Van Pelt house!" Her good humor seemed to break the tension that had risen. By this time Bess had managed to burn the toast and scorch the scrambled eggs. "I'm sorry," she said. "I'll make some more." Emmet Calhoun acted as if he had not heard her. He was gazing into the dining room where Tammi and Mr. Spencer were still battling. With Nancy and George helping, the Shakespearean actor's breakfast was ready in a jiffy. They served it to him, then dashed upstairs. "I think Tammi is perfectly horrid!" Bess burst out. "I don't see why they keep her in the Footlighters." "There's one very good reason," Nancy reminded her friend. "Tammi is an excellent actress—she has amateur status, but she performs as if she had had professional training." The three girls had just reached the stairway leading to the attic when Tammi Whitlock came hurrying up to the second floor. "Hold it!" she ordered. The girls turned in surprise. "Where are you going?" she asked. Nancy and the cousins remained silent. "Oh, don't act so smug," she said angrily. "Nancy Drew, I've heard you're a detective. That means there's a mystery around here, or you wouldn't be staying at the mansion." As Tammi paused, Nancy looked intently at her and said, "Go on." For a second Tammi seemed nonplused, but regaining her belligerent attitude, she said, "I have a right to know what the mystery is!" George looked at Tammi in disgust. "Assuming there is a mystery," she said, "just what gives you the right to know what it is?" "Right?" Tammi repeated. "Who has a better right? I'll have you know I'm the most important person in this amateur group! You and Nancy—and even Bess—are newcomers. And not one of you is an actress!" she added. Nancy had flushed, but she kept her temper. Bess was too flabbergasted to speak. But George was furious. "So you think you're so important?" she almost yelled at Tammi. "Well, you'd better look out or somebody will prick that bubble of conceit! You know how to recite lines and strut around the stage, but that's about it. You're a troublemaker with no respect for your elders. I could tell you a lot more, but I don't even want to talk to you. Better get out of here—and fast!" Tammi, stunned, glared at George. She started down the hall toward the front stairway. But over her shoulder she called back, "I have influence! I'll have all three of you put out of the Footlighters!" The girls dashed into the cousins' room and looked out the window. They saw Tammi flounce out of the house and drive off in her car. Nancy and George were ready to shrug off Tammi's threats, but Bess was worried. "You know Tammi might try to get rid of all of us," she said. "The Footlighters can't afford to lose their leading lady, so we three might have to go instead." Nancy had not thought of the problem this way. "If I were no longer a member of the Footlighters, I might have to leave the Van Pelt estate," she thought. "Then I wouldn't be able to solve the mystery of the dancing puppet!" Suddenly Bess's mood changed. "Say," she said, snapping her fingers, "I have an idea! Nancy, in school you were simply marvelous as the leading lady in plays. Poor Kathy is so scared of Tammi, she can't remember her lines as an understudy. But you could do it. Why don't you learn Tammi's lines in the present play? Then if things come to a showdown, you could take her place!" Nancy laughed. "I never could take Tammi's place," she said. "But I must admit I'm intrigued with the idea of learning her part. Listen, though, this must not be known to a soul but the three of us." The cousins agreed. Nancy, who learned lines quickly and easily, began to quote from the love scene in the play between Tammi and Bob Simpson. Using George as the leading man, she overplayed the part, rolling her eyes, and blowing him kisses with sighs loud enough to be heard on the first floor. Bess, meanwhile, was so convulsed with laughter that she had thrown herself on the bed and was rolling from side to side, tears streaming down her cheeks. "It's perfect! Absolutely perfect!" she said, dabbing her eyes. George, too, was roaring with laughter. Finally she said, "Nancy, if you ever get a chance to play the part and do that to Bob Simpson, I'm telling you, Ned Nickerson will scalp you!" "He sure would," Bess laughed. Nancy's tall, good-looking friend, who attended Emerson College, was now a summer counselor at a camp. Nancy grinned. "Enough play acting! Let's get on up to the attic!" she said. At this moment the girls heard a woman's loud and terrified scream from the first floor! **CHAPTER VIII** _**The Alarming Rehearsal**_ "WHO WAS that?" Bess exclaimed fearfully. Nancy and George did not wait to answer. The sound seemed to have come from the kitchen, so they raced down the back stairs. The girls found Margo Spencer standing in the middle of the floor, her hands over her face. "What happened?" Nancy asked her quickly. The actress looked at her wildly. "I saw a witch!" "A witch! Where?" George questioned. "Out there." Margo pointed toward the back stoop. "I heard a knock and opened the door. There stood the most horrible-looking witch!" "What did she say? What did she want?" George queried. Margo replied that she did not know. "I didn't give the witch a chance to say anything. I slammed the door and locked it." Nancy was across the floor in two seconds. She flung open the door. No one was on the stoop! She turned questioning eyes on Margo Spencer. "It was there! I saw it!" the actress declared. "I couldn't make up such a thing!" By this time her husband had hurried into the kitchen. The drama coach, obviously startled, asked why Margo had screamed. When told, he began to chide her. "How perfectly ridiculous! You're seeing things, my dear. Maybe you've been working too hard. Suppose you go up and take a nap. I'll manage the rehearsal alone." Margo Spencer turned a withering gaze on him. "I wasn't seeing things," she insisted. "Furthermore, you have no right to question my sanity!" "Now I know you've been overworking," her husband said gently. "I'm not questioning your sanity. We actors and actresses have great imaginations. To us, trees or bushes can take on fantastic shapes." Margo Spencer's eyes were darting fire. Nancy felt very uncomfortable standing there. With a sudden inspiration, she said: "Mr. Spencer, please let me tell you about something I discovered this morning in the hayloft. It may clarify the situation." The Spencers looked at her in astonishment. "How?" Margo asked. Nancy told how the hay had concealed the witch puppet. "It was well hidden and contained no strings or wires by which one might manipulate it. But it could lean against something. What you saw, Margo, might have been the witch puppet," she said kindly. "Was it standing by itself, or supported by a post?" The actress thought a moment. "It was leaning against a post," she replied. She turned to her husband. "Now do you believe me?" Mr. Spencer made sincere apologies and gave her a kiss and a hug. "I must go and look in the hayloft again," said Nancy. "It's just possible that the witch you saw, Margo, was not the one I found." The whole group trooped to the hay barn. No one was around. Nancy went up the wooden ladder to the loft and rummaged in the hay. "Our friend the witch is still here," she said. "Margo, will you come up and identify her?" Margo climbed the ladder, followed by her husband. By this time Nancy had uncovered the figure. "That's it!" Margo cried out. "Oh, she's so ugly! Hamilton, now do you blame me for screaming?" Mr. Spencer put an arm around his wife. "No, dear. I probably would have done the same thing." Conversation now turned to speculation on the identity of the person who had dared bring the figure to the stoop in broad daylight. "What do you think, Nancy?" Bess asked. Nancy laughed. "The only thing I know about him at this point is that he's fleet-footed," she replied. She and the others made a thorough search of the theater and the grounds but failed to find any trace of a suspect. The earth was too dry to show footprints plainly. Moreover, there had been so many people coming and going along the arbor walk that it would be impossible to distinguish the shoe prints of any one person. By the time the group had finished their hunt, several girl members of the Footlighters began to arrive for the rehearsal. When they had assembled in the front row of seats in the theater, Mr. Spencer came out on the stage. "Young ladies," he said, "I don't have to tell you that rehearsals haven't been going very well. I hope you took my last warning to heart and studied your lines carefully. I'll read the men's parts." After taking the roll call, he went on, "The girl who was to play the part of the maid has been called out of town for a few weeks. I am giving that part to someone else—Bess Marvin!" Bess gave a cry of delight, and Nancy and George congratulated her. Their elation was cut short by Hamilton Spencer, who said, "Everybody on stage!" The amateur actresses took their stations in the wings, and the rehearsal began. Bess, book in hand, came on, reading her lines as the maid. In a few moments, Margo Spencer clapped her hands. Bess stopped speaking. "Never turn your face away from the audience!" the actress told her. "And speak your lines distinctly!" George whispered in Nancy's ear, "I'll bet Bess's knees are shaking." Nancy nodded. "Maybe Bess is embarrassed because we're here. Let's go outside—where we can hear her but not be seen." They had just reached the front of the theater when Bess walked off stage. George grinned. _"That was a small_ part," she said. "If we'd closed our eyes we would have missed her. I wonder if my aspiring actress cousin will come on again!" She and Nancy went out the front door and circled around to the rear of the building, directly off the wing of the stage. There they collected the scenery still to be painted, and went to work. _From what the girls_ could hear through the open stage door, it was evident that the rehearsal was progressing badly. The young actresses could not remember their lines and were being prompted constantly. When they did remember them, Margo or Hamilton Spencer would tell them that they were putting no spirit into the parts. The only person on stage who seemed to be doing well was Tammi Whitlock. Nancy and George, despite their dislike of the girl personally, were spellbound by her performance. "Tammi's good. No doubt about it," said George. "Say," she added, as a sudden thought came to her, "do you think Tammi could have had anything to do with the witch scare?" Nancy _became thoughtful._ "She could have, I suppose, but I don't see any particular motive." "I wouldn't put anything past her," George declared. "Why, she might even be back of the dancing puppet business!" Nancy stared into space. George had a point! Yet Nancy felt that there was nothing to go on, so far, but a hunch. She smiled and said aloud, "My dad has always reminded me of the legal tradition, 'A man is presumed to be innocent until proved guilty.'" The conversation of the two girls was suddenly drowned out by a tirade from Hamilton Spencer aimed at the amateur actresses. "I'm about ready to give up," he exclaimed in exasperation. Then Margo began to talk also. "It's hopeless, absolutely hopeless," she declared. "I'd be ashamed to have the townspeople come to such a performance!" "The show will have to be postponed!" Hamilton Spencer announced. At this, Tammi flew into a rage. "You mean you'll close this theater for a couple of weeks? No, you won't! I'll see to it that you're out of here before that happens!" "Quiet!" Mr. Spencer ordered her. "You have an idea that the Footlighters cannot get along without you as leading lady in the play. Well, Tammi, you're greatly mistaken." By this time Nancy and George were peering through the doorway at the scene inside the theater. Most of the young performers looked as if they were ready to cry. Tammi stood on stage, her feet planted wide apart and her face red with anger. "You get rid of me and the whole show will fall apart!" she exclaimed. "If you're inferring that Kathy Cromwell can ever take my place, you're talking like a madman!" At this, Kathy, now seated again in the front row, began to sob. "Tammi is right," she said. "Oh, please, all of you, please stop the argument. I'm sure we can all do better. We promise to work hard. But Tammi must remain as our leading lady. I know I'm no good as an understudy. We'll just have to pray that nothing happens to Tammi, and then I'll never have to play her part." Kathy's pleading struck home. Her friends rallied around her. Tammi stood smug, but smiling. Finally Mr. Spencer said perhaps he had been too hard on the girls. "I get carried away sometimes, forgetting you're not professionals." He begged everyone to go home and concentrate on learning the lines and gestures as he had directed. The incident had whetted Nancy's appetite to learn Tammi's part, not for the forthcoming play, but for the one being currently produced several evenings a week. "Something _could_ happen to Tammi, and if Kathy can't take her place—well, I could try." When Bess left the theater, Nancy asked her to get a copy of the Civil War play. Nancy closeted herself in her bedroom, and by suppertime had mastered Tammi's lines in Act One. Coming from her room, she went across the hall to speak to George and Bess. "Let's drive back to my house to dinner," she said. "I want to hear what Dad has found out about the people here." Bess giggled. "You mean there's a chance we might have one of Hannah's marvelous dinners?" Bess loved to eat. Nancy chuckled. "We could, of course, but there's a certain young lady who's been asked to play a part in the new show. If she gained too many pounds, she might lose her chance." Bess considered this. Finally she said, "I won't eat dessert." Nancy telephoned Hannah Gruen. "How nice to have you girls come to dinner!" Hannah said enthusiastically. By the time they arrived, there was a delicious aroma of broiling steak, and macaroni and cheese coming from the kitchen. As the group ate, Mr. Drew reported that he had found the Spencers above suspicion. "They have a very fine reputation in the theatrical world." "And what about Emmet Calhoun?" Nancy asked. The lawyer shrugged. "So far, I have found out little about him. Seems to be a roving character. He may be harmless, but on the other hand he may not be. I suggest you keep an eye on him." Conversation turned to the girls' adventures since last night. Hannah Gruen was particularly interested in Tammi Whitlock. "She sounds like a Tartar," the housekeeper said. Then Mrs. Gruen chuckled. "I always understood that the best way to lose a boy is to chase after him!" "You ought to see how she acts," George said in disgust: "Tammi's so bold on stage and off that it makes me sick!" Bess kept her promise and ate none of the delicious strawberry shortcake. But she had asked to be excused from the table to avoid temptation, and was looking at a television program when the telephone rang. She answered the call and said it was for Nancy. "Hello," said Nancy, when she reached the phone. "This is Joe—down at the garage," the caller said excitedly. "Say, Nancy, can you come right down here?" **CHAPTER IX** _**Shadowing**_ "JOE, what happened?" Nancy asked the young mechanic. "I have something to show you," Joe told her. "It's important!" "I'll come right away," Nancy promised. _She returned_ to the dinner table and told the others about the message. Then Nancy, Bess, and George said good-by to Mr. Drew and Mrs. Gruen and hurried off to the garage. When they reached it, Joe led them to a car which he said had been brought in a short time before. "It needs front bumper and headlight work," he said significantly. "Nancy, maybe this belongs to the fellow you're looking for—the one who rammed into your convertible!" For several seconds Nancy, Bess, and George gazed at the damaged car, a late-model, black four-door sedan. Its bumper had been jammed back, and both headlights were broken. "If the man who ran into you," said George, "is the owner of this car, how in the world did he make his getaway without headlights?" Joe laughed. "When people are desperate, they'll take chances. This guy probably drove off in the darkness and hid his car some place until daylight." "I notice this car has California license plates," Nancy remarked. "Who is the owner?" "He gave his name as Owen Whipley," Joe replied. "And where is he staying?" Nancy prodded. Joe looked a bit sheepish. "He didn't say, and I didn't bother to ask. He told me he'd be back for the car in about three days. Oh, yes, he also said he was just passing through this area. Somebody got in his way, he said, and he swerved into a tree." "Of course his story could be true," Nancy said. "But I'm going to make two tests. First, I'll back up my car and see if our fenders are the same height from the ground." She did this, and they came together exactly. Next, she took a magnifying glass from the glove compartment of her convertible and trained it on the front of the black sedan. "Flecks of light-blue paint on here," she reported. "Joe, you take a look and see if you think they match the paint on my car." The garageman made a careful examination and confirmed Nancy's suspicion that this was the car which had run into her convertible on the lonely country road. "I'll call Chief McGinnis at once," Nancy said. "He'll probably send men here to take samples of the paint and give them a laboratory test. That's the only real way to be sure." The chief greeted Nancy with a warm hello. He listened attentively to her story, then said, "I'll dispatch two detectives at once to make an investigation." When the officers arrived they told Joe that he was not to permit the suspected car to leave the garage. "Drain all the fuel from it," one of them ordered, and this was done at once. "I guess we can't do any more now," Nancy said as the officers packed up their equipment preparatory to leaving. The three girls drove off and returned to the Van Pelt house. The evening's performance was still in progress, so they decided to go into the theater and watch it. Noiselessly the three friends slid into seats at the back and listened attentively. "Sounds pretty good," George remarked admiringly. Whenever Tammi Whitlock was on stage, Nancy watched her intently. Without moving her lips, Nancy repeated the lines after the actress. She wished she dared to imitate the other girl's gestures as well, but felt she should not do this for fear of being misunderstood. However, she scrutinized carefully each movement which Tammi made. "She's graceful and moves her body in rhythm with the meaning of the play, as a dancer does," Nancy thought. Presently Bess smiled. She leaned over and whispered to the girls, "Kathy's magnificent tonight. You know what I think? I think Bob Simpson likes her and she's thrilled at the attention he's paying her." George and Nancy nodded. Then George, with a low chuckle, whispered, "But watch out for fire-works from the leading lady when it dawns on her!" As the show was drawing to a close, Nancy turned to the cousins and said, "In connection with our mystery, I'd like to find out where each one of the actors and actresses goes after taking off the grease paint and changing out of costume." "Okay," said George. "What are Bess's and my assignments?" Nancy suggested that Bess hurry backstage and watch what went on there. "Maybe you'll hear some of them say where they're going." George was to cover the dressing rooms in the house. "I'll take the special section of the parking lot reserved for the Footlighters," Nancy concluded. As the entire cast was taking bows from the enthusiastic audience, the three girls hurried off to their posts. Nancy decided to keep out of sight, and hid behind a large truck which belonged to the Van Pelt estate. It was rarely used now and not likely to be moved at this time. As Nancy watched, she noticed that the first actors and actresses to leave the dressing rooms were young married couples. "They're probably going home," Nancy decided. Other performers came out alone or in couples. Among these was Kathy Cromwell, walking beside Bob Simpson. The two were laughing and looked very happy as they climbed into a station wagon and went off together. "Bess's hunch was right," Nancy thought. The last person to come out was Tammi, who went directly to her car. To Nancy's amazement, the leading lady seemed surprised to find a young man in the driver's seat. "Chuck!" Tammi hissed, then added angrily, "I told you not to come here! Suppose somebody sees you!" To Nancy's further amazement, the stranger behind the wheel said to Tammi icily, "Shut up and get in! Remember? We have a job to do!" As Tammi and her strange companion pulled away from the parking lot, Nancy came out of hiding. She was puzzled by the remarks between the couple. What kind of job did they have to do? Where were they going? Did it have anything to do with the mystery of the dancing puppet? "I have half a mind to follow them!" Nancy told herself. "But it might not be safe to go alone. Oh, dear, if only Bess or George would come out!" As if in answer to her wish, George appeared from the house. Instantly Nancy called to her, "Hurry! We haven't a moment to lose!" **CHAPTER X** _**An Excited Patron**_ GEORGE sprinted across the parking lot to the convertible. Nancy had already jumped into the driver's seat and started the car. Two seconds later the girls were on their way. Nancy sped out the driveway to the main road, then stopped. She looked left and right. In the distance to her left, she saw the taillights of a car and turned in that direction. As she sped up the road, George asked, "What's the mad rush for? I should know where I'm going!" Quickly Nancy told her chum of the conversation between Tammi and the unknown young man. George whistled. "I don't wonder you want to follow them. Sounds ominous, doesn't it?" The car ahead was making good time, but Nancy was able to keep it in view without any difficulty. It went on and on. Nancy did not say a word. But presently George spoke up. "We may travel for hours," she said. "Bess and the Spencers will wonder where we are." "If we stop to telephone," said Nancy, "we may lose Tammi." Just as she was wondering whether she should give up the chase and turn back, the car ahead turned into the grounds of a country restaurant. "'Green Acres,' " George read the sign aloud. Then she added, "This is a very exclusive place." "Which means we shouldn't go in without escorts—or money," Nancy said with a sigh. "If we don't," George answered, "how are we going to find out what the 'job' is?" "I'll park here near the end of the drive," Nancy decided. "Suppose you stay in the car so you can move it if necessary." "And what are you going to do?" George asked. "Scout around a little," Nancy replied. "As long as I've come this far I may as well find out what I can about the plans of Tammi and her escort!" As she walked toward the Green Acres Restaurant, Nancy admired the fine lines of the old colonial building. Once a home, it had been converted into a fashionable restaurant. It was white, with tall pillars at the entrance and heavily curtained windows. The grounds were beautifully planted. "It's a lovely place," Nancy thought. Seeing an attendant at the door, and wishing to avoid being questioned, she skirted the large wooden building. "Perhaps one of the curtains won't be drawn over the window and I can peer inside!" Nancy hoped. To her dismay, all views of the interior were completely blocked off. "Now what am I going to do?" the young sleuth asked herself. At this moment the dance band began to play, and in a few seconds a man started to sing. Nancy listened with pleasure, one foot tapping the pavement. "Nice voice," she thought. Just then a diner seated near one of the windows peered outside. For a few seconds he held one of the draperies open far enough for Nancy to get a good look at the interior of the dining room. At one side were the orchestra and the singer. Suddenly Nancy gasped. The singer was Tammi Whitlock's companion! The girl detective almost laughed aloud. So this was the job he had mentioned at the parking lot! "I've certainly come on a wild-goose chase," she told herself. Nancy was about to turn toward the driveway and rejoin George when another thought struck her. The singer who had spoken to Tammi so unpleasantly at the Van Pelt estate had said, _"We_ have a job to do!" What could Tammi's job be? "If she's singing here, then she's not an amateur," Nancy reflected. "And she has no right to be in the Footlighters!" Nancy decided to stay at the restaurant a little longer to see if Tammi did appear in some professional act, such as a monologue or skit. The young man stopped singing, but the band continued to play. "Maybe I should ask the door attendant about the performers," Nancy thought. As she moved from the side of the building toward the front entrance, she became aware of a sudden disturbance at the door. Two men rushed out and dashed toward one of the parked cars. "Hold on!" the door attendant said. "I'll get your car for you." The men paid no attention. A second later Nancy noticed a well-dressed, middle-aged woman also dash from the entrance. She was wearing a low-cut evening dress and gleaming emerald earrings and bracelets. Pointing ahead, the excited patron cried out, "Stop thieves! Stop thieves!" "She must mean those two men who ran out!" Nancy thought. They had already started their car and were backing around. Quick as lightning, Nancy dashed up the driveway, calling at the top of her voice, "George, block the driveway!" George obeyed orders instantly. She moved the convertible back so that it would be impossible for anyone to leave the grounds in a car. By this time Nancy, the woman who had been robbed, the attendant, and two other men were running after the suspects' car. When the men in it saw their escape blocked, the driver stopped short. "Get out of the way!" he yelled at George. "I can't," George replied, pretending that the car was stalled. "Good old George!" Nancy thought. In a few seconds the whole group was gathered at the entrance. The woman in the evening dress cried out to the men in the car, "You stole my emerald necklace!" The two suspects glared at her, and the driver said, "You're crazy! We don't know what you're talking about!" "You were right there at our table," the woman went on. "All of a sudden I noticed my necklace was gone. You _must_ have taken it!" One of the men who had joined in the chase said, "I'm James Burke, and this lady is my wife. If you're innocent, you won't object to a search." "We most certainly do," said the driver. "Nobody except the police can search us. I tell you, we don't know anything about a necklace." The man standing next to Mr. Burke introduced himself as the owner of the restaurant. "This is most regrettable, gentlemen," he said. "But as Mr. Burke has remarked, if you are innocent, then you will not mind being searched. This puts me in a very awkward position, which I am sure you understand. I hope you will co-operate." "There's no need for us to co-operate," said the driver icily. "We'll show you our drivers' licenses. I think that's enough!" He pulled a wallet from his pocket, and his companion also took out one. The licenses revealed that the driver was John Terrill and his friend Sam Longman. Both were from California. Nancy, all this time, had been studying the men closely. The driver was slim in build and dark, while his companion, Longman, was stockier and had unruly, light-brown hair. They both looked to be about thirty-five years of age, well-to-do, and did not seem like criminals. Nancy wondered what would happen next and whether George would be forced to move the convertible. At that moment a car came whipping up the road and turned in. It stopped dead upon reaching the blockade. "Police!" Nancy thought in relief. Two officers jumped from their car and approached the group. "How do you do, Mr. Landow?" one of them said to the restaurant owner. "Some trouble here?" Quickly Mr. Landow explained what had happened. When Mrs. Burke kept insisting the two men had taken her valuable emerald necklace, the officers said they would make a search. Grudgingly the two suspects permitted this. The necklace was not found on either of them. "We'll look in your car," one of the officers said, and a thorough search was made inside the vehicle. The necklace did not come to light. "I hope all of you are satisfied," said John Terrill. "You can be sure, Mr. Landow, that this not only will be the last time I patronize your restaurant, but I shall tell everyone I meet not to come here! As for you, Mrs. Burke, you ought to have your head examined for making such a scene. And now, if somebody will move that convertible out of the way, we'd like to leave." The officers also looked at the men's driving licenses, then let them go. George deftly moved the car, and the Californians rode off. Nancy addressed the restaurant owner. "Does a young woman named Tammi Whitlock work for you?" The man shook his head. "I don't know such a person," he replied. "She's in the restaurant now," Nancy went on. "Then she's a patron," Mr. Landow answered. He turned away and walked back to the restaurant with Mr. and Mrs. Burke. The police followed, saying they would make a thorough search of the restaurant to see if they could locate the stolen necklace. Nancy did not wish to intrude, but she was interested in learning when and how Mrs. Burke had missed her jewelry. The young detective ran to catch up to her. "Pardon me, Mrs. Burke," she said, smiling, "but I was wondering if perhaps I might help you." She chuckled. "I have a reputation for being able to find lost objects. I don't mean to intrude in the police search, but would you mind telling me what happened just before you missed your necklace?" Nancy's manner was so straightforward and she was so attractive-looking that no one in the group took offense at her request. Mrs. Burke stopped and said, "Well, my husband and I were seated at a table not far from the dance floor. When the singer, Chuck Grant, left the platform he came right past our table. I liked his looks and the way he sang, so I smiled at him. He stopped to chat. "At that moment the two men who just left here stopped at the table also. One stood in back of me and the other alongside. They began to kid Chuck Grant. He came right back at them, and the conversation went on for several seconds. Then all three left. "Right after that, I missed my necklace. It hadn't fallen to the floor, so I was sure the man who stood behind me had taken it." Nancy told herself that any thief who could have done this without attracting attention must indeed be amazingly adept. Mr. Burke added, "My wife became very excited and started running after the two men. They also started to run. I must admit it made them look guilty." He sighed. "But you saw what happened." "Where did Chuck Grant go?" Nancy asked. "Oh, he had walked off in another direction. I believe he was sitting at one of the tables with a young lady." "Tammi!" Nancy thought. For a fleeting second she wondered if there could be any possible connection among Tammi, Chuck, and the two men. But instantly she put the idea out of her mind. It was too improbable! "Well, thank you for telling me," said Nancy. "I must go now. A friend is waiting!" As the two girls left the grounds of the Green Acres Restaurant, Nancy told George the whole story. "Instinct tells me this journey wasn't a complete waste of time," she added. "And instinct tells me," said George, "that in view of what happened last night on the road, we'd better roll up our windows and lock the doors." "You're right," Nancy agreed. There was only moderate traffic on the road, and the girls came within view of the Van Pelt estate without interference. Nancy heaved a sigh of relief and turned into the driveway. But a moment later she jammed on her brakes. There was a roadblock of sawhorses across her path. "Well, for Pete's sake!" said George. She was about to get out and remove the horses, which she recognized as part of the theater's stage props when, without warning. brilliant lights were flashed into the two girls' eyes from each side of the convertible! **CHAPTER XI** _**The Incriminating Mark**_ NANCY and George blinked in the strong glare of the bright flashlights. "Roll down your windows!" a man's voice ordered. Nancy paid no attention to the order. George too remained adamant. Although the girls' eyes had not become entirely accustomed to the light, they could vaguely make out that the persons holding the flashes were masked men. Nancy was sure that the one who had spoken was trying to disguise his voice. "I said roll down your windows," he warned. Instead of obeying, Nancy put her hand on the car's horn. She held it down, and in the stillness of the night it reverberated loudly. "Stop that!" the man on her side ordered. Nancy paid no attention. But after she felt sure the alarm must have been heard, she took her hand off the horn. Nancy did not touch the window, but called through it, "Why did you stop us?" "Because we want to ask you a few questions," the masked man replied. "You didn't have to call for help. We're not going to hurt you." Nancy waited for him to go on. He looked across the top of the car and the girls could see the other man nod. Finally the one alongside Nancy said, "Why are you girls snooping around this place?" He received no answer. The girls kept watching the men closely. "You're cool customers," said the masked man who was doing the talking. "But you won't keep so cool if you stay here. I'm warning you that the Van Pelt estate is a dangerous place. The sooner you get out, the better." "And if I don't choose to go?" Nancy countered, hoping that help would soon be coming from the house. "You haven't seen anything yet around here," the stranger went on. "The theater, the house, and the grounds are haunted!" Nancy and George almost laughed. One moment the speaker sounded like a hoodlum, and the next he was talking like a frightened child about the place being haunted. There was a pause, with no one saying anything. Suddenly the girls became aware of running footsteps. "Help at last!" thought Nancy. She tooted her horn a couple of times. She and George held their breaths, wondering what the men would do. To the girls' relief, the two intruders suddenly took to their heels and dashed down the road in the direction of River Heights. The engine of a getaway car started with a roar just as Mr. Spencer, Emmet Calhoun, and Bess arrived on the run. Nancy and George rolled down the windows. "Why the roadblock?" George demanded, leaning out the window. "Who put these here? What's going on? Where have you been?" Mr. Spencer cried excitedly. "You girls had us scared to death." "Tell you later. We were stopped by two masked men who just left here," Nancy replied. "What!" Bess cried. "How frightening!" "It was no joke," Nancy agreed. Briefly, she explained what had happened. "Did you set up the roadblock, Mr. Spencer?" "No. The men must have taken these props from the theater." Bess sagged limply against the side of the car. "Oh, Nancy, George, what a narrow escape you had!" she gasped. Mr. Spencer and Emmet Calhoun thought they should not let the two masked men get away. They started to climb into the convertible and Mr. Spencer said, "Nancy, we'll chase them!" To his surprise, Nancy did not move. With a slight smile, she said, "This time I picked up a clue. I know who one of the men is." The others looked at her in astonishment. George asked, "How could you? They were masked." "Did you recognize his voice?" Mr. Spencer questioned. Nancy shook her head. "George and I had a little adventure up at the Green Acres Restaurant—tell you all about it later. But the important thing is, two men suspected of being thieves were stopped there and searched. They were allowed to go because a stolen necklace was not found on them." "Yes, yes, go on," Bess pleaded. "One of those men," Nancy. continued, "had an unusual scar just above his right wrist." George blinked and asked, "And you mean to say the masked man who was standing alongside you here had a peculiar scar above his right wrist?" "I certainly do," Nancy answered. "His name is John Terrill. He's from California and the police have this data." "Nancy Drew, you're an absolute whiz," said Bess. The two men looked at her admiringly and praised her fine sleuthing. Nancy felt sure that in some way John Terrill was connected with the mystery at the Van Pelt estate. But she said nothing, not knowing whether or not Emmet Calhoun knew of the mystery of the dancing puppet. "I'd like to phone Chief McGinnis at once," Nancy said. Mr. Spencer and Emmet Calhoun removed the sawhorses and carried them inside the theater. In the meantime, Nancy drove to the house. She asked George to park the car while she made the phone call. "Chief McGinnis," she said, when he came on the line, "have you a few minutes to talk to me?" Receiving an affirmative reply, Nancy related the whole story—from the time she had seen Terrill and Longman run out of the restaurant to the moment the holdup men had dashed away in a car from the Van Pelt estate, On purpose, Nancy said nothing about Tammi or Chuck Grant, the singer. She would pursue that little mystery on her own! "It looks," Chief McGinnis remarked, "as if those men were determined to keep you from interfering in anything further they may want to do. I'll alert my men to keep an eye out for Terrill and Longman. They could possibly be the same elusive fellows who've pulled similar daring jewel thefts lately in this area. You say the local police searched the restaurant and grounds thoroughly?" Nancy said she did not know that exactly, but she was sure the men had not thrown the necklace any place outdoors. "I was watching from the instant they came out the door. The police had not yet searched the inside of the restaurant when I left. Maybe they found Mrs. Burke's necklace afterward." Chief McGinnis asked Nancy to hold the phone a moment. He himself went to another line and called the police in the town nearest the Green Acres Restaurant. The report came back that the necklace had not been located on the floor or among the linen tablecloths and napkins used that evening at the restaurant. The Burkes had finally gone home, saying they would report the loss to their insurance company. "Nancy, that was a very good night's work on your part," said Chief McGinnis. "And now I have something amazing to tell you. I was talking to Joe, the garageman, about the car which we think rammed yours." "You mean the one driven by Owen Whipley?" Nancy asked. "Yes," the officer answered. "But what do you make of this? Owen Whipley, according to Joe, has a peculiarly shaped scar just above his right wrist!" Nancy was thunderstruck. "Really? Is it something like the shape of a crawling snake?" "Exactly. I don't have to tell you, Nancy, that Owen Whipley and John Terrill probably are one and the same person." "Do you think," Nancy asked, "that John Terrill is his right name, or is it Owen Whipley?" Chief McGinnis said it was too early in the case to determine this. "Both might be aliases, and the man might even be using forged licenses." "And what about his friend Sam Longman?" Nancy queried. "I wonder myself. It's a mix-up all right," the chief admitted. "Call me again any time, day or night, if you pick up another clue." Nancy promised to do this. By now Bess and George had come into the house. Babble and excitement started all over again. Margo Spencer arrived from upstairs in robe and slippers to hear what had happened. Bess and George fixed a snack for everyone, while Nancy retold her story. As soon as they had finished eating, she escaped to her room, weary and full of questions. When puzzled, Nancy liked to stretch out on the bed in the darkness and think things through. Right now she was extremely curious about Terrill, or Whipley, whichever his name was. Why was he interested in trying to get her away from the Van Pelt estate? Before she had a chance to start undressing, there was a tap on her door. "Nancy?" She recognized Mr. Spencer's voice. Nancy opened the door. In a whisper, the actor said, "I'm going outside and watch for the dancing puppet. I have a feeling she'll show up again tonight. If she does, I'd like to let you know so you can be there." "But she'll be gone by the time you warn me," Nancy objected. Mr. Spencer grinned. Reddening slightly, he said, "I've rigged up a bell system from the kitchen to your room." He pointed to a crude arrangement on the bedside table. Nancy chuckled. "You think of everything. Yes, I'd like to be notified if you see the dancing puppet. I'll sleep with my ears wide open!" Mr. Spencer said good night and went off. Nancy closed the door and soon was ready for bed in shortie pajamas. As she turned out the light and rolled up the window shade, the young sleuth thought, "The moon will be up late tonight, but it's a perfect setting for a ghostly performance." At that moment there was another knock on her door, and Bess came in. "I know you must be dreadfully tired," she said. "But I can't resist telling you something. In the show tonight, Tammi pulled another one of her overdone love scenes with Bob Simpson. And that's not all. He left the theater as soon as possible and literally ran toward his dressing room in the house. Tammi dashed after him. I had gone on ahead and saw this, so I hid behind a bush and watched. She said something to him—I couldn't hear what it was—but he started running faster than ever, and called over his shoulder, 'Don't be silly!' " Nancy burst out laughing. "I hate to say it, but it served Tammi right." Then she became serious. "Tammi had quite an evening, first being ditched by Bob, then finding a man in her car whom she acted surprised to see and apparently had to go off with." "This place is full of surprises," said Bess, yawning. "Just now I came past Emmet Calhoun's room. The door's open. He isn't there, and his bed isn't turned down!" Nancy was amazed to hear this. "It's a funny time of night for him to be going off," she said thoughtfully. "Come to think of it, he wasn't with us in the kitchen when we were having a snack. Where could he have gone? He doesn't have a car." "Search me," Bess said. "Well, good night." When Nancy finally settled down, she thought she would go over the chain of events in the mystery. But sleep overcame her immediately. She was deep in slumber when her subconscious mind became aware of a tinkling sound. The newly rigged bell on her bedside table was ringing insistently! **CHAPTER XII** _**Puppet Snatcher**_ IN A MOMENT Nancy was wide awake. Thinking it best not to turn on the bedroom light, she felt for the chair near the window on which she had laid the dress she had worn that evening and pulled it over her head. As she stepped into loafers, Nancy gazed out the window. Her heart began to beat faster. _In the center of the lawn, a life-size puppet in ballet costume was jerkily dancing across the grass!_ To Nancy's amazement, a flashlight was trained on the figure. The light came from some bushes along the driveway leading into the estate. Nancy could not see the person holding the light. "I must hurry!" she told herself, and although it took only a few seconds to zip up her dress, it seemed like an hour to the excited young detective. She grabbed her own flashlight and dashed along the hallway toward the rear stairs. "Cally old boy isn't in yet," she told herself, noting that his door was still open and the bed-covers still in place. As Nancy leaped down the stairway, she wondered about the Shakespearean actor. Had he disappeared in order to put on the puppet show? A moment later she reached the kitchen, sped across it, and out the door. At the foot of the steps, partially concealed by the bushes, stood Mr. Spencer. Nancy went to stand beside him. "It's unbelievable!" he whispered in an awed tone. "Nobody's working that puppet, yet it acts as if it were human!" Nancy strained her eyes to see if she could figure out any explanation for the movement of the jerky, yet at times graceful, motions of the dancing puppet. She could see nothing to indicate wires or string. Could it have a mechanism inside which was wound up? "We must capture the puppet!" Nancy declared. "Come on!" With no pretense of moving stealthily, the two dashed across the grass. By this time the mysterious figure was not far from the trees where the flashlight shone on it. "We're gaining!" Nancy thought in delight Any moment now she might solve the mystery surrounding the dancing puppet! Suddenly the bright flashlight ahead went out. For a few seconds Nancy and Mr. Spencer could not see the dancing figure, but as soon as their eyes became accustomed to the pale moonlight, they detected her still dancing jerkily across the lawn. Nancy doubled her speed. She was still some distance from the puppet, when suddenly she was startled to see a long-robed, black-hooded figure emerge from among the trees. The person, with his back to her, reached out and grabbed the dancer. Tucking her under his arm, he made a wild run for the road and disappeared in the darkness. "Good heavens!" Mr. Spencer cried out, trying to catch up to Nancy. The heavy line of trees and bushes along the curved driveway had swallowed up the puppet and her abductor. Nancy followed doggedly. At the point where she reached the driveway, it curved ahead sharply. The black-hooded figure was not in sight. Nancy hurried around the bend. Still no sign of the mysterious person. "Where did he go?" she asked herself. She listened for the sound of a car but heard none. "He must be escaping along the main road." Nancy dashed all the way to the end of the driveway and looked up and down. The dancing puppet and the person carrying her were not in sight. Before going farther, Nancy decided to wait for Mr. Spencer and see what he had to suggest The actor, when he caught up to her, was out of breath and disgusted. He felt there was little more they could do. "We can train our flashlights among the trees," he said. "The fellow may be hiding." Nancy and the actor made a thorough search, casting their lights back of every tree and bush. Their quarry was not behind any of them. "He made a clean getaway," said Mr. Spencer. "I suppose we may as well go back to the house and get some sleep." Intent on searching the ground, Nancy did not reply. Mr. Spencer went on, "I don't mind confessing to you, Nancy, that this puppet business has me extremely worried. It was bad enough when just the dancer was involved, but now that we know there is a flesh-and-blood puppeteer who doesn't want his identity known, I'm more worried than ever. Have you any theory?" "Just one, Mr. Spencer. We haven't yet learned why the puppet is made to perform, but I'm sure the reason is one that involves another mystery." "Oh, dear!" Mr. Spencer sighed. Suddenly Nancy found what she had been looking for—the footprints of the hooded figure. She pointed them out to the actor. "Here are some deep, well-formed prints," she said. "I'll ring them with stones and then ask Chief McGinnis to send men out here to make moulages of them." "You mean in the morning?" the actor asked, and Nancy nodded. He helped her find some small stones, and they encircled several of the footprints. Mr. Spencer heaved a sigh, then chuckled. "You certainly _are_ a detective, Nancy," he said. "I'm delighted your father suggested that you help me solve the mystery of the dancing puppet." "Better save your thanks until I really do something," Nancy replied, smiling, as she and Mr. Spencer started back to the house. As Nancy began to drop off to sleep once more, she could not help wondering again about Emmet Calhoun. She had meant to ask Mr. Spencer where he was, but had forgotten to do so. "Oh, well, I'll find out in the morning." There was no further disturbance that night, and everyone slept soundly. As usual, the Spencers were not up when Nancy and her friends came down to breakfast. While Bess was scrambling eggs, Nancy telephoned Chief McGinnis and told him about the circled footprints. "Very good, Nancy," he praised her. "I'll send a couple of men out there to make moulages." "I'll meet the officers at the gate," Nancy offered, "and show them the exact spot. What time will they be here?" "Nine-thirty," the chief replied. Promptly at that hour Nancy was at the entrance gate of the Footlighters' property. When Officers Jim Clancy and Mark Smith arrived, she led them to the spot where she and Mr. Spencer had carefully laid the small stones. _Footprints and stones were gone!_ Thinking she had made a mistake in the location, Nancy searched for further footprints similar to those she had ringed. There was not a sign of one of theml The two police officers, holding the equipment they had planned to use, stood in silence watching her. Finally she admitted that the footprints had been removed. "The person who made them must have come back and brushed them all away, Indian style, with tree branches," she remarked. The officers did not comment, nor give any sign that they thought she had brought them out on a wild-goose chase. They knew Nancy Drew by reputation and felt sure she would not purposely report a false alarm to the police department. They helped her search. "Probably," said one of the men, "the fellow came back here in stocking feet. He sure doesn't want you to find out who he is." "Nor the police," Nancy added. Suddenly she turned her gaze upward among the trees. "I have a theory. I believe the man we were chasing last night climbed one of these trees and overheard everything Mr. Spencer and I said." "You're probably right," said the other officer. "Well, Jim, I guess we may as well go back to headquarters." "Wait a minute!" Nancy pleaded. She was not ready to give up yet, and furthermore she wanted to compensate for having called them on a futile errand. Quickly she began examining the tree trunks in the area where she had found the deepest footprints. Presently she exclaimed, "This trunk looks as if the bark had been newly peeled off!" Before the two officers could reach the tree to verify her statement, Nancy began to climb the trunk. Soon she was lost to view among the branches. A few seconds later the men heard her cry out. "What is it?" one of them called up. Nancy's excited voice came back. "I've found a clue!" **CHAPTER XIII** _**A Surprising Command**_ "I'VE FOUND the hiding place of that puppeteer!" Nancy exclaimed from her perch in the tree. "What's up there?" asked Officer Clancy. "Wait until I pick up the clues. I'll show them to you," Nancy replied. There was silence for a minute or two, then Nancy started down the tree. "Will you catch these—and please be careful of them," she called to the men below. Through the air floated a piece of black cloth, a jagged square of gray suiting, and several bits of pink tulle. "What in creation are these?" Officer Smith asked in amazement. When Nancy reached the ground she explained. "The man we were trying to catch last night wore a long black-hooded robe. I'm sure this is a piece torn from it. The gray one is from his suit." "But he certainly wasn't wearing pieces of pink net," Officer Clancy spoke up. Nancy grinned. She was pretty sure these men knew nothing about the dancing puppet. For this reason, she merely answered, "Chief McGinnis will understand. Please give these to him. Have you something in which to wrap the pieces?" "Yes," Officer Clancy replied, "in the car." Officer Smith opened the door and brought out a waterproof bag. He drópped the evidence into it and promised to take the bits of cloth at once to Chief McGinnis. "Please ask him to let me know if he tracks down the owner of the gray suit," Nancy requested. "Righto," Officer Clancy said, as the men started to drive off. Relieved that a valuable clue had made the officers' visit worth while, Nancy returned to the house. She entered the kitchen, smiling broadly. At once Bess and George wanted to know what had happened. "You haven't caught the villain, have you?" Bess asked teasingly. "I wish I had, but I did find a piece of his suit and his black robe. The puppet left a clue too. I sent the police a piece of her tulle skirt." As Nancy paused and sniffed the aroma of muffins in the oven, George said, "Don't stop there. Go on with your story." "Tell you what," said Nancy. "I'll trade the whole story for a good breakfast." "It's a bargain," said Bess, giggling, as she opened the oven door and took out a pan of blueberry muffins. "Umm, they look delicious," said Nancy, and helped remove them from the pans to a warm plate. Soon the three girls were seated in the dining room enjoying sliced oranges and bananas, crisp bacon, and muffins. Nancy had just finished briefing her friends on what had happened while the police were there, when Emmet Calhoun stalked into the room. "Good morning, ladies," he said jovially. "Prithee, fair maidens, extend a hungry man a crust to lift his spirits." The three girls chuckled and invited him to sit down. Bess said she would get some oranges and bananas for him. "Aren't you up pretty early for an actor?" George needled him. "Especially for someone who stayed out all night?" Emmet Calhoun blinked. "You knew I was away?" When George nodded, he went on, "Friends from town phoned that they had news of a possible role for me in _King Richard III_ and would pick me up late. I stayed with them overnight, but in order to get a ride back, I had to come early." The girls looked at each other. So Calhoun _had_ been practicing when they had heard him reciting alone on the stage. The actor offered no further explanation, but arose and began to pace the dining room. "Ah, 'thereby hangs a tale,' as 'tis said in _The Merry Wives of Windsor."_ He paused dramatically. "I had a most delightful night in town. Good fellowship, good food, good music. It was as if life's troubles had vanished. _"'Why, then the world's mine oyster,_ _Which I with sword will open.' "_ "Ah, yes," Calhoun went on. _"'We have some salt of our youth in us.' "_ Despite Nancy's slight suspicions of this man and his unawareness of how much trouble he might be to other people, she was amused by him. His quotations were apt, and his manner of delivery was convincing. Nevertheless, she wanted to find out if there were more to his activities of the night before than visiting friends, and whether he knew anything about the puppet or the puppeteer. "Parties in town are fun," Nancy said. "But I love the country with its wide-open spaces and fields and flowers and trees. Oh, I feel bad every time I see a beautiful tree being cut down." Then she in turn quoted: _" 'And many strokes, though with a little_ _axe,_ _Hew down and fell the hardest-timbered_ _oak.'"_ Emmet Calhoun's eyes opened wide, and he looked at Nancy with admiration. "Excellent. I see you know Shakespeare's _Henry the Sixth."_ Before Nancy could reply, he went on, "Did you ever think of training for the theater? You have a marvelous speaking voice. Think about it, my dear. You might become a great actress!" Nancy beamed and blushed a deep red. Bess and George looked at her. They wanted to tell Emmet Calhoun that at their request Nancy had become a self-appointed understudy for Tammi Whitlock. But they said nothing. "Trees, ah yes," Emmet Calhoun went on. "I love trees, but if you must know a little secret, I am scared to death to climb one!" Nancy could not decide whether the actor was telling the truth, or whether he might have been disguised as the black-hooded figure and had made the remark deliberately to throw her off his trail. She remembered that Emmet Calhoun had worn a gray suit the evening before. But somehow, the Shakespearean actor, though eccentric, did not strike Nancy as being dishonest. Maybe she should direct her suspicions elsewhere, the young detective thought. After breakfast Nancy told the cousins she was going to learn Tammi's lines in Act Three of the Civil War play. "What about Act Two?" Bess asked her. "I think I've almost mastered them," Nancy answered. "There aren't so many in that act, if you will recall. That's where Kathy is rather prominent, and Bob Simpson too. He's marvelous in that scene with the President, isn't he?" "He certainly is," said Bess. Then she asked, "No sleuthing today?" "Oh, yes," Nancy answered. "But give me two hours to rehearse first. Then I think we should make another search of the attic for clues to the dancing puppet mystery." At the appointed time she was ready. The three girls had just reached the foot of the attic stairs when Emmet Calhoun approached them. "Going to the third floor?" he asked. "Yes." "I'm sorry, but you can't do that," he told them. "Why not?" George spoke up. Calhoun told them that only the officers of the Footlighters were allowed in the attic. "In fact, no one else in the club is supposed to go above the first floor." George declared firmly, "Mr. Spencer invited us here, and we can go anywhere on these grounds that we wish!" Calhoun smiled patiently. "Not according to our leading lady, you can't." "Tammi!" George cried in a tone of disgust. "What does she have to say about it?" The actor shrugged. "Since I'm not a member of the Footlighters, I am not familiar with the club's rules and regulations. All I know is, Tammi asked me to promise that if anyone went up to the attic I would let her know at once." "Well, of all the nerve!" George exploded. "It's high time somebody taught Tammi Whitlock a lesson!" Nancy laid a hand on George's shoulder. "Take it easy," she said. "I'll phone Tammi myself and get not only this matter but a few more things straightened out!" Nancy hurried downstairs, looked up Tammi's number in a list of members of the Footlighters, and put in the call. It was answered by a gentle-voiced woman who said she was Tammi's aunt. "Please call my niece later," she said. "Tammi was out late last night and is still asleep. I don't want to disturb her." Nancy did not know what to do. She was sure the woman was telling the truth. Yet she wanted to find out whether or not the girls were allowed to investigate the attic of the old Van Pelt mansion. While she was thinking what to say, Tammi's aunt went on, "My niece must be rested and in good form today. She has a rehearsal of the next show this afternoon and then the regular performance tonight." "I see," Nancy replied. Since she had already thought of another way to obtain the information she wanted, Nancy told the woman she would be in touch with Tammi later and hung up. Nancy now looked at the list of members again and dialed the business number of the president of the Footlighters. His name was Bill Forrester, an affable man who gave a great deal of time to help make the whole amateur project a success. When Nancy told him what she had heard and asked if it were true that only the officers of the club could go above the first floor, he laughed. "Tammi is a fine little actress," he said, "but she certainly pulls some funny ones. At a recent meeting of the executive committee of the Footlighters, she made a motion that only the president, the secretary-treasurer, and herself could have access to the rooms above the first floor, other than regular occupants of the mansion. The rest of us didn't see any sense to this, so she was outvoted." "Then it's all right if I go up and look around the attic?" Nancy asked, relieved. "Go ahead," Bill Forrester replied. "But don't forget, if you find any treasures they belong to the Footlighters." "Of course," Nancy said, laughing. She returned to the second floor, where Bess and George were still arguing with Calhoun and making it plain to him that they did not care for Tammi Whitlock. He, in turn, was defending her. When Nancy told of her conversation with Bill Forrester, Calhoun shrugged. Then, striking a dramatic pose, he quoted from Shakespeare's _Troilus and Cressida:_ _"'My mind is troubled, like a fountain_ _stirr'd;_ _And I myself see not the bottom of it.' "_ He walked off and went down the front stairs. Nancy and her friends hurried to the attic. Bess posted herself at the top of the stairs, while Nancy and George began a hunt through the dusty boxes and trunks set under the eaves. The two girls worked for some time but did not find a single clue to the mystery of the dancing puppet. George had just closed the lid of a carton and started to open the trunk next to it when suddenly something flew up into her face! **CHAPTER XIV** _**Nancy's New Role**_ As GEORGE cried out, Nancy ran quickly to her side. Bess, too, left her post to come and find out what had happened. The next second all three burst into laughter. A large jack-in-the-box had risen up and smacked George on the cheek! "Well, this place doesn't lack surprises," she said ruefully, rubbing her cheek. The girls gazed at the jack-in-the-box. It was a toy down fastened in a wooden chest about a foot square and was well constructed. "An expert made this," Nancy commented. "I wonder if it could have any connection with the puppet." She examined the jack-in-the-box thoroughly but could find no similarity to the witch figure in the barn. "Let's continue our hunt," she suggested. "I guess I'd better get back to my post," said Bess, and she returned to the top of the stairway. Nancy and George were intrigued by the contents of the trunk. It contained a crude set of hand puppets and a miniature stage with a long curtain draped below it to hide the puppeteer. "I just can't get it out of my mind that there is a tie-in between the old Van Pelt family and the present mystery of the puppet," said George. "If you're right," said Nancy, "no doubt the mysterious puppeteer has found some clue to a valuable possession of the Van Pelts' and is trying to find it." "You mean," said George, "that he is using the dancing puppet to scare people away from here so he can hunt for it?" "Possibly," Nancy answered. The thought of Tammi and her latest move to keep the girls out of the attic occurred to her. Was Tammi in some way connected with the mystery? Were she and Emmet Calhoun in league with each other? For the next half hour the three girls took turns guarding the stairway and searching the other trunks, boxes, and cartons. They came across nothing suspicious. Finally Bess said, "It's way past lunchtime and I'm starved. Let's get something to eat." At that particular moment Nancy was staring at the far wall of the attic. She began to walk toward it, saying, "I have a hunch there's a hiding place up here that we haven't found yet. Wait until I examine that wall." It took several minutes' close scrutiny of the old wooden wall to find a concealed latch. "Here it is!" Nancy said, excited at the prospect of what she might find. George started to walk toward her, while Bess remained at the top of the stairway. Nancy had a little trouble discovering just how the latch worked, but in a few moments she felt it turn. Gently she started to pull and a door opened. Suddenly she became aware of a movement inside the closet and the next second the life-size puppet of a Pierrot stepped out! As Nancy stared in astonishment, the puppet's left arm, which had been held upright, now lowered menacingly. "Oh!" screamed Bess. George leaped forward, but Nancy had already dodged out of the way. The three girls watched fascinated as Pierrot continued to walk jerkily straight ahead. After it had taken several steps, the figure turned and crashed into a trunk. It fell over with a clatter. The next instant Bess called out, "Here comes Cally old boy!" "He mustn't see this!" Nancy said tensely. She and George grabbed the puppet, dragged him back to the closet, and just managed to close and latch the door when Emmet Calhoun appeared at the top of the stairs. "What crashed?" he asked. George gave a loud laugh. "Haven't you ever noticed how clumsy I am?" she asked. The actor received no further explanation. Instead, Nancy said to him, "Have you ever been up here before?" Emmet Calhoun shook his head. "I detest attics. They're usually full of spiders and dust and make me sneeze." The girls grinned, and Bess added, "I haven't sneezed yet, but on the other two counts I agree with you." She showed smudges on her slacks. "These trunks contain lots of interesting old things," Nancy said. "But nothing too unusual." She did not add that there were three boxes of books which the girls had not examined. "We're all starving, and we're just about to go down for something to eat. Would you like to join us?" "That would be delightful," Calhoun replied, and followed the three girls down to the kitchen. While Nancy washed lettuce for a salad, she said to him, "We found a big jack-in-the-box and some hand puppets in one of the trunks. Are you interested in puppets?" "No more than the average person," Calhoun replied, "though I have read a good deal on the subject." There was no sign that he was not telling the truth. Nancy thought, "I didn't get anywhere on that lead," and suppressed a smile. "Has it ever occurred to you," the actor asked, "that people are really puppets in this world? As Shakespeare says in As You Like It: _"'All the world's a stage,_ _And all the men and women merely players._ _They have their exits and their entrances;_ _And one man in his time plays many_ _parts.' "_ Bess spoke up. "I don't know much about puppets. When did they come into vogue?" Emmet Calhoun said they were one of the most ancient forms of play acting. In the days of the Greek and Roman theaters they were used in plays. "And in this country the North American Indians used puppets in their ceremonies," he added. Emmet Calhoun explained that there had been little change in the method of making puppets perform since the early days of their use. "And there's a fascinating story about how marionettes came into vogue in Venice in the year 944," he went on. "Toymakers there fashioned tiny figures of brides which they called little Maries.' When the French toymakers imitated them, they changed the name to marionettes. By the way, did you know it is thought that Shakespeare's plays _Midsummer Night's Dream and Julius Caesar_ at one time were performed by marionettes?" The three girls admitted that they had never heard this. Emmet Calhoun also told them that during the reign of Queen Victoria in England puppets were made larger than ever before. At times, he said, they were used on the stage with live actors. Nancy asked the actor if he had ever heard of a puppet or marionette being worked in any other way except by strings. Calhoun shook his head. "I don't see how they could be," he said. Nancy was satisfied now that Emmet Calhoun knew nothing about the dancing puppet, the witch, or the Pierrot which she had found. As the group was finishing their luncheon, Margo and Hamilton Spencer walked into the kitchen. They said hello, then at once began to speak of their distress over the forthcoming play. "Those amateurs have got to work hard in the rehearsal this afternoon," Mr. Spencer declared severely. "Bess, do you remember your lines and gestures?" Bess looked a little frightened. "I—I think so," she faltered. The whole group went over to the theater, and one by one the young actresses straggled in. Some of them held jobs but had managed to get a few hours off from business. Nancy and George sat in the front row. Soon all but Tammi had arrived. Mr. Spencer, not to waste time, took sections of the play in which she did not appear and coached the other players. Suddenly he walked out onto the stage, his face red with anger. Stalking up and down, he said, "What's the matter with everybody? We can't put on a performance like this! You say the lines, but you don't put any vitality into them!" "I'm sorry," Kathy Cromwell spoke up. "It's hard for me to act natural when I'm supposed to be talking to a man—and a girl is reading his part." "That's no excuse!" Mr. Spencer shouted. Then he thought better of his remark. "I'll play the part myself." He walked over and took the proper position on the stage, telling Kathy to come on and start again. This time she played the role very convincingly. "Maybe there's something to what you said," he conceded. "We'll have to have more full rehearsals together. Tonight _everybody_ will stay after the show and go through the lines for this play." There were groans from the girls, and the coach was reminded that it would be about three o'clock in the morning before anyone would get home. "Well, I'll decide after I see how you make out this afternoon," Mr. Spencer said. "By the way, is Tammi here yet?" "No," George called up to him. Tammi Whitlock never did arrive for the rehearsal. Finally Nancy told Mr. Spencer of her conversation with the girl's aunt. "Apparently Tammi expected to come," Nancy said. Suppertime drew near and still there had been no word from Tammi. Mr. Spencer announced that he was going to telephone her house. George, her eyes sparkling with an idea, followed the actor. She stood off at a little distance while he made the call. It was easy to guess what was being said on the other end of the line. Tammi's aunt was telling Mr. Spencer that she had tried to phone, but found the line busy. Her niece had lost her voice completely and would not be able to perform that evening! Mr. Spencer put down the phone and sat staring into space. George knew what was running through his mind—what was he going to do? Kathy simply was not ready to take on the part which Tammi had been playing! George walked up to the actor. "I couldn't help overhearing your conversation," she said. "Perhaps I have a solution to the problem." Mr. Spencer stared at her. "A solution?" he repeated. "Yes," said George, and she told him how Nancy had learned Tammi's lines in the play. "She has been rehearsing in secret and imitating every gesture of Tammi's." "That's astounding," said Mr. Spencer. "Are you recommending that I put Nancy on tonight, when she's never been over the part with the rest of the cast?" _**"Wish me luck, girls!" Nancy begged**_ George smiled. "That's up to you, of course," she said. "But I suggest, before you turn down the idea, you go through the lines with Nancy herself." Mr. Spencer, ready to grab at a straw to save the situation in which Tammi had placed him, agreed to do this. "Go get Nancy and meet me on stage. I'll take Bob Simpson's part." When George made her announcement to Nancy, the young sleuth was stunned. "Why, George—" she began. "I think that's a simply marvelous idea!" Bess spoke up. "Come on, Nancy!" she urged. With trepidation, Nancy and the cousins hurried out to the barn theater. Mr. Spencer met her, holding a Civil War ball gown in one hand and a wig with long curls in the other. "Put these on," he directed, "and see how they fit." Excitedly, Bess and George went into a small room at the side of the wings with Nancy and helped her into the costume. "You look simply darling!" Bess said admiringly. Nancy's heart was pounding as she walked toward the stage. She turned and said to her chums, "Wish me luck!" **CHAPTER XV** _**Curtain Call!**_ GEORGE held her breath as Nancy began speaking her lines. Mr. Spencer, taking the part of Bob Simpson, gave no sign that he was either pleased or displeased with Nancy's performance. Whenever there was a scene between the leading lady and another girl character, he called Bess to read the lines. "But don't do any acting," he said. George, now seated in the auditorium, kept her fingers crossed. She noticed that the only time Mr. Spencer stopped Nancy was to drill her on stage directions. Nancy spoke the lines without once forgetting them, and imitated Tammi's movements to a point where George at times could hardly keep from chuckling. The rehearsal went on and on. Presently an idea came to George. She left the theater but returned about twenty minutes later. She was smiling and saying to herself, "Nancy will certainly be surprised." Presently Mr. Spencer said he wouldn't need Bess to read the lines any longer, so she came down to sit beside George. In a few moments the two girls quietly went out together. Nancy thought, "They've gone to cook supper, I'll bet." She herself felt a slight twinge of hunger, but she was too excited about the rehearsal to pay further attention to it. "I suppose I should give you a breather," said Mr. Spencer finally. "Nancy, I didn't want to say anything before, but now I will admit to you that I am absolutely amazed at your ability. I had heard that you performed very well in school plays, but I had no idea you could do this well." Nancy smiled. "Don't forget I've been watching Tammi intently and trying to imitate her." "Well, you've certainly done a remarkable job. Now, if you're ready, I'd like to go over the scene where you're seated on the couch reading a letter and Bob Simpson comes in unexpectedly to bring bad news. Please be very intent while reading the letter. Then, as you become aware of his entrance, start to rise and let the letter flutter to the floor." As Nancy crossed the stage toward the couch, she thought, "That's not the way Tammi does the scene. Mr. Spencer must think his way is better. I wonder if her personal interest in Bob made her interpret the scene differently." Nancy went through the lines and motions exactly as she had been directed, and Mr. Spencer smiled his approval. "Please be sure to do it just that way tonight. It was perfect." Three more short scenes were rehearsed, then Mr. Spencer looked at his watch. "My, it's seven o'clock!" he said in amazement. "Nancy, will you please take a warm shower to relax, have a short rest period, then eat a very light supper. Tell Margo I'll be in shortly." Nancy delivered the message, then went to the second floor. Surprised to find that Bess and George were not around, she returned to the kitchen to ask Margo where they were. "I don't know," the actress replied. "But I did see them go off in your car." Wondering where the cousins had gone, Nancy returned to her bedroom, took a shower, and lay down for twenty minutes. Then she went to the kitchen. After eating a sandwich and drinking a cup of tea, Nancy went over to the theater. Bess and George still had not returned. "Where could they be?" Nancy wondered. The cousins, meanwhile, had hurried to the River Heights airport. George, thinking that Nancy's father and Mrs. Gruen, and also Ned Nickerson, would like to see the performance that evening, had telephoned Mr. Drew. Then she had called the camp where Ned, Burt Eddleton, who was her own favorite date, and Dave Evans were counselors. All of them told her they would like to see the show. The boys would come by plane. "I hope it's on time," Bess fidgeted, as they sat waiting. "We'll just about get back to the theater in time for the curtain." Over a loud-speaker they heard the plane's arrival being announced. The girls hurried to the gate, ready to whisk the boys off as soon as they came through it. Ned and his friends, realizing what a tight schedule they had to meet, ran all the way from the plane to the gate. "Hi!" five voices said at the same time, and everyone laughed. "The car's over here," George explained, leading the way. The trio of college boys formed a most attractive group: Ned, tall and athletic, with brown hair and blue eyes; Burt, blond and a little shorter than Ned; and Dave, rangily built, with dark hair and green eyes. "So Nancy's trying to solve another mystery—with the help of you girls," Ned said, as the car spun along the road. "It's a weird one this time," George answered. "But I don't know how much we're supposed to tell, so perhaps we should wait and let Nancy do it." "Fine thing!" Burt complained. "After all the help we fellows have given Nancy on other mysteries!" "Yes," Dave added, "think of all the miles we've traveled and you won't even let us in on the excitement." Bess and George knew they were being teased, but still refused to divulge any details about the mystery of the dancing puppet. When the young people walked into the theater, Mr. Drew and Hannah Gruen were already there in seats next to those for the newcomers. Greetings were quickly exchanged. "Sh!" George whispered. "Curtain time!" Mr. Spencer was walking out to the footlights. He announced that Tammi Whitlock was suffering with laryngitis and would be unable to play her part that evening. "The Footlighters are very fortunate in having obtained the services of Nancy Drew." As the curtain went up, Bess and George glanced around the theater to see what the reaction was to the change in leading ladies. Some of the audience looked surprised, others frowned. The girls felt that many residents of River Heights had heard what an excellent actress Tammi was and had purchased tickets just to see her. But as the play progressed, the applause for Nancy between acts became very genuine. The young sleuth seemed to have become inspired with the part. Bess and George were seated together, with their dates on either side of them. Bess now whispered to her cousin, "I'm glad Nancy isn't overplaying the love scenes with Bob Simpson the way Tammi does." George suppressed a chuckle. "But look at Ned's face," she whispered. Ned Nickerson sat with a grim jaw and eyes straight ahead. He leaned forward slightly in his seat as Bob kissed Nancy. When the scene was over, he heaved a sigh and sat back, drumming his fingers on the chair arms. As the final curtain came down, the applause was thunderous. All the members of the cast had played their roles unusually well, hoping to support Nancy in the best way they could. There was curtain call after curtain call, with Nancy and Bob Simpson commanding a major share of the crowd's enthusiasm. Mr. Drew was among those who were clapping the loudest. Hannah Gruen's eyes were moist. "I didn't know Nancy was that good!" said Dave. "Boy, she ought to make the stage her career." "And give up sleuthing?" Bess exclaimed. "She wouldn't do it in a million years!" As soon as the audience began to leave, Bess and George took the others to the house. Nancy, waylaid several times and offered congratulations, had not yet taken off her Civil War costume nor her wig. Suddenly she saw her father and Mrs. Gruen, who promptly hugged her. Then, over Hannah's shoulder she saw Ned, Burt, and Dave. "Well, for goodness sake!" she cried. "Oh, it's wonderful to see you! But how in the world did you get here?" "Flew in, at George's invitation," Ned said quickly. "Nancy, you were simply great. I didn't have time to pick up a bouquet for you, but you deserve it. About five dozen red roses!" After Burt and Dave had congratulated Nancy, Ned went on, "I think this calls for a celebration. How about all of us going out somewhere together?" "Thank you," said Hannah Gruen. "But I think I'd better return home." Mr. Drew also said he should get to bed since he had to be up very early the next day. Nancy was silent. "Well, how about it?" Ned asked her. She blushed, then said she was greatly embarrassed. Bob Simpson had asked her to go out with him, and she had accepted. Bob had just come from his dressing room and overheard the conversation. He walked up, smiling. "I couldn't help overhearing what you said, Nancy. I know these fellows have come a long distance. I'll be glad to step aside—that is, if you'll give me a rain check." Suddenly an idea came to Nancy. "Ned, do you and Burt and Dave have to go back tonight?" "Yes, we do." "Then I have a suggestion. We girls will have to drive you out to the airport, and it will be late coming back alone." She smiled at Bob. "It might be good for us to have a male escort." The leading man grinned. "Well, if you insist. But how about my finding me a date? Maybe I can talk Kathy into going." "Swell idea," said Ned. Bob had seen Kathy leaving the house alone. Now he rushed after her and was just in time to invite her to go with the group. The two came back together, and Kathy appeared to be delighted. "I'm honored to be included in the celebration for our new leading lady," she said. Nancy laughed. "I assure you this is only temporary. As soon as Tammi gets her voice back, I'll stick to painting scenery!" "You'll do nothing of the kind," said Kathy. "I don't mind telling you that Tammi and I aren't the best of friends. I wish you'd keep the part." Kathy went into Nancy's dressing room with her and helped her change into street clothes. "It's too bad that you and Tammi don't get along," said Nancy. "I'm going to ask you a very blunt question. Is it because of Bob Simpson?" Kathy nodded. "Tammi is absolutely hateful to me. Of course you've already guessed she's crazy about Bob, but I certainly didn't take him away from her. If he wants to date me, why shouldn't he? Nancy, do you know that Tammi actually _threatened_ me?" "Threatened you! In what way?" Nancy asked her. Kathy said that Tammi had forbidden her to make dates with Bob. "She said if I did, she'd see to it that I never got another part in a play!" "You didn't take her seriously?" Nancy asked. "I tried not to," Kathy replied. "But she gets me so upset I forget lines and never do my best when she's around. One night I actually cried because of what she'd said." Nancy put a hand on Kathy's shoulder. "You must try hard not to pay any attention to Tammi. I admit I don't understand that girl myself." Kathy said she felt better and was sure her acting would improve from now on. "I won't let Tammi get me down—either on the stage or in real life," she said firmly. As the girls left the dressing room, Mr. Spencer came up. He announced that the evening performance had gone so well that there would be no rehearsal that night for the next play. The young people climbed into Bob's station wagon. "Where to, ladies?" Ned asked. Nancy, her mind reverting to the unsolved incident of the stolen necklace at the Green Acres Restaurant, suggested that they go out there. "They have a good dance band and a young singer named Chuck Grant. I think you'll like the place." George chuckled. "Last time we girls were there, we didn't go inside. Nancy and I thought we had nabbed a couple of thieves, but the loot wasn't on them!" "One thing is sure," said Bess. "Those two suspects won't dare show up there again." "Why not?" Nancy countered. "So far they've proved their innocence to the authorities, and they don't suspect I recognized one of them by the scar when he stopped my car." Ned gave Nancy a searching look. "Something tells me you still suspect them of the theft. Am I right in guessing that you think they may have had a confederate in the restaurant and that's why the necklace wasn't found on them?" Nancy laughed. "Mind reader!" When they entered the restaurant, the head-waiter showed the group to a table at the edge of the dance floor. Soon the four couples were enjoying the lively dance rhythms. After a slight intermission, the band returned to the platform. This time Chuck Grant came on stage and sang. As soon as he finished, Chuck stepped down from the platform and came directly to Nancy's table. "You're Nancy Drew, aren't you?" he asked. When Nancy nodded, the singer went on, "I hear you were absolutely terrific in the show tonight." Nancy looked amazed. "Thank you," she said, smiling. "Where did you hear that?" "From several guests who have come in since the performance," he replied. "I think I ought to warn you—Tammi Whitlock is not going to like the report. She's a firebrand when she's jealous!" Nancy laughed. "Tammi has nothing to worry about. Her role is waiting for her whenever she can come back to take it." Then, wishing to change the subject, Nancy asked, "Where'd you learn to sing so well?" "California," Chuck Grant replied. Nancy recalled that Tammi came from California. "Then you knew Tammi out there?" she inquired. Chuck Grant threw back his head and laughed heartily. "I'll say I did. Don't you know who she is?" **CHAPTER XVI** _**Aliases**_ CHUCK Grant leaned toward the waiting group. "Tammi Whitlock is my sister!" he startled them by saying. "Your sister!" George repeated. "Well! _That_ explains a lot of things." "What do you mean?" the singer asked quickly. George was on her guard at once. "Oh, your ability in the arts," she replied. "And one night we saw you leave with her from our theater." "I see," Chuck answered. Had Nancy imagined it, or did the young man look relieved? "Where did you pick up the name Chuck Grant?" Ned spoke up. The singer said that Chuck was a nickname. His family had great objections to his singing with bands in restaurants. "So I took the name Grant." He chuckled. "When I was a little boy I fell in love with a movie star. Her name was Lola Grant. The name has brought me good luck—here in the East." "Did Tammi come here because you did?" Nancy asked him. "Sort of," he replied. "I came because a friend of mine lives here, and I stay with him. Tammi's with our aunt, but that's too slow for me!" Bess giggled. "Slow! Even though you work in a place like this?" Chuck said that the management was very strict, and he was not allowed to make dates with any of the patrons. "So if I weren't staying with a friend, I probably wouldn't have met anybody around here or had any fun," he explained. Nancy asked him how often he saw Tammi, and he said about once a week. "To tell you the truth," he confessed, "my sister and I don't agree on a lot of things. She treats me too much like a kid brother." Nancy smiled and then said, "I understand there was a bit of excitement around here the other night when a Mrs. Burke's valuable necklace was stolen. Did she ever find it?" "Not that I know of," Chuck answered. "But then I wasn't too interested and didn't pay much attention." "Did you know the two men who were accused of taking the necklace?" Nancy prodded him. The young singer stared at her, frowning. "I don't know what you mean. Why should I know a couple of crooks?" "Of course you wouldn't," Nancy said with a disarming smile. "I heard that you and the two men happened to stop at the Burkes' table at the same time, that's all." "Oh, if _they're_ the accused men, I never saw them before in my life," Chuck answered. "Mrs. Burke—if that's her name—smiled at me as I came off the platform. She seemed like a nice motherly soul and I was feeling kind of lonesome that evening, so I stopped to chat." At this moment the band began to play again. Chuck excused himself and returned to the platform. Nancy and her friends got up to dance. When they returned to the table, Ned looked at his watch and said, "Much as I hate to break up this party, we fellows must catch a plane. I think we'll have to go now." He summoned the waiter and asked for their check. From time to time Nancy had glanced over the patrons in the restaurant, hoping that the two suspected men might come in. But they did not appear. "If those two are thieves, they probably work their racket in a different place every time," she thought. Soon she and her friends were in the station wagon speeding toward the airport. "It's been a swell evening," Ned declared, as the boys were ready to show their tickets at the gate and walk out to the waiting plane. "And listen, Nancy, you watch your step solving this mystery. Promise me, if you do need any help, you'll give me a call." Burt guffawed. "You'd need a magic carpet to get here in time to do any good!" Dave also put in his gibe. "If I were you, Ned, I'd tell Nancy to stay away from the stage before she starts taking her lines too seriously!" The banter continued until the three girls, Bob Simpson, and Kathy Cromwell said good-by to the visitors and waved as they boarded the plane. The Footlighter group stayed to watch the take-off, then Bob took his new leading lady and her friends back to the Van Pelt mansion before he drove Kathy home. Although it was late, George and Bess followed Nancy into her bedroom and talked excitedly about the whole evening—how marvelous Nancy had been in the show and how surprising Chuck Grant's announcement was. "Do you think," George asked, "that Tammi and Chuck are in cahoots about something?" "If they are, there's no clue yet as to what it is," the young sleuth answered. Bess yawned and remarked, "He called Tammi a firebrand. I'd like to bet that you'll hear from her about playing her part so well tonight." George grinned. "Tammi can't do anything until she gets her voice back! I hate to wish anyone hard luck, but I hope she doesn't recuperate too soon!" The next morning, just as the girls finished eating their breakfast, the telephone rang. Nancy answered it. The caller was Chief McGinnis. "I have some news for you, Nancy," he said. "We've picked up a suspect in that necklace job." The chief requested that Nancy, Bess, and George come down to headquarters. The suspect was to be put in a line-up for identification. The girls arrived promptly and were introduced to a stranger, named Mike Besser, a pawnbroker in a town some distance away. Among the assembled witnesses was Joe the garageman. The group was given seats in the main room of police headquarters. Then six men were marched in by an officer and ordered to turn so they would face Nancy and the others. Not a word was spoken until Chief McGinnis said to the group, "Have any of you ever seen any of these men before?" At once Mr. Besser spoke up. "That fourth man from the left is the one who came into my shop and pawned an emerald necklace." "Did you notice anything unusual about him?" the officer went on. "No, I didn't," the pawnbroker replied. Joe now answered the chief's question. "That same man—the fourth from the left—he's the one who brought in the car with the smashed headlights and fender." Bess whispered to Nancy, "The one who rammed into your convertible!" Nancy and George had been watching the accused man intently. Now Nancy spoke up. "He's one of the two men we saw at Green Acres Restaurant! He was suspected of having taken Mrs. Burke's necklace." The other men in the line-up were excused. The suspect was brought by the policeman to face the watching group at closer range. Nancy whispered to Chief McGinnis, "Will you ask him to pull up his right shirt sleeve?" The prisoner refused, so the policeman did it for him. "There's the scar!" Nancy cried out. "I'd know that scar anywhere!" The prisoner gritted his teeth and looked balefully at the group in front of him, but he said nothing. Chief McGinnis explained that when the man had been found in his apartment, he had papers on him showing that he was Owen Whipley. "That's the name he gave me," Mr. Besser spoke up. "And me," Joe added. Nancy looked at Chief McGinnis. "But at the Green Acres Restaurant he had a driver's license made out to John Terrill!" The officer faced the prisoner. "Which is your right name and which is an alias?" he asked him. The suspect did not answer. "We'll make him talk later," said the chief, and ordered the policeman to take Whipley to a cell and lock him up. The officer thanked Mr. Besser and Joe for their co-operation. When the two men had left, Chief McGinnis turned to the girls and said, "Nancy, I want to thank you for your tip. My detectives kept working until they found a tailor who had a jacket with a hole in it to be woven. The gray fabric exactly matched the snip you found in the tree out at the Van Pelt estate." "And did you find the dancing puppet and the hooded robe too?" Nancy asked eagerly. Chief McGinnis shook his head. "No, he apparently keeps them somewhere else." Just then the police guard who had taken Whipley away returned. He reported that the prisoner still claimed he was being held illegally —that he had committed no crime. "Whipley claims," the policeman went on, "that some unknown person helped himself to his car and dented it. Whipley took it to the garage to be repaired. As for the stolen necklace, Whipley insists he knows nothing about it. He says the one he took to the pawnbroker belongs to a relative who was hard up for cash." "His story about the car accident has been changed completely," Nancy remarked. Chief McGinnis smiled. "Whipley's explanations sound pretty flimsy. We'll hold him until he can find some proof to back up his statements." Before leaving, Nancy asked Chief McGinnis where Whipley had been living. The officer grinned. "I know you'll pick up a clue," he said. "Whipley has been renting an apartment at 24 Ambrose Street." The three girls went to that address in Nancy's convertible. Two young women with baby carriages were talking in front of the apartment house. Nancy stepped from the car and went to speak to them. First she admired the two adorable babies in the carriages. Finding the young mothers friendly, she asked: "Do you happen to know a Mr. Owen Whipley, who lives here?" "I know him," one of the young women answered, "but he doesn't live here. He has an apartment around the corner." Nancy looked surprised. She said, "Do you happen to know John Terrill?" "He lives here," the other woman replied. Nancy laughed. "I'm certainly confused. I thought they probably lived together." She did not want the two women to suspect she was fishing for information. Apparently they were unaware of her probing. One said, "If you want to find Owen Whipley, he's at 16 Dayton Avenue." "I know where that is," said Nancy. "I'll just stop here a minute and see if Mr. Terrill answers his bell." She went inside the apartment house and looked at the mailboxes. Not finding either the name Whipley or Terrill, she went over them all again. Neither was listed, but there was one box without a name. Apparently the suspect did not wish anyone to call on him! "I suppose the police got their information through the superintendent," Nancy thought as she came back outside. She waved to the two young women and climbed back into her car, then set off for 16 Dayton Avenue. On the way she told Bess and George the latest development. "What a mix-up!" said Bess. "Maybe the man who called himself Sam Longman at the restaurant is now using the name Whipley," George remarked. "Or," Nancy added, "maybe Terrill rents two apartments." Bess sighed. "This mystery is getting beyond me. All I know is that two men using three names are from California, and so are Tammi Whitlock and her brother. Say, do you suppose Chuck Grant was just giving us a story and isn't her brother at all?" "Your guess is as good as mine," Nancy answered. "My only hunch right now is that Owen Whipley or Sam Longman, or whoever he is, won't answer his bell." In a few minutes she parked, and the girls entered the rather shabby-looking apartment house at 16 Dayton Avenue. It proved to be a walk-up, and Nancy noted that again there was one mailbox without a name on it. "It probably belongs to the man we want to see," said George. "Come on! Let's go up!" Nancy laid a restraining hand on her chum's arm. "We have no right to make a search," she said. "I think we should get in touch with Chief McGinnis, tell him what we've found out, and ask him to send a couple of detectives here to go upstairs with us." There was a pay phone on the wall near the front door. Nancy put in a coin and called the chief. Speaking barely above a whisper, she told him her findings, and he promised to send men over at once. Upon the arrival of the officers, who introduced themselves as Foster and Dougherty, she led the way to a rear apartment on the third floor. They rang the bell and waited excitedly. There was no answer. Then Detective Foster knocked. Still there was no answer, but Nancy's sharp ears caught the sound of a movement inside the apartment. "I'm sure someone is in there," she whispered to the officer. "I have a suggestion. It may or may not work. Possibly these thieves use passwords of one sort or another. You might try saying 'Green Acres' and see if it works." The detective nodded. He tapped on the door lightly and called, "Green Acres! Green Acres!" Within seconds the group heard footsteps, and a man opened the door. The startled occupant gave one look at the visitors and tried to slam the door. When Detective Foster prevented this, the man took to his heels through the apartment. "That's Sam Longman!" Nancy cried, recognizing him as Whipley's companion at the Green Acres Restaurant. The girls and the detectives rushed after the suspect. By this time Longman had reached a bedroom. He banged the door shut and locked it. Suddenly Nancy exclaimed, "There may be a fire escape off that room! He'll get away!" "No, he won't!" said Detective Dougherty. "Foster, you and Miss Drew run down and stop him. I'll break down this door!" **CHAPTER XVII** _**The Chase**_ As DETECTIVE Foster and Nancy rushed from the apartment house, they almost collided with a woman hovering over a baby in a carriage. A tall, husky man stood beside her. Foster stopped, opened his coat to show his detective badge, then commandeered the services of the man. "We're after a suspect, and I may need help," the detective said. Nancy, meanwhile, had asked the woman if there was a fire escape from the left side of the building. The young woman nodded, saying, "You can get onto it from every floor through a bedroom in the rear apartments." The detective, the other man, and Nancy sprinted into an alley. Nancy pointed. "There he is! Just jumping down from the foot of the fire escape!" The three pursuers doubled their speed but were not able to lessen the gap between them and the fugitive. "He mustn't get away!" Nancy cried out. To the men's amazement, she was more fleet-footed than they. Nancy had vaulted a fence which the suspect had jumped over, and was now running down an alley toward the next street. The detective and the other man finally caught up with her at the street. Longman was weaving his way to the opposite side, dodging traffic. "Stay here!" Foster commanded Nancy. At that moment a red light on the nearby corner stopped all traffic, giving the two men a chance to dash across the street. After a short chase up the block, they nabbed their quarry! He was putting up a fight, Nancy observed, flailing his arms and trying to wrench free. Longman soon found it was useless to fight, and accompanied the men to the corner. At a green light they all walked across to where Nancy was waiting. "We'll go back to the apartment," said the detective. He turned to the stranger who had helped him. "Thank you for your assistance. Here comes Detective Dougherty. He'll take over." The stranger gave a quick salute, said he had been glad to help, and walked off. The others returned to Longman's apartment. Detective Foster told everyone to sit down in the somewhat shabby living room. To Longman, he said, "Now talk!" The prisoner began to bluster. "What's this all about? You have no right to hold me! I haven't done anything!" "If you won't tell your story," said Detective Dougherty, "suppose we ask you a few questions. Do you know that we have located the emerald necklace you stole at the Green Acres Restaurant?" Longman glared at the detective. "I don't know what you're talking about." "What is your right name?" Foster pursued the interrogation. When the man refused to answer, Nancy spoke up. "I know two names he uses, but maybe neither one is his right name. One is Owen Whipley, and the other is Sam Longman." Suddenly the prisoner, his eyes blazing, cried out, "Who's this girl, anyway? What right's she got to question me or say who I am?" Quietly Bess spoke up. "Nancy Drew is a detective—and a very good one too!" Dougherty now told Longman that his pal, John Terrill, who also used the name Whipley, was behind bars. Longman gave a visible start and looked frightened. Then his bravado returned, and he said, "Well, that's his hard luck!" The officers tried in various ways to get the prisoner to say more, but he merely continued to protest his innocence. Finally Dougherty asked Foster to guard him, while he made a search of the apartment. "It's against the law!" screamed Longman. Dougherty pulled a search warrant from his pocket. Then he and the three girls began a really intensive search for evidence. Every closet and bureau drawer was investigated. Twenty minutes later the searchers were ready to admit defeat. They had arrived in the kitchen as the last area in which to hunt. Longman, a self-satisfied smirk on his face, was standing in the doorway with Foster behind him. "You're nuts if you think you're going to find anything here," he bragged. Cupboards were opened. They revealed a few dishes and several cans of food—nothing more. Discouraged, the searchers stood in the center of the room, while Longman watched, grinning. "What did I tell you?" he said. "Now get out of here, all of you!" Suddenly Bess had an inspiration. She dashed across to the gas range and opened the large oven door. The eyes of the other searchers popped in amazement. _Jammed inside the oven was the missing dancing puppet!_ "For Pete's sake!" Dougherty cried out. "What's this?" To the astonishment of the two detectives, Nancy explained that this figure had been seen dancing eerily around the Van Pelt estate. "My friends and I have been trying to solve the puppet mystery," she said. _Longman screamed, "Don't touch that!_ _You'll be electrocuted."_ Everyone now turned toward Longman. Foster asked him, "Where'd you get this, and what's all this about having a dance on the lawn?" "I'll tell you nothing," the prisoner answered, "except to admit that my friend and I have used the name Whipley as an alias." Nancy spoke up. "Then at least one of your drivers' licenses is forged?" she guessed, and Longman nodded. By this time Bess had carefully lifted the puppet from the oven. It was carried into the living room and set on a straight chair. Nancy began to examine the figure in its frilly dress. Now was her chance to find out how the puppet worked! Longman's eyes had narrowed almost to slits as he watched the girl. Presently Nancy said, "Oh, the whole back comes off!" "What's inside?" asked George. Before Nancy could reply, Longman jumped toward her and screamed frantically, "Don't touch that! You'll be electrocuted!" All eyes turned on Longman. "I'm an electrician," he continued. "That puppet is highly mechanized and works by remote control to electric wires. There's a live one inside. If you touch it, it'll be curtains for you!" "Oh, Nancy!" Bess exclaimed. "You might have been killed!" Nancy seemed less ruffled by Longman's announcement than the others in the room. If there were a live wire, it had been put there for a reason. "I'll bet," she thought, "that Sam Longman has something hidden inside this puppet he doesn't want us to find!" She communicated her idea to the others. The suspect glared at her. Detective Dougherty looked at Nancy in admiration. "You are probably right. We'll look inside this puppet, but we won't take a chance. I'll call the police electrician to handle it with the proper tools." He told Foster to go down to their car and radio Chief McGinnis. The detective made the call, and within a short time Smitty, the police electrician, arrived. He admitted that Longman's statement was partly true and it was just as well that Nancy had not put her hand inside the back of the puppet. Smitty unhooked wires leading to strong batteries. "Once upon a time this puppet worked by being wound up," he announced. "There's a sturdy spring here, but the key has been removed." "We think the puppet may be used to conceal something valuable," Nancy told Smitty. "Do you see anything in there?" The police electrician pulled a small flashlight from his pocket and trained it on the interior of the puppet. "Wait till you see what's here!" he cried out suddenly as he reached inside. **CHAPTER XVIII** _**The Hollow Laugh**_ THE THREE girls crowded forward to see what the police electrician was going to pull out from the back of the dancing puppet. The detectives kept a tight grip on Sam Longman in case he should try to get away again. "A pearl necklace!" Bess squealed. "Those look like genuine pearls," George commented. "And obviously stolen too," Detective Foster spoke up. By this time the police electrician had drawn out several more valuable necklaces—one of diamonds, another of sapphires, two of rubies, and two more of pearls. "These must be worth a fortune!" Bess exclaimed. "They sure are," Detective Dougherty agreed. "We'll take it all down to headquarters. Well, Longman, what do you have to say now?" Instead of replying, the prisoner suddenly went dead white and clutched at his heart. "I'm going to have an attack!" he said. Instantly Dougherty led him into the bedroom, laid the man on the bed, and felt his pulse. "You're having no heart attack," he said acidly. "Your heart beats fast because you're scared, but that won't keep you out of jail. Come on!" He helped the man to his feet, and together the two detectives started for the door with him. Dougherty turned to Nancy and her friends. "Would you girls mind staying here until we return?" he requested. "If any callers come, try to keep them here. We'll get this fellow booked as soon as possible, and be right back." The girls agreed to remain. While awaiting the detectives' return, Nancy examined the puppet herself. "My, what a maze of wires there are in here!" Bess and George peered inside the back of the figure. "Whoever made this was an inventive genius," George remarked. "Let's try to make the puppet dance by holding her up," Bess suggested with a giggle. The three girls stood the puppet on its feet and manipulated its limbs and head from the various gadgets inside. Nancy and her friends were still playing with the puppet when Dougherty and Foster returned. The two detectives laughed heartily. "I guess girls never get tired of playing with dolls," Dougherty said with a grin. Nancy's eyes danced. "Especially when there's a mystery connected with one. I was just thinking —Longman never explained how he happened to be in possession of the dancing puppet." "We tried to make him," Foster told her. "On the way to headquarters we asked him to explain the mystery of this puppet, but he kept insisting he knew nothing about any mystery. He said a friend of his had found the puppet in a junk shop. Being an electrician, Longman had been intrigued enough to try making it work by putting in wires and batteries. He still insists he doesn't know how the stolen jewelry got inside." "Do you think he's telling the truth?" Nancy asked the detectives. The two men shrugged, and Detective Foster answered, "Even the mystery of the stolen jewelry is far from solved." He smiled. "The police certainly want to thank you girls for all your help. If you find out anything more, let us know!" The three young sleuths laughed and promised to do this. Then they drove back toward the Van Pelt estate. Bess had seen a morning newspaper lying on a table in Longman's apartment and had helped herself to it. Now she began to read. In the meantime, George and Nancy continued to discuss the mystery of the dancing puppet. "Do you think," George asked, "that there may be other members of a gang stealing jewelry and using the puppet as a hiding place until it's safe to sell the pieces?" "That's a possibility, George," Nancy agreed. "If so—I'm wondering if we'll be bothered any more out at the mansion." "How could we, with the puppet in the hands of the police?" George countered. "There could be more puppets," Nancy replied. "We already know of two others." George's reply was interrupted by Bess. "Listen to this!" she cried out, reading from an inside page of the newspaper. "'Unknown Amateur Steals Show.' And underneath it says, 'Nancy Drew Makes Big Hit in First Performance.'" "Oh, no!" Nancy exclaimed, blushing. "Why, that makes it look as if I were better than Tammi, and that's ridiculous." "You _were_ better than Tammi," Bess said staunchly. "Just as good, anyway," conceded George. She suddenly laughed loudly. "If Tammi Whitlock sees this, she'll be back on stage tonight even if she sounds like a frog!" Nancy was silent during the balance of the ride. She did not care for Tammi, yet she did not wish to make an enemy of her. Vividly Nancy recalled Chuck Grant's saying that his sister was a firebrand when she became angry. Nancy thought, "Why, there's no telling what Tammi may do!" Upon reaching the estate, she parked the car, then the three girls went into the kitchen. Mr. Spencer stood inside, a copy of the same newspaper in his hand. He wore a broad smile. "I suppose you know what the paper said about your performance, Nancy." "Yes," she said quietly. "I'm glad my performance was good, but I hope that Tammi gets back here in a hurry." Mr. Spencer looked directly at Nancy. "Listen to me," he said. "Even if Tammi returns, you are going to continue in the leading role. I've had enough of her temperamental fits—and there are certain scenes in the play which she refuses to do according to my direction. Fortunately, you are co-operative." Nancy was nonplused. But finally she said, "Mr. Spencer, don't think I'm not appreciative of this honor, but I couldn't continue to have an important part in any play. I help my father, you know, and I shouldn't try to hold down two jobs." "I realize that," the actor said. "I'll talk to your father. I'm sure he'll see things my way." Mr. Spencer was making it very difficult for Nancy. She loved to act, but far more than this, she loved working on mystery cases, either with her father or on her own. The actor went on, "Nancy, you can't let me down! Our new play goes on in a week, and you know what a sad state it's in right now. Please learn the lines. I think you have a good influence on the cast, and they'll probably work better with you than they did with Tammi." Bess and George knew that Nancy was in a tight spot. Bess had a sudden inspiration. "Mr. Spencer," she said, "I think I may have the answer to your problem. Why don't you substitute a puppet show for a couple of weeks until the next play can be whipped into shape?" "Puppet show?" Mr. Spencer echoed. "You must be teasing—your mind's been on the mystery of the dancing puppet too long." "Oh, no, I'm not fooling," said Bess. "There's a long article in the paper about a marvelous European puppeteer who is touring this country and putting on magnificent shows. Maybe you could get him to help you out." Mr. Spencer had not seen the item. After Bess pointed it out and he had read the article, Mr. Spencer scratched his head. "Bess," he said, "you may have a point." Suddenly he became very enthusiastic about the idea. "I think it would be good to give the cast a rest. Maybe I've been pushing them too hard and they've gone stale. I'll make some phone calls right away and try to locate this fellow." After he had left the kitchen, Nancy hugged Bess. "You're a lifesaver, dear," she said. "Let's keep our fingers crossed and hope that Mr. Spencer will be able to engage that puppeteer!" When Hamilton Spencer returned from the telephone, there was a broad smile on his face. "I've reserved the services of the puppeteer!" he announced. "The Footlighters can vote on this tonight." "Swell!" said George. With this matter settled, Nancy now told Mr. Spencer about finding the dancing puppet. "And her back was filled with necklaces!" George announced. The actor listened spellbound as the girls related the entire story. But he was as puzzled as they to know why Longman, and probably his pal Terrill, had made the puppet dance on the Van Pelt lawn. "What are we going to do now?" he asked. "Forget the whole thing and assume that the mystery is ended, even though it hasn't been entirely solved?" Bess spoke up immediately. "Mr. Spencer, if you want us to leave, I'm sure Nancy—" "Oh, no!" the man answered quickly. "I didn't mean to imply that I wanted you to go away. Please don't do that!" Mr. Spencer became so embarrassed that Nancy felt sorry for him. She smiled sweetly. "I'd like to stay," she said. "It bothers me to leave a mystery unsolved. I'd like to do a little more investigating around this place to see if I can pick up another clue. Who knows, maybe the witch and the Pierrot have stolen valuables hidden in them!" "Before we do another speck of sleuthing," Bess spoke up, "we're going to have lunch. I'm starved." George began to laugh. "It would be good for you to go without it. How else can you lose those twenty pounds you've been talking about?" Bess made a face at her cousin, then marched straight for the refrigerator. The first thing she pulled out of it was a large jar of mayonnaise. "Uh-uh," said George, grabbing the jar from her cousin. "Your rations will be one piece of lettuce, one tomato, and one thin slice of roast beef." "I _have_ lost five pounds," Bess contended. "Let's not go overboard on this!" Then she sighed. "Oh, I suppose you're right." Mr. Spencer had left the kitchen, so Bess added, "I still want to get a better part in the play than just the maid. She only has a few lines." As soon as the girls had eaten and washed the dishes, Bess and George asked Nancy what she had in mind. "Another trip to the attic," said Nancy. "I want to look at Pierrot again. He may be more valuable than we think." George grinned. "You mean the clown may be full of diamonds? I always thought everything about a clown was make-believe. It's more likely he'd be wearing costume jewelry!" The other girls laughed, and the three started for the attic in a merry but excited mood. Were they going to find something else connected with the mystery? Once more, Bess stood guard at the top of the stairs. George followed Nancy to the secret door and watched as her friend opened it. A cry of amazement burst from her lips. _Pierrot was gone!_ As the girls stood staring in dismay at the empty closet, they heard an evil-sounding, hollow laugh! **CHAPTER XIX** _**A Puppeteer's Secret**_ "WH-WHAT'S that?" Bess screamed in fright. Nancy and George stood frozen to the spot. The hollow laugh was not repeated. Nancy, sure the laugh had come from behind the back of the secret closet, began to look around for another opening. But though she scrutinized the wooden wall for several minutes, the young detective could not locate any hidden springs or latches. The closet walls seemed perfectly solid. "I wonder what's on the other side of this," Nancy said, frowning. She stepped from the closet and looked questioningly at her chums. Bess had come to the side of George, whose grim look and stance indicated she was poised to greet the mysterious laugher, should he appear. "Maybe," Nancy said, "there's a roof behind this closet, and someone's standing there." She ran to one of the small attic windows. After some difficulty she managed to open it and look outside. There was no roof beyond the closet, but Nancy saw that the closet itself formed the top of an extension of the main house. "See anybody?" George asked. "No." As Nancy returned to her friends, Bess said in a tremulous whisper, "I'm beginning to think this place is haunted!" Nancy laughed. "I'll think so too, until the mystery is solved and I know just who has been doing queer things around here. Personally, I believe Terrill and Longman are guilty." "But they're both in jail!" Bess reminded her. "So they couldn't have given the hollow laugh." Nancy had to admit her friend was right, but said, "They could have confederates." The girls waited for several more minutes. There was no further disturbance and Nancy suggested that they start looking through the books stored in the attic. "We may find a clue tucked in one of them to help us solve the mystery." Since there were three large boxes of them, the girls divided the work. For the next half hour there was silence in the attic as book after book was carefully examined, page by page. No papers, no letters, and no reading matter which was of any help to them came to light. "This is a week's work," Bess said finally, giving a great sigh. "Let's take a rest and come back to the job later." "Yes, let's," George agreed. At that moment Nancy was deep in a small volume she had come across. It was the diary of a Ralph Van Pelt, written nearly fifty years before. "I think I may have found something!" she told her friends excitedly. "Listen!" She explained that Ralph Van Pelt had been an inventor, who had come to the United States from Holland. He had never married but had lived with a brother on the estate, which was then a farm. Every year, as Christmas gifts, he carved toys for his grandnieces and grandnephews. "And guess what!" Nancy went on. "The children loved puppets, so their uncle used to make sets of them and put on little shows." Bess and George, intrigued by the story, had come forward and seated themselves on the trunk to listen. Nancy now began to read the diary word for word. They learned from the well-written account that Ralph Van Pelt had become so interested in making puppets that he decided to try contriving life-size ones with mechanical devices inside to make them move. One section of the diary read: "'Today I had my first show out of doors. Relatives and friends were here for a Fourth of July picnic. Two of my marionettes performed very well. One danced and the other, a witch, frightened the children out of their wits!' " "The puppets we found!" George exclaimed. "What a clever man he must have been!" Bess commented. "I wonder how many puppets he made in all?" Nancy read on. Presently she came to a passage which said that the grandnieces and grandnephews had nearly ruined one of the puppets playing with it. "'So I decided to hide the marionettes,' " Van Pelt had written. "'I built a secret closet in the attic and placed my four puppets inside for safety.' " "Four!" George repeated. "Then one is still missing!" "Probably Terrill and Longman have it some place," said Bess. Nancy did not agree. "I'm positive that the reason they were displaying the dancing puppet here was to scare people away from this mansion. Those men, or pals of theirs, could then have more freedom to search this place for the fourth puppet. But why did they want it so badly? Well, let me read some more." There were several pages in the diary which had no bearing on the present mystery. Then suddenly Nancy came across an exciting item. It read: "'I took one of my puppets from the secret closet today. Inside the puppet I deposited a valuable secret. It would not help anyone today, but I assume the puppet will not be found for some years to come. When it is, the secret will make the finder wealthy. I hereby decree that whoever does find the puppet shall become the true owner of its secret.' " Nancy paused, and the three girls looked at one another in complete amazement. What was the secret? And where was the puppet? Had it been stolen, or was it still in its hiding place? "I certainly hope we can find that puppet!" George muttered. Nancy said pieces of the puzzle were beginning to fall into place now. "I believe someone found this diary and read it not too long ago," she said. "I'm sure he was still hunting for the fourth puppet up to the time of the dancer's last appearance." "Then it could still be here!" George exclaimed. Nancy nodded. "On the other hand, it may have been found years ago by someone who already has made use of the secret." Nancy's eyes roamed the attic, trying to imagine a hiding place for it. Suddenly Bess spoke up. "Don't you think we'd better give up our attic sleuthing for now? Someone in this house may get suspicious and come up here. After all, Cally old boy hasn't been eliminated as a suspect in this case." Before Nancy had a chance to reply, she heard Mr. Spencer calling her from the first floor. She hurried downstairs, followed by Bess and George. "I'd like you to go over some of the lines in the show," he told Nancy. "You did very well last night, and I want everything to run just as smoothly this evening. We'll have an early supper and go over to the theater for a rehearsal." As they were finishing dessert, Mr. Spencer was called to the telephone. Nancy waited and waited for him to finish. Since the conversation went on and on, she decided to go over to the theater herself and practice some of her lines. "Bess, will you please tell Mr. Spencer where I am?" she asked, as she opened the kitchen door to leave. "Will do," Bess promised. "See you later. Good luck!" Nancy quickly crossed the yard and went in the side entrance of the theater, which was unlocked. She had not made a sound in her soft-soled shoes, so anyone inside would not have become aware of her presence. Suddenly Nancy stopped dead in her tracks. Were her eyes deceiving her? The theater was only dimly lighted, but she was sure her imagination was not playing tricks on her. _A life-size puppet was dancing jerkily across the stage!_ "That must be the missing puppet!" Nancy told herself. "But someone has put a modern dress on it!" Though moving jerkily, this figure was far more graceful than the dancing puppet Nancy had seen performing on the lawn. Reaching the far side of the stage, the figure disappeared into the wings. At once Nancy ran after it. But before she herself had reached the opposite wing of the stage, the puppet suddenly returned. To Nancy's amazement, it came at her and began to attack her wildly with its arms and legs! Warding off the blows, Nancy reached out to hold the puppet back. At this point she received a distinct shock. The puppet's body was warm! This was not a wood-and-plaster figure. It was a human being, wearing a mask! Now Nancy fought with the attacker, and managed to pull off the mask. "Tammi!" Nancy cried out, astounded. "Yes, I'm Tammi," the other girl flung back in a hoarse whisper. "I'll teach you to steal my part in the show!" In a frenzied rage the jealous girl grabbed Nancy and began to hit her with her fists! **CHAPTER XX** _**An Amazing Revelation**_ "DO YOU know what I'm going to do?" Tammi Whitlock panted as she tried to strike Nancy in the face. "I'm going to fix you so your acting career—" Before she had a chance to finish her sentence, Mr. Spencer came dashing onto the stage. His face was livid as he cried out, "What's the meaning of this? Tammi Whitlock, stop that!" Without waiting for her to obey, he yanked the actress away from Nancy. "While I've been home with laryngitis, you've been getting away with something out here, haven't you, Hamilton Spencer?" Tammi screamed hoarsely. "You didn't ask _me_ about putting on a puppet show! Emmet Calhoun told me about it on the phone. I had other plans for the Footlighters—much better plans." Nancy, weak from the battle with Tammi, sat down on a couch. She managed to describe to Mr. Spencer her sudden encounter with Tammi as a dancing puppet. "Yes, I was practicing," Tammi went on, "so I could ruin that next show. I was going to come on as a puppet and spoil everything. I'll still do it!" she croaked. Mr. Spencer, now that he had recovered from his astonishment, glared at the girl. "You'll do nothing of the sort," he said. "Furthermore, I shall see to it that you are asked to resign from the Footlighters!" "You wouldn't dare!" Tammi could barely whisper now. At this moment Emmet Calhoun rushed out on the stage to see what the commotion was. At once Tammi flew at him, her eyes blazing, and said in a fierce whisper, "You're the one who started everything going wrong. If you'd kept away from me, my brother wouldn't be in such a jam, you poetry-spouting old fossil!" This remark angered Calhoun so much that he turned white. "You would do better to study Shakespeare," he retorted stiffly, "instead of running around with night-club performers. There was a time when I thought a great deal of you. But now I see I was wrong." "That's enough!" said Tammi as loudly and vehemently as her laryngitis would permit. "You'd better keep still." But Emmet Calhoun, now that he had started, had no intention of keeping quiet. Turning to Nancy, he said, "I have eavesdropped on you and your friends ever since you came here, because I was interested to find out whether you could locate the lost puppet." Nancy looked at the actor in astonishment. _"You_ knew about the diary?" she asked. "I was idly browsing around the attic one day, and found the diary in the trunk where you saw it," Calhoun replied. "When I first met Tammi and took a liking to her, I realized the great difference in our ages and thought I would need to offer her something really valuable in order to win her. So, foolishly, I told Tammi what I had read in the diary. "I expected she would keep the information to herself, and that together we would hunt for the lost puppet. Tammi just made fun of the idea, so I gave it up. But she had a little scheme of her own. Tammi told me you heard that Chuck Grant is her brother. She had told him the story of the valuable hidden secret, and he in turn sold the information to two men named Terrill and Longman." Nancy was amazed to learn of Tammi's involvement. She looked at the actress and said, "So you're tied in with the mystery of the dancing puppet!" "I never had anything to do with the puppets," Tammi maintained stoutly, "except I did telephone to you once and say I was the dancing puppet. I overheard Mr. Spencer's plan to see your father, Nancy, so I knew about you Drews. I mentioned it to Chuck, and he told Longman, who'd heard of your detecting. He happened to be around here the day you arrived. It was Terrill and Longman who made all the trouble here." "Did you know," Nancy asked her, "that both men are in jail?" "N-no! Oh, it can't be true!" Tammi looked as if she were about to faint. Realizing this, Mr. Spencer helped the actress to the couch on stage. As the whole group sat down, he urged Tammi to tell all she knew about the crooked dealings of Terrill and Longman. Tammi did not speak, so Nancy, now filling in the gaps in the mystery and doing a bit of guess-work, told what she knew of the story. She said the two men had found the cannon balls, probably in the attic, and had hidden them in the hay until they found a market for them. "When I came here to try to find out about the dancing puppet," Nancy went on, "one of these men followed me upstairs with the doll's trunk containing a cannon ball. He hurled the trunk at me, hoping everyone would think it was an accident." Tammi began to cry. She nodded in agreement. With hardly any voice left, the young actress said, "I'll tell you the rest of the story. It was Longman who did that. He later sold the cannon balls to a museum for a good price. He also persuaded me to make that witch phone call—and to spy on you one night. But I didn't realize why. "My brother Chuck is not a bad guy—he's just always in need of money," Tammi went on. "Terrill and Longman had come to the Green Acres Restaurant several times and became acquainted with Chuck. Once when he needed some quick cash, they obliged him. "After that, he seemed to be in their clutches. Finally they asked him to help them with a necklace-lifting racket. For a long time I didn't realize what was going on. I'd go to the various other places where Chuck sang. During his breaks, he'd always talk about the expensive jewelry the women were wearing and asked me to point out someone with a real diamond necklace, or one of pearls or rubies, or other valuable stones. "Then in a little while he would say we had to leave. I would go out to the car and wait for him. In a few minutes Chuck would join me. "After one of these singing engagements, he had slung his jacket over into the back seat of the car, and I saw a diamond necklace fall out of the pocket. When I demanded an explanation, he was forced to confess he was working with Terrill and Longman. Chuck would help distract the patron while Terrill would cut the necklace from the patron's neck. Longman would gently lift it and quick as a wink drop it into Chuck's pocket. Then Chuck would leave. "I begged my brother to get out of the racket, but he insisted he couldn't. The men had told him he was in it too deep and that they would soon have enough money so all three could quit the racket before the police caught up with them." Tammi paused. Then she faced Nancy. "Believe it or not, I'm glad the whole thing is over. I've done nothing but worry for weeks. It has made me cranky and hard to live with. I hope all of you will forgive me. I suppose I'll be punished for my part in this thing. But as soon as I'm free again, I'm going to be strictly honest and go back to the legitimate stage." The others stared at her. "You aren't an amateur?" Calhoun cried out. Tammi shook her head. "In California I had parts in stock companies. When I came East my parents requested that I pretend to be an amateur. They didn't want me to be on the legitimate stage." Tammi buried her face in her hands. "Don't feel sorry for me. I deserve this. I just feel terribly sorry for my mother and father and aunt. They're going to be crushed when the news comes out." She rose from the couch. With Mr. Spencer and Emmet Calhoun, walking on each side of her, she left the theater and went over to the mansion. Nancy learned later that the police had been notified to pick up Tammi and Chuck. Presently the two actors returned to the theater. "We must get backstage," said Mr. Spencer. "Nancy, we've used up all our rehearsal time, but to very good advantage." Nancy, still dazed by Tammi's confession, nodded. Then she said to Mr. Spencer, "Have the prisoners said where they found the puppets?" "In the attic," the actor answered. "The witch and the dancing girl were in a trunk, so evidently someone removed them from the closet a long time ago." Mr. Spencer said Chief McGinnis had also told him that Terrill and Longman finally had talked freely about the puppets. The two prisoners had said that they used the dancer to scare residents away from the Van Pelt estate, so they could make a more thorough search. Moreover, they had wanted to test the puppets mechanically, so they could sell or rent them for a fancy price. "Nancy, when you discovered Pierrot, Longman was hiding in the attic. Later he took the puppet." "That means the fourth puppet—the special one—is still missing!" said Nancy. "After the show tonight, let's hunt for it! I still want to know the valuable secret it contains!" That evening's show was another overwhelming success. To make matters more interesting, Bess had been asked to play the part of a minor character. The girl who was to have taken the role had suddenly become ill. Bess, excited and happy, and looking extremely pretty, played the part well. Lines she could not remember she improvised, and her performance brought a good round of applause from the audience. As soon as the show was over, the Footlighters were called together by the Spencers to vote on the idea of a puppet show. There was unanimous acceptance of the plan. Then the actors returned to the mansion and removed costumes and make-up. Congratulations and good-nights were said. As soon as everyone had left, Nancy and the others living in the house hurried to the attic. "I have a hunch that the fourth puppet is hidden somewhere near the secret closet," Nancy said. One by one, trunks and boxes were moved. With a flashlight the girl detective examined the floor carefully. Finally she decided on a spot and asked the men to help her pry up the floor boards. George and Bess each held a flashlight. Margo looked on intently. Suddenly one of the wider boards came free. Below lay a handsome male dancer puppet in Spanish costume! "We've found it!" Bess exclaimed gleefully. She whirled around, causing her light to shine in another direction. "Bring that light back here!" Mr. Spencer called excitedly. He and Emmet Calhoun, with Nancy and Margo helping, pulled up another floor board. The hidden puppet was freed. "He looks almost real!" George remarked. Nancy already was lifting his velvet bolero and white silk blouse to look at his back. In it was a door with a tiny knob. Quickly she turned it and opened the little door. "Papers!" she cried. Nancy pulled them out and with a quick reading of the first page discovered that here were the directions and working drawings for a clever invention. Mr. Spencer was extremely interested. "I studied engineering before I switched to acting," he said. "These drawings are of a device that we now call 'fuel cells'—machines for continuously producing electricity from chemical fuels. The Van Pelt type was to be used on melted aluminum. Of course, fifty years ago that element cost too much to make this invention feasible. But today, with aluminum inexpensive, it's a very worthwhile idea." "Oh, Nancy, you found it!" Bess cried proudly. "It's yours! You can sell it for a mint of money." Nancy smiled and shook her head. "This discovery belongs to the Footlighters, and any money it may bring will go to them." During the momentary silence following Nancy's announcement, the group in the attic heard a voice from downstairs calling, "Anybody home?" Quickly Mr. Spencer descended the stairs, with the others at his heels. When they reached the main hall, everyone burst into laughter. There stood Chief McGinnis, grinning sheepishly. Under one arm he was carrying the Pierrot puppet; under the other, the witch! Behind him, just coming through the doorway was Detective Dougherty, lugging the dancing puppet. Chief McGinnis explained that the two missing puppets had been found in Terrill's apartment. Both had contained several pieces of valuable jewelry. Just as the explanation was finished, the front doorbell rang. Mr. Spencer opened the door. "Good evening, Mr. Trask," he said. "Come in." The actor introduced the caller as the owner of the puppet show which would be presented in the theater a week from that night. Mr. Trask barely acknowledged the introduction. His eyes opening wide, he asked, "Where did these marvelous marionettes come from? If they're for sale, I want to buy them. How much are you asking for them?" Despite the fact that the caller was serious, the whole situation seemed so comical that everyone smiled. Emmet Calhoun threw back his head and gave a long, hollow laugh. Nancy looked at him in amazement. "You were the one who laughed behind the secret closet! How did you do it?" Emmet Calhoun stopped laughing long enough to say, "Nancy Drew, I'm surprised you didn't discover the secret stairway which leads from the closet in my room to the back of that little attic closet. I'm a bit of a detective too, you see. I imagine that stairway opened into the attic years ago." Gaily he quoted the lines from King John: _"'The day shall not be up so soon as I,_ _To try the fair adventure of tomorrow.' "_ "That fits me," thought Nancy. "I'm ready for a new mystery to solve, even if it's before dawn!" Fate was waiting for her to take on _The Moonstone Valley Mystery._ The caller, Mr. Trask, who had been looking on in astonishment, now repeated his offer to buy the puppets. "More money for the Footlighters!" George exclaimed. "Nancy's not only an ace detective, but a money-maker and a top actress!" Nancy waved aside the praise. "The club will vote, of course, on what to do with the puppets; but if you ask me," she added, her eyes twinkling, "we should keep the dancing puppet and her friends. They may come in handy sometime, when a live performance isn't ready to go on!" Mr. Spencer laughed heartily. "Detective Drew," he said, "you're absolutely right. Puppets saved us once, and these just might save us again!"
{ "redpajama_set_name": "RedPajamaBook" }
8,789
\section{Introduction}\label{intro} Realizing a micro- or nano-device exhibiting {\it absolute negative mobility} (ANM) poses serious technological challenges, as this task is believed to require finely tailored spatial asymmetries either in the (nonlinear) particle-particle interactions \cite{INT1,INT2} or, more conveniently, in the geometry of the device itself \cite{augsburg1a, augsburg1b}. A device is said to operate in the ANM regime, when it works steadily against a biased force, i.e., a force with nonzero stationary mean. According to the Second Law of Thermodynamics (or more precisely, the so called principle of Le Chatelier), a static force alone cannot induce ANM in a device coupled to an equilibrium heat bath, unless an additional time dependent force is applied to bring the system out of equilibrium. ANM is known to occur as a genuine {\it quantum mechanical} phenomenon in photovoltaic materials, as the result of photo-assisted tunneling in either the bulk of noncentrosymmetric crystals \cite{quantumANM} or artificial semiconductor structures \cite{gossarda,gossardb}. However, such manifestations of the ANM phenomenon do not survive in the limit of a classical description, so that detecting ANM in a purely classical system remains a challenging task. As spatial symmetry typically suppresses ANM, {\it ad hoc} contrived geometries have been proposed to circumvent this difficulty. The most promising solution devised to date, is represented by two (2D) or three dimensional (3D) channels with inner walls tailored so as to force the transported particles along meandering paths \cite{augsburg1a,augsburg1b}, a design that can be implemented, e.g., in superconducting vortex devices \cite{RMP09}. Other classical set-ups advocate elusive dynamic chaotic effects \cite{augsburg2a,augsburg2b,bielefeld}. Although such finely tuned asymmetric geometries and/or nonlinear dynamic behaviors may seem hardly accessible to table-top experiments, first convincing demonstrations of classical ANM have actually been obtained following this strategy \cite{expANMa,expANMb}. We propose here a much simpler, affordable working concept for a classical ANM device, by embedding the spatial asymmetry into the shape of the transported particles, rather than in the channel geometry. In view of this new formulation, the ANM mechanism is expected to occur in natural systems, too, where cylindrically symmetric channels in low spatial dimensions and elongated particles are frequently encountered \cite{natural,zeolite}. This paper is organized as follows. We introduce in Sec. \ref{model} the Langevin equations for a floating ellipsoidal Brownian particle ac-driven along a 2D compartmentalized channel. By numerical simulation we show in Sec. \ref{mechanism} that ANM actually occurs as an effect of the particle elongation. In Sec. \ref{optim} we analyze the dependence of ANM on both the drive parameters and the particle geometry, with the purpose of determining the optimal operating conditions of our model device. Finally, in Sec. \ref{remarks} we discuss the applicability of the proposed ANM mechanism to nanoparticle transport in realistic biological and artificial devices. \begin{figure}[bp] \centering \includegraphics[width=9cm,clip]{Fig1ANM.eps} \caption{(Color online) (a) Asymmetric particle tumbling in a periodically segmented 2D-channel. The pores, $2\Delta$ wide, are centered on the channel axis. (b) Elliptic particle with semiaxes $a$ and $b$, at rest against a compartment wall. Note that $a<\Delta<b$. (c) Elliptic particle in escape position, its major axis forming a maximum angle $\phi^*$ with the channel axis. \label{F1}} \end{figure} \section{The model}\label{model} Let us consider an elongated Brownian particle, shaped as an elliptic disk, moving in a straight 2D channel (Fig. \ref{F1}). The overdamped dynamics of the particle is modeled by three Langevin equations, namely \begin{subequations} \label{le} \begin{align} \frac{d{\vec r}}{dt}& = -F(t)\;{\vec e}_x + \sqrt{D_r}~{\vec \xi}(t)\, ; \\ \frac{d\phi}{dt} &= \sqrt{D_\phi}~\xi_\phi(t)\, , \end{align} \end{subequations} where ${\vec e}_x, {\vec e}_y$ are the unit vectors along the $x, y$ axes, ${\vec r}\equiv (x,y)$ denotes the particle center of mass, and $\phi$ is the orientation of its major axis with respect to the channel axis, ${\vec e}_x$. Here, ${\vec \xi}(t)\equiv (\xi_x(t),\xi_y(t))$ and $\xi_\phi(t)$ are zero-mean, white Gaussian noises with autocorrelation functions $\langle \xi_i(t)\xi_j(t') \rangle = 2\delta_{ij}\delta(t-t')$ and $i,j=x,y,\phi$. The channel is periodically segmented by means of orthogonal compartment walls, each bearing an opening, or pore, of half-width $\Delta$, placed at its center \cite{bu}. As sketched in Fig.~\ref{F1}(a), the channel is mirror symmetric with respect to both its longitudinal axis and each compartment wall. This is an important difference with Ref. \cite{augsburg1a,augsburg1b}, where the channel confining potential, $V(x,y)$, was taken to be asymmetric under both mirror reflections -- although symmetric under double reflection, $V(-x,y)\doteq V(x,-y)$. In order to detect ANM, the particle must be driven in a pulsating manner parallel to the channel axis. This means that $F(t)$ consists of at least two terms \cite{augsburg1a,augsburg1b}: a dc drive, $F_0$, and an unbiased, symmetric ac drive, $F_{ac}(t)$, with amplitude $\max \{|F_{ac}(t)|\}= F_1$ and temporal period $T_\Omega$. Accordingly, the waveform of $F_{ac}(t)$ is subjected to the conditions $\langle F^{(2n+1)}_{ac}(t)\rangle_\Omega=0$, with $n=0,1,2 \dots$ and $\langle \dots\rangle_\Omega$ denoting the time average taken over one drive cycle \cite{criteria}. Equations (\ref{le}) have been numerically integrated for an elliptic disk of semiaxes $a$ and $b$, under the assumption that the channel walls were perfectly reflecting and the particle-wall collisions were elastic \cite{lboro1}. In the following we report the outcome of extensive simulations for a fixed channel compartment geometry, $x_L=y_L$, $\Delta/y_L\ll 1$, but different particle elongations, $b/a$, ac drive waveforms, and ratios of the rotational to translational diffusion coefficients, $D_\phi/D_r$. We conclude that ANM occurs in such a highly symmetric channel geometry only because of the elongated aspect ratio of the drifting particle. As illustrated in panels (b) and (c) of Fig. \ref{F1}, an elliptic disk with $a<\Delta<b$ crosses a narrow pore only when its major semiaxis forms a small angle with the channel axis, $|\phi|\leq \phi^*$. For $a\ll b$ (rod-like particle) as in most of our simulations, $\sin \phi^*\simeq \Delta/b$. To overcome the escape angle $\phi^*$ from a rest position with $\phi=\pi/2$, the disk must rotate against the total applied force, $F(t)= F_0 + F_{ac}(t)$. For $F_0<F_1$ this is more easily achieved for pore crossings occurring in the direction of $F_{ac}(t)$, but opposite to the static force $F_0$. As a result, under appropriate conditions, detailed below, the net particle current, $\langle v \rangle$, may indeed flow in the direction {\it opposite} to $F_0$. \begin{figure}[tp] \centering \includegraphics[width=9cm,clip]{Fig2ANM.eps} \caption{(Color online) ANM for a driven-pulsated elongated Brownian particle: current $\langle v \rangle$ vs. static bias $F_0$ in the presence of square-wave drives with amplitude $F_1=2$ and different periods $T_\Omega$ (see legend). Other simulation parameters: Diffusion strengths $D=D_r=D_\phi=0.1$; shape parameters $a=0.05$, $b=0.3$; compartment parameters $x_L=y_L=1$, and $\Delta=0.1$. Each data point for $\langle v \rangle\equiv \lim_{t\to \infty}\langle x(t)-x(0)\rangle/t$ was computed from a single trajectory with $t=10^6$ and time-step $10^{-5}$; the statistical error was estimated to be $5\%$, i.e., of the order of the symbol size. Note, for a comparison, that the compartment traversal time is $\tau_0=7$ and the diffusive relaxation times are $\tau_D^{(x)}= \tau_D^{(y)}=5$. The dotted curve represents $v(F)$ at zero ac-drive, $F_1=0$. Inset: the corresponding mobility curve (solid curve), $\mu(F)$, is compared with the analytical estimate of Eq. (\ref{mobility}) (dashed curve) for $F_m=0.86$. \label{F2}} \end{figure} \section{The ANM mechanism}\label{mechanism} In order to explain the appearance of ANM, we start looking at the mobility of an elongated particle driven by a constant force $F$ (Fig. \ref{F2}, inset). Let $v(F)$ denote its steady velocity and $\mu(F)=v(F)/F$ the relevant mobility, with $\mu(-F)=\mu(F)$. From now on, and until stated otherwise, we set for simplicity $D_r=D_\phi=D$, so that $\mu$ is a function of $F/D$. At equilibrium with $F=0$, $\mu_0 \equiv \mu(0)$ is a $D$-independent constant, which strongly depends on both the compartment and the particle geometry as discussed below. For zero drive, the particle rotates away from the walls; pore crossing is thus controlled mostly by {\it translational} diffusion. As the magnitude of the applied force is increased, the mobility of elliptic and circular disks develop a quite different $F$ dependence. The mobility of a circular disk with $a=b<\Delta$, $\mu(F)$, is a concave function of $F/D$, which decays from $\mu_0\equiv \mu(0)$ to $\mu_\infty \equiv \mu(F\to \infty)=(\Delta-a)/(y_L-a)$, with a power law slower than $F^{-1}$ \cite{lboro1}. In the case of an elliptic disk with $a<\Delta<b$, reaching the escape angle $\phi^*$ can be regarded as a noise activated process with energy barrier proportional to $F$. Pore crossing will then be controlled mostly by the {\it rotational} fluctuations, with approximate escape time \begin{equation} \label{time} \tau_0(F)=\tau_0 \exp{(F/F_m)}, \end{equation} where $F_m=2D/(b\cos \phi^*-a)$ is the total activation force, the factor 2 accounts for the two directions of rotation, and $\tau_0$ is the compartment traversal time, $x_L/F$, divided by the probability, $p=(\Delta-a)/(y_L-a)$, that the disk slides through the pore without an additional rotation. The reciprocal of $\tau_0$ plays the role of an effective attack frequency. This estimate for the particle crossing time surely holds good for $b\gg \Delta$ and $F \gg F_m$, where \begin{align} \tau_0 \ll \tau^{(x)}_D,\tau^{(y)}_D \ll \tau_0(F)\, , \end{align} with $\tau^{(x)}_D=x_L^2/2D$ and $\tau^{(y)}_D=y_L^2/2D$ denoting, respectively, the longitudinal and transverse relaxation times. The curve $\mu(F)$ for an elongated particle is thus concave for $F < D/x_L$ \cite{lboro1} and decays exponentially for $F\gg F_m$, like \begin{equation} \label{mobility} \mu(F)\simeq \frac{x_L}{F\tau_0(F)} = 2p\exp{(-F/F_m)}, \end{equation} see inset in Fig. \ref{F2}. Correspondingly, $v(F)$ increases like $\mu_0F$ at small $F$ and decays to zero like $x_L/\tau(F)$ at large $F$, going through a maximum for $F \sim F_m$, as confirmed by our simulations, see Fig. \ref{F2}. \begin{figure}[tp] \centering \includegraphics[width=8cm,clip]{Fig3aANM.eps} \includegraphics[width=8cm,clip]{Fig3bANM.eps} \caption{(Color online) (a) Drive waveform dependence: $\langle v \rangle$ vs. $F_0$ for three waveforms of $F_{ac}(t)$, square (as in Fig. \ref{F2}), sinusoidal and ramped, all with $F_1=2$, $D=0.02$, and $T_\Omega=10^3$. (b) Particle inertia dependence: $\langle v \rangle$ vs. $F_0$ for three values of $m=I$, see text. Other simulation parameters are $F_1=2$, $D=0.1$, and $T_\Omega=500$. \label{F3}} \end{figure} A convincing evidence for ANM has been obtained by simultaneously applying to the elliptic disk a tunable dc force, $F_0$, and a low-frequency, square-wave ac force, $F_{ac}(t)$, with amplitude $F_1>F_0\geq 0$. The characteristics curves $\langle v\rangle$ {\it vs.} $F_0$ plotted in Fig. \ref{F2} exhibit a negative ANM branch only for sufficiently long ac drive periods and $F_0<F_1$; for $F_0>F_1$, however, the current is always oriented in the $F_0$ direction, no matter what $T_\Omega$. This behavior can be explained in the {\it adiabatic} regime, where a half drive period, $T_{\Omega}/2$, is larger than all the drift and diffusion times inside a channel compartment, namely, $\tau_{0}$, $\tau^{(x)}_D$, and $\tau^{(y)}_D$ \cite{chemphyschem}. Note that in the opposite regime, ANM is suppressed. The net current can then be approximated by \begin{equation}\label{vsquare} \langle v(F_0)\rangle = \frac{1}{2} [v(F_1+F_0)-v(F_1-F_0)]. \end{equation} As the curve $v(F)$ peaks at $F\sim F_m$, we expect $\langle v(F_0)\rangle$ to develop a negative minimum for $F_0=F_1-F_m$ and a positive maximum for $F_0=F_1+F_m$, as shown in Fig. \ref{F2}. As this holds true only for $F_1 > F_m$, the two peaks have upper bounds \begin{align} |\langle v(F_1-F_m)\rangle| \lesssim \langle v(F_1+F_m)\rangle \lesssim v(F_m)\, . \end{align} For a more quantitative analysis of this phenomenon, we rewrite $v(F_1\pm F_0)=(F_1\pm F_0) \mu(F_1\pm F_0)$, so that the ANM condition, $\langle v\rangle<0$, reads \begin{equation} \label{ANM} \frac{F_1 - F_0}{F_1 +F_0} > \frac{\mu(F_1 +F_0)}{\mu(F_1 -F_0)}\simeq e^{-2F_0/F_m}. \end{equation} The approximate equality on the r.h.s. applies for $0<F_0<F_1-F_m$, where \begin{equation} \mu(F_1 \pm F_0)\simeq \mu(F_1) e^{\mp F_0/F_m}. \end{equation} The above inequality is satisfied for $0<F_0<F^*$, with the turning point, $F^*$, shifting towards zero in the limit $F_1 \to F_m+$, and towards $F_1$ in the opposite limit, $F_1 \gg F_m$. The approximate equality in Eq. (\ref{ANM}) leads to slightly overestimating $F^*$, with no prejudice of our conclusion: In the adiabatic regime, ANM occurs in an appropriate $F_0$ interval $(0,F^*)$ only provided that $F_1>F_m$. \begin{figure}[tp] \centering \includegraphics[width=9cm,clip]{Fig4ANM.eps} \caption{(Color online) Particle elongation dependence: $\langle v \rangle$ {\it vs.} $b$ for different values of $T_\Omega$ (main panel) and of $D$ (inset). Other simulation parameters: square-wave ac-drive with amplitude strength $F_1=2$, and bias $F_0=1$, $a=0.05$, $x_L=y_L=1$, and $\Delta=0.1$. \label{F4}} \end{figure} Finally, we notice that for $F_0>F_1>F_m$ the net current reads \begin{align} \langle v(F_0)\rangle = \frac{1}{2}[v(F_0+F_1)+v(F_0-F_1)] \end{align} and for extremely large $F_0$, it decays to zero like $\langle v(F_0)\rangle \sim \frac{1}{2}v(F_0-F_1)$. Correspondingly, our simulation data in the neighborhood of the turning point $F^* \sim F_1$ are reasonably well reproduced by the linear fitting law, $\langle v(F_0)\rangle \sim (\mu_0/2)(F_1-F_0)$. \section{Selectivity and Optimization criteria}\label{optim} In view of future experimental implementations of the proposed ANM mechanism, we now analyze in detail its sensitivity with respect to both the drive and the particle parameters. We start noticing that the most prominent ANM effect is produced, in fact, by the square waveform $F_{ac}(t)$ adopted in Fig. \ref{F2}. For the sake of a comparison, in Fig. \ref{F3}(a) we plotted $\langle v(F_0)\rangle$ also for other, inversion-symmetric waveforms $F_{ac}(t)$ with the same amplitude and period, in particular, sinusoidal and up-down ramped waveforms. For a ramped ac drive, no ANM can occur, because in the adiabatic regime \begin{align} \langle v(F_0)\rangle=\frac{1}{2F_1}\int_{F_1-F_0}^{F_1+F_0}v(F)dF \geq 0\, . \end{align} For a sinusoidal ac drive, the ANM effect can be shown analytically to diminish in magnitude and shrink to a narrower interval $(0,F^*)$ than obtained for the corresponding square waveform. The latter is thus the optimal ac drive waveform to operate an ANM device. To quantify the robustness of this effect against the damping conditions, inertia was added to the model by replacing the l.h.s. in the Langevin equations (\ref{le}) as follows: \begin{subequations} \label{inertia} \begin{align} \frac{d{\vec r}}{dt}&\to \frac{d{\vec r}}{dt}-m\frac{d^2{\vec r}}{dt^2}\\ \frac{d\phi}{dt} & \to \frac{d\phi}{dt}-I\frac{d^2\phi}{d^2t}\, . \end{align} \end{subequations} In Fig. \ref{F3}(b) we compare ANM characteristics curves for growing values of the (rescaled) particle mass, $m$, and moment of inertia, $I$: ANM is gradually suppressed by increasing inertia. This is no serious limitation, as in most experiments rectifiers operate, indeed, under overdamped, or zero mass, conditions \cite{RMP09}. We analyze next how selective the ANM effect is versus the geometric and diffusive properties of the transported particles. In Fig. \ref{F4} we displayed the dependence of the net current on the particle elongation. One notices immediately that, when plotted versus $b$ at constant values of the drive parameters, $\langle v \rangle$ starts out positive and then turns negative for $b$ larger than a certain threshold, $b^*$, which appears to increase with either raising $D$ (figure inset) or lowering $T_\Omega$ (main panel). Our adiabatic argument provides a simple explanation for these findings, as well. We recall that the mobility curve $\mu(F)$ decays exponentially on a scale $F_m\propto b^{-1}$. As a consequence, for $b \to \infty$, Eq. (\ref{vsquare}) boils down to $\langle v \rangle \simeq -\frac{1}{2}v(F_1-F_0)$, which means that $\langle v \rangle$ tends to zero from negative values, in agreement with our data. For $b\leq \Delta$ the particle flows through the pores, no matter what the orientation, $\phi$, of its major axis. Therefore, $\langle v \rangle$ becomes insensitive to the particle elongation (main panel), while retaining its known $D$ dependence (inset). The actual value of $b^*$ is determined by the general ANM condition (\ref{ANM}). On making use of the approximation on the r.h.s. of that equation, one easily proves the existence of the threshold $b^*$ for any geometry and drive parameter set. We caution that this way one may underestimate $b^*$ and, therefore, the predicted dependence $b^* \propto D$ holds qualitatively, only (see inset of Fig. \ref{F4}). Of course, when $D$ is raised so that $b^*$ grows larger than the spatial dimensions of a channel compartment, then ANM is suppressed altogether. \begin{figure}[tp] \centering \includegraphics[width=8.5cm,clip]{Fig5ANM.eps} \caption{(Color online) Rotational translational diffusion dependence: $\langle v \rangle$ {\it vs.} $D_\phi/D_r$ for different values of $D_r$ (see legend). Inset: $\langle v \rangle$ {\it vs.} $D=D_r=D_{\phi}$ with $D_\phi/D_r=1$. The arrows mark the asymptotes predicted in the text. Other simulation parameters are as in Fig. \ref{F4} with $b=0.3$.} \label{F5} \end{figure} The dependence of the current on the fluctuation intensities is illustrated in Fig. \ref{F5}. We consider first the case $D_r=D_\phi=D$ (figure inset). The dependence of $\langle v \rangle$ on $D$ can be analyzed following the approach introduced to interpret the results in Fig. \ref{F4}. On recalling that $F_m \propto D$, in the limit $D \to \infty$, the ac drive amplitude ends up being smaller than $F_m$, $F_m>F_1$, thus suppressing ANM. In the opposite limit, $D\to 0$, $F_m$ vanishes and ANM is predicted to occur for any dc drive such that $0<F_0<F_1$. Indeed, from Eq. (\ref{vsquare}) we obtain $\mu(F_1\pm F_0) \to \mu_0$ or $\langle v \rangle \to \mu_0 F_0>0$, for $D\to \infty$ (marked in figure by horizontal arrows), and $\langle v \rangle \simeq -\frac{1}{2}v(F_1-F_0) \to 0-$, for $D \to 0$. On using $D$ as a control parameter, ANM is thus restricted to low noise, $0<D<D^*$, with the threshold $D^*$ also obtainable from the ANM condition (\ref{ANM}). We consider next the more general case when $D_r$ and $D_\phi$ can be independently varied, while keeping $a$ and $b$ fixed. In Fig. \ref{F5}, $\langle v \rangle$ has been plotted versus $D_\phi/D_r$ for different values of $D_r$. The two opposite limits of the net current, $\langle v \rangle_0$, for $D_\phi/D_r\to 0$, and $\langle v \rangle_\infty$, for $D_\phi/D_r\to \infty$, are both positive with $\langle v \rangle_0<\langle v \rangle_\infty$. In between, the magnitude of the ANM effect is seemingly not much sensitive to $D_\phi/D_r$ over several orders of magnitude, which allows us to generalize the conclusions drawn above for $D_\phi/D_r=1$ to the case of realistic extended particles. Note that $\langle v \rangle_0$ is non-null because an elliptic disk with $a<\Delta<b$ can diffuse across a pore even in the limit $D_\phi\to 0$, where the adiabatic argument fails, thanks to the sole translational fluctuations. In view of the crossing condition $|\phi|<\phi^*$, an elongated particle can be handled as a circular one with radius smaller that $\Delta$, see Fig. \ref{F4}, but crossing probability $2\phi^*/\pi$. This argument can be extended to the case of $\langle v \rangle_\infty$, with the important difference that for $D_\phi\to \infty$ the particle has crossing probability one. Both $\langle v \rangle_0$ and $\langle v \rangle_\infty$ are thus positive, with $\langle v \rangle_0$ relatively smaller than $\langle v \rangle_\infty$. \section{Concluding remarks}\label{remarks} The ANM model presented in this work, although stylized, lends itself to interesting nano-technological applications \cite{RMP09,chemphyschem}. A typical reference case is represented by the transport of hydrated DNA fragments across narrow compartmentalized channels \cite{dekker}. Rod-like DNA fragments $30$-$40$nm in length and $1$-$2$nm in (hydrated) diameter are easily accessible \cite{tirado}; their elongation ratio is about $3$ times larger than $b/a$ in Fig. \ref{F2}, but still within the ANM range of Fig. \ref{F4}. Artificial nanopores can be TEM drilled in $10$nm thin SiO$_2$ membranes with reproducible diameters of $5$nm, or less \cite{dekker}, which is consistent with the elongation selectivity condition $a<\Delta<b$ assumed throughout this work. Moreover, the measured $D_\phi/D_r$ ratio for the hydrated DNA fragments of Ref. \cite{tirado} falls in the range $100$-$200$, in dimensionless units, where ANM can also occur, as shown in Fig. \ref{F5}, for an appropriate choice of the drive parameters. To this regard, we remind that experiments on DNA translocation across artificial nanopores require applied electrical fields of the order of 10-100kV/cm \cite{healy}; if applied to the DNA rods of Ref. \cite{tirado}, electrical fields of that intensity, or less, would satisfy the ANM condition of Eq. (\ref{ANM}) with $F_1>F_m$ at room temperature. The ANM characteristics curves plotted in Figs. \ref{F2} and \ref{F5}, being quite selective with respect to the particle shape, suggest the possibility of developing artificial devices that efficiently operate as {\it geometric sieves} for nanoparticles. Our model was stylized to capture the key mechanism responsible for the occurrence of ANM in symmetric channels. The mechanism summarized by Eqs. (\ref{time}) and (\ref{ANM}), however, clearly does not depend on the dimensionality of the channel (experiments can then be carries out in 3D geometries), but can be impacted by other competing effects: (i) Pore selectivity. For a given translocating molecule, the actual crossing time varies with the wall structure inside the pore and in the vicinity of its opening \cite{iqbal}; (ii) Electrophoretic effects. The inhomogeneous electrical field generated by the electrolyte flow across the pores acts on the orientation of drifting spheroidal particles \cite{solomontsev}. System specific effects (i) and (ii) can readily be incorporated in our model by adding appropriate potential terms, $U_r(x,y)$ and $U_\phi(\phi)$, to the Langevin equations (\ref{le}). \acknowledgements{ The work is supported by the Humboldt prize program (F.M.), Humboldt-Bessel prize program (S.S.), the Volkswagen foundation (P.H., G.S.), project I/83902, The European Science Foundation (ESF) under its program ``Exploring the physics of small devices" (P.H.) and by the German Excellence Initiative via the Nanosystems Initiative Munich (NIM) (P.H., G.S.).}
{ "redpajama_set_name": "RedPajamaArXiv" }
9,852
# **PARTY PARTY** _Amy Dodd and Nicholas Latimer Also to Calico, who always observed and enjoyed the entire process!_ **JENNY DODD** ## **ACKNOWLEDGEMENTS** With the production of a book there are so many people who operate behind the scenes, and without whom the publication would not be possible. The process for me started with Linda de Villiers, to whom I extend my first vote of thanks. Thank you, Linda, for your trust, input of ideas and enthusiasm, which has once again allowed me to put my ideas into print. Sincere thanks to Beverley Dodd, the designer, who also wears the cap of 'my daughter'. Bev, you manage to balance the two roles admirably, challenging me with regard to your professional requirements whilst always providing me with the encouragement to explore my own ideas. I am privileged to be able to utilise your indisputable talent. Without the expertise of Joy Clack's phenomenal editing skills the manuscript would not have been possible. Thank you so much for your valuable input and for teaching me the essentials of being absolutely precise with instructions; it has paid dividends! Amy Dodd, thank you for your contribution to this book, particularly with the Farmyard Frolics theme and the Cutting the Ice birthday cake. Not only did I value your assistance but I also appreciated your interest in each and every theme. Ryno, it was again such a privilege for me to partake of your skills and to be able to benefit tremendously from your attention to detail; thank you so much for capturing the fruits of my labour so admirably! Brita du Plessis and her team of Vaune Desmarais and Jen du Plessis worked tirelessly to produce the enchanting displays that contribute so much to the theme setting of the individual parties – thank you for your amazing talent which encapsulated the scenes perfectly! My amazing family – Cedric Dodd, Natalie Dodd, Nicholas Latimer, Keith and Kevin Rowland, Yvonne and Theo von Ruben – I appreciate your assistance and tremendous support. **JENNY DODD** **Note:** While every effort has been made to ensure that the information contained in this book is accurate, the author and publishers accept no responsibility for any loss, injury or inconvenience sustained by any person using this book or following the advice given in it. Published in print in 2010 by Struik Lifestyle (an imprint of Random House Struik (Pty) Ltd) Wembley Square, First Floor, Solan Road, Cape Town 8001, South Africa P.O. Box 1144, Cape Town, 8000, South Africa This ebook edition published in 2012 Copyright © in published edition: Random House Struik 2010 Copyright © in text: Jenny Dodd 2010 Copyright © in photographs and illustrations: Random House Struik 2010 ISBN 978 1770077 782 (print) ISBN 978 1 43230 042 5 (Epub) ISBN 978 1 43230 043 2 (Print) Log on to our photographic website **www.imagesofafrica.co.za** for an African experience All rights reserved. No part of this publication may be reproduced, stored in a retrieval system or transmitted in any form or by any means, electronic, mechanical, photocopying, recording or otherwise, without the prior written permission of the copyright owner/s. PUBLISHER: Linda de Villiers MANAGING EDITOR: Cecilia Barfield EDITOR: Joy Clack DESIGNER: Beverley Dodd PHOTOGRAPHER: Ryno ILLUSTRATOR: James Berrangé STYLIST: Brita du Plessis STYLIST'S ASSISTANTS: Vaune Desmarais and Jen du Plessis PROOFREADER: Tessa Kennedy ## **CONTENTS** Introduction Dotty Do Putting Par-tee Small Affair Winning Formula 1 Birthday Bugs Cooking up Fun Cutting the Ice Destination Mars Enchanted Forest Farmyard Frolics Feisty Fire Engines The Big Number 1 Karate Kicks My Special Pony Shipwrecked and Stranded World Cup Soccer Stone Age High School Rock Crime Scene Travel to Egypt Recipes Templates Stockists Index ## **Introduction** A birthday in the house? Upon reflection of the miracle of birth and the joyous blessing of children, the planning of the celebration of the happy event becomes an absolute necessity! Birthdays are always anticipated with a great deal of excitement; the planning and preparations for this special day contribute so much to the enjoyment of the occasion and seem to stretch the actual birthday to so many extra fun-filled days! My third party guide is once again intended to assist (and enlist) the entire family in the fun-filled pre-planning of the event. Hosting a birthday party for your child can be so much fun that before you close the door on the last guest, pluck the last streamer from the ceiling and dispose of the last torn bit of wrapping paper, you will already be mulling over ideas for the next one! The recipe for success is to plan ahead. Party accessories are currently big business and most outlets have a variety to enhance any theme. Confectionery suppliers and sweet manufacturers add to the simplicity of cake decorating and theme co-ordination with their vast array of goods to complement the party table. Prepare a guest list and place it in an accessible position where the birthday child may record the RSVPs. Do remember to record the happy event by taking an abundance of photographs and include a video as well, if possible. These will provide treasured memories that will last forever! I trust that you and your family will spend many happy hours together planning the most special day on your child's calendar, and that the ideas in this book will contribute to the joyous family event. Should circumstances dictate that you are unable to host a birthday party, your little one may nevertheless feel special on his or her day by taking a batch of cupcakes or biscuits to school to be shared with classmates. The treats demonstrated throughout the book are easily prepared in advance and are guaranteed to delight. ### **PARTY PREPARATIONS** Make the cake well in advance and not on the day of the party! Assemble the cake and coat with a layer of icing. Once the cake has been iced it may be covered with a large plastic bag and frozen until the day before the party, when the finishing touches may be added. Cupcakes and biscuits may also be made in advance and frozen, again adding the final decorations on the day before the party. ### **PARTY THEMES** The themes depicted in this book can be achieved relatively quickly and easily and at a low cost, but you may wish to adapt them to suit personal time and budget constraints. Many of the ideas are interchangeable. ### **PARTY DÉCOR** Setting the scene for the party need not be a formidable chore, especially if planned in advance. The entire family may be involved in creating the various items that contribute to the enchantment of the chosen theme. The basic décor will always include streamers and balloons. Streamers (50 mm wide) cut from sheets of crepe paper are easy to make and, when twisted before hanging, create a wonderful canopy above the party table that can reflect the dominant colours of the theme. Use a pair of pinking shears when cutting the streamers to add to the effect. Staple the ends of the streamers together to increase the length as necessary. Balloons always add extra appeal to any party atmosphere. It has become standard practice to tie a bunch to the garden gate, allowing easy identification of the party venue and to let the rest of the neighbourhood know that a very special day is being celebrated. Tie balloons in bunches (the theme will determine the colours) in the corners of the party room, and wherever else the children are likely to gather. Add curling ribbons to enhance the festive appearance. Take care of broken bits of balloon and dispose of them immediately as they may be dangerous if swallowed. (I prefer to use balloons for decorative purposes only, apart from inclusion in a few games where they will be handled under supervision of the games co-ordinator.) Party banners are very easy to assemble. Simply cut shapes from paper, card or fabric to complement your theme, and fold one end over a length of string and glue or staple to secure. Hang the completed banner against the wall in the party area. Extra tips and décor ideas have been included at the start of each theme. ### **INVITATIONS** Invitations should be distributed two to three weeks before the party. Always include an RSVP date to facilitate catering as well as the preparation of the games – contact the parents who haven't replied to ascertain whether their child will be accepting the invitation, especially when an outing is being planned. Provide the birthday child with access to the guest list so that he or she may tick off the names as the replies are received. Apart from the starting time, stipulate the time that the party will end so that parents collect the children punctually. Ensure that the duration of the party is not too long – two hours is sufficient for most parties – to prevent children tiring. Parties for the babies and toddlers may be restricted to 1½ hours, whilst those for the older children that involve outings will obviously need to be quite a bit longer. Always ensure that you have a contact number for the parents of each guest. The invitation provides a foretaste of the party so try to be original and creative and incorporate party favours where possible. Party favours are becoming more freely available and are thus generally more affordable; once again, shopping ahead is recommended. I have included invitations to complement each theme with easy step-by-step instructions for how to put them together. I have endeavoured to keep them simple, yet appealing, so that the birthday child may assist in making them. I have also included ideas for the wording of the invitation details that are applicable for the theme. Take advantage of the many craft accessories that are available to enhance the invitations. If time is limited, ready-made or computer-generated invitations offer an easy alternative. Encourage the birthday child to add a personal touch to these with, for example, a dab or two of glitter glue and a few beads. ### **TREAT BAGS** These are great as they enable children to take home any party favours and birthday treats that they have accumulated. Instead of setting out all the food on the party table, you may prefer to insert sweets and small packets of potato chips into the treat bags, to be enjoyed at the children's leisure. They are also ideal for a slice of birthday cake (wrapped in a serviette, of course). A nice gesture is to exchange them for the gift when the birthday child opens his or her presents near the end of the party. Include a card in the treat bag that says: 'Thank you so much for making my day special.' Make the bags in advance and your efforts will be rewarded when you see the delight on the recipients' faces! I have omitted to list favours to be included in treat bags as these have been used to adorn the party food. Favours are readily available at supermarkets and discount stores. Pleasant surprises await the mom who plans in advance. Should you prefer to omit the treat bags, the various cone treats make ideal take-home gifts. ### **DRESSING UP** Most children enjoy fancy dress parties, but should you add this stipulation to the invitation, keep the expectations simple to ensure that all the children will be able to participate. It is a good idea to keep a few clothing items and accessories on hand to assist children who fail to arrive in fancy dress. ### **PARTY FOOD** The techniques that I have used for the cakes and other sweet treats are very simple and require only basic decorating tools. A toothpick and a pair of tweezers are invaluable aids. For icing, the star nozzle is a favourite of mine as I believe that it provides a neater and more attractive overall appearance. Sugar paste is readily available at baking supply stores and can easily be coloured using powdered food colourings. I have made use of sugar paste as a decorative aid but if you prefer not to you will be able to improvise with butter icing or sweets. I have used a limited range of ingredients (cupcakes, cones and biscuits, for example) and adapted them with ease according to the theme. The cones always lend a special charm to the party table display and, as mentioned above, may be distributed at the end of the party. Quantities for the recipes in the party food section are not provided as these will vary according to the number of guests. Colour schemes may obviously be altered according to preference. To enhance the visual impact of the party food, I use simple toys and also take advantage of the huge selection of sweets that are available from speciality shops and supermarkets. Shops are stocking a larger variety of party favours, which makes it easier to find inexpensive toys to complement most themes. To illustrate how toys and sweets can contribute to the ease of decorating whilst lending a special charm to the party table, I have concentrated largely on sweet treats. When using sweets on the cakes and other treats remember to consider the age of the children and refrain from using, for example, hard sweets for toddlers' parties. Toys too should be age related so that small objects that may be swallowed don't constitute a danger for the little ones. The treats presented offer alternative choices; it is obviously not my intention that all are included in each party. You may wish to choose one or two options and combine the sweet treats with your own savoury specialities. ### **GAMES AND ACTIVITIES** I have suggested that the winner receives a prize and the rest receive a small token. These may be in the form of stickers or similar inexpensive items. Discount stores and others offer a variety of packs of erasers, etc. that may be split and used to ensure that none of the children feel excluded. The games have been provided as inspiration and to assist with the party planning, but you may prefer to hire entertainment. Consult your local directory for providers in your area and remember to book in advance to avoid disappointment. When planning a party at an outdoor venue, always check the facilities ahead of time. Ensure that you have sufficient, secure transport for the party children. Enlist the help of a friend(s) so that children are well supervised throughout the event. Children should not be permitted to attend cloakrooms or other facilities unaccompanied. Before departure divide the children into groups and delegate each to a helper so that there exists a clear understanding of who is responsible for each child. For younger children you may colour code the different groups to avoid confusion. ### **THANK-YOU NOTES** Children should adopt this courtesy from an early age. Choosing a gift requires time and thought and the guest will be delighted to receive a note of appreciation for the present as well as for attending the party. Keep the note short and, if possible, have the birthday child write it personally. Make a list of the gifts and who gave them whilst the child unwraps them, otherwise it may be difficult to recall who gave what. ## **Dotty Do** ### **SETTING THE SCENE** _Pretty pastels, black and white, or vibrant primary colours? Once you've decided on your colour scheme, all that remains is to go completely dotty!_ * Use cardboard to cut out dots of varying sizes and spray or paint them in the colours of choice. Alternatively, purchase coloured board and cut out dots. Enlist the family to assist with this a few weeks ahead of time. * Attach a cluster of three or four large dots to the front gate by punching two symmetrical holes through each of the dots. Thread matching curling ribbon through the holes and tie the ends in a knot around the gatepost, allowing the excess ribbon to trail down in curls. * Lay a path of dots to the front entrance by attaching Prestik® or Blu-tac™ to the back of each. If you like, get arriving guests to count the dots as they skip from one to the other, in exchange for a small token at the party entrance. * Set up a face-painting station manned by a friend to adorn the little faces with dots in colours to match the theme. * Attach dots to the floors and walls throughout the party venue. * Thread dots of varying sizes onto differing lengths of fishing line and suspend them from the ceiling of the party room. * Cover the table with a polka-dot cloth or use a polka-dot runner over a plain cloth, if preferred. Use round platters for 'round' food. Polka-dot table accessories are relatively easy to find so shop around ahead of time. **_Recommended age group: 4–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Firm coloured card for large circle** **Scissors** **Contrasting card(s) in colour(s) of choice, or generate on the computer, as preferred** **Craft glue** **Notepaper in matching colour for party details** **Small round craft mirror** 1. Make a template from a small plate or saucer and cut out one circle from the card for each guest. 2. Use appropriate small, round articles as templates to create smaller circles in chosen colour(s) and sizes. 3. Arrange the smaller circles on the larger one and fix with glue. (Alternatively, generate on the computer and print on the coloured card.) 4. Write the party details on the coloured note paper – trimmed to size to fit the invitation without protruding – and glue in place on the back of the large circle. 5. Attach the mirror to the card with craft glue. **SUGGESTED WORDING** Look into the dotty mirror to see who has been invited to join the dots at (child's name)'s birthday party on (date) **The Dotty do:** (address) **Be there on the Dot from:** (duration of party) **RSVP:** The Dotty Lady at (phone number) **Dress:** Dots, dots and more dots! ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Circles of varying sizes in colour(s) of choice (either cut from coloured paper or computer-generated, as per the invitation)** **Scissors** **Craft glue** **Small white cake box** **Ribbon, 450 mm in length** **Polka dot bow, ready purchased (optional)** **Glitter pen** 1. Cut out coloured circles and use craft glue to attach them to the lid of the box. 2. Wrap the ribbon around the box to seal, securing with craft glue; add the bow to enhance. 3. Write the guest's name on one of the circles using the glitter pen. ### **GAMES AND ACTIVITIES** #### **Join the Dots** **You will need (per team):** Identical dot-to-dot activity drawing Craft glue, or Prestik® or Blu-tac™ Firm cardboard Felt-tip marker or thick crayon Enlarge the dot-to-dot drawings for ease of play, and use the glue or Prestik® to affix to the cardboard. Mount the posters against a wall. The children form two teams and line up one behind the other at a predetermined distance from the posters. Each team leader is provided with a felt-tip marker or thick crayon. On starter's orders the first child in each group runs to the poster and commences the game by joining the first dot to the second. Upon completion the child runs back to his or her group and hands the crayon to the next child, who continues the exercise. The game continues with the two teams competing to finish the drawing first. Children may have more than one attempt at the drawing, depending on the number of dots in the activity. Each child in the winning group receives a small (round, of course!) prize, the rest receive a token. #### **Flip the Dot** **You will need (per team):** Small frying pan Round dotty beanbag The children are divided into two teams and each team lines up behind a length of tape. The front child holds a small frying pan containing the beanbag (the dot). A marker is placed a few metres in front of each team. On starter's orders the front child in each team has to run around the marker whilst flipping the dot along the route. Upon returning to the team the pan is handed to the next child, who repeats the process. The game continues until each child has had a turn. In the event of a dropped dot the runner has to return to the starting point to commence again. The winning team (all players successfully 'flipped') receives a small prize, the rest receive dotty tokens. #### **A Dotty Snake** **You will need:** Small plate as template, if using cardboard Coloured cardboard (or small coloured paper plates, one per guest) Hat elastic Sheet of paper Pen Ahead of time, use the small plate as a template to draw sufficient circles for all the guests. Make a dot 'hat' for each child by punching two symmetrical holes in each of the circles and threading hat elastic through the holes so that the dot may be worn on the head. Choose two leaders. Divide the rest of the children into two teams, and give each team a set of numbers. The numbers are duplicated and start from one, leading up to the number that ties in with the number of children participating in each team. All children are then permitted to mingle freely to the happy tunes of joyful music. On starter's orders the leaders are requested to start forming their snake. Their task is to 'join their dots' by placing the children in numerical order. Children open their papers only once they have been touched by the leader, who then has to ascertain from the individual whether he or she is a certain number – children are only permitted to say yes or no and may only be asked one question 'per touch'; they are not allowed to divulge their numbers unless it is the one called by the leader! As each child is identified they have to place their hands on the waist of the child in front of them whilst running about to find the rest of their 'snake'. The first team to have its players in numerical order (proof of number has to be retained in their hands) is the winner. Each member of the winning team receives a small prize, the rest receive a token. ### **PARTY FOOD** #### **A Dotty Duo** **Easy Biscuits (page)** **'Gingerbread' boy and girl cookie cutters** **Icing (page) – lilac, yellow, red, blue** **Mini Smarties®** **Small silver balls** **Large silver balls** 1. Prepare the biscuit dough as per the recipe. Use the cookie cutters to cut out shapes and bake as directed. 2. Create the clothes using icing and the star nozzle. Decorate with mini Smarties®. 3. Use the star or multi-hole nozzle to add the hair. Use the writing nozzle for the eyes and mouths. 4. Attach small silver balls to the hair and use the large balls for buttons. #### **The Sweetest Dots** **Party Cupcakes (page)** **Hundreds and thousands** **Paper cookie cups (baking cases)** **Sugar paste – white** **Powdered food colouring – purple** **Icing (page) – lilac** **Edible glitter** 1. Prepare the cupcakes according to the recipe, adding ¼ cup (60 ml) hundreds and thousands to the batter before pouring into the cookie cups. Bake, and then allow to cool completely. 2. Colour some of the sugar paste with the powdered food colouring. Roll out to a thickness of 4 mm. Use the base of an icing nozzle to cut circles from the sugar paste. 3. Roll out white sugar paste to a thickness of 4 mm. Cut out slightly larger circles than those from step 2. 4. Use the star nozzle to coat the cupcakes with icing. 5. Place a white circle on each cupcake and top with a purple circle, securing with a dab of icing. 6. Brush with edible glitter. #### **Fashionably Dotty** **Sugar paste (optional)** **Powdered food colouring – purple** **2 × Marie biscuits or Rich Tea™ biscuits** **Icing (page) – lilac, purple** **Marshmallow** **Small flower cutter (optional)** **Silver balls** 1. Colour a small walnut-sized ball of sugar paste with purple food colouring. Roll out to about 3 mm and cut out small flowers. Set aside to firm up. (Alternatively, as the second last step, use the star nozzle to pipe two 'flowers' on the hat brim.) 2. Sandwich the Marie biscuits together with lilac icing. 3. Coat the upper biscuit with lilac icing. Place the marshmallow in the centre of the biscuit and coat with more lilac icing. 4. Attach the flowers to the brim of the 'hat' and enhance with silver balls. 5. Use the writing nozzle to cover the hat with purple dots of icing, as illustrated. #### **Dot-to-dot Flapjacks** _**Makes 30–36 flapjacks**_ **1 × packet ready-mix flapjack (crumpet) mix** **Cookie cutter of choice** **Icing (page) – purple, or mini Smarties®** **1 × plastic syringe per child** **1 × tin caramel filling** 1. Prepare the flapjacks in advance, as per instructions. 2. Use the cookie cutter to mark out a pattern, for example a star, heart, square, and so on. Place icing dots or mini Smarties® in strategic positions. 3. Fill the plastic syringes with caramel and allow each child to connect the dots on their flapjack using the syringe. 4. This is great fun, but be sure to provide plenty of wet cloths to wipe the sticky fingers! (The children will enjoy the caramel residue left in their syringes.) ### **A DOTTY DELIGHT BIRTHDAY CAKE** **1¼ × Basic Cake (page), baked in 2 × 200 mm round tins and 2 × 120 mm round tins** **Sugar paste** **Powdered food colouring – purple, green** **Icing (page) – lilac** **Wooden skewer** **Purple ribbon, approximately 1 metre in length** **Edible glitter** **Small ornamental purple butterfly** **Florist's wire** **Prestik® or Blu-tac™** 1. Bake the cakes according to the recipe and allow to cool completely. (The smaller cakes are baked for approximately 20 minutes.) 2. Colour the sugar paste with the powdered food colouring and roll out to a thickness of 4–5 mm. Use the base of an icing nozzle to cut out equal-sized dots. Use a cutter with an approximate diameter of 32 mm to cut out larger dots for the flower. Set all aside to firm up. 3. Trim the cakes if necessary with a serrated knife to level the tops. Sandwich the cakes together with icing before completely coating the larger pair with icing. Place the smaller pair on top of the larger cake, securing with a wooden skewer. Coat the top cake with icing. 4. Arrange the ribbon around the base of each cake, securing with extra icing as necessary. 5. Arrange the larger circles to form a flower in the centre of the top cake. Fashion leaves from green sugar paste and arrange around the petals as illustrated. 6. Attach the smaller dots, starting just above the ribbons, to the sides of the cake in neat rows. 7. Dust the flower petals with edible glitter. 8. Attach the butterfly to the wire with a small dab of Prestik®. Insert the wire into the cake so that the butterfly hovers over the flower. ## **Putting Par-tee!** ### **SETTING THE SCENE** _From the first tee to the last, loads of fun will be had with this favourite family theme – parents and older family members (including grandparents!) may enjoy being on this invitation list!_ * Not much needed here as this is an outing! Most miniature golf venues are in locations that are conducive to picnics; investigate your proposed venue prior to planning, and cater accordingly. Confirm that the venue will be open on your preferred date and ensure that you have sufficient adult helpers so that supervision is extended to all guests. * The ideas provided below make the assumption that the birthday cake will be enjoyed at home, either before or after the outing. The suggestions for theme-related treats may be packed in treat bags or served at home, depending on preference. * Attach a tall 'flagstick' pennant to the front gate, to guide guests to the party home. Display the appropriate number of the age of the birthday child on the pennant. * Cover the party table with a green cloth. Scatter plastic airflow balls or dimpled balls and golf tees randomly on the table. Rounds of black paper board attached to the cloth with a blob of Prestik® or Blutac™ may represent holes. * Attach bundles of white and green balloons to the corners of the ceiling over the party table and use fishing line to suspend plastic airflow balls from the ceiling at varying heights above the party table. * You may have an awards ceremony at the end of the party where each child receives a prize. (Make up award titles, for example 'Best Putting Style' or 'Most Outrageous Outfit', to ensure that each child receives a prize.) **_Recommended age group: 8–12 (or 80!)_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Wooden or plastic golf tee** **Plastic dimple golf ball** **Craft glue** **Green notepaper** **Green ribbon, approximately 250 mm in length** 1. Attach the ball to the golf tee with craft glue. 2. Print or write the invitation details (see suggested wording) on the green paper, roll up, tie with ribbon and attach to the tee. **SUGGESTED WORDING** Score at (birthday child's name)'s par-tee on (date) **Collect score card at:** (address) **Golf tournament will be at:** (name of proposed venue) **Tee off at:** (time par-tee starts) **Reach the last hole at:** (time par-tee ends) **Dress:** As for a putting game **RSVP:** The Pro Shop at (phone number) (Ensure that you advise parents to drop children off timeously so that you can get everyone to the party venue on time.) ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Green board paper** **Scissors** **Craft glue** **Green plastic lunchbox-type container with lid** **Black paper circle, 35 mm in diameter** **Small polystyrene ball or white pompom** **Felt-tip marker** 1. Cut out a 'putting green' from the board paper and attach it to the lid of the container with craft glue. 2. Attach the black paper circle to the putting green. Use a dab of glue to add the ball to the 'hole'. 3. Write the guest's name across the 'green' with the felt-tip marker. ### **ABOVE PAR BIRTHDAY CAKE** **1 × Basic Cake (page) – 320 × 220 mm** **Sugar paste** **Powdered food colouring – green, brown** **1 × chocolate-dipped pretzel stick** **Wooden skewers** **Icing (page) – green, flesh, blue** **Edible glitter** **1 × Marie biscuit or Rich Tea™ biscuit, crushed** **Dolls of choice** **Gold balls** 1. Bake the cake according to the recipe and leave to cool completely. 2. Roll a small golf ball from a pinch of sugar paste. Colour some sugar paste with green colouring and fashion a green pennant as for the Score a Birdie Cupcake on page . Set aside to firm up, and then attach it to a pretzel stick with a dab of icing. 3. Fashion 2 putters by moulding a putter head from brown sugar paste and attaching it to a wooden skewer cut to size to fit doll. Set aside. 4. Demarcate the putting course on the cake. Coat the putting green surface with green icing. 5. Colour some more sugar paste with green food colouring and roll out to 3–4 mm thick. Cut out the shape of the putting area and place in position on the cake. 6. Create a slight hollow in the cake for the bunker, and then cover with flesh-coloured icing. 7. Create another hollow in the cake for the water hazard and coat with blue icing. Sprinkle with edible glitter. 8. Coat the sides of the cake with green icing. 9. Use the multiple hole nozzle to create grass on the remaining surface of the cake. 10. Sprinkle the biscuit crumbs in the bunker. 11. Place the flag in position, together with the ball. 12. Attach wooden skewers to the dolls for support and insert into the cake. 13. Use a dab of icing to place the putters in the dolls' hands. 14. Enhance with sugar paste flowers as illustrated. ### **PARTY FOOD** #### **Score a Birdie Cupcake** **Party Cupcakes (page)** **Green paper or foil cookie cups (baking cases)** **Sugar paste** **Powdered food colouring – green** **Icing (page) – green** **Chocolate-dipped pretzel sticks** 1. Bake the cupcakes in the cookie cups as per the recipe. Allow to cool completely. 2. Colour a small fistful of sugar paste with the green food colouring. Roll out to 3–4 mm thick and cut out little flags. Set aside to firm up. 3. Coat the top of the cupcake with green icing. 4. Attach the flag to a pretzel stick with a dab of icing and insert into the cupcake. 5. Roll small golf balls from white sugar paste and add to the scene. #### **A Putting Star** **Easy Biscuits (page)** **Star cookie cutter** **Sugar paste** **Wooden skewer** **Icing (page) – green, black** 1. Prepare the biscuit dough as per the recipe. Use the cookie cutter to cut out stars. Bake according to instructions and leave to cool. 2. Roll the sugar paste into walnut-sized balls, and then cut in half. Place cut-side down and use the blunt end of a wooden skewer to make indentations to resemble a golf ball. Set aside to firm up. 3. Coat the biscuit with green icing and place the half ball in the centre, flat side down. 4. Use the writing nozzle and black icing to pipe facial features onto the ball. #### **In the Bag!** **Sugar paste** **Powdered food colouring – brown** **Chocolate-dipped pretzel sticks** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – green** **Flat-bottomed wafer ice-cream cones** **Wooden skewer** **Liquorice strips** **Small sweets of choice** 1. Roll small balls (one per treat) from the sugar paste and set aside. 2. Colour the rest of the sugar paste with brown food colouring and use to fashion club heads. Attach to the pretzel sticks and set aside to firm up. 3. Coat the top of the Marie biscuit with green icing. 4. Place the cone upright in the centre of the biscuit, pressing slightly to secure. 5. Using the skewer, carefully make two small holes in the side of the cone and insert the liquorice strip to form the bag handle as illustrated. Use a dab of icing to secure if necessary. 6. Use the star nozzle to pipe a row of stars around the base of the bag. 7. Fill the empty cone with sweets and insert the clubs so that the heads protrude. 8. Place the sugar paste ball at the base of the bag. #### **A Hole-in-One Refreshment** **Green paper** **Scissors** **Drinking straws** **Stapler** **Green fizzy cool drink** **Ice cream** 1. Cut a pennant from the paper and attach around one end of a drinking straw using a stapler to secure. 2. Serve green fizzy drinks in tall containers with a rounded scoop of white ice cream floating on top. ## **Small Affair** ### **SETTING THE SCENE** _The birthday child will have so much fun organising this one! Everything is MINImised as all big ideas transform into small ones!_ * Select a preferred colour for your theme. * Attach a bundle of five or six small balloons (you may use the water balloon type) to the front gate with short strips of curling ribbon. * Use the template on page to trace and cut out mini footprints to lead the way to the entrance. * Use a large piece of cardboard and poster paint to fashion a small front door for the party entrance. The board must be big enough to enable you to attach it to your front door frame. Cut along three sides of the cardboard door so that it opens to allow guests to crawl through. Hang curling ribbon along the upper frame of the small doorway. * Use kiddies' furniture throughout the party area. * Cover small tables using serviettes as table cloths. Set aside one small table for the birthday cake. * Place miniature toys on the tables and group the same about the party area and the rest of the house to contribute to the theme of the party. * Attach bundles of small balloons to the corners of the ceiling in the party area. * Use fishing line to suspend mini baubles at varying heights from the ceiling in the party area, interspersed with suspended lengths of curling ribbon. * Use toy plastic tea sets and other small items of crockery and cutlery for serving the food, and use small plastic tot glasses for juices. * Serve mini varieties of popular sweets. * Cocktail serviettes are ideal for the mini foods. **_Recommended age group: 5–8_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Notepaper, 150 mm × 50 mm** **Fine-tipped pen** **Scissors** **Very small envelope (ready bought or self-made)** **Teeny, tiny bow to decorate** **Craft glue** 1. Using the smallest font on the computer, type the party details on the notepaper, or hand print the invitations in your smallest writing. Cut off any excess paper. Once completed, fold tightly and place in the small envelope. 2. Write the guest's name on the envelope and attach the bow using craft glue. **SUGGESTED WORDING** (Child's name)'s Big Bash has become a Small Affair! **Use itty-bitty steps on:** (date of party) **To reach the tiny house at:** (party venue) **Excitement will last from a teensy bit before:** (time party starts) **To a little after:** (time party ends) **RSVP:** The Small Family at (phone number) **Dress:** Mini!! ### **TREAT BAGS** _**These will be symbolic as there won't be space for treats. Distribute at the end of the party as a thank you gesture.**_ **YOU WILL NEED (PER GUEST):** **Notepaper** **Glitter pen** **The smallest box available at party supply stores** **Small gift (for example mini lipstick, mini eraser, small toy bug)** **Ribbon, length depends on size of box** **Craft glue** **Craft flower to decorate** 1. Write a note to each guest, thanking them for attending the party. 2. Fold and place inside the box together with a small token as suggested. 3. Wind the ribbon around the box and knot to secure or use craft glue to attach. 4. Add the decorative flower with a small dab of glue. 5. Write the guest's name (using small type, of course!) on the box using the glitter pen. ### **GAMES AND ACTIVITIES** #### **Mini Party Hats** **You will need:** **Small plate, approximately 18 cm in diameter** **Pencil** **Coloured board paper** **Scissors** **Stapler** **Paper punch** **Hat elastic, cut into measured lengths to fit around a child's chin** **Sequins, small pompoms, beads, glitter glue, curling ribbon, etc. to decorate** **Craft glue** Use the plate and pencil to trace circles onto the board paper. Cut out the circles. Fold the circle in half along the diameter, and then cut along the fold. To assemble the hat, place your thumbs on either end of the cut diameter edge. Bring the ends together, overlapping one over the other to form a cone shape. Staple to secure. Punch two holes on opposite sides near the base of the hat and loop and tie the elastic through these holes. Set up a work area with the decorations and glue laid out in tiny bowls, and allow the children time to make themselves a small party hat. #### **Small Spoon and 'Egg' Race** **You will need (per guest):** **Small teaspoon** **Small pompom** The children stand side by side in a line, balancing the pompom on the teaspoon. On starter's orders the children race to a designated line and back again without dropping the pompom. Children who drop pompoms need to return to the start line and begin again. The winner receives a miniature prize, the rest receive mini tokens. #### **Pin the Small Tail on the Donkey** **You will need:** **Poster paper** **Felt-tip marker** **Material strip for a blindfold** **Donkey tail for each guest (name written on the back)** **Prestik® or Blu-tac™** Draw a picture of a donkey without a tail on the poster paper. Mount the poster on the wall. The children take turns to be blindfolded and spun about lightly two or three times. Armed with their tail to which you have attached a small blob of Prestik®, they attempt to find the correct spot for their small tail. The nearest tail wins a mini prize, the rest of the children receive mini tokens. #### **Small Steps Relay Race** The children form two groups and stand in line one behind the other. On starter's orders the first child in each group moves quickly, taking baby steps (heel to toe), to a predetermined marker and back to the group, and then tags the next child who follows suit. The game continues in the same manner until all the children have had a turn. Each child in the first team to finish receives a small prize, the rest receive mini tokens. ### **PARTY FOOD** #### **Dinky Delight Cupcakes** _**Makes about 48 mini cupcakes**_ **Party cupcakes (page) – halve the recipe** **Mini foil cookie cups (baking cases)** **Icing (page) – yellow, orange** **Small gold balls** 1. Prepare half the cupcake mixture as per the recipe. 2. Place the mini cookie cups in a mini patty pan. Use a teaspoon to fill the cups half to two-thirds full with batter and bake for approximately 8–10 minutes. Leave to cool completely. 3. Use a small star nozzle to coat the top of the cupcake with yellow and orange icing. 4. Embellish with small gold balls. #### **Itsy Bitsy Biscuits** _**Makes about 75 mini biscuits**_ **Easy Biscuits (page) – halve the recipe** **Small cookie cutters – heart, star, flower, etc.** **Icing (page) – yellow, orange** **Hundreds and thousands** **Silver balls** 1. Prepare half of the biscuit dough as per the recipe. 2. Use the cookie cutters to cut out the desired shapes. Bake for approximately 8 minutes, then leave to cool completely. 3. Coat with icing and decorate with hundreds and thousands and silver balls. #### **A Small Freeze** **Melon baller** **Ice cream, flavour of choice** **Small plastic serving dishes** **Small teaspoons** **Selection of ice cream toppings and sauces displayed in mini servers (serve sauces in mini squeeze bottles)** 1. Use the melon baller to scoop small balls of ice cream into mini serving dishes. 2. Allow guests to add their preferred toppings. #### **Mini Jolly Joker** **Mini marshmallow-filled ice-cream cones** **Flat round chocolate sweets or biscuits** **Mini marshmallows** **Icing (page) – orange, red, black** **Small silver balls** 1. Use a serrated knife to remove any protruding filling so that the cone is flat on top. Cut off the tip and set aside for the hat. 2. Place a dab of icing in the centre of the sweet or biscuit to secure and place the cone on top, mallow side down. 3. Coat the cut end of the cone with icing and attach the mini marshmallow for the head. 4. Place a dab of icing on the top of the head and attach the tip of the cone for the hat. 5. Use a small star nozzle to create a ruff and decorate as illustrated. Enhance with silver balls. 6. Add the facial features with the writing nozzle, as illustrated. ### **A TEENY-WEENY BIRTHDAY CAKE** **Basic cake (page) – use ¼ recipe** **2 × 120 mm cake pans** **Icing (page) – yellow, orange** **Edible glitter** **Small cake topper of choice** 1. Prepare the cake batter according to the recipe and divide the mixture equally between the two cake pans. 2. Bake for approximately 20 minutes, and then leave to cool completely. 3. Sandwich the two cakes together with a layer of icing. Coat the sides with icing. 4. Starting at the outer edge of the cake, use a small star nozzle to cover the top with alternating rows of orange and yellow icing. 5. Dust lightly with edible glitter and place the cake topper in position. ## **Winning Formula 1** ### **SETTING THE SCENE** _Guys will rev their engines at this winning boys' bash. Girls enjoy the thrills of Formula 1 racing as well, so don't leave them off the guest list!_ * Paint black-and-white squares for a chequered flag on a piece of material (size optional), or purchase ready made. Tuck one short side of the flag around a wooden dowel and use fabric glue to secure. * Commission Dad or older brother to stand at the front gate with the flag in order to wave winning guests into the party venue. * Chalk white road markings from the front gate to the party area, so the guests may easily find their way; small orange traffic cones will add to the effect and may be used during the games as well. * Old car tyres may be randomly placed in the garden. * Construct winner's flag banners with sheets of board paper, and string together to hang against the walls in the party area. * Use cardboard sprayed or painted black to make licence plates. Attach white board paper letters and numbers to each to spell out guests' names. Attach thank-you notes to the back, mount against the wall in the party area and distribute at the end of the party. * Create a canopy above the party table by draping black and white streamers from the centre of the ceiling to the outer edges. * Tie black and white balloons in bunches and attach to the corners of the ceiling. * Cover the table with a black-and-white chequered tablecloth. Place toy racing cars, toy plastic helmets and other Formula 1-related toys and tools on the table and throughout the party area. * Make small chequered flag toothpicks to add to food servings. **_Recommended age group: 6–10_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **White board paper** **Black board paper (if constructing manually)** **Scissors** **White notepaper** **Pen** **Craft glue** **Prestik® or Blu-tac™** **Plastic toy wheel (as found in party favour packs)** 1. Generate black-and-white chequered cards, measuring approximately 125 × 80 mm, on the computer and print on the white board paper. Alternatively, manually construct by cutting 125 × 80 mm rectangles from the white board paper. Divide into six rows of seven blocks each. Repeat with the black board paper. Cut out the black blocks and paste in appropriate positions on the white board paper to create a chequered note. 2. Write the party details (see suggested wording) on the notepaper and attach to the back of the chequered card with craft glue. 3. Use Prestik® or Blu-tac™ to attach the wheel to the chequered card. **SUGGESTED WORDING** Rev your engines at (birthday child's name)'s Party Prix. **Race to:** (address) on (date) **Line up on starting grid:** (time party starts) **Victory lap:** (time party ends) **Pre-race registration:** (phone number) ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Chequered card, as per the invitation** **Scissors** **Craft glue** **Party box** **Felt-tip pen** 1. Create the chequered card as per the invitation. Cut out and glue to the centre front of the box. 2. Write the guest's name on the back of the box with the felt-tip pen. ### **GAMES AND ACTIVITIES** _**Because of the nature of this theme the games listed are for outdoor play. Provision should be made for the possibility of inclement weather, such as a car/racing movie plus adaptations of traditional party games, for example pass the helmet, pin the trophy on the podium, etc.**_ #### **RED LIGHT, GREEN LIGHT!** _**Played like musical statues.**_ **You will need:** **Side plate** **Pen** **Green board paper** **Red board paper** **Scissors** Use the side plate to trace a circle onto each of the two sheets of board paper. Cut out. The children race about the play area whilst keeping an eye on the starter, who holds up one of the coloured circles at a time. On the green light the children race about, on the red light they have to stand completely still. The last one to come to a standstill is out. Play continues in this manner, until one child remains. The winner receives a prize, the rest receive tokens. #### **STARTING GRID POSITIONS** **You will need:** **Chalk or masking tape** **Music** **Numbers to correspond with grids** **Hat** Mark out numbered grid positions with the chalk or masking tape – the number of grids is optional, depending on available space and number of children. The children move about the play area in time to music. When the music stops the race organiser pulls a grid position from a hat and all children rush to the particular spot; last one there is out. Play continues until one child remains. The winning child steps onto a makeshift podium to receive a plastic trophy, the rest receive tokens. #### **PASS THE HELMET** **You will need (per team):** **One toy plastic helmet or a bicycle helmet, or similar** The children form two teams and line up one behind the other. On starter's orders the leader in each team passes the helmet backwards over his or her head to the next child. The helmet continues to be passed down the line in this manner until it reaches the last child, who places it on his or her head and runs to the front of the line. Play continues until all the children have had a turn to don the helmet. The winning team members receive a small prize, the rest receive tokens. #### **PIT STOP!** **You will need (per team):** **Chalk** **Large cardboard box** **Scissors** **Paint – various colours** **Coloured paper plates or cardboard** **Large split pins or double-sided tape** Mark out a race track with chalk. Make a cardboard box car for each team by cutting out the top and bottom of a large box, leaving only the sides. The children step into the 'cars' and pull them up to their waists. Fashion hand grips on opposite sides by cutting slits in the box. Decorate the boxes by painting headlights, tail lights and race numbers. Use the paper plates or cardboard for wheels and attach to the box with split pins. Prepare two sets of wheels per 'car' and show the children how to detach them. Divide the children into two teams – use racing car manufacturer names. The children have to step into the team car and do a lap around the track. On completion, they pull into their pit where the tyres are changed. The next child in the team then climbs into the car to repeat the procedure. Play continues until all the children have had a turn. The first team to finish wins. Winners receive a prize, the rest receive tokens. ### **PARTY FOOD** #### **TIME-KEEPING BISCUITS** **Easy Biscuits (page)** **Stopwatch template (page)** **Icing (page) – red, black** **Liquorice Allsorts™** **Silver balls** **Mini Smarties®** 1. Prepare the biscuit dough as per the recipe. 2. Trace the template onto stiff cardboard and use to cut out the biscuits. Bake as directed and leave to cool completely. 3. Coat the upper part of the biscuit with red icing. 4. Separate Liquorice Allsorts™ sweets into sections, cut a thin strip and attach both parts to the front of the biscuit to form the counting square as illustrated. 5. Pipe numerals with black icing and writing nozzle (you may want to use the birthday child's age). 6. Embellish with three silver balls and attach the Smarties® 'buttons' with a dab of icing. #### **AN OIL CHECK?** _**You may want to use this same idea for serving drinks – simply pour preferred juice into the cup, place in the food tin and add a drinking straw.**_ **Ice cream** **Plastic or polystyrene cups to fit snugly in tin** **Caramel or chocolate sauce or topping** **Cleaned empty 450 g food tins (ensure that the lid is removed cleanly, without any residual sharp edges)** **Long, thin spoons** 1. Scoop the ice cream into the cup. 2. Cover with a generous layer of caramel or chocolate sauce. 3. Insert the cup into the food tin and insert the spoon. #### **REVVED-UP CUPCAKES** **Party Cupcakes (page)** **Foil cookie cups (baking cases)** **Sugar paste – white, colours of choice** **Powdered food colouring – colours of choice** **Icing (page) – black** **Mini Smarties®** 1. Prepare the cupcakes according to the recipe, bake in the cookie cups and leave to cool completely. 2. Roll a pinch of white sugar paste into a round ball for the helmet. 3. Mould a marble-sized amount of coloured sugar paste into a sausage shape for the car body, set aside to firm up. Cut the ends square and make an indentation for the driver, just off-centre of the car. 4. Coat the cupcakes with black icing. 5. Place the car body on the cupcake. Attach Smarties® wheels with a dab of icing. Place the driver's helmet in position, again securing with a dab of icing. #### **VICTORY LAP** **Tinkies® or Twinkies™** **Icing (page) – red** **Small dolls** **Strips of aluminium foil** **Mini cake boards (or make similar using firm cardboard and aluminium foil)** **Round sweets for wheels** **Chocolate discs or similar for steering wheel** **Silver balls** **Star sweets** 1. Remove a section of the cake just off-centre of the Tinkie, large enough for the doll to fit into. Coat the cake with icing. 2. Cover the lower half of the doll's body with foil and insert into the 'seat' section. 3. Place the cake on the board. 4. Attach the wheels and steering wheel. Embellish with silver balls and a star sweet. ### **A WINNING FORMUL A-1 BIRTHDAY CAKE** **1 × Basic Cake (page) – 320 × 220 mm** **Sugar paste** **Powdered food colouring – black** **Icing (page) – red, black** **Cardboard** **Edible glitter** **Wooden skewers** **1 × chocolate disc or similar for steering wheel** **2 × large dome-shaped sugared jelly sweets** **Liquorice strips** **4 × round sweets for hubcaps** **Wafer biscuit** **Silver balls** 1. Bake the cake according to the recipe and leave to cool completely. 2. Fashion a driver's head (helmet) from a walnut-sized ball of sugar paste and set aside to firm up. Cut an oblong strip of black coloured sugar paste for a visor and attach to the helmet with a dab of icing. 3. Colour a small handful of sugar paste black and roll out to 4 mm thick. Use the templates above to cut out car decals. Mould a 15 × 5 mm cylinder-shaped piece of sugar paste to support the top wind resistor. Set aside to firm up. 4. Use the templates and cardboard to cut out the wind resistors, coat the front one with red icing using the star nozzle, whilst the top and side resistors are coated with a thin layer of black icing. Sprinkle all with edible glitter. 5. Cut out the cake according to the template. Use a 50 mm round cutter to cut out four wheels (refrigerate the wheels to make icing them easier). Use offcuts to build up the section of the car behind the driver, as illustrated. Hollow out the cab section slightly. 6. Coat the cake with red icing. Cover the wheels with black icing and attach to the body with wooden skewers trimmed to size. Add the sugar paste embellishments. 7. Place the wind resistors in position, pushing the side ones into the cake as illustrated. 8. Line the cab with a thin layer of red sugar paste. Place the driver's head in position, insert the steering wheel and place the jelly sweets in position for the mirrors, as illustrated. Add the hubcaps. 9. Assemble the top wind resistor by placing a small dab of icing on one end of the cylindrical shape to secure the top. Press into position behind the driver's head. 10. Use a wooden skewer to add 'vents' alongside the driver's cab. 11. Use liquorice strips to fashion the bonnet and embellish with a black sugar paste star. 12. Cut the wafer biscuit in half along the length, coat with a thin layer of black icing and cover with a black sugar paste strip. Sprinkle with glitter and place in position at a slight angle to form the tail end of the car. 13. Use silver balls to enhance, as illustrated. ## **Birthday Bugs** ### **SETTING THE SCENE** _Wriggly worms and buzzing bees will definitely not want to keep still at this Bug-day Celebration!_ * Tie a bunch of balloons to the front gate and secure with curling ribbon. * Coat a length of string with silver craft spray and lay a 'snail trail' from the gate to the party entrance. * Create the perfect environment for garden insects by hanging hand-crafted poster paper flowers and insects on the walls of the party area. * Paper lanterns hung above the party table will also look enchanting at any party theme. * Cover the table with a green cloth and use crepe paper or raffia to create a table skirt to simulate grass. * Place food dishes on large garden leaves, such as banana leaves (if unavailable, create your own from poster paper). Remember to cut out insect 'chomp' holes! * Plastic or rubber insects and artificial flowers will create a buzz if suspended with fishing line of varying lengths from the ceiling above the party table, whilst other toy creepy crawlies will be happy to vie for attention if placed randomly on the table. * Place available pot plants (with toy inhabitants!) and posies of flowers in strategic positions. Plastic pinwheels in the garden or party area will do much to contribute to the little guests' delight. You may buy sufficient for each child and use them as a take-home gift with a thank-you note attached to each stem. Ensure that they are positioned out of the area of play, to prevent injury. * Enlist a friend or teenager to set up a face-painting station near the entrance. * Antennae may be crafted for all the party bugs by simply twisting coloured pipe cleaners around a thin plastic Alice band. **_Recommended age group: 3–6_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Leaf template (page)** **Pencil** **Green board paper** **Craft glue** **Thin cardboard** **Scissors** **Glitter glue** **Notepaper** **Polyester fibre filling or cotton wool** **Green glitter** **Small craft bug** 1. Trace the outline of the template onto the green board paper. Glue the board paper to the cardboard. Cut out the leaf. 2. Enhance the leaf veins and the outer edges of the leaf with glitter glue. 3. Trace the outline of the template onto the notepaper and cut out. Write the invitation details (see suggested wording) on the notepaper and glue to the back of the leaf. 4. Fashion a small cocoon from the fibre filling or cotton wool, add a sprinkle of glitter and attach to the leaf with glue. 5. Add a dab of glue to the underside of the bug and place in position on the leaf. **SUGGESTED WORDING** **Flap your wings and join the buzz on:** (party date) **Wriggly worms and winged wonders will meet at:** (birthday child's name)'s party **Bee at:** (address) from (duration of party) **RSVP:** The LADYbug at (phone number) ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Large food tins (about 750 g size), washed, with lids cleanly removed to ensure that there are no residual sharp edges** **Green paper or material measuring 330 × 110 mm, or non-toxic craft spray** **Craft glue** **Self-sealing plastic food bag** **Circle of netting, mesh or hessian material, diameter 190 mm** **Elastic band** **Ribbon, 350 mm in length** **Plastic toy bug** **Felt-tip marker** 1. Cover the food tin with the paper or material and glue to secure. Or spray with non-toxic craft spray. 2. Place the treats in the plastic bag, then place the bag inside the tin. 3. Place the circle of netting over the open end of the tin and secure with the elastic band. It should now resemble a bug-catching jar. 4. Wind the ribbon around the tin to cover the elastic, and knot at the back of the tin to secure. 5. Embellish the tin by gluing on a toy bug. 6. Write the guest's name under the tin with the felt-tip marker. ### **GAMES AND ACTIVITIES** _**As this party caters for younger guests it is advisable to stick to simple games and activities.**_ #### **Caterpillar Crawl** **You will need (per guest):** **Used washed pantyhose** **Newspaper** **String** **OPTIONAL: Ribbon, wool or string as preferred for body segments; scraps of felt; googly eyes; pipe cleaners; craft glue** Prepare one caterpillar per guest. Cut the legs off the pantyhose and stuff with balls of newspaper. Close the open end by tying a knot and attach a piece of string that is long enough to allow children to trail the caterpillar on the ground. The children line up at a starting point, with caterpillars trailing behind them on the ground. On starter's orders the children race to a predetermined line. The caterpillars have to remain on the ground throughout the race. The first one across the line wins a prize, the rest receive tokens. Optional: Depending on the time that you have at your disposal (the rest of the family will enjoy making these), these caterpillars can become a feature of the party décor and may be used as take-home gifts for each guest. Tie lengths of ribbon, wool or string around the caterpillar's body at regular intervals. Knot, leaving two trailing ends for legs, thus creating body segments and legs. Decorate the 'head' with felt or googly eyes and a red felt tongue, and attach pipe cleaner antennae. #### **Buzzing About!** **You will need:** **Music** The children move about to music, each mimicking an insect of the caller's choice. When the music stops they must keep very still. Any little bug that moves is out. The game continues until there is a winner, who receives a prize, the rest receive a small token. #### **A Nest of Bugs** **You will need:** **Cardboard box** **Scissors or craft knife** **Green craft paint** **Shredded paper or straw** **Plastic toy bugs** **Cooked spaghetti** **Masking tape** **Garden leaves and twigs** **Craft glue** Cut a hole – large enough for a child to fit his or her hand through – in one side of the cardboard box (size optional). Spray the box with green craft paint. Place shredded paper in the box, together with a number of plastic toy bugs (enough for each guest). Add a few pieces of cooked spaghetti to add to the squirmy sensation! Seal the box with tape. Attach leaves and twigs to the outside of the box with craft glue. The children take turns to 'catch a bug'. #### **Incy Wincy Spider** **You will need:** **Plastic toy spider (one for each guest)** **Black shirring elastic** **Cardboard circles decorated to resemble spider webs** **Treats of choice, one per guest at each station** Attach shirring elastic (length sufficient to reach from child's wrist to the ground) to each toy spider. Tie a loop at the other end to fit around the child's wrist. Set up a few web 'stations' containing treats that have been caught in the spider's web. The children follow a trail whilst bobbing their spiders up and down, ensuring that they visit each station to discover their prey – these may be stickers, plastic bugs, sweets, etc. The children use their bug-catching treat bags for collecting their prey. ### **PARTY FOOD** #### **Intruder Cupcakes** **Party Cupcakes (page)** **Foil or paper cookie cups (baking cases)** **Icing (page) – green, yellow** **Edible glitter** **Jellied berry sweet or Liquorice Allsorts™ for body** **Small round gummy sweets, or similar rounds, for head** **Small yellow banana-shaped sweets for legs** 1. Prepare the cupcakes according to the recipe. Bake in the cookie cups and leave to cool completely. 2. Use the star nozzle to coat the top of the cake with green icing. Dust lightly with edible glitter. 3. Arrange the sweets as illustrated to form the insect. 4. Use the writing nozzle and yellow icing to dot the two eyes. #### **Honeypot Meringues** _**The meringues may be baked ahead of time, stored in an airtight container and assembled shortly before serving.**_ **Meringues (page)** **Caramel treat or custard** **Bug sweets** 1. Prepare the meringue mixture according to the recipe, then spread flat rounds onto a baking sheet lined with greaseproof paper. Make an indentation in the centre to create a hollow for the filling. Bake as directed. 2. Spoon the caramel or custard filling into the hollow and add the bug sweets. #### **Buzzy Biscuits** **Easy Biscuits (page)** **Buzzy Bee template (page)** **Icing (page) – yellow, brown** **Sugared orange or lemon slices** **Silver balls** 1. Prepare the biscuit dough as per the recipe. Use the buzzy bee template to cut out the biscuits and bake as per the instructions. Leave the biscuits to cool completely. 2. Use the star nozzle to coat the biscuits with yellow and brown stripes. 3. Place the orange or lemon slices in position to form wings. Add the silver balls for eyes. #### **Slithery Snails** **Wafer biscuits** **Icing (page) – white** **Edible glitter** **Gummy caterpillar or worm sweets** **Spinning top sweets** 1. Coat the top of the wafer biscuit with icing. Dust with edible glitter. 2. Place the gummy caterpillar in position. 3. Coat the flat side of the spinning top sweets lightly with icing. Place in position on either side of the caterpillar with the tops touching to form the shell of the snail. 4. Use the writing nozzle and white icing to pull out two feelers. ### **BIRTHDAY BUG CAKE** **2 × Basic Cake (page) – 320 × 220 mm** **Icing (page) – purple, yellow, lime green, red** **Sweets of choice for eyes, mouth, and to enhance body** **Large marshmallows or chocolate-coated shortbread balls for legs** **Jelly Tots™ for front feelers** **Florist's wire** **Edible glitter** **2 × pipe cleaners** **Silver balls (optional)** 1. Bake the cakes as per the recipe and leave to cool completely. 2. Trim each cake along one longer edge. Place the cakes side by side and join together by coating the trimmed section with icing. Cut out and assemble the cake according to the template. Retain offcuts. 3. Use the offcuts to 'pad' the head into a ball shape and attach to the body with icing. Secure with a wooden skewer if necessary. 4. Attach the 'sting' section in the same manner. 5. Mark out the segments on the body. Coat the centre with purple icing; use the star nozzle to cover the segmented sections as illustrated. Cover the neck segment with yellow icing and the head with lime green, whilst the sting will appear lethal in bright red! 6. Attach the eyes and mouth and other sweets to enhance the body. 7. Assemble the legs with florist's wire and attach to the body, bending the wire to shape. Repeat for the front feelers. 8. Dust the cake lightly with edible glitter. 9. Insert pipe cleaners into the head for antennae, as illustrated. 10. Enhance with silver balls as preferred. ## **Cooking up Fun!** ### **SETTING THE SCENE** _Whilst their food is in the oven guests will have the opportunity to titivate before taking their place at the dinner table. Keep the guest list small to facilitate the activities in the kitchen! This theme works well for a sleepover party._ * Decorations are minimal as all that is required here is an elegantly set dinner table! * Choose a favourite colour for the theme and decorate accordingly. * Tie bunches of balloons together using curling ribbon and attach to the corners of the ceiling in the dining room. * Set the table beforehand, using all available resources to ensure an elegant dining experience. Small party treats hidden on the table will add to the party excitement and you will be well rewarded with delighted squeals of laughter as guests discover these. * A centrepiece of fresh flowers to match the theme colour may also contain small party treats, such as rings or bracelets. * Place a treat in a small gift box at each place setting. * Serviettes also provide a hiding place for mini lipsticks, nail varnish and other affordable trinkets. * Serve the juice in cocktail glasses which have been 'sugar-rimmed' by first wetting the rim in lemon juice and then dipping in coloured sugar. * Be mindful of using dinner candles as these may easily be knocked over by exuberant guests. * Request that guests arrive in 'working gear' but tell them to bring clothes to change into for the dinner party. Keep a few appropriate items of clothing to cater for guests who forget to bring! * Provide hair accessories and fun kids' make-up, such as body jewels, fake tattoos and glitter. **_Recommended age group: 8–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Apron template (page)** **Pencil** **White board paper** **Scissors or craft knife** **Embellishment of choice for the pocket** **Craft glue** **Ribbon, 110 mm for the neck section, and 100 mm for each side** **Notepaper** 1. Trace the outline of the template onto the board paper and cut out. Cut out the pocket section too. 2. Add an embellishment of choice to the pocket with craft glue. 3. Glue along the edge of the rounded area of the pocket and attach to the apron. 4. Add a dab of glue to each end of the neck ribbon and attach to the back side of the apron. Repeat with the waist sections. 5. Write the invitation details on the notepaper (see suggested wording), fold and insert into the pocket. **SUGGESTED WORDING** (Birthday child's name)'s recipe for cooking up fun. **Ingredients:** 2 cups friendship 1 cup laughter 1 tablespoon birthday song Sprinkling of party treats **Method:** **Gather the above ingredients at:** (address) **Mix together on:** (date) **Bake from:** (time party starts) to (time party ends) **RSVP:** Resident Chef at (phone number) **Dress:** Casual for cooking, thereafter smart for dinner. ### **TREAT BAGS** _**Children may want to take their leftovers (if any) away in their 'doggy bag'. In the event of there not being any leftovers, the guests are sure to appreciate a slice of birthday cake.**_ **YOU WILL NEED (PER TREAT BAG):** **Notepaper** **Polystyrene container – type used for doggy bags at restaurants** **Ribbon, 750 mm in length** **Glitter pen** 1. Print or write all three recipes (see page ) on the notepaper. Fold the paper, place on the lid of the container and secure with the ribbon. 2. Write each child's name across the folded notepaper using a glitter pen. ### **COOKING UP FUN BIRTH DAY CAKE** **1 × Basic Cake (page) – 320 × 220 mm** **Icing (page) – white** **Sugar paste** **Powdered food colouring – black** **Mini Smarties®** **Silver balls** **Small toy watch face for oven clock** **Liquorice strips** **Small banana-shaped sweet** **Toy pot and pan and utensils** **Green Rainbow Bubbles or Mini Astros™** **Fried egg sweet** 1. Bake the cake according to the recipe and leave to cool completely. 2. Slice off a 30 mm strip across the width at one end of the cake and reserve to use along the top edge to form the back of the stove. 3. Cut the cake in half across the width and sandwich together with white icing. 4. Use icing to attach the cut-off strip along one edge. 5. Coat the entire cake with white icing, using the star nozzle to define edges as illustrated. 6. Colour the sugar paste black and roll out to 4 mm thick. Cut out four rounds – about 50 mm in diameter – to form the stove plates and place in position. 7. Attach the Smarties® together with the silver balls and watch face to embellish, as illustrated. 8. Mark out an oven door and use the liquorice strip to define. 9. Attach the banana-shaped sweet for the handle. 10. Place the toy pot and pan on top of the stove plates and add the green Rainbow Bubbles and the fried egg sweet to the pot and pan. 11. Attach a short liquorice strip to one side of the stove to 'hang' the utensils. ### **PARTY FOOD** _This is prepared by the guests. Instructions are included for the preparation of a main course meal as well as a dessert. Type the recipes on a single sheet of paper, decorate, and laminate if possible. Once all guests have arrived provide soap and towels so that they may wash their hands before proceeding to the kitchen to commence cooking. Set aside a table or countertop offering sufficient space in the kitchen for the food preparation and supply each child with a disposable apron. Place all the ingredients in the centre of the table and create work stations for each guest. Ensure that each child has a specific task – tasks may be shared as necessary. If using individual dishes, you may apportion the ingredients appropriately, if preferred. Prepare the pudding first to allow ample time for it to set._ #### **CHICKEN AND MUSHROOM BAKE** _**To make these even more special, use silicone moulds in fun designs. Serves 4–5.**_ **200 g chicken, cooked and chopped (or use tuna, bacon or sliced Vienna sausages)** **1 × 285 g tin sliced mushrooms** **1 cup grated Cheddar cheese** **2 eggs** **250 ml milk (or ½ milk and ½ evaporated milk)** **2 tablespoons cake (plain) flour** **1 teaspoon mustard powder** **Salt and pepper to taste** 1. Preheat the oven to 180 °C (350 °F, Gas Mark 4). 2. Spray an ovenproof dish, or preferably individual dishes, with cooking spray. 3. Place the chicken in the pie dish, together with the mushrooms. 4. Top with grated cheese. 5. Beat together the eggs and milk. 6. Mix the flour, mustard powder, salt and pepper together and beat into the milk mixture. 7. Pour the liquid over the chicken and cheese. 8. Bake for 30 minutes until set, or 15–20 minutes if using individual dishes. #### **INDIVIDUAL SIDE SALADS** **Salad ingredients of choice** **Ready-made salad dressing** 1. Set out the salad ingredients in the centre of the work area. 2. Provide each child with a small bowl and allow them to choose and prepare their own salad. 3. Serve as a side dish with the ready-made dressing. #### **SWEET SENSATION** _**You may vary the fruit and jelly according to preference. Serves 8–10.**_ **1 × 450 g tin strawberries, drained (syrup reserved)** **1 × packet strawberry jelly (powder or cubes)** **225 ml cold water** **1 × 397 g tin condensed milk** **250 ml fresh cream, lightly whipped until just thick** **Custard** **Extra whipped cream for serving** 1. Place 225 ml of the reserved syrup from the strawberries in a saucepan and bring to the boil. 2. Remove from the heat, add the jelly powder or cubes and stir until dissolved. Add the cold water and leave to cool. 3. Stir in the condensed milk and fold in the cream. 4. Add the strawberries. 5. Divide the mixture between individual serving bowls and leave to set in the fridge for 1½–2 hours. 6. Before serving, top with a layer of custard finished off with a swirl of whipped cream. ## **Cutting the Ice** ### **SETTING THE SCENE** _Host a really cool party! For seasoned skaters or beginners, a celebration on ice is a perfect option for older children. If you don't have an ice rink in your town, you can still use the ideas in this theme for a successful party – play party games or show an ice skating movie._ * Contact the ice rink in advance to enquire about the format for hosting a birthday party at their venue. Depending on the options, you may need to cater for the cost of light refreshments at the venue. * Enlist the assistance of friends for supervision as well as transport to and from the venue. * The birthday cake may be enjoyed at home, either before or after the outing. Suggestions for various party treats are also included and, if allowed, may be taken along to the venue. * Obviously décor is not essential but the birthday child will appreciate the fun of attaching a bundle of white and silver balloons to the front gate to identify the 'drop-off' zone. * Cover the cake table with a white cloth and decorate with polystyrene (snow) balls of varing sizes. White cotton wool puffs further enhance the snow theme. Adorn the table with silver tinsel and silver table confetti. * Attach a bunch of white and silver balloons to the centre of the ceiling above the birthday table. **_Recommended age group: 8–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Skating boot template (page)** **Pencil** **White board paper** **Craft glue** **Thin cardboard** **Scissors** **Craft knife** **Black felt-tip marker** **Paper punch** **Silver craft paint** **Silver glitter glue** **Silver ribbon, 150 mm in length** **Adhesive tape** **Silver star (optional)** **Notepaper** 1. Trace the outline of the template onto the white board paper. Glue the board paper to the cardboard. 2. Cut out the boot shape with the scissors, and use the craft knife to remove the two sections from the blade of the boot. Mark the foot and heel caps and the section around the eyelets. Punch the eyelets. 3. Coat the blade with silver paint; allow to dry before coating with glitter glue. 4. Thread ribbon through the eyelet holes and secure the ends at the back of the boot with adhesive tape. Embellish with a star as illustrated. 5. Trace the template onto the notepaper, cut out and write the party details on the notepaper before attaching to the back of the boot with craft glue. 6. Write the guest's name on the boot as preferred. **SUGGESTED WORDING** Cut the ice at (birthday child's name)'s party on (date) **Venue:** (home address), thereafter (name of ice rink) **Snow storm from:** (duration of party) **RSVP:** The Ice Queen at (phone number) **Dress:** As for the ice rink. ### **TREAT BAGS** **YOU WILL NEED (PER GUEST):** **Skating boot template (page)** **Pencil** **White board paper** **Craft glue** **Thin cardboard** **Scissors** **Craft knife** **Black felt-tip marker** **Paper punch** **Silver craft paint** **Silver glitter glue** **1 × clean white** **2-litre milk or juice container** **1 × white pipe cleaner** **1 × silver pipe cleaner** **Narrow feather boa trim, 450 mm in length** 1. Use the template and follow steps 1–4 of the instructions for the invitation, replacing the ribbon through the eyelets with a dot of glitter glue. 2. Cut the upper section from the milk container with the scissors. 3. Use the paper punch to make a hole on either side, near the rim of the container. 4. Twist the two pipe cleaners together and insert the ends through the holes, twisting back up on the inside, to form a handle. 5. Glue the boot to the front of the container as illustrated. 6. Trail a strip of glue along the upper edge of the container and attach the boa. 7. Write the guest's name on the back of the container with the felt-tip marker. ### **CUTTING THE ICE BIRTHDAY CAKE** **1 × Basic Cake (page) – 280 mm in diameter** **3 × wafer ice-cream cones; trim off sections from the base of 2, to create trees of varying sizes** **Icing (page) – white, red, orange, black** **Mini blue Astros™** **Sugar paste** **Wooden skewers** **Silver pipe cleaners** **Rolo® chocolates** **Flat chocolate discs** **Ribbon for scarves** **Silver balls** **Large blue Astros™** **Turquoise sugar paste flowers, available from bakery supply shops, or make your own using sugar paste and a flower cutter** **Silver foliage, available from florist shops** **Edible glitter** **1.** Make the 'trees' the night before you make the rest of the cake so that they have time to set. This will make them easier to handle. Upend the ice-cream cones and, using the star nozzle, pull out the white icing to create the branches on the trees. Work in a circular pattern from the base to the top. (I place the cones on a small plate, which allows me to turn them with ease. I set the trees aside overnight and use a spatula to lift them into position when decorating the cake.) Randomly attach the mini Astros™ to the branches of the trees. **2.** Bake the cake as per the recipe and leave to cool completely. **3.** Assemble the snowmen by rolling two balls of sugar paste for each, one for the body and a smaller one for the head. Attach the head to the body using a wooden skewer, allowing the end to protrude at the bottom for easy insertion into the cake. Gently insert the pipe cleaner arms. Set aside to firm up. **5.** Coat the cake roughly with white icing. **8.** Place the snowmen on the cake. **9.** Make the snowmen's hats by coating the flat side of the Rolo® with a dab of icing to fix to the chocolate disc. Attach to the head using icing to secure. **10.** Pipe facial features using the writing nozzle, as illustrated. **11.** Wrap the ribbon as a scarf and attach silver balls to the body with a dab of icing for buttons. **12.** Add the Astros™ and the flowers to the cake and enhance with the silver foliage. Dust the whole cake with edible glitter. ### **PARTY FOOD** #### **PERFECT FIT CUPCAKES** **Sugar paste** **Wooden skewer** **Party Cupcakes (page)** **Silver foil cookie cups (baking cases)** **Icing (page) – turquoise** **Edible glitter** **Small blue balls** 1. Make the boot by rolling a sausage shape from the sugar paste. Bend one end upwards to form the boot leg. Use the blunt end of a wooden skewer to create the opening. Set aside to firm up. 2. Bake the cupcakes in the cookie cups according to the recipe and leave to cool. 3. Ice the top of the cupcake using the star nozzle. Sprinkle with edible glitter. 4. Place the boot in the centre of the cupcake. Use a writing nozzle to create the criss-cross laces. Enhance with small blue balls. #### **SNOW BALLS** _**These may be made the day before. Makes about 20.**_ **100 g (½ cup) popping corn** **30 ml (2 tablespoons) butter** **1 × 250 g packet white marshmallows** **Edible glitter** 1. Cook the popcorn as directed on the packet. Set aside to cool. 2. It is more convenient to prepare the marshmallow in two batches. Melt the butter on the stove over a very low heat, add the marshmallows and stir continuously until melted. 3. Add the popped corn, coating thoroughly. 4. Coat your hands lightly with non-stick cooking spray and, using fistfuls of the mixture, form the popcorn into balls. 5. Sprinkle with edible glitter and allow to set. #### **BLING BLADES BISCUITS** **Easy Biscuits (page)** **Skating boot template (page)** **Icing (page) – white, turquoise** **Small blue balls** **Edible glitter** 1. Prepare the biscuit dough as per the recipe. Use the template to cut out the boot shape, and then bake according to instructions. Leave to cool completely. 2. Use the star nozzle to coat the boot with white icing and the blade section with turquoise. Attach the blue balls for the eyelets. Sprinkle with glitter. #### **A COOL FRIEND** **Sugar paste** **Marie biscuit or Rich Tea™ biscuit** **Icing (page) – white, turquoise, black, red, orange** **Flat-bottomed wafer ice-cream cone** **Small sweets of choice** **1 × Rolo® chocolate** **1 × flat chocolate disc** **1 × small silver ball** **2 × large silver balls** **Chocolate-dipped pretzel sticks** **Edible glitter** 1. Roll a walnut-sized lump of sugar paste into a ball for the head and set aside to firm up. 2. Coat the top of the Marie biscuit with white icing. 3. Fill the cone with sweets, cover the open end with the Marie biscuit and upend so that it forms the base. Coat the cone with white icing. Attach the head. 4. Coat the flat side of the Rolo with icing and attach to the chocolate disc to form the hat. Dab the underside of the disc with icing and place in position. Pipe a star on the brim and enhance with a small silver ball. 5. Use the star nozzle and turquoise icing to pipe a scarf. Place the large silver balls on the body. 6. Use the writing nozzle to pipe the facial features as illustrated. Use a pull-out motion for the nose. 7. Insert the pretzel sticks into the cone on either side for the arms. Dust lightly with edible glitter. ## **Destination Mars** ### **SETTING THE SCENE** _The intrigue of space lends itself to an 'out of this world' event that includes little green men. Schedule this party for early evening to enhance the effect of the décor for this eerie theme._ * Attach an alien mask to the front gate together with green balloons and silver curling ribbon. * Lay a path of cardboard stars (use the template on page ), painted silver and sprinkled with glitter, from the front gate to the entrance. Let your guests leave Earth behind as they step through the atmosphere – clumps of polyester fibre filling suspended in the doorway – into another world. * Line the entrance with black sheeting (paper or material) and tape black plastic over the windows. * Suspend glow-in-the-dark stars from the ceiling or use cardboard cut-outs painted with glow-in-the-dark paint (available from craft shops). * Paint polystyrene balls with glow-in-the-dark paint and suspend from the ceiling to resemble planets. * Use white Christmas lights or table lights to create twinkling stars. * Create a party area for Mars by covering the party table with a red cloth. Create a table skirt using sheets of foil or similar, and attach to the table. Create a canopy above the party table with twisted red and green crepe paper streamers draped from the centre of the ceiling to the outer edges. Replace clear light bulbs with red globes to reflect the atmosphere of the intriguing Red Planet. * Use affordable alien party masks in red, green and silver to mount on the walls. Alternatively, make alien faces from cardboard and paint with red, green and silver craft paints before decorating. * Use red, green and silver inflatable alien toys, strategically placed in the party area, to add to the décor. Create party banners of alien masks to hang against the walls. * Serve food from silver aluminium foil plates. * Set up a face-painting station to decorate faces not covered by masks. **_Recommended age group: 6–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Red notepaper** **Small cellophane packet** **Chocolate rocks or sweets of choice to simulate 'Martian rocks'** **Red board paper** **Scissors** **Glitter pen** **Paper punch** **Silver ribbon, 250–300 mm in length** 1. Write the invitation details (see suggested wording) on the notepaper. 2. Fold and place in the cellophane packet with a small handful of chocolate rocks. 3. Use the board paper to make a small name card. Write the guest's name using the glitter pen. 4. Punch a hole near an outer edge and attach the name card to the packet with the ribbon. **SUGGESTED WORDING** Collect Martian rocks with (birthday child's name) on (date) **Blast off:** (time party commences) **From Space Station:** (party address) **Shuttle returns to Earth:** (time party ends) **RSVP:** Mission Commander at (phone number) **Dress:** Green, red, silver and alien ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Bubble wrap – 440 × 260 mm** **Stapler** **Large green paper serviette** **Green pipe cleaners** **Googly eyes (or fashion from cardboard if preferred)** **Prestik® or Blu-tac™** **Red board paper for a nametag** **Glitter pen** **Paper punch** **Silver curling ribbon** 1. Fold the bubble wrap to form a packet, and then staple the sides together. 2. Open the serviette and use to line the packet. 3. Attach the googly eyes to the pipe cleaners with Prestik® and twist as illustrated to close the bag. 4. Write the guest's name on the nametag with the glitter pen. 5. Punch a hole near one side edge of the card and attach to the twisted part of the pipe cleaner with the curling ribbon. ### **GAMES AND ACTIVITIES** #### **Refuel the Rockets** _**Strict adult supervision required! Play outdoors.**_ **You will need:** **1 × sparkler per child, plus a few in reserve** **Lighter or matches** **1 × sand bucket per team** **1 × adult helper per team** **1 × sand bucket bearer per team** Divide the children into teams and have them line up at arm's length from one another. Provide each child with a sparkler, and instruct them to hold it in front of them with arms wholly extended. An adult as well as a sand bucket bearer is assigned to each team. On starter's orders the adult in each team lights the first child's sparkler. Just before the sparkler is spent, the next child touches his unlit sparkler to the first child's sparkler to light the stick. Spent sparklers are immediately submerged into the sand bucket to prevent children touching the hot sticks. The game continues until all the children's sparklers have been lit and subsequently spent. As the children finish, they sit down in their team, one behind the other. The first team to complete the process is declared the winner and a small prize is awarded to each child. #### **Martian Traps** **You will need:** **A single-bed duvet** **Blindfold** **Squeaky toys – baby bath toys are affordable and ideal! (squeakers are also available at craft stores)** Spread the duvet on the ground and randomly hide a few squeaky toys beneath it. Blindfold the children in turn, spin them about once or twice and let them try to walk across the duvet without tramping on a squeaker. As soon as they set off a trap, the children are out of the game. Play continues until one child is left, who is then declared the winner. The winner receives a prize, the rest choose a small token. #### **Space Freeze** _**Played in the same manner as 'Statues'.**_ **You will need:** **Music (space movie theme music will enhance the tone)** **1 glow stick per child** The children wave their glow sticks about in the air whilst the music plays. When music stops the glow sticks must be kept absolutely motionless. A moving stick means the bearer is out. If preferred, make the game more difficult – increase intervals between rounds and tell funny stories or jokes to cause the guests to giggle and, in so doing, increase the chances of catching someone moving a glow stick! Play continues until there is a winner, who receives a prize, the rest receive a token. #### **Docking in Space** _**If space is limited allow teams to play in turn.**_ **You will need:** **Tape** **Inflated red and green balloons, one per guest** Use the tape to mark two lines at opposite ends of a reasonably large play area. The children are divided into pairs and stand opposite each other behind the lines. Each child is given an inflated balloon. On starter's orders the children have to toss the balloon into the air and keep it airborne as they approach each other. On meeting at the midpoint they have to, whilst maintaining their balloons in the air, swop their balloons and continue to the opposite side with their partner's balloon. Dropped and subsequently popped balloons are disqualified. Winning pairs receive a prize, the rest receive a token. ### **PARTY FOOD** #### **Blast Off!** **Ready-made mini swiss rolls** **Icing (page) – white** **Mini marshmallow-filled ice-cream cones** **Silver balls** **Wafer cookie cups** **Mini Smarties®** 1. Coat one end of the swiss roll with icing and attach the wide end of the marshmallow cone, pressing to secure. Enhance with silver balls as illustrated. 2. Cut off the base and sufficient wafer to allow the cookie cup to fit around the opposite end of the swiss roll. Coat the join with icing and enhance with the Mini Smarties®. #### **Alien Invasion** **Large round watermelon or other melon** **Large green pepper** **Wooden skewer** **Vienna sausages, cut into 3 cm lengths** **Cheese slices** **Small star cookie cutter** **Green and red cocktail onions** **Wooden cocktail sticks** **Pipe cleaners** **Grapes or similar for the eyes (or use googly eyes)** 1. Slice one end off the melon so that it may be placed upright. 2. Fashion the head from the green pepper, and attach to the melon with a skewer. 3. Cut a deep cross at one end of each piece of sausage, and then place in boiling water until the edges curl. Set aside to drain on paper towels. 4. Cut out star shapes from the cheese slices. 5. Thread a cocktail onion and a sausage, frilled end pointing down, onto a cocktail stick. Insert into the melon. Alternate the onions with the cheese stars. 6. Twist the pipe cleaners to form curly antennae, attach an 'eye' at one end of each and insert into the green pepper head to create an adorable Martian. #### **Friendly Alien Biscuits** **Easy Biscuits (page)** **Alien template (page)** **Icing (page) – green** **Large eye sweets** **Hundreds and thousands** **Large green balls** **Fruit Allsorts™ or similar** 1. Prepare the biscuit dough as per the recipe. Trace the template onto cardboard and use it to cut out the biscuits. Bake as directed and leave to cool completely. 2. Coat each biscuit with the green icing and mark out a mouth. 3. Place the eye in the upper half of the biscuit, surround with hundreds and thousands and enhance with the green balls. 4. Cut the teeth and tongue from layers of Allsorts™ sweets and place in position as illustrated. #### **Martian Cupcakes** **Party Cupcakes (page)** **Liquid food colouring – green** **Green foil cookie cups (baking cases)** **Icing (page) – green** **Toy dolls** **Foil** **Clear plastic domes, approximately 40 mm in diameter (I used chocolate moulds)** **Rainbow Bubbles or Mini Astros™** 1. Prepare the cupcake batter as per the recipe, adding a few drops of green food colouring to the mixture. Bake the cupcakes in the cookie cups according to the recipe and leave to cool completely. 2. Coat the cupcake with icing, wrap the lower half of the doll's body in foil and insert into the centre of the cupcake. Cover with the dome and enhance with the sweets as illustrated. ### **A MERRY MARTIAN BIRTHDAY CAKE** **2 × Basic Cake (page) – each baked in 1 × 1.5 litre ovenproof pudding bowl and 1 × 0.5 litre pudding bowl, thus providing 2 of each size** **Icing (page) – green, white** **Wooden skewers** **Sugar paste** **Powdered food colouring – green, yellow, red** **Small star cookie cutter** **2 × large silver balls** **4 × red pipe cleaners** **4 × googly eyes** **Prestik® or Blu-tac™** **1 × red lollipop** 1. Prepare the cake batter and divide between the ovenproof bowls. Bake the cakes (the 1.5 litre cakes must be baked for 50–60 minutes) and leave to cool completely. 2. Use a serrated knife to level all surfaces on the cakes. Place one large cake on a cake board, flat side up, and coat with a layer of green icing. Attach the matching half to form the lower body of the alien. 3. Place one small cake, flat side up, on top of the body and coat the surface with icing. Attach the matching half to form the head. Insert wooden skewers to secure the head to the body. 4. Use the star nozzle to coat the entire cake with green icing. 5. Roll out white sugar paste to 4 mm thick and cut out three circles for the eyes. Roll out some green sugar paste to 4 mm thick, cut out sections of a circle, attach to the edge of each eye and place in position as illustrated. 6. Roll out yellow sugar paste to 4 mm thick and cut out a triangular nose. 7. Roll out red sugar paste to 4 mm thick and fashion a mouth; use a toothpick to outline the lips. At the same time, cut out circles of varying diameters from the rest of the red sugar paste and set aside. Fashion two teeth from the yellow sugar paste. 8. Roll out white sugar paste to 4 mm thick and cut out a rectangle. Cut out a semicircle from the green sugar paste and attach to the rectangle with icing. Cut out a small semicircle from the red sugar paste and attach to the centre base of the green semicircle with icing. Use the writing nozzle and white icing to add the gauge and arrowed marker. 9. Cut out stars from the yellow sugar paste and decorate the base of the gauge. Enhance with silver balls. 10. Attach the red circles randomly to the body and head. 11. Twist the pipe cleaners around a wooden spoon to curl; add a googly eye to the end of each, securing with a small blob of Prestik®. Place in position for antennae on the head. 12. Insert the red lollipop as a 'receiver' in the centre of the forehead. ## **Enchanted Forest** ### **SETTING THE SCENE** _Frolic with fairies and other woodland creatures at this enchanting birthday party!_ * Decorate the front gate with a bunch of green and gold balloons and trailing strips of garden creeper. Secure with green curling ribbon. * Lay a trail of small stones or florist jewels (inexpensive, round glass stones available from discount shops) from the front gate to the party entrance. Cut out butterflies from poster paper and decorate with glitter glue and sequins and place randomly along the path. * Use available toys to place in the garden, party area and throughout the house, for example fluffy bunnies, teddy bears, squirrels, mice, frogs, friendly spiders in webs, etc. Make paper flowers, butterflies and birds to hang in the garden trees and in the party area. * Place available pot plants at the front entrance and hang garden creepers in the doorway so that guests may pass into the woodland area. Use available artificial Christmas trees and borrow extras from friends to enhance your theme. Artificial birds and butterflies may be attached to these. Trees will also provide ideal hiding spots for toy squirrels and friendly spiders. * Cover the party table with a green cloth and add a green skirt made from raffia strips. Place small fairies and other woodland creatures on the table. Sprinkle glitter, sequins and fairy confetti on the table cloth. * Decorate the walls with party banners of large paper flowers, cut from board paper and decorated with glitter glue and sequins. Make streamers from green crepe paper, and create a canopy above the party table by draping them from the centre of the ceiling to the outer edges, twisting to enhance the effect. * Suspend butterflies and birds (available from craft shops or florists) on varying lengths of fishing line from the ceiling above the party table. Sprinkle fresh flower petals on the floor in the party area. * If you have them, string up fairy lights in the garden and party area (even in daylight) to add to the enchantment of this appealing theme. * As the children arrive adorn each face with paint, face jewellery and/or stick-on tattoos, and then give each child bubble liquid to create magical floating bubbles whilst waiting for the rest of the guests. **_Recommended age group: 3–8_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Toadstool template (page)** **Pencil** **White board paper** **Thin cardboard** **Red board paper** **Craft knife** **Craft glue or Prestik® or Blu-tac™** **Scissors** **Notepaper** **Gold glitter glue** **Small plastic toy of choice** 1. Trace the outline of the toadstool onto the white board paper and glue onto the cardboard. 2. Trace the outline of the toadstool cap onto the red board paper. Cut out the oval markings using a craft knife, and then glue the cap over the white board paper. Cut out the toadstool. 3. Trace the outline of the toadstool onto the notepaper and cut out. Write the party details (see suggested wording) and attach to the back of the toadstool. 4. Enhance the base and oval bits of the toadstool with streaks of glitter glue and allow to dry. 5. Attach the toy with craft glue or Prestik®. **SUGGESTED WORDING** Frolic with woodland folk at (child's name)'s party on (date) **Enchanted forest:** (address) **Duration:** (time party starts and ends) **RSVP:** The Fairy Queen at (phone number) **Dress:** Enchanting! ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **1 × clean 2-litre cool drink bottle** **Felt-tip marker** **Masking tape** **Craft scissors** **Paper punch** **Gold sequins** **Craft glue** **Red board paper, at least 200 × 200 mm** **Stapler** **Cord, 300 mm in length** **Small decorative butterfly or enhancement of choice** **Glitter pen** 1. Measure 125 mm from the base of the cool drink bottle and mark the circumference. Add a strip of masking tape to facilitate a straight cutting edge. 2. Cut off the top section of the bottle. Punch two holes 10 mm from the upper rim of the container, directly opposite each other. Affix sequins randomly. 3. Cut a 180 mm diameter circle from the board paper. Cut along the radius, and then fold the cut edges slightly over each other. Staple together to form a cone-shaped lid for the bottle. 4. Turn the lid upside down, rest the container inside the lid and mark two spots to align with the holes in the container. Punch the holes. 5. Tie a knot at one end of the cord. Thread through the hole in the container, from the inside out, and through one hole in the lid. Thread back through the second hole in the lid and through the second hole of the container, from outside to inside. Knot to secure. 6. Attach the butterfly to the toadstool. Write the guest's name across the lid of the toadstool. ### **GAMES AND ACTIVITIES** #### **The Wishing Well** **You will need:** **Circles cut from coloured cardboard, approximately 60 mm in diameter (one per guest)** **Felt-tip marker** **Large flat tub or basin** **Prestik® or Blu-tac®** **Coin** Number each circle with the marker and secure randomly to the inside base of the tub with Prestik®. The children line up one behind the other and have a turn to toss a coin onto a numbered circle. If the coin lands in the centre of a circle, that number is removed and retained by the child. Unsuccessful children move to the back of the line, to take another turn. Play continues until all children have a numbered circle which is then exchanged for a gift in a basket – number one having the first turn, then number two, etc. #### **Fairy Trails** _**Follow the fairy trails to find the enchanted forest's hidden secrets.**_ **You will need:** **Florist's stones or pebbles, or painted stones, of various colours** **Thread or ribbon in matching colours** Set up a treasure hunt using the stones. Use a different colour for each trail. The children select a thread or ribbon and then go in pursuit of their secret treasure by following the trail that corresponds to their thread. Depending on the number of guests, you may prefer to divide them into small teams. #### **Pass the Tea Please!** **You will need:** **2 × plastic doll's teacup and saucer** **Water** The children form two teams and line up opposite each other, with enough room to move between the two teams. The first child in each team holds a plastic doll's teacup filled to the brim with water. (Add a few drops of food colouring to make for easy viewing.) With the cup balanced on the saucer the child runs down the length of the team before returning to her place. Care must be taken not to spill the 'tea'. Once back in position the cup and saucer is handed to the next child who repeats the process. The game continues until all the children have had a turn. The winning team is the one who has the most water left in the teacup. The winners receive a prize, the rest receive a token. #### **Musical Toadstools** _**Played in the same manner as musical chairs.**_ **You will need:** **White paper** **Scissors** **Craft glue** **Red cardboard circles (one less than the number of guests)** **Glitter glue** **Music** Cut out circles from the white paper and glue to the red cardboard circles. Decorate with glitter glue. Set out the circles in the play area. The children skip about to the joyful music. When the music stops they have to rush to a toadstool. With each round of the game one toadstool is removed and the child not acquiring an enchanted seat is out. The game continues until one child remains, who, as the winner, receives a prize. The rest of the children receive small tokens. ### **PARTY FOOD** #### **Trendy Tortoise** **Sugar paste – colour as preferred** **Small flower cookie cutter** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – brown** **Coloured wafer cookie cups** **Marshmallows** **Large sugared jelly sweets** **Silver balls** 1. Colour the sugar paste and roll out to about 4 mm thick. Cut out flowers and set aside to firm up. 2. Coat the upper side of the Marie biscuit with icing. Dab icing in the cookie cup and place a marshmallow inside, trimming to fit. Upend on the biscuit. 3. Coat a surface with non-stick cooking spray and slice the sweet into three. Fashion legs from the outer slices by cutting each in half. Use the curved portion of the middle slice for the head and the remaining portion for the tail. Place in position as illustrated. 4. Attach the silver balls to the head with a dab of icing. 5. Attach the flower to the tortoise with icing and enhance with a silver ball. #### **Wishing Well Cupcakes** **Party Cupcakes (page)** **Gold foil cookie cups (baking cases)** **Icing (page) – brown** **Small sweets of choice** **Edible glitter** **Paper umbrellas** **Craft butterflies** **Cocktail sticks** **Prestik® or Blu-tac™** 1. Bake the cupcakes in the cookie cups as per the recipe and set aside to cool completely. 2. Coat the top of each cupcake with icing and place sweets around the edge. Sprinkle with glitter. 3. Place an umbrella in the centre of each cake. 4. Attach a butterfly to a cocktail stick with a small blob of Prestik®, and insert into each cake. #### **Forest Fairy** **Sugar paste** **Powdered food colouring – colour of choice** **Small flower cookie cutter** **Flat-bottomed wafer ice-cream cones** **Sweets of choice** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – forest green, white, brown, red, black** **Edible glitter** **Silver balls** **Fairy Wings template (page) and edible rice paper** **Silver pipe cleaners, 150 mm in length, cut in half** **Wooden cocktail sticks** 1. Roll a piece of sugar paste into a ball. Colour sugar paste and cut out two flowers. Set aside. 2. Fill the wafer cone with sweets. Coat a Marie biscuit with green icing and place over the open end of the cone. Upend so that the biscuit forms the base. 3. Coat the flat end of the cone with icing and attach the head. Use the star nozzle and green icing for the dress. Sprinkle with edible glitter and add silver balls. 4. Add the hair with a pull-out motion of the star nozzle, and create facial features with the writing nozzle. Attach one flower to the hair. 5. Cut out wings from the rice paper, dust with edible glitter and attach to the cone with icing. Gently push a pipe cleaner arm into either side of the cone. 6. Attach the other sugar paste flower to the cocktail stick with a dab of icing and insert into position. #### **Forest Friend** **Easy Biscuits (page)** **Squirrel template (page)** **Icing (page) – brown** **Gold balls and sweets of choice** **Edible glitter** 1. Prepare the biscuit dough as per the recipe. Use the template to cut out the biscuits and bake as directed. Leave to cool completely then coat with icing. Use the star or multi-hole nozzle for the tail. Position the gold ball and sweet. Dust the tail with glitter. ### **AN ENCHANTED FOREST BIRTHDAY CAKE** **1 × Basic Cake (page) – 280 mm square** **Wafer ice-cream cones; cut the base off some of the cones with a serrated knife to vary the heights** **Icing (page) – green, blue** **50 g baking chocolate** **50 g unsalted peanuts** **Sugar paste** **Powdered food colouring – red** **Small flower cookie cutter (or use ready-made sugar paste flowers from a baking supply store)** **Caramel crunch or similar for pathway** **Large chocolate-coated nuts** **Edible glitter** **Assorted small toy animals or craft novelties (I also used two doves on florist's wire to hover over the scene)** **Small butterfly sweets** **Small fairy dolls** **Wooden skewers** **Prestik® or Blu-tac™** 1. Make the 'trees' the night before assembling the cake so that they have time to set. This will make them easier to handle. Upend the cones and, using the star nozzle, pull out the icing to create the branches on the trees. Work in a circular pattern from the base to the top. (I place the cones on a small plate, which allows me to turn them around with ease. I set the trees aside overnight and use a spatula to lift them for positioning on the cake the next morning.) 2. Melt the baking chocolate and stir in the peanuts until evenly coated. Set aside. 3. Colour small amounts of sugar paste appropriately and use to fashion toadstools. Roll out small amounts of coloured sugar paste, cut out flowers and set all aside to firm up. 4. Bake the cake as per the recipe and leave to cool completely. 5. Coat the sides and surface of the cake with green icing. Mark out different areas of the forest. 6. Create the path with the caramel crunch. 7. Position the peanut clusters and large chocolate-coated nuts as illustrated to resemble rocks in the stream and begin the tricklings of the stream over them using blue icing. Dust the stream with edible glitter. 8. Use the multi-hole nozzle to create the grass. 9. Place the trees in position and dust with edible glitter. Add the flowers, toadstools, butterfly sweets and other novelties of choice. 10. Attach the fairies to wooden skewers, using Prestik® to secure, and insert into the cake to complete the enchanted scene. ## **Farmyard Frolics** ### **SETTING THE SCENE** _Moo's, oink's, baa's and other animal sounds will fill the air at this happy event and transform your suburban venue into a fertile farmyard!_ * Depending on space, budget and facilities available, you may want to hire a mobile petting zoo, or you could visit one. You could also hire a small pony with groom to provide rides for the little ones. (Ensure that safety measures are adhered to.) Ideas mentioned here cater for a party at home. * Attach a bunch of balloons to the front gate with curling ribbon. * Create a smiling scarecrow using old clothes, stockings, twigs, polyester fibre filling (or newspaper balls), a hat, bandana and other available accessories, to welcome your guests. * A wheelbarrow of vegetables – pumpkins, etc. – will add to the farmyard appeal. * Lay a trail of sawdust from the gate to the front entrance. * Decorate the walls of the party area with computer-generated pictures of farm animals and huge sunflowers, enlarged and glued to cardboard. * Tie bunches of balloons with curling ribbon and hang from the corners of the ceiling in the party area. * Serve the food in enamel dishes with plastic beach spades as ladles. * Juice for the thirsty farmworkers may be served in enamel mugs. * Cover the party table with hessian and place plastic farm animals and small scarecrows (the type sold by florists) on the table. Raffia may be scattered on the ground about the table to simulate straw. * Baskets and/or toy wagons of fruit and vegetables randomly placed on the floor in the party area will provide ample evidence of the farmer's bountiful harvest. * Set up a face-painting station, manned by two friends or older children who would be happy to turn eager little faces into those of favourite farm animals. **_Recommended age group: 3–6_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Notepaper** **Small plastic container** **Small plastic farm animal** **Strips of raffia to simulate straw** **Small paper sunflower, available from craft shops** **Prestik® or Blu-tac™** **Felt-tip marker** 1. Write the invitation details (see suggested wording) on the notepaper and tuck inside the container together with the plastic animal and the 'straw'. 2. Tie a bow around the container with a piece of raffia. 3. Attach the sunflower with a blob of Prestik®. 4. Write the guest's name on the underside of the container with the marker. **SUGGESTED WORDING** Frolic at (birthday child's name)'s farm on (date) **Harvest time:** (duration of party) **Farmyard:** (address) **RSVP:** Farmer (surname) at (phone number) **Dress:** Farm clothes ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Small plastic bucket, with or without lid as preferred (available from plastic discount stores)** **Raffia** **Craft glue** **Craft novelty, as preferred** **Felt-tip marker** 1. Wind the raffia around the outside of the bucket, and use craft glue to secure. 2. Affix a small scarecrow or preferred novelty to the raffia using craft glue. 3. Tie a raffia bow roughly around the handle of the bucket. 4. Write the guest's name on the base of the bucket with the marker. ### **GAMES AND ACTIVITIES** #### **Wheelbarrow Race** **You will need:** **2 × wheelbarrows** **2 × large cushions** Borrow wheelbarrows and obliging husbands from friends if necessary! Place a cushion in each wheelbarrow to protect fragile little bodies from bobs and bumps! The children form two teams and line up one behind the other. The first child in each team is placed in the wheelbarrow and, on starter's orders, the wheelbarrow is pushed to a predetermined spot and back again, where the first child is offloaded before the next guest climbs on board. Ensure that Dads obey all safety rules with their precious cargo! The winning team has first choice from a basket of small prizes/tokens, before the second team selects theirs. #### **Gather the Eggs** **You will need:** **Styrofoam (or as preferred) eggs** Hide Styrofoam eggs throughout the garden or party area and allow children to hunt for them. Each child finds one egg and hands it to the 'farmer', who exchanges it for a prize or token selected from a basket. #### **Sheep Shearing Race** **You will need:** **Cotton wool puffs** **2 × small plastic beach buckets per team** **1 × plastic beach spade per team** The children form two teams and line up behind a leader. Place a small bucket of cotton wool puffs (sufficient puffs for each child plus two or three extra) in front of each team. Place a second empty bucket at a predetermined distance away from the children. On starter's orders the first child in each group picks up a cotton puff with a small plastic spade and races across to deposit it in the empty bucket, before returning to the team where the process is repeated until all the children have had a turn. Puffs that are dropped along the way must be picked up in order for play to continue. The first team to transfer all their puffs from one bucket to the other receives a prize, the rest receive tokens. #### **Feed the Ducks** **You will need:** **Plastic tub** **2–3 small rubber ducks** **Small ball** Fill the tub with water and float two or three small rubber ducks on the surface. (Be mindful of smaller children – fill the tub at time of play and do not leave unattended; empty immediately after the game.) The children line up behind a marker at a predetermined distance away from the tub. Children take turns to attempt to toss the ball into the tub. Successful children choose a prize from a basket, and the game continues until each child has hit the target. (Those who struggle to hit the target may be permitted to move closer to the bucket.) ### **PARTY FOOD** #### **A Mootiful Cow** **Flat-bottomed wafer ice-cream cones** **Small sweets of choice** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – white, black** **Gold balls** **White marshmallows** **Pink marshmallows** **Blue Rainbow Bubbles or Mini Astros™** **Small gold cowbells** **Ribbon, approximately 140 mm in length** 1. Fill the cone with sweets. Coat the upper side of the Marie biscuit with icing and place it over the open end of the cone. Upend so that the biscuit forms the base. 2. Use the star nozzle to pipe a row of stars around the base of the cone. Enhance with gold balls. 3. Assemble the head by placing the white marshmallow with a flat side facing up. Cut a slice off the pink marshmallow and attach to the white, allowing it to overlap the lower edge. Secure with icing. 4. Cut a second slice from the pink marshmallow and snip off opposite ends. With icing sugar-coated fingers, pinch each piece of marshmallow into an ear shape. Attach to the head with icing. 5. Coat the top of the cone with icing and attach the head. Place two dots of icing on the face and attach the Rainbow Bubbles for eyes. Use the writing nozzle and black icing to add facial features and horns. 6. Attach the bell to the length of ribbon and tie around the neck of the cone, securing at the back with icing. #### **Whirring Windmills** **Oranges, halved, with pulp removed** **1 × 80 g packet jelly (powder or cubes) – serves 5–6** **Mini pinwheel cocktail sticks** 1. Cut a thin slice from the base of the orange if necessary so that it stands level. 2. Make up the jelly according to instructions. Fill each orange half with the jelly and set in the refrigerator. 3. Insert a pinwheel into each before serving. #### **Lambkin** **Party Cupcakes (page)** **Gold foil cookie cups (baking cases)** **Pink marshmallows** **Icing (page) – white, black** **Jelly Beans™, cut in half** **Edible glitter** 1. Bake the cupcakes in the cookie cups as per the recipe and leave to cool completely. 2. Cut a slice off the marshmallow. Cut a wedge on each outer edge to fashion the ears. Position on one side of the cupcake, securing with a dab of icing. 3. Use the multi-holed nozzle to pipe the sheep's wool. 4. Place the Jelly Bean™ halves to form the hooves. 5. Add the facial features using the writing nozzle. 6. Sprinkle lightly with edible glitter. #### **Scare the Crow Biscuit** **Easy Biscuits (page)** **Gingerbread man cookie cutter** **Icing (page) – blue, red, flesh, yellow, black** **Liquorice strips** **Red Rainbow Bubbles or Mini Astros™** 1. Prepare the biscuit dough as per the recipe. Cut out shapes with the cookie cutter and bake as directed. Leave to cool completely. 2. Ice the body with the star nozzle, defining the clothes as illustrated. 3. Coat the face with flesh-coloured icing. 4. Cut out a hat from the liquorice strip and enhance with a rainbow bubble. Add two more Rainbow Bubbles to the trousers for buttons. 5. Use the multi-hole nozzle to pull out straw hands, feet and hair. 6. Finally add facial features using the writing nozzle. ### **FARMYARD FROLICS BIRTHDAY CAKE** **1 × Basic Cake (page) – 280 mm square** **Icing (page) – green, brown, yellow, blue** **Sugared fruit cubes** **Plastic farmyard toys of choice** **Gold balls** **Melon sweets** **Large Astros™** **Small craft sunflowers** **Wooden cocktail sticks** **Prestik® or Blu-tac™** **Small novelty scarecrow** **Small plastic tree** 1. Bake the cake according to the recipe and leave to cool completely. 2. Coat the upper two-thirds of the cake with green icing whilst the 'field' section (the lower third) should be iced brown to resemble soil. Mark off the different areas – field of vegetables, pig in mud, field of sunflowers. 3. Separate the field from the grassed section with a row of sugared fruit cubes. 4. Coat the muddy section with brown icing and place the pig in position, with streaks of mud dripping off the toy. 5. Form a few bushy shrubs from icing for the sheep to graze on. 6. With the writing nozzle, dot a few kernels of corn for the chickens to enjoy. 7. Use the star nozzle to mark out the fields, adding a gold ball on alternate stars. 8. 'Plant' one field of melons. 9. Use orange Astros™ to form carrot heads. Pull out green icing tops. Do the same using dark red submerged Astros™ to simulate beetroot. 10. Attach the sunflowers to the cocktail sticks with Prestik® and insert into the cake. 11. Place the scarecrow in position to oversee the crop. 12. Place the tree in position and scatter red Astros™ on the grassed section to resemble apples. ## **Feisty Fire Engines** ### **SETTING THE SCENE** _A favourite with all boys! Guests will sizzle with excitement at this blazing bash!_ * Enquire at your local fire station regarding tours and demonstrations for children – this will be a memorable and educational experience! Ensure that you have reliable transport. If such an outing is planned, the following is optional or may be toned down as preferred. * Tie a large bunch of red and yellow balloons to the front gate with red and yellow curling ribbon. Lay a garden hose/s from the gate to the party area so that the little ones waste no time in getting to the action! * Hang red and yellow 'flame' streamers in the doorway. * Create a canopy over the party table by twisting red and yellow crepe paper streamers from the centre of the ceiling to the outer corners. * Suspend red and yellow streamers from the ceiling over the party table to simulate flames. Tie bunches of red and yellow balloons together and hang in the corners of the party area. * Paste yellow cellophane paper in the windows to create a fiery glow in the room. * Cut flames from red and yellow board paper and attach to walls in the party area, rising from the floor and windowsills upwards. * Cover the table with a bright yellow cloth. Make a table skirt from red and yellow crepe paper 'flames'. * Serve food from toy fire helmets. Decorate the table with toy fire engines. **_Recommended age group: 4–10_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Fire Engine template (page)** **Pencil** **Red board paper** **Craft glue** **Thin cardboard** **Scissors** **Craft knife** **Strip of acetate (optional)** **Adhesive tape** **Notepaper** **Yellow board paper** **Paper punch** **3 × split pin paper fasteners** **Flat black cord – 150 mm in length** **Bead** **Red glitter glue** **Gold glitter glue** **Googly eye (with red pupil)** 1. Trace the outline of the fire engine onto the red board paper. Glue it to the thin cardboard. Cut out. 2. Use the craft knife to remove the windows. Tape a strip of acetate to cover the windows. 3. Cut notepaper to fit the rear end of the fire engine, and write the party details (see suggested wording). Glue to the back of the fire engine. 4. Draw three 35 mm diameter circles on the yellow board paper. Bore a hole in each circle centre. Punch holes in the fire engine to align with the wheel centres. Insert split pins through the wheels and through the punched holes to attach. (Or glue the wheels to the truck, adding a bead for the wheel hub.) 5. Draw two narrow parallel bars on the yellow board paper, 80 mm long and 25 mm apart. Join the bars with rungs drawn at 10 mm intervals. Use a craft knife to cut out the ladder and glue it to the vehicle. 6. Tie a knot at one end of the cord and attach a bead. Apply craft glue along the length of the cord and roll up. Glue to the side of the truck beneath the ladder. 7. Colour the light with red glitter glue and the door handle with gold glitter glue. Attach the googly eye. **SUGGESTED WORDING** Candles are alight at (child's name)'s birthday party! **Man the hydrants on:** (date) **Blazing inferno at:** (venue) **Sound the alarm:** (time party starts) **Extinguish the flames:** (time party ends) **RSVP:** The Fire Chief at (phone number) (If an outing is planned ensure that you advise parents to drop children off timeously.) ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Firefighter's Badge template (page)** **Cardboard** **Scissors** **Heavy-duty foil or silver craft paint** **Craft glue** **Craft stars** **Red party box** **Felt-tip marker** 1. Trace the template onto the cardboard and cut out. Trace the outline onto the foil and carefully cut out (or paint the cardboard if preferred). Glue the foil to the cardboard. 2. Embellish the badge with the stars. 3. Glue the badge to the front of the box. 4. Write the guest's name on the back of the box with the felt-tip marker. ### **GAMES AND ACTIVITIES** #### **Daring Rescue** _**Construct an obstacle course, one for each team, with the following, for example:**_ **You will need:** **1 × ladder, placed flat on the ground** **1 × large box, to crawl through** **1 × rope, to jump over** **Small traffic cones or similar, to zigzag through** **1 × wooden plank, supported above the ground on bricks, to balance on** The children line up one behind the other in two teams, at the end of the obstacle course. One child takes up position at the beginning of the obstacle course. On starter's orders the child at the beginning of the course negotiates all the obstacles and then tags the first child in the line, and together they return to the beginning of the course. The initial 'firefighter' then sits down on the ground whilst the 'rescued' child negotiates the course to retrieve the next child. Play continues in this manner until all children have been rescued. The first team to finish receives a prize, the rest receive tokens. #### **Bouncing the Baby** **You will need:** **Small square cloth per pair of children** **2 × small teddies** The children form two teams. Each team divides into pairs, who then line up an arm's length from each other. Each pair is given a small cloth. The pair at the beginning of the line starts with a teddy on their cloth. They bounce the teddy from their cloth to the next pair who must then catch the teddy in their cloth. The game continues in this manner down the line. The first team to finish receives a small prize, the rest receive a token. #### **Fire Drill** **You will need:** **Numbered cardboard circles – use paper plates if preferred, one per child** **Music or siren sounds** Place the numbered circles randomly on the ground in the play area. The children skip about the play area in time to music or siren sounds. When the music stops the children rush to a circle (one child per circle). The caller, with back to the group to ensure impartiality, shouts out a number. The child on the corresponding circle picks it up and leaves the game. Play continues until one child is left. The winner receives a prize, the rest receive tokens. #### **Blinded by Smoke** **You will need:** **2 × bundles of an assortment of 'firefighters'' clothes** **2 × blindfolds** Divide the children into two teams and have them line up one behind the other. Mark a predetermined point with an X some distance away from each team. Place a pile of firefighters' clothes, including Wellington boots, in front of each team. On starter's orders the first child in each team puts on the clothes, with the help of the team members, as well as the blindfold. The firefighter is spun about once or twice by his or her team members and must then find the X by listening to the directions given by the rest of the team. Once the point is reached, the child may remove the blindfold and run back to his or her team. The clothes are hastily removed and handed to the next child, who repeats the process. Play continues until all the children have had a turn. The first team to finish receives a small prize, the rest receive tokens. ### **PARTY FOOD** #### **Douse the Flames Cupcake** **Party Cupcakes (page)** **Red foil cookie cups (baking cases)** **Icing (page) – orange, red, yellow** **Small plastic toy firefighters** 1. Bake the cupcakes in the cookie cups as per the recipe and leave to cool completely. 2. Spoon orange, red and yellow icing alongside each other into the icing tube and, using the star nozzle, cover the surface of the cake with pull-out flames. 3. Place the toy firefighter in the centre of the cake. #### **A Rescue Attempt** **Flat-bottomed wafer ice-cream cones** **Small sweets of choice** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – white, orange, red, yellow, blue** **Liquorice strips** **Small plastic dolls** **Allsorts sweets for windows** **Small gold balls** 1. Fill the wafer cone with sweets. 2. Coat the Marie biscuit with icing and place over the open end of the cone. Upend so that the biscuit forms the base. 3. Coat the cone with white icing. 4. Spoon orange, red and yellow icing alongside each other into the icing tube and, using the star nozzle, pull out flames on the top end of the cone. 5. Create a ladder from the liquorice strips, place against the cone and attach a plastic firefighter, pressing slightly to secure. 6. Use a dab of icing to attach a liquorice strip to the hand of the doll. Press one end of the hosepipe into the icing at the base of the cone and enhance the free end with a pull-out of blue icing to simulate water. 7. Cut the Allsorts sweets into appropriate shapes and attach to the cone for windows. 8. Pipe a row of fiery stars around the base of the cone and enhance with gold balls. #### **Flashing Sirens** **Ready-made mini swiss rolls** **Icing (page) – red, white** **Round yellow sweets** **White marshmallow** **Red cherry** **Liquorice strips** **Large silver balls** **Small gold balls** **Yellow star sweet** 1. Coat the swiss roll with red icing. 2. Place the yellow sweets in position for the four wheels, pressing slightly to secure. 3. Cut the marshmallow in half and place cut side down on the front section of the swiss roll to create the 'cab'. Neaten with a row of piped stars around the base. 4. Add a dab of icing to the top of the marshmallow to attach the red cherry for the light. 5. Make a ladder out of the liquorice strips and stick on the top of the vehicle, behind the cab. 6. Add the gold and silver balls to the front for lights, as illustrated, together with the star 'badge'. #### **Sound the Alarm Biscuits** **Easy Biscuits (page)** **House template (page)** **Icing (page) – brown, orange, red, yellow** **Gold-coloured chocolate vermicelli** **Allsorts sweets** 1. Prepare the biscuit dough as per the recipe. Use the template to cut out house shapes and bake according to instructions. Leave to cool completely. 2. Coat the biscuit with brown icing. 3. Spoon orange, red and yellow icing alongside each other into the icing tube and, using the star nozzle, pull out flames along one side of the roof. 4. Sprinkle vermicelli on the remainder of the roof. 5. Create a door and windows using the sliced Allsorts sweets. ### **FEISTY FIRE ENGINE BIRTHDAY CAKE** **2 × Basic Cake (page) – 320 × 220 mm each** **Sugar paste** **Powdered food colouring – yellow, red, black** **Icing (page) – red** **1 × clear disposable plastic container measuring approximately 110 × 80 mm (such as those used for store-bought cocktail tomatoes)** **2 × toy firefighters** **Foil** **Liquorice twists** **Liquorice strips** **Round sweets for front and back lights** **4 × chocolate discs for wheels** **Silver balls** **Red and yellow cherries** **2 × banana-shaped sweets** **Toy fire-fighting tools (optional)** 1. Bake the cakes according to the recipe and leave to cool completely. 2. Colour some sugar paste yellow and roll out to 4 mm thick. Fashion a steering wheel, emblems and hubcaps. Set aside to firm up. 3. Sandwich the cakes together with a layer of icing. 4. Cut the upper layer of the cake at an angle to form the front section of the fire engine. 5. Measure the length of the plastic container and trim the sides off the cake accordingly (set aside to use later) so that the cab will fit comfortably across the width of the cake. Coat the truck with red icing. 6. Cover the toy firefighters' legs with foil and insert into the cab section. Add the steering wheel and place the plastic container over the firefighters. Cover the roof section with icing and use the star nozzle to add the support sections at each side edge as illustrated. 7. Place the trimmed pieces of cake across the back of the cake to fit neatly behind the cab; coat with red icing. 8. Fashion a ladder from the liquorice twists and position on top of the truck. 9. Roll some black sugar paste into a sausage shape and fashion into front and back bumpers. 10. Cut liquorice strips into equal lengths and place in position for the front grille. Position the round sweets for the front and back lights. 11. Place the chocolate discs for the wheels in position, add a hubcap with a dab of icing and enhance with silver balls, again attaching with a dab of icing. 12. Roll a liquorice strip into a hosepipe and attach to the side of the fire engine; add a silver ball to the end to simulate the nozzle. 13. Place a row of alternating red and yellow cherries on the roof for flashing emergency lights. 14. Attach the emblems to each panel and enhance with sugar paste stars as illustrated. Attach the banana-shaped sweets for the door handles. 15. Enhance with small fire-fighting tools if using. ## **The Big Number 1** ### **SETTING THE SCENE** _An eagerly anticipated family event that will be celebrated with much enthusiasm! Pink for a girl? Blue for a boy? Adapt the colour scheme as preferred._ * Create a huge number 1 from cardboard (see template on page ). Decorate with craft paint and allow to dry. Bore two small holes through the cardboard and attach it to the front gate with ribbon. Decorate with small balloons tied with ribbon and threaded through the cardboard. Attach artificial or fresh flowers and complement with glitter glue. * Make similar number 1's of varying sizes and attach to the walls in the party area. * Print photos of your baby, cut into a round and mount on a coloured cardboard star, ensuring that there is one per guest. Attach a thank-you note to the back of each star or simply write directly on the cardboard. Punch a hole near the edge of one point of each star, thread ribbon through the hole and suspend from the ceiling above the party table. Cut down and distribute at the end of the party. * Cover the party table with a soft green cloth and top with a scrunched-up length of matching tulle fabric to create a delicate baby atmosphere. Tuck baby's available small toys in the folds of the fabric and scatter rose petals – preferably white or pale yellow – on the table. * Tie bunches of balloons to the corners of the ceiling. * Create a play area for your tiny guests using all available toys – borrow from friends if necessary, depending on the number of guests. * Provide plenty of comfortable seating for older family members. * Circulate a memory book amongst the guests – allocate a double page per guest. Leave one of the two pages blank to attach a photograph of the guest, and allow him or her to write a note or wish to the birthday child on the opposite page. **_Recommended age group: 1–2_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Number 1 template (page)** **Pencil** **Pastel green board paper** **Craft glue** **Thin cardboard** **Scissors** **Embellishments of choice** **Notepaper** **Curling ribbon** 1. Trace the outline of the template onto the board paper, glue to the cardboard and cut out. 2. Attach the embellishments using craft glue. 3. Write the invitation details (see suggested wording) on the notepaper, roll up and attach to the back of the invitation with ribbon, tying in a knot to secure. **SUGGESTED WORDING** (Child's name)'s celebrating the big number ONE! **Be the first to arrive on:** (date) **The number one venue:** (address) **Duration:** ONE minute past (hour) to ONE minute past (hour). **RSVP:** The Number ONE Mom at (phone number) ### **TREAT BAGS** _**Be mindful of the embellishments that you attach to the bucket – they must not be easily detached by little fingers for tasting!**_ **YOU WILL NEED (PER TREAT BAG):** **Small white plastic bucket (available at plastic discount stores)** **Embellishment of choice** **Craft glue** **Curling ribbon** **Felt-tip marker** 1. Glue the embellishment to the bucket. 2. Tie curling ribbon around the handle. 3. Write the guest's name underneath the bucket using the felt-tip marker. ### **GAMES AND ACTIVITIES** Not much here apart from the aforementioned play mat with available or borrowed toys. A ball pond also works well with the tiny tots. If some of the invited guests are slightly older, provide a table where they may make use of computer-generated pictures to colour, and jigsaw puzzles, to keep them entertained. Provide bubbles to blow which will enchant the younger children whilst keeping the older ones entertained and at the same time creating a magical party atmosphere. ### **NUMBER 1 BIRTHDAY CAKE** **1½ × Basic Cake (page) – one × 220 × 320 mm cake, one × 1.5 litre pudding bowl cake** **Sugar paste** **Powdered food colouring – yellow** **Number 1 template (page)** **Icing (page) – light green, yellow** **Toy doll** **Foil** **4 × round biscuits or round sweets for wheels** **Marshmallow flower sweets** **Florist's wire** **Butterflies (available from baking supply stores; alternatively purchase from a craft shop)** **Silver balls** 1. Bake the cakes as directed, using the half batch mixture for the pudding bowl cake. Leave to cool completely. 2. Colour the sugar paste yellow and roll out to 4 mm thick. Use the template to cut out two number 1's. Set aside to firm up. 3. Cut the rectangular cake in half across the width and sandwich the two halves together with icing. 4. Cut the pudding bowl cake in half. Place one half, cut side down, on the cake as illustrated to create a pram. Use a serrated knife to round the corners of the cake to align with the hood. (The second half may be frozen for use at a later stage.) 5. Cut a slight indentation in the bowl cake to make space for the doll. Coat the cake with green icing. 6. Remove the legs from the doll and cover the lower torso with foil. Use the star nozzle to add clothing and insert the doll into the cake. 7. Use the star nozzle to coat the top of the pram to fashion a blanket. 8. Place the number 1's on the sides of the pram. Attach the wheels. 9. Thread the marshmallow sweets onto the wire and insert into the cake for the handle of the pram. 10. Attach a butterfly to the baby's hand with a dab of icing; place the rest randomly on the pram as illustrated. 11. Use the star nozzle and silver balls to enhance the cake as iillustrated. ### **PARTY FOOD** _**Be mindful of your little guests and provide food that is appropriate and easily held in little fingers. The following are a few suggestions to add to the party table, possibly catering for older children as well.**_ #### **NUMBER 1 BISCUITS** **Sugar paste** **Powdered food colouring – yellow** **Small heart cookie cutter, or as preferred** **Easy Biscuits (page)** **Number 1 template (page)** **Icing (page) – light green** **Edible glitter** 1. Colour the sugar paste and roll out to 4 mm thick. Cut out heart shapes and set aside to firm up. 2. Prepare the biscuit dough as per the recipe. Trace the template onto cardboard and use to cut out number 1 shapes. Bake according to instructions and leave to cool. 3. Coat the biscuits with light green icing. Sprinkle with edible glitter and attach a heart, pressing slightly to secure. #### **A NUMBER 1 FRIEND** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – brown, black, and colour to match marshmallows** **Sweetie Pies® or Tunnock's Tea Cakes™** **Medium to large marshmallows** **Mini marshmallows, in matching colour** **Rainbow Bubbles or Mini Astros™** 1. Coat the Marie biscuit with brown icing and place the Sweetie Pie® in the centre. 2. Place the larger marshmallow on the work surface, flat side down. Use the writing nozzle to decorate the upper flat surface with facial features. 3. Attach the head to the top of the Sweetie Pie® with a dab of icing. 4. Attach the ears and limbs with a dab of icing, and add the Rainbow Bubble buttons. #### **HUSHABYE BABY CUPCAKES** **Party Cupcakes (page)** **Foil or paper cookie cups (baking cases)** **Sugar paste** **Powdered food colouring – green** **Small flower cookie cutter** **Jelly Babies™** **Icing (page) – light green** **Wafer cookie cups** **Edible glitter** **Silver balls** 1. Bake the cupcakes in the cookie cups according to the recipe and leave to cool. 2. Colour the sugar paste and roll out to 4 mm thick. Cut out flowers and set aside to firm up. 3. Push a Jelly Baby™ into the cake, just off-centre, so that the upper half of the body protrudes. 4. Using the star nozzle, coat the top of the cake with light green icing. 5. Cut the wafer cookie cup in half and place on the cake, cut side down, to form a crib. 6. Sprinkle the cake with edible glitter. 7. Attach a silver ball to the centre of the flower with a dab of icing before attaching to the iced blanket. #### **A SWEET 1** _**Makes about 24 'ones'**_ **Number 1 template (page)** **Meringues (page)** **Soft teddy sweets, or as preferred** **Icing – white** 1. Line a baking tray with foil and use the template to mark out 'one' shapes. 2. Prepare the meringue mixture according to the recipe and pipe onto the foil, filling in the shapes. Bake as directed. 3. Attach the teddy with a small dab of icing. ## **Karate Kicks** ### **SETTING THE SCENE** _The guests will certainly get a kick out of this party theme. Girls should not be excluded from the opportunity to throw a punch!_ * You may want to enquire at a local karate school whether they host demonstrations to groups, or alternatively hire an instructor or older student to come to your home for the same purpose. * Tie a bunch of white balloons to the front gate using a band of black fabric to resemble a belt. * Enlist the help of a friend or older teenager to set up a booth with Asian-themed temporary tattoos. * Create a canopy over the party table by draping white streamers from the centre of the ceiling to the outer corners. * Suspend white Japanese or Chinese lanterns on fishing line from the ceiling at varying heights. * Attach bundles of white balloons tied together with black ribbon to the corners of the ceiling. * Cover the party table with a white cloth. * Place available Asian novelties and chopsticks on the table. * Lay strips of black fabric across the width of the table to resemble black belts. **_Recommended age group: 6–10_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Black stretchy ribbing material, 560 × 80 mm** **Black thread** **White board paper, 120 × 80 mm** **Scissors** **Craft glue** **Thin cardboard** **Black board paper for frame, or create on computer, or colour as preferred** **Notepaper** **Paper punch** **Black curling ribbon, 300 mm in length** **White curling ribbon, 300 mm in length** 1. Fold the material in half along the length with the right sides together. Sew along the edge to create a tube. Turn right side out and knot the ends together. 2. Glue the white board paper to the thin cardboard. Glue that to the black board paper to create the black frame. 3. Cut the notepaper to the same size as the card, write the invitation details (see suggested wording) and glue to the back of the card. 4. Write the guest's name on the front of the card. 5. Punch a hole near one edge of the card and attach the card to the headband with the curling ribbon. **SUGGESTED WORDING** Kick out at (child's name)'s party on (date) **Perfect your stance at:** (address) **Strike and chop between:** (time party starts) and (time party ends) **RSVP:** Sensei at (phone number) **Dress:** As for karate. (Ensure that parents deliver their children timeously if an outing is scheduled. Arrange safe and reliable transport ahead of time.) ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Flared white gift box** **Black gift ribbon – 500 mm in length** **Stapler or adhesive tape** **Black curling ribbon** **Disposable chopsticks** **Prestik® on Blu-tac™** **Felt-tip marker** 1. Wrap the gift ribbon around the box and secure underneath with the stapler or tape. 2. Tie curling ribbon around the chopsticks and attach to the top of the box with Prestik®. 3. Write the guest's name on the lid of the box with the marker. ### **GAMES AND ACTIVITIES** #### **SENSEI SAYS** _**This is a variation on the more familiar 'Do this, Do that' party game.**_ Enlist the assistance of an older teenager to guide the aspirant experts through their moves. When 'Do this' is called, the children follow instructions, whereas on 'Do that' the children remain absolutely motionless. If a child follows the 'Do that' instruction, he or she is eliminated from the game. The game continues until one child is left and is declared the winner. The winner receives a small prize, the rest receive tokens. #### **BLACK BELT RACE** **You will need:** **1 × black belt for each pair of guests** The children are grouped in pairs and stand abreast of each other. The pairs line up behind a tape. The inner legs of the children are tied together with the black belt. On starter's orders the children race towards a predetermined spot. The winning pair receive a prize, the rest receive tokens. (To add a degree of difficulty you may blindfold one child in each pair.) #### **KARATE CHALLENGE** _**Create an obstacle course using the following suggestions.**_ **You will need:** **1 × tumbling mat** **1 × balancing plank supported at each end by a brick** **Tyres to walk across** **Demarcated stops where children have to perform a predetermined number of kicks** The children are timed whilst individually negotiating the course, or alternatively set up two similar courses and divide the children into two teams. As one child finishes the course the next team member starts. The first one to finish is declared the winner and receives a prize, the rest receive tokens. #### **KARATE CHOP** **You will need:** **Different coloured balloons for each team (one per child)** **String** **1 × large mat for ground play** Divide children into two teams. Tie an inflated balloon to the left wrist of each child. The children pair up, in turn, and sit on the mat in opposing teams, and each attempts to 'chop' the other's balloon, whilst at the same time protecting his or her own. Standing up during the exercise leads to disqualification. Once a balloon has been 'chopped', the pair leave the mat. Play continues in this fashion. The score is tallied at the end of play and the team with the most balloons remaining intact is declared victorious. Each winning team member receives a prize, the rest receive tokens. (Remove any broken bits of balloon immediately as they may be harmful if ingested by small children or pets.) ### **PARTY FOOD** #### **SENSEI'S SWEET SURPRISE** **Sugar paste** **Powdered food colouring – flesh, black** **Small sweets of choice** **Wafer ice-cream cones** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – white, black** **Liquorice strips** **Silver balls** **Pipe cleaners, 150 mm in length, cut in half** 1. For the head, roll flesh-coloured sugar paste into a ball. Mould two pinches of sugar paste for the feet and make indentations for the toes. Set aside to firm up. 2. Place the sweets in the cone. Coat one side of the Marie biscuit with icing and place, iced side down, over the open end of the cone. Upend so that the biscuit forms the base. Cut the tip off the cone. 3. Use the star nozzle and white icing to pipe the trousers. Cover the upper portion of the cone with stars, leaving a V-shape for the chest. Attach a foot to the end of each leg. Attach liquorice strips to the waist for the belt. Pipe stars around the base of the cone and enhance with silver balls. 4. Coat the cut end of the cone with icing. Attach the head. Use the multi-hole nozzle and black icing for hair. Create facial features with the writing nozzle. 5. Carefully insert the pipe cleaner arms into the cone on either side of the body and twist into shape. #### **AWESOME OPPONENT** **Party Cupcakes (page)** **Silver paper or foil cookie cups (baking cases)** **Icing (page) – flesh, yellow, red, black** **Liquorice strips** 1. Bake the cupcakes in the cookie cups according to the recipe and leave to cool completely. 2. Cover the cupcakes with flesh-coloured icing. Use the star nozzle and yellow icing and, with a pull-out motion, create hair. Attach the liquorice strip for the headband and tuck the ends into the hair. Create the facial features with the writing nozzle, as illustrated. #### **ORIENTAL STEAK SENSEI-TION** _**Prepare ahead and re-heat before serving. Serves 6–8.**_ **500 g topside steak, sliced thinly into 5 cm long strips** **30 ml (2 Tbsp) cooking oil** **1 × 285 g tin mushroom pieces and stems** **Cooked rice or noodles for servings** **MARINADE:** **30 ml (2 Tbsp) soy sauce** **30 ml (2 Tbsp) sugar** **15 ml (1 Tbsp) cornflour** **5 ml (1 tsp) zeal** **1.** Mix all the marinade ingredients together and use to coat the strips of meat. Marinate for 5 hours in the refrigerator, turning occasionally. **3.** Heat the oil in a shallow pan and fry the meat, together with the juice, until cooked. Add hot water (25 ml/5 tsp at a time) to thin the juice if necessary. **5.** Add the mushrooms and stir until heated through. **6.** Serve in individual bowls or cartons. #### **BLACK BELT PANCAKES** _**Makes 36.**_ **1 × packet pancake ready-mix (or purchase frozen pancakes and prepare according to instructions)** **10 ml (2 tsp) ground cinnamon** **250 ml (1 cup) white sugar** **Frying pan, 150 mm in diameter** **Black ribbon** 1. Prepare the pancake batter as per the instructions. 2. Mix the cinnamon and sugar together and sprinkle approximately 5 ml (1 tsp) of sugar on a small plate. 3. Cook the pancakes as directed and stack on the plate, topping each pancake with a sprinkling of cinnamon sugar. 4. Cover the stack with a spare plate and invert. Roll each pancake and arrange on a serving platter. Tie the ribbon loosely around the serving platter to resemble a black belt. ### **KARATE KICKS BIRTHDAY CAKE** **2½ × Basic Cake (page) – two × 320 × 220 mm cakes; one × 200 mm round cake** **Icing (page) – flesh, white, yellow, red** **Liquorice strip** **2 × googly eyes** **Sugared jelly sweet for nose** 1. Bake the cakes as directed and leave to cool completely. 2. Cut out and assemble the cakes as per the cutting guide (offcuts may be frozen and used at a later stage for a trifle). 3. Position the round cake for the head. Mark out a V section for the neck. 4. Coat the head, neck and feet with flesh-coloured icing. 5. Coat the sides and the top of the body section with white icing, then use the star or ribbon nozzle to create the white banded edging of the top. 6. Use the yellow icing and a pull-out motion and star nozzle to create the hair. Add the liquorice strip for the headband, tucking each end into the icing. 7. Place the eyes in position and cut liquorice strips for the eyebrows. Add the sugared jelly sweet for the nose. 8. Use the writing nozzle and red icing to outline the mouth. Fill in with the star nozzle. 9. Add the liquorice belt, pressing slightly to secure. ## **My Special Pony** ### **SETTING THE SCENE** _Whether it be pony rides for little ones or a visit to a riding school for older children, pony parties are always a recipe for success!_ * Although this party plan may include an outing, décor ideas have been included in case you are planning to entertain at home. * Use cardboard to make a huge horseshoe to attach to the front gate. Spray with silver paint, decorate with silver glitter glue and attach to the front gate. A bunch of silver and yellow balloons tied together with silver and yellow trailing ribbons will add to the effect. * Cut out smaller horseshoes, paint and lay a path from the gate to the party entrance. Use bricks and boards to create a low 'jump' at the front entrance for high-spirited guests to leap over. * Cover the party table with a yellow gingham cloth. Add a few strands of raffia to simulate straw. * Place silver cardboard horseshoes on the table together with plastic toy ponies and fresh or artificial yellow daisies or similar flowers. * Decorate the party walls with pony pictures and large horseshoe cutouts. * Use yellow crepe paper and yellow cardboard to make giant winners' rosettes and attach to the walls. * Create a canopy over the table by twisting yellow streamers and draping them from the centre of the ceiling to the outer edges. Attach bunches of silver and yellow balloons to the corners of the ceiling. * Attach silver and yellow cardboard horseshoes to fishing line and suspend from the ceiling above the birthday table; intersperse with yellow artificial flowers suspended in the same manner. * Serve food, where practical, from small plastic buckets (horse pails) decorated with ribbons and flowers. **_Recommended age group: 5–12_** ( _adapt the activities to complement the age group_ ) ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Horseshoe template (page)** **Pencil** **Stiff card** **Scissors** **Silver craft paint** **Silver glitter glue** **8 × sequins** **Craft glue** **Yellow daisy (available from craft shops)** **Notepaper** **Yellow ribbon, 35 mm in length** 1. Trace the template onto the card and cut out. 2. Paint the card silver and allow to dry. Enhance with silver glitter glue. 3. Attach the sequins with a dab of glue. Attach a yellow daisy. 4. Write the invitation details (see suggested wording) on the notepaper, roll up and attach to the back of the horseshoe with the ribbon. **SUGGESTED WORDING** Canter over to (birthday child's name)'s party on (date) **Arena:** (address) **Be at the starting gate at:** (time party starts) **Cross the finish line at:** (time party ends) **RSVP:** The Stable Hand at (phone number) **Dress:** Ponytail! ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Horseshoe, as per invitation** **Craft glue** **Yellow gift bag** **Felt-tip marker** 1. Make additional horseshoes in the same manner as for the invitation. Use craft glue to attach the horseshoes to the gift bag. 2. Write the guest's name on the back of the bag with the felt-tip marker. ### **GAMES AND ACTIVITIES** _**The activities are age dependent – if you have a large enough garden, hiring a pony is a good option for young children. Experienced grooms are usually excellent with young riders as good discipline is essential; ensure that both children and adults obey instructions. Enquire about feeding the pony – you may be permitted to supply a bunch of carrots. Older children will certainly enjoy an outing to a riding school – ask friends to assist with reliable transport and ensure that parents are aware of your intentions; children should dress accordingly. A smaller group is preferable to facilitate supervision. I have included party games below as optional alternatives.**_ #### **This Pony is a Puzzle!** **You will need:** **1 × pony picture per guest** **Cardboard** **Craft glue** **Scissors** **Yellow organza ribbon** Glue the picture of the horse onto the cardboard. Allow to dry and then cut each picture into an equal number of puzzle pieces. Pool all the pieces, thus mixing them up. Make bundles of equal numbers of puzzle pieces for each guest, tying each with a pretty ribbon. Distribute the bundles to the children and allow them to piece together their puzzle by exchanging pieces with each other to complete their own. The first child to finish receives a small prize, the rest receive tokens. #### **Gymkhana** _**Set up an obstacle course for 'prancing ponies' to negotiate. A few suggestions include:**_ **4 × traffic cones on the ground** **2 × pieces of rope placed on the ground parallel to each other, about 0.5 m apart** **3 × tyres or hula hoops in a row, slightly apart from each other** **1 × 'jump' constructed with bricks and a board** **Free areas with stops** Children are instructed to, for example: canter between two stops; run sideways between two stops; dodge between the traffic cones without touching them; leap across the ropes; clear the 'jump'. As children complete the course they select a small prize from a basket. #### **The Lucky Shoe** **You will need:** **Horseshoe template (page)** **Cardboard** **Scissors** **Silver craft spray** **Felt-tip marker** **Paper squares** **Bowl** **Music** Trace horseshoes (one per guest) onto the cardboard and cut out. Spray with silver craft spray. Number each horseshoe with the marker. Write the corresponding numbers on paper squares, fold and place in a bowl. Place the horseshoes randomly on the ground – children 'trot' amongst the horseshoes to music. When the music stops each child must rush to a horseshoe. The caller picks a number from the bowl and the child standing on that particular horseshoe is out. Remove the horseshoe and restart the music. Play continues in this manner until there is a winner. The winner receives a prize, the rest receive tokens. #### **My Own Ponytail** **You will need:** **Artificial hair piece – ponytail (very affordable at discount clothing stores), one per guest** **Hair accessories, for example ribbons, artificial flowers, coloured hair spray, hair novelties, etc.** Set up a table with a place setting for each guest. Place a hair piece at each setting. Place the hair accessories in the centre of the table so that each child may decorate her own ponytail, before attaching it to her head. ### **PARTY FOOD** #### **Lucky Biscuits** _**Roll out dough to at least 5 mm thick as the shape of the biscuit makes handling difficult.**_ **Sugar paste** **Powdered food colouring – yellow** **Small flower cookie cutter** **Easy Biscuits (page)** **Horseshoe template (page)** **Icing (page) – pale yellow** **Large and small silver balls** **Edible glitter** 1. Colour the sugar paste (it should be a deeper shade of yellow than the icing) and roll out to 4 mm thick. Cut out flowers and set aside to firm up. 2. Prepare the biscuit dough as per the recipe. Trace the template onto stiff cardboard and use to cut out the horseshoe shapes. Bake the biscuits as directed and leave to cool completely. 3. Coat the biscuits with pale yellow icing. Position the flower. Add a dab of icing to the centre of the flower and attach a large silver ball. Add the small silver balls and sprinkle with edible glitter. #### **Savouring a Winner!** **Pony cookie cutter** **Cheese slices** **Cracker bread** **Soft butter or margarine** **Toppings of choice, suggestions include: ham slices, egg, chicken or tuna mayonnaise, meat and vegetable extract spreads, peanut butter** **Shredded lettuce and slivers of carrots** **Tomato sauce or mustard** 1. Use the cookie cutter to cut out cheese shapes. 2. Spread the cracker breads lightly with butter or margarine and add the topping of choice. 3. Garnish with the cheese shapes, as well as shredded lettuce and slivers of carrots. 4. Use a dot of tomato sauce or mustard for an eye. #### **Giddy-up Cupcakes** **Sugar paste** **Powdered food colouring – yellow** **Small flower cookie cutter** **Party Cupcakes (page)** **Yellow paper or foil cookie cups (baking cases)** **Icing (page) – green** **Small plastic toy horses** **Silver balls** 1. Colour the sugar paste and roll out to 4 mm thick. Cut out flowers and set aside to firm up. 2. Bake the cupcakes in the cookie cups as per the recipe and leave to cool completely. 3. Use the star nozzle to ice the cupcakes. Place the toy horse and a flower on the cake and enhance with a silver ball, secured with a small dab of icing. #### **A Mighty Mane** **Sugar paste** **Powdered food colouring – yellow** **Small flower cookie cutter** **Flat-bottomed wafer ice-cream cone** **Small sweets of choice** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – brown** **Silver balls** **Edible glitter** 1. Colour the sugar paste yellow and roll out to 4 mm thick. Cut out small flowers and set aside to firm up. 2. Fill the wafer cone with sweets. Coat the Marie biscuit with icing and place it over the open end of the cone. Upend so that the biscuit forms the base. 3. Use the star nozzle to pull out curls of icing from the top of the cone to the base. 4. Place a silver ball in the centre of each flower, securing with a small dab of icing. Arrange the flowers randomly on the mane. 5. Pipe a row of stars around the base of the cone and enhance with silver balls. 6. Dust the mane lightly with edible glitter. ### **My Special Pony Birthday Cake** **1 × Basic Cake (page) – 320 × 220 mm** **Sugar paste** **Powdered food colouring – yellow** **Flower cookie cutters in various sizes** **Icing (page) – pale yellow** **Silver balls** **Edible glitter** **Plastic toy horses** 1. Colour the sugar paste a deeper shade of yellow than the icing and roll out to 4 mm thick. Use the cutters to make flower shapes and set aside to firm up. 2. Bake the cake as per the recipe and leave to cool completely. 3. Use the template above to trace two half horseshoes onto cardboard. Place on the cake, cut out and assemble the cake to form a horseshoe. 4. Join the sections together with icing. 5. Coat the cake with pale yellow icing and use the star nozzle to enhance the upper surface. 6. Place the flowers on the cake as illustrated. Add a dab of icing to the centre of each flower to secure a silver ball. 7. Dust lightly with edible glitter. 8. Arrange the toy horses on the cake. ## **Shipwrecked & Stranded** ### **SETTING THE SCENE** _For a summer birthday party, this theme may be incorporated into a poolside event. It is also great for fancy dress as all it needs is for guests to decide what they were doing 'when the ship went down'!_ * Use the template on page as a guide to draw a life buoy on cardboard. Cut out and colour with red or orange paint. Attach to the front gate and drape with garden creepers or strips of green crepe or cellophane paper to resemble seaweed. * Scatter wooden planks and other flotsam along the path to the front door. The planks could be fashioned from cardboard or styrofoam strips and painted appropriately. * Hang a curtain of blue crepe and cellophane paper strips in the doorway, to enable children to pass through the sea. Use fishing line to suspend toy or cardboard fish from the entrance ceiling and affix coloured cardboard fish to the walls. (Shop for baby bath toys – they are brightly coloured and reasonably priced.) Use garden creepers to simulate seaweed and position appropriately. * Blue balloons bundled together and fixed to the ceiling will enhance the underwater appearance, as will blue cellophane paper taped to the windows. Where possible, create a scene of chaos – chairs and small household items overturned and in disarray, as per a disaster at sea. * The guests pass through the underwater scene en route to the island where they are to be stranded. The rest of the party area serves as the island. * Cover the party table with a blue cloth and sprinkle with crushed Marie or Rich Tea™ biscuit crumbs to resemble sea sand. Scatter florist pearls and sea shells on the table. Make a simple table skirt with blue crepe paper or raffia. * Use the fishing line to suspend cardboard or toy seagulls from the ceiling above the table. Indoor plants, particularly palms, will add to the island theme. Use available stuffed animal toys to maximum effect – toy monkeys peeping from behind bushes, parrots perched in cardboard trees. * Skeleton bones, again fashioned from styrofoam, or plastic toy skeletons will serve as a reminder of previous luckless visitors to the island. Toy snakes and spiders may also choose to inhabit the island. **_Recommended age group: 6–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Wooden curtain ring or polystyrene ring, 100 mm diameter** **Red or orange craft paint** **Silver ribbon, 300 mm in length** **Craft glue or Prestik® or Blu-tac™** **Blue board paper, cut in a square slightly larger than the diameter of the ring** 1. Paint the curtain or polystyrene ring to resemble a life buoy. Leave to dry. 2. Wind the ribbon around the ring as illustrated and secure at the back with glue or Prestik®. 3. Write the invitation details on the back of the board paper. Attach the life buoy to the front side of the board paper with blobs of Prestik® to secure. 4. Write the guest's name in the inner circle. 5. Tie ribbon through the loop of the ring to enhance. **SUGGESTED WORDING** Abandon ship and man the lifeboats at (child's name)'s party! **Muster station:** (address) **Last sighting of wreck:** (date and duration of party) **RSVP:** The abandoned ship's Captain at (phone number) **Dress:** As you were when the ship went down! ### **TREAT BAGS** _**The children will forage for these in a treasure hunt – see Games and Activities.**_ **YOU WILL NEED (PER TREAT BAG):** **Clear plastic food container** **Blue serviette** **Blue ribbon** **Sea shells** **Toy crab, starfish or sea creature of choice** **Prestik® or Blu-tac™** **Gold glitter glue** **Felt-tip marker** 1. Line the container with the serviette. 2. Knot the ribbon at the centre front of the container and enhance the lid with the sea shells and chosen toy sea creature, using Prestik® to secure. 3. Lightly swirl glitter glue in between the shells to resemble sand. 4. Write the guest's name with the marker and hide the container in the garden shortly before the party commences. ### **GAMES AND ACTIVITIES** #### **LIFEBOAT RUSH** **You will need:** **Cardboard rounds, about the size of a dinner plate (sufficient for each guest, less one)** **Music** Place the cardboard rounds on the ground in a large circle. To the tunes of island-style music the children dance around the circle. When the music stops each child rushes to a circle. The child without a 'lifeboat' is eliminated, and at the same time one circle is removed from play. The game continues until there is one remaining circle and one successful 'passenger'. The winner receives a small prize, the rest receive tokens. #### **BEWARE OF SHARKS!** **You will need:** **Huge piece of cardboard** **Shark's jaws template (page)** **Craft paint** **Craft knife** Draw and paint huge shark's jaws on the cardboard. Ensure that once the centre of the jaw is removed the gaping hole is big enough for a guest to crawl through. Enlist an adult's assistance to support the jaws. The children line up one behind the other and, once the music starts, the first child crawls through the jaws and then rejoins the end of the line, in this manner forming a circle whilst each child has a turn to crawl through the scary shark teeth. For larger groups it will be much more fun if you make more than one set of jaws for the children to negotiate. The music should add to this drama at sea! When the music stops the child who is caught in the shark's jaws is out. Play continues in this manner until there is one remaining child, who is declared the winner. The winner receives a prize, the rest receive tokens! #### **FEATHER A PARROT** **You will need:** **1 × parrot picture per guest** **Coloured feathers** **Craft glue** **Googly eyes** **Coloured pens** Set out a work table covered with a plastic sheet. Provide a drawing of a parrot for each guest. Set out bowls of coloured feathers, together with craft glue, googly eyes and coloured pens. Each child then decorates his or her parrot using the tools provided. #### **FORAGE FOR FOOD** _**See treat bags.**_ Divide the children into small groups and provide each group with a different set of clues that will lead them to find the previously hidden treat bags. The clues should be structured so that each group finds one bag per child. The children work together in their groups until all have found their island food. ### **PARTY FOOD** #### **BAKED POTATO BOATS** _**These may be prepared beforehand and grilled just before serving.**_ **Medium to large potatoes, one half per child plus a few extra** **Sufficient butter to ensure a firm but smooth consistency when mashed** **Salt and pepper to taste** **250 g cooked bacon, chopped (optional)** **Cheddar cheese, sliced to fit the halved potato** **Blue board paper or cellophane, cut into sail shapes and threaded onto wooden cocktail sticks (you may write guests' names on the sails if preferred)** 1. Preheat the oven to 200 °C (400 °F, Gas Mark 6). 2. Wash the potatoes, dry well with paper towels, prick with a fork and bake for approximately 1 hour until cooked through. 3. Remove from oven and cool to touch. Cut each potato in half and scoop out the inside, taking care not to break the skin. Reserve the hollowed-out skins. 4. Mash the potato well, adding the butter, seasoning and chopped bacon. Divide the mixture between the empty shells and use a spatula to smooth the surface. Set aside until required. 5. Cover the top of the potato with a slice of cheese, top with a small dot of butter and place on a low oven shelf under a hot grill until the cheese is golden brown and the potato is warmed through. 6. Insert a sail into each potato boat. #### **ISLAND BIRD DRUMSTICKS** **Chicken seasoning** **Chicken drumsticks, allow two per child plus a few extra** 1. Heat the oven to 180 °C (350 °F, Gas Mark 4). 2. Season the drumsticks and place on a baking tray. 3. Bake for 45–50 minutes until done, turning after 25 minutes. 4. Serve on platters decorated with plenty of greenery. #### **LIFE-SAVING CUPCAKES** **Party Cupcakes (page)** **Blue paper or foil cookie cups (baking cases)** **Sugar paste** **Powdered food colouring – red** **Two round cutters, approximately 40 mm and 20 mm** **Icing (page) – blue, white** 1. Bake the cupcakes in the cookie cups as per the recipe and leave to cool completely. 2. Colour the sugar paste red and roll out to 4 mm thick. Use the cutters to create a life buoy. 3. Coat the cupcakes roughly with blue icing to resemble the sea and top with the red life buoy. 4. Use the writing nozzle to decorate the lifebuoy with strips of white icing. #### **SMOKE SIGNALS** **Wafer cookie cups** **Small sweets of choice** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – blue, green** **Caramel popcorn** **Short wooden skewers, 120 mm in length** **Small fish-shaped sweets** 1. Fill the wafer cookie cup with sweets of choice. 2. Coat the Marie biscuit with blue icing and place over the open end of the cookie cup. Upend so that the biscuit forms the base. 3. Use the star nozzle to coat the upper surface of the cup with green icing. 4. Thread popcorn pieces at intervals on the skewer and secure by piercing through the centre of the cookie cup. 5. Place the fish sweet in the 'ocean'. ### **SHIPWRECKED & STRANDED BIRTHDAY CAKE** **1½ × Basic Cake (page) – one × 280 mm square cake; one × 150 mm round cake** **100 g unsalted peanuts** **100 g baking chocolate** **Icing (page) – blue, white, flesh, green** **2 × Marie biscuits or Rich Tea™ biscuits, crumbled** **Liquorice Allsorts™ (use the cable type for the portholes)** **Liquorice strip** **Marshmallow, trimmed as necessary (secure on a toothpick for easy insertion)** **Shark-shaped sweets** **Fish-shaped sweets** **Toys of choice, including plastic trees** 1. Place the peanuts in a bowl. Melt the chocolate according to package instructions and use to coat the peanuts. Drop clusters of varying sizes onto a baking sheet lined with greaseproof paper and leave to set in the refrigerator. (You may make these a few days in advance to save time.) 2. Prepare the cake batter. Fill the round tin up to approximately one-third of the way and place the rest of the batter in the square tin. Bake as directed and leave to cool completely. 3. Cut a 25 mm wide slice from one edge of the round cake and set aside. Form indentations along the remaining edge to create an irregular coastline, trimming at an angle to create a beach. 4. Coat the square cake very roughly (stormy sea!) with blue icing. 5. Coat the side edges of the round 'island' with flesh-coloured icing, press in the Marie biscuit crumbs for sand and place the island along one back corner of the square cake. 6. Use the multi-hole nozzle to coat the top of the island with green grass. 7. Slice the 25 mm strip of cake in half across the centre and sandwich together along the straight edges to create the ship's bow. Coat with white icing and place in the sea. Create the funnel and portholes using the sweets, as illustrated. 8. Place the 'rocks' (peanut clusters) around the ship in the sea plus an additional few along the coastline. 9. Add a few shark- and fish-shaped sweets to the sea. 10. Arrange the toys as illustrated to create the mayhem of a shipwreck. ## **World Cup Soccer** ### **SETTING THE SCENE** _Prepare to carry the trophy as you score with this popular theme! Don't exclude the girls from this winning event._ * A few weeks before the party select an appropriate venue. This may be a nearby park where ball games are permitted, or alternatively you may be able to hire a school field or to use the facilities of a local sports club. Always have a back-up plan in the event of inclement weather. * To ensure that the birthday child's home is easily located, cut a large circle out of stiff cardboard and paint it black and white like a soccer ball. Bore two holes through the centre and attach to the front gate with a thin piece of wire. * Set up a ticket booth at the entrance from where each child selects a 'player's pass' from a hat. The cards should be printed in the two opposing team colours so that this distribution ensures a fair team selection process. Mount a board against the wall where players' names are chalked in in their relevant teams. * Set up a face-painting station where the children's faces are adorned with their respective team's colours. Supply each child with a coloured sash in his or her team colours. * Depending on the facilities at the venue, you may prefer to return to the party house for refreshments. * Cover the party table with a green cloth and use white tape or chalk to mark out a soccer field. * Adorn the walls of the party area with posters of favourite stars interspersed with giant rosettes made from crepe paper. * Any available family trophies may be impressively displayed on the table to add to the décor. * Soccer memorabilia placed on the table or attached to the walls will further complement the theme. * Tie bunches of balloons in team colours to the corners of the ceiling in the party area. **_Recommended age group: 6–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Soccer shirt template (page)** **Pencil** **Yellow board paper** **Blue board paper** **Scissors** **Craft glue** **Soccer ball sticker (optional)** **Felt-tip marker** 1. Trace the outline of the template onto the yellow board paper as well as the blue board paper. Cut out. 2. Cut out the trim from the blue paper and use craft glue to attach to the shirt. 3. Attach the soccer ball sticker, if using, to the shirt. 4. Use the marker to write the guest's name on the 'chest' of the shirt and the number of the birthday child's age. 5. Write the party details (see suggested wording) on the back of the shirt. **SUGGESTED WORDING** Head over to (birthday child's name)'s soccer party on (date) **Stadium:** (party address) **Kick off:** (time party starts) **Final whistle:** (time party ends) **RSVP:** The Referee at (phone number) **Dress:** As for soccer game. (Ensure that children arrive timeously if you are proceeding to an alternative venue.) ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Soccer shirt template (page)** **Pencil** **Yellow board paper** **Blue board paper** **Scissors** **Craft glue** **Felt-tip marker** **Plastic lunchbox in the teams' colours (available from plastic discount stores)** **Prestik® or Blu-tac™** 1. Make a soccer shirt as per the invitation, but on a smaller scale. 2. Write the guest's name on the soccer shirt and attach to the lid of the container with Prestik®. ### **GAMES AND ACTIVITIES** _**Have a first-aid kit on hand for minor injuries!**_ Enlist the help of older teenage boys or a few fathers to play the role of referee, coach and assistants. Visit the venue prior to the party to assess facilities. If necessary, purchase traffic cones to demarcate the goal area. Decide on the length of play, depending on the age of the guests. Parents may want to remain to watch the World Final – ascertain numbers with the RSVP's to allow for catering. If transport is required to get the children to the venue, ensure that it is safe and reliable. Encourage crowd participation to add to the spirit of the game. Consider older sisters or other family members in cheerleading roles. Serve drinks and a light snack at half time and save the rest of the party fare for after the game. After the final whistle, award prizes in various categories, ensuring that each child receives a small token. Suggestions: Fastest Runner, Most Goals Scored, Furthest Kick, Shortest Player, Curliest Hair, etc., thus ensuring that each player has a moment of glory. Here are a few extra activities as an alternative to a match play if the party is held at home. #### **WORLD FINAL KICKOFF** **You will need:** **2 × small plastic traffic cones** **Soccer ball** Demarcate a goal area in the garden using traffic cones. The children stand behind a predetermined line and take turns to have a kick at goal. Successful scorers progress to the next round, with the kick-off angle becoming more difficult each time. Game continues in this manner until there is a winner, who receives a prize, the rest receive tokens. #### **DARE TO DRIBBLE** **You will need:** **2 × soccer balls** The children are divided into two teams and line up standing abreast of each other at arm's length. Each team leader has a soccer ball at his feet. On starter's orders the leader passes the ball to the child next to him. Play continues in this manner along the line until the end child receives the ball. The child then dribbles the ball down the back of the line to take up position at the head, where he or she in turn passes to the next child. Play continues in this manner until all children have had a turn to dribble down the back of the line. The first team to finish receives a prize, the rest receive tokens. #### **HOLD A YELLOW CARD** **You will need:** **One or more yellow cards** **Whistle** Instruct the children to sit in a circle. Hand one child a yellow card. The referee stands with his back to the circle to ensure impartiality. On his orders the children pass the card from one to the other. When the referee's whistle blows the child holding the yellow card is out. Play continues in this manner until one child is left. This child is declared the winner and receives a prize, the rest receive a token. To speed up the game and increase the fun level you may wish to add a second card, ensuring that both cards are passed in the same direction. ### **PARTY FOOD** #### **DRIBBLING DOGS** _**The onion and tomato mixture makes about 8 servings. Remember to cater for parents and helpers too.**_ **2 medium onions, sliced** **30 ml (2 Tbsp) butter** **5 ml (1 tsp) curry powder** **5 ml (1 tsp) sugar** **15 ml (1 Tbsp) vinegar** **1 × 450 g can peeled and chopped tomatoes** **Salt and pepper to taste** **Hot dog rolls, one per guest plus a few extra** **Vienna sausages or frankfurters** **Paper serviettes** **Tomato sauce (in squeeze bottle to facilitate serving)** **Mustard sauce (in squeeze bottle)** 1. Fry the onions in the butter until soft. 2. Mix together the curry powder, sugar and vinegar. Add to the onions, together with the tomatoes, and simmer for 5 minutes. Add salt and pepper to taste. 3. Make a slit in each roll and spread with butter. 4. Place the sausages in boiling water until heated through. Drain and place in the buttered roll. 5. Serve rolled in a serviette and set out the onion and tomato relish and tomato sauce and mustard for guests to help themselves. #### **SOCCER SHIRT BISCUITS** **Easy Biscuits (page)** **Soccer shirt template (page)** **Icing (page) – yellow, blue** **Soccer ball chocolate** 1. Prepare the biscuit dough as per the recipe. Trace the template onto cardboard and use it to cut out the biscuits. Bake as directed and leave to cool completely. 2. Coat the biscuits with yellow icing, and then use a small star nozzle and blue icing to add the stripes. 3. Place a chocolate in the centre of each shirt or alternatively use the writing nozzle to enhance the biscuits with the birthday child's age. #### **GOAL-SCORING CUPCAKES** **Sugar paste** **Powdered food colouring – black** **Party Cupcakes (page)** **Yellow paper or foil cookie cups (baking cases)** **Icing (page) – yellow, white, blue** 1. Colour the sugar paste black and mould to form soccer boots. (Create a sausage shape and use the rounded end of a wooden spoon or similar to mould the opening of the shoe.) Set aside to firm up. 2. Bake the cupcakes in the cookie cups as per the recipe and leave to cool completely. 3. Decorate the boots with white icing as illustrated. 4. Coat the cupcake with yellow icing; use the star nozzle to create a blue border before arranging the boots on the top. #### **TEAM PLAYER** **Sugar paste** **Powdered food colouring – flesh** **Small sweets of choice** **Wafer ice-cream cones** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – green, yellow, blue, white, black, red, brown** **Pipe cleaners, 120 mm in length** 1. Colour the sugar paste with flesh-coloured food colouring and roll into a walnut-sized ball for the head. Set aside to firm up. 2. Place the sweets of choice in the ice-cream cone. 3. Coat one side of the Marie biscuit with green icing and place, iced side down, over the open end of the cone. Upend so that the biscuit forms the base. Cut the tip off the cone and discard. 4. Use the star nozzle to ice the clothes and legs. Attach the head to the open end of the cone with icing. Use the writing nozzle to create the facial features and the multi-hole nozzle for hair. 5. Cut a pipe cleaner in half and gently insert in position on either side of the cone, bending to shape. 6. Neaten the base of the cone with green piped stars. ### **A SOCCER WORLD FINAL BIRTHDAY CAKE** **2½ × Basic Cake (page) – 1 × 280 mm round cake, 2 × 1.5 litre ovenproof pudding bowl cakes** **Icing (page) – green, white, black** **Wooden dowel sticks** **Toy soccer players** 1. Prepare 1 × cake batter and bake the round cake as per the recipe. 2. Prepare the additional 1½ × batter, divide between the two pudding bowls and bake for 50–60 minutes until a skewer inserted into the centre comes out clean. Leave the cakes to cool completely. 3. Use the multi-hole nozzle and green icing to coat the round cake to resemble grass. 4. Use a serrated knife to level the surfaces of the bowl cakes. Cover one with a layer of icing, and upend the second bowl cake and place on the first to form a ball. Coat the ball with a thin layer of white icing. 5. Trace the templates onto cardboard and mark out the sections on the ball. Note: It is easier to decorate the lower section of the ball before placing it in the centre of the 'grass', being careful not to disturb the icing. 6. Use the writing nozzle and black icing to connect the shapes as illustrated, and the star nozzle to decorate the ball. 7. Insert dowel sticks to secure the ball in position before completing the rest of the shapes. 8. Place the toy soccer players in position as preferred. ## **Stone Age** ### **SETTING THE SCENE** _Dinosaurs remain an all-time favourite – team them up with cavemen and cavewomen and your party will be a roaring success!_ * Tie a large bunch of brown and gold balloons together and attach to the front gate with brown and gold curling ribbons. * Lay a path of pebbles from the gate to the party entrance. * Create a cave-like entrance at the front door with two brown sheets; join them so that just a small opening remains for guests to crawl through. * Potted ferns and large rocks will enhance the appearance of the cave entrance. * Create a canopy over the table in the party area by draping brown streamers from the centre of the ceiling to the outer edges. * Tie bunches of gold and brown balloons together and attach to the corners of the ceiling. * Suspend varying lengths of garden creepers from the ceiling; some may be twisted together to form thicker 'ropes'. * Surround the table with potted ferns and other suitable greenery. * Cover the table with a brown cloth or hessian and serve the food on stone tablets (wall or floor tiles work well here). * Place toy dinosaurs and stones of varying sizes on the table, with smaller potted ferns interspersed between them. **_Recommended age group: 5–10_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Notepaper** **Flat stone** **Prestik® or Blu-tac™** **Green raffia** **Brown nametag** **Glitter pen** **Paper punch** 1. Write the party details (see suggested wording) on the notepaper, fold and attach to the underside of the stone with Prestik®. Tie with the raffia to secure. 2. Write the guest's name on the nametag with the glitter pen, punch a hole near one corner and tie into the raffia bow. **SUGGESTED WORDING** Hitch a ride on a dinosaur to (child's name)'s party on (date) **Cave:** (party venue) **Prehistoric era:** (duration of party) **RSVP:** Cave Mum at (phone number) before (date) **Dress:** Stone age! ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Faux fur fabric, 400 × 200 mm** **Stapler** **Bone template (page)** **Pencil** **Cardboard** **Brown board paper** **Scissors** **Craft glue** **Glitter pen** **Self-sealing plastic food bag** 1. Fold the fabric in half across the width and staple the two side edges together. 2. Trace the outline of the bone onto the cardboard and the board paper. Cut out and glue together. 3. Write the guest's name on the bone with the glitter pen and staple to the front of the pouch. 4. Line the pouch with the plastic food bag to hold the treats. ### **GAMES AND ACTIVITIES** #### **Cave Exploration** **You will need:** **Glow-in-the-dark stickers and toys** **Artificial spider webs or black polyester fibre filling** **Plastic snakes and spiders** **Plastic skeletons** **Glow-in-the-dark paint** **Cardboard** **Flashlight** **Small plastic dinosaur for each guest** Set aside a room to turn into a cave. Close the curtains and block out excess light with thick drapes or blankets. Attach glow-in-the-dark stickers and toys to the walls and ceiling. Hang artificial spider webs from the ceiling with fishing line so that they may brush against cheeks as the children venture inside. Plastic, preferably glow-in-the-dark, snakes and spiders will add to the intrigue! Plastic skeletons tucked into corners and other nooks will be discovered as the children shine their torches around the cave. Use glow-in-the-dark paint and cardboard cutouts to create dinosaur footprints (see template on page ) to accentuate the prehistoric theme. Allow the children to enter one at a time or in small groups. Supply children with a flashlight as they enter the cave. Hide a toy dinosaur for each guest, labelled with the guest's name, and instruct each to retrieve this on exploration in the cave. #### **Lava Rush!** **You will need:** **1 × blindfold for each guest** **1 × bowl of custard for each pair of guests** **1 × plastic teaspoon for each pair of guests** Divide the children into pairs – blindfold each child. The children sit cross-legged, facing each other. Provide each pair with a bowl of custard and a plastic spoon. On starter's orders one child in each pair has to feed the lava to his or her partner. The pair who finishes their bowl of lava first with the least mess is the winning team and receives a prize, the rest receive a token. #### **Toil in the Quarry** **You will need:** **1 × balloon for each child, plus extras** **1 × paper packet per balloon** **2 × duvet covers** **2 × wooden planks or bats, or similar** Place an inflated balloon inside a paper packet and twist to secure (to prevent a mess when the balloons are popped). Repeat until you have one balloon per guest, plus extras. The children split into two teams and stand abreast in a line, each team facing the other with a fair distance between them. Place the plank or bat on the ground at the head of the line. Divide the balloons and put them inside the duvet covers, which are then placed at the end of each line. On starter's orders the child at the end of the line reaches into the duvet cover to grasp a balloon. The balloon is passed down the line to the child at the front end, who picks up the plank and whacks the balloon until it pops. He or she then places the plank back in position and runs to the end of the line to retrieve a balloon from the bag to pass down the line. The play continues until all the children have had a turn. The winning team receives a prize, the rest of the children receive a token. #### **Musical Dino Prints** **You will need:** **Dino footprint template (page)** **Pencil** **Cardboard** **Scissors** **Music** Trace the template onto the cardboard and cut out dinosaur footprints, one less than the number of children. Place on the ground in the play area. On starter's orders and to music, the children dance about – when the music stops each child rushes to a footprint. The last child is extinct! Play continues and with each round a footprint is removed, thus ensuring that there is always an extra child. The last child remaining receives a prize, the rest receive a token. ### **PARTY FOOD** #### **Cute Caveman Cupcakes** **Sugar paste** **Powdered food colouring – flesh** **Small gingerbread man cutter** **Party Cupcakes (page)** **Paper or foil cookie cups (baking cases)** **Icing (page) – green, yellow, brown, black** 1. Colour the sugar paste and roll out to 4 mm thick. Cut out the little man and set aside to firm up. 2. Bake the cupcakes in the cookie cups as per the recipe and leave to cool completely. 3. Coat the cupcake with green icing. 4. Use a small star nozzle to adorn the caveman's body with 'animal skin' clothing, as illustrated. Place in position on the cupcake before piping the hair. 5. Use the writing nozzle to add eyes and a mouth. #### **Rock (sorry, stone) Cakes of course!** **250 ml (1 cup) cake (plain) flour** **A pinch of salt** **8 ml (1½ tsp) baking powder** **25 ml (5 tsp) sugar** **75 ml (5 Tbsp) chopped dried fruit** **50 ml ( cup) butter or margarine** **1 egg and enough water or milk to make up to 100 ml** **Castor sugar for sprinkling** **Dinosaur-shaped sweets or toys** **Icing (page) – chocolate** 1. Preheat the oven to 160 °C (325 °F, Gas Mark 3). 2. Mix the flour, salt, baking powder, sugar and dried fruit together. 3. Melt the butter and add to the egg/milk mixture. 4. Add the liquid to the dry mixture and blend well. 5. Drop spoonfuls of the mixture onto a greased baking sheet and bake for 10–15 minutes. 6. Remove from the oven and immediately sprinkle lightly with castor sugar. Allow to cool. 7. Add a dinosaur sweet or toy to the top of the cake, securing with a blob of icing. #### **Volcanic Rocks** **500 g lean beef mince** **5 ml (1 tsp) crushed garlic** **1 small onion, finely chopped** **1 small carrot, finely chopped** **2 slices bread, crumbed** **15 ml (1 Tbsp) chutney** **15 ml (1 Tbsp) vinegar** **Salt and pepper to taste** **2.5 ml (½ tsp) mixed herbs or sweet basil** **Cake (plain) flour for coating** **1–2 eggs, beaten** **Oil for frying** **Tomato sauce** **1 × sparkler** 1. Mix the mince, garlic, onion, carrot, breadcrumbs, chutney, vinegar, seasoning and herbs together. Form the mixture into meatballs of desired size. 2. Coat in flour and then beaten egg. Fry for 8–10 minutes in oil, turning frequently. Remove from the pan and drain excess oil on paper towels. 3. Pile up the meatballs in the shape of a volcano. Drizzle tomato sauce down the sides. Insert a sparkler into the top and light upon serving. Serve with plastic picks once the volcano has stopped erupting. Remove the sparkler as soon as it is spent! #### **Hunting Tool** **Easy Biscuits (page)** **Arrowhead template (page)** **Wooden skewer, about 150 mm in length** **Cooking chocolate** 1. Prepare the biscuit dough as per the recipe, rolling slightly thicker than normal. Use the template to cut out arrowhead shapes. Insert the wooden skewer and bake until browned. Leave to cool completely. 2. Melt the chocolate according to package instructions. 3. Dip the arrowheads into the melted chocolate, and then place on a wire rack with greaseproof paper underneath until set. ### **STONE AGE BIRTHDAY CAKE** **2 × Basic Cake (page) – 1 × 280 mm square cake, 1 × 200 mm round cake, 1 × 1.5 litre pudding bowl cake** **Icing (page) – brown, yellow** **'Greenery' available from craft shops** **Crunchie honeycomb sweet pieces** **Speckled egg sweets** **2 × small dolls** **Dinosaur toys** **Chocolate-coated nuts in varying sizes** **White bone-shaped sweets** 1. Prepare the cake batter as per the recipe and pour into the cake pans. Use the one batch for the square cake and divide the second cake batter between the round tin and the pudding bowl. Because of the depth of the bowl cake the baking time should be extended to 50–60 minutes. Leave the cakes to cool completely. 2. Coat the upper surface of the round cake with brown icing. Trim the surface of the pudding bowl cake if necessary and place flat side down on top of the round cake. Hollow out a cave entrance, using the removed section to 'pad' around the base of the dome if necessary to fit neatly on the round cake. 3. Coat the square cake with brown icing and place the cave in position as illustrated. 4. Insert the artificial greenery as illustrated. 5. Create a quarry with the Crunchie honeycomb sweet pieces. 6. Create a dinosaur nest with a mixture of brown and yellow icing and place the speckled eggs inside. 7. Place one of the dolls on the back of a dinosaur, securing with Prestik® or Blu-tac™ if necessary, and position on the cake. Add the other doll and dinosaurs as illustrated. 8. Pile the chocolate-coated nuts on the cake to resemble rocks. 9. Randomly scatter the white bone sweets around the cave. ## **High School Rock** ### **SETTING THE SCENE** _Guests will rock at this all-star production!_ * Attach a huge red cardboard star to the front gate. * Lay a path of smaller red stars from the gate to the party area. * Line the walk with fluttering felt pennants. These are easy to make – use the template on page and attach the pennants to a dowel stick. If you like, write each guest's name on a pennant – include a thank-you note secured around the stick with an elastic band – and distribute at the end of the party. * Use the same template to create party banners in colours of choice to hang against the walls in the party area. * Use red board paper to create large music notes to fix to the walls in the party room. Enhance with glitter for extra sparkle. * Create a 'stage' by hanging a white, red or black sheet against the wall. Frame the sheet with a rope of twinkling lights. * Use fishing line to suspend red baubles of varying sizes, at varying heights, from the ceiling. Intersperse with red cardboard stars if desired. Decorate with glitter glue to enhance. * Cover the party table with a white cloth. Sprinkle with red star and/or music note confetti. * Place school-related items on the table – pencils, books, rulers, erasers, plastic alphabet letters, plastic numbers, etc. * Use red and white crepe paper to make cheerleader pompoms and arrange in bunches throughout the party area; ensure that there is a pair for each guest. * Provide a glowstick for each guest to wave in time to the chosen lyrics. **_Recommended age group: 10–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Clapper Board template (page)** **Pencil** **Red board paper** **Craft glue** **Thin cardboard** **Scissors** **White board paper** **Star template (page)** **1 × split pin paper fastener** **Notepaper** **Glitter pen** 1. Use the template to trace the clapper board and upper strip onto the red board paper. Glue to the thin cardboard. Cut out. 2. Use the template as a guide to cut out the stripes from the white board paper and glue in position as illustrated. 3. Trace the star onto white board paper and cut out. Attach to the centre of the clapper board. 4. Bore a small hole through the end of the loose strip as well as through the upper left corner of the clapper board. Insert the split pin to secure. 5. Cut a piece of notepaper to fit the back of the clapper board without protruding, write the party details (see suggested wording) and attach to the back of the board with glue. 6. Write the guest's name on the star with a glitter pen. **SUGGESTED WORDING** **Scene 1:** (birthday child's name)'s High School Rock Party **Take 1:** Birthday blast on (date) **Auditions start:** (time party starts) **Auditions close:** (time party ends) **The rocking venue:** (address) **RSVP:** The Director @ (phone number) **Dress:** As for High School! ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Star template (page)** **Pencil** **White board paper** **Scissors** **Brown paper packet** **Stapler** **Red gift ribbon, 500 mm in length** **Glitter pen** **Craft glue** 1. Trace the outline of the star template onto the white board paper and cut out. 2. Fold the top of the paper packet over twice to close and staple to secure. 3. Wrap the ribbon around the bag and staple the ends together at the back. 4. Write the guest's name on the star with the glitter pen and use craft glue to attach it to the front of the bag. ### **GAMES AND ACTIVITIES** Hire a karaoke for this party or use similar sing-a-long computer programs. Consider that not all guests will feel comfortable singing and dancing solo so allow the formation of pairs or small groups. Children may prefer to choreograph in two large groups. If possible, have two older teens assist with this part of the organisation and to format each item on the programme. Allow time for children to practise their productions, arrange seating in front of the stage, appoint a master of ceremonies to announce each item and sit back and enjoy the show. Allow an interval during the show or after the rehearsals for refreshments. Be sure to award prizes in categories that will ensure that each child receives an award, for example: Best Song, Best Rhythm, Curliest Hair, Tallest Dancer, Loudest Voice, Loudest Cheering, Best Glow Stick Waves, etc. As an optional extra provide a make-up station, manned by an older teen, where guests may adorn themselves with make-up, temporary tattoos, face paint, coloured hair gels and sprays, body glitter, etc. Additional activities are unnecessary as the children will enjoy 'free dancing' if time permits. ### **HIGH SCHOOL ROCK BIRTHDAY CAKE** **2 × Basic Cakes (page) – 320 × 220 mm each** **Icing (page) – white, red** **Wooden skewers** **Silver balls** **Sugared jelly sweets for spotlights** **Dolls of choice** **Prestik® or Blu-tac™** 1. Bake the cakes according to the recipe and leave to cool completely. 2. Cut a 200 × 220 mm rectangle from each cake and sandwich together with icing to form the stage. 3. Slice the remaining 120 × 220 mm of each section into three 40 × 220 mm strips. Place three of the strips along the back of the stage for the curtain, sandwiching together with icing and using wooden skewers to secure. (Freeze the fourth strip for later use in a trifle or similar.) 4. Coat the upper surface of the stage with white icing and the sides of the cake with red icing. 5. Coat the curtains with red icing and use the star or ribbon nozzle to create the drapes. Enhance with silver balls. 6. Position the sugared jelly sweets along the front edge of the stage for spotlights. 7. Attach the dolls to wooden skewers with Prestik® and insert into the cake as illustrated. ### **PARTY FOOD** #### **TUNEFUL SUNDAE** _**Make the sugar paste music notes ahead of time and set aside until ready to serve.**_ **Sugar paste** **Powdered food colouring – red** **Music Note template (page)** **Edible glitter** **Vanilla ice cream** **Parfait dish** **Red syrup** 1. Colour the sugar paste red and roll out to about 4 mm thick. Use the template to cut out music notes. Brush with edible glitter and set aside to firm up. 2. Place scoops of ice cream in a parfait dish, drizzle with syrup, sprinkle with glitter and decorate with the music note. #### **MEGAPHONE BISCUITS** **Easy Biscuits (page)** **Megaphone template (page)** **Icing (page) – red, white** **Silver balls** **Edible glitter** **Small white star sweets (or fashion from sugar paste)** 1. Prepare the biscuit dough as per the recipe. Use the template to cut out megaphone shapes and bake according to instructions. Leave to cool completely. 2. Coat the biscuits with red icing and decorate as illustrated. 3. Dust with edible glitter and place a small star sweet in position. #### **NACHOS** _**Serves 8.**_ **4 × 150 g packets corn chips of choice** **1 × 250 g tub plain chunky cottage cheese** **1 × 410 g can Mexican chopped tomatoes** **300 g Cheddar cheese, grated** **Ready-made guacamole** **Sour cream (optional)** 1. Preheat the oven to 180 °C (350 °F, Gas Mark 4). 2. Spray an ovenproof dish with non-stick cooking spray. Layer the chips on the bottom of the dish. 3. Spoon the cottage cheese over the chips, spreading roughly with a fork to cover the chips. 4. Pour over the tomatoes and top with grated cheese. 5. Bake for about 20 minutes until heated through and the cheese has melted. 6. Serve with a dollop of guacamole and sour cream. #### **MICROPHONE CUPCAKES** **Party Cupcakes (page)** **Red foil cookie cups (baking cases)** **Mini marshmallow-filled ice-cream cones** **Icing (page) – white** **Large red sugared jelly sweets** **Red edible glitter** 1. Bake the cupcakes in the cookie cups according to the recipe and leave to cool. 2. Use a serrated knife to cut any protruding marshmallow from the cone, to level the surface. Coat with icing and attach the sugared jelly sweet. 3. Cover the cupcake with a swirl of white icing and place the cone on the cake as illustrated. 4. Sprinkle the surface of the cake with edible glitter. ## **Crime Scene** ### **SETTING THE SCENE** _The excitement generated by this theme will certainly fail to be kept undercover!_ * Attach a bunch of black and grey balloons to the front gate. * Use the template on page to generate a path of shoe prints from the front gate to the party area. * Put hazard tape (black and yellow or red and white striped tape) across the front entrance so that guests have to crawl through the 'crime scene'. * Create a streamer canopy over the party table using black and grey twisted streamers. * Tie bunches of black and grey balloons together and attach to the corners of the ceiling. * Use the templates to create question marks (page ) and shoe prints (page ) of varying sizes and attach to the walls in the party area. * Dim the lighting or replace clear light bulbs with black (available at supermarkets) if the party is held in the early evening, otherwise cover windows with black paper to block out light. * Use more hazard tape to seal off the party table. * Place props of disguise on the party table, for example fake noses, moustaches, spectacles and hair pieces. Add binoculars, torches and a magnifying glass to further enhance the undercover investigation. **_Recommended age group: 8–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Silver or grey board paper, 100 × 100 mm** **Thin cardboard, same size as the board paper** **Craft glue** **Ink pad** **Notepaper** **Toy magnifying glass** **Prestik® or Blu-tac™** **Silver ribbon** 1. Glue the board paper to the thin cardboard. 2. Use the ink pad to create fingerprints on the board paper and allow to dry. 3. Write the invitation details (see suggested wording) on the notepaper and attach to the back of the cardboard with craft glue. 4. Run a thin strip of Prestik® around the rim of the magnifying glass and attach to the invitation, pressing to secure. (This allows for easy removal so that this essential prop may be brought to the party!) 5. Embellish with the ribbon. **SUGGESTED WORDING** **Scene of the crime:** (venue address) on (date) **Case:** To celebrate (birthday child's name)'s birthday **Solve the riddle:** (duration of party) **RSVP:** P.I. (Mom's name) at (phone number) **Dress:** Undercover! ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Question Mark template (page)** **Pencil** **Black board paper** **Scissors** **Craft glue** **Silver gift box** **Glitter glue** 1. Trace the template onto the black board paper. Cut out. 2. Glue to the lid of the gift box. 3. Decorate with glitter glue. ### **GAMES AND ACTIVITIES** The Kingdom of (birthday child's surname)'s jewels have been stolen. The king's crown has disappeared, together with the queen's enormous diamond. The princess's tiara is also missing and the prince's bag of gold coins was removed from his room. (The scenario may be adapted according to the age of the children – older guests may enjoy a 'villainous' mystery, but here I have elected to maintain a non-violent approach!) **You will need (per team):** **1 × plastic or cardboard crown** **1 × plastic tiara** **1 × large plastic 'crystal' bead** **1 × small bag of fake coins** **Florist's gemstones, or small beads** **1 × set of clues** **Paper and pen to record observations, per team** **Small scraps of material, wool, etc. (as per your preferred set of clues)** The children are divided into teams (as many teams as items missing) and set out on a mission to recover the missing items, one specific item to be found per team. Give each team a different set of clues. The mission may take them around the neighbourhood if preferred, but ensure that each team is accompanied by an adult if the children leave your property. Apart from the list of clues, each team is provided with a pen and paper to record their findings, for example finding green wool would mean the thief was wearing a green jersey; a lock of black hair would mean the thief had that colour hair; brown material caught on a stick would provide the clue to the pants; a number on a cardboard footprint would identify the size of the thief's shoe; a single sock or shoe would further assist with the villain's identity. A few dropped 'jewels' may provide a path to each clue. Once the clues have been gathered, each team puts together a profile, for example: The suspect escaped through the window; the suspect has black hair and is wearing a green jersey and brown pants; he or she wears a size 6 shoe and will be wearing only one shoe and sock. Older siblings, parents or obliging neighbours may surreptitiously mingle in the party area, dressed appropriately according to the clues and with the missing property on their person. The first team to locate their missing item is the winner and receives a prize; the rest receive tokens. #### **IDENTITY PARADE** **You will need:** **An old sheet or similar** **Pair of scissors** Cut a small peephole in the sheet at the children's eye level. Allow one per guest. You may create a second row at a level which would allow children to peep through in a crouching position. Drape the sheet against a wall or suspend over a washing line. Each guest has a turn to leave the room, whilst the others crouch or stand behind the sheet with an eye positioned at the peephole. Ensure that their bodies are covered to conceal identities. The 'detective' then returns to the room and attempts to identify each peeping eye by name. A score is kept and the child who gets the most correct is the winner and receives a prize, the rest receive a small token. #### **LEAVE YOUR FOOTPRINTS** **You will need:** **Cardboard** **Shoe print template (page)** **Music** Use the template to create shoe prints and place them in position on the ground along a track, quite a distance from each other. Allow sufficient for one per child, less one. The children form a line and attempt to jump from one print to the other in time to the music. When the music stops any child not on a print is out. Remove one print and continue until there is a winner. The winner receives a prize, the rest receive a token. ### **PARTY FOOD** #### **EYE SPY?** **Easy Biscuits (page)** **Keyhole template (page)** **Sugar paste** **Icing (page) – black** **Mini Smarties®** 1. Prepare the biscuit dough as per the recipe. Use the keyhole template to cut out the biscuits and bake as directed. Leave to cool completely. 2. Roll out the sugar paste to 4 mm thick. Cut out an oval shape for the eye. 3. Coat the biscuit with black icing. 4. Place the eye on the biscuit and attach the mini Smartie® with a small dab of icing. Use the writing nozzle to dot on the black pupil. #### **FOOTPRINT JELLIES** **Jelly (powder or cubes) – 5–6 servings per packet** **125 ml clear plastic containers** **Ready-made custard** **Footprint-shaped sweets** 1. Make the jelly according to packet instructions, pour into the plastic containers and place in the fridge until set. 2. Top with a layer of custard 3. Just before serving, place a footprint sweet on top of the custard. #### **UNDER WRAPS!** **Ready-made tortilla wraps** **Cooked chicken breasts** **Mayonnaise** **Sandwich spread** **Lettuce, shredded** **Tomato sauce (in a squeeze bottle)** 1. Prepare the wraps as per the package instructions. 2. Dice the cooked chicken. 3. Flavour the mayonnaise with sandwich spread and then mix into the chicken. 4. Place shredded lettuce on the wrap, add the chicken mayonnaise and fold. 5. Create a tomato sauce question mark on each wrap before serving. #### **SECRET MESSAGE CUPCAKES** _**Warn children to eat with care to avoid any possible injury from the straw.**_ **Party Cupcakes (page)** **Silver foil or paper cookie cups (baking cases)** **Drinking straws** **Notepaper** **Icing (page) – black, white** 1. Bake the cupcakes in the cookie cups as per the recipe and leave to cool completely. 2. Cut the straw to fit (approximately 50 mm) so that it may be inserted into the cupcake without being visible. 3. Write a message of choice on the notepaper, roll up and insert into the straw. (You may want to supply directions to finding a small hidden treat.) Slit one end section of the straw to allow for easy retrieval of the note. Press the straw into the cupcake at an angle so that most of it is submerged with just a tip showing for easy detection. 4. Ice the top of the cupcake with black icing. 5. Use the star nozzle and white icing to create a question mark on each cake. ### **CRIME SCENE BIRTHDAY CAKE** _**To change the gender of this detective, alter the lips and omit the padding for the hair. Simply create strands of hair from beneath the hat on either side of the head using the star nozzle and a pull-out motion.**_ **2½ × Basic Cake (page) – two × 320 × 220 mm cakes; one × 200 mm round cake** **1 × sugared jelly sweet for nose** **Icing (page) – flesh, grey, black, red** **Large silver balls** **Liquorice strips** **Small silver balls** **Firm cardboard** **Black sun glasses (available from discount stores), with side arms removed** **Pinch of sugar paste, coloured red (optional)** **Toy magnifying glass** 1. Bake the cakes according to the recipe and leave to cool completely. 2. Cut out and assemble the cakes as per the cutting guide. Use the round cake for the head, shaping slightly along the lower edge to form a chin. 3. Place the sugared jelly sweet in position for the nose and coat the lower face portion of the head with fleshcoloured icing. 4. Coat the sides and top of the trench coat with grey icing. Mark out the collar section and pocket and use the star nozzle to accentuate. Create the opening below the belt with a single row of stars. 5. Ice a black belt using the star nozzle and create a buckle with large silver balls. 6. Cover the shoes with black stars. Add large silver balls for eyelets and join them with liquorice strips for laces. 7. Using the back of an icing nozzle as a template, gently press into the cake, down the centre, for the buttons. Fill in with small silver balls. 8. Cut the cardboard to shape (see template above), cover with foil, coat with grey icing and press into the cake to form the hat brim, supporting if necessary with wooden skewers (remember to remove these when cutting the cake). 9. Coat the upper part of the head with grey icing to form the hat. Use the star nozzle and black icing to make the hat band. 10. Pad the face with offcuts and use the star nozzle and a pull-out action to create the hair. Add the sun glasses. 11. Use the writing nozzle and black icing to outline the lips. Fill in with the small star nozzle and red icing. Alternatively fashion lips from red sugar paste. 12. Cover the rod of the magnifying glass with foil and press into the pocket to complete your super sleuth. ## **Travel to Egypt** ### **SETTING THE SCENE** _Invite your guests to walk back in time and party like Egyptians!_ * Decorate the walls in the party area with pictures or posters that represent ancient Egypt, for example hieroglyphics, pharaohs, mummies, scarabs, the Sphinx, camels, etc. * Create a canopy above the party table by draping blue streamers from the centre of the ceiling to the outer edges. * Tie bunches of blue and gold balloons together and attach to the corners of the ceiling. * Cover the party table with a gold or sand-coloured cloth. Use a strip of blue organza or similar material to represent the River Nile, winding its way along the table. * Scatter beads and imitation jewels and crystals on the table. * Gold-covered chocolate coins are a welcome addition to the opulence of this theme. * An odd scarab peeping out from beneath a plate of food will add to the mood. Crumb a few biscuits and scatter on the table to simulate sand. * Set up a face-painting station where your guests may have their features adorned by a willing family friend or two! * An enterprising dad may want to greet the guests as a bandage-swathed mummy, whilst the mom may want to be Cleopatra. * Place available potted palms and reed-like plants in the party area. Miniature potted palms will look good on the party table. **_Recommended age group: 6–12_** ### **INVITATIONS** **YOU WILL NEED (PER INVITATION):** **Notepaper** **Small pyramid-shaped gift box** **Plastic scarab or similar, or one or two gold-covered chocolate coins** **Board paper** **Scissors** **Craft glue** **Thin cardboard** **Felt-tip marker** **Gold glitter glue** 1. Write the invitation details (see suggested wording) on the notepaper, fold and place in the gift box together with the scarab or chocolate coins. 2. Cut a square base, large enough to support the pyramid, from the board paper, and glue to cardboard cut to the same size. 3. Write the guest's name on the underside of the base. (You may prefer to omit the base, in which case write the name on the side of the pyramid.) 4. Attach the pyramid to the base with craft glue and decorate the surrounding space with glitter glue. **SUGGESTED WORDING** Saddle up your camel at (child's name)'s birthday party! **Uncover the secrets of the pyramids on:** (date) **Oasis:** (address) **Tour time:** (duration of party) **RSVP:** The Mummy at (phone number) **Dress:** Egyptian ### **TREAT BAGS** **YOU WILL NEED (PER TREAT BAG):** **Calico fabric or similar, 500 × 220 mm** **Pencil** **Light brown fabric paint** **Gold glitter glue** **Ribbon, 70 mm in length** **Glitter pen** 1. Fold the material in half across the length. 2. Draw a triangle with the pencil on the front of the bag. 3. Open out the material and place on a flat surface to colour in the pyramid with the fabric paint. Allow to dry before decorating with the glitter glue, and again set aside to dry. 4. Fold the bag in half again, this time inside out. Sew the bag along the two side edges. Leave the top open for the ribbon. 5. Turn the bag right side out. Turn down about 20 mm to the inside and hem to form a casing. Leave about 20 mm free to insert the ribbon. Thread the ribbon through the casing and knot to secure. 6. Write the guest's name on the bag with glitter pen. ### **GAMES AND ACTIVITIES** #### **CROSSING THE NILE** **You will need:** **Blue sheet** **Small squeaky toys or plain squeakers (available from craft shops)** **Blindfold** Place the sheet on the ground and randomly scatter the toys or squeakers underneath. The children line up and take turns to be blindfolded. Spin each child around a couple of times before allowing them to cross the Nile. Instruct them to be mindful of waking the Nile crocodiles. Children who successfully complete the crossing down the Nile without being caught by a crocodile receive a small prize, the rest receive a token. #### **PASS THE MUMMY** **You will need:** **Material torn into strips** **1 × present** **String** **Red string** **Music** **Small box (see suggestions for dare items)** Tear the material into strips and wrap a present in layers, like a mummy, ensuring that there is one layer per child. Secure each layer with natural string. Use a red string to indicate a dare. The parcel is passed from child to child whilst the music plays. When the music stops the child holding the mummy has to unwrap a layer. The child who unties the red string has to do a dare. Blindfold the child and offer an opportunity to feel inside the mummy's tomb. Offer a small box with a hole just big enough for a child's hand – inside have a few cleaned chicken leg bones, spaghetti, grapes, a small plastic container of jelly, a lock of hair, etc. Play continues until there is a winner, who keeps the present. You may offer the children who did the dare a small prize as well. The rest receive tokens. #### **WALK LIKE AN EGYPTIAN!** **You will need:** **Music** **2 × bundle of cloth tied securely with cord so that it may be balanced on the head** The children line up one behind the other in two teams. Hand the first child in each team a bundle. As the music plays the child places the bundle on his or her head and 'walks like an Egyptian' from the starting point to a demarcated line a fair distance from the team and back again, where the bundle is handed to the next child in line. Any dropped bundles dictate that the child has to return to the starting line. Play continues in this manner until all the children have had a turn. The winning team receives a prize, the rest receive tokens. #### **SPITTING COBRAS** **You will need:** **2 × water pistols** **2 × blindfolds** **± 6 × rubber snakes** Place the rubber snakes along the ground, parallel to each other and approximately 1 metre apart. Two adults are blindfolded, armed with water pistols and then stand on either edge of the play area. The children form a line and have to cross the play area, jumping over each snake whilst avoiding the poisonous spurts from the water pistols. The first child across rejoins the end of the line, allowing play to move in a circle. The children move over the snakes in quick succession whilst the adults shoot at them with water pistols. Any child who is hit is out. Play continues in this manner until there is a winner, who receives a small prize, whilst the rest receive tokens. ### **PARTY FOOD** #### **MIGHTY RIVER NILE** **Caramel-coloured ice cream** **Flat plastic serving dishes** **Bubblegum-flavoured syrup** **Wafer fans** **Paper parasols** 1. Place the ice cream in the serving dish and flatten to form a 'desert'. Create a groove running down the centre. 2. Trail blue syrup in the groove to create the Nile River. 3. Insert a wafer fan upside down to look like a pyramid. Enhance with the paper parasol. #### **SWEET MUMMY** **Wafer ice-cream cone** **Small sweets of choice** **Marie biscuits or Rich Tea™ biscuits** **Icing (page) – white** **White marshmallows** **Gold balls** 1. Fill the wafer cone with sweets. 2. Coat the Marie biscuit with icing and place over the open end of the cone. Upend so that the biscuit forms the base. 3. Cut the tip off the cone and attach a marshmallow for the head, securing well with icing. 4. Use the star or ribbon nozzle to swathe the cone in bandages to create a very sweet mummy. 5. Attach the gold balls for eyes. #### **TO YONDER PYRAMID!** **Wafer biscuits** **Icing (page) – light brown or sand colour** **Toasted coconut marshmallows** **Edible glitter** **Toy plastic camels** 1. Coat the top of the biscuit with icing. 2. Cut marshmallow diagonally across and place in position at one end of the biscuit. Dust lightly with edible glitter. 3. Add the camel to the desert scene, pressing into the icing to secure. #### **SPITTING COBRAS** _**Remember to warn the children about the cocktail sticks when serving.**_ **Party Cupcakes (page)** **Gold foil cookie cups (baking cases)** **Icing (page) – light brown or sand colour** **Large jellied snake sweet** **Wooden cocktail stick** **Gold balls** **Edible glitter** 1. Bake the cupcakes in the cookie cups according to the recipe and leave to cool completely. 2. Cover the top of the cake with icing. 3. Thread the head and upper portion of the snake onto the cocktail stick. Push the stick into the cake and wind the body of the snake around the stick. 4. Use the writing nozzle to make two icing dots on the head of the snake and attach a gold ball to each for the eyes. 5. Enhance the cupcake with a flower made from gold balls and sprinkle with edible glitter. ### **RIGHT ROYAL EGYPTIAN BIRTHDAY CAKE** **2 × Basic Cake (page) – 320 × 220 mm** **Icing (page) – flesh, royal blue, red, black, white, sand colour** **Wooden cocktail stick** **Large sugared jelly sweet** **Sweets of choice** **Sugar paste – white, black, red, for facial features (optional)** **Large gold balls** **Large jellied snake sweet, or use plastic toy snake** **Small gold balls** **Edible glitter** 1. Bake the cakes as directed and leave to cool completely. 2. Cut out and assemble the cakes as per the cutting guide. Trim the longer edges of the cakes to neaten and join together with icing. 3. Coat the entire assembled cake with flesh-coloured icing and mark out the various features with a wooden cocktail stick. 4. Place the sugared jelly sweet in position on the face to create the nose. Cover the face, neck and ears with a second layer of flesh-coloured icing. Create nostrils with a foil-covered cotton bud. Use the bud to form the ear indentations as well or outline features with a toothpick. 5. Use the star nozzle and royal blue and sand-coloured icing to create alternate stripes on the headdress and beneath the chin. 6. Use sweets to create an opulent bodice section, again alternating with rows of royal blue stars. 7. Create the facial features with the writing nozzle or fashion from sugar paste. Embellish the ears with large gold balls. 8. Add the snake to the headdress, using a wooden skewer if necessary to secure. 9. Place small gold balls on the bodice section to enhance. 10. Dust the cake with edible glitter. ## **Recipes** _Note: Extra-large eggs (61–68 g) have been used throughout._ ### **BASIC CAKE** _**Makes 1 × rectangular cake measuring 320 × 220 mm; OR 1 × round cake measuring 280 mm in diameter; OR 2 × round cakes measuring 200 mm in diameter; OR 2 × 200 mm square cakes; OR 1 × 1.5 litre ovenproof pudding bowl plus 1 × 0.5 litre ovenproof pudding bowl.**_ _**The ingredients are easily halved or quartered so that you may bake 1 × 200 mm round cake, and 2 × 125 mm cakes, when required.**_ **4 eggs** **300 g (300 ml) white sugar** **2½ cups (625 ml) cake (plain) flour** **4 tsp (20 ml) baking powder** **a pinch of salt** **¾ cup (180 ml) oil** **¾ cup (180 ml) water** **1 tsp (5 ml) vanilla essence** 1. Preheat the oven to 180 °C (350 °F, Gas Mark 4). 2. Beat the eggs, then gradually add the sugar and beat until thick and pale. 3. In a separate bowl, sift the flour, baking powder and salt together. 4. In another bowl, lightly whisk the oil, water and vanilla essence to combine. 5. Gently fold the dry ingredients, alternately with the liquid, into the egg mixture. 6. Depending on your requirements, pour the cake mixture into the required greased cake pan(s). 7. Bake for 30–35 minutes. To test whether the cake is baked through, insert a skewer into the centre of the cake. If it comes out clean, it is done. 8. Turn out onto a rack to cool completely before icing. ### **PARTY CUPCAKES** _**Makes about 20**_ **1½ cups (375 ml) self-raising flour** **1 tsp (5 ml) baking powder** **a pinch of salt** **¾ cup (180 ml) sugar** **2 eggs** **½ cup (125 ml) oil** **½ cup (125 ml) milk** **1 tsp (5 ml) vanilla essence** 1. Preheat the oven to 180 °C (350 °F, Gas Mark 4). 2. Mix the dry ingredients together. 3. Beat the eggs lightly and add the oil, milk and vanilla essence. 4. Add the liquid to the dry ingredients and mix well. 5. Spoon the mixture into cookie cups (baking cases) in a muffin tray and bake for 12–15 minutes. 6. Leave to cool before icing ### **ICING** _**This recipe is sufficient to ice the basic cake, but for larger cakes, and particularly where the star nozzle is used, the quantity will have to be doubled.**_ **100 g white margarine, at room temperature** **2½ cups (625 ml) icing sugar, sifted** **± 5 tsp (25 ml) boiling water** **½ tsp (2.5 ml) vanilla essence** 1. Mix together the margarine and sifted icing sugar. 2. Add the boiling water, a little at a time, and mix until the desired consistency is obtained. 3. Add the vanilla essence. 4. Once the icing has been mixed, it may be coloured by adding powdered colouring, blending in small quantities (about ¼ tsp/1 ml) at a time, until the desired shade is obtained. Liquid colouring may be used if preferred, but care should be taken that the consistency does not become too runny. **FOR CHOCOLATE ICING** Add 2 Tbsp (30 ml) sifted cocoa powder to the icing sugar and proceed as above. ### **MERINGUES** _**Makes about 36 (depending on shape)**_ **4 egg whites** **a pinch of salt** **1½ cups (375 ml) castor sugar** 1. Preheat the oven to 100 °C (200 °F, Gas Mark ¼). 2. Whisk the egg whites and salt until stiff and dry. 3. Gradually add half the sugar, and whisk until stiff peaks form. 4. Fold in the remaining sugar, gently but thoroughly. 5. Spoon about 2 tsp (10 ml) of the mixture onto baking sheets lined with greaseproof paper, spaced about 80 mm apart. 6. Bake for about 45 minutes. Switch off the oven, keep the door shut, and leave the meringues to cool completely, preferably overnight. ### **EASY BISCUITS** _**Makes about 24 (depending on the shape)**_ **125 g butter (at room temperature)** **½ cup (125 ml) castor sugar** **1 tsp (5 ml) vanilla essence** **1 egg, beaten** **2 cups (500 ml) cake (plain) flour** **4 Tbsp (60 ml) cornflour** **1 tsp (5 ml) baking powder** **a pinch of salt** 1. Preheat the oven to 180 °C (350 °F, Gas Mark 4). 2. Beat together the butter and castor sugar until pale. 3. Add the vanilla essence and beaten egg. 4. Add the sifted dry ingredients and knead well to form a stiff dough. 5. Roll out on a lightly floured board to a thickness of 3–4 mm. 6. Cut into desired shapes. 7. Bake on a greased baking sheet for 10–12 minutes until lightly browned. Remove to a wire rack. 8. Leave to cool completely before icing. 9. The dough may be prepared in advance and frozen until required (it will keep for 4–6 weeks). Alternatively, bake the biscuits in advance and freeze until required. ## **Templates** You can print these images from our website <http://www.randomstruik.co.za/cake-templates.php>. ## **Stockists** ### **BAKING SUPPLIES** **The Baking Tin** E-mail: info@thebakingtin.co.za * 52 Belvedere Road, Claremont, Cape Town. Tel: (021) 671 6434. * 132 Durban Road, Bellville, Cape Town. Tel: (021) 948 2274. * Shop 23, Glenwood Village, Cnr Hunt & Moore roads, Glenwood, Durban. Tel: (031) 202 2224. * Perridgevale Shopping Centre, Rochel Road, Perridgevale, Port Elizabeth. Tel: (041) 363 0271. **Baking Extravaganza** Eastdale Pavillion, Cnr Jacqueline & Hans Strydom Drive, Garsfontein, Pretoria. Tel: (012) 993 0750. www.bakingextravaganza.co.za **South Bakels** 6 Don Dodson Road, New East End, Bloemfontein. Tel: (051) 432 8446. www.sbakels.co.za **PQ Products** Unit 1A, Millside Park, 35 Morningside Road, Ndabeni, Cape Town. Tel: (021) 531 4061. **CAB Food Factory Shop** 34A Northumberland Street, Bellville, Cape Town. Tel: (021) 948 6644. ### **TOYS/ACCESSORIES** **Plastics for Africa** Unit 3B, Montagu Drive, Montagu Gardens, Cape Town. Tel: (021) 551 5790. www.plasticsforafrica.com **Plastics Warehouse** 26 Northumberland Road, Oakdale, Bellville, Cape Town. Tel: (021) 948 3042. **The Crazy Store** Branches countrywide. Head Office: Tel: (021) 505 5500. www.crazystore.co.za **The Factory Toy Shop** 250 Voortrekker Road, Parow, Cape Town. Tel: (021) 939 8958. ### **SWEETS/CHOCOLATES** **Giant Sweet Wholesaler** 3 Benbow Avenue, Epping 1, Cape Town. Tel: (021) 534 5925. **A2Z Candy** 27 Darius Street, Reyno Ridge, Witbank, Mpumalanga. Tel: (011) 498 2675. **The Chocolate Den** 99 Linksfield Road, Glendower Shopping Centre, Edenvale. Tel: (011) 453 8160. www.chocolateden.co.za **Sweets from Heaven** Branches countrywide. www.theheavengroup.com **Sunrise Sweets** Old Mutual Complex, Hermanstad, Pretoria. Tel: (012) 379 4748. www.sunrisesweets.co.za ### **PACKAGING** **Merrypak & Print** www.merrypak.co.za * 45 Morningside Road, Ndabeni, Cape Town. Tel: (021) 531 2244. * 21 Bridlington Road, Seaview, Durban. Tel: (031) 465 2719. ### **CRAFTS/FABRIC SUPPLIES** **The Crafters One-Stop Shop** Checkers Hyper, N1 City, Goodwood, Cape Town. Tel: (021) 595 2635. **Cape Arts and Crafts** Shop 27, Lower Mall, Canal Walk, Cape Town. Tel: (021) 555 3699. **Fabric City Wholesalers** 32 Sir Lowry Road, Woodstock, Cape Town. Tel: (021) 462 1287. **Arts, Crafts and Hobbies** 72 Hibernia Street (next to Mr Price), George. Tel: (044) 874 1337. E-mail: artcraft@polka.co.za **Maridadi Crafts** Shop 4, Centurion Mall, Centurion Boulevard, Centurion, Pretoria. Tel: (012) 663 4030. ## **Index** Page numbers in **bold** indicate photographs. ### **B** big number 1 90–95 birthday cake **** , décor ideas **** , games and activities invitations , **** party food , **** templates treat bags , **** birthday bugs 38–45 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates , treat bags , **** biscuits , , , , , , , , , , , , , , , basic recipe ### **C** cakes , , , , , , , , , , , , , , , , , , , recipe for basic cooking up fun 46–51 birthday cake **** , décor ideas **** , invitations , **** party food , **** templates treat bags , **** crime scene 142–149 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates , treat bags , **** cupcakes , , , , , , , , , , , , , , , , , , basic recipe cutting the ice 52–57 birthday cake **** , décor ideas **** , invitations , **** party food , **** templates treat bags , **** ### **D** décor 4–5, , , , , , , , , , , , , , , , , , , , destination Mars 58–65 cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates , treat bags , **** dotty do 8–15 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** treat bags , **** dressing up ### **E** enchanted forest 66–73 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates , , treat bags , **** ### **F** farmyard frolics 74–81 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** treat bags , **** feisty fire engines 82–89 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates , , treat bags , **** food 5–6, , , , , , , , , , , , , , , , , , , , ### **G** games and activities , , , , , , , , , , , , , , , , , ### **H** high school rock 136–141 birthday cake **** , décor ideas **** , games and activities invitations , **** party food , **** templates , , treat bags , **** ### **I** invitations , , , , , , , , , , , , , , , , , , , , ### **K** karate kicks 96–103 birthday cake , **** décor ideas **** , game and activities invitations , **** party food , **** treat bags , **** ### **M** my special pony 104–111 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates treat bags , **** ### **P** party supplies see stockists preparations putting par-tee 16–21 birthday cake **** , décor ideas **** , invitations , **** party food , **** treat bags , **** ### **R** recipes 158–159 basic cake chocolate icing easy biscuits icing meringues party cupcakes ### **S** shipwrecked and stranded 112–119 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates , treat bags , **** small affair 22–29 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates treat bags , **** stockists stone age 128–135 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates , , treat bags , **** ### **T** templates 160–165 thank-you notes themes big number 90–95 birthday bugs 38–45 cooking up fun 46–51 crime scene 142–149 cutting the ice 52–57 destination Mars 58–65 dotty do 8–15 enchanted forest 66–73 farmyard frolics 74–81 feisty fire engines 82–89 high school rock 136–141 karate kicks 96–103 my special pony 104–111 putting par-tee 16–21 shipwrecked and stranded 112–119 small affair 22–29 stone age 128–135 travel to Egypt 150–157 winning formula 30–37 world cup soccer 120–127 travel to Egypt 150–157 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** treat bags , **** treat bags , , , , , , , , , , , , , , , , , , , ### **W** winning formula 30–37 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates treat bags , **** world cup soccer 120–127 birthday cake , **** décor ideas **** , games and activities invitations , **** party food , **** templates treat bags , ****
{ "redpajama_set_name": "RedPajamaBook" }
1,090
{"url":"https:\/\/chemistry.stackexchange.com\/questions\/116761\/aldol-reaction-on-an-intermediate","text":"# Aldol Reaction on an intermediate\n\nI was given the following reaction to prove a mechanism for:\n\nand I managed to prove the first step with ease.\n\nThe second step, forming the \"base-catalysed aldol\" is the part that's rather confusing me.\n\nConsider the mechanism of a base-catalysed aldol reaction below.\n\nFor this reaction to take place, I need a second carbonyl molecule, but the $$\\ce{CO2Me}$$ on the right hand side ring appears untouched, and likewise so does the carbonyl group on the left hand side too.\n\nI tried the reaction a second way (giving the mechanism below) but am unsure if this is correct.\nIs this the correct mechanism?\n\n\u2022 Looks mostly reasonable to me. There\u2019s an alkene missing from your final product though. Also, in the final elimination you\u2019ve drawn an E2 reaction, but OH typically isn\u2019t a good enough leaving group to do this. Can you think of an alternative elimination pathway? \u2013\u00a0PCK Jun 12 at 21:04","date":"2019-11-15 00:06:35","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 0, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 1, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.7934240102767944, \"perplexity\": 1203.3488090846674}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 5, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2019-47\/segments\/1573496668544.32\/warc\/CC-MAIN-20191114232502-20191115020502-00514.warc.gz\"}"}
null
null
Q: sqlite drop table c++ where is the problem with the following code? It's can not DROP my table. When I make this drop from sql browser (on the same databade) - all works fine. int rcc = sqlite3_open_v2(str_sessions_file.c_str(), &db, SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE, NULL ); if ( SQLITE_OK != rcc) { fprintf (stderr, "Can't open database: %s\n", sqlite3_errmsg (db)); sqlite3_close (db); return; } // Drop std::string sql_dropatable = "DROP TABLE IF EXISTS sessions"; if( sqlite3_exec(db, sql_dropatable.c_str(), 0, 0, 0) != SQLITE_OK ) { // or == -- same effect std::cout << "SQLite can't drop sessions table" << std::endl; sqlite3_close (db); //exit (1); return; }
{ "redpajama_set_name": "RedPajamaStackExchange" }
6,258
{"url":"http:\/\/www.eng-tips.com\/viewthread.cfm?qid=415066","text":"INTELLIGENT WORK FORUMS\nFOR ENGINEERING PROFESSIONALS\n\nAre you an\nEngineering professional?\nJoin Eng-Tips Forums!\n\u2022 Talk With Other Members\n\u2022 Be Notified Of Responses\n\u2022 Keyword Search\nFavorite Forums\n\u2022 Automated Signatures\n\u2022 Best Of All, It's Free!\n\n*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.\n\n#### Posting Guidelines\n\nPromoting, selling, recruiting, coursework and thesis posting is forbidden.\n\n# Wind turbine & wind direction\n\n## Wind turbine & wind direction\n\n(OP)\nHow do these types of wind turbines maintain their face into the wind? No vertical stabilizer?\nI've seen a lot of them lately turned away from the wind, just doing nothing. Why no tails?\n\nIt seems that if the wind blew on a 3blade arrangement, it would always want to turn in the direction of the two blade side and it would just swivel off the wind. If it managed to get going, the 2bladed side would change with 1\/2 revolution and then it would want to swivel off to the other side. Do they simply swivel a little bit in one direction, then the other at half rev, then the other at a full rev? Seems like a little bit of a tail would help greatly with that. Surely the wind on the nacelle isn't going to be enough to keep them facing the wind. That doesn't look like much of a tail. Is it enough (at least in most case) to keep them heading into the wind?\n\n### RE: Wind turbine & wind direction\n\nBI,\n\nThese suckers are slewed by a motor and pinion gear arrangement, controlled by a system that determines average local wind direction and speed. Rotors face upstream to avoid the problems with the tower\/mast wake disturbance.\n\nAs for turbines not spinning, see http:\/\/www.greentechmedia.com\/articles\/read\/why-ar...\n\n### RE: Wind turbine & wind direction\n\n(OP)\nI figured it might have directional control.\n\nCurtailment ... if you can't get it through the grid to where it's needed, no point in making it. Isn't a lot of power gen capacity in the US Midwest stranded power?\n\nThe 40% capacity factor for the best wind sites would be really good. I've found that as you increase the area of \"the site\" to an area as large as Spain, the capacity factor drops to 10-20%.\n\n### RE: Wind turbine & wind direction\n\nOne manufacturer [if not most of them?] uses suspended cables as opposed to slip rings to connect the nacelle to the switchgear at the tower's base; there is a monitoring system in place to keep track of how many degrees of slewing \/ nacelle rotations, in which direction, have occurred from \"neutral\" since the latest time the tower began generating, and unless the twist in the cables draws too close to what they can absorb without damage the unit will continue to produce until its next shutdown due to failing wind. Once the tower is idle the restoring system will slew the tower around as many turns as needed to get it back to within 360\u00b0 of \"neutral...\" or something like that; I'm going from memory from when I was given a tour of a ~200 MW wind farm.\n\nCR\n\n\"As iron sharpens iron, so one person sharpens another.\" [Proverbs 27:17, NIV]\n\n### RE: Wind turbine & wind direction\n\n\"Curtailment ... if you can't get it through the grid to where it's needed, no point in making it. Isn't a lot of power gen capacity in the US Midwest stranded power?\"\n\nCapX2020 alleviated a lot of that in the upper Midwest. In my locale, just 45 minutes north of the \"Buffalo Ridge\", this has been a hot topic for many years.\n\nIt is better to have enough ideas for some of them to be wrong, than to be always right by having no ideas at all.\n\n### RE: Wind turbine & wind direction\n\nYes. You are right.\nIn general, the wind turbine \"business\" relies on the manufactoring and construction tax write-offs and government-mandated rebates and government-mandated \"electrical favored buy-in\" rates to even pretend to make a profit.\n\nThe wind turbine average capacity = 0.17 to 0.22. Meaning you have to build 6x to 5x wind turbines to get the rated nominal power output of 1 over a full year's service. But half the time, you are getting no power out at all.\n\n### RE: Wind turbine & wind direction\n\n(OP)\nAlso a very quick way to get your tax credits and total generating capacity numbers up.\n\n### RE: Wind turbine & wind direction\n\nRacookpe1978,\n\nA capacity factor of 17-22% percent is very low. If you go look up the EIA's yearly report on the LOCE (levelized cost of energy), you'll see the total cost of different forms of generation's all said and done cost, including fuel, maintenance, spinning reserves, everything. Wind generation is near competitive or is competitive in some regions against everything with the exclusion of natural gas.\n\n### RE: Wind turbine & wind direction\n\n(OP)\nTotal cost of everything is a start, but what you really need to know is how much money a given installation will make, hence capacity factor is equally important. It is the other half of thee equation.\n\nYes 12% (lowest yearly average over the total area of Spain) to 22% (higher yearly average over the same area) are low numbers, which is why wind turbines can compete with other forms of energy generation ONLY when they are located in areas where the local capacity factor is very high (say 35-40% or more to equal solar PV). Those areas are not as common as one thinks. Most of these already have wind turbines working there. What I have noticed explains that not all wind turbines are located on hilltops where winds are best. That is why, as you increase the area you analyze, the regional capacity factors drop to numbers so low. That is also something that the WTMA doesn't like to talk about. I made a detailed comment on their online magazine a few years ago, giving specific actual examples showing reducing capacity factors as area increases and they promptly removed the whole article.\n\nAnyway, all of that indicates that many wind turbines have been built up on land with poor wind generating characteristics, probably only for the tax credits. Why else would you do it. I certainly would not put one up if I was only expecting to get a max 20% return on my nameplate capacity... during a very windy year. You need a really great hilltop, Cape Cod, or tax credits to make most of them work. Santa Ana winds don't blow anywhere near 40% of the time over a year.\n\n### RE: Wind turbine & wind direction\n\nAnother thing that needs to be taken into account when talking about capacity factors is going rate of electricity. In places like California, the price per a kwh is high, near $0.20. My electric bill in Texas for comparison is$0.11 per kwh. This offers a lot of margin that can be used to offset low capacity factors. A capacity factor in Oklahoma of 30-35% might be equivalent to 20-25% in California in terms of economics. California is a green state with its own mandates but green energy will and can make inroads in expensive markets. Looking at the map, I kind of suspect that the wind energy in Hawaii is economical even with low wind capacity factor due to Hawaii not having the resources or access to cheap generation.\n\n### RE: Wind turbine & wind direction\n\n(OP)\nYes I believe wind is economic there and other remote locations with no oil, because the cost of importing oil to fuel conventional generators adds a few cents per kW, so even a lo cap wind farm can compete. Big problem with wind, and all renewables for that matter, is usually, if you need reliable power and who doesn't, you wind up building the same amount of conventional power plant to back it up, or you will need to add mucho, mucho batteries. Another big cost.\n\n### RE: Wind turbine & wind direction\n\n\"Anyway, all of that indicates that many wind turbines have been built up on land with poor wind generating characteristics, probably only for the tax credits.\"\n\nThat's pretty much exactly what's happening in this area. The wind farm companies are chasing government money, not wind.\n\n#### Red Flag This Post\n\nPlease let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.\n\n#### Red Flag Submitted\n\nThank you for helping keep Eng-Tips Forums free from inappropriate posts.\nThe Eng-Tips staff will check this out and take appropriate action.\n\nClose Box\n\n# Join Eng-Tips\u00ae Today!\n\nJoin your peers on the Internet's largest technical engineering professional community.\nIt's easy to join and it's free.\n\nHere's Why Members Love Eng-Tips Forums:\n\n\u2022 Talk To Other Members\n\u2022 Notification Of Responses To Questions\n\u2022 Favorite Forums One Click Access\n\u2022 Keyword Search Of All Posts, And More...\n\nRegister now while it's still free!","date":"2017-10-17 22:34:22","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.27577972412109375, \"perplexity\": 2659.1762403237867}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2017-43\/segments\/1508187822513.17\/warc\/CC-MAIN-20171017215800-20171017235800-00668.warc.gz\"}"}
null
null
{"url":"http:\/\/pldml.icm.edu.pl\/pldml\/element\/bwmeta1.element.bwnjournal-article-doi-10_4064-ap89-1-1","text":"Pe\u0142notekstowe zasoby PLDML oraz innych baz dziedzinowych s\u0105 ju\u017c dost\u0119pne w nowej Bibliotece Nauki.\nZapraszamy na https:\/\/bibliotekanauki.pl\n\nPL EN\n\nPreferencje\nJ\u0119zyk\nWidoczny [Schowaj] Abstrakt\nLiczba wynik\u00f3w\n\u2022 # Artyku\u0142 - szczeg\u00f3\u0142y\n\n## Annales Polonici Mathematici\n\n2006 | 89 | 1 | 1-12\n\n## On the variational calculus in fibered-fibered manifolds\n\nEN\n\n### Abstrakty\n\nEN\nIn this paper we extend the variational calculus to fibered-fibered manifolds. Fibered-fibered manifolds are surjective fibered submersions \u03c0:Y \u2192 X between fibered manifolds. For natural numbers s \u2265 r \u2264 q with r \u2265 1 we define (r,s,q)th order Lagrangians on fibered-fibered manifolds \u03c0:Y \u2192 X as base-preserving morphisms $\u03bb:J^{r,s,q}Y \u2192\u22c0^{dimX}T*X$. Then similarly to the fibered manifold case we define critical fibered sections of~Y. Setting p=max(q,s) we prove that there exists a canonical \"Euler\" morphism $\ud835\udcd4(\u03bb):J^{r+s,2s,r+p}Y \u2192 \ud835\udce5*Y \u2297 \u22c0^{dimX}T*X$ of \u03bb satisfying a decomposition property similar to the one in the fibered manifold case, and we deduce that critical fibered sections \u03c3 are exactly the solutions of the \"Euler-Lagrange\" equations $\ud835\udcd4(\u03bb)\u2218 j^{r+s,2s,r+p}\u03c3=0$. Next we study the naturality of the \"Euler\" morphism. We prove that any natural operator of the \"Euler\" morphism type is c\ud835\udcd4(\u03bb), c \u2208 \u211d, provided dim X \u2265 2.\n\n1-12\n\nwydano\n2006\n\n### Tw\u00f3rcy\n\nautor\n\u2022 Institute of Mathematics, Jagiellonian University, Reymonta 4, 30-059 Krak\u00f3w, Poland","date":"2022-05-26 18:01:29","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.733626663684845, \"perplexity\": 8098.545161862071}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.3, \"absolute_threshold\": 10, \"end_threshold\": 5, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2022-21\/segments\/1652662619221.81\/warc\/CC-MAIN-20220526162749-20220526192749-00308.warc.gz\"}"}
null
null
\section{Introduction} Young low-mass stars ($<2$~M$_\odot$), aged of 1-15 Myr, that have just emerged from their dust cocoon and are still contracting towards the main sequence are called T~Tauri stars (TTSs). These pre-main sequence (PMS) stars are divided into two classes: the classical T~Tauri stars (cTTSs), still surrounded by an accretion disc and accreting from its inner regions, and the weak-line T~Tauri stars (wTTSs) that are no longer accreting and have exhausted the inner regions of their discs (or the whole disc). These stars are of obvious interest for further constraining theoretical models of star/planet formation, especially considering the role that stellar magnetic fields play at early stages of evolution \citep{bouvier07a}. Magnetospheric accretion/ejection processes at work in cTTSs have been studied with increasing attention since the first detection of magnetic fields in such stars by \cite{johnskrull99}: e.g. AA Tau \citep{bouvier07b}, V2129 Oph \citep{donati07,donati11,alencar12}, DN Tau \citep{donati13}, LkCa 15 \citep{alencar18,donati19}, HQ Tau \citep{pouilly20} or DoAr44 \citep{Bouvier20}. Most of these studies were made possible thanks to the MaPP (Magnetic Protostars and Planets) Large Observing Programme, dedicated to the observation of magnetized PMS stars and their accretion discs, carried out with the ESPaDOnS high-resolution spectropolarimeter on the 3.6~m Canada-France-Hawaii Telescope (CFHT). These studies suggested that the magnetic topologies of cTTSs mainly reflect the internal stellar structure as they do for main-sequence (MS) low-mass stars \citep{donati09,morin10,gregory12}. The MaTYSSE (Magnetic Topologies of Young Stars and the Survival of close-in giant Exoplanets) Large Programme, also carried out mostly with ESPaDOnS at the CFHT, was dedicated to the observation of wTTSs with the aim of investigating how different magnetic fields of wTTSs are from those of cTTSs, and whether/how frequently they host close-in massive planets (hot Jupiters/hJs). A few tens of wTTSs have been studied within MaTYSSE, for example LkCa 4 \citep{donati14}, V830 Tau \citep{donati17}, TAP 26 \citep{yu17}, Par 1379 and Par 2244 \citep{hill17}, V410 Tau \citep{yu19}. In all cases, the large-scale magnetic field of the star was mapped using Zeeman-Doppler Imaging (ZDI), a tomographic technique inspired from medical imaging which proved very efficient at recovering stellar magnetic topologies \citep{semel89,brown91,donatibrown97,donati06}. This technique revealed the wide diversity of magnetic field topologies that can be found on wTTSs. Whereas most wTTSs show the same magnetic trends as those reported for cTTSs, some of them depart from this picture, with, e.g., V410~Tau showing a strong azimuthal field despite being fully convective. MaTYSSE also enabled the detection of hJs around 2 wTTSs \citep{donati17,yu17} through the periodic velocimetric signal they induce in the spectral lines of their host stars. The SPIRou Legacy Survey (SLS) is a new Large Programme allocated on CFHT with SPIRou, the new cryogenic spectropolarimeter/high-precision velocimeter operating at near-infrared wavelengths (0.95-2.55 $\mu$m, \citealt{donati20b}). The SLS includes in particular a work package focusing on cTTSs and wTTSs, with the goal of studying further their magnetic topologies and the potential presence of hJs. Infrared wavelengths are indeed well adapted for measurements of stellar magnetic fields thanks to the enhanced Zeeman effect. The impact of activity (and in particular of surface brightness features) on the shape of line profiles, and thereby on the measured radial velocity, is also expected to be smaller \citep{mahmud11,crockett12}, making it easier to ascertain the presence of potential hJs. In this paper, we report the results about V410 Tau, obtained in the framework of SLS. V410 Tau is a triple star system with the main star V410 Tau A being much brighter than the two other companions \citep{ghez97}. In particular, \cite{ghez97} reported a difference of $\mathord{\sim}$2.5~mag (resp. $\unsim3$~mag) between V410~Tau~A and B (resp. C) in the $K$ band. From the brightness measurements collected by \cite{ghez97} and the colour indexes for young PMS stars derived by \cite{pecaut13}, we also estimated a difference of 3~mag (resp. 5~mag) between V410~Tau~A and B (resp. C) in the $I_{\rm c}$ band. V410~Tau is a young, fully convective wTTS with an age of about 1~Myr hosting a complex magnetic field \citep{skelly10,yu19}. Located at a distance of $129.4\pm0.4$~pc in the Taurus star forming complex, V410~Tau belongs to the youngest substellar region C2-L1495 whose age was recently estimated from GAIA data ($1.34\pm0.19$~Myr, \citealt{krolikowski21}). V410~Tau has an effective temperature $T_{\rm eff}$ and a logarithmic gravity of 4500~K and 3.8 (in cgs units), respectively, for a mass of $1.42\pm0.15$~M$_\odot$\ and a radius of $3.40\pm0.5$~R$_\odot$\ \citep{yu19}. Recent stellar models (e.g. \citealt{baraffe15}) suggest an even younger age (<0.5~Myr, hardly compatible with results from GAIA) and a lower mass ($1.14\pm0.10$~M$_\odot$) as mentioned in \cite{yu19}. All models suggest that V410~Tau is a fully-convective star. \cite{yu19} performed a thorough spectropolarimetric analysis of V410 Tau based on optical data collected between 2008 and 2016. This study revealed in particular that the brightness distribution and the large-scale magnetic topology at the surface of the star evolve with a timescale of months (160 to 600~d) but also that the surface is sheared by a weak level of differential rotation ($9.7\pm0.3~\rm mrad\ d^{-1}$). The magnetic field of V410~Tau exhibits a strong toroidal component whose contribution to the overall magnetic energy decreased from $\unsim50\%$ in 2008 to $\unsim30\%$ in 2016. In addition, the strength of the dipole followed the opposite trend, increasing from $\unsim130$~G to $\unsim400$~G. Although their data were spread over several years, they were not able to identify a clear magnetic cycle but only a lower limit (of $\simeq$8~yr) for its duration (if a cycle is indeed present). The study of radial velocities coupled to stellar surface imaging revealed that no planet more massive than 1~M$_{\rm jup}$ orbits the host star within a distance of 0.09~au. V410~Tau has been monitored both with SPIRou from 2019 October 31 to December 13, and with the Transiting Exoplanet Survey Satellite (TESS) from 2019 November 28 to December 23 during its monitoring of sector 19. Additional contemporaneous ground-based photometric data were also collected at the Crimean Astrophysical Observatory (CrAO) over the same observing season. We start this paper with the description (in Section \ref{sec:sec2}) of both spectropolarimetric and photometric observations collected for our study. In Section \ref{sec:sec3}, we report our investigations about the surface brightness and the large-scale magnetic field with ZDI. In Section \ref{sec:sec4} we investigate the stellar activity both with radial velocity (RV) measurements and activity indicators (based on the \ion{He}{i} triplet at 1083.3~nm and the Paschen $\beta$ and Brackett $\gamma$ lines). Finally, we summarize and discuss our main results in Section \ref{sec:sec5}. \section{Observations} \label{sec:sec2} \subsection{SPIRou observations} \label{sec:sec2.1} We performed spectropolarimetric observations with SPIRou between 2019 October 31 and 2019 December 13 (UTC). SPIRou works in the near-infrared (NIR) domain between 950~nm and 2500~nm with a spectral resolving power of $\mathord{\sim}$70 000 \citep{donati20b}. Each polarimetric observation is composed of a sequence of 4 subexposures of 300 seconds each taken with different configurations of the polarimeter (i.e., different azimuths of the polarimeter retarders) in order to get rid of potential spurious signals in the polarisation and systematic errors at first order \citep{donati97}. Twenty sequences were collected, yielding spectra in both unpolarized (Stokes~$I$) and circularly polarized (Stokes $V$) light. Data reduction was performed with a pipeline based on the ESPaDOnS pipeline Libre-ESpRIT \citep{donati97} adapted for SPIRou observations. We then obtained telluric-corrected spectra using a PCA approach as mentionned by \cite{artigau14}. The signal-to-noise ratio (SNR) per pixel of these spectra peaks in the $H$ band with a median value of 179 (ranging from 140 to 200). We applied Least-Square Deconvolution (LSD; \citealt{donati97}) on all spectra in order to add up information from all lines. We only used 18 out of the 20 recorded spectra, the two remaining ones (collected on 2019 Nov 10 and Dec 13) being either much noiser than the average or suffering from a technical issue. Three series of LSD profiles were computed with three different masks generated with the VALD-3 database \citep{vald} and including lines ranging from 950 to 2600~nm. The first one (hereafter M1) contains $\mathord{\sim}$10~000 atomic and molecular lines. It yields Stokes~$I$ LSD profiles only, as the magnetic sensitivity (i.e. Landé factor) of many molecular lines is unknown, with SNRs ranging from 1890 to 3060 (median of 2770). The second mask (hereafter M2) contains $\unsim2000$ atomic lines with known Landé factors and relative depths with respect to the continuum >10\%. It yields Stokes~$I$ LSD profiles with SNRs ranging from 1270 ro 1930 (median of 1740) and Stokes~$V$ LSD profiles with SNRs ranging from 3380 to 4950 (median of 4440). The last mask (M3 hereafter), containing $\unsim900$ molecular lines with a depth relative to the continuum down to 5\%, yields Stokes~$I$ LSD profiles with SNRs ranging from 600 to 1020 (median of 835). To phase our observations on the rotation cycle of the star, we used the same reference date as in \cite{skelly10} and \cite{yu19}, namely the Barycentric Julian Date BJD$_0$=2,454,832.58033, along with the well defined stellar rotation period obtained by \cite{stelzer03}: $P_{\mathrm{rot}}~=~1.871970~\pm~0.000010$~d. Despite the very well constrained rotation period, the reconstructed maps presented in Sec.~\ref{sec:sec3} cannot be directly compared to the previously published ones, as the brightness and magnetic surface maps of V410~Tau evolved since then as a result of both differential rotation and intrinsic variability. A summary of our observations is given in Table \ref{table1}. Since our data are spread over 23 rotation cycles only (i.e. 43~d), we do not expect major changes in the surface brightness map nor in the large-scale magnetic topology of V410~Tau, given the typical timescale on which both quantities are found to evolve, either as a result of intrinsic variability or differential rotation \citep{yu19}. \addtolength{\tabcolsep}{6pt} \begin{table*} \caption{Spectropolarimetric observations of V410~Tau obtained with SPIRou between 2019 October and December. Each observation is composed of a sequence of four 300~s-subexposures. The 1$^{\rm st}$ to the 4$^{\rm th}$ columns give the date, the Coordinated Universal Time, the Barycentric Julian Date and the rotation cycle (computed as indicated in Sec.~\ref{sec:sec2.1}). Columns 5 to 9 list the SNRs of the spectra in the $H$ band, in the Stokes~$I$ LSD profiles provided by masks M1, M2 and M3 and in the Stokes~$V$ LSD profiles obtained with mask M2. From column 10 to 14, we detail the measured RV, the longitudinal magnetic field, and the activity indicators (see Sec.~\ref{sec:activity_index}) based on the \ion{He}{i} triplet at 1083.3~nm, Paschen $\beta$ and Brackett $\gamma$ lines, along with their error bars estimated from photon noise only (or taking into account intrinsic variability as well for the number in parenthesis, see Sec.~\ref{sec:activity_index}).} \label{table1} \centering \resizebox{\textwidth}{!}{ \begin{threeparttable} \begin{tabular}{lccccccccccccc} \\ \hline \hline \multicolumn{1}{c}{Date} & UTC & BJD & Cycle & SNR & \multicolumn{3}{c}{SNR$_I$} & SNR$_V$ & RV & B$_l$ & \multicolumn{3}{c}{Activity proxies}\\[1mm] \multicolumn{1}{c}{} & & & & & (M1) & (M2) & (M3) & (M2) & & & \ion{He}{i} & Pa$\beta$ & Br$\gamma$ \\ \multicolumn{1}{c}{2019} & & 2458700+ & 2112+ & & & & & & ($\mathrm{km}\,\mathrm{s}^{-1}$) & (G) & (nm) & (nm) & (nm) \\ \hline Oct 31 & 12:07:55 & 88.012 & 0.978 & 179 & 1890 & 1270 & 600 & 4950 & -1.923 $\pm$ 0.273 & $-182\pm29$ & $0.129\pm0.002$ (0.025) & $0.009\pm0.001$ (0.003) & $-0.003\pm0.004$ (0.006) \\ Nov 01 & 12:16:25 & 89.018 & 1.516 & 193 & 2070 & 1380 & 600 & 4460 & 0.901 $\pm$ 0.258 & $-195\pm32$ & $-0.152\pm0.002$ (0.025) & $-0.005\pm0.001$ (0.003) & $-0.009\pm0.004$ (0.006) \\ Nov 03 & 10:43:17 & 90.954 & 2.550 & 202 & 2890 & 1820 & 890 & 4870 & 1.149 $\pm$ 0.177 & $-224\pm29$ & $-0.202\pm0.002$ (0.025) & $-0.007\pm0.001$ (0.003) & $-0.008\pm0.004$ (0.006)\\ Nov 04 & 14:01:42 & 92.092 & 3.157 & 185 & 2570 & 1680 & 710 &4440 & -1.589 $\pm$ 0.202 & $-83\pm32$ & $0.113\pm0.002$ (0.025) & $-0.002\pm0.001$ (0.003) & $-0.000\pm0.004$ (0.006)\\ Nov 05 & 11:23:26 & 92.981 & 3.633 & 197 & 2880 & 1830 & 870 & 4700 & 2.292 $\pm$ 0.175 & $-198\pm30$ & $-0.008\pm0.002$ (0.025) & $-0.001\pm0.001$ (0.003) & $-0.005\pm0.004$ (0.006)\\ Nov 07 & 10:53:20 & 94.961 & 4.690 & 171 & 2760 & 1730 & 760 & 3870 & 2.553 $\pm$ 0.179 & $-252\pm37$ & $0.070\pm0.002$ (0.025) & $0.005\pm0.001$ (0.003) & $0.007\pm0.004$ (0.006) \\ Nov 08 & 12:48:55 & 96.041 & 5.267 & 187 & 3050 & 1930 & 860& 4400 & -0.302 $\pm$ 0.175 & $-15\pm32$ & $0.096\pm0.002$ (0.025) & $-0.006\pm0.001$ (0.003) & $-0.004\pm0.004$ (0.006) \\ Nov 09 & 10:01:53 & 96.925 & 5.739 & 176 & 2070 & 1400 & 660& 4560 & 2.349 $\pm$ 0.245 & $-148\pm31$ & $-0.014\pm0.002$ (0.025) & $0.006\pm0.001$ (0.003) & $0.009\pm0.004$ (0.006)\\ Nov 10$^{(a)}$ & 11:34:51 & 97.988 & 6.305 & 143 & - & - & -& - & - & - & - & - & -\\ Nov 11 & 11:19:14 & 98.979 & 6.837 & 197 & 2660 & 1680 & 810 &4370 & 0.294 $\pm$ 0.193 & $-91\pm33$ & $-0.011\pm0.002$ (0.025) & $0.005\pm0.001$ (0.003) & $-0.003\pm0.004$ (0.006)\\ Nov 13 & 09:37:13 & 100.908 & 7.867 & 179 & 2720 & 1720 & 820 & 3950 & -0.128 $\pm$ 0.192 & $-142\pm36$ & $0.015\pm0.002$ (0.025) & $0.005\pm0.001$ (0.003) & $0.000\pm0.004$ (0.006)\\ Nov 14 & 10:00:42 & 101.924 & 8.410 & 172 & 2710 & 1720 & 850 & 4210 & 0.627 $\pm$ 0.197 & $-115\pm34$ & $-0.075\pm0.002$ (0.025) & $-0.001\pm0.001$ (0.003) & $0.004\pm0.004$ (0.006) \\ Dec 05 & 09:34:52 & 122.906 & 19.619 & 155 & 2780 & 1760 & 760 & 3580 & 2.127 $\pm$ 0.182 & $-223\pm40$ & $-0.057\pm0.002$ (0.025) & $0.002\pm0.001$ (0.003) & $-0.004\pm0.004$ (0.006) \\ Dec 07 & 10:50:36 & 124.960 & 20.715 & 150 & 2320 & 1550 & 690 & 3380 & 2.767 $\pm$ 0.213 & $-211\pm42$ & $0.028\pm0.002$ (0.025) & $0.002\pm0.001$ (0.003) & $0.005\pm0.004$ (0.006) \\ Dec 08 & 09:11:20 & 125.890 & 21.213 & 175 & 2940 & 1870 & 930 & 4120 & -1.043 $\pm$ 0.179 & $-33\pm35$ & $0.099\pm0.002$ (0.025) & $0.003\pm0.001$ (0.003) & $0.002\pm0.004$ (0.006)\\ Dec 09$^{(b)}$ & 09:25:30 & 126.900 & 21.752 & 191 & 3000 & 1900 & 1020 &4570 & 1.851 $\pm$ 0.171 & $-131\pm31$& - & - & -\\ Dec 10 & 08:16:38 & 127.852 & 22.261 & 186 & 3060 & 1910 & 1020 &4750 & -0.423 $\pm$ 0.165 & $47\pm30$ & $0.114\pm0.002$ & $0.014\pm0.001$ & $0.012\pm0.004$\\ Dec 11 & 11:06:22 & 128.970 & 22.858 & 197 & 2870 & 1800 & 970 & 4620 & 0.060 $\pm$ 0.180 & $-87\pm31$ & $0.172\pm0.002$ & $0.026\pm0.001$ & $0.009\pm0.004$\\ Dec 12 & 09:25:49 & 129.900 & 23.355 & 176 & 2920 & 1830 & 910 & 4440 & 0.377 $\pm$ 0.177 & $23\pm32$ & $-0.045\pm0.002$ (0.025) & $-0.006\pm0.001$ (0.003) & $0.012\pm0.004$ (0.006)\\ Dec 13$^{(a)}$ & 09:32:01 & 130.904 & 23.891 & 166 & - & - & - & - & - & - & - & - & - \\ \hline \end{tabular} \begin{tablenotes} \item $^{(a)}$ Removed from the analysis (see Sec.~\ref{sec:sec2.1}) \item $^{(b)}$ Removed from the activity indicators due to a flare (see Sec.~\ref{sec:activity_index}) \end{tablenotes} \end{threeparttable} } \end{table*} \addtolength{\tabcolsep}{-6pt} \subsection{TESS observations} \label{sec:sec2.2} Contemporaneously with SPIRou observations, V410~Tau (TIC 58231482) was observed by TESS \citep{ricker14} from 2019 November 28 to 2019 December 23 during its monitoring of sector 19. TESS being mostly sensitive to wavelengths in the range 600 to 1000~nm (centred on the Cousins $I_{\rm c}$ photometric band), it thus probes a different surface brightness distribution than that observed with SPIRou. The target was observed with a cadence of 2 min over a total time span of 25~d. These observations have been re-processed by the Science Processing Operations Center (SPOC; \citealt{jenkins16}) data pipeline (version 4.0), with light curves available from the Mikulski Archive for Space Telescopes (MAST)\footnote{\url{https://archive.stsci.edu/missions-and-data/tess}}. In particular, we used the Pre-search Data Conditioning Single Aperture Photometry (PDCSAP) flux that provides a better estimate of the intrinsic variability of the star since instrumental variations have been corrected in this light curve, as well as contamination from some nearby stars \citep{smith12,stumpe12,stumpe14}. We only kept the data that were not flagged from the SPOC pipeline, thus those with no known problems. We also rejected the observations carried out between BJD 2,458,826.5 and 2,458,827.8, for which a high background level from the Earth led to spurious photometric variations\footnote{Details can be found in the Data Release notes of sector 19 (DR26 and DR30) available at \url{https://archive.stsci.edu/tess/tess_drn.html}} (see Fig. \ref{fig:Lc_tess}). \begin{figure} \centering \includegraphics[scale=0.19]{TESS_LC.png} \caption{TESS Pre-search Data Conditioning Single Aperture Photometry. The black dots are the ones used in the study, while the red ones have been flagged by the SPOC pipeline or rejected because of the high background level or filtered by a 3$\sigma$-clipping process (see Sec. \ref{sec:sec2.2}) and have thus not been taken into account in this work. The dashed vertical lines depict SPIRou observations contemporary with the TESS monitoring (additional SPIRou observations were collected before). The orange star flags the observation affected by a flare (see Sec.~\ref{sec:activity_index}).} \label{fig:Lc_tess} \end{figure} Since TESS is sensitive to small flux variations caused by flares, we first filtered them through a $3\sigma$-clipping process, which also allowed us to mitigate the potential effects of activity from stellar companions (V410~Tau~B and C) on the photometry. This process consisted in an iterative fit of the light curve with a Gaussian Process Regression (GPR; \citealt{rasmussen06}). At each iteration, we rejected the points having a residual larger than 3$\sigma$ until all the residuals were lower than this threshold. As we expected that the variations in the light curve are mainly due to stellar activity, we chose a quasi-periodic kernel to model the TESS light curve, which is well adapted to model signals induced by active regions rotating with the stellar disk \citep{haywood14}:% \begin{equation} k(t_i,t_j) = \theta_1^2 \exp\left[-\frac{(t_i-t_j)^2}{\theta_2^2} - \frac{\sin^2\frac{\pi(t_i-t_j)}{\theta_3}}{\theta_4^2}\right], \label{eq1} \end{equation} where $t_i, t_j$ are the times associated to the observations $i$ and $j$, respectively. $\theta_1$ is the amplitude of the Gaussian Process (GP), $\theta_2$ is the decay timescale (i.e. the exponential timescale on which the modeled photometry departs from pure periodicity) or equivalently typical spots lifetime, $\theta_3$ is the period of the GP (expected to be close to $P_{\mathrm{rot}}$) and $\theta_4$ is the smoothing parameter that controls the amount of short-term variations that the fit can include (within a rotation cycle). For our purpose, we imposed a large decay timescale $\theta_2 = 300$ d to avoid the GP to fit rapidly evolving patterns. The resulting light curve is shown in Fig \ref{fig:Lc_tess}. We then modelled this filtered light curve with the same GPR but letting all 4 parameters free in order to derive an estimate of the typical timescale on which the main surface features evolve (found to be equal to $162^{+30}_{-25}$~d). This value is lower than that obtained by \cite{yu19} from ground-based $V$ measurements ($314^{+31}_{-29}$~d) most likely because TESS photometry is much more accurate and sensitive to small structures evolving rapidly. We also found $\theta_3 = 1.873\pm0.001$~d, consistent with the rotation period obtained by \cite{stelzer03} and the smoothing parameter $\theta_4=1.02\pm0.06$. Considering only the data obtained before the end of SPIRou observations (2019 December 12), we computed median time and relative photometry every ten points, resulting in 757 photometric values, in order to get a smoother curve, to reduce computational time and to balance the relative weights of photometry and spectroscopy when applying ZDI (see Sec.~\ref{sec:brightness}). Despite the very-high-precision photometry provided by TESS, no periodic signal beyond that due to V410~Tau~A is detected in the light curve, which indicate that the temporal variations are attributable to the main star. In addition, the amplitude ratio between the peaks associated with component A and the noise in the TESS light curve periodogram (equal to $\unsim32$) provides an independant confirmation that the magnitude contrasts with the two other components in the $I_{\rm c}$ band is about 4 or more, in agreement with \cite{ghez97}. \subsection{Additional photometric observations} \label{sec:sec2.3} Multicolour photometry of V410~Tau was collected with the ground-based 1.25~m AZT-11 telescope at the CrAO from 2019 September 02 to December 18. Using a ProLine PL23042 CCD camera, 40 brightness measurements were collected in the $V$, $R_{\rm c}$ and $I_{\rm c}$ bands. For these estimates, the wTTS V1023~Tau was used as a comparison star as this star shows small variability amplitude. We note that V410~Tau has an average magnitude in the $V$ band equal to 10.85~mag (see Fig.~\ref{fig:compare_photometry}), thus consistent with observations of this star at previous epochs \citep{grankin08}. A full log of the CrAO photometric observations is given in Table~\ref{tab:log_crao}. We fitted the light curves in the $V$, $R_{\rm c}$ and $I_{\rm c}$ bands separately, using a periodic fit including the fundamental frequency and the first two harmonics. As the formal uncertainties on the measured magnitudes (7~mmag for $V$ and $R_{\rm c}$, 5~mmag for $I_{\rm c}$) are underestimated, missing some sources of noise like the intrinsic variability of the observed star, we derived empirical estimates of these error bars by scaling them up to the values that ensure a unit reduced chi square for the fit in each band (using a sine wave plus 2 harmonics, see Fig.~\ref{fig:compare_photometry}). We find these empirical error bars to be equal to $20$, $14$, and $13$~mmag for $V$, $R_{\rm c}$ and $I_{\rm c}$, respectively. The models for $V-R_{\rm c}$ and $V-I_{\rm c}$ were then obtained by subtracting the models for the associated magnitudes while the error bars on these colours were estimated by propagating the uncertainties (Fig.~\ref{fig:compare_photometry}). As expected we find that the light curve amplitude decreases with wavelength: $0.231\pm0.012$~mag in the $V$ band, $0.212\pm0.008$~mag in the $R_{\rm c}$ band and $0.174\pm0.008$~mag in the $I_{\rm c}$ band (with the error bars on the amplitudes derived from the empirical uncertainties on the measured magnitudes). As expected, TESS photometry (amplitude of $0.17656\pm0.0009$~mag) is consistent with that obtained from the ground in the $I_{\rm c}$ band. As all light curves are more or less consistent in shape, we will only use TESS data in the following as they are much more accurate than ground-based photometry. \begin{figure} \centering \hspace*{-.4cm} \includegraphics[scale=0.32,trim={0.5cm 1.8cm 3cm 3cm},clip]{Compare_photometry_colours.png} \caption{Ground-based photometric data in the $V$, $R_{\rm c}$ and $I_{\rm c}$ bands showing an empirical uncertainty of 20, 14 and 13 mmag, respectively (first to third panels), and $V-R_{\rm c}$ and $V-I_{\rm c}$ colour indexes (fourth and fifth panels). The cyan error bars correspond to the formal measurement uncertainties while the black error bars are the scaled-up empirical uncertainties (slightly shifted along the horizontal axis for display purposes). The red curves correspond to periodic fits to the $V$, $R_{\rm c}$ and $I_{\rm c}$ magnitudes including the fundamental frequency and the first two harmonics (three first panels). The red curves plotted on $V-R_{\rm c}$ and $V-I_{\rm c}$ were derived by subtracting the previous models. The light curve shows an amplitude of $0.231$~mag in the $V$ band, $0.212$~mag in the $R_{\rm c}$ band and $0.174$~mag in the $I_{\rm c}$ band. All light curves are phased with the same ephemeris as that used for SPIRou data (see Sec.~\ref{sec:sec2.1}).} \label{fig:compare_photometry} \end{figure} \section{Stellar tomography} \label{sec:sec3} \subsection{Zeeman-Doppler Imaging} \label{sec:sec3.1} \begin{table*} \caption{In this table we recall the data that were used to derive each of the main type of results outlined in this paper.} \label{table:summary_ZDI} \begin{tabular}{cccc} \\ \hline \multicolumn{1}{c}{SPIRou Stokes~$I$} & \multicolumn{1}{c}{SPIRou Stokes~$I$ + TESS} & \multicolumn{1}{c}{SPIRou Stokes~$I$ + $V$} & \multicolumn{1}{c}{SPIRou Stokes~$I$} \\ \multicolumn{1}{c}{(M1: $\mathord{\sim}$10 000 atomic + molecular lines)} & \multicolumn{1}{c}{(M1: $\mathord{\sim}$10 000 atomic + molecular lines)} & \multicolumn{1}{c}{(M2: $\mathord{\sim}$2000 atomic lines)} & \multicolumn{1}{c}{(M3: $\mathord{\sim}$900 molecular lines)} \\ \hline Brightness map & Brightness map & Brightness \& magnetic field maps & Brightness map \\ Differential Rotation (Stokes~$I$ only) & - & Differential Rotation (Stokes~$V$ only) & - \\ Radial velocities & Radial Velocities & Longitudinal field & - \\ \hline \end{tabular} \end{table*} To recover maps of the surface brightness and/or of the magnetic field topology of the star, we applied ZDI \citep{semel89,brown91,donatibrown97,donati06} on our time series of Stokes~$I$ and/or Stokes $V$\footnote{Stokes $V$ profiles are obviously different from $V$ magnitudes despite sharing similar notations. As there is no real ambiguities between the 2 quantities, we kept the notations unchanged.} LSD profiles. ZDI aims at constraining surface (brightness or magnetic) maps of rotating stars from time series of (Stokes $I$ and $V$) LSD profiles collected as the star rotates. To achieve this we proceed as follows. ZDI uses a conjugate gradient algorithm to deduce iteratively, from an initially non-spotted (resp. non-magnetic) distribution, the maps of relative brightness with respect to the quiet photosphere at SPIRou wavelengths (resp. of the magnetic field vector) at the surface of the star, until the corresponding synthetic LSD profiles fit the observed ones down to a unit reduced chi-square ($\chi^2_r$). This allows to look for the maximum-entropy solution of this optimization problem, i.e. the map containing the smallest amount of information capable of fitting the data down to the noise level. In a second step, we applied ZDI to both SPIRou and TESS data simultaneously. We proceeded as in \cite{yu19} but this time including photometric data as part of the fit (instead of simply comparing the light curve predicted by ZDI with photometric observations). This is achieved by deriving, as part of the iterative imaging process and using Planck's law, the brightness contrast in the TESS bandpass that we expect from the one in the SPIRou bandpass (which we reconstruct through ZDI). In practice, we divide the surface of the star into a grid of a few thousand cells; to estimate the spectral contribution of each cell to the measured Stokes~$I$ and $V$ LSD profiles, we use Unno-Rachkovsky's analytical solution to the polarized radiative transfer equations in a Milne-Eddington atmosphere (see e.g. \citealt{landi04}) with appropriate values for relevant parameters such as the limb-darkening coefficient known to strongly depend on wavelength ($0.3\pm0.1$ in the $H$ band for $T_{\rm eff}=4500$~K and $\log g = 4$; \citealt{claret11}). The synthetic Stokes~$I$ (resp. Stokes~$V$) LSD profiles are then computed by integrating all the local Stokes~$I$ (resp. Stokes~$V$) LSD profiles over the visible stellar hemisphere, while the photometric values are computed by summing up the value of the continuum over all grid cells. The poloidal and toroidal components of the magnetic field are decomposed into spherical harmonics \citep{donati06} while the photospheric relative brightness is computed independently for each cell of the grid. In a first approach, we will assume that the star rotates as a solid body. We will then take into account differential rotation at the surface of V410~Tau in Sec.~\ref{sub:differential_rotation}. In order to fit our LSD profiles, we chose a line model with mean wavelength, Doppler width and Landé factor of 1650~nm, 1.8~$\mathrm{km}\,\mathrm{s}^{-1}$\ and 1.2, respectively. As the depth of the LSD profiles varies depending on the mask and as we kept constant the Doppler width, our line models features an equivalent width (EW) of 1.5~$\mathrm{km}\,\mathrm{s}^{-1}$, 1.9~$\mathrm{km}\,\mathrm{s}^{-1}$\ and 1.4~$\mathrm{km}\,\mathrm{s}^{-1}$\ for the M1, M2 and M3 masks, respectively. Using ZDI on our Stokes~$I$ LSD profiles obtained from SPIRou data, we found $v\sin{i}~=~72.8~\pm~0.5$~ $\mathrm{km}\,\mathrm{s}^{-1}$\ for the line-of-sight-projected equatorial rotation velocity and $i=45\pm10^{\circ}$ for the inclination of the rotation axis to the line of sight. These values being consistent with those of \cite{yu19} within the error bars, we decided to follow \cite{yu19} and set $v\sin{i}=~73.2$ $\mathrm{km}\,\mathrm{s}^{-1}$\ and $i=50^{\circ}$. Using ZDI, we found that the bulk RV of the star is equal to $17.4\pm0.3$~$\mathrm{km}\,\mathrm{s}^{-1}$\ when considering M1, $18.1\pm0.3$~$\mathrm{km}\,\mathrm{s}^{-1}$\ when considering M2 and $16.0 \pm 0.6$ when considering M3. Although these values remain compatible within 3$\sigma$, we suspect that these differences may partly come from inaccuracies in the empirical mask line wavelengths, known to be less reliable for molecules than for atoms. It may also reflect a systematic RV blueshift of molecular lines with respect to atomic lines, that would suggest that atomic lines are more affected than molecular lines by the inhibition of convective blueshift by stellar magnetic activity for a reason yet to be clarified. Finally, as in \cite{yu19}, we set the maximum number of spherical harmonics to $\ell=15$ to describe the large-scale magnetic topology. A summary of the information provided by our ZDI analyses with the three different masks is provided in Table~\ref{table:summary_ZDI}. \subsection{Brightness mapping} \label{sec:brightness} We focused on the Stokes~$I$ LSD profiles obtained with M1 to deduce the surface brightness map of the star. We performed two analyses, one with SPIRou data only and one considering simultaneously SPIRou and TESS data. For the first analysis, we just applied ZDI on our time series of Stokes~$I$ LSD profiles that we fitted down to $\chi^2_r=1$ (see Fig.~\ref{fig:LSD_profiles_I}). The reconstructed surface brightness distribution is shown in the left panel of Fig. \ref{fig2}. We note the presence of large features, such as dark spots at phase 0.70 or 0.85, along with smaller ones. However, rather surprisingly, no polar spot is visible in this map from SPIRou data, whereas previous maps from optical data always showed conspicuous dark features covering the polar regions (e.g. \citealt{joncour94,hatzes95,yu19}). \begin{figure} \centering \hspace*{-1cm} \includegraphics[scale=0.12]{v410_stokesI.png} \caption{Stokes~$I$ LSD profiles obtained with the M1 mask (see Sec.~\ref{sec:sec2.1}). The observed profiles are shown in black while ZDI model (using SPIRou data only) is plotted in red. The rotation cycle associated with each profile is also mentioned on the right of each profile. Including the TESS data in ZDI does not lead to significant differences in the synthetic profiles.} \label{fig:LSD_profiles_I} \end{figure} \begin{figure} \centering \includegraphics[scale=0.08]{compare_spirou_tess.png} \caption{ZDI maps of the logarithmic relative surface brightness reconstructed from SPIRou data only (left) and from both SPIRou and TESS data (right). The maps are shown in a flattened polar view with the pole at the center, the equator represented as a bold black line and the 60$^\circ$ and 30$^\circ$ latitude parallels shown as dashed lines. The ticks around the star correspond to the phases of spectropolarimetric observations collected with SPIRou. Dark cool spots appear in yellow/red while the bright plages show up in blue.} \label{fig2} \end{figure} \begin{figure} \centering \includegraphics[scale=0.26]{Fit_TESS_ZDI.png} \caption{ZDI fit of the TESS light curve. \textit{Top panel:} the 757 relative photometry values from the TESS light curve are represented by the black dots (see Sec.~\ref{sec:sec2.2}). The fit of these points with ZDI is shown in solid red line. \textit{Bottom panel:} residuals exhibiting a dispersion of 1.6~mmag.} \label{fig:fit_tess} \end{figure} \begin{figure} \centering \includegraphics[scale=0.08]{v410_mapQ_mol.png} \caption{Logaritmic relative surface brightness map obtained with ZDI by reconstructing the brightness with a mask containing only molecular lines. The star is shown in a flattened polar projection as in Fig. \ref{fig2}.} \label{fig:mapQ_mol} \end{figure} \begin{figure} \centering \includegraphics[scale=0.08]{maps_2013.png} \caption{Logaritmic relative surface brightness maps obtained from 2013 optical data both in its original version (left panel, from \citealt{yu19}) and after rescaling to SPIRou wavelengths using Planck's law (right panel). The star is shown in a flattened polar view as in Fig. \ref{fig2}.} \label{fig:compare_2013_2019} \end{figure} \begin{figure} \centering \hspace*{-0.5cm} \includegraphics[scale=0.19]{Comparison_2013_2019.png} \caption{Histograms of contrasts for the maps shown in Fig. \ref{fig2} and \ref{fig:compare_2013_2019}. The blue distribution corresponds to the map obtained by \citet{yu19} with 2013 optical NARVAL data. The orange one corresponds to the 2013 optical map rescaled to SPIRou wavelengths using Planck's law, while the green one shows the distribution associated with the map obtained directly from our 2019 SPIRou data.} \label{fig:histograms} \end{figure} For our brightness reconstruction using both SPIRou and TESS data, we provided ZDI with the 757 photometric values (with error bars set to 1.6~mmag per data point) from the TESS light curve before 2019 December 12 (see Sec.~\ref{sec:sec2.2}) in addition to the Stokes~$I$ LSD profiles. This yielded the reconstructed map and the fitted light curve shown in the right panel of Fig.~\ref{fig2} and in Fig.~\ref{fig:fit_tess}, respectively. Both spectroscopic and photometric data were fitted down to $\chi^2_r=~1$, with the fit of Stokes~$I$ profiles being almost identical to that obtained using SPIRou data only. We find that including photometry in addition to SPIRou data yields brightness maps with enhanced contrasts, especially at low latitudes, that were needed to fit the light curve at a RMS level of 1.6~mmag. When fitting Stokes~$I$ profiles only, the spot coverage is close to 8.4\% while it increased to 10.7\% when TESS data were taken into account.This 2.3\% increase is significant, firstly because this difference is larger than the typical error we can expect on this parameter (of order 0.4\% in the context of this particular data set), and secondly since maximum entropy is profiled to provide the image containing the smallest amount of information. We come back on the origin of this difference in Sec.~\ref{sec:5.1}. We note that, in the fitted light curve, the residuals still exhibit correlated noise (at a level of 1.6~mmag RMS) that does not repeat from one rotation cycle to the next, and that likely reflects small-scale structures at the surface that evolve with time. (This explains a posteriori why the error bar on the TESS data points was set to this value). As no polar spot is visible whether we take into account the TESS data or not, we reconstructed the brightness distribution from Stokes~$I$ LSD profiles using the M3 mask, expected to be more sensitive to cooler regions (Fig.~\ref{fig:mapQ_mol} and \ref{fig:StokesI_M3}). Once again, the reconstructed map does not show a polar spot but displays some low-level differences with the map reconstructed with the M1 mask, e.g., the cool spot at phase 0.70 (see Fig~\ref{fig:mapQ_mol}). Obviously, we do expect the brightness distribution to evolve over timescales of several years. However, we expect histograms of brightness contrasts to remain more or less the same in a given spectral range. In this context we can compare maps from NIR and optical data by rescaling, with Planck's law, brightness maps reconstructed from optical data (see left panel of Fig.~\ref{fig:compare_2013_2019} in the particular case of epoch 2013 December; from \citealt{yu19}) to the image one would have reconstructed in the NIR (right panel of Fig.~\ref{fig:compare_2013_2019}). We find that, as expected, the NIR map is less contrasted than the original optical map. Moreover, the histogram of rescaled optical data is comparable with that directly obtained from SPIRou data (Fig.~\ref{fig:histograms}). \subsection{Magnetic analysis} \label{sec:magnetic} To reconstruct the large-scale magnetic topology, we focused on LSD profiles provided by mask M2, as it contains only lines with well known magnetic sensitivity. \begin{figure} \centering \hspace*{-0.5cm} \includegraphics[scale=0.12]{stokesI_QB.png} \hspace*{0.5cm} \includegraphics[scale=0.12]{stokesV_QB.png} \caption{Stokes~$I$ (left) and Stokes~$V$ (right) LSD profiles obtained with a mask containing only atomic lines with well known Landé factors. The observed profiles are plotted in black while the ZDI fit is shown in red. The rotation cycle is mentioned on the right of each profile. 3$\sigma$ error bars are displayed on the left of each Stokes~$V$ profile. } \label{fig:LSD_profiles_IV} \end{figure} \begin{figure*} \centering \includegraphics[scale=0.7]{v410_maps_QB.pdf} \caption{ZDI maps of the logarithmic relative surface brightness (1$^{\rm st}$ panel), and of the radial, azimuthal and meridional magnetic field components (2$^{\rm nd}$ to 4$^{\rm th}$ panels) obtained from a simultaneous fit of Stokes~$I$ and Stokes~$V$ LSD profiles. The description of the brightness map is as in Fig.~\ref{fig2}. For the magnetic field maps, red indicates positive radial, azimuthal and meridional fields that point outwards, counterclockwise and polewards, respectively. The star is shown in a flattened polar projection as in Fig. \ref{fig2}.} \label{fig:maps_Iv} \end{figure*} \begin{figure} \centering \hspace*{-0.5cm} \includegraphics[scale=0.27]{Bl_sinus_final.png} \caption{Phase folded longitudinal field $B_\ell$. \textit{Top panel:} Observed values are represented by coloured dots, each color representing a different cycle. The black curve corresponds to the fit of our data with a sine curve with one harmonic. \textit{Bottom panel:} Residuals between the raw $B_\ell$ and the model, showing a dispersion of about 30~G. } \label{fig:bl} \end{figure} We fitted simultaneously Stokes~$I$ and Stokes~$V$ LSD profiles with ZDI. Once again, we achieved a fit of the data down to $\chi^2_r =1$. The profiles and the associated maps are shown in Fig. \ref{fig:LSD_profiles_IV} and \ref{fig:maps_Iv}, respectively. We found a map of the logarithmic surface brightness similar to those reconstructed with mask M1 (with and without the TESS data). We see that the magnetic field is complex, with a topology similar to those derived by \cite{yu19}. We note that the magnetic field average strength is close to 410~G. The poloidal component of the field, which encloses about 60\% of the overall reconstructed magnetic energy, is essentially non-axisymmetric ($\unsim50\%$) and weakly dipolar ($\unsim35\%$) while the toroidal one presents the inverse properties ($\unsim70\%$ axisymmetric and $\unsim55\%$ dipolar). We find that the dipole component has a polar strength of 390~G and that its axis is tilted at 15$^\circ$ to the rotation axis, towards phase 0.70. We see no clear correlation between brightness and magnetic field maps obtained with ZDI as was already the case in maps derived from optical data \citep{yu19}. We determined the longitudinal field\footnote{The longitudinal field is defined as the (algebraic) line-of-sight projected magnetic field component averaged over the visible hemisphere and weighted by brightness inhomogeneities.} $B_\ell$ at each epoch by computing the first moment of Stokes~$V$ profiles \citep{donati97}. The longitudinal field varies between about +50 and -250~G. The associated uncertainties range between 29~G and 42~G with a median of 32~G. We clearly see a periodic pattern in this index that can be fitted down to the noise level with a sine curve with one harmonic (period of $1.873\pm0.002$~d) as shown in Fig. \ref{fig:bl}. \subsection{Differential rotation} \label{sub:differential_rotation} As our spectropolarimetric observations are spread over more than one month, the data can potentially exhibit some variability due to differential rotation. By computing the amount of shearing by latitudinal differential rotation that the surface (brightness or magnetic) maps experienced with time, ZDI allows one to estimate the surface differential rotation assuming a solar-like shear, given by: \begin{equation} \Omega(\theta) = \Omega_{\mathrm{eq}} - (\cos \theta)^2 \mathrm{d}\Omega \end{equation} where $\theta$ is the colatitude, $\Omega_{\mathrm{eq}}$ and $\mathrm{d}\Omega$ are the rotation rates at the equator and the difference of rotation rate between the pole and the equator, respectively. This differential rotation law was found to be successful at modeling the surface shear of low-mass stars, including those of rapidly rotating, fully convective dwarfs \citep{morin08}, including in particular V410~Tau \citep{yu19}. One can measure both $\Omega_{\mathrm{eq}}$ and $\mathrm{d}\Omega$ by finding out the values that minimize the $\chi^2_r$ for a given amount of reconstructed information. \begin{table} \centering \caption{Summary of differential rotation parameters of V410 Tau obtained thanks to ZDI. Column 1 indicates the parameters of interest. Column 2 and 3 refer to estimates provided by Stokes~$I$ (brightness reconstruction) and Stokes~$V$ profiles (magnetic reconstruction), respectively. In the first row, we report the number of points used into ZDI process. Rows 2-3 show the equatorial rotation rate $\Omega_\mathrm{eq}$ and the associated rotation period, along with their 68\% confidence interval. Rows 4-5 provide the pole-to-equatorial difference rate d$\Omega$ with its 68\% confidence interval and the rotation period at the pole. Row 6 gives the inverse slope of the ellipsoid in the $\Omega_\mathrm{eq}$-d$\Omega$ plane (also equal to $\cos^2\theta_s$, where $\theta_s$ is the colatitude of the gravity centre of the brightness or magnetic field distribution (see \citealt{donati2000})). Last rows give the rotation rate $\Omega_s$ at colatitude $\theta_s$ and the associated rotation period.} \label{tab:differential_rotation} \begin{tabular}{lcc} \hline Parameter & Stokes~$I$ data & Stokes~$V$ data \\ \hline n & 1674 & 1674 \\ $\Omega_{\mathrm{eq}}$ (mrad d$^{-1}$) & $3358.8 \pm 0.5$ & $3358.7 \pm 0.4$ \\ $P_{\rm eq}$ (d) & $1.8707 \pm 0.0003$ & $1.8707 \pm 0.0002$ \\ d$\Omega$ (mrad d$^{-1}$) & $6.4 \pm 2.2$ & $9.0 \pm 1.9$ \\ $P_{\rm pole}$ & $1.8742 \pm 0.0013$ & $1.8757 \pm 0.0011$ \\ $\cos^2 \theta_s$ & 0.241 & 0.220 \\ $\Omega_s$ (mrad d$^{-1}$) & $3357.2 \pm 0.1$ &$3356.9 \pm 0.2$ \\ $P_{\rm s}$ & $1.87156 \pm 0.00006$ & $1.8717 \pm 0.0001$ \\ \hline \end{tabular} \end{table} \begin{figure*} \hspace*{-.73cm} \centering \begin{subfigure}[b]{0.49\textwidth} \centering \includegraphics[scale=0.35]{contour_StokesI_withyu.png} \caption{Stokes~$I$} \label{fig:subfig_contourI} \end{subfigure} \hfill \hspace*{-5cm} \begin{subfigure}[b]{0.52\textwidth} \centering \includegraphics[scale=0.35]{contours_StokesV_withyu.png} \caption{Stokes~$V$} \label{fig:subfig_contourV} \end{subfigure} \caption{Reduced $\chi^2$ map as a function of the differential rotation parameters $\Omega_{\mathrm{eq}}$, the equatorial rotation rate, and d$\Omega$, the pole-to-equator difference in rotation rate, obtained from (a) Stokes~$I$ and (b) Stokes~$V$ LSD profiles. The white cross indicates the optimal value with its associated error bars deduced from fitting a paraboloid to the $\chi^2_r$\ maps while the pink ones correspond to the estimates found by \citet{yu19}. Red ellipses define contours of 68\% (1$\sigma$) and 99.7\% (3$\sigma$) confidence levels for both parameters taken as pair. } \label{fig:contour_StokesI} \end{figure*} The $\chi^2_r$ maps derived from Stokes~$I$ and $V$ data respectively are shown in Fig. \ref{fig:contour_StokesI}, where contours of 68\% (1$\sigma$) and 99.7\% (3$\sigma$) confidence levels are depicted. We find from Stokes~$I$ LSD profiles that $\Omega_{\mathrm{eq}} = 3358.8 \pm 0.5$~mrad~d$^{-1}$ and $\mathrm{d}\Omega = 6.4 \pm 2.2$~mrad~d$^{-1}$, while Stokes~$V$ LSD profiles yield $\Omega_{\mathrm{eq}} = 3358.7 \pm 0.4$~mrad~d$^{-1}$ and $\mathrm{d}\Omega = 9.0 \pm 1.9$~mrad~d$^{-1}$, both estimates being mutually consistent within 1.5~$\sigma$. This implies that the rotation period ranges from about 1.8707~d ($\pm 0.0003$ from Stokes~$I$ and $\pm 0.0002$ from Stokes~$V$) at the equator to $1.8742 \pm 0.0013$~d (from Stokes~$I$) or $1.8757\pm0.0011$~d (from Stokes~$V$) at the pole. Compared to previous shear detections in the optical \citep{yu19}, we find that the uncertainty on $\Omega_{\rm eq}$ and d$\Omega$ obtained from Stokes~$I$ are about 5 and 3 times larger, respectively, which is likely related to the lower amount of data in our set as well as to the lower contrast of the reconstructed brightness features. On the contrary, uncertainties derived from Stokes~$V$ profiles are comparable to that estimated from optical data at previous epochs. We also computed the colatitude corresponding to the barycentre of the brightness and magnetic field distributions from the slope of the major axis of the confidence ellipse. In particular, our estimate from Stokes~$I$ LSD profiles is slightly larger than the ones derived by \cite{yu19} in the optical at previous epochs, suggesting that large surface features are indeed migrating poleward as speculated by these authors. Table \ref{tab:differential_rotation} gathers our results about differential rotation. \section{Stellar activity} \label{sec:sec4} \subsection{Radial velocities} \label{sec:sec4.1} \begin{figure*} \centering \hspace*{-1cm} \includegraphics[scale=0.4,trim={1.5cm 1.cm 3cm 2cm},clip]{RVs_V410_final.png} \caption{RVs of V410 Tau in 2019 November and December. \textit{Top panel:} Raw observed RVs have a dispersion of 1.40 $\mathrm{km}\,\mathrm{s}^{-1}$\ and are represented by black dots with their associated error bars. The green and pink curves are ZDI models obtained from brightness reconstruction considering SPIRou data only or SPIRou and TESS data simultaneously, respectively. The orange curve corresponds to the Gaussian process regression with its associated 1$\sigma$ confidence area in light grey. \textit{Bottom panel:} Filtered RVs for each of the three models. The color code of the points is the same as for the curves in the top panel. The dispersion of the filtered RVs is 0.13, 0.23 and 0.08 $\mathrm{km}\,\mathrm{s}^{-1}$\ for green, pink and orange data, respectively. Filtered RVs of different colors at each observation phase are slightly shifted along the horizontal axis for graphics purposes.} \label{fig:RV} \end{figure*} We computed the RV of V410 Tau at each observed phase as the first moment of Stokes~$I$ LSD profiles \citep{donati17} for both observed (obtained with M1) and ZDI synthetic ones. With the set of synthetic profiles, we simulated noisy profiles with the same SNRs as the observed ones. For several realisations of the noise we computed the RV and then the dispersion of these measurements to estimate the error bars on our actual radial velocity data. We compared raw observed RVs with synthetic RV curves obtained from the maps in Fig. \ref{fig2} and we computed activity filtered RVs as the difference between the observations and the model (Fig.~\ref{fig:RV}). We note that both maps lead to models that fit reasonably well the data. In a second step, we used GPR to model the impact of stellar activity on the observed RVs. For that, we chose the same kernel as that presented in Sec.~\ref{sec:sec2.2}, in Eq. \eqref{eq1}. Moreover, we added an additional term representing a potential excess of uncorrelated noise (in case our RV error bars are underestimated). The log likelihood function $\log \mathcal{L}$ we wanted to maximize becomes: \begin{equation} \log \mathcal{L} = -\frac{1}{2} \left( N\log2\pi + \log |\mathrm{K} + \mathrm{\Sigma} + \mathrm{S} | + y^T( \mathrm{K} + \mathrm{\Sigma} + \mathrm{S})^{-1}y \right) \end{equation} where $\mathrm{K}$, $ \mathrm{\Sigma}$ and $\mathrm{S}$ denote the covariance matrix with a quasi-periodic kernel, the diagonal matrix containing the variance of the observed RVs, and the diagonal matrix containing the additional noise $s$ to the square. $N$ refers to the number of points (i.e. number of observed RVs) and $y$ corresponds to the observed raw RVs. Given the low number of RV points, we chose to fix 2 of the 4 hyperparameters, namely the decay timescale $\theta_2$ (exponential timescale on which modeled RVs depart from pure periodicity) and the smoothing parameter $\theta_4$ (controling the amount of short-term variations in the fit) at 160~d (as derived from TESS light curve) and 0.35, respectively, following \cite{yu19}\footnote{As shown in \cite{klein20}, surface features induce more complex modulation on RVs than on light curves, hence the smaller value of the smoothing parameter $\theta_4$ used here compared to that derived when fitting the TESS data (see Sec.~\ref{sec:sec2.2}).}. Through a Markov Chain Monte Carlo (MCMC) approach using the \texttt{EMCEE PYTHON} module \citep{emcee}, we sampled the posterior distribution of the other parameters given the priors listed in Table \ref{tab:prior_RV}. We ran our MCMC on 5000 iterations of 100 walkers, and removed a burn-in period of 250~iterations, that is about 5 times larger than the autocorrelation time of the chain ($\unsim50$~iterations). We then chose the median of these posterior distributions as best values for the free parameters. The resulting phase plot is illustrated in Fig. \ref{fig:corner_plot_RV}. The amount of excess uncorrelated noise in the data (modeled with $s$) is found to be compatible with 0. From the best set of parameters, we obtained the GPR fit that is shown in Fig. \ref{fig:RV}. Each model yields a synthetic RV curve that we compared to our RV measurements; the corresponding $\chi^2_r$\ values are equal to 0.53 when applying ZDI to SPIRou data alone, 1.97 when ZDI is applied to combined SPIRou and TESS data and 0.14 when applying GPR. The corresponding dispersion of the activity-filtered RVs is about twice lower when we use GPR (0.08~$\mathrm{km}\,\mathrm{s}^{-1}$) rather than ZDI (0.13~$\mathrm{km}\,\mathrm{s}^{-1}$\ and 0.23~$\mathrm{km}\,\mathrm{s}^{-1}$, using SPIRou data alone or both SPIRou and TESS data). We come back on the potential origin of this difference in Sec.~\ref{sec:sec5.5}. We note that these dispersions are consistent with the typical uncertainty on our RV measurements ($\unsim180$~$\mathrm{m}\,\mathrm{s}^{-1}$), demonstrating that our models are successful at reproducing the activity-induced RV variations, both for atomic and molecular lines (and despite the difference in bulk RVs for both sets of lines). Applying the FF' method \citep{aigrain12} to the light curve predicted with ZDI, we can investigate the precision level at which this technique can mitigate activity in RV curves. We find that RV residuals exhibit a dispersion of 810~$\mathrm{m}\,\mathrm{s}^{-1}$\ RMS, i.e., 6-7$\times$ larger than those predicted with ZDI (130~$\mathrm{m}\,\mathrm{s}^{-1}$\ RMS), confirming that the FF' technique is not adequate for filtering out RV curves of moderately to rapidly rotating active stars, whose brightness distributions are often rather complex. \begin{table} \caption{Priors used for the MCMC sampling for the GPR on raw RVs and median values of the hyperparameters posterior distributions. For the uniform priors, we give the lower and upper boundaries of the interval while for the modified Jeffreys prior \citep{gregory07} we give the knee value. For $\theta_2$ and $\theta_4$ we mention the value we imposed. } \label{tab:prior_RV} \centering \begin{tabular}{lcc} \hline Hyperparameter & Prior & Estimate \\ \hline $\ln\theta_1$ [$\ln(\mathrm{km\,s^{-1}})$] & Uniform (-10, 10) & $0.08\pm0.18$ \\ $\theta_2$ [d] & 160 & \\ $\theta_3$ [d] & Uniform (0.9 $P_{\rm rot}$, 1.1 $P_{\rm rot}$) & $1.872\pm0.002$ \\ $\theta_4$ & 0.35 & \\ $s$ [$\mathrm{km\,s^{-1}}$] & Modified Jeffreys ($\sigma_{\rm RV}$) &$0.08\pm0.07$ \\ & & (compatible with zero)\\ \hline \end{tabular} \end{table} \begin{figure} \includegraphics[scale=0.4]{Corner_plot_RV.png} \caption{Phase plot of the posterior distribution of the three parameters let free, returned by the MCMC sampling. The best value for each parameter is chosen as the median value of the posterior distributions distributions shown in red line. We found $\ln\theta_1 = 0.08\pm0.18$, $\theta_3 = 1.872\pm0.002$ d and $s = 0.08\pm0.07$~$\mathrm{km}\,\mathrm{s}^{-1}$. We also traced the values that maximizes the posterior distributions in green lines. The plot has been done with the \texttt{CORNER PYTHON} module \citep{corner}.} \label{fig:corner_plot_RV} \end{figure} \subsection{Activity indicators} \label{sec:activity_index} We focused on three main activity indicators: the \ion{He}{i} triplet at 1083~nm, the Paschen $\beta$ (Pa$\beta$) and Brackett $\gamma$ (Br$\gamma$) lines at 1282~nm and 2165~nm, respectively (Fig.~\ref{fig:spectral_lines}). We identified a flare on December 09 (cycle 21.752) with the corresponding spectrum being blueshifted by 100~$\mathrm{km}\,\mathrm{s}^{-1}$\ with respect to the stellar rest frame, and the flux in the three lines being stronger than the typical one, especially in the Pa$\beta$ line (Fig.~\ref{fig:spectral_lines}). This flare occurs in the main gap of the TESS data (BJD 2,458,826.5 to BJD 2,458,829.3, see Fig.~\ref{fig:Lc_tess}) and therefore does not show up in the light curve. In addition, two observations collected just after the flare (i.e. on December 10 and 11) were also affected by the flaring episode and we thus decided not to use these three observations for our analyses based on the \ion{He}{i} triplet and Pa$\beta$ and Br$\gamma$ lines. We also identified a feature in the red wing of Pa$\beta$ (at $+120$~$\mathrm{km}\,\mathrm{s}^{-1}$), likely tracing Ti, Ca and Fe lines blending with Pa$\beta$, that does not vary more than the continuum around this line and is thereby expected not to affect significantly our analyses. We then compute the amount by which the equivalent width of these lines vary as a result of activity, which we call activity `equivalent width variations' (EWVs). In the stellar rest frame, we divided each telluric-corrected Stokes~$I$ spectrum by the median spectrum shown in Fig.~\ref{fig:median_lines}, yielding the median-divided spectra in Fig.~\ref{fig:spectral_lines_residuals}. The activity EWVs are then defined as the EW of these median-divided spectra counted as negative when absorption is larger than average. The values of the EWVs (and the corresponding error bars) were obtained through a gaussian fit to the median-divided spectra, using a gaussian of full-width-at-half maximum equal to 130~$\mathrm{km}\,\mathrm{s}^{-1}$\ centred on the stellar rest frame (consistent with the median \ion{He}{i}, Pa$\beta$ and Br$\gamma$ median profiles). We note that an activity indicator equal to 0 at a specific epoch does not indicate a lack of detection but rather that the corresponding profile is identical to the median one. The EWVs are provided in Table~\ref{table1}. For each line, we assumed equal error bars for all spectral points of all observations, which we set to the dispersion between spectra in the continuum about each line (equal to 0.014 for \ion{He}{i} and Br$\gamma$, and 0.008 for Pa$\beta$, and tracing mostly photon noise). The corresponding error bars we derive for the EWVs are equal to 2, 1 and 4~pm, respectively. As the integrated flux in the \ion{He}{i} and Pa$\beta$ lines is variable at a higher level than that expected from photon noise, we empirically derived the error bars on the EWVs of the three lines using the same method as in Sec.~\ref{sec:sec2.3} (likely overestimating the uncertainties) to account for the intrinsic variability and other main sources of noise that cannot be easily quantified. We achieved this by fitting the \ion{He}{i} and Pa$\beta$ EWVs with a sine curve (including 2 harmonics for \ion{He}{i}), whereas the Br$\gamma$ EWVs (showing essentially no variation with time) were fitted with a constant, yielding error bars of 25, 3 and 6~pm for the \ion{He}{i}, Pa$\beta$ and Br$\gamma$ lines, respectively. To assess the significance of our models, we computed the $\chi^2_r$\ when fitting a constant instead of a periodic curve for the \ion{He}{i} ($\chi^2_r$$=13.6$) and Pa$\beta$ ($\chi^2_r$$=3.5$) lines, yielding probabilities of 0 and $3.6\,10^{-6}$, respectively, for the detected modulation to be spurious by chance. Even with these simple models and pessimistic estimates of the error bars, we detected a significant modulation of both the \ion{He}{i} and Pa$\beta$ EWVs. We however caution that the false alarm probabilies (FAPs) we quote, assuming white noise, may be underestimated if correlated noise dominates, even though pessimistic error bars were used. The activity EWVs reveal enhanced absorption in phase range 0.4-0.6 for both the \ion{He}{i} triplet and the Pa$\beta$ line. This feature is also seen in the dynamic spectrum of the \ion{He}{i} triplet (Fig.~\ref{fig:dynamic_spectra}). \begin{figure} \centering \begin{subfigure}{0.49\textwidth} \centering \includegraphics[scale=0.285]{HeI_2harmo_gauss.png} \end{subfigure} \hfill \begin{subfigure}{0.49\textwidth} \centering \includegraphics[scale=0.285]{PaB_sinus_gauss2.png} \end{subfigure} \hfill \begin{subfigure}{0.49\textwidth} \centering \includegraphics[scale=0.285]{BrG_cste_gauss2.png} \end{subfigure} \caption{Phase folded activity EWVs derived from the \ion{He}{i} triplet at 1083.3~nm (first panel), Pa$\beta$ (second panel) and Br$\gamma$ lines (third panel) after removing the profile affected by the main flare at cycle 21.752. For the first two panels, the fit to the EWVs is shown in black line in the top panel while the bottom panel displayed the residuals between the EWVs and the best fit. In all panels, the red error bars correspond to those expected from the dispersion between spectra in the adjacent continuum (tracing photon noise) while the black ones were set to ensure a unit $\chi^2_r$\ fit to the data (thereby tracing intrinsic variability as well, and equal to 25, 3 and 6~pm for the \ion{He}{i}, Pa$\beta$ and Br$\gamma$ EWVs, respectively). The cyan open circles and error bars represent the two observations collected after the flare (not taken into account for the fit). The red error bars are slightly shifted along the horizontal axis for clarity purposes.} \label{fig:proxies_sinus} \end{figure} \subsection{Correlation matrices} \label{sec:sec4.3} From the median-divided spectra, we computed autocorrelation matrices for each of the three lines, considering the line relative intensities within an interval of $\pm200$~$\mathrm{km}\,\mathrm{s}^{-1}$. The coefficient $C_{ij}$ between velocity bins $i$ and $j$ is defined as: \begin{equation} C_{ij} = r_{ij} \sqrt{\sigma_i \sigma_j} \label{eq:4} \end{equation} where $r_{ij}$ is the Pearson linear coefficient between the two velocity bins, $\sigma_i$ and $\sigma_j$ are the standard deviation in the velocity bins $i$ and $j$, respectively. This definition of the unnormalised coefficient allows us to estimate the relative importance of the correlations, as a high value of $r_{ij}$ associated with a high level of variability is better emphasized than a high value of $r_{ij}$ associated with a low level of variability. The autocorrelation matrix of the \ion{He}{i} triplet reveals that the entire profile correlates well with itself (left panel of Fig.~\ref{fig:autocorrelation}). As a strong correlation indicates a common origin for the components, the observed correlation suggests that the entire \ion{He}{i} triplet emerges from a single region, likely the stellar chromosphere. The autocorrelation matrix of Pa$\beta$ (middle panel of Fig.~\ref{fig:autocorrelation}) shows a correlation / anticorrelation chessboard pattern above the noise level suggesting that the line width is slightly changing with time, getting narrower and deeper at times, then broader and shallower at some other times. In addition, both matrices show that the variability is asymmetric, being larger in the blue wing of these lines, possibly indicating the presence of a stellar wind. No particular pattern is apparent in the autocorrelation of the Br$\gamma$ line (right panel of Fig.~\ref{fig:autocorrelation}). We also show the normalized autocorrelation matrices (i.e. the $r_{ij}$ coefficients) in Fig.~\ref{fig:Pearson_autocorrelation_matrices}. \begin{figure*} \centering \begin{subfigure}[b]{0.3\textwidth} \centering \includegraphics[scale=0.22, trim= 0cm 0cm 2cm 1 cm, clip]{He_Pearson_Unnormalised.png} \end{subfigure} \hfill \begin{subfigure}[b]{0.3\textwidth} \centering \includegraphics[scale=0.22, trim= 0cm 0cm 2cm 1 cm, clip]{Pa_Pearson_unnormalised.png} \end{subfigure} \hfill \begin{subfigure}[b]{0.3\textwidth} \centering \includegraphics[scale=0.22, trim= 0cm 0cm 2cm 1 cm, clip]{Ga_Pearson_unnormalised.png} \end{subfigure} \caption{Autocorrelation matrices for \ion{He}{i} triplet (left panel), Pa$\beta$ (middle panel) and Br$\gamma$ (right panel) after removing the three observations affected by a flaring episode. The colorbars refer to the value of the coefficients as defined by Eq.~\eqref{eq:4}, with important correlation represented by reddish colours. The color scale depends on the level of variability for the considered line which is much larger for the \ion{He}{i} triplet than for the two other lines.} \label{fig:autocorrelation} \end{figure*} \subsection{2D Periodograms} For each velocity bin of the median-divided spectra, we computed a Generalized Lomb-Scargle periodogram as introduced by \cite{zechmeister09} thanks to the \texttt{PyAstronomy PYTHON} module \citep{pyastronomy}. We show them as 2D maps in Fig.~\ref{fig:he_periodogram} and \ref{fig:periodogram_PaB_BrG}. Using the typical error bars derived in Sec.~\ref{sec:activity_index} for all spectral points, we found that the \ion{He}{i} and Pa$\beta$ profiles exhibit rotational modulation (with aliases associated with the observing window), with a stronger variability in the blue wing (as seen in Sec.~\ref{sec:sec4.3}). These results are consistent with those obtained from the EWVs in Sec.~\ref{sec:activity_index}, though less obvious as information is not integrated over the line profile. The Br$\gamma$ periodogram does not show any clear period, consistent with EWV$\unsim0$. \begin{figure} \centering \begin{subfigure}[b]{0.45\textwidth} \centering \includegraphics[scale=0.27, trim= 0cm 0cm 2cm 1 cm, clip]{He_periodogram.png} \end{subfigure} \hfill \caption{2D periodogram for the \ion{He}{i} line at 1083.3~nm obtained using the \texttt{PyAstronomy PYTHON} module \citep{pyastronomy}. A Generalized Lomb-Scargle periodogram \citep{zechmeister09} has been computed for each velocity bin and represented through a color code. The color reflects the power of the associated period in the periodogram, normalized to 1 (red indicates most powerful periods). The magenta solid line depicts the stellar rotation period while the vertical dashed lines correspond to $\pm v\sin{i}$. The periodogram highlights a period compatible with the stellar rotation period but also aliases associated with the observing window. We note that the velocity bins between 20 and 40~$\mathrm{km}\,\mathrm{s}^{-1}$\ were poorly corrected from telluric lines which affected the periodograms.} \label{fig:he_periodogram} \end{figure} \section{Summary and discussion} \label{sec:sec5} Our paper reports new results derived from spectropolarimetric and photometric observations of the wTTS V410~Tau collected with the NIR spectropolarimeter SPIRou from 2019 October 31 to December 13 and the TESS space probe, from 2019 November 28 to December 23. \subsection{Benefit of photometry} \label{sec:5.1} For the first time, we jointly used high-resolution spectropolarimetry and high-precision photometry in ZDI to reconstruct the brightness distribution at the surface of the star. Both data are complementary as spectropolarimetry mostly constrains the location of the spots (from the distorsions of profiles) while photometry mainly informs on their contrast relative to the quiet photosphere. Taking into account photometry yields a higher number of brightness features and higher contrasts in the ZDI image, especially at low latitudes (Fig.~\ref{fig2}). These features are needed so that both SPIRou and TESS data can be fitted at unit $\chi^2_r$\, with the light curve fitted down to 1.6~mmag RMS (with residual correlated noise likely attributable to small-scale rapidly-evolving surface brightness features that cannot be properly reproduced by ZDI). These latitudes are usually not well reconstructed when considering spectropolarimetry only, as ZDI is best sensitive to features located at higher latitudes, in the visible hemisphere \citep{Vogt87,brown91}. We suspect that this increase in spot coverage reflects that TESS and SPIRou do not see the same spot distributions because of the difference of spectral domains. To further improve the accuracy of the brightness modeling at the surface of the star, one would need to secure photometric data in the $JHK$ bands that would provide an ideal match to the SPIRou spectropolarimetric data. This would ensure in particular that all brightness features present at the surface of the star (including those in the polar regions) affect spectroscopic and photometric data in the same way (which is not the case for, e.g., the cool polar spot detected in the optical but not in the NIR). Ground-based photometry allowed us to perform a similar analysis as \cite{yu19} (Fig.~B7 of their paper) but with $V-R_{\rm c}$ and $V-I_{\rm c}$ colour indexes. We fitted these indexes as a function of the magnitude in the $V$ band using a simplistic two-temperature model based on colour indexes from \cite{bessel98}. Our model features a fixed temperature of 4500~K for the photosphere, a surface gravity $\log{g}=4.0$, and a fixed temperature for spots with varying filling factor. We found an optimal spot temperature of 3750~K with a typical surface spot coverage of about 70\% (Fig.~\ref{fig:two_temperatures_model}), consistent with previous photometric measurements \citep{yu19}. This rather high spottedness level (consistent with that found for the similar wTTS LkCa~4, \citealt{gullysantiago17}) suggests in particular that a large fraction of the stellar surface is more or less evenly covered with small features that are not accessible to (and thus not reconstructed by) ZDI. \subsection{Infrared vs optical brightness reconstruction} V410~Tau is a wTTS that has been extensively studied in the past, mainly in the optical. Our study is innovative as we used NIR observations to constrain the brightness and the magnetic field of the star. As expected, NIR leads to a less contrasted surface brightness map. We find a reasonable statistical agreement for low- and mid-latitude spots (but less so in the polar regions) between optical and NIR maps, even though secured at different epochs. However, the absence of a polar spot in the map reconstructed from NIR data is surprising since such a feature consistently showed up in images derived from optical data up to now \citep{joncour94,hatzes95,skelly10,rice11,caroll12,yu19}. Our reconstructed map obtained with a mask containing only molecular lines, more sensitive to cooler regions, further confirms that no polar spot is detected at NIR wavelengths. Although we cannot entirely dismiss it, the option that the polar spot disappeared at the time of our SPIRou observations seems unlikely given the persistent presence of this feature in all previously published studies. The fact that the TESS light curve yields an average rotation period that is consistent with the trend derived from previous photometric data by \cite{yu19} suggests that the spot configuration at the surface of V410~Tau did not drastically evolve since 2016 and in particular that the cool spot reconstructed near the pole from optical data was likely still present in 2019. If the dark polar feature systematically seen at optical wavelengths is indeed not visible in the NIR, it suggests that continuum opacity above polar regions of V410 Tau is much larger in the optical domain than in the NIR for some reason. A speculative option, to be investigated further, may be that dust grains, such as those present in the upper solar atmosphere though in larger concentrations, tend to cluster in polar regions of the upper atmosphere of V410~Tau, making them appear much darker at optical than at NIR wavelengths. \subsection{Magnetic field} Applying ZDI to our Stokes~$I$ and $V$ LSD profiles simultaneously allowed us to reconstruct the large scale magnetic topology of the star. Our results are consistent with previous studies \citep{skelly10,yu19}. We find that the large-scale magnetic field has an average surface strength of about 410~G and that the radial field can be more intense locally, reaching up to 1.1~kG. Although V410~Tau is still fully convective, the magnetic field presents a strong toroidal component of unclear origin, as for the other fully-convective wTTS LkCa4 \citep{donati14}. More observations of fully-convective wTTSs are thus clearly needed to further constrain the origin of this strong toroidal field. We also found that the poloidal component contributes to nearly 60\% of the overall magnetic energy, compatible with the recent measurements derived from NARVAL (at the Telescope Bernard Lyot) optical data in 2016 \citep{yu19}. In addition, the polar strength of the dipole component (of the poloidal field) is close to 400~G, which again supports the reported increase in the intensity of the dipole from 2008 \citep{yu19}. These properties are compatible with those obtained by \cite{yu19} from their 2016 data set, and more generally with the long-term evolution they pointed out. These results suggest that, if a magnetic cycle exists, it is likely longer than 11~years. More observations of V410~Tau would be needed to confirm whether the observed tendency reflects part of a magnetic cycle as suggested by other studies \citep{stelzer03,hambalek19} or rather intrinsic variability of a stochastic nature. The longitudinal field as derived from SPIRou data shows similar fluctuations than that from optical studies (of period $\mathord{\sim} P_{\rm rot}$), but with error bars that are about 1.7 times smaller (typically 30~G) in half the exposure time, clearly demonstrating the benefits of studying magnetic fields of young stars in the NIR thanks to the enhanced Zeeman effect. We constrained the surface differential rotation of V410~Tau with ZDI from our Stokes~$I$ and $V$ LSD profiles separately, both results being compatible within 1.5$\sigma$. Our estimates are also consistent with those provided by \cite{yu19} within $\unsim3 \sigma$, although our Stokes~$I$ LSD profiles yielded slightly lower value. We note that the error bars obtained from Stokes~$I$ LSD profiles are larger in the NIR than in the optical, which is likely due to the lower number of observations but also to the lower contrast of the brightness features. For Stokes V data, the differential rotation parameters we derived are similar to the optical measurements of Yu et al (2019), with error bars of the same magnitude despite the sparser data thanks to the enhanced Zeeman effect in the NIR. We note that our estimates of differential rotation are larger than those derived by \citealt{siwak11} from photometric data collected with the MOST space-telescope in 2009. This photometric measurement of differential rotation is also inconsistent with the estimates of \cite{yu19}, despite having been collected at a close-by epoch. We thus suspect that this difference is related to the two-spot model used by \cite{siwak11} known to be inappropriate for stars like V410~Tau given the complex spot distributions reconstructed with ZDI (featuring both bright and dark spots). \subsection{Chromospheric activity} The \ion{He}{i} triplet at 1083~nm, the Pa$\beta$ and Br$\gamma$ lines are used as proxies to study the chromospheric activity of V410~Tau. A flare was detected at cycle 21.752 which also affected the two subsequent observations. Our analyses reveal that both the \ion{He}{i} and the Pa$\beta$ lines are rotationally modulated, while no significant variations are observed in Br$\gamma$. To obtain a rough description of the large-scale stellar magnetosphere, we extrapolated our magnetic image at the surface of V410 Tau into 3D maps, assuming that the magnetic field is potential (following the method described by \citealt{jardine99}) and that the source surface at which field lines open is located at 2.1~R$_\star$, following \cite{yu19} (Fig.~\ref{fig:extrapolated_field}). We see that enhanced absorption in chromospheric lines, occuring in phase range 0.4-0.6, takes place slightly before the magnetic pole crosses the line of sight (at phase 0.7, see Fig.~\ref{fig:extrapolated_field}), i.e., when one may have expected it to occur by analogy with solar coronal holes (darker in regions of open field lines). This phase lag may relate to the potential field assumption being no more than a rough approximation in our case. The reconstructed large-scale magnetic field indeed features a strong toroidal component (with intense azimuthal fields located close to the open field line region at phase 0.7, see Fig.~\ref{fig:maps_Iv}) that may suggest that the large-scale surface field is significantly stressed at these phases. Another option is that this enhanced absorption episode is due to the presence of massive prominences trapped in closed coronal loops (such as those reported in \citealt{yu19}) and crossing the stellar disc at phases 0.4-0.6. Obviously, the way the \ion{He}{i} triplet and the Pa$\beta$ line behave in wTTSs, and in particular how the \ion{He}{i} and Pa$\beta$ fluxes respond to the topology of the large-scale field remains to be investigated in more details. This will be the subject of forthcoming papers. \begin{figure} \centering \begin{subfigure}[b]{0.23\textwidth} \centering \includegraphics[scale=0.05]{phase000.png} \label{fig:phase00} \end{subfigure} \begin{subfigure}[b]{0.23\textwidth} \centering \includegraphics[scale=0.05]{phase025.png} \label{fig:phase20} \end{subfigure} \begin{subfigure}[b]{0.23\textwidth} \centering \includegraphics[scale=0.05]{phase050.png} \label{fig:phase50} \end{subfigure} \begin{subfigure}[b]{0.23\textwidth} \centering \includegraphics[scale=0.05]{phase075.png} \label{fig:phase70} \end{subfigure} \caption{Potential field extrapolations of the surface radial magnetic field obtained with ZDI, as seen by an Earth-based observer. Open field lines are shown in orange while closed field lines are drawn in black. Colours at the stellar surface represent the local value of the radial magnetic field (in G). Following \citet{yu19}, we assumed that the source surface is located at 2.1~R$_\star$, corresponding to the corotation radius, beyond which field lines open under the impact of centrifugal force. The star is shown at 4 evenly-spaced phases of the rotation cycle (indicated in the top left corner of each plot). } \label{fig:extrapolated_field} \end{figure} \subsection{Filtering activity jitter from RV curves} \label{sec:sec5.5} RVs of V410 Tau derived from Stokes~$I$ LSD profiles exhibit a full amplitude of about 4.5~$\mathrm{km}\,\mathrm{s}^{-1}$\ and a dispersion of 1.40~$\mathrm{km}\,\mathrm{s}^{-1}$\ RMS. These values are smaller than those generally observed in the optical at roughly the same SNRs, with amplitudes ranging from 4 to 8.5~$\mathrm{km}\,\mathrm{s}^{-1}$\ and a typical dispersion of 1.8~$\mathrm{km}\,\mathrm{s}^{-1}$\ RMS, respectively \citep{yu19}. This confirms the gain in using NIR observations to reduce the activity jitter in RV measurements. We find that the amplitude of RV jitter is reduced by up to a factor of 2, consistent with results of previous optical and NIR RV studies of TTSs \citep{prato08,mahmud11,crockett12}. For each of our ZDI reconstructed brightness maps (Fig.~\ref{fig2}) we computed the RV curve that results from the brightness features at the surface of V410~Tau. The ZDI image taking into account SPIRou data only, corresponding to a static brightness distribution, yields filtered RVs with a dispersion of 0.13~$\mathrm{km}\,\mathrm{s}^{-1}$\ RMS, i.e. about 25\% lower than in the optical for this star (typically 0.17~$\mathrm{km}\,\mathrm{s}^{-1}$; \citealt{yu19}), which suggests that the evolution of spots is not significant over our observations. We note that adding TESS data to the SPIRou data in the ZDI modeling does not improve, and actually even degrades, the accuracy of the filtering process (even after explicitly taking into account the difference in brightness contrasts at SPIRou and TESS wavelengths in the imaging process). This result demonstrates that the brightness distributions as seen by SPIRou and TESS are genuinely different and cannot be simply scaled up from one another, e.g., using Planck's law, with some features showing up in one spectral domain but not in the other (like the prominent polar spot detected ine the optical but not seen at NIR wavelengths). Filtering the activity jitter would thus likely be more efficient with ZDI applied to data sets combining SPIRou data with high-precision NIR photometry. We also modeled the RV activity jitter using GPR yielding a dispersion of filtered RVs about twice smaller than with ZDI models thanks to the higher flexibility of GPR to model intrinsic variability in the periodic modulation of the RV curve, that results from the evolution of the spot configuration at the surface of the star. The periodograms of RVs (Fig.~\ref{fig:Filtered_RV_periodogram}) do not show any periodic signature beyond that from V410~Tau~A, which further confirms that our spectropolarimetric data mainly probe the primary star, and not (or no more than very marginally) its 2 companions. In addition, our filtered RVs show no evidence for a RV signal from a potential giant planet on a close-in orbit (Fig.~\ref{fig:Filtered_RV_periodogram}), consistent with previous observations that did not suggest the presence of a hJ \citep{yu19}. To derive an upper limit on the mass of a potential planet from our data, we proceeded as in \cite{yu19} and applied GPR on simulated datasets (with the same temporal sampling as that achieved for our 2019 observations) featuring both a RV activity jitter (computed from the results of Sec.~\ref{sec:sec4.1}) and a RV signal from a planet on a circular orbit with a white noise identical to that of our measurement (of 181~$\mathrm{m}\,\mathrm{s}^{-1}$\ RMS). For each simulation, we compared models including both the planet and the activity jitter, with those including only the activity jitter, to assess the significance level at which a close-in giant planet of given mass could be detected from our data. From the difference of logarithmic marginal likelihood between both models (detection threshold set at $\Delta \mathcal{L}=10$), we found that, for a planet-star separation lower than 0.09~au, only planets with a mass larger than $\unsim5$~M$_{\rm jup}$ can be reliably detected (at a >3$\sigma$ level), consistent with the (more stringent) upper limit (of $\unsim1$~M$_{\rm jup}$) derived by \cite{yu19} for the same planet-star separation. Detecting close-in massive planets typically requires carrying out monitorings over several months during which the surface of the star can evolve significantly. This intrinsic variability cannot be modeled with the current version of ZDI that assumes a static distribution of features at the surface of the star (except for differential rotation), often forcing one to split data sets into smaller subsets that can be modelled independently from one another (e.g. \citealt{donati17,yu17,yu19}). In order to get a more global and consistent description of the stellar surface activity over several months, one needs to be able to model at the same time both the distribution of surface (brightness and magnetic) features and its evolution with time using all data at once. In this aim, we started to modify the original ZDI code to couple it with GPR, in order to simultaneously benefit from the physical modeling provided by ZDI (to detect and characterize stellar surface features), and from the flexibility provided by GPR (to describe the temporal evolution of these features). This new version of ZDI is currently under development and will be the object of forthcoming publications. Our study illustrates the benefits of NIR (vs optical) observations with instruments like SPIRou, to investigate the magnetic topologies of young stars and look for the potential presence of hJ on close-in orbits through RV measurements. New monitorings of V410~Tau will provide strong constraints on the existence of a magnetic cycle (and the underlying dynamo processes), will bring further clues on the enigmatic strong toroidal field that the star is able to trigger despite being fully convective, and will allow us identifying the main differences between images reconstructed from optical and NIR data, especially in the polar regions. More generally, SPIRou observations of PMS stars, including those carried out within the SLS, will offer the opportunity to investigate in more details the impact of magnetic fields on star / planet formation, and in particular to accurately characterize young planetary systems hosting transiting planets such as AU Mic and V1298 Tau \citep{david19a,david19b,plavchan20,klein21}, allowing one to refine the mass-radius relation of planets at an early stage of evolution. \section*{Acknowledgements} This work includes data collected with SPIRou in the framework of the SPIRou Legacy Survey (SLS), an international large programme allocated on the Canada-France-Hawaii Telescope (CFHT), operated from the summit of Maunakea by the National Research Council of Canada, the Institut National des Sciences de l'Univers of the Centre National de la Recherche Scientifique of France, and the University of Hawaii. We acknowledge funding by the European Research Council (ERC) under the H2020 research \& innovation programme (grant agreements \#740651 NewWorlds, \#865624 GPRV and \#716155 SACCRED). SHPA acknowledges financial support from CNPq, CAPES and Fapemig. We thank the referee for valuable comments and suggestions that helped improving the manuscript. \section*{Data Availability} The data collected with the TESS space probe are publicly available from the Mikulski Archive for Space Telescopes (MAST). The SLS data will be publicly available from CADC one year after the completion of the SLS programme (in 2022). \bibliographystyle{mnras}
{ "redpajama_set_name": "RedPajamaArXiv" }
5,790
Сан Мартин Дос има више значења: Сан Мартин Дос (Виљафлорес), насеље у савезној држави Чијапас у Мексику Сан Мартин Дос, Ла Вуелта дел СЕРЕСО (Леон), насеље у савезној држави Гванахуато у Мексику
{ "redpajama_set_name": "RedPajamaWikipedia" }
14
\subsection{INTRODUCTION} In recent years, many experimental and numerical efforts have been focusing on the propagation of strongly nonlinear solitary waves in granular media \cite{VFN_01}. These waves are a natural extension of the well known weakly nonlinear solitary waves such as the Korteweg-de Vries (KdV) solitons. Chains composed of steel, brass, glass, Nylon \cite{VFN_01, CFF_97, CG_98} and Polytetraflouroethylene (PTFE) \cite{DNHJ_05} particles support solitary waves using Hertz' law for particle interactions. However, dissipation plays a significant role in the transmission of pulses in almost all experimental settings. Restitution coefficients and velocity dependent friction have been used to investigate dissipation in a chain of particles \cite{MSH_01, RL_03}. The energy losses are significant even when the experiments are performed in air (see Fig. 1.25 in \cite{VFN_01}). These losses may be attributed to uncontrolled features in the experimental setup as well as inherent material properties \cite{JMSS_04}. To predictably control the dissipation, a chain of spheres may be immersed in viscous fluids. The viscous dissipation of pulses in chains of particles differs from a two particle interaction in liquid because the compression wave dominates the system's dynamic behavior. To our knowledge, there has not been an attempt to extend the research involving the collision of particles in fluids to a chain of particles. This paper extends current knowledge of a two particle collision in a viscous medium to a case where multiple particle interactions support a solitary wave. \subsection{ANALYTICAL MODEL AND NUMERICAL CALCULATIONS} The analytical model for a one-dimensional Hertzian chain of spheres can be found in \cite{VFN_01}. The description of particle interactions in fluids is presented in [8-12]. One of the complications of using current sphere-fluid models for a chain of spheres is that a developed flow around the sphere is assumed before the particle collision though the duration of the pulse in a chain is relatively short ($\sim$50 $\mu$s). Nevertheless we use the outlined approach for the first stage of our research. In \cite{M-T_68} two particles are considered to be traveling towards each other in a surrounding medium. If the spheres are the same size then the total kinetic energy is \begin{equation} \label{eq:MT} \frac{1}{4}\left(2m + m' + \frac{3}{8}\frac{m'R^{3}}{h^{3}}\right)U^{2} = constant, \end{equation} where $m = \frac{4}{3}\pi\rho R^{3}$ is the mass of the particle, $m' = \frac{11}{12}\pi \rho_{f}R^{3}$ is the added mass, $R$ is the particle's radius, $h$ is the separation distance between particle centers and $U=\frac{dh}{dt}$ is the relative particle velocity. Differentiating Eq. (\ref{eq:MT}) with respect to $h$ yields the added mass and pressure force terms. The equations of motion for a chain of spheres, with mass $m_{i}$, placed vertically in a gravitational field in a fluid becomes \begin{multline} \label{eq:full} \left(m_{i}+m'_{i}\right)\frac{d^{2}x_{i}}{dt^{2}} = F_{c,i}\left(\delta\right) + m_{i}g + F_{b,i} \\+ F_{D,i} + F_{p,i} + F_{d,i}. \end{multline} where $\delta_{i,i+1}=\left(R_{i}+R_{i+1}+x_{i}-x_{i+1}\right)$ and the $x_{i}$'s are the particle positions. The compression force $F_{c,i}$ is based on Hertz law between particle '{\it{i}}' and the adjacent particles '{\it{i}}-1' and '{\it{i}}+1'; \begin{equation} F_{c,i} = \phi\left(\delta_{i-1,i}\right)- \psi\left(\delta_{i,i+1}\right), \end{equation} where $\phi$ and $\psi$ can be expressed as \begin{equation} \label{eq:phi} \phi\left(\delta_{i-1,i}\right) =A_{i-1,i}\left(\delta_{i-1,i}\right)^{3/2} \end{equation} and \begin{equation} \label{eq:psi} \psi\left(\delta_{i,i+1}\right)=A_{i,i+1}\left(\delta_{i,i+1}\right)^{3/2}. \end{equation} The coefficients in Eqs. (\ref{eq:phi}) and (\ref{eq:psi}) are identical except for a shift of indices. The equation for $A_{i-1,i}$ can be inferred from \begin{equation} A_{i,i+1} = \frac{4E_{i}E_{i+1}\left(\frac{R_{i}R_{i+1}}{R_{i}+R_{i+1}}\right) ^{1/2}}{3\left[E_{i+1}\left(1-\nu_{i}^{2}\right) + E_{i}\left(1- \nu_{i+1}^{2}\right)\right]}, \end{equation} where $E_{i}$ and $\nu_{i}$ are the elastic modulus and Poisson's ratio of the particle. For all of the calculations performed with air as the surrounding medium, only the first two terms on the right hand side and the first term on the left side of Eq. (\ref{eq:full}) are used. When liquids surround the chain of spheres the buoyancy, drag, pressure, added mass and dissipative terms are used. The buoyancy force for each particle is \begin{equation} \label{eq:buo} F_{b,i}= -\frac{4}{3}\pi R_{i}^{3}\rho_{f}g, \end{equation} where $g$ is the gravitational constant, $R_{i}$ is the radius of the particle and $\rho_{f}$ is the density of the fluid. The drag force has a correction factor to account for a Reynold's number $Re$ greater than unity i.e. not in the Stoke's flow regime, \begin{equation} \label{eq:drg} F_{D,i} = -6\pi \nu R_{i}U_{i}(1+0.15Re^{0.687}), \end{equation} where $\nu$ is the dynamic viscosity and $U_{i}$ is the particle velocity. The pressure force in \cite{ZFZP_99} is written for one sphere moving toward a stationary sphere. In our case, we use a relative velocity between particles, \begin{equation} \label{eq:pres} F_{p,i} = \frac{3}{8}\pi R_{i}^{2}\rho_{f}\left[(U_{i-1}-U_{i})^{2}-(U_{i}-U_{i+1})^{2}\right]. \end{equation} We introduce an additional dissipative term based on the relative velocity between particles with a fitting parameter $c$ due to the lack of a qualitative agreement between the experiments and calculations based on the drag force term (Eq. (\ref{eq:drg})). This addition is tantamount to adding a dash-pot between neighboring particles \cite{DML_69}, \begin{equation} \label{eq:diss} F_{d,i} = c\left(U_{i-1} - 2U_{i}+U_{i+1}\right), \end{equation} where the coefficient $c$ is a fitting parameter. The physical reason for this term can be due to the radial flow of liquid caused by the change of contact area between particles. MATLAB's intrinsic ODE45 solver was used to march the explicit calculation forward in time with a time-step of 0.05$\mu$s. The error in the energy calculations were found to be less than 10$^{-9}$\% in air and within 10$^{-5}$\% in the fluid. The error in the conservation of linear momentum performed with a chain in air was less than 10$^{-12}$\%. \subsection{EXPERIMENTAL PROCEDURES AND RESULTS} In the experiments, the impulse propagation was investigated in three different media: air, SAE 10W-30 motor oil, and non-aqueous Glycerol GX0185-5. \begin{figure*}[t] \label{fig:1} \includegraphics[scale=0.41,clip,trim=14mm 11mm 16mm 15mm]{single_b4diss.eps} \caption{Single solitary wave in calculations (a) and experiments (c) in a chain surrounded by air. Results for an identical chain surrounded by glycerol in calculations (b) and experiments (d). Vertical scale is 2 N/div.} \end{figure*} The density and dynamic viscosity used in numerical calculations were $\rho_{f}=880$ kg/m$^{3}$, $\nu=0.067$ Ns/m$^{2}$ for oil and $\rho_{f}=1260$ kg/m$^{3}$, $\nu=0.62$ Ns/m$^{2}$ for glycerol. An experiment was performed with each of the three types of media to see how single and multiple solitary waves propagate through the chain. The chain was placed into an adjustable holder that had four contact points on each sphere. The air or fluid was able to flow freely between the contacts as opposed to the cylindrical holder that had been used in previous experiments. To create a single solitary wave, a spherical stainless steel striker with a radius of $R=4.76$ mm and a mass of $m=0.4501$ g was used to impact the top of a chain of 19 stainless steel particles (also with $R=4.76$ mm) with a velocity of $U_{0}=0.44$ m/s. To create multiple solitary waves in the same chain, a cylindrical alumina striker with a larger mass of $m=1.23$ g impacted the chain at $U_{0}=0.44$ m/s. The elastic modulus and Poisson's ratio of the stainless steel particles were 193 MPa and 0.3, respectively. The experimental results were recorded via piezoelectric gauges imbedded \cite{DNHJ_05} in the 10th and 15th particles from the top of the chain. The procedures outlined in \cite{DNHJ_05} were implemented to compare the calculations to the experimental results using the averaged dynamic force as noted on the vertical axis of Fig. \ref{fig:1}, \ref{fig:2} and \ref{fig:3}. In Fig. \ref{fig:1} the numerical and experimental results are shown for a single solitary wave in a chain surrounded by air (a), (c) and glycerol (b), (d). It is evident that there is a very small difference between the numerical results for the chain in air and glycerol using Eqs. (\ref{eq:full})-(\ref{eq:pres}), which prompted the inclusion of the additional dissipative term (Eq. (\ref{eq:diss})). Without this dissipative term, the numerical results for glycerol shown in Fig. \ref{fig:1}(b) do not exhibit the shape and speed of the pulses in experiments. In experiments the speeds of the single pulse were $V_{s}=520$ m/s in air and increased to $V_{s}=541$ m/s in glycerol. It is interesting to note that the calculated signal speed was $V_{s}=564$ m/s in air and decreased to $V_{s}=540$ m/s in glycerol. In numerical calculations the speed of the single pulses in chains surrounded by both air and glycerol should be higher than the experimental pulse speeds due to the higher amplitude of the waves. Also, one would intuitively think that the pulse speed in air would be higher than in glycerol due to viscous dissipation. This is the case in calculations (even when the additional dissipative term $F_{d}$ is added) but the opposite is true in experiments (Fig. \ref{fig:1}(c) and (d)). \begin{figure*}[htbp] \label{fig:2} \includegraphics[scale=0.37,clip,trim=17mm 0mm 18mm 5mm]{mult_b4diss.eps} \caption{(a) Numerical results for multiple solitary waves in a chain of 19 particles surrounded by air. (b) Numerical results for multiple solitary waves in an identical chain surrounded by glycerol. (c) Experimental results related to (b). Vertical scale is 2 N/div.} \end{figure*} In Fig. \ref{fig:2} the numerical results for a train of solitary waves in air and glycerol are presented. The dissipative term $F_{d}$ was not included in the calculations in (a) and (b) and it is apparent that the amplitudes of the waves are much higher than the experimental results in glycerol (c). Additionally, no signal splitting into a train of solitary waves were present in experiments Fig. \ref{fig:1}(c), which is not reflected by the calculations without the additional dissipative term $F_{d}$. Again, the wave speeds in experiments were higher in glycerol than in air. There is a disparity between the presented analytical formulation using the corrected Stokes drag for dissipation and the experiments. The largest dissipative term in the calculations (before the addition of the dissipative term $F_{d}$) is the drag force term. The reduction of the amplitude of a single pulse was about 3\% in oil and about 4\% in glycerol when using Eqs. (\ref{eq:full})-(\ref{eq:pres}). These equations, while important for accurately describing a particle trajectory pre and post collision are negligible when their effect on the compression wave are examined. \begin{figure*}[tbp] \label{fig:3} \includegraphics[scale=0.34,clip,trim=19mm 0mm 20mm 9mm]{aft_diss.eps} \caption{(a) Numerical results for a single pulse with additional dissipative term Eq. (\ref{eq:diss}) in a chain surrounded by glycerol. (b) Numerical result for an impact by an alumina striker on the same chain. Vertical scale is 2 N/div.} \end{figure*} The results of adding the dissipative term Eq. (\ref{eq:diss}) are presented in Fig. \ref{fig:3} for single and multiple pulses traveling in a chain submersed in glycerol. A similar asymmetry and widening of the pulse, apparent in experiments, can also be seen when Fig. \ref{fig:3}(a) is compared to Fig.\ref{fig:1}(d). The lower line in Fig. \ref{fig:1}(d) has a noticeable shock-like tail. In calculations the tail of the wave becomes more shock-like as parameter $c$ increases. The qualitative behavior of the pulse in experiments is reproduced in calculations by adding an additional dissipative term $F_{d}$ with a coefficient $c=6.0$ Ns/m for glycerol and $c=0.648$ Ns/m for oil. These values provided the best comparison between experimental and numerical data and were scaled according to the difference in viscosity. When comparing Fig. \ref{fig:2}(b) and Fig. \ref{fig:3}(b), notice the additional dissipation Eq. (\ref{eq:diss}) has also created a shock-like response of the train of solitary waves. In calculations the amplitude and tendency to split decreased by adding this term in accord with experiments. \subsection{CONCLUSIONS} The experimental results indicate a qualitative change of the propagating shock and solitary waves in a chain immersed in glycerol while only a small change in oil. Without the relative velocity based dissipative term $F_{d}$, the equations pertaining to the surrounding fluid could not accurately reproduce the amplitude or the shock like structure of the incident pulse. This term provided the qualitative change needed to match the numerical analysis to the experiments. The numerical analysis predicted a decrease in solitary wave speed as the viscosity of the surrounding fluid increased contrary to experiments. This phenomenon may be explained by an increased effective stiffness modulus between particles in the presence of a viscous fluid. \subsection{ACKNOWLEDGEMENTS} The work is supported by NSF (Grant No. DCMS03013220). \bibliographystyle{aipprocl}
{ "redpajama_set_name": "RedPajamaArXiv" }
4,598
{"url":"http:\/\/rsps.wikia.com\/wiki\/Data_Types","text":"## FANDOM\n\n48 Pages\n\nIn computer programming, a data type is a classification identifying one of various types of data, such as floating-point, integer, or Boolean, that determines the possible values for that type; the operations that can be done on values of that type; and the way values of that type can be stored.\n\n## OverviewEdit\n\nAlmost all programming languages explicitly include the notion of data type, though different languages may use different terminology.\n\nCommon data types may include:\n\n\u2022 booleans,\n\u2022 characters,\n\u2022 floating-point numbers,\n\u2022 alphanumeric strings.\n\nFor example, in the Java programming language, the \"int\" type represents the set of 32-bit integers ranging in value from -2,147,483,648 to 2,147,483,647, as well as the operations that can be performed on integers, such as addition, subtraction, and multiplication. Colors, on the other hand, are represented by three bytes denoting the amounts each of red, green, and blue, and one string representing that color's name; allowable operations include addition and subtraction, but not multiplication.\n\nMost programming languages also allow the programmer to define additional data types, usually by combining multiple elements of other types and defining the valid operations of the new data type. For example, a programmer might create a new data type named \"complex number\" that would include real and imaginary parts.\n\nA data type also represents a constraint placed upon the interpretation of data in a type system, describing representation, interpretation and structure of values or objects stored in computer memory. The type system uses data type information to check correctness of computer programs that access or manipulate the data.\n\n## Classes of data typesEdit\n\n### Machine data typesEdit\n\nAll data in computers based on digital electronics is represented as bits (alternatives 0 and 1) on the lowest level. The smallest addressable unit of data is usually a group of bits called a byte (usually an octet, which is 8 bits). The unit processed by machine code instructions is called a word (as of 2011, typically 32 or 64 bits). Most instructions interpret the word as a binary number, such that a 32-bit word can represent unsigned integer values from 0 to $2^{32}-1$ or signed integer values from $-2^{31}$ to $2^{31}-1$. Because of two's complement, the machine language and machine don't need to distinguish between these unsigned and signed data types for the most part.\n\nThere is a specific set of arithmetic instructions that use a different interpretation of the bits in word as a floating-point number.\n\n### Primitive data typesEdit\n\nThese are basic data types that are provided by the programming language with built-in support. These data types are native to the language.This data type is supported by machine directly\n\n## Runescape Data TypesEdit\n\n### IntroductionEdit\n\nRuneScape uses a number of standard and non-standard data types.\n\n### Byte OrderEdit\n\nData types that are two bytes or larger can be stored and ordered in a variety of different ways. Generally people either use big endian or little endian.\n\n#### Big EndianEdit\n\nIn big endian order, the most significant byte (MSB) is stored first and the least significant byte (LSB) is stored last.\n\n#### Little EndianEdit\n\nIn little endian order, the least significant byte (LSB) is stored first and the most significant byte (MSB) is stored last.\n\n#### Byte order in RuneScapeEdit\n\nRuneScape uses both little and big-endian byte orders throughout the protocol (however, the 194 client only uses big-endian order), presumably to make reverse-engineering of the protocol harder. Some confusion has arisen over the byte order as the data types are named incorrectly in Winterlove's server where little endian data types are incorrectly named as big endian types.\n\n### Standard data typesEdit\n\nThese datatypes can also be read\/written by a DataWriter\/DataReader implementation (DataStreams and Buffers)\n\nNaming conventions:\n\nOfficial name Datatype name Jagex name Encoding\nByte byte 1,1b\nWORD short 2,2b\nDWORD int,int32 4,4b\nQWORD long,int64 8,8b\nC style string string,String,char *,char[] str,strbyte text bytes then '\\n' or 10\nJava style string string,String,char *,char[] strraw WORD length then text bytes\n\nNote that Jagex used to use a new line character as string terminator, in more recent versions they use the null character \\0 or 0 to support multi-line strings.\n\n### Non Standard Data Types Edit\n\nWinterlove's name Jagex name Read transformation Write transformation\nSpecial A Unknown value - 128 value + 128\nSpecial C Unknown 0 - value 0 - value\nSpecial S Unknown 128 - value 128 - value\nSpaceSaverA smarts (value[0] < 128)\u00a0? (((value[0] - 128)<<8)+value[1])\u00a0: value[0] if(value < 128) putword(value+32768) else putbyte(value);\nSpaceSaverB smart ((value[0]<<8)+value[1]) - 49152 if(i < 64 && i >= -64) putbyte(i + 64) else if(i < 16384 && i >= -16384) putword(i + 49152);\ntribyte \/ RGBColour \/ 3Byte \/ int3 \/ medium 3 (value[0] << 24) + (value[1] << 16) + value[2] putbyte(value >> 24);putbyte(value >> 16);putbyte(value);\nRS_String jstr Old engine: read until newline delimiter (\"\\n\")\nNew engine: read until null byte (value 0).\nOld engine: write and finish with newline delimiter (\"\\n\")\nNew engine: write and finish with null byte (value 0).\n\nAdditionally, RuneScape also uses two integers that are different from a big or low endian order. Both byte orders are called middle endian. Their orders could be described as following:\n\nMiddle endian big int: C3 D4 A1 B2\n\nMiddle endian small int: B2 A1 D4 C3\n\n(A1 smallest D4 biggest byte)","date":"2018-12-12 18:18:20","metadata":"{\"extraction_info\": {\"found_math\": true, \"script_math_tex\": 0, \"script_math_asciimath\": 0, \"math_annotations\": 0, \"math_alttext\": 0, \"mathml\": 0, \"mathjax_tag\": 0, \"mathjax_inline_tex\": 1, \"mathjax_display_tex\": 0, \"mathjax_asciimath\": 0, \"img_math\": 0, \"codecogs_latex\": 0, \"wp_latex\": 0, \"mimetex.cgi\": 0, \"\/images\/math\/codecogs\": 0, \"mathtex.cgi\": 0, \"katex\": 0, \"math-container\": 0, \"wp-katex-eq\": 0, \"align\": 0, \"equation\": 0, \"x-ck12\": 0, \"texerror\": 0, \"math_score\": 0.17480264604091644, \"perplexity\": 4744.109000704188}, \"config\": {\"markdown_headings\": true, \"markdown_code\": true, \"boilerplate_config\": {\"ratio_threshold\": 0.18, \"absolute_threshold\": 10, \"end_threshold\": 15, \"enable\": true}, \"remove_buttons\": true, \"remove_image_figures\": true, \"remove_link_clusters\": true, \"table_config\": {\"min_rows\": 2, \"min_cols\": 3, \"format\": \"plain\"}, \"remove_chinese\": true, \"remove_edit_buttons\": true, \"extract_latex\": true}, \"warc_path\": \"s3:\/\/commoncrawl\/crawl-data\/CC-MAIN-2018-51\/segments\/1544376824115.18\/warc\/CC-MAIN-20181212181507-20181212203007-00095.warc.gz\"}"}
null
null
Q: Splitting tablets in YugabyteDB over multiple directories using fs_data_dirs [Question posted by a user on YugabyteDB Community Slack] I did some reading in the docs and found fs_data_dirs. Does yugabyte-db automatically split the tablets evenly in the data dirs? A: The flag fs_data_dirs sets the directory or directories for the tablet server or master where it will store data on the filesystem. This should be specified as a comma-separated list. This data is logging, metadata, and data. The first directory will get the logging, all the directories will get the WAL and rocksdb databases. The tablets which is the storage foundation of a table or index are distributed over the directories in a round-robin fashion. This indeed happens completely automatically. It might be confusing to talk about splitting because when a YSQL table or secondary index is created, the create statement allows you to explicitly define how many tablets the object is split, which is what is distributed over the directories specified. At the risk of making it confusing, there is another feature which is called automatic tablet splitting, which is a feature set by the flag '--enable_automatic_tablet_splitting' set in the masters, which is the mechanism of making YugabyteDB automatically split tablets when it deems tablets getting too big, and thus allows you to start with a single tablet, which will then be split automatically.
{ "redpajama_set_name": "RedPajamaStackExchange" }
259
Commentary OpinionTHE CRY-BULLIES Media fail trying to sell campus protest Exclusive: Jack Cashill shares data proving ineffectiveness of Mizzou brouhaha By Jack Cashill Published November 18, 2015 at 7:25pm No publication tried harder to persuade the public of the righteousness of the recent campus protest movement than the Kansas City Star. Backing the Star in its attempt were virtually every major broadcast media other than Fox News. If nothing else, these media succeeded in drawing the attention of the public to events taking place on the state's flagship campus in Columbia. And yet as poll results have clearly shown, the media failed to convince Missourians of the protests' value or even that there was a problem worth protesting. Indeed, if there were ever a test case of the mainstream's media's estrangement from ordinary America – and no state is more ordinary than Missouri – this was it. For a week Star editors were giddy with excitement at having a major racial meltdown take place right on their home state campus. Almost immediately, the editors called for the head of MU system President Tim Wolfe. His crime: responding to "ugly" racist incidents on campus in "bureaucratic, uncaring fashion." As to hunger striker Jonathan Butler, the editors begged him to desist. He had "already achieved dramatic change at his university," they assured him. "It is my hope and belief that from this point on," wrote columnist Barbara Shelly in a public letter to Butler, "no one in Missouri will discount the acts of racism and evil that too often smear your campus as isolated, not-so-serious incidents." These were two of the score or more pieces the Star dedicated to highlighting the "evil" Butler and his pals were protesting. In a vacuum, they might have been effective, but in the age of social media, they merely appeared foolish. Through alternative channels, the public learned that Butler's fight against white privilege was bankrolled in part by his father's $8 million-plus annual income. The public learned that the gay, black, student-body president who got the racism drum beating was a proven liar. If his lament that a guy in a pickup truck called him names went unchallenged, his later claim that the KKK had invaded campus did not. That was provably false, and the fellow had to apologize. Jack Cahill's brand new book illustrates how the neo-Puritan progressive movement came to mimic a religion in its structure but not at all in its spirit -- order "Scarlet Letters: The Ever-Increasing Intolerance of the Cult of Liberalism" Finally, if the public carefully parsed the deliberately clouded campus police reports, they might have learned that the chief suspect in the notorious "poop swastika" incident was likely black. Certainly, the public learned enough to reject the Star's thesis – echoed throughout the major broadcast media – that the campus protest was a good and noble thing. After the MU president was forced out, the Remington Research Group ran a statewide poll on behalf of Missouri Scout, a website for state political news. Although 96 percent of the respondents followed the events on campus, a reassuringly low percentage of them swallowed the party line sold by the mainstream media. When asked if they agreed with the MU "student protesters' actions," 62 percent disagreed, and only 20 percent agreed. For white respondents, the margin was even greater: 63 percent to 18 percent. For that matter, only 51 percent of blacks agreed with the actions while 38 percent did not. The "message" – whatever that was – did not fare much better than the "actions." Among whites, 23 percent approved; among blacks, 53 percent. For university administrators, the results had to be particularly worrying. By a greater than 5-to-1 margin, respondents disapproved of the administration. By a 48 to 38 percent margin, respondents would vote against a cigarette tax to provide public scholarships to the university. Even more troubling, by a 45 to 35 percent margin, parents would discourage their children from attending the university. As to the future of the football program, forget it. Unconvinced perhaps by the statewide results, the Star ran its own poll among its own generally liberal readers and fared no better. When asked if the protesters deserved praise for exposing racial problems, 66 percent said "no." When asked if Tim Wolfe should have resigned as president, 67 percent said "no." When asked if the two faculty members who intimidated student journalists should be fired, 67 percent "agreed strongly" and 84 percent said "yes." If there is a genuine cause worth protesting, it is that even in a fairly sane state like Missouri the left has a stranglehold on the media and on the universities. This is not true everywhere. Kudos to President Mitch Daniels and my homeboys at Purdue for publicly taking a stand. Wrote Daniels in the wake of the protests, "Last year, both our undergraduate and graduate student governments led an effort that produced a strengthened statement of policies protecting free speech." Daniels continued, "What a proud contrast to the environments that appear to prevail at places like Missouri and Yale." Proud contrast indeed. Media wishing to interview Jack Cashill, please contact [email protected]. Receive Jack Cashill's commentaries in your email BONUS: By signing up for Jack Cashill's alerts, you will also be signed up for news and special offers from WND via email. Where we will email your daily updates A valid zip code or postal code is required Click the button below to sign up for Jack Cashill's commentaries by email, and keep up to date with special offers from WND. You may change your email preferences at any time. Jack Cashill Jack Cashill has a Ph.D. from Purdue University in American studies. His lastest book is "Unmasking Obama." 49ers' Brock Purdy carries on QBs' Christian tradition Time to apply the Obama standard to George Santos New documentary exposes truth of George Floyd's undoing '60 Minutes' showcases world's worst futurist Jewish women wage war on the woke AI used by feds to track ISIS now targeting conservative Americans Pro-prostitution bills may worsen human trafficking, but are they part of the solution?
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
5,060
Click here for a list of Special Award winners for 2018. REALTOR OF THE YEAR –A REALTOR ® who is an all-around outstanding person; one who emanates professionalism in real estate practice and is a credit to the Board. ROOKIE OF THE YEAR –A REALTOR® who is new to the Board and/or real estate profession who has shown excellence in their duties to their profession and their service to the Board. VOLUNTEER OF THE YEAR –A member of the Board (REALTOR® or affiliate) who has willingly volunteered their time for various projects of the Board. COMMITTEE MEMBER OF THE YEAR –A volunteer of a committee who has dedicated their time and efforts to organize, promote and carry out the functions of their respective committee. AFFILIATE OF THE YEAR –A member of the Board who is not a REALTOR® who has excelled in their duties to their profession and their service to the Board.
{ "redpajama_set_name": "RedPajamaC4" }
5,945
Q: JTable not showing any data I created a class that is meant to show a JTable populated with data taken from a database with hibernate: public class FLlistes extends JInternalFrame { private JTable table; private DefaultTableModel model; //some code for more components of the form String[] columns = {"Id","Data", "Lloc"}; model = new DefaultTableModel(columns, 0) { @Override public Class<?> getColumnClass(int columna) { if (columna == 2) return LocalDate.class; return Object.class; } @Override public boolean isCellEditable(int row, int column) { return false; } }; table = new JTable(model); JScrollPane scrollPane = new JScrollPane(); scrollPane.setBounds(49, 176, 732, 361); getContentPane().add(scrollPane); scrollPane.setViewportView(table); //some code for more components of the form } Then I have a class that makes the queries with hibernate. The next method is supposed to collect data from a table and populate the table I created before. public class AccionsBD { public static void GetAllLlistes() { String jql = "select llc from LlistaCompra llc"; EntityManager entityManager = JPAUtil.getEntityManagerFactory().createEntityManager(); TypedQuery<LlistaCompra> q = entityManager.createQuery(jql,LlistaCompra.class); List<LlistaCompra> llistes = q.getResultList(); FLlistes fl = new FLlistes(); for (LlistaCompra llista: llistes) { System.out.println(llista.getIdLlista()); System.out.println(llista.getData()); System.out.println(llista.getLloc()); Object[] objFila = new Object[3]; objFila[0] = llista.getIdLlista(); objFila[1] = llista.getData(); objFila[2] = llista.getLloc(); fl.getModel().addRow(objFila); } entityManager.close(); } } The purpose of the System.out.println inside the loop is only to check that the query works. The query is working fine, I tried debugging and the end of the loop objFila contains all the correct data, but the table in the form never shows anything besides the table header. What am I missing? Also, for some reason sometimes when I run the app the form shows up, and somtimes it doesn't. It does this without even changing the code. Why does this happen? Edit: this is my getter: public DefaultTableModel getModel() { return model; }
{ "redpajama_set_name": "RedPajamaStackExchange" }
4,031
Q: Saxon rpm build fails due to "ant: command not found" Hopefully this is a question I can ask this community. I'm currently working on building zookeeper-3.4.5-13 for a CentOS 5 environment. During this process I've been going down a long list of required packages ( mockito -> objenesis -> maven -> maven2 -> classworlds -> dom4j -> jtidy-> ant -> jakarata-common-net -> saxon ) and I'm running into an issue building saxon-6.5.5-3.3. When I build, I get to the %build section of the process and end up erring out with the following: DEBUG: + exit 0 DEBUG: Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.mUxwgM DEBUG: + umask 022 DEBUG: + cd /builddir/build/BUILD DEBUG: + cd saxon-6.5.5 DEBUG: + LANG=C DEBUG: + export LANG DEBUG: + unset DISPLAY DEBUG: + export CLASSPATH= DEBUG: + CLASSPATH= DEBUG: + ant -Dj2se.javadoc=/usr/share/javadoc/java -Djdom.javadoc=/usr/share/javadoc/jdom DEBUG: /var/tmp/rpm-tmp.mUxwgM: line 32: ant: command not found DEBUG: error: Bad exit status from /var/tmp/rpm-tmp.mUxwgM (%build) DEBUG: RPM build errors: DEBUG: Bad exit status from /var/tmp/rpm-tmp.mUxwgM (%build) DEBUG: Child returncode was: 1 The first to check is that ant was installed, and sure enough, it was: DEBUG: ================================================================================ DEBUG: Package Arch Version Repository DEBUG: Size DEBUG: ================================================================================ DEBUG: Installing: DEBUG: ant i386 1.6.5-2jpp.2 core 2.0 M DEBUG: java-1.6.0-openjdk-javadoc i386 1:1.6.0.0-1.21.b17.el5 core 20 M DEBUG: jdom i386 1.0-4jpp.1 core 328 k DEBUG: jdom-javadoc i386 1.0-4jpp.1 core 305 k DEBUG: jpackage-utils noarch 1.7.5-3.8.iot5 core 63 k DEBUG: xml-commons-apis Any other information I can provide as needed, but if anyone could tell me why ant isn't found it would be appreciated. For more insight, this is being done with mock and going into the mock shell does show that any is missing from any locations that would be considered normal to run from. A: The ant executable cannot be found in your path. Run rpm -ql ant | grep 'bin/ant$' and make sure that the bin/ directory is included in your PATH variable.
{ "redpajama_set_name": "RedPajamaStackExchange" }
6,264
Q: Why Jest is sending me this timeout error? Actually this code don't work, the error message is : thrown: "Exceeded timeout of 5000 ms for a test. Use jest.setTimeout(newTimeout) to increase the timeout value, if this is a long-running test." I an blocked since 1 week can someone help me ? When i call the route /login on postman its works perfectly const session = require('express-session') const res = require('express/lib/response') const request = require('supertest') const app = require("../routes/routes") describe('test POST', () => { it('login', async () => { let result = await request(app) .post('/login') .send({ loginID:"1705", loginPwd:"17051999" }) }) }) I tried to increase the timeout but not works too Here is the post route app.post('/login', (req, res) => { console.log(req.body) let id = req.body.loginID let mdp = req.body.loginPwd if (id != '' && id != undefined) { if (mdp != '' && mdp != undefined) { let Login = require('../models/M_Login') Login.testLogin(id,mdp, (result, id) => { console.log(result) switch (result.resultCode) { case 0: req.session.infoUser = result req.session.infoUser.loginNo = id req.session.success = 'Connexion réussie' res.redirect('/accueil') break case 2001: req.session.error = 'Identifiant inconnu' res.redirect('/') break case 2002: req.session.error = 'Mot de passe incorrect' res.redirect('/') break case 1003: req.session.error = 'Compte bloqué veuillez contacter l\'administrateur' res.redirect('/') break } }) } else { req.session.error = 'Vous devez renseigner votre mot de passe' res.redirect('/') } } else { req.session.error = 'Vous devez renseigner votre identifiant' res.redirect('/') } }) and here the function who call the API const axios = require('axios').default; const { baseUrlServer } = require('../server') class M_Login { static testLogin(id, mdp, cb) { axios.post(baseUrlServer + '/login/loginPwd', { "loginNo": id , "loginPwd": mdp , "domainNo": 0 }) .then(function (res) { cb(res.data, id) }) .catch(function (error) { cb(error) }) } } module.exports = M_Login A: If you want to test your API call, I recommend you to mock your API response A: EDIT : I found the problem, it was on the req.session of the routes.js I think that jest don't know express session and thats why the test never finish
{ "redpajama_set_name": "RedPajamaStackExchange" }
7,465
Becoming a dog trainer is the secret dream of many. When the "sport" of dog training turns into your professional career, there's a lot more to know then merely handling and training a dog. If you are going to run a successful business, you MUST understand that dog training has become a client-oriented service. The key to being a powerful instructor and top-notch coach is to understand how people learn and the challenges adults face when acquiring the new physical skills they need to train their dogs. In other words, you need to know almost as much about training and educating people as you do about dogs. To be a powerful instructor you must communicate effectively, show enthusiasm, motivate your clients and their belief in their ability to achieve success, and maximize their comprehension and retention of what you teach. In this course, Pia reveals the communication, classroom management, coaching, teaching and overall "people" skills she not only uses herself but teaches to her apprentice instructors that have made St. Huberts Dog Training School in Madison NJ one of the largest and most respected dog training schools in the country. You'll learn exceptional classroom skills that will allow you to manage even those classes from "you know where", and can also be applied to private lessons with chaotic families how to build in flexibility in your instruction to accommodate and motivate a wide range of personalities, learning styles, and physical abilities how to create detailed lesson plans and a curriculum that will maximize your students' success advanced skills that will allow you to better monitor your clients' actions and measure their success to apply the standards to people that you do when training dogs to help them reach their goals and Much, Much More! If you implement what you learn in this course, experienced trainers will become top-notch coaches and powerful instructors, and set themselves apart from "the pack!" If you are a novice trainer, this course will jump-start your instructing and coaching skills it would take years to learn on your own. If you are thinking about changing careers to become a dog trainer because you love animals, you'll quickly learn that you need to care about people just as much, and know how to create good client relationships.
{ "redpajama_set_name": "RedPajamaC4" }
2,423
Welcome! This Ruby gem helps You to send SMS using API https://sms-fly.com/ TODO: ## Installation Add this line to your application's Gemfile: ```ruby gem 'smsfly', '~> 0.4.6' ``` And then execute: $ bundle Or install it yourself as: $ gem install smsfly Then run: $ rails g smsfly:config which will generate default settings files: config/initializers/smsfly.rb Then configurate smsfly.rb file: ```ruby Smsfly.configuration do |config| config.login = 'You login' # Like this 380675807873 config.password = 'You password' # Like this ZhHtgj4Z end ``` Or another method ```ruby #/YouApp/config/application.rb module YouApp class Application < Rails::Application ENV['SMS_FLY_USER'] = 'You login' # Like this 380675807873 ENV['SMS_FLY_PASS'] = 'Your password' # Your password at https://sms-fly.com/ end end #and config/initializers/smsfly.rb Smsfly.configuration do |config| config.login = ENV['SMS_FLY_USER'] config.password = ENV['SMS_FLY_PASS'] end ``` Test connection to API: ```ruby Smsfly.authentication? #this return true #- If authentication is successful false #- If authentication failed ``` Get your balance: ```ruby Smsfly.balance #this return Float object(like "6.177" ,"5.655")#- If authentication is successful false #- If authentication failed ``` ## Usage TODO: For show you login and password run: $ rails c $ Smsfly.connect_info If the file *smsfly.rb* is set up correctly You can send a test message to your own login/phone ```ruby Smsfly.test_sms('You random text') ``` To send a message to other numbers, use ```ruby Smsfly.send_sms(text, recipient , description , source) # For example Smsfly.send_sms('Hello Word', '380675807873' , 'Name for Sms' , 'Alfaname') ``` Add campaignID ```ruby log_obj - object where we write campaignID log_filed - campaignID field # for example history = HistoryItem.new() history.save Smsfly.send_sms(text, recipient , description , source , {:log_obj => history, :log_filed => 'campaign_id'} ) # This write campaignID from API TO history.campaign_id ``` To send a message without getting campaignID ```ruby Smsfly.send_sms(text, recipient , description , source , options = {} ) # For example Smsfly.send_sms('Hello Word', '380675807873' , 'Name for Sms' , 'Alfaname' , {:log_obj => 'Model', :log_filed => 'campaign_id'}) ``` Get Sms Status ```ruby Smsfly.get_status(campaignID) # Smsfly.get_status(43545345) # It return {"STOPFLAG"=>"0", "ALFANAMELIMITED"=>"0", "ERROR"=>"0", "USERSTOPED"=>"0", "STOPED"=>"0", "UNDELIV"=>"1", "EXPIRED"=>"0", "DELIVERED"=>"0", "SENT"=>"0", "PENDING"=>"0", "NEW"=>"0"} if campaignID valid # Or returrn false if campaignID = no valid ``` ## Development After checking out the repo, run `bin/setup` to install dependencies. You can also run `bin/console` for an interactive prompt that will allow you to experiment. To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org). ## Contributing Bug reports and pull requests are welcome on GitHub at https://github.com/Serhii-Danovsky/smsfly. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct. ## License The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
{ "redpajama_set_name": "RedPajamaGithub" }
8,760
Madeline Sonik Anvil Press Publishers Inc, 2020 Reviewed by Isaac Maschek Madeline Sonik sets her misanthropic and heartbreaking short story collection in the fictional Ontario city of Fontainebleau, along the Detroit river. Each story follows a citizen of the city through traumas relived and repressed, from idealistic cops to heartbroken vandals. Sonik makes it easy to sympathize with even the most troubled individuals, and weep for the good-hearted souls trapped by Fontainebleau's pull. Fontainebleau presents an immoral world where every human is a monster and every monster is humanized. The world Sonik describes is dark and grim,and plays with perspective, unreliable narrators, and characters that cross over between stories, making it read like a novel more often than not. A lesser writer would fall into preachiness, but Sonik leaves the readers to make up their own minds. Rather than persuade them to feel sympathy for the disadvantaged, Sonik shows her characters as they are, warts and all. While this sometimes leads to sudden shifts in reader perspective, the complex characterization is worth the effort. Each short story is told from a different point of view, and the fluctuating timing and narration can make it seem as if each of the stories is unconnected, which makes it all the more satisfying when they eventually do align. Fontainebleau sows a paranoia in the reader not unlike that of its characters. Unsurprisingly, Sonik's poetic talents are on full display as she focuses on the most important details and poetically sings them home, hard-hitting for their contrast without being too dissonant. Readers drawn to soft crime novels and subtle horror set in the real world will find Fontainebleau to their liking. The book dabbles with the supernatural, but never fully commits to it, or "explains the monster." The terrifying elements are very human – making them all the more unsettling. Fontainebleau both benefits from rereads and has the makings of an excellent if atypical book club read. Sonik is an accomplished poet, non-fiction, and fiction writer from Detroit. Her experimental non-fiction Afflictions and Departures was longlisted for the 2012 BC National Award for Canadian Non-Fiction, shortlisted for the 2012 Charles Taylor Prize, and winner of the 2012 City of Victoria Butler Book Prize. She currently teaches at the University of Victoria's Department of Writing.
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
5,202
Goldin Elite (66) Non Sport Cards (212) Kareem Abdul Jabbar Collection (116) Bobby Doerr Collection (51) Lamar Odom Collection (21) 1957 Topps Football #1 PSA Set (158) Rings, Trophies & Awards (109) Babe Ruth (24) US History (2) October Legends Closing October 27,2018 Auction closed on 10/28/2018. Final prices include buyers premium. Lot #2: 1961 School Safety Patrol Award of Merit Presented To Lewis Alcindor (Abdul-Jabbar LOA) Min Bid: $300.00 Final Price: $1,350.25 Lot #3: 1961 St. Jude C.Y.O. MVP Trophy Presented To Lewis Alcindor (Abdul-Jabbar LOA) Min Bid: $1,000.00 Lot #4: 1961 The Catholic News All-Stars Basketball Festival Trophy Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #5: 1962 Power Memorial Academy Honor Society Certificate Presented To Lewis Alcindor (Abdul-Jabbar LOA) Final Price: $552.38 Lot #6: 1962 IONA Catholic High School 1st Place Trophy Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #7: 1962 Saint Peter's College Invitational Basketball Tournament Most Valuable Player Trophy Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #8: 1963 La Salle Alumni Basketball Festival Outstanding Player Trophy Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #9: 1963 Mount St. Michael Academy 9th Annual Block "M" Dinner Plaque For Outstanding Opponent Presented To Lewis Alcindor (Abdul-Jabbar LOA) Lot #10: 1963-64 Power Memorial Academy MVP Trophy Presented to Lew Alcindor (Abdul-Jabbar LOA) # Bids: 18 Final Price: $10,800.00 Lot #14: 1964 John Norton Memorial Trophy 1964 CHSAA Championship Playoffs MVP Awarded To Lew Alcindor (Abdul-Jabbar LOA) Lot #15: 1964 Parade Publication Annual All-America High School Basketball Team "First Squad" Certificate Presented To Lew Alcindor - Spelled "Lou" (Abdul-Jabbar LOA) Lot #16: 1964 Power Memorial Academy Basketball Team Signed Basketball Presented To Lew Alcindor For Scoring, 2,000 Points (Abdul-Jabbar LOA) Lot #18: 1965 John Norton Memorial Award CHSAA Championship Playoff MVP Trophy Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #20: 1965 Power Memorial Academy MVP Trophy Presented to Lew Alcindor (Abdul-Jabbar LOA) Lot #21: 1966 Los Angeles Basketball Classic All-Tournament Award Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #22: 1966 UCLA Bruins Christmas Tournament Championship Watch Given To Lew Alcindor (Abdul-Jabbar LOA) Lot #23: 1966-67 Converse Chuck Taylor All-America Selection Award Certificate Presented To Lewis Alcindor (Abdul-Jabbar LOA) Lot #24: 1966-67 Lew Alcindor/Kareem Abdul-Jabbar UCLA Letterman's Sweater Replaced By UCLA In 1984 (Abdul-Jabbar LOA) Lot #25: 1966-67 U.S. Basketball Writers Association Player of the Year Plaque Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #26: 1966-67 UCLA Most Valuable Player Desk Set Presented To Lewis Alcindor (Abdul-Jabbar LOA) Lot #27: 1967 All America Selections University Division Plaque Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #28: 1967 All-America Basketball Team Award Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #29: 1967 Basketball Writers Association All American Plaque Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #30: 1967 Coach & Athlete Magazine Player of the Year Award Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #31: 1967 Helms Athletic Foundation All-America Team Award Presented To Lewis Alcindor (Abdul-Jabbar LOA) Lot #32: 1967 Helms Athletic Foundation College Basketball Player of the Year Trophy Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #33: 1967 Pohlmeyer Memorial Trophy Presented To Lewis Alcindor (Abdul-Jabbar LOA) Lot #34: 1967 The Sporting News All-America Team Plaque Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #35: 1967 United Press International All-America Basketball Team Certificate Presented to Lew Alcindor For Member Of First Team (Abdul-Jabbar LOA) Lot #36: 1967 United Press International All-America Basketball Team Certificate Presented to Lew Alcindor For Player Of The Year (Abdul-Jabbar LOA) Lot #37: The 1967 Look Magazine Basketball Writer's Association All America Team Certificate Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #40: 1968 City of Los Angeles Plaque Presented To Lew Alcindor For Contribution To 1967-68 UCLA Basketball Team (Abdul-Jabbar LOA) Lot #41: 1968 Holiday Basketball Festival MSG Winner Bulova Award Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #42: 1968 UCLA Bruins NCAA Basketball National Championship Watch Given To Lew Alcindor (Abdul-Jabbar LOA) Lot #43: 1968 UCLA Most Valuable Player Desk Set Presented To Lewis Alcindor (Abdul-Jabbar LOA) Lot #45: 1968-69 Helms Athletic Foundation Certificate Presented To Lew Alcindor For Collegiate Player Of The Week (Abdul-Jabbar LOA) Lot #46: 1968-69 James A. Naismith Trophy Award Presented To Lew Alcindor For Most Outstanding College Basketball Player In The US (Abdul-Jabbar LOA) Lot #50: 1969 Congratulatory Assembly California Legislature Resolution for the UCLA Bruins Basketball Team (Abdul-Jabbar LOA) Lot #51: 1969 Helms Foundation Basketball Writers University Player of the Year Gold Bowl Award Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #52: 1969 Lew Alcindor Look Magazine College All American Ring (Abdul-Jabbar LOA) Lot #54: 1969 Lew Alcindor Personally Owned UCLA Letterman's Jacket Given Freshman Year (Abdul-Jabbar LOA) Min Bid: $10,000.00 Lot #55: 1969 Outstanding Metropolitan College Athlete Dolly King Memorial Award Plaque Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #56: 1969 UCLA Most Valuable Player Trophy Presented To Lewis Alcindor (Abdul-Jabbar LOA) Lot #58: Kareem Abdul-Jabbar & John Wooden Signed Photo, Wooden Signed Basketball & Various UCLA Photos in 42x33 Framed Display (Abdul-Jabbar LOA & JSA) Lot #59: 1970 Lew Alcindor Rookie Game Used All-Star Game Eastern Conference Uniform In 28x42 Framed Display (Abdul-Jabbar LOA) Lot #61: 1970-71 M.B.W.A Sam Davis Memorial Award MVP Trophy Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #62: 1970-71 NBA Most Valuable Player Scoring Champion Award Presented To Lew Alcindor (Abdul-Jabbar LOA) Lot #63: 1971 Lew Alcindor Milwaukee Bucks NBA Championship Ring (Abdul-Jabbar LOA) Final Price: $150,000.00 Lot #65: 1971 Sport Magazine NBA Playoff Award Presented To MVP Lew Alcindor (Abdul-Jabbar LOA) Lot #66: 1971-73 Kareem Abdul-Jabbar Game Used Photo Matched Milwaukee Bucks Home Jersey (Mears A9, Abdul-Jabbar LOA & Sports Investors) Lot #68: 1974-75 Milwaukee Bucks Blocked Shots Average Champion Clock Award Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #69: 1975-76 NBA Rebounding Average & Blocked Shots Average Champion Presentation Clock Awarded To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #70: 1976 Seagram's Seven Crowns Of Sports Basketball Champion Trophy Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #71: 1976-77 NBA Field Goal Percentage Champion Presentation Clock Awarded To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #73: 1977 All Star Plaque Presented to Kareem Abdul-Jabbar in Recognition Of Being Selected For The NBA All-Star Team (Abdul-Jabbar LOA) Lot #74: 1978-79 NBA Blocked Shots Average Champion Presentation Clock Awarded To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #75: 1980 Kareem Abdul-Jabbar NBA All League Team Watch (Abdul-Jabbar LOA) Lot #77: Kareem Abdul-Jabbar Game Worn Herslof Goggles (Abdul-Jabbar LOA) Lot #78: 1983 Kareem Abdul-Jabbar Signed Los Angeles Lakers Uniform Player Contract Also Signed By Jerry Buss (Abdul-Jabbar LOA & PSA/DNA) Lot #79: 1984 Congratulatory Letters to Kareem Abdul-Jabbar On Surpassing Wilt Chamberlain's Record of All-Time Leading Scorer In 24x28 Framed Display (Abdul-Jabbar LOA) Lot #80: 1984 Jerry Buss All-Time Leading Scorer Recognition Award Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #82: 1984 Kareem Abdul-Jabbar NBA All Time Leading Scorer Ring - Only One Issued! (Abdul-Jabbar LOA) Lot #83: 1984 Original LeRoy Neiman Oil Painting Of Famous Skyhook in 23x41 Framed Display Signed By 1983-84 Los Angeles Lakers (Abdul-Jabbar LOA & JSA) Lot #84: 1984-85 NBA & Sport Magazine's Most Valuable Player Trophy(FINALS MVP) Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #85: 1981 Kareem Abdul-Jabbar Game Used All-Star Game Western Conference Uniform In 28x42 Framed Display (Abdul-Jabbar LOA) Lot #87: 1985 NBA All-Star Game Ballot Plaque Presented To Kareem Abdul-Jabbar For Western Conference Center (Abdul-Jabbar LOA) Lot #88: 1985 Sports Illustrated Sportsman of the Year Trophy Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #89: 1985-86 All-NBA Team Los Angeles Lakers First Team Award Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #90: 1984 President Ronald Reagan Typed Letter Of Congratulations Sent To Kareem Abdul-Jabbar in 14x17 Framed Display (Abdul-Jabbar LOA) Lot #91: 1969 Los Angeles Times Newspaper Ad For Kareem Abdul-Jabbar's Pro Debut In 13x21 Framed Display (Abdul-Jabbar LOA) Lot #92: 1986-87 Kareem Abdul-Jabbar Game Used, Photo Matched & Signed Los Angeles Lakers Home Jersey With Shorts (Abdul-Jabbar LOA & Sports Investors) Lot #93: 1986-87 Kareem Abdul-Jabbar Game Used & Signed Los Angeles Lakers Road Jersey (Abdul-Jabbar LOA) Lot #94: 1988 California State Assembly Resolution Presented To Kareem Abdul-Jabbar As Congratulations For 1987-88 NBA Championship (Abdul-Jabbar LOA) Lot #95: 1988 Kareem Abdul-Jabbar Los Angeles Lakers "Back To Back" Championship Watch (Abdul-Jabbar LOA) Lot #96: 1988 Pepsi-Cola Plaque Award Presented To Kareem Abdul-Jabbar For Breaking The NBA All-Time Scoring Record 31,421 (Abdul-Jabbar LOA) Lot #99: Kareem Abdul-Jabbar Los Angeles Lakers Scrapbook (Abdul-Jabbar LOA) Lot #100: 1989 Kareem Abdul-Jabbar Signed California Legislature Assembly Concurrent Resolution On Retirement In 17x23 Framed Display (Abdul-Jabbar LOA) Lot #101: 1989 Kareem Abdul-Jabbar Signed Glass Ice Bucket Presented For Last Regular Season Appearance at the Forum (Abdul-Jabbar LOA) Lot #102: 1989 Republic of China Plaque Presented To Kareem Abdul-Jabbar In Commemoration of His Farewell Game (Abdul-Jabbar LOA) Lot #103: 1989 State of California Senate Resolution of Gratitude Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #104: NBA Trophy Presented To Kareem Abdul-Jabbar For 20 Years of Greatness & Excellence in the NBA (Abdul-Jabbar LOA) Lot #105: 1988-89 Kareem Abdul-Jabbar Final Season Game Used Los Angeles Lakers Jersey in 30x42 Framed Display Presented For #33 Retirement (Abdul-Jabbar LOA) Lot #107: Kareem Abdul-Jabbar Owned & Signed Custom Made Crutches (Abdul-Jabbar LOA) Lot #108: Kareem Abdul-Jabbar Owned 1990 All-American Team Satin Jacket (Abdul-Jabbar LOA) Lot #109: 1990 New York City Basketball Hall of Fame Inaugural Induction Ceremony Award Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #110: Key To The City Of Los Angeles Presented To "The Cap" Kareem Abdul-Jabbar By Mayor Tom Bradley In Presentation Box (Abdul-Jabbar LOA) Lot #112: 1990 The City of Inglewood Proclamation of Kareem Abdul-Jabbar Week (Abdul-Jabbar LOA) Lot #113: Ronald Reagan & Bill Clinton Signed Photos Inscribed To Kareem Abdul-Jabbar With Additional Presidential Photos In 32x28 Framed Display (Abdul-Jabbar LOA & PSA/DNA) Lot #114: The Great Ones: 1993 The National Sports Award Photo In Lucite Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #116: 1995 Jim Thorpe Pro Sports Awards Lifetime Achievement Award To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #117: 1995 John F. Kennedy Original Oil Painting On Canvas By Peter Max On 36x48 Framed Backing (Abdul-Jabbar LOA) Lot #118: Kareem Abdul-Jabbar Personally Owned NBA's 50 Greatest Customized Jeff Hamilton Leather Jacket (Abdul-Jabbar LOA) Lot #119: Muhammad Ali Signed Training Jacket & Inscribed Boxing Glove Used In Preparation for Fight with Joe Frazier Gifted To Kareem Abdul-Jabbar In 42x29 Framed Display (Abdul-Jabbar LOA & PSA/DNA) Lot #120: 2008 National Civil Rights Museum National Sports Legacy Award Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #121: 2013 NCAA Top 75 All-Time March Madness Player Award Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #122: 1995 The School of Saint Jude Appreciation Plaque Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA) Lot #123: 1996 Victor Awards NBA Career Achievement Award Presented To Kareem Abdul-Jabbar (Abdul-Jabbar LOA)
{ "redpajama_set_name": "RedPajamaCommonCrawl" }
1,155
Welcome to Japan! We at Accessible Travel Japan provide information and arrangements for people with disabilities and/or special needs to travel pleasantly and safely. We provide information according to your disability and/or needs. Tell us about yourself and what you'd like to do in Japan. We match your condition and needs with the necessary accessibility information. ATJ provide information for your specific needs. Please tell us about yourself and what you need. Accessible Guide for Greater Tokyo Area Released! JAPAN Accessible Travel Organization Launches New Service for Foreign Travelers and Residents with Disabilities.
{ "redpajama_set_name": "RedPajamaC4" }
2,882
/** * 单选框 * @author Brian Li * @email lbxxlht@163.com * @version 0.0.2.2 */ define(function (require) { var React = require('react'); var InputWidget = require('./mixins/InputWidget'); var cTools = require('./core/componentTools'); return React.createClass({ /** * @properties * * @param {Import|Properties} src\core\componentTools.js skin className style disabled * @param {String} label 单选框旁边显示的文字,点击文字也可以改变选中状态 * @param {String} value 单选框的值,触发onChange时随事件对象返回,用于区分单选框的身份 * @param {Boolean} checked 单选框是否被选中,触发onChange时随事件对象返回,用于表明单选框时候被选中 * @param {String} labelPosition 文本标签显示的位置,'right'为单选框右侧,否则在左侧 * @param {Import|Properties} src\mixins\InputWidget.js * onChange name validations customErrorTemplates valueTemplate */ /** * @fire Radio onChange * @param {SyntheticEvent} e React事件对象。此事件一般不需要被监听。 * @param {HtmlElement} e.target 组件实例的根容器 * @param {Boolean} e.target.checked Radio是否被选中。如果onChange被触发这个值必然是true * @param {String} e.target.value Radio的值,用于区别身份,等于this.props.value。 */ // @override contextTypes: { appSkin: React.PropTypes.string }, // @override mixins: [InputWidget], // @override getDefaultProps: function getDefaultProps() { return { ___uitype___: 'radio', // base skin: '', className: '', style: {}, disabled: false, // self label: '', value: '', labelPosition: 'right', // mixin valueTemplate: false }; }, // @override componentWillReceiveProps: function componentWillReceiveProps(nextProps) { if (nextProps.checked !== this.props.checked) { this.refs.inputbox.checked = nextProps.checked; } }, // @override getInitialState: function getInitialState() { return {}; }, onClick: function onClick(e) { if (this.props.disabled) return; e = { target: this.refs.inputbox }; if (e.target.checked) return; e.target.checked = true; this.___dispatchChange___(e); }, render: function render() { var containerProp = cTools.containerBaseProps('checkbox', this, { style: { position: 'relative' } }); var checked = this.___getValue___(); var labelProp = { className: 'fcui2-checkbox-label', onClick: this.onClick }; var inputProp = { ref: 'inputbox', type: 'radio', name: this.props.name, value: this.props.value, checked: checked, onChange: cTools.noop, disabled: this.props.disabled }; var virtualCheckboxProp = { className: 'fcui2-icon fcui2-icon-radio' + (checked ? '-selected' : ''), onClick: this.onClick }; return React.createElement( 'div', containerProp, this.props.labelPosition !== 'right' ? React.createElement( 'span', labelProp, this.props.label ) : null, React.createElement('input', inputProp), React.createElement('span', virtualCheckboxProp), this.props.labelPosition === 'right' ? React.createElement( 'span', labelProp, this.props.label ) : null ); } }); });
{ "redpajama_set_name": "RedPajamaGithub" }
1,330
Велоінфраструктура Тернополя — сукупність споруд, систем, служб Тернополя, необхідних для забезпечення умов розвитку велосипедного руху в місті, організації велоподій, спортивних змагань тощо. Історія розвитку Концепцію розвитку велоінфраструктури Тернополя запропонували велоактивісти. Її підтримали в Тернопільській міській раді. Відповідно, до 2025 року заплановано ряд заходів щодо розвитку міської велоінфраструктури, зокрема: 2015—2018 — створення першого зеленого маршруту довкола Тернопільського ставу; станом на серпень 2017 заплановане майже реалізовано; 2015—2016 — маркування велодоріжок у парках і скверах згідно карти маршрутів; частково реалізовано, хоч і без дотримання норм законодавства та здорового глузду; 2016—2018 — маркування магістрального веломаршруту «Аляска-Дружба-Східний»; 2018—2021 — з'єднання між собою районів та прокладання альтернативних маршрутів; 2021—2025 — створення велохабів та продовження створення велодоріжок від Тернополя до прилеглих сіл, районів. Наразі місту бракує не тільки велодоріжок, а й великих парковок у місцях, де люди пересідають з одного транспорту на інший. Велоактивісти пропонують розмістити їх біля авто- та залізничного вокзалів, «Шостого магазину», перетину вулиць 15 Квітня та В. Симоненка, на Збаразькому кільці. У бюджеті міста на 2016 рік на розвиток велоінфраструктури заклали 2 млн гривень. 18 травня 2016 року в управлінні житлово-комунального господарства, благоустрою та екології Тернопільської міської ради відбулася зустріч робочої групи «Першочергові заходи по велоінфраструктурі на 2016 рік», в якій брали участь фахівці управління житлово-комунального господарства, благоустрою та екології ТМР, координатор проекту «ВелоТернопіль» Юрій Суходоляк, депутати, які підтримують розвиток велоінфраструктури — Назар Зелінка та Іван Сороколіт. 7 липня в Ресурсному центрі підтримки ОСББ з питань чистої енергії в місті Тернополі відбулася зустріч експертної ради з питань житлово-комунального господарства, екології та надзвичайних ситуацій, енергозбереження та енергоефективності за участі фахівців управління житлово-комунального господарства, благоустрою та екології, відділу технагляду, координатора проекту «ВелоТернопіль» Юрія Суходоляка та депутата Назара Зелінки. 26 серпня там само відбулася нарада щодо розвитку велоінфраструктури в місті на найближчі роки. 21 вересня 2016 року на засіданні виконавчого комітету Тернопільської міської ради затвердили титульний список капітального ремонту — влаштування велоінфраструктури в місті на 2016 рік, за яким передбачено влаштування велоінфраструктури на вул. Текстильній (в районі пішохідного переходу поблизу Тернопільського обласного центру зайнятості) та в районі пішохідного переходу поблизу фабрики «Нова»; на бульварі Тараса Шевченка (поблизу Українського дому «Перемога») на вул. Білецькій (в районі переходу від ДПІ до парку імені Тараса Шевченка), на вул. М. Грушевського (в районі переходу від ОДА до парку); на вул. Руській (поблизу переходу біля зупинки «Готель Галичина» та поблизу Надставної церкви); на просп. С. Бандери (поблизу переходу від бульвару Д. Галицького до парку Національного Відродження) 1 лютого 2017 року на засіданні виконавчого комітету Тернопільської міської ради затвердили титульний список капітального ремонту — влаштування велоінфраструктури в місті на 2017 рік, за яким передбачено влаштування велоінфраструктури по вул. Руській (на пішохідних переходах перехрестя вулиць Замкова — Руська — Шашкевича); влаштування велоінфраструктури в межах транспортної розв'язки вул. Збаразька — вул. Енергетична — просп. Злуки — вул. Текстильна — вул. Промислова; встановлення велопарковок. Велодоріжки Велосипедні доріжки є: у парку імені Тараса Шевченка від вул. Руської (біля церкви Воздвиження Чесного Хреста вздовж набережної ставу на «Циганку» на Новому світі у парку імені Тараса Шевченка від вул. Замкової до вул. Білецької у гідропарку «Топільче» на центральній алеї від вул. Митрополита Шептицького до дамби на вул. Руській у межах транспортної розв'язки нa вулицях Збаразькій, Енергетичній, Текстильній, Промисловій та проспекті Злуки Велопереїзди на вул. Руській поблизу Надставної церкви на вул. Білецькій поблизу Головного управління державної фіскальної служби Велорозмітка Наразі на велодоріжках активісти нанесли розмітку у вигляді велосипеда за допомогою трафарета. Велопарковки Перші велопарковки в Тернополі почали з'являтися ще наприкінці 2000-их. Нині вони є вже майже в усіх районах міста — встановлені комунальниками в заздалегідь обумовлених місцях, біля шкіл, установ міста, підприємцями біля закладів торгівлі, кав'ярень, барів, ресторанів. Станом на початок жовтня 2017 року міською владою встановлено 114 велопарковок біля місць громадського відпочинку, навчальних закладів та медичних установ. Велознаки Поки що ні велоактивістами, ні державними органами в Тернополі не встановлено жодних велознаків, навіть стандартних 4.12. «Доріжка для велосипедистів» та 4.14. «Доріжка для пішоходів і велосипедистів», 4.22 «Суміжні пішохідна та велосипедна доріжки». Велокомерція магазини «Велокрай» — прокат та продаж велосипедів для особистого користування, вул. Текстильна, 28Б «Вело Сіті» — С. Крушельницької, 43 «РоверБайк» — Митрополита Шептицького, 3 заклади харчування арткав'ярня «Ровер» — Театральний майдан У Тернополі велосипеди використовуються як елементи реклами, зокрема, у рекламних кліпах, а також як рухомі чи нерухомі рекламні конструкції. Велосипеди чи їхні частини використовують як елементи декору інтер'єрів та вітрин закладів. Див. також Велорух у Тернополі Примітки Посилання Концепція розвитку велоінфраструктури Тернополя (мапа) . Веломапа Тернополя (за актуальними даними OpenStreetmap) Веломапа. Велопарковки Тернополя (мапа на Гуглі). Інфраструктура Тернополя Тернопіль
{ "redpajama_set_name": "RedPajamaWikipedia" }
3,122
Q: Matlab regexp tokens - optional tokens and size of the returned array Say we have a collection of files with names which can be either myfilename_ABC (type 1) or myfilename_ABC=XYZ(type 2). Providing that at any one time we supply regexp with an array of filenames of only one of these two types, how do I get it to return an array with either 1 (for type 1) or 2 (for type 2) columns containing the 3-letter combinations? I have tried using 'myfilename_(\w+)=?(\w+)?' but this returns a cell array with 2 columns even for type 1 filenames where the second column contains empty string ''. A: It's possible to do this if you simply create match expressions for each case and use a conditional operator. For example: >> type1 = {'myfilename_ABC'; 'myfilename_DEF'}; >> type2 = {'myfilename_ABC=XYZ'; 'myfilename_DEF=UVW'}; >> matchExpr = 'myfilename_(\w+)=(\w+)|myfilename_(\w+)'; >> results1 = regexp(type1, matchExpr, 'tokens', 'once') results1 = 2×1 cell array {1×1 cell} % Each cell contains 1-by-1 results {1×1 cell} >> results2 = regexp(type2, matchExpr, 'tokens', 'once') results2 = 2×1 cell array {1×2 cell} % Each cell contains 1-by-2 results {1×2 cell} Notice that I placed the longer match expression (myfilename_(\w+)=(\w+)) before the shorter one (myfilename_(\w+)) so that it would attempt to match the longer first. I also used the 'once' option (to match the expression only once per input) to remove an extra layer of cell encapsulation.
{ "redpajama_set_name": "RedPajamaStackExchange" }
7,422
Guntramsdorf osztrák mezőváros Alsó-Ausztria Mödlingi járásában. 2022 januárjában 9144 lakosa volt. Elhelyezkedése Guntramsdorf a tartomány Industrieviertel régiójában fekszik, a Bécsi-medence északnyugati részén, Bécstől délre. Legfontosabb folyóvizei a Mühlbach és a Bécsújhelyi-csatorna. Területének 4,5%-a erdő, 49,4% áll mezőgazdasági művelés alatt. Az önkormányzat 3 települést és településrészt egyesít: Blumensiedlung, Guntransdorf és Neu-Guntramsdorf. A környező önkormányzatok: délnyugatra Gumpoldskirchen, nyugatra Gaaden, északnyugatra Mödling, északra Wiener Neudorf, északkeletre Biedermannsdorf, keletre Laxenburg, délkeletre Münchendorf, délre Möllersdorf. Története A mezőváros területén a korai kelta La Tène-kultúra temetőjét tárták fel 18 sírral. A települést feltehetően az a Guntram gróf alapította, aki tanúként szerepel a regensburgi apátság 859-ből származó adománylevelében. III. Lipót (1095-1136) idejében a falu birtokosa II. Heinrich von Kuenring volt, aki a Heinric de Gundrammisdorf nevet is használta. Vára valószínűleg a későbbi kastély helyén állt (a kastélyból mára csak egy barokk pavilon maradt fenn). 1200 körül Guntramsdorf a Babenbergek mödlingi uradalmához tartozott. 1246-1365 között a Guntramsdorf lovagoké volt, majd többször cserélődtek urai. 1570-ben a zwettli apátság eladta a birtokot a heiligenkreuzi kolostornak. Az 1938-as Anschluss után a környező községek beolvasztásával létrehozták Nagy-Bécset; Guntramsdorf is a főváros 24. kerületéhez került. Függetlenségét 1954-ben nyerte vissza. Szintén 1938-ban jelentős fejlesztésekre került sor, egy új lakónegyed (Neu-Guntramsdorf) építését kezdték el, majd 1941-ben részben ezen a területen (részben Wiener Neudorfban) megalapították a Flugmotorenwerke Ostmark repülőgépmotorgyárat. Az építkezésen kényszermunkásokat és a mauthauseni koncentrációs tábor helyi altáborának mintegy 3 ezer foglyát dolgoztatták. 1945 áprilisának elején három napos harcra került sor a német 6. páncéloshadsereg és a szovjet 3. Ukrán Front csapatai között és Guntramsdorf épületei súlyos károkat szenvedtek, elsősorban a tüzérségi tűztől. Lakosság A guntramsdorfi önkormányzat területén 2022 januárjában 9144 fő élt. A lakosságszám 1923 óta gyarapodó tendenciát mutat. 2020-ban az ittlakók 85,7%-a volt osztrák állampolgár; a külföldiek közül 3,1% a régi (2004 előtti), 4,2% az új EU-tagállamokból érkezett. 5,4% az egykori Jugoszlávia (Szlovénia és Horvátország nélkül) vagy Törökország, 1,6% egyéb országok polgára volt. 2001-ben a lakosok 62,1%-a római katolikusnak, 6,4% evangélikusnak, 3,6% ortodoxnak, 4,7% mohamedánnak, 19,5% pedig felekezeten kívülinek vallotta magát. Ugyanekkor 79 magyar élt a mezővárosban; a legnagyobb nemzetiségi csoportokat a németek (86,3%) mellett a szerbek (3,8%), a törökök (3,6%) és a horvátok (1%) alkották. A népesség változása: Látnivalók a Szt. Jakab-plébániatemplom a szőlőhegyi kápolna az 1713-ban állított pestisoszlop a volt kastély megmaradt kerti pavilonja a helytörténeti múzeum a textilnyomó-múzeum Híres guntramsdorfiak Leopoldine Blahetka (1809-1885) zeneszerző Gabriele Heinisch-Hosek (1961-) politikus, művelődésügyi miniszter Jegyzetek Források A település honlapja 31710 – Guntramsdorf Statistik Austria Fordítás Alsó-Ausztria települései
{ "redpajama_set_name": "RedPajamaWikipedia" }
4,453
Q: Is it possible to dynamically show the title and legend of an Echart for when the download icon is clicked? Echart reference My issue is that we are using custom components for our legend and title but when a user downloads a chart these are missing since they are not in the actual Echart. Is it possible to use the title and legend of the Echart for only when the saveAsImage toolbox feature is clicked?
{ "redpajama_set_name": "RedPajamaStackExchange" }
8,953
<?xml version="1.0" encoding="utf-8"?> <!--This Adobe Flex compiler configuration file was generated by a tool.--> <!--Any modifications you make may be lost.--> <flex-config> <target-player>14.0</target-player> <benchmark>false</benchmark> <static-link-runtime-shared-libraries>true</static-link-runtime-shared-libraries> <compiler> <define append="true"> <name>CONFIG::debug</name> <value>true</value> </define> <define append="true"> <name>CONFIG::release</name> <value>false</value> </define> <define append="true"> <name>CONFIG::timeStamp</name> <value>'2015/4/24'</value> </define> <define append="true"> <name>CONFIG::air</name> <value>false</value> </define> <define append="true"> <name>CONFIG::mobile</name> <value>false</value> </define> <define append="true"> <name>CONFIG::desktop</name> <value>false</value> </define> <verbose-stacktraces>true</verbose-stacktraces> <source-path append="true"> <path-element>C:\Users\zilong.xu\Documents\GitHub\avalon.oniui\fileuploader\flash.src\avalon.oniui.fileuploader\src</path-element> <path-element>C:\Program Files (x86)\FlashDevelop\Library\AS3\frameworks\FlashIDE\fl</path-element> <path-element>C:\Program Files (x86)\FlashDevelop\Library\AS3\classes</path-element> </source-path> </compiler> <file-specs> <path-element>C:\Users\zilong.xu\Documents\GitHub\avalon.oniui\fileuploader\flash.src\avalon.oniui.fileuploader\src\Main.as</path-element> </file-specs> <default-background-color>#FFFFFF</default-background-color> <default-frame-rate>30</default-frame-rate> <default-size> <width>800</width> <height>600</height> </default-size> </flex-config>
{ "redpajama_set_name": "RedPajamaGithub" }
3,574
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="description" content=""> <meta name="author" content=""> <title>ReHarvest</title> <!-- Bootstrap Core CSS --> <link href="vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet"> <!-- Custom Fonts --> <link href="vendor/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css"> <link href='https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css'> <link href='https://fonts.googleapis.com/css?family=Merriweather:400,300,300italic,400italic,700,700italic,900,900italic' rel='stylesheet' type='text/css'> <!-- Plugin CSS --> <link href="vendor/magnific-popup/magnific-popup.css" rel="stylesheet"> <!-- Theme CSS --> <link href="css/creative.css" rel="stylesheet"> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script> <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script> <![endif]--> <style type = "text/css"> .parent { margin-bottom: 15px; padding: 10px; color: #0A416B; clear:both; } .left, .center, .right{ float:left; width:50%; padding:20px; } </style> </head> <link rel="shortcut icon" type="image/x-icon" href="img/favicon.ico" /> <body id="page-top"> <nav id="mainNav" class="navbar navbar-default navbar-fixed-top"> <div class="container-fluid"> <!-- Brand and toggle get grouped for better mobile display --> <div class="navbar-header"> <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1"> <span class="sr-only">Toggle navigation</span> Menu <i class="fa fa-bars"></i> </button> </div> <!-- Collect the nav links, forms, and other content for toggling --> <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1"> <ul class="nav navbar-nav navbar-left"> <li> <img src="img/logo.png" width="13% style="padding-top:5px" style="padding-top:0px" > <ul class="nav navbar-nav navbar-right"> <li> <a class="page-scroll" href="index.html">Home</a> </li> <li> <a class="page-scroll" href="about.html">About</a> </li> <li> <a class="page-scroll" href="volunteer.html">Volunteer</a> </li> <li> <a class="page-scroll" href="partners.html">Partners</a> </li> <li> <a class="page-scroll" href="contact.html">Contact</a> </li> <li> <a class="page-scroll" href="https://medium.com/@foodrescuecanada">Blog</a> </li> </ul> </div> <!-- /.navbar-collapse --> </div> <!-- /.container-fluid --> </nav> <header class="page-contact"> </div> <div class="header-content"> <div class="header-content-inner"> <div class="row"> <br> <h1 id="homeHeading"> Contact Us </h1> <br> <br> <div class="left" align="right"> <h4> <b> FOLLOW US </b></h4> <a href="https://twitter.com/reharvestcanada"> <img src="img/twitter.png" alt="Follow us on Twitter" style=width:40px;height:40px;"> <a/> &nbsp;&nbsp; <a href="https://www.facebook.com/reharvestcanada/"> <img src="img/facebook.png" alt="Follow us on Facebook" style=width:40px;height:40px;"> <a/> </a> </a> <h4> <b> SUBSCRIBE FOR UPDATES </b> </h4> <a href="http://eepurl.com/cOxt5H"> <img src="img/email green.png" style="width:50px;height:50px"> </a> </div> <div class="center" align="left"> <h4> <b> CANADA </b></h4> <a href="mailto:canada@reharvest.ca" target="_top" style="color:white" ><b>canada@reharvest.ca</b></a> <br> <br> <h4> <b> MEDIA INQUIRIES </b></h4> <a href="mailto:media@reharvest.ca" target="_top" style="color:white" ><b>media@reharvest.ca</b></a> <br> <br> <h4> <b> LONDON </b></h4> <a href="mailto:london@reharvest.ca" target="_top" style="color:white" ><b>london@reharvest.ca</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="mailto:partnerslondon@reharvest.ca" target="_top" style="color:white" ><b>partnerslondon@reharvest.ca</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <a href="mailto:canada@reharvest.ca" target="_top" style="color:white" ><b>volunteerlondon@reharvest.ca</b></a> &nbsp;&nbsp;&nbsp;&nbsp; <br> <br> <h4> <b> TORONTO </b></h4> <a href="mailto:toronto@reharvest.ca" target="_top" style="color:white" ><b>toronto@reharvest.ca</b></a> <br> <br> </div> <!-- <iframe src="https://www.facebook.com/plugins/page.php?href=https%3A%2F%2Fwww.facebook.com%2Freharvestcanada%2F&tabs&width=340&height=70&small_header=true&adapt_container_width=true&hide_cover=false&show_facepile=false&appId" width="340" height="70" style="border:none;overflow:hidden" scrolling="no" frameborder="0" allowTransparency="true"></iframe>--> </div> </div> </header> </body> <!-- jQuery --> <script src="vendor/jquery/jquery.min.js"></script> <!-- Bootstrap Core JavaScript --> <script src="vendor/bootstrap/js/bootstrap.min.js"></script> <!-- Plugin JavaScript --> <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js"></script> <script src="vendor/scrollreveal/scrollreveal.min.js"></script> <script src="vendor/magnific-popup/jquery.magnific-popup.min.js"></script> <!-- Theme JavaScript --> <script src="js/creative.min.js"></script> </body> </html>
{ "redpajama_set_name": "RedPajamaGithub" }
9,822