From 35d91830a2548370f7ecbc13d42729cbc5d70cac Mon Sep 17 00:00:00 2001 From: Ian Jauslin Date: Thu, 12 May 2022 09:32:58 +0200 Subject: Corrections in doc --- docs/nstrophy_doc/nstrophy_doc.tex | 7 ++++--- src/main.c | 8 +++++--- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/docs/nstrophy_doc/nstrophy_doc.tex b/docs/nstrophy_doc/nstrophy_doc.tex index 914b0b8..0ec222b 100644 --- a/docs/nstrophy_doc/nstrophy_doc.tex +++ b/docs/nstrophy_doc/nstrophy_doc.tex @@ -50,7 +50,7 @@ in terms of which, multiplying both sides of the equation by $\frac{k^\perp}{|k| \partial_t\hat \varphi_k= -4\pi^2\nu k^2\hat \varphi_k+\frac{k^\perp}{2i\pi|k|}\cdot\hat g_k +\frac{4\pi^2}{|k|}\sum_{\displaystyle\mathop{\scriptstyle p,q\in\mathbb Z^2}_{p+q=k}} - (q\cdot p^\perp)(k^\perp\cdot q^\perp)\hat\varphi_p\hat\varphi_q + \frac{(q\cdot p^\perp)(k^\perp\cdot q^\perp)}{|q||p|}\hat\varphi_p\hat\varphi_q . \label{ins_k} \end{equation} @@ -88,7 +88,7 @@ using a fast Fourier transform, defined as \end{equation} where \begin{equation} - \mathcal N:=\{(n_1,n_2),\ 0\leqslant n_1\leqslant N_1,\ 0\leqslant n_2\leqslant N_2\} + \mathcal N:=\{(n_1,n_2),\ 0\leqslant n_1< N_1,\ 0\leqslant n_2< N_2\} \end{equation} for some fixed $N_1,N_2$. The transform is inverted by \begin{equation} @@ -110,7 +110,8 @@ provided \begin{equation} N_i>4K_i. \end{equation} -Indeed, $\sum_{n_i=0}^{N_i}e^{-\frac{2i\pi}{N_i}n_im_i}$ vanishes unless $m_i=0\%N_i$ (in which $\%N_i$ means `modulo $N_i$'), and, if $p,q\in\mathcal K$, then $|p_i+q_i|\leqslant2K_i$. Therefore, +Indeed, $\sum_{n_i=0}^{N_i}e^{-\frac{2i\pi}{N_i}n_im_i}$ vanishes unless $m_i=0\%N_i$ (in which $\%N_i$ means `modulo $N_i$'), and, if $p,q\in\mathcal K$, then $|p_i+q_i|\leqslant2K_i$. +Therefore, \begin{equation} T(\hat\varphi,k) = diff --git a/src/main.c b/src/main.c index 4b68f92..10b1e70 100644 --- a/src/main.c +++ b/src/main.c @@ -77,10 +77,12 @@ int read_args(int argc, const char* argv[], ns_params* params, unsigned int* nst *nsteps=10000000; params->nu=1./1024/(2*params->K+1); */ - params->K=3; + params->K=16; params->h=0.0001220703125; + params->h=0.001953125; *nsteps=10000000; - params->nu=0.00048828125; + //params->nu=0.00048828125; + params->nu=0.0078125; // loop over arguments for(i=1;i0 && t%8192==0){ + if(t>0 && t%1000==0){ fprintf(stderr,"%8d % .8e % .8e % .8e % .8e\n",t, __real__ avg, __imag__ avg, __real__ alpha, __imag__ alpha); printf("%8d % .8e % .8e % .8e % .8e\n",t, __real__ avg, __imag__ avg, __real__ alpha, __imag__ alpha); } -- cgit v1.2.3-54-g00ecf