# Discussions Study Questions

Teacher Philipp Schlatter created page 7 March 2012

commented 10 March 2012

Hej,

I have a mathematical question concerning study question 21:

How is the mathematical way to follow from the advection equation u_t=-a*u_x that u_tt=a^2*u_xx?

Thank you!

commented 10 March 2012

Hej,

if you derive the advection equation with respect to t you get

u_tt=-a*(u_x)_t=-a*(u_t)_x=-a*(-a*u_x)_x=a^2*u_xx

commented 10 March 2012

Thanks a lot!

commented 11 March 2012

Hi,

I have a question concerning exercise 14 part b, and more specifically the part we should derive a condition relating sigma and vita.

Should we take into account the third term of the sinusTaylorexpansion or just assume sin(ksi*Dx)~ksi*Dx ?

Thanks, Michail.

Teacher commented 11 March 2012

Hi,

it is sufficient to only take into accoutn ksi*Dx for sin(ksi*Dx).

Philipp

Teacher commented 12 March 2012

An alternative way to show that u_tt=a^2 u_xx is:

do the derivative of u_t+au_x=0 with respect to x, and then with respect to t. Then, you will get in each a equation a term u_xt and u_tx which are the same due to the symmetry of secondary derivatives. Eliminating thus this terms gives the u_tt=a^2 u_xx.

But of course the above derivation is equivalent.

Philipp

commented 13 March 2012

Hi,

I have a question about the definition "ABSOLUTE STABILITY" of a scheme. Does it mean:

a) the scheme is stable when the analytical solution is stable or

b) the scheme is always stable, even if the analytical solution is unstable?

Besides that, if I say "the scheme is "UNCONDITIONALLY STABLE", is this statement equivalent to "the scheme is ABSOLUTE STABLE"?

commented 13 March 2012

Hello,
there is one question conserning question 29 (b). Which type of discontinuity is excuded and why? Is it discontinuity of entropy over the shock? Why can we exclude it? We have done the same in the simulation of the shocktube (home work 4), did we neglect something?

Teacher commented 13 March 2012

Concerning the question about absolute stability:

A scheme is absolutely stable if the complete left half-plane is stable (i.e. included in the region of absolute stability of the scheme). This corresponds to your option a).

For the term "unconditionally stable" I guess there are various interpretations possible. My definition would be that unconditionally stable would be much stronger, i.e. including the complete plane (corresponding to your option b) ).

Philipp

Teacher commented 13 March 2012

Concerning the shock tube:

In question 29, we assume the isentropic Euler equations, which is the same as in HW4 (leading to weak shocks). The full Euler equations would have one equation (energy equation) more, i.e. three components. Therefore, we would also get three different characteristics instead of only two as in the example (see notes Lecture10.pdf page 6). The additional feature absent in the isentropic case is the "contact discontinuity", characterised by the same pressure but different densities. The reason for this discontinuity is that it separates regions that have been processed by the shock on the right and by the expansion fan on the left, which leaves the two regions on different entropy levels. However, if these are not allowed due to an isentropy condition, this discontinuity disappear.

Philipp

commented 13 March 2012

One question to number 28:

Is there a mathematical difference between the terms "physical" and "numerical" boundary conditions? Or is the difference just the reason why they are needed, e.g. the relation to the number of ingoing characteristics?

Tack.

Teacher commented 14 March 2012

What we call "physical" boundary conditions are the ones that are needed to solve the physical (or mathematical) problem. For instance that means that in situations where we  solve the advection equation and we have outflow, then no physical condition is allowed.

Numerical conditions are not needed from the mathematical/physical point of view, i.e. specifying them would render the system ill posed. These are needed for certain (e.g. central) discretisation schemes and must be obtained via extrapolation from the inside.

Philipp

commented 14 March 2012

I have some doubts about the question 26:

- The linearisation I did for the barotropic gas dynamic equation give the correct result except the denominator of the last equation:

to get rid the last rho' we have to suppose that it is negligible compared to rho_0?

- Moreover  I found that this system is hyperbolic with characteristics =+-a

However I do not get what does it mean characteristic variables thus the characteristic formulation we have to write there.

- Another question is, how much deep we have to go for the last questions? The answer for some of them is the entire topic of 1 lecture,  I want to know, if it is possible, if we have to write every steps or a summary is sufficient.

