text:
\section{Introduction}

The need for the efficient use of the scarce spectrum in wireless applications has led to significant interest in the analysis of cognitive radio systems which are proposed as systems that have the potential to operate in the licensed spectrum without disturbing the primary users and hence better utilize the spectrum \cite{cognitive}.
Since it is very important for the cognitive users not to interfere with the primary users during their transmission, detection of primary users' activity in the channel is the main concern in cognitive radio research. In \cite{qzhao} and \cite{yunxia} the authors developed an optimal strategy for opportunistic spectrum access by maximally utilizing spectrum opportunities in cognitive radio networks with multiple potential channels. Note that spectrum sensing brings along an essential decrease in the throughput of a system. Realizing this fact, the authors in \cite{Hoang} studied the tradeoff between channel sensing and throughput considering Shannon capacity as the throughput metric. Providing primary users with a sufficient protection against interference, they formulated an optimization problem and found out the optimal sensing time. Motivated by jointly detecting signal energy levels over multiple frequency bands rather than considering one band at a time, Quan \textit{et al.} in \cite{poor} introduced a novel wideband spectrum sensing technique.

An important characteristics of wireless communications is that channel conditions vary over time randomly due to mobility and changing environment  If the channel conditions are not known a priori, training sequences are frequently employed to perform channel estimation. Early studies conducted by Cavers \cite{cavers1} and \cite{cavers2} provided an analytical approach in pilot-assisted transmissions. In \cite{hassibi}, Hassibi and Hochwald  optimized the power and duration of training signals by maximizing a capacity lower bound in multiple-antenna Rayleigh block fading channels. Ohno and Giannakis \cite{giannakis} focused on a capacity lower bound and optimized the spacing of training symbols and training power by employing a noncausal Wiener filter for channel estimation at the receiver in slowly-varying channels. In their studies \cite{faycal}, Abou-Faycal \textit{et al.} employed a causal Kalman filter at the receiver in which all the past pilot symbols are used to estimate the channel coefficients. More recently, we in \cite{icc_akin} jointly optimized the pilot symbol period and power allocation among pilot and data symbols by maximizing the achievable rates in Gauss-Markov fading channels, and in \cite{spawc_akin} we used causal and noncausal Wiener filters at the receiver to estimate the channel coefficients.

In this paper, we study the training-based transmission schemes for cognitive radio systems in time-selective Rayleigh fading channels where cognitive radios are able to transmit data as long as they do not disturb the primary (licensed) users of the channel. We employ causal and noncausal Wiener filters at the receiver to obtain the estimates of the channel fading coefficients. We maximize a capacity lower bound by optimizing the training parameters. Note that even though the treatment is in general, we provide our numerical results for Gauss-Markov channel models.

\vspace{-0.2cm}
\section{Cognitive Channel Model and Channel Sensing}\label{sec:system}
In this paper, we consider a cognitive radio channel model communicating over a time-selective Rayleigh flat fading channel in which a secondary transmitter attempts to send information to a secondary receiver, probably interfering with the primary users. Initially, the secondary users perform channel sensing, and then depending on the primary users' activity, the secondary transmitter selects its transmission power, i.e., when the channel is busy, the average symbol power is $\overline{P}_{1}$, and when the channel is idle, the average symbol power is $\overline{P}_{2}$. For example, if $\overline{P}_{1}=0$, the secondary transmitter stops transmission when the primary users are sensed to be active. During the transmission, the discrete-time channel input-output relation in the $k^{\text{th}}$ symbol duration is given by
\begin{align}\label{input-out1}
&y_{k}=h_{k}x_{1,k}+n_{k}+s_{p,k}\quad k=1,2,\dots
\end{align}
if the primary users are in the channel. On the other hand, if the primary users are idle in the channel, we have
\begin{align}\label{input-out2}
&y_{k}=h_{k}x_{2,k}+n_{k}\quad k=1,2,\dots
\end{align}
In the above equations, $x_{1,k}$ and $x_{2,k}$ are the complex-valued channel inputs, and $y_{k}$ is the complex-valued channel output, and $\{n_{k}\}$ is assumed to be a sequence of independent and identically distributed (i.i.d.) zero mean Gaussian random variables with variance $\sigma_{n}^{2}$. In (\ref{input-out1}) and (\ref{input-out2}), $h_{k}$ denotes the fading coefficient between the secondary transmitter and the secondary receiver, which is assumed to be a zero-mean Gaussian random process with power spectral density $S_{h}(e^{jw})$. It is further assumed that $x_{k}$ is independent of $h_{k}$ and $n_{k}$. While both the secondary transmitter and the secondary receiver know the channel statistics, neither has prior knowledge of instantaneous realizations of the fading coefficients. In (\ref{input-out1}), $s_{p,k}$ represents the sum of the active primary users' faded signals arriving at the secondary receiver. We assume that the bandwidth available in the system is $B$, and the channel is sensed every first $N$ seconds of the block which is $T$ seconds. Note that the discrete-time model is obtained by sampling the received signal every $T_{s}=\frac{1}{B}$ seconds.

If the transmission strategies of the primary users are not known, energy-based detection methods are well-suited for the detection of the activities of primary users. Following the same approach as in \cite{globecom_akin}, we consider a hypothesis testing problem between the noise $n_{k}$ and the signal $s_{p,k}$ in noise. Noting
that there are $NB$ complex symbols in a duration of $N$ seconds, this can mathematically be expressed as follows:
\begin{align}\label{hypothesis}
&\mathcal{H}_{0}\quad : \quad y_{k}=n_{k}, \quad k=1,\dots,NB\\ \nonumber
&\mathcal{H}_{1}\quad : \quad y_{k}=s_{p,k}+n_{k}, \quad k=1,\dots,NB.
\end{align}
Considering the above detection problem, the optimal Neyman-Pearson detector is given by \cite{Poor-book} as
\begin{equation}\label{Neyman-Pearson}
Y=\frac{1}{NB}\sum_{k=0}^{NB-1}|y_{k}|^{2}\gtrless^{\mathcal{H}_{1}}_{\mathcal{H}_{0}}\lambda
\end{equation}
where $\lambda$ is the detection threshold. We assume that $s_{p,k}$ has a circularly symmetric complex Gaussian distribution with zero-mean and variance $\sigma_{s_{p}}^{2}$. Assuming further that $\{s_{p,k}\}$ are i.i.d., we can immediately conclude that the test statistic $Y$ is chi-square distributed with $2NB$ degrees of freedom. In this case, the probabilities of false alarm and detection can be established as follows:
\begin{align}\label{false alarm}
&P_{f}=Pr(Y>\lambda|\mathcal{H}_{0})=1-P\left(\frac{NB\lambda}{\sigma_{n}^{2}},NB\right)\\
&P_{d}=Pr(Y>\lambda|\mathcal{H}_{1})=1-P\left(\frac{NB\lambda}{\sigma_{n}^{2}+\sigma_{s_{p}}^{2}},NB\right) \label{eq:probdetect
\end{align}
where $P(x,a)$ denotes the regularized lower gamma function and is defined as $P(x,a) = \frac{\gamma(x,a)}{\Gamma(a)}$ where $\gamma(x,a)$ is the lower incomplete gamma function and $\Gamma(a)$ is the Gamma function.

In the above hypothesis testing problem, another approach is to consider $Y$ as Gaussian distributed, which is accurate if $NB$ is large \cite{Hoang}. In this case, the detection and false alarm probabilities can be expressed in terms of Gaussian $Q$-functions. We would like to note the rest of the analysis in the paper does not depend on the specific expressions of the false alarm and detection probabilities. However, numerical results are obtained using (\ref{false alarm}) and (\ref{eq:probdetect}).

\vspace{-0.2cm}
\section{Pilot Symbol Assisted Modulation and Channel Estimation at the Receiver}\label{PSAM}
We consider pilot-assisted transmission where periodically inserted pilot symbols, known by both the sender and the receiver, are used to estimate the fading coefficients of the channel. We assume a simple scenario where a pilot symbol is transmitted every $T$ seconds after channel sensing, and $(T-N)B-1$ data symbols following the pilot symbol are transmitted between the secondary transmitter and the secondary receiver. We consider the following average power constraints:
\begin{equation}\label{power constraint 1}
\frac{1}{T}\sum_{k=lTB+NB}^{(l+1)TB-1}|x_{1,k}|^{2}\leq \overline{P}_{1} \quad l=\dots,-2,-1,0,1,2,\dots
\end{equation}
when the channel is detected as busy. On the other hand, when the channel is detected as idle the power constraint becomes
\begin{equation}\label{power constraint 1}
\frac{1}{T}\sum_{k=lTB+NB}^{(l+1)TB-1}|x_{2,k}|^{2}\leq \overline{P}_{2} \quad l=\dots,-2,-1,0,1,2,\dots
\end{equation}
Therefore, the total number of symbols transmitted in one block is $(T-N)B$, and the total energy is limited by $T\overline{P}_{1}$ and $T\overline{P}_{2}$ for the cases when the channel is busy and idle, respectively.

Communication takes place in two phases. In the training phase, the transmitter sends pilot symbols and the receiver estimates the channel coefficients. In this phase, the channel output is given by
\begin{equation}\label{training1}
y_{lTB+NB}=h_{lTB+NB}\sqrt{P_{t}}+n_{lTB+NB}+s_{p,lTB+NB}
\end{equation}
when the channel is busy, and
\begin{equation}\label{training2}
y_{lTB+NB}=h_{lTB+NB}\sqrt{P_{t}}+n_{lTB+NB}
\end{equation}
when the channel is idle. $P_{t}$ is the power allocated to the pilot symbol. In the data transmission phase, data symbols are transmitted. In this phase, input-output relationship can be written as
\begin{equation}\label{datatransmission1}
y_{k}=\widehat{h}_{k}x_{1,k}+\widetilde{h}_{k}x_{1,k}+n_{k}+s_{p,k}\quad lTB+NB<k\leq (l+1)TB-1
\end{equation}
when the channel is busy, and
\begin{equation}\label{datatransmission11}
y_{k}=\widehat{h}_{k}x_{2,k}+\widetilde{h}_{k}x_{2,k}+n_{k}\quad lTB+NB<k\leq (l+1)TB-1
\end{equation}
when the channel is idle where $\widehat{h}_{k}$ and $\widetilde{h}_{k}$ are the estimated channel coefficient and the error in the estimate at sample time $k$, respectively. Note that $\widehat{h}_{k}$ and $\widetilde{h}_{k}$ for $lTB+NB<k\leq (l+1)TB-1$ are uncorrelated zero-mean circularly symmetric complex Gaussian random variables with variances $\sigma_{\widehat{h}_{k}}^{2}$ and $\sigma_{\widetilde{h}_{k}}^{2}$, respectively.

Let us assume that $\mathcal{C}$ is the set of integers, $l$, such that outputs at time samples $lTB+NB$ are used to estimate the channel fading coefficient at time $k$. Due to periodicity, we will consider only the cases where $k=NB,NB+1,\dots,TB-1$. We consider a causal and a non-causal estimation procedure.

\section{Achievable Rates}
Considering the decision of channel sensing and its correctness, we have four possible scenarios:
\begin{enumerate}
  \item Channel is busy, detected as busy,
  \item Channel is busy, detected as idle,
  \item Channel is idle, detected as busy,
  \item Channel is idle, detected as idle.
\end{enumerate}

We assume that a Wiener filter, known as the optimum linear estimator in the mean-square sense, is used at the secondary receiver to estimate the fading coefficients of the channel between the secondary transmitter and the secondary receiver. Since the pilot symbol is sent every $T$ seconds, the channel is sampled every $T$ seconds. Therefore, we have to consider the under-sampled version of the channel's Doppler spectrum given by
\begin{equation}\label{under-sampled}
S_{h,m}(e^{jw})=\frac{1}{TB}\sum_{i=0}^{TB-1}e^{\frac{jm(w-2i\pi}{TB})}S_{h}(e^{\frac{j(w-2i\pi)}{TB}}).
\end{equation}
Also as shown in \cite{spawc_akin}, \cite{Hassibi} and \cite{giannakis}, it can be easily obtained that the channel MMSE for the noncausal Wiener filter at time $lTB+NB+m$ is given by
\begin{equation}\label{noncausal min mean square error}
\sigma_{\widetilde{h}_{TBl+NB+m}}^{2}=\sigma_{h}^{2}-\frac{P_{t}}{2\pi}\int_{-\pi}^{\pi}\frac{|S_{h,m}(e^{jw})|^{2}}{P_{t}S_{h,0}(e^{jw})+\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}}\mathit{dw}.
\end{equation}
where $\rho$ is the activity probability of primary users in the channel. As for the causal Wiener filter, using a similar approach as in in \cite{spawc_akin} and \cite{Hassibi}, MMSE at time $lTB+NB+m$ is given by
\begin{align}\label{causal min mean square error}
\sigma_{\widetilde{h}_{lTB+NB+m}}^{2}=\sigma_{h}^{2}-&\frac{P_{t}}{2\pi}\int_{-\pi}^{\pi}\frac{|S_{h,m}(e^{jw})|^{2}}{P_{t}S_{h,0}(e^{jw})+\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}}\mathit{dw}\nonumber\\+&\frac{1}{2\pi}\int_{-\pi}^{\pi}\frac{P_{t}}{r_{e}}\left|\left\{\frac{S_{h,m}(e^{jw})}{L^{*}(e^{jw})}\right\}_{-}\right|^{2}\mathit{dw}.
\end{align}
where $L^{*}(e^{jw})$ is obtained from the canonical factorization of the channel output's sampled power spectral density at $m=0$, given by
\begin{equation}\label{canon}
P_{t}S_{h,0}(e^{jw})+\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}=r_{e}L(e^{jw})L^{*}(e^{jw}).
\end{equation}
The operators $\{\}_{+}$ and $\{\}_{-}$ give the causal and anti-causal parts of the function to which they are applied, respectively. Using the orthogonality principle we have
\begin{equation}\label{orhogonal}
\sigma_{\widehat{h}_{lTB+NB+m}}^{2}=\sigma_{h}^{2}-\sigma_{\widetilde{h}_{lTB+TB+m}}^{2}
\end{equation}
where $\sigma_{\widehat{h}_{lTB+NB+m}}^{2}$ is the variance of the channel estimate at time $lTB+NB+m$. Similarly as in \cite{spawc_akin}, we regard the errors in (\ref{datatransmission1}) and (\ref{datatransmission11}) as another source of additive noise and assume that
\begin{equation}\label{new noise 1}
w_{1,k}=\widetilde{h}_{k}x_{1,k}+n_{k}+s_{p,k}
\end{equation}
and
\begin{equation}\label{new noise 2}
w_{2,k}=\widetilde{h}_{k}x_{2,k}+n_{k}
\end{equation}
are zero-mean Gaussian noises with variances
\begin{equation}\label{new variance 1}
\sigma_{w_{1,k}}^{2}=\sigma_{\widetilde{h}_{k}}^{2}P_{1,m}+\sigma_{n}^{2}+\sigma_{s_{p,k}}^{2}
\end{equation}
when the channel is busy, and
\begin{equation}\label{new variance 2}
\sigma_{w_{2,k}}^{2}=\sigma_{\widetilde{h}_{k}}^{2}P_{2,m}+\sigma_{n}^{2}
\end{equation}
when the channel is idle, respectively. Considering the errors in (\ref{datatransmission1}) and (\ref{datatransmission11}) and the scenarios given above, we obtain the following lower bound on the channel capacity:

