Skip to content

Commit

Permalink
Remove empty parentheses that don't mean empty parentheses
Browse files Browse the repository at this point in the history
This change is related to the other changes where operators with function calling syntax are mentioned.
  • Loading branch information
henrikt-ma committed Jun 2, 2020
1 parent 16f659f commit ca5afe9
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 12 deletions.
2 changes: 1 addition & 1 deletion chapters/classes.tex
Expand Up @@ -378,7 +378,7 @@ \subsection{Component Variability Prefixes discrete, parameter, constant}\double
A \emph{discrete-time} variable \lstinline!vd! has a vanishing time derivative between events.
Note that this is not the same as saying that \lstinline!der(vd)=0! almost everywhere,
as the derivative is not even defined at the events, and it is not legal
to apply \lstinline!der()! to discrete-time variables as they are not continuous. During transient analysis the variable
to apply \lstinline!der! to discrete-time variables as they are not continuous. During transient analysis the variable
can only change its value at event
instants (see \autoref{events-and-synchronization}).
\item
Expand Down
2 changes: 1 addition & 1 deletion chapters/equations.tex
Expand Up @@ -311,7 +311,7 @@ \subsubsection{Restrictions on Equations within When-Equations}\doublelabel{rest
\item \lstinline!v = expr;!
\item \lstinline!(out1, out2, out3, ...) = function_call_name(in1, in2, ...);!
\item
operators \lstinline!assert()!, \lstinline!terminate()!, \lstinline!reinit()!
operators \lstinline!assert!, \lstinline!terminate!, \lstinline!reinit!
\item
For- and if-equations if the equations within the for- and
if-equations satisfy these requirements.
Expand Down
8 changes: 4 additions & 4 deletions chapters/operatorsandexpressions.tex
Expand Up @@ -481,7 +481,7 @@ \subsubsection{Event Triggering Mathematical Functions}\doublelabel{event-trigge
\lstinline!div(x,y)! & Returns the algebraic quotient \lstinline!x/y! with any fractional part
discarded (also known as truncation toward zero).
\begin{nonnormative}
This is defined for \lstinline!/! in C99; in C89 the result for negative numbers is implementation-defined, so the standard function \lstinline!div()! must be used.
This is defined for \lstinline!/! in C99; in C89 the result for negative numbers is implementation-defined, so the standard function \lstinline[language=C]!div! must be used.
\end{nonnormative}
Result and arguments shall have type \lstinline!Real! or \lstinline!Integer!. If
either of the arguments is \lstinline!Real! the result is \lstinline!Real! otherwise
Expand Down Expand Up @@ -810,7 +810,7 @@ \subsubsection{spatialDistribution}\doublelabel{spatialdistribution}
\end{lstlisting}

Events are generated at the exact instants when the velocity
changes sign -- if this is not needed, \lstinline!noEvent()! can be used to
changes sign --- if this is not needed, \lstinline!noEvent! can be used to
suppress event generation.

If the velocity is known to be always positive, then \lstinline!out0! can be omitted, e.g.:
Expand Down Expand Up @@ -1009,7 +1009,7 @@ \subsubsection{homotopy}\doublelabel{homotopy}
\subsubsection{semiLinear}\doublelabel{semilinear}

(See definition of \lstinline!semiLinear! in \autoref{derivative-and-special-purpose-operators-with-function-syntax}). In some situations,
equations with the \lstinline!semiLinear()! function become underdetermined if the
equations with \lstinline!semiLinear! become underdetermined if the
first argument (\lstinline!x!) becomes zero, i.e., there are an infinite number of
solutions. It is recommended that the following rules are used to
transform the equations during the translation phase in order to select
Expand Down Expand Up @@ -1363,7 +1363,7 @@ \subsection{Discrete-Time Expressions}\doublelabel{discrete-time-expressions}
argument is non-discrete time expression and subtype of \lstinline!Real!.
\begin{nonnormative}
These will generate events, see \autoref{events-and-synchronization}. Note that \lstinline!rem! and \lstinline!mod! generate events but are not discrete-time
expressions. In other words, relations inside \lstinline!noEvent()!, such as \lstinline!noEvent(x>1)!, are not discrete-time expressions.
expressions. In other words, relations inside \lstinline!noEvent!, such as \lstinline!noEvent(x>1)!, are not discrete-time expressions.
\end{nonnormative}
\item
The functions \lstinline!pre!, \lstinline!edge!, and \lstinline!change! result in discrete-time
Expand Down
2 changes: 1 addition & 1 deletion chapters/statemachines.tex
Expand Up @@ -157,7 +157,7 @@ \section{State Machine Graphics}\doublelabel{state-machine-graphics}
lines.
\end{nonnormative}

The annotation for graphics of \lstinline!transition()! has the following
The annotation for graphics of \lstinline!transition! has the following
structure: \lstinline[mathescape=true]!annotation(Line($\ldots$), Text($\ldots$))!; and for
\lstinline!initialState()!: \emph{graphical-primitives}\lstinline[mathescape=true]!(Line($\ldots$))!; with \lstinline!Line!
and \lstinline!Text! annotations defined in \autoref{annotations}.
Expand Down
9 changes: 4 additions & 5 deletions chapters/stream.tex
Expand Up @@ -405,11 +405,10 @@ \section{Stream Operator actualStream}\doublelabel{stream-operator-actualstream}
\end{lstlisting}

\begin{nonnormative}
The \textbf{actualStream}(v) operator is typically used in two
contexts:
\lstinline!actualStream! is typically used in two contexts:
\begin{lstlisting}[language=modelica]
der(U) = c.m_flow*actualStream(c.h_outflow); // (1) energy balance equation
h_c = actualStream(c.h); // (2) monitoring the enthalpy at port c
der(U) = c.m_flow * actualStream(c.h_outflow); // (1) energy balance equation
h_c = actualStream(c.h); // (2) monitoring the enthalpy at port c
\end{lstlisting}
In the case of equation (1), although \lstinline!actualStream!
is discontinuous, the product with the flow variable is not, because
Expand All @@ -424,7 +423,7 @@ \section{Stream Operator actualStream}\doublelabel{stream-operator-actualstream}
flowing through a port is. In this case, the user will probably want to
see the change due to flow reversal at the exact instant, so an event
should be generated. If the user doesn't bother, then he/she should
enclose the right-hand side of (2) with \lstinline!noEvent()!. Since the output of
enclose the right-hand side of (2) with \lstinline!noEvent!. Since the output of
\lstinline!actualStream! will be discontinuous, it should not be used by itself to
model physical behaviour (e.g., to compute densities used in momentum
balances) --- \lstinline!inStream! should be used for this purpose.
Expand Down

0 comments on commit ca5afe9

Please sign in to comment.