Thank you

Fabio

commented 14 March 2012

I also spent hours with this question 26. The trick is to write the system in the linear form q_t+A*q_x=0, where q is the vector with conservative quantities rho and u.

Then you can diagionalize A=V*L*Vinv (L is diagional matrix with eigenvalues, and V is matrix whose columns are eigenvectors of A), so your system can be written as Vinv*q_t+L*Vinv*q_x=0. This becomes decoupled system with characteristic variables: w_t+L*w_x=0, where characteristic variable is w=Vinv*q. Further you can solve the system analyticaly for w=w_0 (x-lamda*t), and obtain q as V*w.

I hope this helps.

commented 14 March 2012

Hej Slobodan

Really thank you for the answer!!! I get your point and i is a very smart way to find the solution...however I get  as characteristic variables, I hope you have the same:)

The only thing is that I have a different result for the task e but I have to check it now...I think I made some mistakes:)

thank you again for the help!

commented 14 March 2012

I think the result I posted is wrong...

Teacher commented 15 March 2012

Hi,

regarding question 26: Indeed, you start with the variables in *primitive* variables, i.e. $(\rho, u)^T$. To then get to the characteristic variables, the idea is to diagonalise the matrix, as Slobodan writes above, this gives you the eigenvalues and eigenvectors, and with that the rule to transform the state variables into $Vinv*q$, which are called characteristic variables. In fact, the characteristic variables are also called Riemann invariants. In case of a linear problem, the eigenvalues are independent of the solution (for instance $a$ is independent of the solution $\rho$ or $u$), then the two equations are completely uncoupled and can be solved independently. In the general case, the characteristics speeds are only valid close to the point under consideration, but in general the two equations are still coupled (through the eigenvalue).

Hope this helps,

Philipp

Teacher commented 15 March 2012

Hi Fabio,

To get the second equation correctly you need to expand the term

in following way:

here the nonlinear terms are neglected and derivatives av set to zero as it's constant.

It is difficult to say how detauled the answer to study question should be, all steps that is neccessary to proof a theory should be possible to follow. Of course we may ask only about specicific parts of each study question which can require shorter answers.

Regards

Ardeshir

commented 8 March 2013

Hej,

I was wondering if the given approximation of question 23 should have a minus sign on the RHS instead of the plus sign as in the document.

Is that correct?

Teacher commented 8 March 2013

yes, sorry, this is correct. I updated the questions now.

Philipp

commented 9 March 2013

Hej,

I have a question about checking the well-posedness of the backward heat equation presented in the notes of Lecture 4 page 2. If we understood it properly, it says that the backward (implicit) scheme is ill-posed due to amplification of errors. However, performing a Von Neumann analysis, it is the forward (explicit) scheme the one amplificating errors, not the backward. We would like to know if it is a mistake in the lecture notes.

Thank you very much for your attention

Teacher commented 9 March 2013

Hi,

indeed, the inverse heat equation is ill posed, as the solution will be dominated by amplification of errors. Consider for instance the "natural" occurance of the inverse heat equation, namely the inverse problem of determining the initial distribution of heat if only the state after some time is known. Then the solution (i.e. the distribution at the earlier time) will depend strongly on the known final solution, i.e. the condition that we have a continuous dependence on the initial condition is not satisfied.

This has at that point nothing to do with implicit or explicit discretisation. Of course, one could use the amplification factor from one time to another to see whether you have growing solutions, but the ill-posedness is a property of the PDE rather than the discretisation.

HOpe this helps.

commented 11 March 2013

Hej,

I have a few questions about the study questions:

1- You talked above about the absolute stability but I didn't get the point. As for me , if only a region of the plane is stable ,that means that the scheme is not absolutely stable?

2-About question 21), I wrote dow the modified wave equation by using Taylor expansion, but I don't see what type of equation it is? I only know that it would have a dispersive behaviour.

3-About question 25), I don't know how to start, I have begun by trying to find the eigenvalues but I get nowhere.

4-About question 26), I have found the partial differential equations (question d) but I can't find tha analytical solution even if I star from the characteristic formulation.

Thank you very much for your help!

Teacher commented 11 March 2013

Hi, let my try to give you some hints:

