Friday, March 10, 2017

Inertial Flow in Porous Media


The plot of Pi number versus Reynolds number in the system like below. Compared to Andrade 1999 (PRL).




64x64 blocks (numerical mesh is way larger)



Friday, December 16, 2016

Monday, June 20, 2016

Logistics maps

 Standard logistic map x=r*(x(1-x))
Logistic map x=(r*r)*(x(1-x))
Logistic map x=sqrt(r)*(x(1-x))



#include <iostream>
#include <cmath>
using namespace std;
int main(void)
{
    float r,x0,x;
    const int NSAVE = 500;
    const int NITER = 5000 + NSAVE;

    for(r=-3;r<45;r+=0.005)
    {
       x0=0.9;
       x=x0;
       for(int i=0; i<NITER; i++)
       {
          x = (r*r)*(x*(1-x));
          //x = x*exp(r*(1-x));  // eq. 4. May Nature 76
          if(i>NITER-NSAVE)
          if(isfinite(x))
            cout << r << " " << x << endl;
       }
    }
    return 1;
}