different result with scipy integrate.tplquad

前端 未结 1 2002
北恋
北恋 2021-01-25 04:58

With Matematica this integral gives me 3. wolfram alpha With integrate.tplquad I get -3.
This is Matematica code.

Integrate[1-x, {(0,2),(0,3-1.5*x),(0         


        
相关标签:
1条回答
  • 2021-01-25 05:18

    Double-check the tplquad docstring; you'll see that the signature of the function f is f(z, y, x). So it looks like your integrand should be:

       f = lambda x, y, z: 1 - z
    
    0 讨论(0)
提交回复
热议问题