# Numerical solution to integral equation

I have an integral equation where one factor $f(t)$ in the integrand is defined in terms of an integral equation where it is again a factor.

$\quad \quad y[t]=\int _0^tf[\tau ]g[t-\tau ]d\tau + h[t]$
$\quad \quad f[t]= -\int _0^tf[t']\zeta [t-t']dt' + \rho[t]$

How do I solve for $y$ numerically? I have used trapezoidal rules explicitly to evaluate both the integrals and also, the code seems to become very slow as I increase the number of terms. I am not sure , I am doing it the right way in Mathematica, I am quite new to using it. The equation details and the code is pasted below:

$\quad \quad \Phi[t]= (1+(\alpha-1)(t/tR))^{1/(1-\alpha)}$
$\quad \quad \Phi B[t,t1] = (1+(\alpha B-1)(t-t1)/tB)^{1/(1-\alpha B)}$
$\quad \quad \gamma [t]=(1-\rho)(1-\Phi[t])-\int _0^t\Phi B[t,t1]\gamma[t1]dt1$
$\quad \quad \sigma[t]=\mu 0 \big[[(1-\rho)\Phi[t]+\rho](\lambda[t]-1/\lambda^2[t])+ \int _0^t\gamma [\tau] \Phi B[t,\tau] (\frac{\lambda[t]}{\lambda^2 [\tau]}-\frac{\lambda[\tau]}{\lambda^2 [t]}) d\tau)\big]$

ClearAll[γ1, "Global*"]

σ[t_] := μ0*(((1 - ρ) ϕ[t] + ρ)*(λ[t] - 1/λ[t]^2) + term2[t])

term2[t_] :=
dt*Sum[(ϕB[nIter*dt, k*dt]*γ1[k])*(λ[nIter*dt]/λ[k*dt]^2 - λ[k*dt]/
λ[nIter*dt]^2), {k, 1, nIter - 1}]

ϕ[t_] := (1 + (α - 1) (t/tR))^(1/(1 - α))

ϕB[t_, t1_] := (1 + (αB - 1) ((t - t1)/tB))^(1/(1 - αB))

λ[t_] := 1 + 0.2*t;

tFinal = 5.0;

params = {μ0 -> 24.15, α -> 2.64, tR -> 0.6, ρ -> 0.105,
tH -> 0.042, αB -> 1.55, tB -> 0.44};

γ1[n_] :=
γ1[n] = (1/(tH + 0.5*dt))*((1 - ρ)*(1 - ϕ[n*dt]) -
dt*Sum[ϕB[n*dt, k*dt]*γ1[k], {k, 1, n - 1}])

nIter = 8;
dt = tFinal/nIter;

γ1 = 0;

data = Table[{t, σ[t], λ[t]}, {t, 0, tFinal}] /. params ;

ListPlot[data[[All, {1, 2}]]]
`
• – george2079 Jul 24 '15 at 21:04
• It is not clear to me this is question concerning WRI's Mathematica software. – m_goldberg Jul 24 '15 at 21:27
• @george2079 Thanks, for the direction. I will try to see if i can implement it along those lines. – novice Jul 24 '15 at 21:30
• @m_goldberg I was wondering if there is a way to use "NIntegrate" of Mathematica and get a solution easily. – novice Jul 24 '15 at 21:31
• It is unfortunate that Mathematica does not have a function for solving integral (or integro-differential) equations. – bbgodfrey Jul 26 '15 at 13:12