When I try to calculate the following integral in Mathematica 8, I get this strange result:
In[1]:= Integrate[y/((1 + x^2 + y^2)^(3/2)), {y, 0, 1}]
Maple 14 can solve this one easily:
Why is Mathematica giving me a different result?
I want to integrate the equation:
f(x) = integral(E^(-i * omega * t)), from -a to a.
I wrote the following code:
from sympy import *
from sympy.abc import a, omega, t
init_printing(use_unicode=False, wrap_line=False, no_global=True)
f = E**(-I…
In attempting to use scipy's quad method to integrate a gaussian (lets say there's a gaussian method named gauss), I was having problems passing needed parameters to gauss and leaving quad to do the integration over the correct variable. Does anyone…
I am having a problem when using simpson's rule from scipy.integrate library. The Area calculated sometimes is negative even if all the numbers are positive and the values on the x-axis are increasing from left to right. For example:
from…
In doc of sympy http://docs.sympy.org/latest/modules/integrals/integrals.html we can read:
The manualintegrate module has functions that return the steps used (see the module docstring for more information).
but calling…
I would like to lambdify the function Integral(t**t,(t,0,x)). It works, but my new function, which was returned by lambdify, doesn't return a number but only sympy.integrals.integrals.Integral class. But I don't want that, I want it to return a…
I am getting the following error code when trying to evaluate a definite integral in Python.
AttributeError Traceback (most recent call last)
in ()
7 x, n = symbols('x n')
…
Using the recent version of sympy (0.7.6) I get the following bad result when determining the integral of a function with support [0,y):
from sympy import *
a,b,c,x,z = symbols("a,b,c,x,z",real = True)
y = Symbol("y",real=True,positive=True)
inner =…
According to http://en.cppreference.com/w/cpp/language/reinterpret_cast, it is known that reinterpret_cast a pointer to an integral of sufficient size and back yield the same value. I'm wondering whether the converse is also true by the standards.…
I now have an idea, that I use the function as a string, and I calculate the real integral by hand, and ask a question to the user what the definite integral is, but that isn't a real solution.
I was wondering if there was a way to input a function…
Is it possible to do triple integration in R without using the cubature package?
based on the answer in this post
InnerFunc = function(x) { x + 0.805 }
InnerIntegral = function(y) { sapply(y,
function(z) { integrate(InnerFunc, 15, z)$value })…
I want to solve the following in R:
∫0H [π(t) ∫tH A(x) dx ] dt
Where π(t) is the prior and A(x) is the A function defined below.
prior <- function(t) dbeta(t, 1, 24)
A <- function(x) dbeta(x, 1, 4)
expected_loss <- function(H){
integrand …
Ok, so this has me stumped for over more then 3 days and after still not being one step closer to the solution, I'm gonna try my luck here.
In the past, I've written some code for one sorted dataset in specific and it goes like this:
n <-…
I have a function for with i need to do an infinite summation on (over all the integers) numerically. The summation doesn't always need to converge as I can change internal parameters. The function looks like,
m(g, x, q0) = sum(abs(g(x - n*q0))^2…
I recently started using Matlab and I am trying to plot Imaginary part of a function. I can see I am making a mistake somewhere because I have the graph showing what I need to get and I am getting something else. Here is the link of the graph that I…