add: variations of stabilization params w.r.t. velocity
This commit is contained in:
parent
952bb20bd7
commit
ff76b83c98
@ -59,4 +59,23 @@ bool getTauNSALEPt(double dt, double mu, const Vector& U, const Matrix& G, doubl
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool getTauPtJac(const Vector& U, const Matrix& G, const double tauM, Vector& tauMjac)
|
||||||
|
{
|
||||||
|
tauMjac = -pow(tauM,3)*G*U;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
bool getTauNSPtJac(const Vector& U, const Matrix& G, const double tauM, const double& tauC, Vector& tauMjac, Vector& tauCjac)
|
||||||
|
{
|
||||||
|
if (!getTauPtJac(U, G, tauM, tauMjac))
|
||||||
|
return false;
|
||||||
|
|
||||||
|
tauCjac = (-tauC/tauM) * tauMjac;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -45,6 +45,23 @@ namespace StabilizationUtils {
|
|||||||
//! \details Stabilization parameters in integration point
|
//! \details Stabilization parameters in integration point
|
||||||
bool getTauNSALEPt(double dt, double mu, const Vector& U, const Matrix& G,
|
bool getTauNSALEPt(double dt, double mu, const Vector& U, const Matrix& G,
|
||||||
double& tauM, double& tauC, const double Ct=2.0, const double Cl=36.0);
|
double& tauM, double& tauC, const double Ct=2.0, const double Cl=36.0);
|
||||||
|
|
||||||
|
//! \brief Computes variation of stability parameters with respect to velocity
|
||||||
|
//! \param[in] U Velocity vector
|
||||||
|
//! \param[in] G The G matrix
|
||||||
|
//! \param[in] tauM Stabilization parameter for momentum
|
||||||
|
//! \param[out] tauMjac Variation of tauM with respect to U
|
||||||
|
bool getTauPtJac(const Vector& U, const Matrix& G, const double tauM, Vector& tauMjac);
|
||||||
|
|
||||||
|
//! \brief Computes variation of stability parameters with respect to velocity
|
||||||
|
//! \param[in] U Velocity vector
|
||||||
|
//! \param[in] G The G matrix
|
||||||
|
//! \param[in] tauM Stabilization parameter for momentum
|
||||||
|
//! \param[in] tauC Stabilization parameter for continuity
|
||||||
|
//! \param[out] tauMjac Variation of tauM with respect to U
|
||||||
|
//! \param[out] tauCjac Variation of tauC with respect to U
|
||||||
|
bool getTauNSPtJac(const Vector& U, const Matrix& G, const double tauM,
|
||||||
|
const double& tauC, Vector& tauMjac, Vector& tauCjac);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user