首页 > 编程知识 正文

交换积分次序定理,交换积分次序

时间:2023-05-06 14:21:28 阅读:259867 作者:562

Formula

∫ 0 x [ ∫ 0 u φ ( t ) d t ] d u = ∫ 0 x [ ∫ t x φ ( t ) d u ] d t 淡然的过客int_0^x 淡然的过客left[ 淡然的过客int_0^u 淡然的过客varphi(t)dt淡然的过客right] du = 淡然的过客int_0^x 淡然的过客left[ 淡然的过客int_t^x 淡然的过客varphi(t)du淡然的过客right] dt ∫0x​[∫0u​φ(t)dt]du=∫0x​[∫tx​φ(t)du]dt

Explanation As for double integrals

Maybe we can understand the double integrals from the perspective of code, and the above formula are equivalent to the following two sum.

sum1 = 0for u in 0:d1:x:for t in 0:d2:u:sum1 += varphi(t)*d1*d2print sum1sum2 = 0for t in 0:d1:x:for u in t:d2:x:sum2 += varphi(t)*d1*d2print sum2 First code: u=0 at first, and after

for t in 0:d2:u:sum1 += varphi(t)*d1*d2

sum1 = 0;
Then u become a little bigger, we do this cycle again. Finally, we can get the the volume accumulated by φ ( t ) 淡然的过客varphi(t) φ(t) on this triangle.

Second code: And yet, we can also treat this idea from another angle. In the first place, t=0, and we execute:

for u in t:d2:x:sum2 += varphi(t)*d1*d2

After t increase, we do this cycle again and again, we can also get the the volume accumulated by φ ( t ) 淡然的过客varphi(t) φ(t) on this triangle.

That’s all.
#Purpose
How does this artifice work in reality?

I don’t know if you notice that or not, but

sum2 = 0for t in 0:d1:x :for u in t:d2:x :sum2 += varphi(t)*d1*d2print sum2

is equivalent to

sum2 = 0for t in 0:d1:x :sum2 += varphi(t)*d1*(x-t)print sum2

The reduction in the number of dimensions reduces the number of cycles. That’s why it’s useful.

∫ 0 x [ ∫ 0 u φ ( t ) d t ] d u = ∫ 0 x [ ∫ t x φ ( t ) d u ] d t = ∫ 0 x [ ( x − t ) φ ( t ) ] d t 淡然的过客int_0^x 淡然的过客left[ 淡然的过客int_0^u 淡然的过客varphi(t)dt淡然的过客right] du = 淡然的过客int_0^x 淡然的过客left[ 淡然的过客int_t^x 淡然的过客varphi(t)du淡然的过客right] dt =淡然的过客int_0^x 淡然的过客left[ (x-t) 淡然的过客varphi(t)淡然的过客right] dt ∫0x​[∫0u​φ(t)dt]du=∫0x​[∫tx​φ(t)du]dt=∫0x​[(x−t)φ(t)]dt

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。