51 {Integrating Computation and Deduction\\ |
51 {Integrating Computation and Deduction\\ |
52 in the \isac-System} |
52 in the \isac-System} |
53 |
53 |
54 \subtitle{Projektpraktikum: Introducing Isabelle's Contexts} |
54 \subtitle{Projektpraktikum: Introducing Isabelle's Contexts} |
55 |
55 |
56 \author[Lehnfeld, Neuper] % (optional, use only with lots of authors) |
56 \author[Lehnfeld] % (optional, use only with lots of authors) |
57 {Mathias~Lehnfeld\inst{1} \and Walther~Neuper\inst{2}} |
57 {Mathias~Lehnfeld} |
58 % - Give the names in the same order as the appear in the paper. |
58 % - Give the names in the same order as the appear in the paper. |
59 % - Use the \inst{?} command only if the authors have different |
59 % - Use the \inst{?} command only if the authors have different |
60 % affiliation. |
60 % affiliation. |
61 |
61 |
62 \institute % (optional, but mostly needed) |
62 \institute % (optional, but mostly needed) |
63 { |
63 { |
64 \inst{1}% |
64 Vienna University of Technology\\ |
65 Vienna University of Technology |
65 Institute of Computer Languages |
66 \and |
|
67 \inst{2}% |
|
68 Institute of Software Technology\\ |
|
69 Graz University of Technology |
|
70 } |
66 } |
71 % - Use the \inst command only if there are several affiliations. |
67 % - Use the \inst command only if there are several affiliations. |
72 % - Keep it simple, no one is interested in your street address. |
68 % - Keep it simple, no one is interested in your street address. |
73 |
69 |
74 % \date[CFP 2003] % (optional, should be abbreviation of conference name) |
70 % \date[CFP 2003] % (optional, should be abbreviation of conference name) |
136 % you think necessary. |
132 % you think necessary. |
137 % - If you omit details that are vital to the proof/implementation, |
133 % - If you omit details that are vital to the proof/implementation, |
138 % just say so once. Everybody will be happy with that. |
134 % just say so once. Everybody will be happy with that. |
139 |
135 |
140 \section[Introduction]{Introduction} |
136 \section[Introduction]{Introduction} |
141 \subsection[TODO]{Isabelle and \isac} |
137 \subsection[Isabelle \& \isac]{Isabelle and \isac} |
142 \begin{frame} |
138 \begin{frame} |
143 \frametitle{Isabelle and \isac} |
139 \frametitle{Isabelle and \isac} |
144 TODO |
140 \begin{itemize} |
145 \end{frame} |
141 \item Computer Theorem Prover Isabelle |
146 |
142 \item Math Learning Assistent \isac |
147 \subsection[TODO]{Computation and deduction in a Lucas-Interpreter} |
143 \end{itemize} |
148 \begin{frame} |
144 \end{frame} |
149 \frametitle{Computation and deduction in a Lucas-Interpreter} |
145 |
150 TODO |
146 \subsection[Computation \& Deduction]{Computation and Deduction in a Lucas-Interpreter} |
|
147 \begin{frame} |
|
148 \frametitle{Computation and Deduction in a Lucas-Interpreter} |
|
149 \includegraphics[width=100mm]{overview.pdf} |
151 \end{frame} |
150 \end{frame} |
152 |
151 |
153 \section[Contributions]{Contributions of the project} |
152 \section[Contributions]{Contributions of the project} |
154 \subsection[TODO]{Introduction of Isabelle Contexts} |
153 \subsection[Contexts]{Introduction of Isabelle Contexts} |
155 \begin{frame} |
154 \begin{frame} |
156 \frametitle{TODO} |
155 \frametitle{Introduction of Isabelle Contexts} |
157 TODO |
156 \begin{itemize} |
158 \end{frame} |
157 \item theories too general |
159 |
158 \item not capable of type inference |
160 \subsection[TODO]{Redesign of type inference in \isac} |
159 \item replace function \texttt{parseNEW} |
161 \begin{frame} |
160 \end{itemize} |
162 \frametitle{TODO} |
161 \end{frame} |
163 TODO |
162 |
164 \end{frame} |
163 \begin{frame} |
165 |
164 \frametitle{Introduction of Isabelle Contexts} |
166 \subsection[TODO]{Improvement of functional code} |
165 \texttt{\tiny{ |
167 \begin{frame} |
166 \begin{tabbing} |
168 \frametitle{Drop \textit{Check\_Elementwise} !} |
167 xx\=xx\=xx\=xx\=\kill |
169 %\begin{verbatim} |
168 fun parse thy str =\\ |
170 %solve (x / (x ^ 2 - 6 * x + 9) - 1 / (x ^ 2 - 3 * x) = 1 / x, x) |
169 \>(let val t = (typ\_a2real o numbers\_to\_string)\\ |
171 % x / (x ^ 2 - 6 * x + 9) - 1 / (x ^ 2 - 3 * x) = 1 / x |
170 \>\>\>\>(Syntax.read\_term\_global thy str)\\ |
172 % x / (x ^ 2 + -1 * (6 * x) + 9) + -1 * 1 / (x ^ 2 + -1 * (3 * x)) = 1 / x |
171 \>\>in SOME (cterm\_of thy t) end)\\ |
173 % (3 + -1 * x + x ^ 2) / (9 * x + -6 * x ^ 2 + x ^ 3) = 1 / x |
172 \>\>\>handle \_ => NONE; |
174 % (3 + -1 * x + x ^ 2) * x = 1 * (9 * x + -6 * x ^ 2 + x ^ 3) |
173 \\~\\~\\ |
175 % solve ((3 + -1 * x + x ^ 2) * x = 1 * (9 * x + -6 * x ^ 2 + x ^ 3), x) |
174 fun parseNEW ctxt str = SOME (Syntax.read\_term ctxt str |> numbers\_to\_string)\\ |
176 % (3 + -1 * x + x ^ 2) * x = 1 * (9 * x + -6 * x ^ 2 + x ^ 3) |
175 \>\>\>handle \_ => NONE; |
177 % (3 + -1 * x + x ^ 2) * x - 1 * (9 * x + -6 * x ^ 2 + x ^ 3) = 0 |
176 \\~\\~\\ |
178 % (3 + -1 * x + x ^ 2) * x - (9 * x + -6 * x ^ 2 + x ^ 3) = 0 |
177 local\\ |
179 % -6 * x + 5 * x ^ 2 = 0 |
178 \>fun insert\_ctxt data = ContextData.map (fn xs => distinct (data@xs));\\ |
180 % solve (-6 * x + 5 * x ^ 2 = 0, x) |
179 in\\ |
181 % [x = 0, x = 6 / 5] |
180 \>fun insert\_assumptions asms = map (fn t => Asm t) asms |> insert\_ctxt;\\ |
182 % [x = 0, x = 6 / 5] |
181 \>fun insert\_environments envs = map (fn t => Env t) envs |> insert\_ctxt;\\ |
183 % [x = 6 / 5] |
182 end |
184 %[x = 6 / 5] |
183 \end{tabbing} |
185 %\end{verbatim} |
184 }} |
|
185 \end{frame} |
|
186 |
|
187 \subsection[Redesign]{Redesign of Type Inference in \isac} |
|
188 \begin{frame} |
|
189 \frametitle{Redesign of type inference in \isac} |
|
190 \begin{itemize} |
|
191 \item use context type inference |
|
192 \item parsing input (specification \& user input) |
|
193 \item specification with polymorphic types |
|
194 \item etc. |
|
195 \end{itemize} |
|
196 \end{frame} |
|
197 |
|
198 \subsection[Code Improvement]{Improvement of functional code} |
|
199 \begin{frame} |
|
200 \frametitle{Improvement of functional code} |
|
201 \begin{itemize} |
|
202 \item combinators |
|
203 \item code conventions |
|
204 \end{itemize} |
|
205 \end{frame} |
|
206 |
|
207 \begin{frame} |
|
208 \frametitle{Combinators \& Code Conventions} |
|
209 \texttt{\tiny{ |
|
210 \begin{tabbing} |
|
211 xx\=xx\=xx\=xx\=xx\=\kill |
|
212 fun prep\_ori [] \_ \_ = ([], e\_ctxt)\\ |
|
213 \>| prep\_ori fmz thy pbt =\\ |
|
214 \>\>\>let\\ |
|
215 \>\>\>\>val ctxt = ProofContext.init\_global thy |> fold declare\_constraints fmz\\ |
|
216 \>\>\>\>val ori = map (add\_field thy pbt o split\_dts o the o parseNEW ctxt) fmz\\ |
|
217 \>\>\>\>\>|> add\_variants\\ |
|
218 \>\>\>\>val maxv = map fst ori |> max\\ |
|
219 \>\>\>\>val maxv = if maxv = 0 then 1 else maxv\\ |
|
220 \>\>\>\>val oris = coll\_variants ori\\ |
|
221 \>\>\>\>\>|> map (replace\_0 maxv |> apfst)\\ |
|
222 \>\>\>\>\>|> add\_id\\ |
|
223 \>\>\>\>\>|> map flattup\\ |
|
224 \>\>\>in (oris, ctxt) end; |
|
225 \end{tabbing} |
|
226 }} |
|
227 \end{frame} |
|
228 |
|
229 \begin{frame} |
|
230 \frametitle{Drop \tt{Check\_Elementwise}!} |
186 |
231 |
187 \small{ |
232 \small{ |
188 %\begin{onehalfspace} |
233 %\begin{onehalfspace} |
189 \begin{tabbing} |
234 \begin{tabbing} |
190 xxx\=xxx\=\kill |
235 xxx\=xxx\=\kill |