\begin{align}\label{capacity_gh}
&C\geq \frac{1}{T}\sum_{m=1}^{(T-N)B-1}E\bigg\{\rho P_{d}\log\left(1+\frac{P_{1,m}\sigma_{\widehat{h}_{m}}^{2}}{P_{1,m}\sigma_{\widetilde{h}_{m}}^{2}+\sigma_{n}^{2}+\sigma_{s_{p}}^{2}}|\xi|^{2}\right)\nonumber\\
&+\rho(1-P_{d})\log\left(1+\frac{P_{2,m}\sigma_{\widehat{h}_{m}}^{2}}{P_{2,m}\sigma_{\widetilde{h}_{m}}^{2}+\sigma_{n}^{2}+\sigma_{s_{p}}^{2}}|\xi|^{2}\right)\nonumber\\ &+(1-\rho)P_{f}\log\left(1+\frac{P_{1,m}\sigma_{\widehat{h}_{m}}^{2}}{P_{1,m}\sigma_{\widetilde{h}_{m}}^{2}+\sigma_{n}^{2}}|\xi|^{2}\right)\nonumber\\
&+(1-\rho)(1-P_{f})\log\left(1+\frac{P_{2,m}\sigma_{\widehat{h}_{m}}^{2}}{P_{2,m}\sigma_{\widetilde{h}_{m}}^{2}+\sigma_{n}^{2}}|\xi|^{2}\right)
\bigg\}
\end{align}
where $\xi$ is a zero-mean, unit variance, circularly symmetric complex Gaussian random variable, and $P_{1,m}=E\left[|x_{1,lTB+NB+m}|^{2}\right]$ and $P_{2,m}=E\left[|x_{2,lTB+NB+m}|^{2}\right]$ denote the power of $m^{th}$ data symbol after the pilot symbol when the channel is busy and idle, respectively. Note that the error variance $\sigma_{\widetilde{h}_{lTB+NB+m}}^{2}$ depends on $m$ or the location of data symbol with respect to the pilot symbol. However, if the fading is slowly varying and the channel sampled fast enough, we can satisfy $f_{D}\leq\frac{1}{2T}$ or $w_{D}\leq\frac{\pi}{BT}$ where $f_{D}$ is the maximum Doppler frequency and $Bw_{D}=2\pi f_{D}$. In this case, we can see from Nyquist's Theorem that there is no aliasing in the under-sampled version of the channel's Doppler spectrum, and hence $|S_{h,m}(e^{jw})|=|S_{h,0}(e^{jw})|=S_{h}(e^{jw/T/B})/T/B$, for $m\in[1,TB]$ and $-\pi\leq w\leq\pi$. Henceforth, (\ref{noncausal min mean square error}) becomes
\begin{align}\label{noncausal_min mean square error new}
&\sigma_{\widetilde{h}_{lTB+NB+m}}^{2}=\sigma_{h}^{2}-\frac{P_{t}}{2\pi}\int_{-\pi}^{\pi}\frac{|S_{h,m}(e^{jw})|^{2}}{P_{t}S_{h,0}(e^{jw})+\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}}\mathit{dw}\nonumber\\ &=\sigma_{h}^{2}-\frac{P_{t}}{2\pi}\int_{-\frac{\pi}{TB}}^{\frac{\pi}{TB}}\frac{|S_{h}(e^{jw})|^{2}}{P_{t}S_{h}(e^{jw})+TB(\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2})}\mathit{dw}=\sigma_{\widetilde{h}}^{2}
\end{align}
and (\ref{causal min mean square error}) becomes
\begin{align}\label{causal min mean square error new}
&\sigma_{\widetilde{h}_{lTB+NB+m}}^{2}=\sigma_{h}^{2}-\frac{P_{t}}{2\pi}\int_{-\pi}^{\pi}\bigg[\frac{|S_{h,m}(e^{jw})|^{2}}{P_{t}S_{h,0}(e^{jw})+\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}}\nonumber\\ &-\frac{1}{r_{e}}\left|\left\{\frac{S_{h,m}(e^{jw})}{L^{*}(e^{jw})}\right\}_{-}\right|^{2}\bigg]\mathit{dw}\nonumber\\
&=\sigma_{h}^{2}-\frac{P_{t}}{2\pi}\int_{-\frac{\pi}{TB}}^{\frac{\pi}{TB}}\frac{|S_{h}(e^{jw})|^{2}}{P_{t}S_{h}(e^{jw})+TB(\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2})}\mathit{dw}\nonumber\\ &+\frac{P_{t}}{2\pi r_{e}(TB)^{2}}\int_{-\pi}^{\pi}\left|\left\{\frac{S_{h}(e^{\frac{jw}{TB}})}{L^{*}(e^{jw})}\right\}_{-}\right|^{2}\mathit{dw}=\sigma_{\widetilde{h}}^{2},
\end{align}
where
\begin{equation}\label{new F}
\frac{P_{t}S_{h}(e^{\frac{jw}{TB}})}{TB}+\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}=r_{e}L(e^{jw})L^{*}(e^{jw}).
\end{equation}
Therefore, under this assumption, the error variances become independent of $m$. Since the estimate quality is the same for each data symbol regardless of its position with respect to the pilot symbol, uniform power allocation among the data symbols is optimal, and we have
\begin{equation}\nonumber
P_{1,m}=\frac{T\overline{P}_{1}-P_{t}}{(T-N)B-1}=P_{1}
\end{equation}
and
\begin{equation}\nonumber
P_{2,m}=\frac{T\overline{P}_{2}-P_{t}}{(T-N)B-1}=P_{2}.
\end{equation}
Then, (\ref{capacity_gh}) becomes
\begin{align}\label{capacity_ghh}
&C\geq \frac{(T-N)B-1}{T}E\bigg\{\rho P_{d}\log\left(1+\frac{P_{1}\sigma_{\widehat{h}}^{2}}{P_{1}\sigma_{\widetilde{h}}^{2}+\sigma_{n}^{2}+\sigma_{s_{p}}^{2}}|\xi|^{2}\right)\nonumber\\
&+\rho(1-P_{d})\log\left(1+\frac{P_{2}\sigma_{\widehat{h}}^{2}}{P_{2}\sigma_{\widetilde{h}}^{2}+\sigma_{n}^{2}+\sigma_{s_{p}}^{2}}|\xi|^{2}\right)\nonumber\\ &+(1-\rho)P_{f}\log\left(1+\frac{P_{1}\sigma_{\widehat{h}}^{2}}{P_{1}\sigma_{\widetilde{h}}^{2}+\sigma_{n}^{2}}|\xi|^{2}\right)\nonumber\\
&+(1-\rho)(1-P_{f})\log\left(1+\frac{P_{2}\sigma_{\widehat{h}}^{2}}{P_{2}\sigma_{\widetilde{h}}^{2}+\sigma_{n}^{2}}|\xi|^{2}\right)
\bigg\}
\end{align}

\section{Numerical Results in Gauss-Markov Channels}
In this section, we consider Gauss-Markov fading process whose dynamics is given as
\begin{equation}\label{autocorrelation}
h_{k}=\alpha h_{k-1}+z_{k}\quad 0\leq \alpha\leq1\quad k=1,2,3,...
\end{equation}
where $\alpha$ is a parameter that controls the rate of channel variation, and $\{z_{k}\}$ are i.i.d. circular complex Gaussian variables with zero mean and variance $(1-\alpha)\sigma_{h}^{2}$. The power spectral density of this channel is given as
\begin{equation}\label{psd}
S_{h}(e^{jw})=\frac{(1-\alpha^{2})\sigma_{h}^{2}}{1+\alpha^{2}-2\alpha\cos(w)}\quad -\pi\leq w \leq\pi.
\end{equation}
Note that $S_{h}(e^{jw})$ in (\ref{psd}) is not band-limited. Therefore, the condition $w_{D}\leq\frac{\pi}{BT}$ can be satisfied only when $TB=1$ which is not a reliable strategy. On the other hand, if the fading is varying slowly and the value of $\alpha$ is close to 1, the Doppler spectrum $S_{h}(e^{jw})$ decreases sharply for large frequencies and most of the energy is kept around the lower frequencies. We can easily find that the frequency ranges $[-\pi/49,\pi/49]$, $[-\pi/9,\pi/9]$ and $[-\pi/4,\pi/4]$ contain more than $90\%$ of the power when $\alpha=0.99,0.95$ and $0.90$, respectively. Therefore, in these cases the effect of aliasing is negligible.

