Changeset 8792


Ignore:
Timestamp:
Mar 30, 2013, 12:56:51 AM (12 years ago)
Author:
mungkasi
Message:

Automated report for rundown_mild_slope.

Location:
trunk/anuga_core/source/anuga_validation_tests/Analytical_exact/rundown_mild_slope
Files:
2 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/anuga_core/source/anuga_validation_tests/Analytical_exact/rundown_mild_slope/plot_results.py

    r8651 r8792  
    4646#--------------------
    4747pyplot.clf()
    48 pyplot.ion()
    4948
    5049line, = pyplot.plot( (p2.x[v].min(),p2.x[v].max()) ,( (p2.stage[:,v]-p2.elev[:,v]).max(),(p2.stage[:,v]-p2.elev[v]).min() ) )
  • trunk/anuga_core/source/anuga_validation_tests/Analytical_exact/rundown_mild_slope/produce_results.py

    r8739 r8792  
    1515    run_validation_script('run_channel.py')
    1616    run_validation_script('plot_results.py')
     17    run('pdflatex', 'report.tex')
     18    run('bibtex', 'report')
     19    run('pdflatex', 'report.tex')
     20    run('bibtex', 'report')
     21    run('pdflatex', 'report.tex')
     22    run('bibtex', 'report')     
    1723
    1824def clean():
  • trunk/anuga_core/source/anuga_validation_tests/Analytical_exact/rundown_mild_slope/results.tex

    r8651 r8792  
    55
    66\section{Shallow flow down a mild slope}
    7 This case simulates very shallow flow running down a mild slope topography. It represents an idealisation of the rainfall-runoff problem, which will often involve very shallow flows down such a topography. This case has an analytical solution (the steady-uniform solution, bed slope = friction slope).   
     7This case simulates very shallow flow running down a mild slope topography. It represents an idealisation of the rainfall-runoff problem, which will often involve very shallow flows down such a topography. This case has an analytical solution, and in particular, we consider the steady-uniform solution with the values of bed slope and friction slope are the same.   
     8
     9Suppose that we are given a one dimensional domain. The steady state conditions with a contant water depth everywhere make the shallow water equations to the single identity
     10\begin{equation}
     11z_x = - S_f.
     12\end{equation}
     13Here $q=uh$ is the momentum or water discharge and $S_f$ is the symbol for the force of bottom friction involving Manning's coefficient $n$. We take
     14\begin{equation}
     15S_f = n^2 \frac{q|q|}{h^{10/3}}.
     16\end{equation}
     17If $q$, $n$, and $z_x$ are given, then the analytical solution is
     18\begin{equation}
     19u(x)= \left[- n^{-2} q^{4/3} z_x\right]^{3/10},
     20\end{equation}
     21\begin{equation}
     22h(x)= \frac{q}{u}\,.
     23\end{equation}
    824
    925\subsection{Results}
     26For our test, we consider a square dimensional domain with length and width 100. We take $q=0.2$, $n=0.03$, and $z_x=-0.1$.
     27The topography is
     28\begin{equation}
     29z(x, y)= -0.1 x\,.
     30\end{equation}
     31The initial condition is $u=v=0$ and
     32\begin{equation}
     33w(x,y,0)= -0.1 x + 0.01\,.
     34\end{equation}
     35
     36
     37Some simualtion results are as follows.
    1038Figures~\ref{fig:depthdownchan} shows the steady state depth in the downstream direction. There should be a good agreement with the analytical solution, at least away from the boundaries. 
     39Figures~\ref{fig:xvelscrosschan} and~\ref{fig:yvelscroschan} show the steady state $x$- and $y$-velocities, along a slice in the cross slope direction (near $x=50$). The $x$-velocities should agree well with the analytical solution, and the $y$-velocities should be zero.
    1140
    1241\begin{figure}[h]
     
    1746\end{center}
    1847\end{figure}
    19 
    20 Figures~\ref{fig:xvelscrosschan} and~\ref{fig:yvelscroschan} show the steady state $x$- and $y$-velocities, along a slice in the cross slope direction (near $x=50$). The $x$-velocities should agree well with the analytical solution, and the $y$-velocities should be zero. 
     48 
    2149
    2250\begin{figure}[h]
  • trunk/anuga_core/source/anuga_validation_tests/Analytical_exact/rundown_mild_slope/run_channel.py

    r8678 r8792  
    2626from anuga.utilities.argparsing import parse_standard_args
    2727alg, cfl = parse_standard_args()
    28 alg = '2_0'
    2928domain.set_flow_algorithm(alg)
    3029domain.set_CFL(cfl)
     
    6059Br = anuga.Reflective_boundary(domain) # Solid reflective wall
    6160domain.set_boundary({'left': BdIN, 'right': Bt, 'top': Br, 'bottom': Br})
     61
     62
     63#------------------------------------------------------------------------------
     64# Produce a documentation of parameters
     65#------------------------------------------------------------------------------
     66parameter_file=open('parameters.tex', 'w')
     67parameter_file.write('\\begin{verbatim}\n')
     68from pprint import pprint
     69pprint(domain.get_algorithm_parameters(),parameter_file,indent=4)
     70parameter_file.write('\\end{verbatim}\n')
     71parameter_file.close()
     72
    6273#------------------------------------------------------------------------------
    6374# Evolve system through time
Note: See TracChangeset for help on using the changeset viewer.