Esempio n. 1
0
/// Velocity on the parabolic Womersley profile
T womersleyVelocity(plint iY, T t, T A, T omega, T alpha, IncomprFlowParam<T> const& parameters)
{
    const complex<T> I(0.,1.);
    T y = (T)iY / parameters.getResolution();

    return ( A / (I * omega) * std::exp(I * omega * t) *
             ( (T)1. - std::cosh(std::sqrt((T)2.)*(y-(T).5)*(alpha+I*alpha)) /
               std::cosh(std::sqrt((T)2.)/(T)2. * (alpha+I*alpha)) ) ).real();
}
/// Velocity on the parabolic Poiseuille profile
T poiseuilleVelocity(plint iY, IncomprFlowParam<T> const& parameters) {
	T y = (T)iY / parameters.getResolution();
	return 4.*parameters.getLatticeU() * (y-y*y);
}