We can easily obtain the error variance for the noncausal Wiener filter from (\ref{noncausal_min mean square error new}). On the other hand, we have to perform canonical factorization in order to obtain the error variance for the causal Wiener filter in the absence of aliasing. Due to limited space in the paper, we will skip some of the calculation steps. We can express the anti-causal part of (\ref{causal min mean square error new}) as
\begin{equation}\label{anti-causal part}
\left\{\frac{S_{h}\left(e^{\frac{jw}{TB}}\right)}{L^{*}\left(e^{jw}\right)}\right\}_{-}=\frac{\left(1-\alpha^{2}\right)\sigma_{h}^{2}v}{1-\alpha v}\frac{e^{\frac{jw}{TB}}}{\left(1-ve^{\frac{jw}{TB}}\right)}.
\end{equation}
where
\begin{equation}\label{v}
v=\frac{\alpha\left(\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}\right)}{r_{e}}
\end{equation}
\begin{equation}\label{re}
r_{e}=\frac{c+\sqrt{c^{2}-4\alpha^{2}\left(\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2}\right)^{2}}}{2}
\end{equation}
and
\begin{equation}\label{c}
c=\frac{P_{t}}{TB}\left(1-\alpha^{2}\right)\sigma_{h}^{2}+\left(1+\alpha^{2}\right)\left(\sigma_{n}^{2}+\sigma_{s_{p}}^{2}\right)
\end{equation}
Note that
\begin{equation}\label{equation}
L\left(e^{jw}\right)=\frac{1-ve^{-\frac{jw}{TB}}}{1-\alpha e^{-\frac{jw}{TB}}}.
\end{equation}
Using (\ref{anti-causal part}) and (\ref{re}), we can obtain the error variance for the causal Wiener filter as
\begin{align}\label{causal min mean square error en son}
\sigma_{\widetilde{h}}^{2}&=\sigma_{h}^{2}-\frac{P_{t}}{2\pi}\int_{-\frac{\pi}{TB}}^{\frac{\pi}{TB}}\bigg[\frac{|S_{h}(e^{jw})|^{2}}{P_{t}S_{h}(e^{jw})+TB(\sigma_{n}^{2}+\rho\sigma_{s_{p}}^{2})}\nonumber\\ &-\frac{(1-\alpha^{2})^{2}\sigma_{h}^{4}v^{2}}{TBr_{e}(1-\alpha v)^{2}(1+v^{2}-2v\cos(w))}\bigg]\mathit{dw}
\end{align}

Since the primary users are not to be disturbed by the secondary users, when the primary users are active there is an average transmission power threshold on the secondary users which is denoted as $I_{avg}$. Therefore, the power constraint can be expressed as follows
\begin{equation}\label{interference}
P_{t}+\left[(T-N)B-1\right]\left[P_{d}P_{1}+(1-P_{d})P_{2}\right]\leq TI_{avg}
\end{equation}
and the average signal-to-noise (SNR) is
\begin{equation}\label{snr}
SNR = \frac{I_{avg}}{B\sigma_{n}^{2}}.
\end{equation}

\begin{figure}
\begin{center}
\includegraphics[width = \figsize\textwidth]{figure1.eps}
\caption{SNR dB v.s. Data Rate (Nats/Sec) when $B=100$Hz, $T=0.5$sec, $N=0.1$sec, $\alpha=0.99$, $P_{d}=0.91$, and $P_{f}=0.23$.} \label{fig:fig1}
\end{center}
\end{figure}

In Figure \ref{fig:fig1}, employing a causal Wiener filter and a noncausal Wiener filter at the secondary receiver, we show the data rate as a function of SNR (dB) when $B=100$Hz, and $T=0.5$ seconds and $N=0.1$ seconds. We choose $P_{d}=0.91$ and $P_{f}=0.23$ since in reality these are plausible and obtainable values considering the tradeoff between probability of detection and false alarm. Note that when $P_{d}=1$, there will be no constraint on $P_{2}$ and the secondary user can use power as much as its peak value allows. As expected, we obtain higher data rates when we use a noncausal Wiener filter. Note that the difference between the data rates obtained by using a causal and a noncausal Wiener filter is decreasing with the increasing SNR. In Fig. \ref{fig:fig2}, we compare the data rate values for different SNR values, 0 dB and 10 dB, as a function of probability of detection, $P_{d}$, again employing a causal and a noncausal Wiener filter at the secondary receiver. It is clearly seen that the highest data rates are obtained when $P_{d}=0.91$ and $P_{f}=0.23$ for both Wiener filters. Again, as expected the data rates obtained using noncausal Wiener filters are higher than the ones obtained by causal Wiener filters. In Fig. \ref{fig:fig3}, we display the optimal power distribution as a function of probability of detection, $P_{d}$. Recall that $P_{t}$ denotes the power allocated to the pilot symbol, and $P_{1}$ and $P_{2}$ represent the power allocated to the data symbols when the channel is busy and idle, respectively. In Fig. \ref{fig:fig3}, it is easily observed that the power allocated to the data symbols when the channel is busy or idle is decreasing with decreasing $P_{d}$, since the interference power constraint is mainly over $P_{2}$ and there is less transmission with $P_{1}$. Furthermore, the power allocated to the pilot symbol is the highest when $P_{d}=0.91$, where at the same time $P_{f}=0.23$.

\begin{figure}
\begin{center}
\includegraphics[width = \figsize\textwidth]{figure2.eps}
\caption{Data Rate and Probability of False Alarm, $P_{f}$ v.s. Probability of Detection, $P_{d}$ when $B=100$Hz, $T=0.5$sec, $N=0.1$sec, and $\alpha=0.99$.} \label{fig:fig2}
\end{center}
\end{figure}

\begin{figure}
\begin{center}
\includegraphics[width =\figsize\textwidth]{figure3.eps}
\caption{The optimal power distribution among the pilot and data symbols when $B=100$Hz, $T=0.5$sec, $N=0.1$sec, and $\alpha=0.99$.} \label{fig:fig3}
\end{center}
\end{figure}

\section{Conclusion}
We have studied channel sensing, pilot-symbol assisted channel estimation, and achievable rates when causal and noncausal Wiener filters are employed at the secondary receiver. We have obtained achievable rates by finding error variances in both cases, and shown the effects of channel sensing over the achievable rates. Subsequently, we have optimized power allocated to the pilot and data symbols. Finally, we have obtained numerical results in Gauss-Markov channels showing the optimal parameter values. We have compared the performances of causal and noncausal Wiener filters at different SNR, $P_{d}$ and $P_{f}$ values.

redpajama_set_name: RedPajamaArXiv


Hey, No ubers! Welcome to WatchMojo.com and today we'll be counting down our picks for the Top 10 Strongest Pokémon.
For this list, we'll be taking a look at the Pokémon with ridiculous stats both in the anime series and the games. We're not condoning the use of Legendaries in competitive play but damn if these guys aren't powerful.
Don't let its cutesy appearance fool you; Mega Diancie is a force to be reckoned with. In addition to having the ability to absorb light and create diamonds to defend itself, Mega Diancie is also the only Pokémon capable of learning the devastating move Diamond Storm. While also dealing out damage to its opponent, this move also increases Mega Diancie's defensive capabilities as well, a reminder that a good offence is also a good defence.
The Eon Duo of Hoenn are formidable Pokémon in their original forms, but their Mega forms make them just that much more badass. These two dragon/psychic-types also possess incredible intelligence, which allows them to understand human speech and communicate telepathically. They both already possessed some unique attacks; such as Luster Purge for Latios and Mist Ball for Latias – but now they've got the overpowered stats to go with them.
With blood-red spikes, scythe-like blade-arms, and explosive rage which surpasses that of a regular Garchomp – This Mega Form is a whole different level of scary. The nasty dragon/ground-type also possesses increased offensive and defensive stats while in Mega form, these, in addition to its greater physical frame and Sand Force ability, make it an excellent wall breaker for opponents who prefer a more defensive strategy as opposed to offensive.
Tyranitar is one of the most badass Pokémon of all time, so one can only imagine how menacing Mega Tyranitar is. With even more spikes and horns to intimidate its opponents and an even more belligerent attitude, Mega Tyranitar wields even greater offensive and defensive capabilities than its regular form which make it all the more imposing. Strong enough to destroy entire landscapes, Mega Tyranitar is a walking engine of destruction who more than lives up to its pseudo-Legendary status.
Few Pokémon strike terror into their opponents' hearts quite like Kyurem. According to legend Kyurem is actually an extraterrestrial Pokémon, which would perhaps explain its dislike for humans and other Pokémon alike. The use of DNA Splicers alongside Reshiram or Zekrom allows it to become the more destructive White or Black Kyurem respectively. Kyurem is also the only Pokémon who can learn Glaciate, an ice-type attacks that it creates from the freezing energy it generates within its body.
Zygarde is distinguished by having three unique forms instead of evolutions. Despite all maintaining its dragon/ground-type, Zygarde's three forms share few common features aside from their black and green colour scheme. All three possess their own unique abilities and battle tactics, with the Form best equipped to deal with the specific challenge undertaking it. But of course, none of these compare to its 100% form – The result of all its separated cells coming together and forming a total beast.
Commonly known as "The Original One", legend has it that Arceus is responsible for creating the entire Pokémon universe. The Trio Master of the Lake Guardians as well as the Creation Trio, Arceus wields truly awesome power, which has allowed it to serve as Earth's protector for several millennia. Although gentle to those who treat it with kindness, Arceus is also capable of incredible destruction if it feels deceived or betrayed. The only known Pokémon who is able to learn the devastating move Judgment, Arceus' vast power also allows it to stop the flow of time.
Pulling these two apart is just about impossible. As two thirds of the Weather Trio, Kyogre and Groudon both possess immense power when it comes to their respective realms of the sea and land. Once they are in their Primal forms however, these two leviathans become god-like in terms of both power and ferocity. While Primal Groudon creates new bodies of land with every step it takes, Primal Kyogre expands the sea, an appropriate metaphor for their seemingly never-ending conflict.
These two continue to remain neck-and-neck in their private war that has no end in sight.
The final third of the Weather Trio, Rayquaza is the master of the skies and serves as the balancing force that keeps its counterparts Groudon and Kyogre in check. Once in its mighty Mega form, the particles that stream from Rayquaza's jaw allow it to manipulate the air around it and by extension the very weather itself, a handy skill in any situation. In addition to its trademark move Dragon Ascent, Mega Rayquaza can also perform feats of speed, which liken it more to a meteor than a living creature.
As if Mewtwo hadn't already cemented its legend as the most powerful Pokémon of all time, not one but two versions of Mega Mewtwo were created for the sixth generation. Mega Mewtwo X is a larger, more intimidating presence while Mega Mewtwo Y is smaller and possesses astonishing speed. Naturally, both Mega versions boast even greater psychic powers than their original form, which is exemplified in their signature attack Psystrike. These attributes make Mega Mewtwo nigh invincible in a battle of brainpower, and since brains tend to triumph over brawn, Mega Mewtwo is an opponent any trainer should fear in battle.


