Dimensionless Space and Time

Moderator: Mike Everman

WebPilot
Posts: 3716
Joined: Tue Dec 07, 2004 6:51 pm
Antipspambot question: 0
Location: 41d 1' N 80d 22' W

re: Dimensionless Space and Time

Post by WebPilot » Thu Dec 01, 2005 5:33 am

Hank wrote: ... Wave propagation. Figure out duct dimensions from the data you now have, Forrest.
Your drawing appears to be of a tube open on both ends. The drawing I
have posted is useless for your case.

-fde
Last edited by WebPilot on Sun Jan 07, 2007 1:49 am, edited 2 times in total.
Image

WebPilot
Posts: 3716
Joined: Tue Dec 07, 2004 6:51 pm
Antipspambot question: 0
Location: 41d 1' N 80d 22' W

re: Dimensionless Space and Time

Post by WebPilot » Thu Dec 01, 2005 9:49 am

Image

If one is interested in wave interaction details at later periods of time, then more
lines in the original expansion wave fan need to be drawn and allowed to develop. As
one can see from inspection of the diagram, things are getting sparse after Tau = 4.0.

However, one important fact is clearly illustrated - the shock wave approaches the
open end, which is now an area of subsonic inflow. It is reflected as an
expansion fan at point 46.

At point 46, the inflow 'jumps' from -0.3430 to -0.2030.

Image

-fde
Last edited by WebPilot on Sun Jan 07, 2007 1:52 am, edited 2 times in total.
Image

sam
Posts: 80
Joined: Mon Jan 26, 2004 5:40 pm
Antipspambot question: 0
Location: Stoke-on-Trent, England

re: Dimensionless Space and Time

Post by sam » Fri Dec 02, 2005 4:27 pm

Just to prove that my code (NUDiS) can be used to solve this problem too...
The code is different (better?) than UFLOW because it can model a proper closed end boundary condition.
Sam
Attachments
p.jpg
(72.14 KiB) Downloaded 607 times

WebPilot
Posts: 3716
Joined: Tue Dec 07, 2004 6:51 pm
Antipspambot question: 0
Location: 41d 1' N 80d 22' W

re: Dimensionless Space and Time

Post by WebPilot » Fri Dec 02, 2005 7:14 pm

Sam,

I was wondering if you were going to join the 'fun'.

Yes, approximating a closed boundary condition was one of the things that bothered me
about Uflow - among others.

Your code produces output in dimensionless parameters? Or did you non-dimensionalize
after a run with numbers?

We have a small timing discrepancy where the pressure discontinuity appears? - my point
31.

What method of solution are you using?

Regardless, pretty work.

-fde

PS Will your code plot out velocity vs. dimensionless time at the open end?
I'd like to see that plot.

After reading the user's document, I was able to answer some
of these questions myself. Results forthcoming.
Last edited by WebPilot on Sun Jan 07, 2007 1:58 am, edited 4 times in total.
Image

pezman
Posts: 613
Joined: Fri Oct 08, 2004 4:13 am
Antipspambot question: 0
Location: USA

re: Dimensionless Space and Time

Post by pezman » Fri Dec 02, 2005 9:10 pm

You can get code for a Riemann solver here:
http://www.physics.buffalo.edu/phy411-5 ... tml#topic7

.. along with notes that will help w/ understanding.

If you look in "shocktube.cpp", you'll see that a modeling a closed boundary condition is almost trivial.

I have been playing around w/ the code in my spare time and I get mysterious underflow problems -- so it was easy to compile but not so easy to get working (thus far).

WebPilot
Posts: 3716
Joined: Tue Dec 07, 2004 6:51 pm
Antipspambot question: 0
Location: 41d 1' N 80d 22' W

re: Dimensionless Space and Time

Post by WebPilot » Sat Dec 03, 2005 8:29 am

Cool site. If I passed that course which this problem is just a part of, I
would have flunked everything else, since I wouldn't have had any extra
time for other studies.

Keep plugging away pezman - you'll do it.

-----

Image

I, too, got NUDiS to solve this problem.

I had to use a text editor that was able to move 'columns' of data about between different
output files for plotting purposes. At least the output data is in ASCII. The editor I used
came from an operating system called 'PC-DOS version 6'.

NUDiS requires #'s to work, so if you want to plot dimensionless time, Tau, you have to
multiply the program's 'time.dat' file by the suitable parameters to make it dimensionless
and then plot it out.

The documentation for 'Output frequency' in 'inputs.dat' needs a little more clarification.

In 'geom.dat ', I assume the Duct diameter and Wall thickness, are expressed in meters.

I don't like the idea of entering 256 columns of data for input. I would prefer 256 ROWS
since it would be so much easier to enter data and keep track of where I am.

Now, this may read like I am bad mouthing the code, and I am not.

It can model a closed end which Uflow cannot. I can test the code's number crunching
abilities by testing it say, with this problem, but more importantly, a shock tube.

