<!DOCTYPE TEI.2 PUBLIC '-//C. M. Sperberg-McQueen//DTD
          TEI Lite 1.0 plus SWeb (XML)//EN'
          '../../../lib/swebxml.dtd' [
<!ATTLIST list type CDATA 'bullets' >
<!ATTLIST seg  rend CDATA 'incremental' >
<!ATTLIST xref href CDATA '' >

<!ATTLIST item id ID #IMPLIED >
<!ATTLIST div id ID #IMPLIED >
<!ATTLIST item id ID #IMPLIED >

<!ENTITY date.last.touched '3 July 2013'>

<!--* 
<!ENTITY city '[CITY]'>
<!ENTITY state '[STATE]'>
<!ENTITY city-state '&city;, &state;'>
<!ENTITY course-dates '[D-D MONTH YYYY]'>
<!ENTITY earlybird-deadline '[DD MONTH YYYY]'>
<!ENTITY course-price '[$NNN]'>
<!ENTITY earlybird-price '[$MMM]'>
<!ENTITY dow1 '[DAY1]'>
<!ENTITY dow2 '[DAY2]'>
<!ENTITY course-dow '&dow1; and &dow2;'>

<!ENTITY hostorg '[HOST]'>
<!ENTITY hostorg-inc '[HOST, Inc.]'>
<!ENTITY course-address '<address>
<addrLine>[HOST]</addrLine>
<addrLine>[STREET]</addrLine>
<addrLine>[CITY, STATE, ZIP]</addrLine>
</address>'>
<!ENTITY local-info '<p>For <label>Metro directions</label>, <label>driving directions</label>,
<label>parking information</label>, and
<label>maps</label>, see
[LOCAL INFO SOURCE].
</p>

<p><label>Accessibility</label>: [ACCESSIBILITY-DESCRIPTION]
</p>
'>
*-->

<!--* for real *-->
<!ENTITY city 'Lincoln'>
<!ENTITY state 'Nebraska'>
<!ENTITY city-state '&city;, &state;'>
<!ENTITY course-dates '15 July 2013'>
<!ENTITY dow1 'Monday'>
<!ENTITY course-dow '&dow1;'>

<!ENTITY hostorg 'University of Nebraska'>
<!ENTITY ntilde  "&#241;" ><!-- small n, tilde -->

]>
<?xml-stylesheet type="text/xsl" href="../../../lib/courses201206.bmt.xsl"?> 
<!--* <?xml-stylesheet type="text/xsl" href="../../../lib/xforms201102.bmt.xsl"?>  *-->
<TEI.2 rend="no-sec-nums">
<teiHeader>
<fileDesc>
<titleStmt>
<title type="main">Introduction to Alloy</title>
<title type="sub">XQuery as a tool for working with natural-language documents</title>
</titleStmt>
<publicationStmt>
<pubPlace>Espa&ntilde;ola, New Mexico</pubPlace>
<publisher>Black Mesa Technologies LLC</publisher>
<date>2012</date>
</publicationStmt>
<sourceDesc>
<p>No source; created in electronic form.</p>
</sourceDesc>
</fileDesc>
</teiHeader>
<text>
<front>
<titlePage>
<docTitle>
<titlePart>Taking modeling seriously</titlePart>
<titlePart>A hands-on introduction to Alloy</titlePart>
</docTitle>

<titlePart type="event-loc">&city-state;</titlePart>
<titlePart type="event-date">&course-dates;</titlePart>

<!--*
<docAuthor>C. M. Sperberg-McQueen, Black Mesa Technologies LLC</docAuthor>
<docDate>rev. &date.last.touched;</docDate>
*-->
<docDate rend="footer">&date.last.touched;</docDate>
</titlePage>

<div id="navbar" type="navbar">
<head>Nearby documents</head>
<list>
<!--* <item><xref href="online.html">Online interface to Thutmose II</xref></item>
      <item><xref href="progdoc.xml">Programmers' documentation</xref></item>
    *-->