text:
3rd Annual Private Equity US Fall Forum San Francisco | October 29-30, 2019 Request Agenda
3RD ANNUAL PRIVATE EQUITY US FALL FORUM
The 3rd Annual Private Equity US Fall Forum is the leading West Coast investor-centric meeting for LPs investing in private markets.
The forum brings together 450+ investors, funds, and advisers for a two-day meeting to discuss sectors, due diligence, and private equity investment opportunities in the US and around the world.
The investor focused forum will bring together US and international pension funds, foundations, endowments, fund of funds, family offices, wealth managers, consultants, and sovereign wealth funds interested in direct research on private investment opportunities.
Session topics cover the entire spectrum of private equity investments, from sector specific sessions on venture capital to discussions on global buyout opportunities and round-tables of leading global institutional investors discussing their specific investment appetites.
Orlando Bravo, Founder & Managing Partner, Thoma Bravo
Mr. Bravo is a Founder & Managing Partner at Thoma Bravo. He spearheaded the firm's investment strategy in software, leading Thoma Bravo's rise as one of the most successful private equity firms of the last decade. Orlando has overseen over 200 acquisitions completed by Thoma Bravo, representing over $60 billion in enterprise value. He is recognized as one of the leading private equity investors in the software and technology sectors and was named one of "Eight Buyout Pros to Watch" by Thomson Reuters' Buyouts. He holds an MBA from the Stanford GSB and a law degree from Stanford Law School.
Rich Lawson, Chairman | Chief Executive Officer & Co-Founder, HGGC
Mr. Lawson is the Chairman, Chief Executive Officer and Co-Founder of HGGC. Based in Palo Alto, California, HGGC is a leading private equity firm with over $4.3 billion in cumulative capital commitments and oversees portfolio companies that employ more than 63,000 employees globally. Over its history, HGGC has completed platform investments, add-on acquisitions, recapitalizations and liquidity events with an aggregate transaction value of $20 billion. Mr. Lawson has been involved in all phases of the firm's development since its inception and directs HGGC's firm governance, investment decisions, and investor relations.
Mark Yusko, Founder, Chief Executive Officer & Chief Investment Officer, Morgan Creek Capital
Mr. Yusko is the Founder, CEO and Chief Investment Officer of Morgan Creek Capital Management. He is also the Managing Partner of Morgan Creek Digital Assets. Morgan Creek Capital Management was founded in 2004 and currently manages close to $2 billion in discretionary and non-discretionary assets. Prior to founding Morgan Creek, Mr. Yusko was CIO and Founder of UNC Management Company (UNCMC), the Endowment investment office for the University of North Carolina at Chapel Hill. Before that, he was Senior Investment Director for the University of Notre Dame Investment Office. Mr. Yusko received a BA with Honors from the University of Notre Dame and an MBA in Accounting and Finance from the University of Chicago.
Jean-Pierre Conte, Chairman & Managing Director, Genstar Capital
Mr. Conte is a business leader, philanthropist, policy entrepreneur and Chairman & Managing Director of Genstar Capital, a San Francisco-based private equity firm investing in growth industries including life sciences, financial services, industrial technology and software. A graduate of Colgate University and Harvard Business School, J-P joined Genstar Capital in 1995, and within three years he was leading the firm. Since 1995, the firm has acquired 66 platform companies with $18.3 billion of revenue and 455 strategic add-on acquisitions with another roughly $20 billion in revenue. Under J-P's stewardship, Genstar Capital has grown from $100 million to a fully functioning and distributed partnership with five senior partners who have worked closely together for up to 15 years, 60 professionals and over $17 billion of committed capital.
Richard Kramlich, Chairman Emeritus & Co-Founder, New Enterprise Associates
Mr. Kramlich is Co-Founder of NEA and is currently Chairman of the NEA Management Company. Dick was Managing General Partner of the firm through NEA VII when he turned the reins over to Peter Barris and became a General Partner. He began his venture career in 1969 as a General Partner with Arthur Rock and Co. after nine years in general management as Manager of Financial Planning at the Kroger Co. and in investment management as Executive Vice President at Gardner & Preston Moss Company in Boston. In 1977 Dick was an early investor in Apple Computer for his own account. Since co-founding NEA in 1978, he has been involved in ten companies that have grown from start-up or near start-up stage to companies with market value in excess of $1 billion.
David Layton, Partner, Co-Chief Executive Officer, Head of Private Equity, Partners Group
Mr. Layton is Head of the Private Equity business department & Head of the European Private Equity business unit, based in Denver. He is a member of the Executive Committee and the Global Executive Board. He is furthermore a member of the Global Investment Committee and the Private Equity Directs Investment Committee. Previously, he was the Head of Private Equity in the Americas. He has been with Partners Group since 2005 and has 15 years of industry experience. He has represented Partners Group on the Board of Directors of several portfolio companies. He holds a bachelor's degree in finance from Brigham Young University's Marriott School of Management, USA.
Hans Tung, Managing Partner, GGV Capital
Mr. Tung is a Managing Partner at GGV Capital, focusing on consumer Internet, e-commerce, and IoT investments globally. He is recognized among the top venture capital investors in the world, having been named to the Forbes Midas list seven times from 2013-2019, most recently ranking #7, and #18 on the New York Times/C.B. Insights Top 100 Venture Capitalists list. He has invested in 14 unicorns, each valued at more than $1 billion. Hans was an early investor and former board member of Xiaomi most recently valued at $33 billion—and Musical.ly, which was acquired by Bytedance for around $900 million. He actively works with Airbnb co-founder Nathan Blecharczyk on Airbnb's China strategy, and helped broker Uber co-founder Garrett Camp's first meeting with Didi Chuxing in 2013.
Angela Miller-May Chief Investment Officer Illinois Municipal Retirement Fund (IMRF)
John Beil Managing Director, Private Equity Regents of the University of California
Jane Rowe Executive Managing Director, Equities Ontario Teachers' Pension Plan
Sarah Kim Head of Private Equity & Co-Investments ICONIQ Capital
Jeff Parks Co-Founder & Managing Partner Riverwood Capital
Senia Rapisarda Managing Director HabourVest
Alex Slusky Managing Partner Vector Capital
Josh Stein Managing Partner & Co-Founder Threshold Ventures
Brad Bernstein Managing Partner FTV Capital
Ignacio Giraldo Operating Partner TPG
Bill Sacher Partner and Head of Private Credit Adam Street Partners
Joshua Aaron Chief Technology Officer Hellman & Friedman
Ashutosh Agrawal Managing Director & Investment Committee Member TA Associates
David Smolen Managing Director, General Counel & Chief Compliance Officer GI Partners
Tim Davitt Managing Director, Middle Market Credit Kanye Anderson
Chris Wright Managing Director Crescent Capital

redpajama_set_name: RedPajamaCommonCrawl


I'd like to network with other writers, particularly writers living and working in London, to organise public reading events.
All writers would be welcome to join the group, London based or not, those contracted to a publisher and those independents self publishing like myself. This means poets, journalists, editors, magazine contributors, short story people ie ALL writers, no prejudices!
If you pass this on people can find out more about me at a useful resource for anyone who has multiple on line resources (ie you tube, blogs, articles etc) called 'about me '.


New Delhi: Just over four months after it chalked up a surprising yet convincing win in the general election, the Congress party, which leads the United Progressive Alliance (UPA), seems to be gripped by self-doubt as it gears up for the first real electoral challenge in the upcoming state elections due in Haryana and Maharashtra.
This is in contrast with the past when the central leadership of the Congress was considered supreme, which analysts believe is part of a transformation process of the 125-year-old party. This trend has begun to manifest itself more clearly in recent weeks.
In Uttar Pradesh, where party activities are directly under the control of Congress general secretary Rahul Gandhi, the state unit is divided and engaged in public spat with a sacked treasurer, Deepak Gupta, accusing the president, Rita Bahuguna Joshi, of "diverting funds meant for the election campaign".
On 27 September, a supporter of Jagan Mohan Reddy, son of late Andhra Pradesh chief minister Y.S. Rajasekhara Reddy, vandalized a picture of party president Sonia Gandhi during a protest demanding appointment of the Kadapa member of Parliament as the next chief minister.
On the same day, an order appointing Congress general secretary Digvijay Singh as the coordinator of matters related to Maharashtra election and the party's alliance with the Nationalist Congress Party had to be reissued within an hour adding that defence minister A.K. Antony had been retained on the job.
Besides, there are party leaders, including sitting legislator from Amravati constituency and a minister Sunil Deshmukh, who are openly challenging the leadership's decisions on ticket distribution. Deshmukh has announced his fight against Rajendra Shekhawat, son of President Pratibha Patil, the party's official candidate there.
At least three Congress leaders separately admit that the dissent in the party, especially in state units, is getting "louder". "Although, it shows the democratic nature of our party, it is not so good as we are heading to face crucial elections," a Congress general secretary said on condition of anonymity.
Maharashtra (where Congress-Nationalist Congress Party is in power), Haryana and Arunachal Pradesh, all of which are ruled by the Congress, are going for assembly elections on 13 October. The counting is on 22 October.
Analysts say such developments are new in the Congress, in which the central leadership or party high command is unquestioned. "It never happened under (former prime ministers) Indira Gandhi or Rajiv Gandhi," pointed out Sandeep Shastri, pro vice-chancellor, Jain University and director, International Academy for Creative Teaching at Bangalore.
But Shastri does not believe that such developments weaken the political prowess of Gandhi. Instead, he explains it as a new phenomenon taking place in Indian political parties. "There is a restructuring of power happening in political parties, be it (the) Congress or (the) Bharatiya Janata Party. If I put it rhetorically, centre of political power is not the Centre, but the states."
It is only the second stint of the Congress party's experiment with a coalition at the Centre. In 2004, they were an accidental victor. At that time they had come together with an alliance of 13 parties and the outside support of the Left front to form a government. In the April-May general election, the Congress won 206 seats, the highest since 1991.
The new pressures on the central leadership have a precedent. Ever since Sonia Gandhi took over as the Congress president, there have been various instances of rebellion against her.
In 1999, three veteran Congress leaders, Sharad Pawar, P.A. Sangma and Tariq Anwar raised the banner of rebellion against her saying that Gandhi being a person of foreign origin could not accept the top political posts in the country. Yet, this did not deter their breakaway party, the Nationalist Congress Party, to be part of the UPA since 2004.
Similarly, in 2005, former Kerala chief minister K. Karunakaran questioned her leadership and quit the party only to rejoin it after three years.
Sonia Gandhi took over the reins of India's oldest party in March 1998 and none of her predecessors since 1929—24 of them including the country's first prime minister Jawaharlal Nehru—claim such a long uninterrupted presidency.
The difference this time is that the aggressive state units are not proposing inclement action. Instead, they are seeking to carve out more autonomy for themselves and yet stay within the system.
Jai Mrug, a Mumbai-based political analyst and psephologist, attributes the developments in the states to Gandhi's style of functioning, too.
"An advent of a strong leadership at the state level was never allowed in the Congress earlier. But with Gandhi allowing this, it happened that the party resources, machinery, money and capital concentrated on one or two individuals," he said, indirectly referring to the clout that Y.S.R. Reddy enjoyed.
Congress leaders admitted it was the high command's failure to create a second rung leadership that resulted in the current confusion in Andhra Pradesh. According to Lucknow-based political commentator Indra Bhushan Singh, the dissent notes also reflect the growing demand of cadres to share the power. "Congress is coming out of hibernation. When a political party becomes powerful and there is scope for more power, second and third layer leaders want their share of power."
However, all the analysts agree that the attacks were not directed at Sonia Gandhi or her authority as the party president. "It is an indirect challenge to the central leadership or high command culture of the Congress party. But it would not be at Gandhi. Because recent developments have showed that nobody survived outside the Congress," Mrug said.


Digital Extremes obviously have a penchant for music and the music video for Warframe's new update Fortuna really strikes a chord, even if there will be little singing once you start wreaking havoc across the frozen planes of Venus.
Nevertheless, there ain't a soul alive that can tell me Digital Extremes haven't nailed the look, feel and sound of We All Lift Together just right. There's a peculiar calmness emanating from the chanting of the Solaris United, so full props to developer and whoever ultimately crafted the song.
There's symbolism here aplenty, since you could say the song is about the industrious Solaris just as easily as it could be about Warframe's playerbase, which is one of the most devoted ones around. How many games that launched in 2013 could you say are still around? How many of them have Tennocon?
Digital Extremes and Warframe have raised $200,000 for a charity on the event, their biggest score yet, unveiling a bunch of content that was one of the prime example of catering to your players. As much as one would expect this to be the norm, we all know it's often not the case. But, I digress.
The video takes place in Fortuna, Venusian underground, which is actually a bustling marketplace that Warframers are sure to abuse often. If the interchanging robot and human components haven't already given you a clue, Venus is the place to go for proper customization.
While the Solaris United are toiling away in a frozen hell so as to repay their debt to Corpus, Tenno will be strutting their stuff around on fancy new hoverboards, tricks included. I already see more tricks being added to Warframe down the line, even if it is just a thought at the moment.
Codename: Railjack is still in development, as well as two new warframes, Revenant and Garuda, all of which will be coming before the end of 2018. Railjack on the other hand will give you a new level of ship customization, sharing responsibilities with your crew members along the way.


