Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
SETL
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{Short description|Programming language}} {{Redirect|Setl|the indigenous location in Canada|Bridge River Rapids}} {{Infobox programming language | logo = | paradigm = [[Multi-paradigm programming language|multi-paradigm]]: [[Imperative programming|imperative]], [[Procedural programming|procedural]], [[Structured programming|structured]], [[Object-oriented programming|object-oriented]] | released = {{Start date and age|1969}} | designer = (Jack) [[Jacob T. Schwartz]] | developer = [[Courant Institute of Mathematical Sciences]] | latest release version = 1.1 | latest release date = {{Start date and age|2005|01|07}} | typing = [[Type system#DYNAMIC|Dynamic]] | implementations = | dialects = | website = {{URL|setl.org}} | influenced_by = [[ALGOL 60]] | influenced = [[SETL2]], [[ISETL]], [[SETLX]], [[Starset (programming language)|Starset]], [[ABC (programming language)|ABC]] }} '''SETL''' (SET Language) is a [[very high-level programming language]]<ref name=":0">{{Cite journal |last=Schwartz |first=J. T. |last2=Dewar |first2=R. B. K. |last3=Schonberg |first3=E. |last4=Dubinsky |first4=E. |date=1986 |title=Programming with Sets |url=https://doi.org/10.1007/978-1-4613-9575-1 |journal=SpringerLink |language=en |pages=v-vii, 2, 48, 53, 57-58, 63, 113ff |doi=10.1007/978-1-4613-9575-1|url-access=subscription }}</ref> based on the mathematical [[Set theory|theory of sets]].<ref name=":2">{{Cite web |title=GNU SETL Om |url=https://setl.org/setl/doc/setl.html |access-date=2024-04-24 |website=setl.org}}</ref><ref name=":3">{{Cite news |last=Markoff |first=John |date=2009-03-04 |title=Jacob T. Schwartz, 79, Restless Scientist, Dies |url=https://www.nytimes.com/2009/03/04/science/04schwartz.html |access-date=2024-04-24 |work=The New York Times |language=en-US |issn=0362-4331}}</ref> It was originally developed at the [[New York University]] (NYU) [[Courant Institute of Mathematical Sciences]] in the late 1960s, by a group containing (Jack) [[Jacob T. Schwartz]],<ref name=":0" /><ref name=":3" /> R.B.K. Dewar, and E. Schonberg.<ref name=":0" /> Schwartz is credited with designing the language.<ref>{{Cite book |url=https://link.springer.com/book/10.1007/978-0-85729-808-9 |title=Computational Logic and Set Theory |pages=vii |language=en |doi=10.1007/978-0-85729-808-9}}</ref> == Design == SETL provides two basic aggregate data types: (unordered) ''sets'', and ''tuples''.<ref name=":0" /><ref name=":2" /><ref name=":4">{{Cite web |title=CHAPTER 2 |url=https://www.settheory.com/Chapters/Chapter_2.html |access-date=2024-04-24 |website=www.settheory.com}}</ref> The elements of sets and tuples can be of any arbitrary type, including sets and tuples themselves, except the undefined value '''om'''<ref name=":0" /> (sometimes capitalized: '''OM''').<ref>{{Cite web |title=CHAPTER 3 |url=https://www.settheory.com/Chapters/Chapter_3.html |access-date=2024-04-24 |website=www.settheory.com}}</ref> ''Maps'' are provided as sets of ''pairs'' (i.e., tuples of length 2) and can have arbitrary domain and range types.<ref name=":0" /><ref name=":4" /> Primitive operations in SETL include set membership, union, intersection, and power set construction, among others.<ref name=":0" /><ref name=":5">{{Cite web |title=CHAPTER 3 |url=https://www.settheory.com/Chapters/Chapter_3.html |access-date=2024-04-24 |website=www.settheory.com}}</ref> SETL provides quantified boolean expressions constructed using the [[universal quantifier|universal]] and [[existential quantifier]]s of [[first-order predicate logic]].<ref name=":0" /><ref name=":5" /> SETL provides several [[iterator]]s to produce a variety of loops over aggregate data structures.<ref name=":0" /><ref>{{Cite web |title=CHAPTER 4 |url=https://www.settheory.com/Chapters/Chapter_4.html |access-date=2024-04-24 |website=www.settheory.com}}</ref> == Examples == Print all prime numbers from 2 to {{Var|N}}: print([n in [2..N] | forall m in {2..n - 1} | n mod m > 0]); The notation is similar to [[list comprehension]]. A factorial procedure definition: procedure factorial(n); -- calculates the factorial n! return if n = 1 then 1 else n * factorial(n - 1) end if; end factorial; A more conventional SETL expression for factorial (n > 0): */[1..n] == Uses == Implementations of SETL were available on the [[CDC 6600]], [[CDC Cyber]], DEC [[VAX]], [[IBM/370]], [[Sun Microsystems|SUN]] workstation and [[Apollo Computer|APOLLO]].<ref>{{cite book | title = Programming with sets. An Introduction to SETL | author = J.T. Schwartz | author2 = R.B.K. Dewar | author3 = E. Dubinsky | author4 = E. Schonberg | publisher = Springer-Verlag New York Inc. | year = 1986 | isbn = 978-1-4613-9577-5 | url = https://books.google.com/books?id=4pfbBwAAQBAJ&pg=PR6 }}</ref> In the 1970s, SETL was ported to the [[BESM-6]], [[ES EVM]] and other Russian computer systems.<ref>{{cite book | title = Становление новосибирской школы программирования (мозаика воспоминаний) | trans-title = Formation of the Novosibirsk school of programming (mosaic of memories) | editor = И.В. Поттосин | location = Новосибирск | publisher = Институт систем информатики им. А. П. Ершова СО РАН | year = 2001 | pages = 106–113 | url = https://www.iis.nsk.su/files/articles/mozaika.pdf | language = ru }}</ref> SETL was used for an early implementation of the programming language [[Ada (programming language)|Ada]], named the NYU Ada/ED translator.<ref>{{cite book |first1=Robert B. K. |last1=Dewar |first2=Gerald A. |last2=Fisher Jr. |first3=Edmond |last3=Schonberg |first4=Robert |last4=Froelich |first5=Stephen |last5=Bryant |first6=Clinton F. |last6=Goss |first7=Michael |last7=Burke |title=Proceeding of the ACM-SIGPLAN symposium on Ada programming language - SIGPLAN '80 |chapter=The NYU Ada translator and interpreter |volume=15 |issue=11 |pages=194–201 |date=November 1980 |isbn=0-89791-030-3 |doi=10.1145/948632.948659|s2cid=10586359 }}</ref> This later became the first validated Ada implementation, certified on April 11, 1983.<ref>{{cite web |url=http://www.dtic.mil/docs/citations/ADA136759 |archive-url=https://web.archive.org/web/20170607044753/http://www.dtic.mil/docs/citations/ADA136759 |url-status=dead |archive-date=June 7, 2017 |title=Ada Compiler Validation Summary Report: NYU Ada/ED, Version 19.7 V-001 |author=SofTech Inc., Waltham, MA |date=1983-04-11 |access-date=2010-12-16}}</ref> According to [[Guido van Rossum]], "[[Python (programming language)|Python]]'s predecessor, [[ABC (programming language)|ABC]], was inspired by SETL -- [[Lambert Meertens]] spent a year with the SETL group at NYU before coming up with the final ABC design!"<ref>[http://mail.python.org/pipermail/python-dev/2000-August/008881.html Python-Dev: SETL (was: Lukewarm about range literals)]</ref> ==Language variants== ''SET Language 2'' (SETL2), a backward incompatible descendant of SETL, was created by Kirk Snyder of the Courant Institute of Mathematical Sciences at [[New York University]] in the late 1980s.<ref name=":1">{{Cite web |title=SETL2 - EDM2 |url=http://www.edm2.com/index.php/SETL2 |access-date=2024-04-24 |website=www.edm2.com}}</ref> Like its predecessor, it is based on the theory and notation of finite sets, but has also been influenced in syntax and style by the Ada language.<ref name=":1" /> ''Interactive SET Language'' (ISETL) is a variant of SETL used in [[discrete mathematics]].<ref>{{Cite book |last=Baxter Hastings |first=Nancy |title=Learning discrete mathematics with ISETL |last2=Dubinsky |first2=Ed |last3=Levin |first3=Gary |date=1989 |publisher=Springer-Verlag |isbn=978-0-387-96898-8 |location=New York}}</ref> ''GNU SETL'' is a command-line utility that extends and implements SETL.<ref>{{Cite web |title=GNU SETL |url=https://setl.org/setl/ |access-date=2024-04-24 |website=setl.org}}</ref> == References == {{Reflist}} == Further reading == * Schwartz, Jacob T., "Set Theory as a Language for Program Specification and Programming". Courant Institute of Mathematical Sciences, New York University, 1970. * Schwartz, Jacob T., "On Programming, An Interim Report on the SETL Project", Computer Science Department, Courant Institute of Mathematical Sciences, New York University (1973). * Schwartz, Jacob T., Dewar, R.B.K., Dubinsky, E., and Schonberg, E., ''Programming With Sets: An Introduction to SETL'', 1986. {{ISBN|0-387-96399-5}}. == External links == * {{Official website}} * [http://www.settheory.com ''Programming in SETL'' and other things] * [http://www.softwarepreservation.org/projects/SETL SETL Historical Sources Archive] {{Authority control}} [[Category:Academic programming languages]] [[Category:Set theoretic programming languages]] [[Category:Programming languages created in 1969]]
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)
Pages transcluded onto the current version of this page
(
help
)
:
Template:Authority control
(
edit
)
Template:Cite book
(
edit
)
Template:Cite journal
(
edit
)
Template:Cite news
(
edit
)
Template:Cite web
(
edit
)
Template:ISBN
(
edit
)
Template:Infobox programming language
(
edit
)
Template:Official website
(
edit
)
Template:Redirect
(
edit
)
Template:Reflist
(
edit
)
Template:Short description
(
edit
)
Template:Var
(
edit
)