Triple integral with absolute value limits

5 visualizaciones (últimos 30 días)
mohammed saleh
mohammed saleh el 4 de Dic. de 2022
Comentada: mohammed saleh el 9 de Sept. de 2023
I would like to solve the following integral numerically:
I wrote this code, but the result is not coming. Can anyone tell me what my mistake is?
lambda1=25/(1000)^2;
lambda1=100/(1000)^2
lambda1 = 1.0000e-04
fun =integral3(@(l0,l2,l1) (l1.^-3).*exp(-pi*(lambda2.*l2.^(2)+lambda1.*l0.^(2)))./(sqrt(1-((l0.^(2)+l2.^(2)-l1.^(2))/(2*l0.*l2)).^2)),0,Inf,0,@(l0,l2) abs(l0-l2),@(l0,l2) (l0+l2))
Error using integral3
Invalid argument list. Function requires 1 more input(s).

Respuesta aceptada

Walter Roberson
Walter Roberson el 4 de Dic. de 2022
lambda1=25/(1000)^2;
lambda2=100/(1000)^2
lambda2 = 1.0000e-04
fun =integral3(@(l0,l2,l1) (l1.^-3).*exp(-pi*(lambda2.*l2.^(2)+lambda1.*l0.^(2)))./(sqrt(1-((l0.^(2)+l2.^(2)-l1.^(2))/(2*l0.*l2)).^2)),0,Inf,0,Inf,@(l0,l2) abs(l0-l2),@(l0,l2) (l0+l2))
Warning: Inf or NaN value encountered.
Warning: The integration was unsuccessful.
fun = NaN
  14 comentarios
mohammed saleh
mohammed saleh el 9 de Sept. de 2023
Editada: mohammed saleh el 9 de Sept. de 2023
SORRY fun=fun2
its mistake
fun =@(l1,l2,l0) ((l1.^(1-4)).*(exp(-pi*(lambda_2*l2.^2+lambda_1*l0.^2))./(sqrt(1-((l0.^2+l2.^2-l1.^2)./(2*l0.*l2)).^2))));
const=4*pi*lambda_2*lambda_1;
z=const*integral3(fun,0,inf,0,inf,@(l0,l2) 1+eps*(l0-l2),@(l0,l2) 1-eps*(l0+l2));
I got it, but there are big differences with the simulation result.
if iw ant to change like this
z=@(l2) const*integral2(@(l0,l1) fun,0,inf,@(l0,l2) 1+eps*(l0-l2),@(l0,l2) 1-eps*(l0+l2)); its possible ?
i want z as functions of l2.
mohammed saleh
mohammed saleh el 9 de Sept. de 2023
i did like that but get error Not enough input arguments.
fun =@(l0,l2,l1) ((l1.^(1-4)).*(exp(-pi*(lambda_2*l2.^2+lambda_1*l0.^2))./(sqrt(1-((l0.^2+l2.^2-l1.^2)./(2*l0.*l2)).^2))));
z = @(l2) integral2(@(l0, l1) fun(l0,l2,l1), 0,inf, @(l0,l2) 1+eps*(l0-l2),@(l0,l2) 1-eps*(l0+l2));

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Ordinary Differential Equations en Help Center y File Exchange.

Productos


Versión

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by