text:
Anne Hathaway To Play Doomed Prostitute In LES MISERABLES
Hathaway will Dream A Little Dream in the big screen version of the musical.
By Devin Faraci Oct. 18, 2011
On My OwnLes Miserables
And now we know! Deadline says she's officially cast as Fantine, who is totally one of the 99%. She works in a factory and is totally a good girl, but gets fired because a horrible supervisor learns she has a child out of wedlock. Fantine ends up on the streets, sells her beautiful hair and soon becomes a prostitute. Then she dies.
This is just like the first act! See, she worked at the factory owned by Jean Valjean, a fugitive who has become rich (to be played in the film by Hugh Jackman). When Jean, a very good guy, learns about Fantine's fate he vows to take care of her daughter Cosette.
Fantine doesn't really have any of the best songs, in my opinion. Ironically THE best song is the one Hathaway sang at the Oscars, which goes to a secondary character, Eponine. Les Mis is sort of a weird show like that. Fantine does have a great solo, though, and this is that song, which you will surely hear Hathaway belt out:
DARK WATERS Review: The Cost Of Speaking Truth To Power
THE HUSTLE Trailer: DIRTY ROTTEN SCOUNDRELS, The Remix
SERENITY Review: What The Hell Did I Just Watch?
les mis
By Leigh Monson, Nov 26, 2019
Even Todd Haynes at his most conventional is excellent.
In which Anne Hathaway and Rebel Wilson remake a stone-cold classic.
By Leigh Monson, Jan 24, 2019
Sure looks like 2019 has a strong case of ill-advised cinema right out the gate.


You may have seen him as you went flying by on U.S. 85 or U.S. 34: An elderly man in a bright orange hat and yellow reflective vest walking along the side of the road or bent at the waist in the median.
Five or six days a week, 85-year-old Paul Ansley of Kersey makes a small living picking up aluminum cans and other bits and pieces of metal. He can make anywhere from $2 to $40 a day filling buckets with metal.
As a young man during the Great Depression, Ansley drove cattle for 50 cents a day. He couldn't afford lunch, but a neighbor of the ranch he worked at would let him pull peaches and plums from the trees along the road.
Ansley's father taught him the value of hard work, telling him, "Don't ask for nothing." He's retired from ranching, but Ansley still heads out for a workweek of cleaning up metal from the roadside.
Looking at a pile of garbage dumped beside the highway, Ansley says, "If I knew who did this I'd pack it up and take it to them." He says that it would be better if more people went and picked up trash along the roadways.


large patches set cat style, iron-on patches, Flickli - spcial reinforced cotton patches perfect suitable as knee patches!
These large patchesfor kids in the set in the retro shape with cat style! The 2 big strap patches with cat are backed with a quality iron-on film. So, mounting this cotton patches is not a problem! So does mend with this stylish retro cats pants patch really fun! The tear-resistant cotton patches are also perfectly suitable as a knee patches for children. The delivery of the patch with the cat is carried out in a package with one detailed ironing instructions per order. In no time at such a simple children's clothes can be ironed easily by simply repairing and decorating. Even high-quality clothing can be used so much longer and be additionally upgraded by the strap patches xl with kitten.
The offer is for one set iron-on patches large with cat style (fig. 1).


Okay, you have always added the most amazing books to my list of what I should read next BUT.... RJ, can you find me the time... please? I love all your recommendations. I try to share them with people at work since there are a lot of readers in my workplace so I know some of them are enjoying this list too.
I love the trailers and the cover for The Dead...is fantastic. Makes me want to pick it up just by looking at it. Thanks for sharing Ricki.
I have been so very busy this week reading and joining in on new release book parties. That is what I posted about, if you'd like to come visit.
It sounds as if I have to add another author to my list! Thanks for the great recommendation.
I think I will look into Jio novels. I like the premises.
My reading? Just finished "Unspoken" by Sarah Rees Brennan. Great YA book!
I love Jio's books...I have read them all...and while I enjoyed The Last Camellia, the others (especially Morning Glory) I enjoyed even more.
Seriously, though....Lake Union is gorgeous and I would cover up murder to live on one of those boat houses.
Thanks for sharing these, and that new Flavia de Luce! YAY!
Thank you for introducing me to Sarah Jio. I'll look for her books. The Dead in Their Vaulted Arches sounds good too. Lots of enticing choices on your blog post today!
I'm desperate to get the next Flavia book. I adore that kiddo. That houseboat is just amazing.
Yep, the house boat in Seattle made me think of Tom Hanks. :-) I've only read one Sarah Jio novel - Blackberry Winter. It was amazing! I have a copy of The Last Camilla, but my mom snatched it from me before I could read it. She loves Jio's flower books!
I have had so little time to read. I am still trying to finish Songs of Willow Frost.
I have never read anything by her and These two books sound great! I am definitely going to be putting these on my wish list. Thanks for being such a wonderful host and great blog friend!
I haven't read any books by Jio...I'll add her to my list to read! I need to get back into doing book reviews! I did a car review today but don't think you want me to link that! hahaha! Sweet hugs!
I haven't read a book for years but if I were to read one it would be Morning Glory. It sounds fabulous! I am looking forward to the recipe you make from the book. Hope you are well and having a lovely weekend!
I love camellias too, Ricki Jill. They are such a pretty flower. They look a bit like the rose to me.
Hope January is treating you good.


text:
SN 2010hi – supernowa odkryta 1 września 2010 roku w galaktyce NGC 6621. W momencie odkrycia miała maksymalną jasność 18,00.

Przypisy

Gwiazdozbiór Smoka
Supernowe zaobserwowane w 2010 roku

redpajama_set_name: RedPajamaWikipedia


InlineEditBox: allow the client to choose whether to match the geometry of the original field.
Ideally, the InlineEditBox edit mode elements will match the width and height of the original field. There are certainly conditions where this won't be desirable (you don't want edit fields running off the page) so it should be the client's choice based on the unique situations they are designed for.
Allow the client to choose whether to match the geometry of the original field. → InlineEditBox: Allow the client to choose whether to match the geometry of the original field.
InlineEditBox: Allow the client to choose whether to match the geometry of the original field. → InlineEditBox: allow the client to choose whether to match the geometry of the original field.
I can't imagine when an edit field would run off the page, since the view version presumably doesn't run off the page, but I guess we could obey an explicit style setting in the editorParams attribute.
But can you give some examples where this would be needed?
Oh, there's a width parameter to control the editor's width, so this is already partially supported. See also #10758.
Given that no one has shown interest in creating a patch in the past 5 years, I'm closing this as patchwelcome.


* Please remember to return your completed Commitment Cards soon so that we may compile our lists of responses and ask our MinistryLeaders to contact you in a timely manner.
* Saint Mary Volunteer Appreciation Dinner is Thursday, October 23: Any adults who have volunteered in any way at church or school in the past year are invited: RSVP and make plans to come. This is the 8th annual event when the parish staff gets to serve you, the volunteers! Come for an evening of dinner, dancing to Fredericksburg's own Blue Tips Rhythm Review and a lot of fun.


text:
Tribal Resistance Gains Momentum Against Ganjal Moran Dam in MP
Located in the Narmada valley, it will submerge at least 10 villages inhabited by the tribal Korku community
Despite the change of guard in Madhya Pradesh, development projects that threaten the lives of the indigenous population of the state are still going strong. In its latest attempt, the Congress government has shown a green flag to the Ganjal Moran dam project.
The mammoth dam project is estimated to cost the state government approximately Rs. 2,813 crores, with a command area of approximately 52,000 hectares to be irrigated by the twin dams at Morand and Ganjal. The proposed project is aimed at benefiting total 4,617 ha of land in 28 villages of Hoshangabad, 17,678 ha of land in 62 villages of Harsud tehsil in district Khandwa, and 29,910 ha of agriculture land in 121 villages of Harda, Khirkiya, Sirali and Rahatgaon tehsils of Harda district. The proposed project and initiation of surveys for land acquisition have led the Korku Adivasis to fear for their future.
"There is fear, anxiety and uncertainty that has gripped us, we have seen so many people go from having homes and livelihoods to have to wander on the streets and start a life of a labourer – all in the name of development. We can't let this happen to us," said Harish Sahu of the Synergy group, who is a part of the mobilisation efforts by the tribals against corporate interests in the region. The Korku Adivasis on the ground are organising themselves in small collectives to spread awareness about the repercussions of the project. Reportedly, at least 10 villages are to be submerged following the construction of the dam, with no concrete measures being taken to rehabilitate the tribal population.
Harish said, "On the ground, we are now seeing that the tribals are forming small collectives to reach out to the community and give a message of unity. We are all uniting against the collector right now and massive protests over this issue are being planned."
The proposed project will be located at the Morand river in Halda district. Approximately, 4,000 acres of land is to be affected in the Hoshanabad district, spanning over 28 villages, 62 villages in the Khandwa Harood district. Over 100 villages covering about 29,000 hectares in Harda, Sirali and Khirkiya too will face repercussions if the project is implemented successfully.
The project will be constructed in three phases. Construction of Morand dam under first phase and construction of canal under second phase will take place. Both the canals coming out from the dam will be in the form of underground pipes which will provide irrigation facility through underground canal system. Construction of Ganjal dam is proposed to take place in third phase.
*This is a developing story.
First published in Newsclick.


Chart and art ~ Flow Chart Applowchart Product Life Cycle Process Goodor Macree Trial Pc Business And Art Apaflowchart Patienten Annehmen Arzt Flow Chart App. Flowchart Apaflowchart Patienten Annehmen Arzt. Flowchart Patienten Annehmen Arztflowchart App. Flowchart App.
Flow chart app explore visio now windows phone toohart apaflowchart apa patienten annehmen arzt arztflowchart. Flow chart app and art new git flowchart so you ve made mess of things learn pics apaflowchartenten annehmen arzt. Flow chart app awesome myers petency based id flowchart photograph of patienten. Flow chart app which oauth grant should i use flowchart apaflowchart apa patienten annehmen arzt.


text:
        <?php $this->renderPartial('/installer/sidebar_view', compact('progressValue', 'classesForStep')); ?>

        <?php echo CHtml::beginForm($this->createUrl('installer/database'), 'post', array('class' => 'form-horizontal')); ?>

<?php echo $title; ?>