<item id="siteroot"><xref href="../../../">Home</xref></item>
</list>
</div>
</front>
<body>
<p>This full-day hands-on tutorial introduces Alloy as a modeling
tool for digital humanities work.</p>
<p>The modeling of humanities data is a core activity (some say the
core activity) of the digital humanities. The activity so described
may take a wide variety of forms; often the term is used for any
compact description of a domain, whether in prose or in user-interface
metaphors. Machine-processable descriptions are probably more common,
but these, too, vary: the definition of an XML vocabulary, the table
declarations for a SQL database, the data structures or even the
executable code of a program may all be described informally as
offering a ‘model’ of some domain or other.
</p>
<p>
Properly speaking, however, the term model is most usefully applied to
expressions in some well defined formalization. Models are most useful
when formalized in a declarative not a procedural notation, and when
their logical import is clear. Formulating precise models can be
difficult. Inconsistencies and unforeseen interferences between parts
of the model can easily creep in. With informal definitions, such
shortcomings can remain undetected for long periods, even until after
the model has been put to use. Formally defined models, on the other
hand, can be tested systematically for logical consistency; their
consequences can be established systematically. Such testing can help
uncover shortcomings in a timely manner.
</p>
<p>
Alloy is a tool for “lightweight formal methods”, which makes it
easier to test the implications of our models and check our
assumptions for plausibility, consistency, and completeness. Its usual
application area is the testing of software designs, but the variant
of first-order logic provided by Alloy is by no means limited to the
description of software or electronic objects. It can be (and has
been) successfully used to formalize notions far removed from any
software (including the nature of transcription, an application of the
type/token distinction to document structure, and fragments of Goodman
and Nelson's mereology and of Hilbert's formulation of Euclidean
geometry). Alloy's logic is powerful enough to formulate interesting
concepts, while remaining weak enough to be tractable for machine
processing. Using Alloy's syntax, a modeler can formulate the axioms
of a model and augment them by asserting that certain properties hold
for all instances of the model, or by defining predicates which
characterize particular instances of the model. The Alloy Analyzer can
test the assertions and illustrate the predicates, by seeking
counter-examples to the assertion or instances of the predicate.</p>
<p>Hands-on exercises will give students experience actually writing
simple models in Alloy and examining their properties using the
Alloy Analyzer.

