I am in the process of programming the local & average Nusselt number in a left vertical wall but my Matlab script gives me inappropriate values and it doesn't change with changing of Rayleigh number!!

The problem is: how to calculate and impliment the local Nusselt number in a vertical left wall of a cavity. The expressions of the local nusselt: $-\dfrac{\partial T}{\partial x}|_{x=0}$

My script: using finite difference approximation with 5 points-Forward scheme ( j=1 to m+1 and i=1 )

for j=1:m+1
    Nu_loc(j) = -(-25*T(1,j)+48*T(1+1,j)-36*T(1+2,j)+16*T(1+3,j)-3*T(1+4,j))/(12*hx);   
  • 1
    $\begingroup$ The Nusselt number is a dimensionless number, but your formula has units $K/m$. It can't be right. $\endgroup$ Commented Mar 23, 2022 at 16:43
  • $\begingroup$ Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. $\endgroup$
    – Community Bot
    Commented Mar 23, 2022 at 20:20
  • $\begingroup$ @WolfgangBangerth in this case T and x are both dimensionless parameters $\endgroup$
    – Bakizza
    Commented Mar 23, 2022 at 23:45
  • $\begingroup$ OK, but I still don't understand what the question is. You are computing the derivative with a finite difference stencil that looks correct to me. What is it you want to ask? Your post has no question mark. $\endgroup$ Commented Mar 24, 2022 at 21:46
  • $\begingroup$ Mr. @WolfgangBangerth my question: are the formulation and the implimentation above right or need to try another ones? $\endgroup$
    – Bakizza
    Commented Mar 25, 2022 at 10:34

1 Answer 1


You might consider some of the references in this summary article of a contest at a meeting to solve the 3D problem.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.