<?php echo $descp; ?>

            <?php echo CHtml::errorSummary($model, null, null, array('class' => 'errors')); ?>

        <?php eT("Note: All fields marked with (*) are required."); ?>
        <fieldset>
            <legend><?php eT("Database configuration"); ?></legend>
            <?php
                $rows = array();
                $rows[] = array(
                    'label' => CHtml::activeLabelEx($model, 'dbtype', array('class' => 'control-label', 'label' => gT("Database type"))),
                    'control' => CHtml::activeDropDownList($model, 'dbtype', $model->supported_db_types, array('required' => 'required', 'autofocus' => 'autofocus')),
                    'description' => gT("The type of your database management system")
                );
                $rows[] = array(
                    'label' => CHtml::activeLabelEx($model, 'dblocation', array('class' => 'control-label', 'label' => gT("Database location"))),
                    'control' => CHtml::activeTextField($model, 'dblocation', array('required' => 'required')),
                    'description' => gT('Set this to the IP/net location of your database server. In most cases "localhost" will work. You can force Unix socket with complete socket path.').' '.gT('If your database is using a custom port attach it using a colon. Example: db.host.com:5431')
                );
                $rows[] = array(
                    'label' => CHtml::activeLabelEx($model, 'dbuser', array('class' => 'control-label', 'label' => gT("Database user"))),
                    'control' => CHtml::activeTextField($model, 'dbuser', array('required' => 'required','autocomplete'=>'off')),
                    'description' => gT('Your database server user name. In most cases "root" will work.')
                );
                $rows[] = array(
                    'label' => CHtml::activeLabelEx($model, 'dbpwd', array('class' => 'control-label', 'label' => gT("Database password"))),
                    'control' => CHtml::activePasswordField($model, 'dbpwd',array('autocomplete'=>'off')),
                    'description' => gT("Your database server password.")
                );
                $rows[] = array(
                    'label' => CHtml::activeLabelEx($model, 'dbname', array('class' => 'control-label', 'label' => gT("Database name"))),
                    'control' => CHtml::activeTextField($model, 'dbname', array('required' => 'required','autocomplete'=>'off')),
                    'description' => gT("If the database does not yet exist it will be created (make sure your database user has the necessary permissions). In contrast, if there are existing LimeSurvey tables in that database they will be upgraded automatically after installation.")
                );

                $rows[] = array(
                    'label' => CHtml::activeLabelEx($model, 'dbprefix', array('class' => 'control-label', 'label' => gT("Table prefix"))),
                    'control' => CHtml::activeTextField($model, 'dbprefix', array('value' => 'lime_','autocomplete'=>'off')),
                    'description' => gT('If your database is shared, recommended prefix is "lime_" else you can leave this setting blank.')
                );

            foreach ($rows as $row)
            {
                echo CHtml::openTag('div', array('class' => 'control-group'));
                    echo $row['label'];
                    echo CHtml::tag('div', array('class' => 'controls'), $row['control'] . CHtml::tag('div', array('class' => 'description-field'), $row['description']));
                echo CHtml::closeTag('div');
            }

            ?>
        </fieldset>

                <input class="btn" type="button" value="<?php eT('Previous'); ?>" onclick="javascript: window.open('<?php echo $this->createUrl("installer/precheck"); ?>', '_top')" />

                <?php echo CHtml::submitButton(gT("Next"), array('class' => 'btn')); ?>

        <?php echo CHtml::endForm(); ?>

redpajama_set_name: RedPajamaGithub


text:
Q: Set, not list in Lisp world? In set theory, we have {x, y, z}, which is the same as {z, y, x} which is the same as ... {y, x, z}, {z, x, y} ... Now, in Lisp (Scheme etc.) a list doesn't allow such juxtaposition. Order matters. Question: Is there a Lisp/Scheme equivalent to an order-doesn't-matter set?
Just guessing, I might simply construct a list, say (x y z), then have some sort of member? i.e., Are you a member of? mechanism.
...I bet I'm not the only person who's wondered about this...

A: If you talking about common lisp, it has a bunch of functions, which operate on lists like if they were sets:
(member 'b '(a b c d))
=> (B C)
You can also use member_if. There are also some other functions for set operations:
(union '(a b c) '(f a d))
=> (C B F A D)
(intersection '(a b c) '(f a d))
=> (A)
(set-difference '(a b c) '(b c d))
=> (A)

redpajama_set_name: RedPajamaStackExchange


The roadway infrastructure and environment can have a significant effect on a driver's ability to perceive and react to hazards. Infrastructure planning, design, construction, and maintenance involve many levels of activities and disciplines. We analyze the transportation infrastructure to evaluate how the human, vehicle, and environment interact to determine incident causation and prevention.


text:
using System;
using System.Collections;
using System.Collections.Generic;
using System.Globalization;
using System.Runtime.InteropServices;
using System.Runtime.Serialization;
using System.Numerics;
using System.Linq;
using GlmSharp.Swizzle;

// ReSharper disable InconsistentNaming

namespace GlmSharp
{

    /// <summary>
    /// A quaternion of type int.
    /// </summary>
    [Serializable]
    [DataContract]
    [StructLayout(LayoutKind.Sequential)]
    public struct iquat : IReadOnlyList<int>, IEquatable<iquat>
    {

        #region Fields

        /// <summary>
        /// x-component
        /// </summary>
        [DataMember]
        public int x;

        /// <summary>
        /// y-component
        /// </summary>
        [DataMember]
        public int y;

        /// <summary>
        /// z-component
        /// </summary>
        [DataMember]
        public int z;

        /// <summary>
        /// w-component
        /// </summary>
        [DataMember]
        public int w;

        #endregion

        #region Constructors

        /// <summary>
        /// Component-wise constructor
        /// </summary>
        public iquat(int x, int y, int z, int w)
        {
            this.x = x;
            this.y = y;
            this.z = z;
            this.w = w;
        }

        /// <summary>
        /// all-same-value constructor
        /// </summary>
        public iquat(int v)
        {
            this.x = v;
            this.y = v;
            this.z = v;
            this.w = v;
        }

        /// <summary>
        /// copy constructor
        /// </summary>
        public iquat(iquat q)
        {
            this.x = q.x;
            this.y = q.y;
            this.z = q.z;
            this.w = q.w;
        }

        /// <summary>
        /// vector-and-scalar constructor (CAUTION: not angle-axis, use FromAngleAxis instead)
        /// </summary>
        public iquat(ivec3 v, int s)
        {
            this.x = v.x;
            this.y = v.y;
            this.z = v.z;
            this.w = s;
        }

        #endregion

        #region Implicit Operators

        /// <summary>
        /// Implicitly converts this to a lquat.
        /// </summary>
        public static implicit operator lquat(iquat v) => new lquat((long)v.x, (long)v.y, (long)v.z, (long)v.w);

        /// <summary>
        /// Implicitly converts this to a quat.
        /// </summary>
        public static implicit operator quat(iquat v) => new quat((float)v.x, (float)v.y, (float)v.z, (float)v.w);

        /// <summary>
        /// Implicitly converts this to a hquat.
        /// </summary>
        public static implicit operator hquat(iquat v) => new hquat((Half)v.x, (Half)v.y, (Half)v.z, (Half)v.w);

        /// <summary>
        /// Implicitly converts this to a dquat.
        /// </summary>
        public static implicit operator dquat(iquat v) => new dquat((double)v.x, (double)v.y, (double)v.z, (double)v.w);

        /// <summary>
        /// Implicitly converts this to a decquat.
        /// </summary>
        public static implicit operator decquat(iquat v) => new decquat((decimal)v.x, (decimal)v.y, (decimal)v.z, (decimal)v.w);

        /// <summary>
        /// Implicitly converts this to a cquat.
        /// </summary>
        public static implicit operator cquat(iquat v) => new cquat((Complex)v.x, (Complex)v.y, (Complex)v.z, (Complex)v.w);

        #endregion

        #region Explicit Operators

        /// <summary>
        /// Explicitly converts this to a ivec4.
        /// </summary>
        public static explicit operator ivec4(iquat v) => new ivec4((int)v.x, (int)v.y, (int)v.z, (int)v.w);

        /// <summary>
        /// Explicitly converts this to a uvec4.
        /// </summary>
        public static explicit operator uvec4(iquat v) => new uvec4((uint)v.x, (uint)v.y, (uint)v.z, (uint)v.w);

        /// <summary>
        /// Explicitly converts this to a uquat.
        /// </summary>
        public static explicit operator uquat(iquat v) => new uquat((uint)v.x, (uint)v.y, (uint)v.z, (uint)v.w);

        /// <summary>
        /// Explicitly converts this to a vec4.
        /// </summary>
        public static explicit operator vec4(iquat v) => new vec4((float)v.x, (float)v.y, (float)v.z, (float)v.w);

        /// <summary>
        /// Explicitly converts this to a hvec4.
        /// </summary>
        public static explicit operator hvec4(iquat v) => new hvec4((Half)v.x, (Half)v.y, (Half)v.z, (Half)v.w);

        /// <summary>
        /// Explicitly converts this to a dvec4.
        /// </summary>
        public static explicit operator dvec4(iquat v) => new dvec4((double)v.x, (double)v.y, (double)v.z, (double)v.w);

        /// <summary>
        /// Explicitly converts this to a decvec4.
        /// </summary>
        public static explicit operator decvec4(iquat v) => new decvec4((decimal)v.x, (decimal)v.y, (decimal)v.z, (decimal)v.w);

        /// <summary>
        /// Explicitly converts this to a cvec4.
        /// </summary>
        public static explicit operator cvec4(iquat v) => new cvec4((Complex)v.x, (Complex)v.y, (Complex)v.z, (Complex)v.w);

        /// <summary>
        /// Explicitly converts this to a lvec4.
        /// </summary>
        public static explicit operator lvec4(iquat v) => new lvec4((long)v.x, (long)v.y, (long)v.z, (long)v.w);

        /// <summary>
        /// Explicitly converts this to a bvec4.
        /// </summary>
        public static explicit operator bvec4(iquat v) => new bvec4(v.x != 0, v.y != 0, v.z != 0, v.w != 0);

        /// <summary>
        /// Explicitly converts this to a bquat.
        /// </summary>
        public static explicit operator bquat(iquat v) => new bquat(v.x != 0, v.y != 0, v.z != 0, v.w != 0);

        #endregion

        #region Indexer

        /// <summary>
        /// Gets/Sets a specific indexed component (a bit slower than direct access).
        /// </summary>
        public int this[int index]
        {
            get
            {
                switch (index)
                {
                    case 0: return x;
                    case 1: return y;
                    case 2: return z;
                    case 3: return w;
                    default: throw new ArgumentOutOfRangeException("index");
                }
            }
            set
            {
                switch (index)
                {
                    case 0: x = value; break;
                    case 1: y = value; break;
                    case 2: z = value; break;
                    case 3: w = value; break;
                    default: throw new ArgumentOutOfRangeException("index");
                }
            }
        }

        #endregion

        #region Properties

        /// <summary>
        /// Returns an array with all values
        /// </summary>
        public int[] Values => new[] { x, y, z, w };

        /// <summary>
        /// Returns the number of components (4).
        /// </summary>
        public int Count => 4;

        /// <summary>
        /// Returns the euclidean length of this quaternion.
        /// </summary>
        public float Length => (float)Math.Sqrt(((x*x + y*y) + (z*z + w*w)));

        /// <summary>
        /// Returns the squared euclidean length of this quaternion.
        /// </summary>
        public int LengthSqr => ((x*x + y*y) + (z*z + w*w));

        /// <summary>
        /// Returns the conjugated quaternion
        /// </summary>
        public iquat Conjugate => new iquat(-x, -y, -z, w);

        /// <summary>
        /// Returns the inverse quaternion
        /// </summary>
        public iquat Inverse => Conjugate / LengthSqr;

        #endregion

        #region Static Properties

        /// <summary>
        /// Predefined all-zero quaternion
        /// </summary>
        public static iquat Zero { get; } = new iquat(0, 0, 0, 0);

        /// <summary>
        /// Predefined all-ones quaternion
        /// </summary>
        public static iquat Ones { get; } = new iquat(1, 1, 1, 1);

        /// <summary>
        /// Predefined identity quaternion
        /// </summary>
        public static iquat Identity { get; } = new iquat(0, 0, 0, 1);

        /// <summary>
        /// Predefined unit-X quaternion
        /// </summary>
        public static iquat UnitX { get; } = new iquat(1, 0, 0, 0);

        /// <summary>
        /// Predefined unit-Y quaternion
        /// </summary>
        public static iquat UnitY { get; } = new iquat(0, 1, 0, 0);

        /// <summary>
        /// Predefined unit-Z quaternion
        /// </summary>
        public static iquat UnitZ { get; } = new iquat(0, 0, 1, 0);

        /// <summary>
        /// Predefined unit-W quaternion
        /// </summary>
        public static iquat UnitW { get; } = new iquat(0, 0, 0, 1);

        /// <summary>
        /// Predefined all-MaxValue quaternion
        /// </summary>
        public static iquat MaxValue { get; } = new iquat(int.MaxValue, int.MaxValue, int.MaxValue, int.MaxValue);