Participants should have good knowledge of XML syntax;
knowledge of XPath and XSLT (1.0 or 2.0) will be helpful but is not a
prerequisite. Familiarity with basic programming concepts (input,
output, types, flow of control will be helpful (or alternatively, the
ability to confront new concepts without fear).</p>
<div id="topics">
<head>Topics and syllabus</head>
<p>Topics include:
<list type="bullets">
<item id="intro">
<p><label>Introduction</label></p>
<p>Modeling, formal logic, formal methods. Lightweight formal methods;
Alloy.</p>
<p>Demonstration: Alloy model of manuscript traditions.</p>
<p>Hands-on exercise.  Using the Analyzer: 
the absolute minimum of Alloy syntax (<kw>sig</kw>, <kw>fact</kw>,
<kw>pred</kw>, <kw>run</kw>, <kw>assert</kw>, <kw>check</kw>)
and a <soCalled>hello, world</soCalled> example (Gen. 1:1).</p>
</item>

<item><p><label>Alloy's first-order logic</label></p>
<p>Alloy's universe of discourse (atoms, tuples, relations, sets).</p>
<p>Basic syntax:  signatures, sub-signatures, subset signatures,
multiplicities, compound objects, relations.</p>
<p>The small-scope hypothesis; how Alloy manages to
be useful despite Goedel's Theorem.</p>
<p>Set operations; hands-on exercise.</p>
<p>Logical operators, sentential logic; hands-on exercise.</p>
</item>
<item><p><label>Quantification and relations</label></p>
<p>Universal and existential quantification; the keyword <kw>one</kw> 
and Russell's definite descriptions; exercise.</p>
<p>Operations on relations; exercise.</p>
<p>Set comprehensions, <kw>let</kw> expressions; exercise.</p>
<p>More about the Analyzer:  customizing the theme, exporting
examples; the evaluator.</p>
<p>Facts, predicates, assertions, functions.</p>
<p>Styles of expression: predicate-calculus style, navigational style,
relational style.</p>
<p>Using Alloy to model concepts: bibliographic entities in FRBR
(Functional Reqirements for Bibliographic Records).</p>
</item>
<item>
<p><label>Recursion, conclusion</label></p>

<p>Recursion via transitive closure; serial-adder example.</p>
<p>Dynamic systems:  operations, traces, events.</p>
<p>Q/A and pointers for further information.</p>
</item>
</list>
</p>

<!--*
<p><label>Resources</label>:
<xref href="slides/outline.xml">course outline</xref> (with links to slides),
<xref href="misc/xforms.resources.xml">XForms resources list</xref>,
sample <xref href="data/Gorbals/gorbals-description.xml">Gorbals census data</xref>.
</p>
*-->

</div>

<div id="resources">
<head>Resources</head>
<p>Some materials of possible interest:
<list>
<item><xref href="http://alloy.mit.edu/">Alloy web site</xref></item>
<item><xref href="http://stackoverflow.com/questions/tagged/alloy"
>Alloy questions on Stack Overflow</xref></item>
<item>course outline, with pointers to slides 
(<xref href="slides/outline.xml">XML</xref>,
<xref href="slides/outline.xhtml">XHTML</xref>)</item>
<item>exercise sheet (<xref href="slides/exercises.xml">XML</xref>,
<xref href="slides/exercises.xhtml">XHTML</xref>,
<xref href="slides/exercises.pdf">PDF</xref>)</item>
<item>Alloy syntax summary (<xref href="slides/cheatsheet.xml">XML</xref>,
<xref href="slides/cheatsheet.xhtml">XHTML</xref>,
<xref href="slides/cheatsheet.pdf">PDF</xref>)</item>
</list>
</p>

</div>

<div id="prerequisites">
<head>Prerequisites</head>
<p>There are no formal prerequisites. Some prior exposure to symbolic
logic and/or programming is probably desirable; failing that,
sufficiently motivated participants may be able to benefit from the
workshop if they have sufficiently high tolerance for exposure to new
material.</p>

<p>Students should bring a laptop computer with a current installation
of Java; they may optionally pre-install Alloy 4.2 or they may install
it during the workshop.</p>

</div>
<div id="logistics">
<head>Logistics</head>

<div id="where-when">
<head>When and where</head>
<p>This course will be held from 9:30 a.m. to 5:30 p.m.
&course-dow;, &course-dates;, 
in conjunction with the
<xref href="http://dh2013.unl.edu/">Digital Humanites 2013</xref>
conference hosted by the University of Nebraska - Lincoln.
Thanks to the conference sponsors for hosting the tutorial.
</p>
</div>

<div id="who">
<head>Who</head>
<p>The course is organized by Black Mesa Technologies LLC and 
will be taught by 
<xref href=".../../../who/cmsmcq/">C. M. Sperberg-McQueen</xref>.
</p>
<p>
Michael Sperberg-McQueen 
is the founder of Black Mesa Technologies.
He has served as co-editor of the XML 1.0 specification, the
Text Encoding Initiative's 
<title>Guidelines for Text Encoding and Interchange</title>, 
and the XML Schema Definition Language (XSD) 1.1 specification;
in 2003 he was awarded the XML Cup for contributions to the
development and spread of XML.
</p>
</div>


</div>
</body>
</text>
</TEI.2>
<!-- Keep this comment at the end of the file
Local variables:
mode: xml
sgml-default-dtd-file:"/Library/SGML/Public/Emacs/sweb.ced"
sgml-omittag:t
sgml-shorttag:t
End:
-->
