Wikiversity:Semantic templates/Environments design/Latex

%Exercisedesign

\newcommand{\inputexercise}[4]{\exercisepreskip \begin{exercise} \pointmarks {#1} \exercisemarkskip #2 #3 #4\end{exercise} \exercisepostskip}


\newcommand{\inputexerciseexistssolution}[4]{\exercisepreskip \begin{exercise}\hspace{-1.8 mm}* \pointmarks {#1} \exercisemarkskip #2 #3 #4\end{exercise} \exercisepostskip}

\newcommand{\inputexercisemarknumberbyhand}[3]{\exercisepreskip {\bf Exercise #1} (#2 marks) \exercisemarkskip #3 \exercisepostskip}

\newcommand{\inputexercisesolution}[2]{ \begin{exercise} #1 \end{exercise} \exercisepostskip


\bigskip

Solution

\bigskip #2

}


\newcommand{\inputexerciseexamsolution}[3]{\par \newpage \begin{exercise} {\ifthenelse {\equal {#1}{}}{} {\ifthenelse {\equal {#1}{1}} {(1 marks)} {(#1 marks)}}} \par \bigskip #2 \end{exercise} \underline{Solution:} \par \bigskip #3 }



\newcommand{\inputexercisesolutionvar}[2]{\exercisepreskip exercise: #1 \exercisepostskip Solution: #2}


\newcommand{\inputexercisemarkssolution}[3]{\exercisepreskip \begin{exercise} {\ifthenelse {\equal {#1}{}}{} {\ifthenelse {\equal {#1}{1}} {(1 mark)} {(#1 marks)}}} \exercisemarksskip #2 \end{exercise} \exercisepostskip \solution #3}

\newcommand{\solution}[1]{\underline{Solution:} #1}

\newcommand{\pointmarks}[1]{\ifthenelse {\equal {#1}{}}{} {\ifthenelse {\equal {#1}{1}} {(1 marks)} {(#1 marks)}}}



%Example design

\newcommand{\inputexample}[2] {\examplepreskip \begin{example} \examplename{#1} \examplenamepostskip #2 \end{example} \examplepostskip}


\newcommand{\examplename}[1]{ \ifthenelse {\equal {#1}{} \OR \equal {#1}{ } }{}{(#1)} }


%Remark design

\newcommand{\inputremark}[2] {\remarkpreskip \begin{remark} \remarkname{#1} \remarknamepostskip #2 \end{remark} \remarkpostskip}


\newcommand{\remarkname}[1]{ \ifthenelse {\equal {#1}{} \OR \equal {#1}{ } }{}{(#1)}}


\newcommand{\inputmethod}[2] {\remarkpreskip \begin{method} \remarkname{#1} \remarknamepostskip #2 \end{method} \remarkpostskip}


\newcommand{\inputconstruktion}[2] {\remarkpreskip \begin{construktion} \remarkname{#1} \remarknamepostskip #2 \end{construktion} \remarkpostskip}


\newcommand{\inputquestion}[2] {\remarkpreskip \begin{question} \questionname{#1} \remarknamepostskip #2 \end{question} \remarkpostskip}

\newcommand{\questionname}[1]{ \ifthenelse {\equal {#1}{} \OR \equal {#1}{ } }{}{(#1)}}



\newcommand{\inputproblem}[2] {\remarkpreskip \begin{problem} \problemname{#1} \remarknamepostskip #2 \end{problem} \remarkpostskip}

\newcommand{\problemname}[1]{ \ifthenelse {\equal {#1}{} \OR \equal {#1}{ } }{}{(#1)}}



%Situation design \newcommand{\inputsituation}[2] {\begin{situation} \situationname{#1} #2 \end{situation} }

\newcommand{\situationname}[1]{\ifthenelse {\equal {#1}{} \OR \equal {#1}{ } }{}{(#1)}}

%Definition design

\newcommand{\inputdefinition}[2] {\definitionpreskip \begin{definition} \definitionname{#1} \definitionnamepostskip #2 \end{definition} \definitionpostskip}


\newcommand{\inputaxiom}[2] {\definitionpreskip \begin{axiom} \definitionname{#1} \definitionnameskip #2 \end{axiom} \definitionpostskip}


\newcommand{\definitionname}[1]{\ifthenelse {\equal {#1}{} \OR \equal {#1}{ } }{}{(#1)}}


\newcommand{\inputnotation}[2] {\definitionpreskip \begin{notation} \definitionname{#1} \definitionnamepostskip #2 \end{notation} \definitionpostskip}


%Fact- and proof design


\renewcommand{\proofname}{\hspace{0cm}{\it Proof}}

%\newcommand{\proof}[1]{\begin{proof} #1 \end{proof}}


\newcommand{\inputfact}[4] {\factpreskip \begin{#2}

%\label{#1}

\factname{#3} \factnamepostskip #4 \end{#2} \faktpostskip }



\newcommand{\inputfactproof}[5] {\factpreskip \begin{#2}

%\label{#1}

\factname{#3} \factnamepostskip #4 \end{#2} \factpostskip \proof{#5}}




\newcommand{\inputfactproofnotpresented}[5]{\inputfactproof {#1} {#2} {#3} {#4} {This proof was not presented in the lecture.} }




\newcommand{\inputfactprooftrivial}[4]{\inputfactproof {#1} {#2} {#3} {#4} {This is trivial.} }





\newcommand{\inputproof}[1]{\proof{#1} }



\newcommand{\factname}[1]{\ifthenelse {\equal {#1}{} \OR \equal {#1}{ } }{}{(#1)}}


%Design of fact structure

\newcommand{\factsituation}[1]{\factsituationskip #1}

\newcommand{\factcondition}[1]{\factconditionskip #1}

\newcommand{\factconditionempty}[1]{ \hspace{-0,15cm} }

\newcommand{\factconditionpos}[1]{\factconditionskip #1}

\newcommand{\factsegue}[1]{\factsegueskip #1}

\newcommand{\factsegueempty}[1]{\factsegueskip \hspace{-0,15cm} }

\newcommand{\factconclusion}[1]{\factconclusionskip #1}

\newcommand{\factextra}[1]{\factextraskip #1}