Takala wrote:
“Peter did not confirm your statement.”

OK then, I might have misunderstood his last post. But this is easy to clarify by simply asking a pointed question. Peter, did you recognize and acknowledge that my explanations are correct, and the solution of this project given by the Elmer solver is wrong?

Takala wrote:
“Your results are correct.”

Apparently you still don’t get it… I have meticulously proven that the results are incorrect! Please read my previous posts again and again until you understand it.

Takala wrote:
“What you are missing here is that a wave has a time and place.”

How did you come to this conclusion? Did you read my previous posts? It looks like you didn’t; or if you did, then you have not understood the math and explanations I have demonstrated. The wave does not “have a time and a place”. The wave has different local properties at different points in space and time. The equation (9.3) in the ElemerModelsManual.pdf

p(t)=Re(P*exp(i*om*t)=Re(P)*cos(om*t) – Im(P)*sin(om*t)

describes exactly how to calculate the instantaneous pressure at a specific point in space at a specific time using the solution provided by the Elmer solver. The solver gives only the value P, which is a complex number. This complex number describes the wave at a specific point in space in frequency domain. In fact if we want to be very specific, then instead of P we supposed to write P(x,y,z) in 3D space (or P(x,y) in 2D, or P(x) in 1D), because the complex value of P depends on where it is measured or calculated.

In this project I was attempting to model the propagation of a harmonic acoustic wave of 100 Pa amplitude through a simple tube. It was ambiguous whether the incoming wave at the input should be given as an amplitude, or as an effective value, because this is not specified in the manual. In commercial software this is always amplitude, and the derived results are also amplitudes, because this makes most sense. But doing so in Elmer leads to wrong solution, so out of good will I have had to try both options, and both options lead to wrong results. But the closest solution to the expected value is obtained when the input is defined using the effective value of the pressure peff= 100 /sqrt(2) Pa=70.71 Pa as:

pressure Wave 1 (real part): 70.71068

pressure Wave 2 (imag part): 0

This value is defined at the input at coordinate point x=0. If we assume that this value is the effective value, then the amplitude must be 100 Pa. Since pressure Wave 2 (imag part)=0 that means that at point x=0 and at time t=0 the instantaneous pressure amplitude must be 100 Pa.

The pressure in the solution at the same point at the same time must be the same if there are no reflections (or at least approximately the same, if there are small reflections) within the tube. Since the output boundary condition is chosen to be a matched boundary, having the same impedance as the characteristic impedance of the tube (supposed to be rho*c, but Elmer awkwardly requires this to be only c):

real part of impedance: 343

imag part of impedance: 0

there should not be any reflections in the solution.

Therefore again, the complex pressure amplitude at the point x=0 in the solution must be equal with the defined input pressure amplitude at x=0 which is 100 Pa; or if we deal with effective values, then the effective magnitude of the pressure in the solution must be 70.71 Pa, the same as the input effective value. This requirement is satisfied by the Elmer solution only if we (again awkwardly) assume that the result represents amplitudes and not effective values. But even with this assumption, this is still not a sufficient condition to make the solution accurate.

The other requirement is that the phase of the complex pressure must be also identical with the input wave in this case, which is zero. Or the same requirement expressed in time domain demands that at time t=0 at point x=0 the instantaneous pressure must be 100 Pa. This is the requirement that the Elmer solution does not fulfil!

In my previous posts I have proven and explained in detail that there is only one accurate solution that satisfies this condition of equivalence, namely when at point x=0 the effective value of

pressure Wave 1 (real part)[at point x=0]: 70.71068

pressure Wave 2 (imag part)[at point x=0]: 0

Or more consistently expressed as amplitudes:

pressure Wave 1 (real part)[at point x=0]: 100

pressure Wave 2 (imag part)[at point x=0]: 0

Please note that “pressure Wave 2 (imag part)” MUST be zero! But instead of this only possible accurate solution Elmer provides a wrong solution with these values:

pressure Wave 1 (real part)[at point x=0]: =70.71

pressure Wave 2 (imag part)[at point x=0]: =70.6308

Now the confusion gets squared here again, because if we have defined the input wave using its effective value, then we would logically expect the Elmer solution to be also given as effective values. But if these are effective values and we want to calculate the instantaneous pressure in time domain, then first we must convert these effective values back to amplitudes, which would be:

pressure Wave 1 amplitude (real part)[at point x=0]: ~100

pressure Wave 2 amplitude (imag part)[at point x=0]: ~100

Why does this lead to confusion? Because the time domain amplitude of this wave would be p_amp=sqrt(100^2+100^2)= 141.42 Pa, which is obviously wrong.

Therefore, the complex pressure components of the Elemer solution can not possibly be effective values, but must be amplitudes. If this is so, then the user is utterly confused, because when setting up the project effective values are demanded to define input waves, but apparently the output values of the solution are not effective values, but rather amplitudes!

Now out of good will we gulp down this inconsistency, and let’s assume that the solution is meant to represent complex amplitudes. In that case the time domain amplitude of the pressure would be p_amp=sqrt(70.71 ^2+70.6308^2)= 99.94, Pa which is close enough to the expected 100 Pa. So far so good, but even in this case the solution is still wrong! Why? Because the phase angle of the complex pressure is not zero as it supposed to be (it must be identical with the phase angle of the input wave), but it is -45 degrees instead.

In time domain this means that the instantaneous pressure at time t=0 at point x=0 is

p(t)=Re(P*exp(i*om*t)=Re(P)*cos(om*t) – Im(P)*sin(om*t)

p(0)=Re(P)*cos(om*t) = Re(P)= 70.71 Pa,

which is incorrect, because the input pressure at t=0 at x=0, p(0,0)=100 Pa, and in the absence of reflections, the instantaneous pressure of the Elmer solution must be the same!

Takala wrote:
“If you concentrate only on the time variable, then you should choose a point where you inspect the amplitude.”

I have chosen the point of x=0 in my previous explanations (and above as well), which you should have already realized if you would really be interested in being constructive.

Takala wrote:
“Generally, the resultant of the two pressure components should be 70.71 as you have set. And additionally at the *boundary* you set the amplitude explicitly to 70.71 (re) and 0 (im), it should be so.”

It should be so, but as demonstrated, it is NOT so, which makes the solution wrong.

Takala wrote:
“However in some other point in space the amplitude can be a mix of the two components but the resultant needs to equate to the set value. Just remember that you have only explicitly set the amplitude at the boundary!”

There is no “however” here! I have explicitly and exclusively examined the pressure at one single specific point of x=0 in order to make my arguments as simple as possible. If the solution would be correct at this trivial point then we could take a step further and check the validity of the results at other points as well. But as long as the solution is wrong even at this point, it is totally meaningless to talk about pressures at other points.

Takala wrote:
“You can also check that wherever the p1 amplitude is 70.71 then p2 needs to be zero and vice versa.”

I have already shown several times (and you can also see it for yourself if you would really care), that the imaginary part of the solution p2 is NOT zero! This makes the solution wrong! Why is it so difficult to understand so trivially simple things?

To summarize the problems, inconsistencies, awkwardness, and errors again:

1) The input waves supposed to be defined as pressure amplitudes (not as effective values, because this leads to confusion as this case demonstrates).

2) The impedance of boundaries supposed to be given as properly defined in acoustics as rho*c and not as c only (source of confusion again)

3) The output result of the Elmer solver supposed to be consistent with the definition of the input pressures, namely they should be amplitudes as well (and not effective values).

4) Both the real and imaginary parts of the complex pressure of the solution must be correct, not only the real part (or only the imaginary part). In time domain this requirement means that both the pressure amplitude AND also its phase angle must be correct (not only the amplitude).

Did you write the code of the Helholz Solver?

Joe