1) yes, this is what absolutely stable means. If a time-integration scheme only has a part of the left-hand side, it might be stable (depending on the time step).

2) The idea is to see what the type of the equation becomes if you only retain the leading order error term (plus of course the terms corresponding to the original PDE). Then you can see what kind of behaviour the error will introduce (dispersion, diffusion).

3) You need to state the conditions for the matrix A if you have a hyperbolic system (what are the eigenvalues and eigenvectors doing).

4) once you have the characteristic form of the equation, you have two independent advection equations, right? So you can construct the solution by combining, in an appropriate way, the solutions of these two advection equations.

Hope this helps, Philipp

commented 12 March 2013

Yes, it helps thanks!

commented 14 March 2013

I have couple of questions about the study questions:

1- About question 39, how do we combine the stability limits , should we take  or should we derive another stability limit using both terms in the equation ? how can it differ for 2D case ?

2- About Euler equations, we tried to turn in into quasi-linear form but we don't know wether should we compute  regarding the conservative variables or  ? we tried both of them but non resulted as in the lecture notes. How should we proceed.

regards.

Teacher commented 14 March 2013

1) There are two ways to combine the stability limits: i) one takes the individual limits from the CFL condition (advection) and the diffusion (viscous limit) and takes the minimum. ii) for the advection -diffusion equation there is a combined limit (see study question 14), that add an additional expression (independent of the spatial grid). However, the derivation is a bit tricky (it has been wrong in the literature for nearly 50 years!). The changes when going to 2D are quite important, and this is what we discussed in the project lecture last week (notes).

2) To get the Euler equations in quasi-linear form, essentially you need to change the variables from the conservative ones (rho, rho u, E) to the primitive ones (rho, u, P). The derivation is a bit tedious, but it work in the end.

commented 13 March 2014

Hi,

When looking at question 42, what is the difference between this and Q16? Is there some special form of the advection-diffusion equation that we should use (part a?). And also, it is not stated what spatial discretizaiton to use in 42. I assume FTCS, but then doing "the terms seperately" (part c) gives that advection is unconditionally unstable - one can only get  from considering both together. To get normal CFL one needs to use FTBS/FTFS. Or am I missing something?

Thanks

JP

Teacher commented 13 March 2014

Question 42 is more general about the applicability of the advection/diffusion equation as a model. Therefore, also part c) is more open, and you can choose what scheme to take. Similarly d) does not require you to do the analysis, but rather to explain what you would be doing. When doing it separately, for c) you can also use the CFL condition and assume, that the diffusion is high enough to damp the instability of the central scheme.

Philipp

commented 13 March 2014

Ok Thanks, that makes some sense. With regard to part A though, is there some better form of the advection-diffusion equation that would be more suitable? As the regular advection terms do not appear as simply in the NS - or is it just a good trade off between having hyperbolic and elliptic parts and being easy?

One more quick question. When working with the dual grid for the first derivative, we had in lectures that . I cannot quite work out why. Applying divergence theory I would get something like . I'm sure there is something I am missing but I can't seem to work it out.

Thanks again

commented 14 March 2014

Isn't it because ?

commented 14 March 2014

Right, sorry that makes sense. Thanks!

commented 18 March 2014

Hej,

I have a question regarding the second part SQ33, why one does not use an artificial viscosity for upwind schemes.

As we discussed in the lecture, the leading error term of an first order upwind scheme is diffusive, and therefore we wouldn't need an artificial viscosity term, but is this the case for any other order aswell? Or was only a first order upwind scheme assumed in this question?

Randi

commented 18 March 2014

Question 37:

Can such a question in this extent really come up in the exam? I mean it is important to understand to concept to derive the Navier-Stokes equations on an arbitrary grid and to see that at the end it is equal to using a CDS on a Cartesian grid, but one needs a long time to do all derivations in part a) and b). And actually it is just a lot of maths...

Teacher commented 18 March 2014

Q33: yes, it was assumed that the upwind scheme is first order.

commented 20 March 2014

Hello

regarding the question 34 can you explain what exactly are the characteristics and the primitive variables?

Dimitris

commented 20 March 2014

Hi,

Regarding question 7 : in the c part can we use the same formula as in b to calculate the relative error? And when we use the term absolute error, we mean just the difference between the two values?

Regarding question 24 : can you point out in which lecture pdf can I find the solution?

