Functions handle (product of functions)

5 visualizaciones (últimos 30 días)
Marcus Vinicius Pereira de Souza
Marcus Vinicius Pereira de Souza el 20 de Mzo. de 2013
Dear all, I have the following functions:
X=@(fi) 2*sqrt(5/8)*atan(sqrt(45)*fi.); h=@(fi) 10*fi.^2;
However, I need to calculate the follow function:
f=X*h area= quad(f,0,10)
Can anyone help me? Thanks a lot. Marcus Vinicius
  2 comentarios
Youssef  Khmou
Youssef Khmou el 20 de Mzo. de 2013
i am not sure if we can define function based on functions but as alternative solution take a look at the solution below
Marcus Vinicius Pereira de Souza
Marcus Vinicius Pereira de Souza el 20 de Mzo. de 2013
Thanks a lot!! Best wishes, Marcus Vinicius

Iniciar sesión para comentar.

Respuesta aceptada

Youssef  Khmou
Youssef Khmou el 20 de Mzo. de 2013
hi,
why dont you use one single function handle :
>>G=@(fi) 2*sqrt(5/8)*atan(sqrt(45).*fi)*10.*(fi.^2) % This is X*H
>>I=quad(G,0,10)

Más respuestas (0)

Categorías

Más información sobre Monte-Carlo 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