Question about the Bernouilli equation

There are some things I encountered, studying the Bernouilly equation, that I don't understand. I was studying in the following book: http://www.unimasr.net/ums/upload/files/2012/Sep/UniMasr.com_919e27ecea47b46d74dd7e268097b653.pdf. At page 72-73 they derive the Bernouilli equation for the first time, from energy considerations. They state that it can be applied if the flow is steady, incompressible, inviscid, when there is no change in internal energy and no heat transfer is done (p.72 at the bottom). I understand this derivation, my problems arise when they derive the equation again at page 110-111, this time from the Navier-Stokes equation.

I don't quite understand the derivation yet, but I am more confused about the outcome. It seems that the Bernouilli equation can now be applied under the four conditions they state (inviscid flow, steady flow, incompressible flow and the equation applies along a streamline) while it seems that there are no limitations to the internal energy of the flow and the heat transfer done. If I understand the last paragraph right, they state that the requirement that the flow is inviscid already comprises the claim that there is no change in internal energy ("the constant internal energy assumption and the inviscid flow assumption must be equivalent, as the other assumptions were the same", I don't really understand this reasoning, because the "inviscid flow assumption" was also already made in the previous derivation).

Furthermore, if I follow the reasoning (so if I assume that inviscid flow indeed implies that there is no change in internal energy or if I assume that the Bernouilli equation can also be applied, without the assumption of "no change in internal energy") then example 4 at page 74 seems strange to me. It shows that in this situation the Bernouilli equation can't be applied directly (because headloss has to be included in the equation). However I think that we can easily repeat the derivation, assuming that the flow is inviscid (and assuming that the other conditions are satisfied), but this example shows that the internal energy increases, so inviscid flow can't imply "no change in internal energy". And the example also shows that the Bernouilli equation can't be applied, because head loss has to be considered (so this example seems to contradict the result at page 110-111).

I hope someone can explain where my understanding is lacking, because this really confuses me about the conditions under which the Bernouilli equation can be applied.

It would also be helpful, if someone could explain the derivation at p.110: what I don't understand is the definition of "streamline coordinates". Do they just take a random point on the streamline, where they place a cartesian coordinate system?

• viscosity (basically internal fluid friction) results in the "dissipation" of kinetic energy in the form of heat into the fluid, resulting in a rise in the internal energy of the fluid. that defines the statement: the constant internal energy assumption and the inviscid ﬂow assumption must be equivalent. – aditya kp Aug 17 '13 at 2:11

So the equation is $v^2/2+gy+P/\rho = const$, which has no change in internal energy (i.e. $U_1=U_2$).
OK was going to leave this for you to puzzle through, but just for completeness: because of the immediate area change of the pipe, with the constant steady pressure $P_1>0$, there is turbulent flow (high Reynolds number, depicted in the picture by the swirls), corresponding to viscosity and hence not inviscid.