Changeset 4205


Ignore:
Timestamp:
Feb 1, 2007, 9:45:42 AM (18 years ago)
Author:
ole
Message:

Added a FAQ about model time based on Matt Barnes' question.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • anuga_core/documentation/user_manual/anuga_user_manual.tex

    r4123 r4205  
    763763
    764764\subsection{Changing boundary conditions on the fly}
     765\label{sec:change boundary}
    765766
    766767Here is the code for the second version of the channel flow \file{channel2.py}:
     
    789790    domain.set_boundary({'right': Bo})
    790791\end{verbatim}}
    791 This type of dynamically varying boundary could for example be used to model the
     792This type of dynamically varying boundary could for example be
     793used to model the
    792794breakdown of a sluice door when water exceeds a certain level.
    793795
     
    33323334
    33333335\subsubsection{Can I change boundary conditions during the simulation?}
    3334 Not sure, but it would be nice :-)
     3336Yes - see example on page \pageref{sec:change boundary} in Section
     3337\ref{sec:change boundary}.
     3338
     3339\subsubsection{How do I access model time during the simulation?}
     3340The variable \code{t} in the evolve for loop is the model time.
     3341{\small \begin{verbatim}
     3342    for t in domain.evolve(yieldstep = 0.1, duration = 4.0):
     3343        if t > 15:
     3344            <Do something>
     3345\end{verbatim}}
     3346The model time can also be accessed through the public interface \code{domain.get\_time()}, or changed (at your own peril) through \code{domain.set\_time()}.
     3347
    33353348
    33363349\subsubsection{Why does a file\_function return a list of numbers when evaluated?}
Note: See TracChangeset for help on using the changeset viewer.