        /// <summary>
        /// Predefined all-MinValue quaternion
        /// </summary>
        public static iquat MinValue { get; } = new iquat(int.MinValue, int.MinValue, int.MinValue, int.MinValue);

        #endregion

        #region Operators

        /// <summary>
        /// Returns true iff this equals rhs component-wise.
        /// </summary>
        public static bool operator==(iquat lhs, iquat rhs) => lhs.Equals(rhs);

        /// <summary>
        /// Returns true iff this does not equal rhs (component-wise).
        /// </summary>
        public static bool operator!=(iquat lhs, iquat rhs) => !lhs.Equals(rhs);

        /// <summary>
        /// Returns proper multiplication of two quaternions.
        /// </summary>
        public static iquat operator*(iquat p, iquat q) => new iquat(p.w * q.x + p.x * q.w + p.y * q.z - p.z * q.y, p.w * q.y + p.y * q.w + p.z * q.x - p.x * q.z, p.w * q.z + p.z * q.w + p.x * q.y - p.y * q.x, p.w * q.w - p.x * q.x - p.y * q.y - p.z * q.z);

        /// <summary>
        /// Returns a vector rotated by the quaternion.
        /// </summary>
        public static ivec3 operator*(iquat q, ivec3 v)
        {
            var qv = new ivec3(q.x, q.y, q.z);
            var uv = ivec3.Cross(qv, v);
            var uuv = ivec3.Cross(qv, uv);
            return v + ((uv * q.w) + uuv) * 2;
        }

        /// <summary>
        /// Returns a vector rotated by the quaternion (preserves v.w).
        /// </summary>
        public static ivec4 operator*(iquat q, ivec4 v) => new ivec4(q * new ivec3(v), v.w);

        /// <summary>
        /// Returns a vector rotated by the inverted quaternion.
        /// </summary>
        public static ivec3 operator*(ivec3 v, iquat q) => q.Inverse * v;

        /// <summary>
        /// Returns a vector rotated by the inverted quaternion (preserves v.w).
        /// </summary>
        public static ivec4 operator*(ivec4 v, iquat q) => q.Inverse * v;

        #endregion

        #region Functions

        /// <summary>
        /// Returns an enumerator that iterates through all components.
        /// </summary>
        public IEnumerator<int> GetEnumerator()
        {
            yield return x;
            yield return y;
            yield return z;
            yield return w;
        }

        /// <summary>
        /// Returns an enumerator that iterates through all components.
        /// </summary>
        IEnumerator IEnumerable.GetEnumerator() => GetEnumerator();

        /// <summary>
        /// Returns a string representation of this quaternion using ', ' as a seperator.
        /// </summary>
        public override string ToString() => ToString(", ");

        /// <summary>
        /// Returns a string representation of this quaternion using a provided seperator.
        /// </summary>
        public string ToString(string sep) => ((x + sep + y) + sep + (z + sep + w));

        /// <summary>
        /// Returns a string representation of this quaternion using a provided seperator and a format provider for each component.
        /// </summary>
        public string ToString(string sep, IFormatProvider provider) => ((x.ToString(provider) + sep + y.ToString(provider)) + sep + (z.ToString(provider) + sep + w.ToString(provider)));

        /// <summary>
        /// Returns a string representation of this quaternion using a provided seperator and a format for each component.
        /// </summary>
        public string ToString(string sep, string format) => ((x.ToString(format) + sep + y.ToString(format)) + sep + (z.ToString(format) + sep + w.ToString(format)));

        /// <summary>
        /// Returns a string representation of this quaternion using a provided seperator and a format and format provider for each component.
        /// </summary>
        public string ToString(string sep, string format, IFormatProvider provider) => ((x.ToString(format, provider) + sep + y.ToString(format, provider)) + sep + (z.ToString(format, provider) + sep + w.ToString(format, provider)));

        /// <summary>
        /// Returns true iff this equals rhs component-wise.
        /// </summary>
        public bool Equals(iquat rhs) => ((x.Equals(rhs.x) && y.Equals(rhs.y)) && (z.Equals(rhs.z) && w.Equals(rhs.w)));

        /// <summary>
        /// Returns true iff this equals rhs type- and component-wise.
        /// </summary>
        public override bool Equals(object obj)
        {
            if (ReferenceEquals(null, obj)) return false;
            return obj is iquat && Equals((iquat) obj);
        }

        /// <summary>
        /// Returns a hash code for this instance.
        /// </summary>
        public override int GetHashCode()
        {
            unchecked
            {
                return ((((((x.GetHashCode()) * 397) ^ y.GetHashCode()) * 397) ^ z.GetHashCode()) * 397) ^ w.GetHashCode();
            }
        }

        #endregion

        #region Static Functions

        /// <summary>
        /// Converts the string representation of the quaternion into a quaternion representation (using ', ' as a separator).
        /// </summary>
        public static iquat Parse(string s) => Parse(s, ", ");

        /// <summary>
        /// Converts the string representation of the quaternion into a quaternion representation (using a designated separator).
        /// </summary>
        public static iquat Parse(string s, string sep)
        {
            var kvp = s.Split(new[] { sep }, StringSplitOptions.None);
            if (kvp.Length != 4) throw new FormatException("input has not exactly 4 parts");
            return new iquat(int.Parse(kvp[0].Trim()), int.Parse(kvp[1].Trim()), int.Parse(kvp[2].Trim()), int.Parse(kvp[3].Trim()));
        }

        /// <summary>
        /// Converts the string representation of the quaternion into a quaternion representation (using a designated separator and a type provider).
        /// </summary>
        public static iquat Parse(string s, string sep, IFormatProvider provider)
        {
            var kvp = s.Split(new[] { sep }, StringSplitOptions.None);
            if (kvp.Length != 4) throw new FormatException("input has not exactly 4 parts");
            return new iquat(int.Parse(kvp[0].Trim(), provider), int.Parse(kvp[1].Trim(), provider), int.Parse(kvp[2].Trim(), provider), int.Parse(kvp[3].Trim(), provider));
        }

        /// <summary>
        /// Converts the string representation of the quaternion into a quaternion representation (using a designated separator and a number style).
        /// </summary>
        public static iquat Parse(string s, string sep, NumberStyles style)
        {
            var kvp = s.Split(new[] { sep }, StringSplitOptions.None);
            if (kvp.Length != 4) throw new FormatException("input has not exactly 4 parts");
            return new iquat(int.Parse(kvp[0].Trim(), style), int.Parse(kvp[1].Trim(), style), int.Parse(kvp[2].Trim(), style), int.Parse(kvp[3].Trim(), style));
        }

        /// <summary>
        /// Converts the string representation of the quaternion into a quaternion representation (using a designated separator and a number style and a format provider).
        /// </summary>
        public static iquat Parse(string s, string sep, NumberStyles style, IFormatProvider provider)
        {
            var kvp = s.Split(new[] { sep }, StringSplitOptions.None);
            if (kvp.Length != 4) throw new FormatException("input has not exactly 4 parts");
            return new iquat(int.Parse(kvp[0].Trim(), style, provider), int.Parse(kvp[1].Trim(), style, provider), int.Parse(kvp[2].Trim(), style, provider), int.Parse(kvp[3].Trim(), style, provider));
        }

        /// <summary>
        /// Tries to convert the string representation of the quaternion into a quaternion representation (using ', ' as a separator), returns false if string was invalid.
        /// </summary>
        public static bool TryParse(string s, out iquat result) => TryParse(s, ", ", out result);

        /// <summary>
        /// Tries to convert the string representation of the quaternion into a quaternion representation (using a designated separator), returns false if string was invalid.
        /// </summary>
        public static bool TryParse(string s, string sep, out iquat result)
        {
            result = Zero;
            if (string.IsNullOrEmpty(s)) return false;
            var kvp = s.Split(new[] { sep }, StringSplitOptions.None);
            if (kvp.Length != 4) return false;
            int x = 0, y = 0, z = 0, w = 0;
            var ok = ((int.TryParse(kvp[0].Trim(), out x) && int.TryParse(kvp[1].Trim(), out y)) && (int.TryParse(kvp[2].Trim(), out z) && int.TryParse(kvp[3].Trim(), out w)));
            result = ok ? new iquat(x, y, z, w) : Zero;
            return ok;
        }

        /// <summary>
        /// Tries to convert the string representation of the quaternion into a quaternion representation (using a designated separator and a number style and a format provider), returns false if string was invalid.
        /// </summary>
        public static bool TryParse(string s, string sep, NumberStyles style, IFormatProvider provider, out iquat result)
        {
            result = Zero;
            if (string.IsNullOrEmpty(s)) return false;
            var kvp = s.Split(new[] { sep }, StringSplitOptions.None);
            if (kvp.Length != 4) return false;
            int x = 0, y = 0, z = 0, w = 0;
            var ok = ((int.TryParse(kvp[0].Trim(), style, provider, out x) && int.TryParse(kvp[1].Trim(), style, provider, out y)) && (int.TryParse(kvp[2].Trim(), style, provider, out z) && int.TryParse(kvp[3].Trim(), style, provider, out w)));
            result = ok ? new iquat(x, y, z, w) : Zero;
            return ok;
        }

        /// <summary>
        /// Returns the inner product (dot product, scalar product) of the two quaternions.
        /// </summary>
        public static int Dot(iquat lhs, iquat rhs) => ((lhs.x * rhs.x + lhs.y * rhs.y) + (lhs.z * rhs.z + lhs.w * rhs.w));

        /// <summary>
        /// Returns the cross product between two quaternions.
        /// </summary>
        public static iquat Cross(iquat q1, iquat q2) => new iquat(q1.w * q2.x + q1.x * q2.w + q1.y * q2.z - q1.z * q2.y, q1.w * q2.y + q1.y * q2.w + q1.z * q2.x - q1.x * q2.z, q1.w * q2.z + q1.z * q2.w + q1.x * q2.y - q1.y * q2.x, q1.w * q2.w - q1.x * q2.x - q1.y * q2.y - q1.z * q2.z);

        #endregion

        #region Component-Wise Static Functions