The more interesting of the 2 graphs is this one. I posted my earlier not knowing what
exactly is was supposed to look like. There indeed seems to be a discontinuity in the
flow velocity around my point, 46 (around Tau = 4.5). The initial amplitude is 0.7 not the
0.8 I computed ... hmmm.

Image

-fde
Last edited by WebPilot on Sun Jan 07, 2007 2:04 am, edited 3 times in total.
Image

mk
Posts: 1053
Joined: Mon Jan 19, 2004 8:38 pm
Antipspambot question: 0
Location: FRG

re: Dimensionless Space and Time

Post by mk » Sat Dec 03, 2005 11:16 am

Very interesting, again. Too bad I actually don't know too much about that stuff.

A general questions: The initial fan existance is the result of the assumtion dp happening not instantly, but in dt, right? Thus these fan lines are just for complexicity reduction of plotting numerous graphs equaling a plane, correct?
Last edited by mk on Sat Dec 03, 2005 12:38 pm, edited 1 time in total.
mk

sam
Posts: 80
Joined: Mon Jan 26, 2004 5:40 pm
Antipspambot question: 0
Location: Stoke-on-Trent, England

re: Dimensionless Space and Time

Post by sam » Sat Dec 03, 2005 12:12 pm

Forrest,
I suspect that the discrepancy in the velocity plot is because my open-end boundary condition is different to yours. I think I'm right in saying that you have been assuming that the static pressure stays constant at one atmosphere at all times at the open boundary. This is the usual "open-end boundary" assumption, and is used in UFLOW too.
NUDiS makes a different assumption: The static pressure is held constant during outflow only. During inflow the static pressure is allowed to reduce from the atmospheric value. Physically, this models a separated jet during outflow, and reversible sink flow during inflow. Its a more correct interpretation of what actually happens at a pulsejet exhaust/inlet, but only really becomes significant at relatively high flow velocities.
NUDiS is capable of simulating shock tube problems. You can compare the results with an exact Riemann solver for accuracy. As with all numerical simulations, the accuracy will reduce as the shock strength increases.
I'm sorry you don't particularly like the way that data is input. This method of data entry is very convenient for me, and I'm not really prepared to go changing this now. Mike E. is working on a frontend interface for the code which should alleviate any problems you may be having, if all goes well.
Sam

PS. The 'output frequency' basically tells the software how often you want to dump a solution to file. It has to be an integer >=1. e.g. If you set it to 50 then it dumps a solution every 50 timesteps.

pezman
Posts: 613
Joined: Fri Oct 08, 2004 4:13 am
Antipspambot question: 0
Location: USA

Modeling "closed end" boundary conditions in UFLOW

Post by pezman » Sat Dec 03, 2005 3:27 pm

One way to model a closed end in UFLOW is to make a "mirror image" of the structure being tested. Initial conditions must also be a "mirror image" about the center point (i.e. they match in terms of pressure and temperature, and must be opposite in terms of initial flow speed). This requirement of matching P, T and opposing flow speeds applies to the ICs at the open ends of the tube as well.

Then, just run the simulation and discard all data to the left of the "mirror" point.

WebPilot
Posts: 3716
Joined: Tue Dec 07, 2004 6:51 pm
Antipspambot question: 0
Location: 41d 1' N 80d 22' W

re: Dimensionless Space and Time

Post by WebPilot » Sat Dec 03, 2005 9:51 pm

Hey Marten,

Wie Geht's?

Probably the simplest explanation I can give for what is going on initially is that as soon
as the 'frangible' diaphragm is broken, flow comes out. Right? Well, the wave cannot be
one of compression, because it would 'push' the flow back in. This wave is propagating to
the left and 'pulling' the air out, thus, it must be an expansion wave.

A centered expansion wave is created by an 'instantaneous' decrease of pressure
at some point of the duct.

As far as why it is a 'fan' is because, it is a continuous 'array' of expansion waves originating
at some point. I have chosen the 'head' and 'tail' and a few in between. There are many
more in between.

Fröhliches Weihnachten!

-fde

-----
Sam wrote: I suspect that the discrepancy in the velocity plot is because my open-end boundary
condition is different to yours. I think I'm right in saying that you have been assuming that
the static pressure stays constant at one atmosphere at all times at the open boundary. This
is the usual "open-end boundary" assumption, and is used in UFLOW too.
Nope. I am not assuming that. See graph.

Image Image
Sam wrote: NUDiS makes a different assumption: The static pressure is held constant during outflow
only.
Well, at points 0 and 6, there is outflow. By your admission, the
static pressure should be atmospheric. Yours, Larry's and my plots all
agree on the pressure vs time. Something else is amiss, here for
velocity vs tau.