Maria

commented 20 March 2014

Maria,

For the question 24 have a look at the lecture notes 10 on the first page.

Mickael

Teacher commented 20 March 2014

Q34: primitive variables: think of the system as dudt + A*dudx = 0, where u would be velocity and pressure.

conservative variables: think of the system as dvdt + d/dx f(v) = 0, where v might be mass, momentum, energy.

characteristic variables: think of the system as dwdt + B*dwdx = 0 with a diagonal B, such that the components in w are decoupled. This then relates to Riemann invariants, and can be used to determine numerical boundary conditions along characteristics. Note that we have this year NOT discussed that during the lecture.

Philipp

Teacher commented 20 March 2014

Q7: yes, you can use the same formula. The trick is to realise that you will get a drastic difference between absolute and relative error for the two cases (addition, difference).

Philipp

commented 20 March 2014

A more general question regarding consistency:

So we derive an expression for the truncation error and get the accuracy order from the exponents of Delta x respective Delta t. In most examples we had p=q. What happens if p isn't equal to q? Is the scheme then inconsistent? Or is it just the accuracy that is different for time and space discretisation?

Thanks, Randi

Teacher commented 20 March 2014

p does not need to be the same as q, but it needs to be such that the error really goes down by refining in time or in space. A typical example of a scheme that is NOT consistent is the Dufort Frankel method.

Philipp

commented 20 March 2014

So what was the deal with the Q37? I agree with Markus on that!

(Markus Christian Geisenhofer tisdag 17:26)

commented 11 March 2015

For Q39, are we taking the 2D case for the Navier Stokes Equations?

Teacher commented 11 March 2015

Yes.

commented 11 March 2015

Q39: I'm not quite sure then how to do the staggered grid because unlike the project, I'm guessing we're dealing with compressible flow. So would we also need to stagger density?

Cheers

Teacher commented 11 March 2015

We are considering the incompressible flow only.

commented 13 March 2015

Question 11 c is regarding the selection of an appropriate time integration scheme for a certain value of %lambda in the Dahlqvist equation. I would like to know the various considerations one would make.

I currently understand the considerations as stability, accuracy and computational memory, but what are their relative order of importance?

Teacher commented 13 March 2015

for part c) your points are correct. There is no general way of really saying which aspect is most important, it all depends on the specific circumstances you have for the problem at hand, e.g. how difficult is it to invert the matrix for the implicit scheme, how small is the time step really for the explicit one etc. The main answer comes from the consideration of the "time to solution", i.e. how long does the run really take to get a result with a certain accuracy.

for part d) it is important to understand the order of the two schemes, and maybe also look at the "intermediate" scheme, i.e. the Crank-Nicolson scheme. Also, for stiff problems one might need to look at the asymptotic behaviour, e.g. to avoid oscillating solutions.

Hth,

Philipp

commented 13 March 2015

Q19: Looking through the lecture notes for determining the Euler equations in conservative form, I understand why the viscous stress is removed, but I'm not quite sure why we also ignore heat dispersion, heat sources and gravity.

Assistant commented 13 March 2015

The most general form of the compressible Euler equations comprises heat transmission and generation and gravity (and in general body forces).
They are included even in the lecture notes (I am now looking at the first page of lecture8.pdf).
In flow cases where these contributions are absent or negligible, or if you want to simplify the treatment to show certain properties, they can be omitted from the equations, but in general they are present.
May I ask you what lecture notes you are referring to so that I may give a more specific answer?

Kind regards,
Jacopo

commented 14 March 2015

Same lecture, a bit further down on the 3rd page. Also searching around on the internet, these terms are generally omitted.

So just to confirm, we would usually be looking at cases where these components are negligible? Would there be any general case when they aren't then or is this a fair assumption?

Teacher commented 14 March 2015

It always depends on the flow situation which terms need to be taken into account, and which ones can be neglected; see for instance the discussion we had on that in my first lecture (physical modelling etc.). For instance, in aeronautics, gravity (and buoyancy) can usually be neglected, but if you consider problems with natural convection (like the Rayleigh-Bénard problem) these terms are the actual driving force. Similarly, when treating a flow to be inviscid, one would do the same approximation also for the heat diffusion.

Philipp

commented 14 March 2015