        /// <summary>
        /// Returns a bvec4 from component-wise application of Equal (lhs == rhs).
        /// </summary>
        public static bvec4 Equal(iquat lhs, iquat rhs) => new bvec4(lhs.x == rhs.x, lhs.y == rhs.y, lhs.z == rhs.z, lhs.w == rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of Equal (lhs == rhs).
        /// </summary>
        public static bvec4 Equal(iquat lhs, int rhs) => new bvec4(lhs.x == rhs, lhs.y == rhs, lhs.z == rhs, lhs.w == rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of Equal (lhs == rhs).
        /// </summary>
        public static bvec4 Equal(int lhs, iquat rhs) => new bvec4(lhs == rhs.x, lhs == rhs.y, lhs == rhs.z, lhs == rhs.w);

        /// <summary>
        /// Returns a bvec from the application of Equal (lhs == rhs).
        /// </summary>
        public static bvec4 Equal(int lhs, int rhs) => new bvec4(lhs == rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of NotEqual (lhs != rhs).
        /// </summary>
        public static bvec4 NotEqual(iquat lhs, iquat rhs) => new bvec4(lhs.x != rhs.x, lhs.y != rhs.y, lhs.z != rhs.z, lhs.w != rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of NotEqual (lhs != rhs).
        /// </summary>
        public static bvec4 NotEqual(iquat lhs, int rhs) => new bvec4(lhs.x != rhs, lhs.y != rhs, lhs.z != rhs, lhs.w != rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of NotEqual (lhs != rhs).
        /// </summary>
        public static bvec4 NotEqual(int lhs, iquat rhs) => new bvec4(lhs != rhs.x, lhs != rhs.y, lhs != rhs.z, lhs != rhs.w);

        /// <summary>
        /// Returns a bvec from the application of NotEqual (lhs != rhs).
        /// </summary>
        public static bvec4 NotEqual(int lhs, int rhs) => new bvec4(lhs != rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of GreaterThan (lhs > rhs).
        /// </summary>
        public static bvec4 GreaterThan(iquat lhs, iquat rhs) => new bvec4(lhs.x > rhs.x, lhs.y > rhs.y, lhs.z > rhs.z, lhs.w > rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of GreaterThan (lhs > rhs).
        /// </summary>
        public static bvec4 GreaterThan(iquat lhs, int rhs) => new bvec4(lhs.x > rhs, lhs.y > rhs, lhs.z > rhs, lhs.w > rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of GreaterThan (lhs > rhs).
        /// </summary>
        public static bvec4 GreaterThan(int lhs, iquat rhs) => new bvec4(lhs > rhs.x, lhs > rhs.y, lhs > rhs.z, lhs > rhs.w);

        /// <summary>
        /// Returns a bvec from the application of GreaterThan (lhs > rhs).
        /// </summary>
        public static bvec4 GreaterThan(int lhs, int rhs) => new bvec4(lhs > rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of GreaterThanEqual (lhs >= rhs).
        /// </summary>
        public static bvec4 GreaterThanEqual(iquat lhs, iquat rhs) => new bvec4(lhs.x >= rhs.x, lhs.y >= rhs.y, lhs.z >= rhs.z, lhs.w >= rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of GreaterThanEqual (lhs >= rhs).
        /// </summary>
        public static bvec4 GreaterThanEqual(iquat lhs, int rhs) => new bvec4(lhs.x >= rhs, lhs.y >= rhs, lhs.z >= rhs, lhs.w >= rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of GreaterThanEqual (lhs >= rhs).
        /// </summary>
        public static bvec4 GreaterThanEqual(int lhs, iquat rhs) => new bvec4(lhs >= rhs.x, lhs >= rhs.y, lhs >= rhs.z, lhs >= rhs.w);

        /// <summary>
        /// Returns a bvec from the application of GreaterThanEqual (lhs >= rhs).
        /// </summary>
        public static bvec4 GreaterThanEqual(int lhs, int rhs) => new bvec4(lhs >= rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of LesserThan (lhs < rhs).
        /// </summary>
        public static bvec4 LesserThan(iquat lhs, iquat rhs) => new bvec4(lhs.x < rhs.x, lhs.y < rhs.y, lhs.z < rhs.z, lhs.w < rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of LesserThan (lhs < rhs).
        /// </summary>
        public static bvec4 LesserThan(iquat lhs, int rhs) => new bvec4(lhs.x < rhs, lhs.y < rhs, lhs.z < rhs, lhs.w < rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of LesserThan (lhs < rhs).
        /// </summary>
        public static bvec4 LesserThan(int lhs, iquat rhs) => new bvec4(lhs < rhs.x, lhs < rhs.y, lhs < rhs.z, lhs < rhs.w);

        /// <summary>
        /// Returns a bvec from the application of LesserThan (lhs < rhs).
        /// </summary>
        public static bvec4 LesserThan(int lhs, int rhs) => new bvec4(lhs < rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of LesserThanEqual (lhs <= rhs).
        /// </summary>
        public static bvec4 LesserThanEqual(iquat lhs, iquat rhs) => new bvec4(lhs.x <= rhs.x, lhs.y <= rhs.y, lhs.z <= rhs.z, lhs.w <= rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of LesserThanEqual (lhs <= rhs).
        /// </summary>
        public static bvec4 LesserThanEqual(iquat lhs, int rhs) => new bvec4(lhs.x <= rhs, lhs.y <= rhs, lhs.z <= rhs, lhs.w <= rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of LesserThanEqual (lhs <= rhs).
        /// </summary>
        public static bvec4 LesserThanEqual(int lhs, iquat rhs) => new bvec4(lhs <= rhs.x, lhs <= rhs.y, lhs <= rhs.z, lhs <= rhs.w);

        /// <summary>
        /// Returns a bvec from the application of LesserThanEqual (lhs <= rhs).
        /// </summary>
        public static bvec4 LesserThanEqual(int lhs, int rhs) => new bvec4(lhs <= rhs);

        /// <summary>
        /// Returns a iquat from component-wise application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(iquat min, iquat max, iquat a) => new iquat(min.x * (1-a.x) + max.x * a.x, min.y * (1-a.y) + max.y * a.y, min.z * (1-a.z) + max.z * a.z, min.w * (1-a.w) + max.w * a.w);

        /// <summary>
        /// Returns a iquat from component-wise application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(iquat min, iquat max, int a) => new iquat(min.x * (1-a) + max.x * a, min.y * (1-a) + max.y * a, min.z * (1-a) + max.z * a, min.w * (1-a) + max.w * a);

        /// <summary>
        /// Returns a iquat from component-wise application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(iquat min, int max, iquat a) => new iquat(min.x * (1-a.x) + max * a.x, min.y * (1-a.y) + max * a.y, min.z * (1-a.z) + max * a.z, min.w * (1-a.w) + max * a.w);

        /// <summary>
        /// Returns a iquat from component-wise application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(iquat min, int max, int a) => new iquat(min.x * (1-a) + max * a, min.y * (1-a) + max * a, min.z * (1-a) + max * a, min.w * (1-a) + max * a);

        /// <summary>
        /// Returns a iquat from component-wise application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(int min, iquat max, iquat a) => new iquat(min * (1-a.x) + max.x * a.x, min * (1-a.y) + max.y * a.y, min * (1-a.z) + max.z * a.z, min * (1-a.w) + max.w * a.w);

        /// <summary>
        /// Returns a iquat from component-wise application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(int min, iquat max, int a) => new iquat(min * (1-a) + max.x * a, min * (1-a) + max.y * a, min * (1-a) + max.z * a, min * (1-a) + max.w * a);

        /// <summary>
        /// Returns a iquat from component-wise application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(int min, int max, iquat a) => new iquat(min * (1-a.x) + max * a.x, min * (1-a.y) + max * a.y, min * (1-a.z) + max * a.z, min * (1-a.w) + max * a.w);

        /// <summary>
        /// Returns a iquat from the application of Lerp (min * (1-a) + max * a).
        /// </summary>
        public static iquat Lerp(int min, int max, int a) => new iquat(min * (1-a) + max * a);

        #endregion

        #region Component-Wise Operator Overloads

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator< (lhs < rhs).
        /// </summary>
        public static bvec4 operator<(iquat lhs, iquat rhs) => new bvec4(lhs.x < rhs.x, lhs.y < rhs.y, lhs.z < rhs.z, lhs.w < rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator< (lhs < rhs).
        /// </summary>
        public static bvec4 operator<(iquat lhs, int rhs) => new bvec4(lhs.x < rhs, lhs.y < rhs, lhs.z < rhs, lhs.w < rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator< (lhs < rhs).
        /// </summary>
        public static bvec4 operator<(int lhs, iquat rhs) => new bvec4(lhs < rhs.x, lhs < rhs.y, lhs < rhs.z, lhs < rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator<= (lhs <= rhs).
        /// </summary>
        public static bvec4 operator<=(iquat lhs, iquat rhs) => new bvec4(lhs.x <= rhs.x, lhs.y <= rhs.y, lhs.z <= rhs.z, lhs.w <= rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator<= (lhs <= rhs).
        /// </summary>
        public static bvec4 operator<=(iquat lhs, int rhs) => new bvec4(lhs.x <= rhs, lhs.y <= rhs, lhs.z <= rhs, lhs.w <= rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator<= (lhs <= rhs).
        /// </summary>
        public static bvec4 operator<=(int lhs, iquat rhs) => new bvec4(lhs <= rhs.x, lhs <= rhs.y, lhs <= rhs.z, lhs <= rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator> (lhs > rhs).
        /// </summary>
        public static bvec4 operator>(iquat lhs, iquat rhs) => new bvec4(lhs.x > rhs.x, lhs.y > rhs.y, lhs.z > rhs.z, lhs.w > rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator> (lhs > rhs).
        /// </summary>
        public static bvec4 operator>(iquat lhs, int rhs) => new bvec4(lhs.x > rhs, lhs.y > rhs, lhs.z > rhs, lhs.w > rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator> (lhs > rhs).
        /// </summary>
        public static bvec4 operator>(int lhs, iquat rhs) => new bvec4(lhs > rhs.x, lhs > rhs.y, lhs > rhs.z, lhs > rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator>= (lhs >= rhs).
        /// </summary>
        public static bvec4 operator>=(iquat lhs, iquat rhs) => new bvec4(lhs.x >= rhs.x, lhs.y >= rhs.y, lhs.z >= rhs.z, lhs.w >= rhs.w);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator>= (lhs >= rhs).
        /// </summary>
        public static bvec4 operator>=(iquat lhs, int rhs) => new bvec4(lhs.x >= rhs, lhs.y >= rhs, lhs.z >= rhs, lhs.w >= rhs);

        /// <summary>
        /// Returns a bvec4 from component-wise application of operator>= (lhs >= rhs).
        /// </summary>
        public static bvec4 operator>=(int lhs, iquat rhs) => new bvec4(lhs >= rhs.x, lhs >= rhs.y, lhs >= rhs.z, lhs >= rhs.w);

        /// <summary>
        /// Returns a iquat from component-wise application of operator+ (identity).
        /// </summary>
        public static iquat operator+(iquat v) => v;

        /// <summary>
        /// Returns a iquat from component-wise application of operator- (-v).
        /// </summary>
        public static iquat operator-(iquat v) => new iquat(-v.x, -v.y, -v.z, -v.w);

        /// <summary>
        /// Returns a iquat from component-wise application of operator+ (lhs + rhs).
        /// </summary>
        public static iquat operator+(iquat lhs, iquat rhs) => new iquat(lhs.x + rhs.x, lhs.y + rhs.y, lhs.z + rhs.z, lhs.w + rhs.w);

        /// <summary>
        /// Returns a iquat from component-wise application of operator+ (lhs + rhs).
        /// </summary>
        public static iquat operator+(iquat lhs, int rhs) => new iquat(lhs.x + rhs, lhs.y + rhs, lhs.z + rhs, lhs.w + rhs);

        /// <summary>
        /// Returns a iquat from component-wise application of operator+ (lhs + rhs).
        /// </summary>
        public static iquat operator+(int lhs, iquat rhs) => new iquat(lhs + rhs.x, lhs + rhs.y, lhs + rhs.z, lhs + rhs.w);

        /// <summary>
        /// Returns a iquat from component-wise application of operator- (lhs - rhs).
        /// </summary>
        public static iquat operator-(iquat lhs, iquat rhs) => new iquat(lhs.x - rhs.x, lhs.y - rhs.y, lhs.z - rhs.z, lhs.w - rhs.w);

        /// <summary>
        /// Returns a iquat from component-wise application of operator- (lhs - rhs).
        /// </summary>
        public static iquat operator-(iquat lhs, int rhs) => new iquat(lhs.x - rhs, lhs.y - rhs, lhs.z - rhs, lhs.w - rhs);

        /// <summary>
        /// Returns a iquat from component-wise application of operator- (lhs - rhs).
        /// </summary>
        public static iquat operator-(int lhs, iquat rhs) => new iquat(lhs - rhs.x, lhs - rhs.y, lhs - rhs.z, lhs - rhs.w);

        /// <summary>
        /// Returns a iquat from component-wise application of operator* (lhs * rhs).
        /// </summary>
        public static iquat operator*(iquat lhs, int rhs) => new iquat(lhs.x * rhs, lhs.y * rhs, lhs.z * rhs, lhs.w * rhs);

        /// <summary>
        /// Returns a iquat from component-wise application of operator* (lhs * rhs).
        /// </summary>
        public static iquat operator*(int lhs, iquat rhs) => new iquat(lhs * rhs.x, lhs * rhs.y, lhs * rhs.z, lhs * rhs.w);

        /// <summary>
        /// Returns a iquat from component-wise application of operator/ (lhs / rhs).
        /// </summary>
        public static iquat operator/(iquat lhs, int rhs) => new iquat(lhs.x / rhs, lhs.y / rhs, lhs.z / rhs, lhs.w / rhs);

        #endregion

    }
}