not enough input arguments Urgent Help

1 visualización (últimos 30 días)
Rey Perez
Rey Perez el 16 de Sept. de 2021
Respondida: Star Strider el 17 de Sept. de 2021
function [V] = Tank_Volume(R, h, L, H)
% h is fluid height
% R is radius of tank
% H is tank height
% L is the lenght of the tank
if h<0
error('Please fill the tank!!') ;
elseif h>=0 && h<R
V= L*(R^2*acos((R-h)/R)-(R-h)*sqrt(h(2*R-h))) ;
elseif h>=R && h<=H
V=(L*((pi*R^2)/2+((h-R)*2*R)));
else
error('Do not waste alcohol, drink it instead!!') ;
end
Not enough input arguments.
Error in Tank_Volume (line 18)
elseif h>=R && h<=H
Error in Main_Code (line 16)
V(i)=Tank_Volume(h(i),R,H);

Respuestas (1)

Star Strider
Star Strider el 17 de Sept. de 2021
The function declaration is:
function [V] = Tank_Volume(R, h, L, H)
and the function call is:
V(i)=Tank_Volume(h(i),R,H);
.

Categorías

Más información sobre Fluid Dynamics en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by