I am trying to solve the second order differential equation of the type of heat transfer in a finite system x<0,L>, in particular:

```
eq = D(T(x, t), t) - k*D(T(x, t), {x, 2}) == 0;
```

(For simplicity, I suppose that hereafter k = 1 and L = 1).

The system is connected to a semi-infinite source of power 1 for x (-infty, 0), while the & # 39; temperature & # 39; initial for x <0.1) is 0. This provides the initial condition for the equation in parts form:

```
T(x, 0) == Piecewise({{1, x < 0}, {0, x >= 0}})
```

I also assume that Neumann's boundary conditions: 1) the "heat" flow in the system is proportional to the temperature gradient between the source and the system:

```
Derivative(1, 0)(T)(0., t) == (T(0., T) - 1)
```

and 2) there is no loss of & # 39; heat & # 39; in the second system limit:

```
Derivative(1, 0)(T)(1, t) == 0}
```

Merging all the elements I obtained a code:

```
sol = NDSolve({eq,
T(x, 0) == Piecewise({{1, x < 0}, {0, x >= 0}}),
Derivative(1, 0)(T)(0., t) == (T(0., t) - 1),
Derivative(1, 0)(T)(1, t) == 0},
T, {x, 0, 1}, {t, 0, 1})
Plot3D(Evaluate(T(x, t) /. sol), {x, 0, 1}, {t, 0, 1})
```

When I ran the Mathematica code (v8.0) he sent me a warning about the inconsistency of the initial conditions / limit: I guess I confused something with the behavior at x = 0. However, I got a graph, not exactly what I want (T (x, t) = 0). Then I changed the initial conditions to

```
T(x, 0) == Piecewise({{1, x <= 0}, {0, x > 0}})
```

to impose the heat flux through x = 0. Once again, I received the warning and a graph: this time I can see some distributions of & # 39; temperature & # 39; in the system, but the result seems to be bad, since the inconsistency of the initial conditions / limit and also the non-physical results (T> 1, while it cannot be higher than the source temperature T = 1).

Can anyone help me overcome the problem with the initial limits / conditions? I am using Mathematica 8, so I cannot use the NeumannValue function.