This is a general question. Do we need to memorise the open forms of the NS equations (continuity, momentum and energy) if, for instance, a question asks for a derivation of the nondimensional NS equations or the boundary layer equations or are they going to be available for us?

Best,

Emirhan

Teacher commented 14 March 2015

you would need to know the basic governing equations, like the continuity equation, momentum and energy equations, in their respective simplest form (compressible and incompressible). The exam is not about knowing a lot of equations by heart, but rather on testing some of the concepts, which however does require some basic equations.

Philipp

commented 14 March 2015

Would it be assume from the expressions for amplification factor for very stiff problems, the implicit scheme works better than crank nicolson?

commented 14 March 2015

*safe to

Teacher commented 14 March 2015

Crank-Nicolson is an implicit scheme as well. What you need to look at is the amplification factor for   and determine, which of the schemes is closest to the amplification factor of the exact solution during time .

commented 17 March 2015

Hej! For question 8, we did it in the lesson but we don't really understant why lambda = infinity. Lambda just seemed undefined. For question 16, there is an indication to neglect terms of order 4 but where do those terms come from? Thank you, Ambre

Teacher commented 17 March 2015

For question 8, you could also switch the denominator and numerator and your slope would then become zero, which is well defined.

In question 16, you get terms of order 4 when considering \xi \delta x = 0 because the approximation of the cosine already contains a square.

commented 17 March 2015

In question 16, I cannot get rid of the multiplier . I neglect the 4th order term as instructed, but then I get . Is the final condition supposed to be a function of and only or is it okay to leave the condition in the form I described above?

Teacher commented 18 March 2015

well, one should get a condition relating sigma and beta, both mulitplied by (\xi \Deltax)^2. Therefore, the latter can be divided by (because it is positive).

Philipp

commented 18 March 2015

I realized I was doing some miscalculations, that's why I didn't get a condition of . Thanks.

commented 18 March 2015

As I read in the previous comments we should know the compressible/incompressible Navier-Stokes, Euler etc. Regarding the formulas for the truncation/ propagation or the varius other equations that we dealt during the lectures should we know these as well or will they be given to us in case they are needed?

Thanks,
Nikos

Teacher commented 18 March 2015

In case you need truncation errors etc. you would be asked to derive it as part of an exam question. However, you might want to know the Burgers equation, advection equation, diffusion equation etc. and their respective characteristics.

Philipp

commented 9 March 2017

Hi!

Question 25. Is a general wave not expressed by u = u_hat*exp(i*(kx-wt)) ? In the study questions the imaginary unit i seems to be missing? According to the lecture notes it sure looks like the i should be there.

Regards

Assistant commented 9 March 2017

Hello,

if k and omega are complex numbers there is no reason to pre-multiply by i, it is just a matter of how you define k and omega and their real and imaginary parts.

Kind regards,
Jacopo

commented 13 March 2017

In questions 29 and 34 the so-called "Characteristic variables" and characteristic formulation are mentioned. What are they? I can't find them in my notes nor on the lecture notes here.

Regards,

Francesco

Teacher commented 13 March 2017

The characteristic variables are calculated by diagonalising the matrix, so that the new system essentially has the characteristic speed on the diagonal, and can be solved very easily as an ODE. One uses this formulation also to derive proper characteristic boundary conditions, as briefly mentioned in the context of the shock tube. However, we have not discussed this aspect during this year in more detail.

commented 16 March 2017

Question 48b:

in the lecture notes it is stated that Vc = h^2. However if we compute Vc with the formula:

we will get . Which is the correct one?

Thanks.

commented 16 March 2017

Question 7b and 7c:

I used equation (4) for calculating the relative error for both cases. Regarding the machine accuracy eps_aj, is it correct to use the machine epsilon or do we need to use 1/2 of the machine epsilon?

About the absolute error, is it sufficient to calculate it multiplying the relative error for (x+y) in the first case and (x-y) in the second one or do we need to proceed in another way?

Regards,

Francesco

Teacher commented 16 March 2017

for b), the epsilon given is directly the relative error.

for c) yes.

Teacher commented 16 March 2017

Regarding question 48b:

The correct volume is , which you will get if you use the relation

Note that  and  are vectors. So you need to account for the the direction of surface normals.

The normal vectors on the faces of dual grid cutting line  is  and  on the face cutting line  is .