Hey pezman or Larry, can Uflow do an exit velocity vs. Tau plot at Xi=1.0?
Sam wrote: I'm sorry you don't particularly like the way that data is input. This method of data entry is very convenient for me, and I'm not really prepared to go changing this now. Mike E. is working on a frontend interface for the code which should alleviate any problems you may be having, if all goes well.
Well, it's just a matter of preference. Don't take it personally. Mike E.'s front end is based
on Excel and macros. I know he's doing a wonderful job, but don't think everyone has Excel
on their machines. I do, but am not too excited about Excel's graphics capabilities. I may
have to write some utilities.
Sam wrote: PS. The 'output frequency' basically tells the software how often you want to dump a solution to file. It has to be an integer >=1. e.g. If you set it to 50 then it dumps a solution every 50 timesteps.
Forgive my ignorance, but how do you 'compute' the time step during the data input stage?

Cheers,

-fde
Last edited by WebPilot on Sun Jan 07, 2007 2:10 am, edited 6 times in total.
Image

WebPilot
Posts: 3716
Joined: Tue Dec 07, 2004 6:51 pm
Antipspambot question: 0
Location: 41d 1' N 80d 22' W

re: Dimensionless Space and Time

Post by WebPilot » Sat Dec 03, 2005 10:46 pm

Yep, it's a 'filler' or 'stub' meant to keep you interested until I get the correct
graphic up. I see it was a good choice and it's working. he he he

-fde
Last edited by WebPilot on Sun Jan 07, 2007 2:08 am, edited 2 times in total.
Image

sam
Posts: 80
Joined: Mon Jan 26, 2004 5:40 pm
Antipspambot question: 0
Location: Stoke-on-Trent, England

re: Dimensionless Space and Time

Post by sam » Sat Dec 03, 2005 11:26 pm

[quote]Forgive my ignorance, but how do you 'compute' the time step during the data input stage?[/quote]

The timestep is calculated by a stability crtierion (or CFL criterion as its usually called). You can't really work it out before hand, and the program calculates it as it goes along.

Its given by C * dx / max(a+u)

where C is the CFL number (I think its set as 0.5 in 'inputs.dat')
dx is the cell length (= duct length / number of cells)
a is the sonic velocity
u is the particle velocity


Not sure why the velocity should be different. I'll have to think about that for a bit longer...

sam
Posts: 80
Joined: Mon Jan 26, 2004 5:40 pm
Antipspambot question: 0
Location: Stoke-on-Trent, England

re: Dimensionless Space and Time

Post by sam » Sat Dec 03, 2005 11:53 pm

fde,
I've just checked my solution to the problem and I too get an initial outflow Mach Number of 0.8, as your Method of Characteristic solution suggests. I'm not sure where you went wrong... maybe you weren't normalising the velocity by the correct speed of sound?
sam
Attachments
M.jpg
(87.03 KiB) Downloaded 664 times

pezman
Posts: 613
Joined: Fri Oct 08, 2004 4:13 am
Antipspambot question: 0
Location: USA

Shock Tube animation

Post by pezman » Sun Dec 04, 2005 1:08 am

I managed to get my 1D Euler prototype working -- not perfectly, but not bad.

Here is an animation of a shock tube simulation. The left half of the tube has air whose density is "3" and whose pressure is "3", while the right half has air that is at a density of "1" and a pressure of "1".

All of the units are essentially dimensionless. I'll need to do some test problems to get the simulator to accept real-world physical units and set up problems using practical terms (e.g. specifying initial conditions in terms of presure and temperature).


Once that is done, I'll add some code to put an automation wrapper around it, so that Excel, VB etc. can be used to set up simulations. That should make it easier to set up PJ-style simulations (e.g. you can heat the fluid every cycle).

I'm also hoping to be able to set the simulation up so that you can have multiple boindary conditions at a point (e.g. to simulate the two rear-facint tubes of a Chinese valveless).

At any rate, here's the animation -- my apologies for its hugeness.

Note: it takes about 10 seconds before the animation actually starts moving.
Attachments
capture_20051204_004851.zip
(474.87 KiB) Downloaded 668 times

WebPilot
Posts: 3716
Joined: Tue Dec 07, 2004 6:51 pm
Antipspambot question: 0
Location: 41d 1' N 80d 22' W

Re: re: Dimensionless Space and Time

Post by WebPilot » Sun Dec 04, 2005 3:02 am

Image

As you can see, the pressures at the open end determined by the 2
methods are comparable - virtually exact for outflow.
sam wrote: The timestep is calculated by a stability criterion (or CFL criterion as its
usually called) ...
Ah, the ol' Courant-Friedrichs-Lewy stability criterion, I should have
known.
sam wrote: I've just checked my solution to the problem and I too get an initial
outflow Mach Number of 0.8, as your Method of Characteristic solution
suggests. I'm not sure where you went wrong... maybe you weren't
normalising the velocity by the correct speed of sound?
sam
It's cool that your model matches my MOC analysis. It's not so cool I
can't get my model using your code to do so, too - although I am close
with it.

Well, I might have used the wrong speed of sound for non-dimensionalizing
the flow velocity. I used 347.2 m/sec (the speed of sound in air at 300°K).

Why not POST your model's data files?

-fde
Last edited by WebPilot on Sun Jan 07, 2007 2:12 am, edited 2 times in total.
Image

Post Reply