How to fix equation code error

1 visualizzazione (ultimi 30 giorni)
Cesar Cardenas
Cesar Cardenas il 7 Apr 2023
Modificato: Torsten il 7 Apr 2023
I would like to know if I'm coding this equation correctly?? I'm getting a error. Any help will be appreciated. Thanks.
nu = 1.5e-5;
ya = 9.7;
k = 0.41;
y = 2.3025e-03;
uT = (k.*rho.*nu).*((y.*ustar/nu) - ya.*tanh((y.*ustar/nu)/ya))
  2 Commenti
Dyuman Joshi
Dyuman Joshi il 7 Apr 2023
From equation standpoint, the formula is correct. Apart from what Steven has mentioned below, are you facing any other problem?
Torsten
Torsten il 7 Apr 2023
Modificato: Torsten il 7 Apr 2023
We are full of expectation to see the error message and the values of rho and ustar to evaluate the expression for uT.

Accedi per commentare.

Risposte (1)

Steven Lord
Steven Lord il 7 Apr 2023
nu = 1.5e-5;
ya = 9.7;
k = 0.41;
y = 2.3025e-03;
uT = (k.*rho.*nu).*((y.*ustar/nu) - ya.*tanh(y.*ustar/nu.*ya))
Unrecognized function or variable 'rho'.
Nowhere in this code do you define the variables rho or ustar.

Categorie

Scopri di più su Mathematics and Optimization in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by